lanjianrong 4 سال پیش
والد
کامیت
7699f320f6
3فایلهای تغییر یافته به همراه6 افزوده شده و 6 حذف شده
  1. 1 1
      dao/approver_dao.go
  2. 1 1
      services/quality_audit.service.go
  3. 4 4
      services/safe_service.go

+ 1 - 1
dao/approver_dao.go

@@ -164,7 +164,7 @@ func (d *ApproverDao) ChangeNextStatus(id int, status int) error {
 // 根据当前times,获取审批流程(包括原报)
 func (d *ApproverDao) GetAuditorsWithOwner(bid int, dataType int, dataId int, cur_uid int) []viewmodels.Auditors {
 	auditors := make([]viewmodels.Auditors, 0)
-	auditor := viewmodels.Auditors{Progress: "", Id: "", Status: 2}
+	auditor := viewmodels.Auditors{Progress: "", Id: "0", Status: 2}
 
 	_, err := d.engine.Sql("select name, company, position, mobile, id as `audit_id` from `cm_project_account` where id = ?", cur_uid).Get(&auditor)
 

+ 1 - 1
services/quality_audit.service.go

@@ -103,7 +103,7 @@ func (s *qualityAuditService) StartAudit(qualityId int, bidsectionId int, audito
 		return err
 	}
 	// 创建审批流程
-	err = s.daoApprover.InsertData(uid, bidsectionId, pid, 1, qualityId, auditors, reAuditors)
+	err = s.daoApprover.InsertData(uid, bidsectionId, pid, 2, qualityId, auditors, reAuditors)
 	if err != nil {
 		return err
 	}

+ 4 - 4
services/safe_service.go

@@ -150,10 +150,10 @@ func (s *safeService) GetDetail(id int, pid int) viewmodels.SafeDetail {
 	encryptAuditors := make([]viewmodels.Auditors, 0)
 	for _, item := range auditors {
 		auditorVM := viewmodels.Auditors{}
-		if item.Id != "" {
-			id, _ := comm.AesEncrypt(item.Id, conf.SignSecret)
-			auditorVM.Id = id
-		}
+		// if item.Id != "" {
+		// }
+		id, _ := comm.AesEncrypt(item.Id, conf.SignSecret)
+		auditorVM.Id = id
 		auditId, _ := comm.AesEncrypt(item.AuditId, conf.SignSecret)
 		auditorVM.AuditId = auditId
 		auditorVM.Name = item.Name