修改搜索条件设置

This commit is contained in:
jhc 2023-06-13 16:55:25 +08:00
parent 4e23a6722c
commit adeae10479

View File

@ -592,16 +592,21 @@ func MyAllWorkApprovals(in *approval.ListRequest) ([]*Approval, int64) {
//我未阅读的和我未操作的
queryApproval := &Approval{NowUserId: in.UserID}
if in.ApprovalStatus == 0 && in.SubmitterName == "" { // 此处 为 阅读状态 表示 审批状态 默认为 StatusDoing
queryApproval.Status = StatusDoing
}
if in.ApprovalStatus <= StatusFail && in.ApprovalStatus > 0 { // 具体 的 审批状态
queryApproval.Status = int8(in.ApprovalStatus)
}
if in.SubmitterName != "" {
queryApproval.SubmitterName = in.SubmitterName
} else {
if in.ApprovalStatus == 0 {
queryApproval.Status = StatusDoing
}
}
//if in.ApprovalStatus == 0 && in.SubmitterName == "" { // 此处 为 阅读状态 表示 审批状态 默认为 StatusDoing
// queryApproval.Status = StatusDoing
//}
if in.ApprovalStatus <= StatusFail && in.ApprovalStatus > 0 { // 具体 的 审批状态
queryApproval.Status = int8(in.ApprovalStatus)
}
queryApprovalCopy := &ApprovalCopy{UserId: in.UserID}