瀏覽代碼

资质选择

lining 5 年之前
父節點
當前提交
f46b580e1c

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

@@ -422,7 +422,7 @@ func (this *OilSupplierCertSubController) AddGoodsBus() {
 			}
 
 			var Havelist []supplierfile.OilSupplierFile // 已经有的资质
-			where := "SupplierTypeCode in (01,000) and IsManuf in ('0','2', '') and SupplierId = '" + strconv.Itoa(dataother.SupplierId) + "'"
+			where := "SupplierTypeCode in (01,000) and IsManuf in ('0','"+ strconv.Itoa(datamain.IsManufacturer) +"', '') and SupplierId = '" + strconv.Itoa(dataother.SupplierId) + "'"
 			svc.GetEntitysByWhere(OilSupplierFileName, where, &Havelist)
 
 			//三证合一或五证合一不需要的字段

+ 16 - 8
src/dashoo.cn/frontend_web/src/components/oilsupplier/subfilelist.vue

@@ -215,11 +215,12 @@
         SubClassIds: [],
         SupplierCertId: 0,
         InStyle: '1',
-        IsMust:false,
+        IsMust: false,
         businessList: [],
         subfileList: [],
         techList: [],
         techTreeList: [],
+        fileList: [],
         orgtreeprops: {
           value: 'id',
           label: 'Name',
@@ -559,7 +560,10 @@
         this.SubfileForm.FileName = val.FileName
         this.SubfileForm.EffectDate = (this.jsEffectDate(val.EffectDate))
         this.SubfileForm.FileUrl = val.FileUrl
-        this.getwendanginfo(val.FileUrl)
+        console.log(val.FileUrl, 'val.FileUrl')
+        if (val.FileUrl !== '') {
+          this.getwendanginfo(val.FileUrl)
+        }
         this.SubfileForm.OtherRemark = val.OtherRemark
         this.SubfileForm.Remark = val.Remark
         this.SubfileForm.IsDelete = val.IsDelete
@@ -569,12 +573,16 @@
       getwendanginfo (iUrl) {
         let _this = this
         _this.doclist = []
-        let exArr = iUrl.split('|')
-        let params = {
-          name: exArr[1],
-          url: exArr[0]
+        let urlArr = iUrl.split('$')
+        for (let idx in urlArr) {
+          let exArr = urlArr[idx].split('|')
+          console.log(exArr, 'exArr')
+          let params = {
+            name: exArr[1],
+            url: exArr[0]
+          }
+          _this.doclist.push(params)
         }
-        _this.doclist.push(params)
       },
 
       beforeAvatarUpload (file) {
@@ -604,7 +612,7 @@
                 } else {
                   option.action = `http://${res.data.publicUrl}/${res.data.fid}`
                 }
-
+                console.log(option.action, 'option.action')
                 _this.waituploads.push({
                   uid: option.file.uid,
                   url: res.data.publicUrl,