作者 tangxvhui

调整时间格式化输出

@@ -37,9 +37,6 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue @@ -37,9 +37,6 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue
37 defer func() { 37 defer func() {
38 _ = transactionContext.RollbackTransaction() 38 _ = transactionContext.RollbackTransaction()
39 }() 39 }()
40 - // staffAssessTaskRepo := factory.CreateStaffAssessTaskRepository(map[string]interface{}{  
41 - // "transactionContext": transactionContext,  
42 - // })  
43 40
44 staffAssessTaskRepo := dao.NewStaffAssessDao(map[string]interface{}{ 41 staffAssessTaskRepo := dao.NewStaffAssessDao(map[string]interface{}{
45 "transactionContext": transactionContext, 42 "transactionContext": transactionContext,
@@ -59,18 +56,7 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue @@ -59,18 +56,7 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue
59 if err != nil { 56 if err != nil {
60 return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, "查询评估任务"+err.Error()) 57 return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, "查询评估任务"+err.Error())
61 } 58 }
62 - // condition := map[string]interface{}{  
63 - // "executorId": param.UserId,  
64 - // "companyId": param.CompanyId,  
65 - // "limit": limit,  
66 - // }  
67 - // if offset > 0 {  
68 - // condition["offset"] = offset  
69 - // }  
70 - // cnt, assessTaskList, err := staffAssessTaskRepo.Find(condition)  
71 - // if err != nil {  
72 - // return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, "查询周期"+err.Error())  
73 - // } 59 +
74 if err := transactionContext.CommitTransaction(); err != nil { 60 if err := transactionContext.CommitTransaction(); err != nil {
75 return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error()) 61 return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
76 } 62 }
@@ -79,8 +65,8 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue @@ -79,8 +65,8 @@ func (srv StaffAssessServeice) SearchAssessTaskMe(param *query.SearchAssessMeQue
79 for _, v := range assessTaskList { 65 for _, v := range assessTaskList {
80 temp = adapter.SearchAssessMeResp{ 66 temp = adapter.SearchAssessMeResp{
81 AssessTaskId: v.Id, 67 AssessTaskId: v.Id,
82 - BeginTime: v.BeginTime.Format("2006-01-02 15:04:05"),  
83 - EndTime: v.EndTime.Format("2006-01-02 15:04:05"), 68 + BeginTime: v.BeginTime.Local().Format("2006-01-02 15:04:05"),
  69 + EndTime: v.EndTime.Local().Format("2006-01-02 15:04:05"),
84 CycleId: v.CycleId, 70 CycleId: v.CycleId,
85 CycleName: v.CycleName, 71 CycleName: v.CycleName,
86 EvaluationProjectId: v.EvaluationProjectId, 72 EvaluationProjectId: v.EvaluationProjectId,