作者 tangxvhui

暂存

... ... @@ -2,6 +2,7 @@ package adapter
import "gitlab.fjmaimaimai.com/allied-creation/performance/pkg/domain"
// 评估信息详情
type EvaluationInfoAdapter struct {
SummaryEvaluationId int `json:"summaryEvaluationId"` //
CycleId int `json:"cycleId,string"` //周期id
... ... @@ -32,6 +33,11 @@ type EvaluationItemAdapter struct {
Value string `json:"value"` //评估填写的评分
Score string `json:"score"` //计算的评定得分
Remark string `json:"remark"` //填写的内容反馈
LevelCount []LevalCodeCount `json:"levelCount"` //周期内每次评估的等级数量统计
//
//
}
type LevalCodeCount struct {
Code string `json:"code"`
Number int `json:"number"`
}
... ...
... ... @@ -504,3 +504,30 @@ func (srv *SummaryEvaluationService) GetTargetUserCycleList(param *command.Query
}
return tool_funs.SimpleWrapGridMap(int64(cnt), cycleList), nil
}
// 自评小结详情
func (srv *SummaryEvaluationService) CountEvaluationSelfLevel(param *command.QueryEvaluationInfo) (*adapter.EvaluationInfoAdapter, error) {
evaluationInfo, err := srv.GetEvaluationSelf(param)
if err != nil {
return nil, err
}
_ = evaluationInfo
//TODO 组装等级数量统计
transactionContext, err := factory.CreateTransactionContext(nil)
if err != nil {
return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error())
}
if err := transactionContext.StartTransaction(); err != nil {
return nil, application.ThrowError(application.TRANSACTION_ERROR, err.Error())
}
defer func() {
_ = transactionContext.RollbackTransaction()
}()
if err := transactionContext.CommitTransaction(); err != nil {
return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, err.Error())
}
return nil, nil
}
... ...