|
@@ -478,6 +478,14 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
|
@@ -478,6 +478,14 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
478
|
assessRepo := factory.CreateStaffAssessRepository(map[string]interface{}{
|
478
|
assessRepo := factory.CreateStaffAssessRepository(map[string]interface{}{
|
479
|
"transactionContext": transactionContext,
|
479
|
"transactionContext": transactionContext,
|
480
|
})
|
480
|
})
|
|
|
481
|
+ //公司存储
|
|
|
482
|
+ companyRepo := factory.CreateCompanyRepository(map[string]interface{}{
|
|
|
483
|
+ "transactionContext": transactionContext,
|
|
|
484
|
+ })
|
|
|
485
|
+
|
|
|
486
|
+ companyInfo, _ := companyRepo.FindOne(map[string]interface{}{
|
|
|
487
|
+ "id": param.CompanyId,
|
|
|
488
|
+ })
|
481
|
|
489
|
|
482
|
limit := 20
|
490
|
limit := 20
|
483
|
if param.PageSize > 0 {
|
491
|
if param.PageSize > 0 {
|
|
@@ -502,6 +510,7 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
|
@@ -502,6 +510,7 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
502
|
if err != nil {
|
510
|
if err != nil {
|
503
|
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
|
511
|
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
|
504
|
}
|
512
|
}
|
|
|
513
|
+
|
505
|
//获取目标用户
|
514
|
//获取目标用户
|
506
|
userIds := []int{}
|
515
|
userIds := []int{}
|
507
|
for _, v := range assessList {
|
516
|
for _, v := range assessList {
|
|
@@ -556,10 +565,20 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
|
@@ -556,10 +565,20 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
556
|
if err != nil {
|
565
|
if err != nil {
|
557
|
return nil, application.ThrowError(application.TRANSACTION_ERROR, "获取个人的评估环节"+err.Error())
|
566
|
return nil, application.ThrowError(application.TRANSACTION_ERROR, "获取个人的评估环节"+err.Error())
|
558
|
}
|
567
|
}
|
|
|
568
|
+ var allAssessId []int
|
|
|
569
|
+ for _, v := range assessList {
|
|
|
570
|
+ allAssessId = append(allAssessId, v.Id)
|
|
|
571
|
+ }
|
|
|
572
|
+
|
|
|
573
|
+ assessValueMap := d.SearchContentValueByAssessId(allAssessId)
|
|
|
574
|
+
|
559
|
if err := transactionContext.CommitTransaction(); err != nil {
|
575
|
if err := transactionContext.CommitTransaction(); err != nil {
|
560
|
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
|
576
|
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
|
561
|
}
|
577
|
}
|
562
|
-
|
578
|
+ companyName := ""
|
|
|
579
|
+ if companyInfo != nil {
|
|
|
580
|
+ companyName = companyInfo.Name
|
|
|
581
|
+ }
|
563
|
resultList := []adapter.ListSupperAssessResp{}
|
582
|
resultList := []adapter.ListSupperAssessResp{}
|
564
|
for _, v := range assessList {
|
583
|
for _, v := range assessList {
|
565
|
item := adapter.ListSupperAssessResp{
|
584
|
item := adapter.ListSupperAssessResp{
|
|
@@ -575,7 +594,12 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
|
@@ -575,7 +594,12 @@ func (srv StaffAssessServeice) ListExecutorSupperAssessV2(param *query.ListExecu |
575
|
InviteTotal: 5,
|
594
|
InviteTotal: 5,
|
576
|
Department: "",
|
595
|
Department: "",
|
577
|
Position: "",
|
596
|
Position: "",
|
|
|
597
|
+ CompanyName: companyName,
|
578
|
DutyTime: "",
|
598
|
DutyTime: "",
|
|
|
599
|
+ ContentValue: []string{},
|
|
|
600
|
+ }
|
|
|
601
|
+ if values, ok := assessValueMap[v.Id]; ok {
|
|
|
602
|
+ item.ContentValue = values
|
579
|
}
|
603
|
}
|
580
|
//填入部门
|
604
|
//填入部门
|
581
|
for _, vv := range v.TargetDepartment {
|
605
|
for _, vv := range v.TargetDepartment {
|