|
|
@@ -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 + "'")
|
|
|
}
|