作者 tangxvhui

bug 修复

@@ -344,8 +344,8 @@ func AddUserCompanyData(centerCompany *ModuleCompanytData, newcompany *models.Co @@ -344,8 +344,8 @@ func AddUserCompanyData(centerCompany *ModuleCompanytData, newcompany *models.Co
344 uc = &models.UserCompany{ 344 uc = &models.UserCompany{
345 UserId: newuser.Id, 345 UserId: newuser.Id,
346 CompanyId: newcompany.Id, 346 CompanyId: newcompany.Id,
347 - Enable: models.USERCOMPANY_ENABLE_YES,  
348 - ChargeStatus: models.USERCOMPANY_CHARGE_YES, 347 + Enable: adminUserData.Status,
  348 + ChargeStatus: adminUserData.ChargeStatus,
349 Id: adminUserData.Id, 349 Id: adminUserData.Id,
350 NickName: adminUserData.Name, 350 NickName: adminUserData.Name,
351 OpenId: adminUserData.OpenId, 351 OpenId: adminUserData.OpenId,
@@ -359,8 +359,8 @@ func AddUserCompanyData(centerCompany *ModuleCompanytData, newcompany *models.Co @@ -359,8 +359,8 @@ func AddUserCompanyData(centerCompany *ModuleCompanytData, newcompany *models.Co
359 IsBusiness: adminUserData.IsBusiness, 359 IsBusiness: adminUserData.IsBusiness,
360 Avatar: adminUserData.Avatar, 360 Avatar: adminUserData.Avatar,
361 Remarks: adminUserData.Remarks, 361 Remarks: adminUserData.Remarks,
362 - // AdminType: adminUserData.AdminType,  
363 - ExtraText: adminUserData.ExtraText, 362 + AdminType: adminUserData.AdminType,
  363 + ExtraText: adminUserData.ExtraText,
364 } 364 }
365 _, err = models.AddUserCompany(uc, o) 365 _, err = models.AddUserCompany(uc, o)
366 if err != nil { 366 if err != nil {
@@ -359,6 +359,7 @@ func UpdateEmployeeData(data ModuleEmployee) error { @@ -359,6 +359,7 @@ func UpdateEmployeeData(data ModuleEmployee) error {
359 ucompany.Remarks = data.Remarks 359 ucompany.Remarks = data.Remarks
360 ucompany.ChargeStatus = data.ChargeStatus 360 ucompany.ChargeStatus = data.ChargeStatus
361 ucompany.ExtraText = data.ExtraText 361 ucompany.ExtraText = data.ExtraText
  362 + ucompany.AdminType = data.AdminType
362 cols := []string{"NickName", "OpenId", "Sex", "JobNum", 363 cols := []string{"NickName", "OpenId", "Sex", "JobNum",
363 "Phone", "PrivatePhone", "Email", "ExtensionNum", "Workspace", 364 "Phone", "PrivatePhone", "Email", "ExtensionNum", "Workspace",
364 "IsBusiness", "Avatar", "Remarks", "AdminType", "ChargeStatus", 365 "IsBusiness", "Avatar", "Remarks", "AdminType", "ChargeStatus",