Browse Source

控制行数

Qukatie 6 months ago
parent
commit
c26a0c216b

+ 28 - 0
src/views/iosBasicData/SeafreightExportF/bills/assembly/DocumentCenter.vue

@@ -296,6 +296,8 @@ export default {
             loading: false,
             businesstypeData: {}, // 左侧选择的数据
             addShow: false,
+            mttachedGoodsdesc: 15,
+            mttachedMark: 15,
         }
     },
     props: {
@@ -320,6 +322,16 @@ export default {
                 this.textareaNumber = res.data.data
             }
         })
+        isProcurement({ "param": "ATTACHED_MARK" }).then(res => {
+            if (res.data.data) {
+                this.mttachedMark = res.data.data
+            }
+        })
+        isProcurement({ "param": " ATTACHED_GOODSDESC" }).then(res => {
+            if (res.data.data) {
+                this.mttachedGoodsdesc = res.data.data
+            }
+        })
         // this.reportsListfun()
     },
     methods: {
@@ -490,6 +502,22 @@ export default {
         },
         // 单证弹窗的确认按钮
         documentSubmit(type) {
+            this.documentForm.attachedMark = 0
+            this.documentForm.attachedGoodsdesc = 0
+            if (this.documentForm.marks) {
+                if (this.documentForm.marks.split('\n').length > this.mttachedMark) {
+                    this.documentForm.attachedMark = 1
+                } else {
+                    this.documentForm.attachedMark = 0
+                }
+            }
+            if (this.documentForm.commodityDescr) {
+                if (this.documentForm.commodityDescr.split('\n').length > this.mttachedMark) {
+                    this.documentForm.attachedGoodsdesc = 1
+                } else {
+                    this.documentForm.attachedGoodsdesc = 0
+                }
+            }
             let obj = {}
             if (this.editData.id) {
                 obj = this.editData