切换导航条
此项目
正在载入...
登录
allied-creation
/
performance
·
提交
转到一个项目
GitLab
转到群组
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
差异文件
浏览文件
作者
tangxvhui
2 years ago
提交
22e2879f87b66104b10e23f658ff8fce2020b0bb
2 个父辈
cb31a93e
352f8d7f
Merge branch 'test' into dev-tangxvhui
显示空白字符变更
内嵌
并排对比
正在显示
7 个修改的文件
包含
16 行增加
和
0 行删除
pkg/application/staff_assess/service/service.go
pkg/application/staff_assess/service/service_3.go
pkg/domain/evaluation_template.go
pkg/domain/staff_assess_content.go
pkg/infrastructure/pg/models/staff_assess_content.go
pkg/infrastructure/repository/pg_staff_assess_content_repository.go
pkg/port/beego/controllers/import_controller.go
pkg/application/staff_assess/service/service.go
查看文件 @
22e2879
...
...
@@ -1072,6 +1072,7 @@ func (srv StaffAssessServeice) getAssessSelfInfoUncompleted(transactionContext a
ReteResult
:
""
,
CreatedAt
:
nowTime
,
Weight
:
v
.
Weight
,
Required
:
v
.
Required
,
UpdatedAt
:
nowTime
,
DeletedAt
:
nil
,
// Rule: ,
...
...
@@ -1725,11 +1726,13 @@ func (srv StaffAssessServeice) SaveAssessInfo(param *command.SaveAssessInfoComma
continue
}
v
.
Value
=
item
.
Value
if
v
.
Required
==
1
{
//转换填入的评估值
err
=
v
.
TransformValue
()
if
err
!=
nil
{
return
nil
,
application
.
ThrowError
(
application
.
BUSINESS_ERROR
,
err
.
Error
())
}
}
for
ii
:=
range
v
.
Remark
{
for
_
,
vvv
:=
range
item
.
Remark
{
if
v
.
Remark
[
ii
]
.
Title
==
vvv
.
Title
{
...
...
pkg/application/staff_assess/service/service_3.go
查看文件 @
22e2879
...
...
@@ -172,6 +172,7 @@ func (srv StaffAssessServeice) ListUserAssessContentCycleDay(param *query.ListAs
}
changeableRows
[
v
.
TargetUserId
][
"targetUserName"
]
=
v
.
TargetUserName
changeableRows
[
v
.
TargetUserId
][
"targetUserId"
]
=
v
.
TargetUserId
changeableRows
[
v
.
TargetUserId
][
"assessId"
]
=
v
.
AssessId
if
v
.
ContentId
>
0
{
name
:=
fmt
.
Sprintf
(
"%s-%s"
,
v
.
Category
,
v
.
ContentName
)
key
:=
fmt
.
Sprintf
(
"k%d"
,
i
)
...
...
pkg/domain/evaluation_template.go
查看文件 @
22e2879
...
...
@@ -19,6 +19,11 @@ const (
LinkNodeViewResult
int
=
5
// 环节-绩效结果查看
)
const
(
NodeRequiredYes
int
=
1
// 是否必填项-必填(默认)
NodeRequiredNo
int
=
2
// 是否必填项-非必填
)
type
EntryItem
struct
{
Title
string
`json:"title" comment:"填写标题"`
HintText
string
`json:"hintText" comment:"文本内容提示"`
...
...
@@ -35,6 +40,7 @@ type NodeContent struct {
PromptTitle
string
`json:"promptTitle" comment:"提示项标题"`
PromptText
string
`json:"promptText" comment:"提示项正文"`
EntryItems
[]
*
EntryItem
`json:"entryItems" comment:"填写项"`
Required
int
`json:"required" comment:"必填项"`
}
// LinkNode 评估流程、环节
...
...
pkg/domain/staff_assess_content.go
查看文件 @
22e2879
...
...
@@ -23,6 +23,7 @@ type StaffAssessContent struct {
ReteResult
string
`json:"reteResult"`
//评估的结果
Rule
EvaluationRule
`json:"rule"`
//评估的选项规则
Weight
float64
`json:"weight" `
//"权重"
Required
int
`json:"required"`
// 必填项
CreatedAt
time
.
Time
`json:"createdAt"`
//数据创建时间
UpdatedAt
time
.
Time
`json:"updatedAt"`
//数据更新时间
DeletedAt
*
time
.
Time
`json:"deletedAt"`
...
...
pkg/infrastructure/pg/models/staff_assess_content.go
查看文件 @
22e2879
...
...
@@ -23,6 +23,7 @@ type StaffAssessContent struct {
Rule
domain
.
EvaluationRule
Remark
[]
domain
.
AssessContemtRemark
Weight
float64
`pg:",use_zero"`
//权重
Required
int
//必填项
CreatedAt
time
.
Time
//数据创建时间
UpdatedAt
time
.
Time
//数据更新时间
DeletedAt
*
time
.
Time
...
...
pkg/infrastructure/repository/pg_staff_assess_content_repository.go
查看文件 @
22e2879
...
...
@@ -37,6 +37,7 @@ func (repo *StaffAssessContentRepository) TransformToDomain(d *models.StaffAsses
ReteResult
:
d
.
ReteResult
,
Rule
:
d
.
Rule
,
Weight
:
d
.
Weight
,
Required
:
d
.
Required
,
CreatedAt
:
d
.
CreatedAt
,
UpdatedAt
:
d
.
UpdatedAt
,
DeletedAt
:
nil
,
...
...
@@ -59,6 +60,7 @@ func (repo *StaffAssessContentRepository) Save(d *domain.StaffAssessContent) (*d
Rule
:
d
.
Rule
,
Remark
:
d
.
Remark
,
Weight
:
d
.
Weight
,
Required
:
d
.
Required
,
CreatedAt
:
d
.
CreatedAt
,
UpdatedAt
:
d
.
UpdatedAt
,
DeletedAt
:
nil
,
...
...
pkg/port/beego/controllers/import_controller.go
查看文件 @
22e2879
...
...
@@ -120,6 +120,8 @@ func (controller *ImportController) parseTemplateNodeContent(data []*domain.Perf
})
}
// 必填项
nc
.
Required
=
domain
.
NodeRequiredYes
nodeContents
=
append
(
nodeContents
,
nc
)
}
}
...
...
请
注册
或
登录
后发表评论