Jelajahi Sumber

前后:对比;

dubch 5 tahun lalu
induk
melakukan
be2f5d9eff

+ 1 - 1
src/dashoo.cn/backend/api/business/oilsupplier/goodsaptitude/oilgoodsaptitudeService.go

@@ -622,7 +622,7 @@ func (s *OilGoodsAptitudeService) GetTableTotal(where string, entitiesPtr interf
 
 func (s *OilGoodsAptitudeService) GetNoSubCntTotal(where string) (total int64) {
 
-	sqlCount := "select count(a.`Name`) as total from OilSupplierCertSub a left join tmp_OilGoodsAptitudeClass b on b.`Name` = a.`Name` where (" + where + ")"
+	sqlCount := "select count(a.`Code`) as total from OilSupplierCertSub a left join tmp_OilGoodsAptitudeClass b on b.`Code` = a.`Code` where (" + where + ")"
 
 	var totalResult TotalResult
 	s.DBE.SQL(sqlCount).Get(&totalResult)

+ 2 - 2
src/dashoo.cn/backend/api/controllers/oilsupplier/goodsaptitude.go

@@ -1707,7 +1707,7 @@ func (this *OilGoodsAptitudeController) CreateContrast() {
 			if list != nil {
 				var supplierCertSubList []suppliercertsub.OilSupplierCertSub
 				total := svc.GetTableTotal(" SupplierTypeCode = '01' AND SupplierId = "+strconv.Itoa(item.Id), &supplierCertSubList)
-				total1 := svc.GetNoSubCntTotal("a.SupplierTypeCode = '01' and b.`Name` is null and a.SupplierId = " + strconv.Itoa(item.Id))
+				total1 := svc.GetNoSubCntTotal("a.SupplierTypeCode = '01' and b.`Code` is null and a.SupplierId = " + strconv.Itoa(item.Id))
 				list[0].SubCnt = int(total)
 				//list[0].MinClassId = "0"
 				list[0].NoSubCnt = int(total1)
@@ -3036,7 +3036,7 @@ func (this *OilGoodsAptitudeController) DeleteUpdate() {
 				// 1降2修改
 				err = svc.UpdateEntityBywheretbl(OilSupplierCertSubName, &subDelete, cols, "SupplierTypeCode = '01' and Code = '" + item.Code + "'")
 			} else {
-				err = svc.UpdateEntityBywheretbl(OilSupplierCertSubName, &subDelete, cols, "SupplierTypeCode = '01' and GoodsLevel = '1' and Code = '" + item.Code + "'")
+				err = svc.UpdateEntityBywheretbl(OilSupplierCertSubName, &subDelete, cols, "SupplierTypeCode = '01' and (GoodsLevel = '1' or GoodsLevel is null) and Code = '" + item.Code + "'")
 				//2升1删除
 				err = svc.DeleteTable (OilSupplierCertSubName, "SupplierTypeCode = '01' and GoodsLevel = '2' and Code = '" + item.Code + "'")
 			}

+ 1 - 1
src/dashoo.cn/frontend_web/src/pages/oilsupplier/basisbuild/tmpsuppliercheck.vue

@@ -417,7 +417,7 @@
           _size: this.sizeSub
         }
         Object.assign(params, this.searchFormSub)
-        this.$axios.get('technologyservice/delcertsublist', {
+        this.$axios.get('basisbuild/delcertsublist', {
           params
         })
           .then(res => {