Преглед изворни кода

1.OW放 封装放箱号弹窗组件 需要给其他字段赋值
2.箱池动态 导入数据去掉箱号校验功能
3.决策分析 业务利润 去掉核算部门
4.封装锁单公共方法 暂时还没引用
5.结算中心 合计解决浮点数问题
6.箱池动态 联调进场导入 出场导入接口
7.客户托书 预订舱 新加报表功能
8.审核列表 新加字段并检索
9.海运出口 订舱日期修改占位文本 并加上默认值
10.提取成本 新加承运人字段
11.决策分析 新加字段
12.费用申请 审批后 返回的页面不对
13.费用模板 单价可以为0

Qukatie пре 6 месеци
родитељ
комит
b73b44b682

+ 498 - 0
src/components/dicSelect/containerNumber.vue

@@ -0,0 +1,498 @@
+<template>
+    <!-- 中文下拉 -->
+    <div>
+        <div style="display: flex;"  @click="open()">
+            <el-input v-model="value" @input="inputChange" :placeholder="'请选择 ' + placeholder" :disabled="disabled" :size="size" readonly></el-input>
+        </div>
+        <el-dialog :title="titleDialog" :visible.sync="dialogVisible" width="70%" :before-close="false" @closed="closed"
+            append-to-body>
+            <span>
+                <avue-crud v-if="dialogVisible" :option="option" :table-loading="loading" :data="dataList"
+                    :search.sync="query" v-model="form" id="out-table" ref="crud" @row-del="rowDel"
+                    @search-change="searchChange" @search-reset="searchReset" @selection-change="selectionChange"
+                    @on-load="onLoad">
+                </avue-crud>
+            </span>
+            <span slot="footer" class="dialog-footer">
+                <el-button size="small" @click="dialogVisible = false">取 消</el-button>
+                <el-button size="small" type="primary" :disabled="this.selectionList.length != 1" @click="importData">确
+                    定</el-button>
+            </span>
+        </el-dialog>
+    </div>
+</template>
+
+<script>
+import { getDicinit } from "@/api/dicSelect/index";
+import { bcorpstypedefineList } from "@/api/iosBasicData/bcorpstypedefine"
+export default {
+    data() {
+        return {
+            dialogVisible: false,
+            options: [],
+            loading: false,
+            data: {},
+            form: {},
+            query: {},
+            page: {
+                pageSize: 10,
+                currentPage: 1,
+                total: 0
+            },
+            dataList: [],
+            selectionList: [],
+            option: {
+                height: 400,
+                calcHeight: 30,
+                tip: false,
+                searchIcon: true,
+                searchIndex: 3,
+                searchShow: true,
+                searchMenuSpan: 18,
+                border: true,
+                index: true,
+                selection: true,
+                header: false,
+                menu: false,
+                column: [
+                   {
+                        label: "放箱号",
+                        prop: "containerNumber",
+                        width: 100,
+                        overHidden: true,
+                        search:true,
+                    },
+                    {
+                        label: "放箱号类型",
+                        prop: "busType",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "场站",
+                        prop: "polStationCname",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "箱型",
+                        prop: "boxType",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "可用箱数",
+                        prop: "remainingNum",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "占用箱量",
+                        prop: "occupyNum",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "优先等级",
+                        prop: "priorityLevel",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "箱管备注",
+                        prop: "boxRemarks",
+                        width: 100,
+                        overHidden: true,
+                    },
+                    {
+                        label: "备注",
+                        prop: "remarks",
+                        width: 100,
+                        overHidden: true,
+                    }
+                ],
+                designer: null,
+            },
+            treeOption: {
+                nodeKey: "id",
+                lazy: true,
+                treeLoad: function (node, resolve) {
+                    const parentId = node.level === 0 ? 0 : node.data.id;
+                },
+                addBtn: false,
+                menu: false,
+                size: "small",
+                props: {
+                    labelText: "标题",
+                    label: "cnName",
+                    value: "id",
+                    children: "children"
+                }
+            },
+            treeData: [],
+            selectWidth: 0,
+            obtained: true,
+        }
+    },
+    props: {
+        activateCreated: {
+            type: Boolean,
+            default: true
+        },
+        slotRight: {
+            type: Boolean,
+            default: false
+        },
+        diySlot: {
+            type: Boolean,
+            default: false
+        },
+        key: {
+            type: [String, Number],
+            default: null
+        },
+        label: {
+            type: String,
+            default: ''
+        },
+        rightLabel: {
+            type: String,
+            default: ''
+        },
+        keyValue: {
+            type: [String, Number],
+            default: null
+        },
+        res: {
+            type: String,
+            default: ''
+        },
+        placeholder: {
+            type: String,
+            default: '请输入'
+        },
+        clearable: {
+            type: Boolean,
+            default: true
+        },
+        value: {
+            type: [String, Number],
+            default: ''
+        },
+        method: {
+            type: String,
+            default: 'GET'
+        },
+        url: {
+            type: String,
+            default: ''
+        },
+        dataName: {
+            type: String,
+            default: ''
+        },
+        multiple: {
+            type: Boolean,
+            default: false
+        },
+        filterable: {
+            type: Boolean,
+            default: false
+        },
+        remote: {
+            type: Boolean,
+            default: false
+        },
+        size: {
+            type: String,
+            default: 'small'
+        },
+        disabled: {
+            type: Boolean,
+            default: false
+        },
+        searchShow: {
+            type: Boolean,
+            default: false
+        },
+        treeShow: {
+            type: Boolean,
+            default: false
+        },
+        mockData: {
+            type: Array,
+            default: function () {
+                return [];
+            }
+        },
+        collapseTags: {
+            type: Boolean,
+            default: false
+        },
+        default: {
+            type: Boolean,
+            default: false
+        },
+        defaultValue: {
+            type: String,
+            default: ''
+        },
+        disabledLabel: {
+            type: String,
+            default: ''
+        },
+        dataType: {
+            type: String,
+            default: ''
+        },
+        titleDialog: {
+            type: String,
+            default: '客户'
+        },
+        multipleStrings: {
+            type: Boolean,
+            default: false
+        },
+        type: {
+            type: String,
+            default: 'select'
+        },
+    },
+    model: {
+        prop: "value",
+        event: "selectedValue"
+    },
+    created() {
+    },
+    mounted() {
+        if (this.activateCreated) {
+            // this.getDicData()
+        } else {
+            this.options = this.mockData
+        }
+        if (this.diySlot) {
+            this.$nextTick(() => {
+                this.selectWidth = this.$refs.mySelect.$el.offsetWidth;
+                this.$refs.mySelect.$el.querySelector('.el-select-dropdown').style.width = `${this.selectWidth}px`;
+            });
+        }
+    },
+    watch: {
+        value: {
+            handler(val, oldVal) {
+                if (this.dataType == 'string') {
+                    if (val) {
+                        if (typeof val == 'string') {
+                            this.value = val.split(',')
+                        }
+                    } else {
+                        this.value = []
+                    }
+                }
+            },
+            deep: true,
+            immediate: true
+        }
+    },
+    methods: {
+        visibleChange(status) {
+            if (status) {
+                if (this.options.length == 0) {
+                    this.data = {}
+                    this.getDicData()
+                }
+
+            }
+        },
+        inputChange() {
+            if (this.dataType == 'string') {
+                if (this.value && this.value.length) {
+                    this.$emit('selectedValue', this.value.join(','))
+                } else {
+                    this.$emit('selectedValue', [])
+                }
+            } else {
+                this.$emit('selectedValue', this.value)
+            }
+
+        },
+        open() {
+            this.selectionList=[]
+            this.dialogVisible = true
+            this.getTree()
+        },
+        // 获取客户类别
+        getTree() {
+            bcorpstypedefineList(1, 50).then(res => {
+                this.treeData = res.data.data.records
+            })
+        },
+        nodeClick(data) {
+            this.query.corpTypeName = data.cnName
+            this.onLoad(this.page, this.query);
+        },
+        closed() {
+            this.query = {}
+            this.selectionList = []
+        },
+        remoteMethod(query) {
+            if (query !== '') {
+                setTimeout(() => {
+                    this.data[this.dataName] = query
+                    this.getDicData()
+                }, 200);
+            } else {
+                setTimeout(() => {
+                    this.data = this.$options.data().data
+                    this.getDicData()
+                }, 200);
+            }
+        },
+        getDicData() {
+            if (this.url) {
+                this.loading = true
+                getDicinit(this.method, this.url, this.data).then(res => {
+                    if (this.res) {
+                        res.data.data[this.res].forEach(e => {
+                            if (this.disabledLabel.split(",").some(item => item == e[this.label])) {
+                                e.disabled = true
+                            }
+                        })
+                        this.options = res.data.data[this.res]
+                    } else {
+                        res.data.data.forEach(e => {
+                            if (this.disabledLabel.split(",").some(item => item == e[this.label])) {
+                                e.disabled = true
+                            }
+                        })
+                        this.options = res.data.data
+                    }
+                }).finally(() => {
+                    this.loading = false;
+                })
+            } else {
+                this.options = this.mockData
+            }
+
+        },
+        IdGetDicData(data) {
+            this.loading = true
+            getDicinit(this.method, this.url, data).then(res => {
+                if (this.res) {
+                    this.options = res.data.data[this.res]
+                } else {
+                    this.options = res.data.data
+                }
+            }).finally(() => {
+                this.loading = false;
+            })
+        },
+        selectChange(row) {
+            if (this.dataType == 'string') {
+                let data = []
+                let ids = []
+                let multipleData = []
+                this.options.forEach(e => {
+                    if (row.length) {
+                        if (this.keyValue) {
+                            row.forEach(item => {
+                                if (item == e[this.keyValue]) {
+                                    data.push(e[this.label])
+                                    this.$emit('selectChange', data.join(','))
+                                }
+                            })
+
+                        }
+                        if (this.label) {
+                            row.forEach(item => {
+                                if (item == e[this.label]) {
+                                    ids.push(e.id)
+                                    data.push(e[this.label])
+                                    if (this.multipleStrings) {
+                                        multipleData.push(e)
+                                        this.$emit('selectChange', {
+                                            ids: ids.join(','),
+                                            names: data.join(','),
+                                            multipleData: multipleData
+                                        })
+                                    } else {
+                                        this.$emit('selectChange', {
+                                            ids: ids.join(','),
+                                            names: data.join(','),
+                                        })
+                                    }
+
+                                }
+
+                            })
+                        }
+                    } else {
+                        this.$emit('selectChange', null)
+                    }
+
+                })
+            } else {
+                this.options.forEach(e => {
+                    if (this.keyValue) {
+                        if (row == e[this.keyValue]) {
+                            this.$emit('selectChange', e)
+                        }
+                    }
+                    if (this.label) {
+                        if (row == e[this.label]) {
+                            this.$emit('selectChange', e)
+                        }
+                    }
+                })
+            }
+
+        },
+        clear() {
+            if (this.url) {
+                this.data = this.$options.data().data
+                this.getDicData()
+            }
+            this.$emit('selectChange', null)
+        },
+        importData() {
+            this.dialogVisible = false
+            this.$emit('selectChange', this.selectionList[0])
+        },
+        searchChange(params, done) {
+            this.page.currentPage = 1;
+            this.onLoad(this.page, this.query);
+            done();
+        },
+        selectionChange(list) {
+            this.selectionList = list;
+        },
+        currentChange(currentPage) {
+            this.page.currentPage = currentPage;
+        },
+        sizeChange(pageSize) {
+            this.page.pageSize = pageSize;
+        },
+        refreshChange() {
+            this.onLoad(this.page, this.query);
+        },
+        onLoad(page, params = {}) {
+            let obj = {}
+            obj = {
+                ...Object.assign(params, this.query),
+            }
+            this.loading = true
+            getDicinit(this.method, this.url, obj).then(res => {
+                this.dataList = res.data.data
+            }).finally(() => {
+                this.loading = false;
+            })
+        },
+    }
+}
+</script>
+
+<style lang="scss" scoped>
+/deep/ .el-col-md-8 {
+    width: 24.33333%;
+}
+</style>

+ 6 - 0
src/components/extractionCost/main.vue

@@ -114,6 +114,12 @@ export default {
                         width:140,
                         overHidden: true,
                     },
+                         {
+                        label: '承运人',
+                        prop: 'shippingCompanyCname',
+                        width:140,
+                        overHidden: true,
+                    },
                     {
                         label: '运输条款',
                         prop: 'transportationTerms',

+ 18 - 3
src/views/approveDataH/configuration/mainList.json

@@ -49,7 +49,6 @@
       "hide": true,
       "showColumn": false,
       "index": 1
-      
     },
     {
       "label": "业务类型",
@@ -120,7 +119,23 @@
       "search": true,
       "overHidden": true,
       "width": 100,
-      "index":7
+      "index": 7
+    },
+    {
+      "label": "MB/L NO",
+      "prop": "mblno",
+      "search": true,
+      "overHidden": true,
+      "width": 100,
+      "index": 7.1
+    },
+    {
+      "label": "HB/L NO",
+      "prop": "hblno",
+      "search": true,
+      "overHidden": true,
+      "width": 100,
+      "index": 7.2
     },
     {
       "label": "参考号",
@@ -194,7 +209,7 @@
       "type": "date",
       "format": "yyyy-MM-dd",
       "valueFormat": "yyyy-MM-dd HH:mm:ss",
-        "searchDefaultTime": [
+      "searchDefaultTime": [
         "00:00:00",
         "23:59:59"
       ],

+ 3 - 0
src/views/boxManagement/agentBox/detailsPage.vue

@@ -2202,6 +2202,9 @@ export default {
       }
       if (name == '费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 3 - 0
src/views/boxManagement/boxAdjustment/detailsPage.vue

@@ -1901,6 +1901,9 @@ export default {
       }
       if (name == '费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 9 - 7
src/views/boxManagement/boxCost/detailsPage.vue

@@ -67,8 +67,7 @@
                 <el-button type="danger" plain size="small"
                   :disabled="editDisabled || selectionList.length == 0 || form.buxStaus == '已确认'"
                   @click="allClick('批量删除')">批量删除</el-button>
-                <el-button type="success" size="small" @click="allClick('导入')"
-                  :disabled="!form.id">导入</el-button>
+                <el-button type="success" size="small" @click="allClick('导入')" :disabled="!form.id">导入</el-button>
                 <!-- <el-button type="info" size="small" @click="allClick('启用')"
                   :disabled="selectionList.length == 0">启用</el-button> -->
                 <!-- <el-button type="primary" size="small" @click="allClick('卖箱')">卖箱</el-button> -->
@@ -175,8 +174,8 @@
                 <!-- <el-button type="primary" plain size="small" @click="$refs.printC.openDialog()">打印账单</el-button> -->
               </template>
               <template slot="indexHeader" slot-scope="{row,index}">
-                <el-button type="primary" size="mini" icon="el-icon-plus"
-                  :disabled="form.buxStaus == '已确认'" circle @click="feedAddRow()">
+                <el-button type="primary" size="mini" icon="el-icon-plus" :disabled="form.buxStaus == '已确认'" circle
+                  @click="feedAddRow()">
                 </el-button>
               </template>
               <template slot="index" slot-scope="{row,index}">
@@ -270,8 +269,8 @@
                 <!-- <el-button type="primary" plain size="small" @click="$refs.printC.openDialog()">打印账单</el-button> -->
               </template>
               <template slot="indexHeader" slot-scope="{row,index}">
-                <el-button type="primary" size="mini" icon="el-icon-plus"
-                  :disabled="form.buxStaus == '已确认'" circle @click="feecAddRow()">
+                <el-button type="primary" size="mini" icon="el-icon-plus" :disabled="form.buxStaus == '已确认'" circle
+                  @click="feecAddRow()">
                 </el-button>
               </template>
               <template slot="index" slot-scope="{row,index}">
@@ -2465,6 +2464,9 @@ export default {
       if (name == 'D费用申请') {
         let selecList = [...this.selectionfeedList, ...this.selectionfeecList]
         for (let row of selecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }
@@ -2711,7 +2713,7 @@ export default {
     goBack(type) {
       this.$emit("goBack");
     },
-     getSum() {
+    getSum() {
       let sumArr = []
       let corpArr = []
       let newArr = []

+ 3 - 0
src/views/boxManagement/boxExit/detailsPage.vue

@@ -1938,6 +1938,9 @@ export default {
       }
       if (name == '费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 4 - 1
src/views/boxManagement/buyContainer/detailsPage.vue

@@ -1193,7 +1193,7 @@ export default {
     this.saveLocalCurrency(this.deptId)
   },
   methods: {
-      verifyChange(name, row) {
+    verifyChange(name, row) {
       if (row[name]) {
         getAccurate({ accurate: row[name] }).then(res => {
           if (res.data.data.records.length == 0) {
@@ -1861,6 +1861,9 @@ export default {
       }
       if (name == '费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 4 - 1
src/views/boxManagement/rentalBox/detailsPage.vue

@@ -1421,7 +1421,7 @@ export default {
     this.saveLocalCurrency(this.deptId)
   },
   methods: {
-   verifyChange(name, row) {
+    verifyChange(name, row) {
       if (row[name]) {
         getAccurate({ accurate: row[name] }).then(res => {
           if (res.data.data.records.length == 0) {
@@ -2453,6 +2453,9 @@ export default {
       }
       if (name == '费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 2 - 2
src/views/iosBasicData/ComputationCenter/index.vue

@@ -32,10 +32,10 @@
                     </el-button>
                     <span style="font-size: 24px;font-weight: 600;">
                         <span style="color: #67C23A;margin-right: 10px;">
-                            本币:{{ amountSubSum }}元
+                            本币:{{ amountSubSum.toFixed(2) }}元
                         </span>
                         <span style="color: #E6A23C;">
-                            外币:{{ amountSubUsdSum }}元
+                            外币:{{ amountSubUsdSum.toFixed(2) }}元
                         </span>
                     </span>
                 </template>

+ 6 - 0
src/views/iosBasicData/OceanFreightImport/bills/assembly/feecenter.vue

@@ -3105,6 +3105,9 @@ export default {
             if (name == 'D费用申请') {
                 // let selecList = [...this.selectionDList, ...this.selectionCList]
                 for (let row of this.selectionDList) {
+                    if (!row.id) {
+                        return this.$message.error("请保存费用明细");
+                    }
                     if (row.stlPid && row.accStatus != 0) {
                         return this.$message.error("已生成账单,不允许重复申请");
                     }
@@ -3151,6 +3154,9 @@ export default {
             if (name == 'C费用申请') {
                 // let selecList = [...this.selectionDList, ...this.selectionCList]
                 for (let row of this.selectionCList) {
+                    if (!row.id) {
+                        return this.$message.error("请保存费用明细");
+                    }
                     if (row.stlPid && row.accStatus != 0) {
                         return this.$message.error("已生成账单,不允许重复申请");
                     }

+ 6 - 0
src/views/iosBasicData/SeafreightExportF/bills/assembly/feecenter.vue

@@ -3071,6 +3071,9 @@ export default {
                     return
                 }
                 for (let row of this.selectionDList) {
+                    if (!row.id) {
+                        return this.$message.error("请保存费用明细");
+                    }
                     if (row.stlPid && row.accStatus != 0) {
                         return this.$message.error("已生成账单,不允许重复申请");
                     }
@@ -3117,6 +3120,9 @@ export default {
                 }
                 // let selecList = [...this.selectionDList, ...this.selectionCList]
                 for (let row of this.selectionCList) {
+                    if (!row.id) {
+                        return this.$message.error("请保存费用明细");
+                    }
                     if (row.stlPid && row.accStatus != 0) {
                         return this.$message.error("已生成账单,不允许重复申请");
                     }

+ 112 - 4
src/views/iosBasicData/businessCenter/customerLetter/detailsPage.vue

@@ -7,9 +7,9 @@
         </el-button>
       </div>
       <div class="add-customer-btn">
-        <el-button size="small" style="margin-right: 8px" :disabled="!form.id" @click="$refs.print.openDialog()">预 览
+        <el-button size="small"  :disabled="!form.id" @click="$refs.print.openDialog()">预 览
         </el-button>
-        <el-button v-if="roleName.indexOf('admin') != -1" size="small" style="margin-right: 8px" :disabled="!form.id"
+        <el-button v-if="roleName.indexOf('admin') != -1" size="small"  :disabled="!form.id"
           @click="$refs.report.openDialog()">报表设计
         </el-button>
         <!--        <el-button class="el-button&#45;&#45;small-yh" style="margin-left: 6px;" type="danger" size="small"
@@ -28,9 +28,20 @@
         <el-button v-if="form.id" class="el-button--small-yh" style="margin-left: 6px;" type="success" size="small"
           :disabled="form.status != 0 || form.issueStatus == 1" @click="application">运费申请
         </el-button>
-        <el-button v-if="form.status == 1" class="el-button--small-yh" style="margin-left: 6px;" type="danger"
+        <el-button v-if="form.status == 1"  class="el-button--small-yh" style="margin-left: 6px;" type="danger"
           size="small" @click="revokeApplication">撤销单据请核
         </el-button>
+        <el-dropdown style="line-height: 0" v-if="importTemplate == 1">
+          <el-button size="small" type="warning" style="margin-left: 8px"
+            :disabled="form.status > 0 || showLock || !form.id">
+            导入模板<i class="el-icon-arrow-down el-icon--right"></i>
+          </el-button>
+          <el-dropdown-menu slot="dropdown">
+            <el-dropdown-item v-for="item in imporiData" :key="item.id" @click.native="importData2(item.id)">{{
+              item.name }}
+            </el-dropdown-item>
+          </el-dropdown-menu>
+        </el-dropdown>
         <el-dropdown style="line-height: 0">
           <el-button class="el-button--small-yh" style="margin-left: 6px;" type="warning" :disabled="!form.id"
             size="small">
@@ -388,6 +399,13 @@
       <check-schedule :checkId="checkId" :batchNo="batchNo" @choceScheduleFun="choceScheduleFun"></check-schedule>
     </el-dialog>
     <freight-rate ref="freightRate" @importData="importData" />
+    <!--导入模板-->
+    <el-dialog title="导入模板" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false"
+      v-dialog-drag>
+      <avue-form v-if="excelBox" :option="excelOption" v-model="excelForm" :upload-before="uploadBefore"
+        :upload-after="onSuccess">
+      </avue-form>
+    </el-dialog>
   </div>
 </template>
 
@@ -405,10 +423,41 @@ import { getDicinit } from "@/api/dicSelect/index";
 import _ from "lodash";
 import { Header } from "element-ui";
 import { dateFormat } from "@/util/date";
+import { isProcurement } from "@/api/basicData/configuration";
 export default {
   name: "detailsPage",
   data() {
     return {
+      excelForm: {},
+      excelLoading: false,
+      excelOption: {
+        submitBtn: false,
+        emptyBtn: false,
+        column: [
+          {
+            label: "模板上传",
+            prop: "excelFile",
+            type: "upload",
+            drag: true,
+            loadText: "模板上传中,请稍等",
+            span: 24,
+            propsHttp: {
+              res: "data"
+            },
+            tip: "请上传 .xls,.xlsx 标准格式文件",
+            action: "api/blade-los/templateImport/importOne"
+          }
+        ]
+      },
+      excelBox: false,
+      imporiData: [
+        // { id: 0, name: '导入 ONE 模板' },
+        // { id: 1, name: '导入 PIL 订舱模板' },
+        // { id: 2, name: '导入截单格式' },
+        // { id: 3, name: '导入海信提单' },
+        { id: 4, name: '提单样本' }
+      ],
+      importTemplate: null,
       selectionTemplateList: [],
       selectionfeecList: [],
       feeType: null,
@@ -951,7 +1000,9 @@ export default {
     this.option = await this.getColumnData(this.getColumnName(502), this.optionBack);
     this.feecOption = await this.getColumnData(this.getColumnName(235.2), this.feecOptionBack);
     this.saveLocalCurrency(JSON.parse(localStorage.getItem('sysitemData')).deptId)
-    console.log(this.detailData)
+    isProcurement({ "param": "import.template" }).then(res => {
+      this.importTemplate = res.data.data
+    })
     if (this.detailData && this.detailData.id) {
       this.getDetails(this.detailData.id)
     }
@@ -975,6 +1026,63 @@ export default {
     this.saveLocalCurrency(this.deptId)
   },
   methods: {
+    //文档导入
+    importData2(row) {
+      if (row == 0) {
+        this.excelOption.column[0].action = `/api/blade-los/templateImport/importOne?billId=${this.form.id}`
+      } else if (row == 1) {
+        this.excelOption.column[0].action = `/api/blade-los/templateImport/importPilBooking?billId=${this.form.id}`
+      } else if (row == 2) {
+        this.excelOption.column[0].action = `/api/blade-los/templateImport/importPilCutOffOrders?billId=${this.form.id}`
+      } else if (row == 3) {
+        this.excelOption.column[0].action = `/api/blade-los/templateImport/importHisenseBill?billId=${this.form.id}`
+      } else if (row == 4) {
+        this.excelOption.column[0].action = `/api/blade-los/templateImport/importBills?billId=${this.form.id}`
+      }
+      this.excelBox = true
+    },
+    // 上传成功
+    onSuccess(res, done, loading, column) {
+      loading = true
+      if (Object.keys(res).length) {
+        //   loading = false;
+        this.$confirm('此操作将覆盖数据, 是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          // this.form = res;
+          Object.keys(res).forEach(key => {
+            if (res[key]) {
+              if (key != 'detail') {
+                // this.form[key] = res[key]
+                this.$set(this.form, key, res[key])
+              }
+              if (key == 'detail') {
+                Object.keys(res.detail).forEach(key => {
+                  if (res.detail[key]) {
+                    // this.form.detail[key] = res.detail[key]
+                    this.$set(this.form.detail, key, res.detail[key])
+                  }
+                });
+              }
+
+            }
+          });
+          this.excelBox = false;
+          this.$message.success("导入成功!");
+          loading = false;
+          done();
+        }).catch(() => {
+          this.excelBox = false;
+          loading = false;
+          done();
+        });
+      } else {
+        loading = false;
+        done();
+      }
+    },
     countChange(row) {
       if (row.curCode == this.getLocalCurrency()) {
         row.amountCNY = _.round(_.multiply(row.price, row.quantity), 2)

+ 13 - 7
src/views/iosBasicData/costStatistics/index.vue

@@ -58,7 +58,7 @@ export default {
                 height: '600px',
                 calcHeight: 30,
                 searchShow: true,
-                searchMenuSpan: 18,
+                searchMenuSpan: 12,
                 border: true,
                 index: true,
                 addBtn: false,
@@ -190,6 +190,12 @@ export default {
                         overHidden: true,
                     },
                     {
+                        label: "分单号",
+                        prop: "hblno",
+                        search: true,
+                        overHidden: true,
+                    },
+                    {
                         label: "来源编号",
                         prop: "srcNo",
                         search: true,
@@ -290,13 +296,17 @@ export default {
         ).content;
         this.option = await this.getColumnData(this.getColumnName(411), this.optionBack)
         if (this.saberUserInfo.role_name.indexOf('admin') != -1 || this.saberUserInfo.role_name.indexOf('总部') != -1) {
-            this.option.searchMenuSpan = 12
+            this.option.searchMenuSpan = 6
             this.option.column.forEach(item => {
                 if (item.prop == 'branchId') {
                     item.search = true
                 }
             })
         }
+        this.$nextTick(() => {
+            this.$refs.crud.refreshTable()
+            this.$refs.crud.dicInit()
+        })
     },
     activated() {
         this.$refs.crud.doLayout();
@@ -433,10 +443,6 @@ export default {
                 this.page.total = res.data.data.total;
                 this.data = res.data.data.records
                 this.getStatisticsSum(Object.assign(params, this.query))
-                this.$nextTick(() => {
-                    this.$refs.crud.refreshTable()
-                    this.$refs.crud.dicInit()
-                })
             }).finally(() => {
                 this.loading = false;
             })
@@ -478,7 +484,7 @@ export default {
             this[option] = this[optionBack];
             const inSave = await this.delColumnData(this.getColumnName(code), this[optionBack]);
             if (this.saberUserInfo.role_name.indexOf('admin') != -1 || this.saberUserInfo.role_name.indexOf('总部') != -1) {
-                this.option.searchMenuSpan = 12
+                this.option.searchMenuSpan = 6
                 this.option.column.forEach(item => {
                     if (item.prop == 'branchId') {
                         item.search = true

+ 1 - 1
src/views/iosBasicData/feeApplication/index.vue

@@ -311,7 +311,7 @@ export default {
       if (JSON.stringify(this.$route.query) != "{}") {
         this.$router.$avueRouter.closeTag();
         this.$router.push({
-          path: "/boxManagement/buyContainer/index"
+          path: "/iosBasicData/feeApplication/index"
         });
       }
       this.detailData = {}

+ 22 - 7
src/views/iosBasicData/losbfeestemplate/feesTemplateItems.vue

@@ -526,11 +526,11 @@ export default {
                         // type: 'number',
                         // controls: false,
                         overHidden: true,
-                        rules: [{
-                            required: true,
-                            message: "请输入单价",
-                            trigger: "blur"
-                        }]
+                        // rules: [{
+                        //     required: true,
+                        //     message: "请输入单价",
+                        //     trigger: "blur"
+                        // }]
                     },
                     {
                         label: "计量单位",
@@ -741,10 +741,13 @@ export default {
     },
     methods: {
         rowCell(row, index) {
-            if (!row.feeCnName || !row.quantityRule || !row.quantity || !row.price || !row.unitNo || !row.curCode) {
+            if (!row.feeCnName || !row.quantityRule || !row.quantity || !row.unitNo || !row.curCode) {
                 this.$refs.crud.rowCell(row, index)
                 return this.$message.error("请完善明细信息");
             }
+            // if (row.price==0) {
+            //     return this.$message.error("请完善明细信息");
+            // }
             if (row.$cellEdit == true) {
                 this.$set(row, "$cellEdit", false);
             } else {
@@ -1123,7 +1126,19 @@ export default {
                             remove({ ids: ids.join(',') })
                         }
                     }
-                    this.losbfeestemplateSubmitfun()
+                    if (this.form.feesTemplateItemsList.filter(item => item.price == 9)) {
+                        this.$confirm('费用单价为0,是否确认保存?', '提示', {
+                            confirmButtonText: '确定',
+                            cancelButtonText: '取消',
+                            type: 'warning'
+                        }).then(() => {
+                         
+                        this.losbfeestemplateSubmitfun()
+                        })
+                    } else {
+                        this.losbfeestemplateSubmitfun()
+                    }
+
                 } else {
                     return false;
                 }

+ 15 - 3
src/views/ow/owPut/detailsPage.vue

@@ -49,11 +49,14 @@
                 </dic-select>
               </tempalte>
               <tempalte slot="containerNumber">
-                <dic-select v-model="form.containerNumber" placeholder="放箱号" :key="containerNumberKey"
+                <!-- <dic-select v-model="form.containerNumber" placeholder="放箱号" :key="containerNumberKey"
                   label="containerNumber" :disabled="editDisabled || form.whetherEnable == '是'"
                   :url="'/blade-los/putbox/selectContainerNumber?boxType=' + (form.boxTypeQuantityOne ? form.boxTypeQuantityOne : '') + '&polId=' + (form.polId ? form.polId : '') + '&podId=' + (form.podId ? form.podId : '') + '&polStationId=' + (form.polStationId ? form.polStationId : '')"
                   :filterable="true" @selectChange="dicChange('containerNumber', $event)">
-                </dic-select>
+                </dic-select> -->
+                <container-number v-model="form.containerNumber" placeholder="放箱号" label="containerNumber"
+                  :url="'/blade-los/putbox/selectContainerNumber?boxType=' + (form.boxTypeQuantityOne ? form.boxTypeQuantityOne : '') + '&polId=' + (form.polId ? form.polId : '') + '&podId=' + (form.podId ? form.podId : '') + '&polStationId=' + (form.polStationId ? form.polStationId : '')"
+                  @selectChange="dicChange('containerNumber', $event)" :titleDialog="放箱号"></container-number>
               </tempalte>
               <!-- <tempalte slot="polStationCname">
                 <dic-select v-model="form.polStationCname" placeholder="起运港提/送箱场站" key="id" label="cnName" res="records"
@@ -608,6 +611,7 @@ import {
   getAccurate
 } from "@/api/boxManagement/buyContainer";
 import dicSelect from "@/components/dicSelect/main";
+import containerNumber from "@/components/dicSelect/containerNumber";
 import checkSchedule from "@/components/checkH/checkSchedule.vue";
 import businessReports from "@/components/boxManagement/businessReports.vue";
 import reports from "@/components/boxManagement/reports.vue";
@@ -2057,7 +2061,8 @@ export default {
     dicSelect,
     checkSchedule,
     businessReports,
-    reports
+    reports,
+    containerNumber
   },
   props: {
     detailData: Object
@@ -2250,6 +2255,7 @@ export default {
     dicChange(name, row) {
       if (name == 'containerNumber') {
         if (row) {
+          this.form.containerNumber =row.containerNumber
           this.form.boxCondition = row.boxCondition
           this.form.polId = row.polId
           this.form.polCode = row.polCode
@@ -3086,6 +3092,9 @@ export default {
       if (name == 'D费用申请') {
         let selecList = [...this.selectionfeedList, ...this.selectionfeecList]
         for (let row of selecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }
@@ -3123,6 +3132,9 @@ export default {
       }
       if (name == 'C费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }

+ 7 - 1
src/views/ow/owTask/detailsPage.vue

@@ -2051,7 +2051,7 @@ export default {
 
   },
   methods: {
-   verifyChange(name, row) {
+    verifyChange(name, row) {
       if (row[name]) {
         getAccurate({ accurate: row[name] }).then(res => {
           if (res.data.data.records.length == 0) {
@@ -3024,6 +3024,9 @@ export default {
       if (name == 'D费用申请') {
         let selecList = [...this.selectionfeedList, ...this.selectionfeecList]
         for (let row of selecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }
@@ -3061,6 +3064,9 @@ export default {
       }
       if (name == 'C费用申请') {
         for (let row of this.selectionfeecList) {
+          if (!row.id) {
+            return this.$message.error("请保存费用明细");
+          }
           if (row.stlPid && row.accStatus != 0) {
             return this.$message.error("已生成账单,不允许重复申请");
           }