dubch 5 éve
szülő
commit
64ff85e2d8

+ 7 - 6
src/dashoo.cn/backend/api/business/oilsupplier/badrecord/badrecordservice.go

@@ -59,19 +59,20 @@ func (s *BadRecordService) GetMyPagingEntitiesWithOrderBytbl1(TableName, supTabl
 
 	//获取总记录数
 	sqlCount := `select count(*) from ` + TableName + ` a `
-	sqlCount += ` left join ` + supTableName + " b on (b.SupplierId = a.CompanyCode)"
+	//sqlCount += ` left join ` + supTableName + " b on (b.SupplierId = a.CompanyCode)"
 	sqlCount += ` where ` + where
-	sqlCount += ` AND b.CertSubStatus = '2' `
-	sqlCount += ` GROUP BY a.Id `
+	//sqlCount += ` AND b.CertSubStatus = '2' `
+	//sqlCount += ` GROUP BY a.Id `
 
 	var sql string
 	sql = `select a.Id, a.CompanyName, a.CompanyCode, a.CategoryName, a.CategoryCode, a.Record, a.Bak2, a.Bak3, 
 			a.Bak4, a.WZStatus, a.WZRecord, a.JJStatus, a.JJRecord, a.JFStatus, a.JFRecord, a.CertRecord
-			, a.Remark, a.CreateOn, a.CreateUserId, a.CreateBy,count(b.Id) as Bak1 `
+			, a.Remark, a.CreateOn, a.CreateUserId, a.CreateBy,(select count(*) from `
+	sql += supTableName + ` where CertSubStatus = '2' and SupplierId = a.CompanyCode) as Bak1 `
 	sql += ` from ` + TableName + ` a `
-	sql += ` left join ` + supTableName + " b on (b.SupplierId = a.CompanyCode)"
+	//sql += ` left join ` + supTableName + " b on (b.SupplierId = a.CompanyCode)"
 	sql += ` where ` + where
-	sql += ` AND b.CertSubStatus = '2' `
+	//sql += ` AND b.CertSubStatus = '2' `
 	sql += ` GROUP BY a.Id `
 	if asc {
 		sql += ` order by ` + orderby + ` ASC `

+ 15 - 15
src/dashoo.cn/backend/api/controllers/oilsupplier/supplierfile.go

@@ -6,9 +6,8 @@ import (
 	"dashoo.cn/business2/parameter"
 	"encoding/json"
 	"strconv"
-	"time"
-
 	"strings"
+	"time"
 
 	//"strings"
 
@@ -244,7 +243,7 @@ func (this *SupplierfileController) AddGeneral() {
 	json.Unmarshal(jsonblob, &model)
 	model.CreateBy = this.User.Realname
 	model.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
-	where := " IsManuf = '0' and CategoryCode = '" + model.SupplierTypeCode + "'"
+	where := " CategoryCode = '" + model.SupplierTypeCode + "'"
 	svc1.GetEntitysByWhere(BaseTableHeader, where, &model1)
 
 	var fileist supplierfile.OilSupplierFile
@@ -258,20 +257,21 @@ func (this *SupplierfileController) AddGeneral() {
 			paramSvc := baseparameter.GetBaseparameterService(utils.DBE)
 			//"营业执照,组织代码,组织机构代码证,税务登记证,税务登记,开户许可,银行开户许可证,承诺书,诚信合规承诺书,企业信息系统截图,战略合作协议扫描件,"
 			mustField := paramSvc.GetBaseparameterMessage("GFGL", "paramset", "MustFieldName")
-			if strings.Contains(mustField, value.Name + ",") {
+			if strings.Contains(mustField, value.Name + ",") && value.Name != "组织机构代码证" && value.Name != "税务登记证" {
 				model2.SupplierTypeCode = "000"
-			} else {
-				model2.SupplierTypeCode = model.SupplierTypeCode
+				model2.IsManuf = "0"
+				model2.SupplierId = model.SupplierId
+				model2.NeedFileType = value.Name
+				model2.FileName = ""
+				model2.SupType = 1
+				model2.CreateOn = time.Now()
+				model2.CreateBy = this.User.Realname
+				model2.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
+				svc.InsertEntityBytbl(OilSupplierFileName, &model2)
 			}
-			model2.IsManuf = "0"
-			model2.SupplierId = model.SupplierId
-			model2.NeedFileType = value.Name
-			model2.FileName = ""
-			model2.SupType = 1
-			model2.CreateOn = time.Now()
-			model2.CreateBy = this.User.Realname
-			model2.CreateUserId, _ = utils.StrTo(this.User.Id).Int()
-			svc.InsertEntityBytbl(OilSupplierFileName, &model2)
+			//else {
+			//	model2.SupplierTypeCode = model.SupplierTypeCode
+			//}
 		}
 		errinfo.Message = "操作成功!"
 		errinfo.Code = 0

+ 1 - 1
src/dashoo.cn/backend/api/controllers/oilsupplier/todolist.go

@@ -39,7 +39,7 @@ func (this *TodoListController) GetMyTaskEntityList() {
 	supplierTypeCode := this.GetString("SupplierTypeCode")
 	supplierName := this.GetString("SupplierName")
 	wfNames := ""
-	wfNames = workflow.OIL_ENUSER_SUPPLIER_APPLY  + "," + workflow.OIL_ENUSER_APPEND_APPLY + "," + workflow.OIL_INFO_CHANGE + "," + workflow.OIL_AUDIT_APPLY + "," + workflow.OIL_SUPPLIER_VERIFY+ "," + workflow.OIL_DAILY_CONTRACT_EVALUATION+ "," + workflow.OIL_ANNUAL_CONTRACT_EVALUATION+ "," + workflow.OIL_Catalog
+	wfNames = workflow.OIL_ENUSER_SUPPLIER_APPLY  + "," + workflow.OIL_ENUSER_APPEND_APPLY + "," + workflow.OIL_INFO_CHANGE + "," + workflow.OIL_AUDIT_APPLY + "," + workflow.OIL_SUPPLIER_VERIFY+ "," + workflow.OIL_DAILY_CONTRACT_EVALUATION+ "," + workflow.OIL_ANNUAL_CONTRACT_EVALUATION+ "," + workflow.OIL_Catalog+ "," + workflow.OIL_REGISTER_APPLY
 
 	var todoliststemp []todolist.TodoList
 

+ 3 - 1
src/dashoo.cn/frontend_web/src/pages/oilsupplier/paymentinfo/paymentsure.vue

@@ -272,7 +272,9 @@
         }
         Object.assign(params, this.searchForm)
         api.getBillList(params, this.$axios).then(res => {
-          this.formDataSup = res.data.SupplierEntity
+          if (res.data.SupplierEntity.CommercialNo !== '') {
+            this.formDataSup = res.data.SupplierEntity
+          }
           this.entityList = res.data.DataInfos[0].items
           this.entityList2 = res.data.DataInfos[1].items
           this.amount1 = res.data.AmountList[0]