Merge branch 'dev' of http://gitlab.fjmaimaimai.com/allied-creation/allied-creation-gateway into dev
正在显示
1 个修改的文件
包含
4 行增加
和
9 行删除
@@ -350,7 +350,7 @@ func (usersService *UsersService) CooperationUserGet(cooperationUserGetQuery *qu | @@ -350,7 +350,7 @@ func (usersService *UsersService) CooperationUserGet(cooperationUserGetQuery *qu | ||
350 | } | 350 | } |
351 | var deadline int64 | 351 | var deadline int64 |
352 | if !result.CooperationInfo.CooperationDeadline.IsZero() { | 352 | if !result.CooperationInfo.CooperationDeadline.IsZero() { |
353 | - deadline = result.CooperationInfo.CooperationDeadline.UnixNano() / 1e6 | 353 | + deadline = result.CooperationInfo.CooperationDeadline.Unix() |
354 | } | 354 | } |
355 | userInfo := dto.CooperationUserInfo{ | 355 | userInfo := dto.CooperationUserInfo{ |
356 | UserId: strconv.Itoa(result.UserId), | 356 | UserId: strconv.Itoa(result.UserId), |
@@ -399,7 +399,7 @@ func (usersService *UsersService) CooperationUserList(cooperationUserListQuery * | @@ -399,7 +399,7 @@ func (usersService *UsersService) CooperationUserList(cooperationUserListQuery * | ||
399 | OrgName: v.Org.OrgName, | 399 | OrgName: v.Org.OrgName, |
400 | OrgId: strconv.Itoa(v.Org.OrgId), | 400 | OrgId: strconv.Itoa(v.Org.OrgId), |
401 | } | 401 | } |
402 | - if !v.CooperationInfo.CooperationDeadline.IsZero() { | 402 | + if !v.CooperationInfo.CooperationDeadline.IsZero() && v.CooperationInfo.CooperationDeadline.After(time.Unix(1136044800, 0)) { |
403 | item.CooperationDeadline = v.CooperationInfo.CooperationDeadline.Format("2006-01-02") | 403 | item.CooperationDeadline = v.CooperationInfo.CooperationDeadline.Format("2006-01-02") |
404 | } | 404 | } |
405 | 405 | ||
@@ -435,15 +435,10 @@ func (usersService *UsersService) CooperationUserResetPassword(cooperationUserRe | @@ -435,15 +435,10 @@ func (usersService *UsersService) CooperationUserResetPassword(cooperationUserRe | ||
435 | func (usersService *UsersService) CooperationUserUpdate(cooperationUserUpdateCommand *command.CooperationUserUpdateCommand) (interface{}, error) { | 435 | func (usersService *UsersService) CooperationUserUpdate(cooperationUserUpdateCommand *command.CooperationUserUpdateCommand) (interface{}, error) { |
436 | creationUserGateway := allied_creation_user.NewHttplibAlliedCreationUser( | 436 | creationUserGateway := allied_creation_user.NewHttplibAlliedCreationUser( |
437 | cooperationUserUpdateCommand.Operator) | 437 | cooperationUserUpdateCommand.Operator) |
438 | - var cooperationDeadline time.Time | ||
439 | - if cooperationUserUpdateCommand.CooperationDeadline > 0 { | ||
440 | - cooperationDeadline = time.Unix(cooperationUserUpdateCommand.CooperationDeadline, 0) | ||
441 | - } | ||
442 | - | ||
443 | _, err := creationUserGateway.CooperatorUserUpdate(allied_creation_user.ReqUpdateCooperatorUser{ | 438 | _, err := creationUserGateway.CooperatorUserUpdate(allied_creation_user.ReqUpdateCooperatorUser{ |
444 | UserId: cooperationUserUpdateCommand.UserId, | 439 | UserId: cooperationUserUpdateCommand.UserId, |
445 | CooperationCompany: cooperationUserUpdateCommand.CooperationCompany, | 440 | CooperationCompany: cooperationUserUpdateCommand.CooperationCompany, |
446 | - CooperationDeadline: cooperationDeadline, | 441 | + CooperationDeadline: time.Unix(cooperationUserUpdateCommand.CooperationDeadline/1000, 0), |
447 | Email: cooperationUserUpdateCommand.Email, | 442 | Email: cooperationUserUpdateCommand.Email, |
448 | EnableStatus: cooperationUserUpdateCommand.EnableStatus, | 443 | EnableStatus: cooperationUserUpdateCommand.EnableStatus, |
449 | UserCode: cooperationUserUpdateCommand.UserCode, | 444 | UserCode: cooperationUserUpdateCommand.UserCode, |
@@ -555,7 +550,7 @@ func (usersService *UsersService) GetInitPassword(operator domain.Operator) (str | @@ -555,7 +550,7 @@ func (usersService *UsersService) GetInitPassword(operator domain.Operator) (str | ||
555 | var password string | 550 | var password string |
556 | alliedCreationBasic := allied_creation_basic.NewHttplibAlliedCreationBasic(operator) | 551 | alliedCreationBasic := allied_creation_basic.NewHttplibAlliedCreationBasic(operator) |
557 | reqResult, err := alliedCreationBasic.SystemSettingGet(allied_creation_basic.ReqSystemSettingGet{ | 552 | reqResult, err := alliedCreationBasic.SystemSettingGet(allied_creation_basic.ReqSystemSettingGet{ |
558 | - SettingCode: domain.InitPasswordSettingKey, | 553 | + domain.InitPasswordSettingKey, |
559 | }) | 554 | }) |
560 | if err != nil { | 555 | if err != nil { |
561 | log.Logger.Error(err.Error()) | 556 | log.Logger.Error(err.Error()) |
-
请 注册 或 登录 后发表评论