作者 陈志颖

fix:审核校验

@@ -178,7 +178,7 @@ func (cooperationApplicationService *CooperationApplicationService) ApplyForCoop @@ -178,7 +178,7 @@ func (cooperationApplicationService *CooperationApplicationService) ApplyForCoop
178 "cooperationProjectNumber": cooperationProject.CooperationProjectNumber, 178 "cooperationProjectNumber": cooperationProject.CooperationProjectNumber,
179 }) 179 })
180 if applicationExist { 180 if applicationExist {
181 - return nil, application.ThrowError(application.TRANSACTION_ERROR, "抱歉,您已经申请过该项目") 181 + return nil, application.ThrowError(application.TRANSACTION_ERROR, "当前项目申请已提交")
182 } 182 }
183 183
184 // 校验:判断用户类型是否属于承接对象 184 // 校验:判断用户类型是否属于承接对象
@@ -33,6 +33,8 @@ func (dao *CooperationApplicationDao) CheckApplicationExist(queryOptions map[str @@ -33,6 +33,8 @@ func (dao *CooperationApplicationDao) CheckApplicationExist(queryOptions map[str
33 if applicantBaseId, ok := queryOptions["applicantBaseId"]; ok && applicantBaseId.(int64) != 0 { 33 if applicantBaseId, ok := queryOptions["applicantBaseId"]; ok && applicantBaseId.(int64) != 0 {
34 query = query.Where(`cooperation_application.cooperation_application_applicant @>'{"userBaseId":"?"}'`, applicantBaseId) 34 query = query.Where(`cooperation_application.cooperation_application_applicant @>'{"userBaseId":"?"}'`, applicantBaseId)
35 } 35 }
  36 + query.Where("cooperation_application.cooperation_application_status <> 3")
  37 + query.Where("cooperation_application.is_canceled <> 2")
36 ok, err := query.Exists() 38 ok, err := query.Exists()
37 return ok, err 39 return ok, err
38 } 40 }