|
|
@@ -864,6 +864,7 @@ func (this *OilSupplierCertAppendController) SeparateUnitSubmitAuditEntity() {
|
|
|
// @router /separate-audit/:id [post]
|
|
|
func (this *OilSupplierCertAppendController) AppendSeparateAuditEntity() {
|
|
|
certAppendId := this.Ctx.Input.Param(":id")
|
|
|
+ Result := this.GetString("Result")
|
|
|
firstAudit := this.GetString("FirstAudit")
|
|
|
secondAudit := this.GetString("SecondAudit")
|
|
|
thirdAudit := this.GetString("ThirdAudit")
|
|
|
@@ -890,16 +891,18 @@ func (this *OilSupplierCertAppendController) AppendSeparateAuditEntity() {
|
|
|
certSrv := suppliercertappend.GetOilSupplierCertAppendService(utils.DBE)
|
|
|
var supplierCertAppendEntity suppliercertappend.OilSupplierCertAppend
|
|
|
certSrv.GetEntityById(certAppendId, &supplierCertAppendEntity)
|
|
|
- // 将选择的初审和复审人员保存下来
|
|
|
- cols := []string{
|
|
|
- "FirstAudit",
|
|
|
- "SecondAudit",
|
|
|
- "thirdAudit",
|
|
|
+ if Result == "1" {
|
|
|
+ // 将选择的初审和复审人员保存下来
|
|
|
+ cols := []string{
|
|
|
+ "FirstAudit",
|
|
|
+ "SecondAudit",
|
|
|
+ "thirdAudit",
|
|
|
+ }
|
|
|
+ supplierCertAppendEntity.FirstAudit, _ = strconv.Atoi(firstAudit)
|
|
|
+ supplierCertAppendEntity.SecondAudit, _ = strconv.Atoi(secondAudit)
|
|
|
+ supplierCertAppendEntity.ThirdAudit, _ = strconv.Atoi(thirdAudit) // 专业处室
|
|
|
+ certSrv.UpdateEntityByIdCols(certAppendId, supplierCertAppendEntity, cols)
|
|
|
}
|
|
|
- supplierCertAppendEntity.FirstAudit, _ = strconv.Atoi(firstAudit)
|
|
|
- supplierCertAppendEntity.SecondAudit, _ = strconv.Atoi(secondAudit)
|
|
|
- supplierCertAppendEntity.ThirdAudit, _ = strconv.Atoi(thirdAudit) // 专业处室
|
|
|
- certSrv.UpdateEntityByIdCols(certAppendId, supplierCertAppendEntity, cols)
|
|
|
|
|
|
svcActiviti := workflow.GetActivitiService(utils.DBE)
|
|
|
var ActiComplete workflow.ActiCompleteVM
|
|
|
@@ -907,7 +910,7 @@ func (this *OilSupplierCertAppendController) AppendSeparateAuditEntity() {
|
|
|
ActiComplete.BusinessKey = supplierCertAppendEntity.BusinessKey
|
|
|
ActiComplete.UserId = this.User.Id // 审批人员
|
|
|
// ActiComplete.UserNames = secondAudit // 初审人员
|
|
|
- ActiComplete.Result = "1" //分办完成后只向前走
|
|
|
+ ActiComplete.Result = Result //分办完成后只向前走
|
|
|
ActiComplete.Remarks = AuditRemark
|
|
|
ActiComplete.CallbackUrl = utils.Cfg.MustValue("workflow", "callbackHost")
|
|
|
receiveVal := svcActiviti.TaskComplete(ActiComplete)
|
|
|
@@ -966,6 +969,7 @@ func (this *OilSupplierCertAppendController) AppendCommonAuditEntity() {
|
|
|
// @router /business-separate-audit/:id [post]
|
|
|
func (this *OilSupplierCertAppendController) AppendBusinessOfficeSeparateAuditEntity() {
|
|
|
certAppendId := this.Ctx.Input.Param(":id")
|
|
|
+ Result := this.GetString("Result")
|
|
|
ProfessionalAudit := this.GetString("ProfessionalAudit")
|
|
|
AuditRemark := this.GetString("AuditRemark")
|
|
|
|
|
|
@@ -995,7 +999,7 @@ func (this *OilSupplierCertAppendController) AppendBusinessOfficeSeparateAuditEn
|
|
|
ActiComplete.ProcessKey = workflow.OIL_ENUSER_APPEND_APPLY
|
|
|
ActiComplete.BusinessKey = supplierCertAppendEntity.BusinessKey
|
|
|
ActiComplete.UserId = this.User.Id //审批人员
|
|
|
- ActiComplete.Result = "1" //前台审批[同意、不同意]
|
|
|
+ ActiComplete.Result = Result //前台审批[同意、不同意]
|
|
|
ActiComplete.UserNames = ProfessionalAudit // 直接分配业务处室专业审批人
|
|
|
ActiComplete.Remarks = AuditRemark
|
|
|
ActiComplete.CallbackUrl = utils.Cfg.MustValue("workflow", "callbackHost")
|
|
|
@@ -1003,15 +1007,17 @@ func (this *OilSupplierCertAppendController) AppendBusinessOfficeSeparateAuditEn
|
|
|
if receiveVal != "true" {
|
|
|
panic("工作流异常,请联系管理员!" + receiveVal)
|
|
|
}
|
|
|
- cols := []string{
|
|
|
- "Id",
|
|
|
- "Status",
|
|
|
- "ProfessionalAudit",
|
|
|
+ if Result == "1" {
|
|
|
+ cols := []string{
|
|
|
+ "Id",
|
|
|
+ "Status",
|
|
|
+ "ProfessionalAudit",
|
|
|
+ }
|
|
|
+ supplierCertAppendId := strings.Split(supplierCertAppendEntity.BusinessKey, "-")[0]
|
|
|
+ supplierCertAppendEntity.Status = suppliercert.PROF_AUDIT_STATUS //专业处室接收
|
|
|
+ supplierCertAppendEntity.ProfessionalAudit, _ = strconv.Atoi(ProfessionalAudit)
|
|
|
+ certSrv.UpdateEntityByIdCols(supplierCertAppendId, supplierCertAppendEntity, cols)
|
|
|
}
|
|
|
- supplierCertAppendId := strings.Split(supplierCertAppendEntity.BusinessKey, "-")[0]
|
|
|
- supplierCertAppendEntity.Status = suppliercert.PROF_AUDIT_STATUS //专业处室接收
|
|
|
- supplierCertAppendEntity.ProfessionalAudit, _ = strconv.Atoi(ProfessionalAudit)
|
|
|
- certSrv.UpdateEntityByIdCols(supplierCertAppendId, supplierCertAppendEntity, cols)
|
|
|
}
|
|
|
|
|
|
// @Title 集中审批
|