切换导航条
此项目
正在载入...
登录
allied-creation
/
performance
·
提交
转到一个项目
GitLab
转到群组
项目
活动
文件
提交
管道
0
构建
0
图表
里程碑
问题
0
合并请求
0
成员
标记
维基
派生
网络
创建新的问题
下载为
邮件补丁
差异文件
浏览文件
作者
tangxvhui
2 years ago
提交
f2141246ceb4436bb7236d4bfadc2cd702f6fcc3
1 个父辈
9b026617
修复一些问题
显示空白字符变更
内嵌
并排对比
正在显示
1 个修改的文件
包含
5 行增加
和
5 行删除
pkg/infrastructure/repository/pg_staff_assess_repository.go
pkg/infrastructure/repository/pg_staff_assess_repository.go
查看文件 @
f214124
...
...
@@ -127,18 +127,18 @@ func (repo *StaffAssessRepository) Find(queryOptions map[string]interface{}) (in
if
v
,
ok
:=
queryOptions
[
"offset"
]
.
(
int
);
ok
{
query
.
Offset
(
v
)
}
if
v
,
ok
:=
queryOptions
[
"targetUserId"
]
.
(
int
);
ok
&&
v
>
0
{
if
v
,
ok
:=
queryOptions
[
"targetUserId"
]
;
ok
{
query
.
Where
(
`target_user->>'userId'='?'`
,
v
)
}
if
v
,
ok
:=
queryOptions
[
"targetUserName"
]
.
(
int
);
ok
&&
v
>
0
{
if
v
,
ok
:=
queryOptions
[
"targetUserName"
]
.
(
string
);
ok
{
query
.
Where
(
`target_user->>'userName' like ?`
,
fmt
.
Sprintf
(
"%%%v%%"
,
v
))
}
if
v
,
ok
:=
queryOptions
[
"executorId"
]
.
(
int
);
ok
&&
v
>
0
{
if
v
,
ok
:=
queryOptions
[
"executorId"
]
;
ok
{
query
.
Where
(
`executor->>'userId'='?'`
,
v
)
}
if
v
,
ok
:=
queryOptions
[
"cycleId"
]
.
(
int64
);
ok
&&
v
>
0
{
if
v
,
ok
:=
queryOptions
[
"cycleId"
]
;
ok
{
query
.
Where
(
`cycle_id=?`
,
v
)
}
if
v
,
ok
:=
queryOptions
[
"staffAssessTaskId"
];
ok
{
...
...
@@ -151,7 +151,7 @@ func (repo *StaffAssessRepository) Find(queryOptions map[string]interface{}) (in
if
v
,
ok
:=
queryOptions
[
"typesList"
]
.
([]
string
);
ok
{
query
.
Where
(
"types in(?)"
,
pg
.
In
(
v
))
}
if
v
,
ok
:=
queryOptions
[
"status"
]
.
(
string
)
;
ok
{
if
v
,
ok
:=
queryOptions
[
"status"
];
ok
{
query
.
Where
(
"status=?"
,
v
)
}
if
v
,
ok
:=
queryOptions
[
"endTime"
];
ok
{
...
...
请
注册
或
登录
后发表评论