achao преди 3 години
родител
ревизия
d016b6e010

+ 73 - 62
unimall-admin/src/api/customerBillingInfo.js

@@ -2,88 +2,99 @@ import request from '@/utils/request'
 import Qs from 'qs'
 
 export function listCustomerBillingInfo(query) {
-  return request({
-    method: 'post',
-    params: {
-      _gp: 'admin.customerbilling',
-      _mt: 'list',
-      page: query.page,
-      limit: query.limit,
-      CustomerBillingInfoDTO: JSON.stringify(query.type)
-    }
-  })
+    return request({
+        method: 'post',
+        params: {
+            _gp: 'admin.customerbilling',
+            _mt: 'list',
+            page: query.page,
+            limit: query.limit,
+            CustomerBillingInfoDTO: JSON.stringify(query.type)
+        }
+    })
 }
 export function getCusDate(query) {
-  return request({
-    method: 'post',
-    params: {
-      _gp: 'admin.customerbilling',
-      _mt: 'cusDate',
-      ...query
+    return request({
+        method: 'post',
+        params: {
+            _gp: 'admin.customerbilling',
+            _mt: 'cusDate',
+            ...query
 
-    }
-  })
+        }
+    })
 }
 export function listCustomer() {
-  return request({
-    method: 'post',
-    params: {
-      _gp: 'admin.customerbilling',
-      _mt: 'customerList'
-    }
-  })
+    return request({
+        method: 'post',
+        params: {
+            _gp: 'admin.customerbilling',
+            _mt: 'customerList'
+        }
+    })
 }
 export function createCustomerBillingInfo(data) {
-  return request({
-    method: 'post',
-    data: Qs.stringify({
-      _gp: 'admin.customerbilling',
-      _mt: 'create',
-      CustomerBillingInfoDTO: JSON.stringify(data)
+    return request({
+        method: 'post',
+        data: Qs.stringify({
+            _gp: 'admin.customerbilling',
+            _mt: 'create',
+            CustomerBillingInfoDTO: JSON.stringify(data)
+        })
     })
-  })
 }
 export function editCustomerBillingInfo(data) {
-  return request({
-    method: 'post',
-    data: Qs.stringify({
-      _gp: 'admin.customerbilling',
-      _mt: 'edit',
-      CustomerBillingInfoDTO: JSON.stringify(data)
+    return request({
+        method: 'post',
+        data: Qs.stringify({
+            _gp: 'admin.customerbilling',
+            _mt: 'edit',
+            CustomerBillingInfoDTO: JSON.stringify(data)
+        })
     })
-  })
 }
 
 export function updateCustomerBillingInfo(data) {
-  return request({
-    method: 'post',
-    data: Qs.stringify({
-      _gp: 'admin.customerbilling',
-      _mt: 'edit',
-      CustomerBillingInfoDTO: JSON.stringify(data)
+    return request({
+        method: 'post',
+        data: Qs.stringify({
+            _gp: 'admin.customerbilling',
+            _mt: 'edit',
+            CustomerBillingInfoDTO: JSON.stringify(data)
+        })
     })
-  })
 }
 
 export function deleteCustomerBillingInfo(id) {
-  return request({
-    method: 'post',
-    params: {
-      _gp: 'admin.customerbilling',
-      _mt: 'delete',
-      id: id
-    }
-  })
+    return request({
+        method: 'post',
+        params: {
+            _gp: 'admin.customerbilling',
+            _mt: 'delete',
+            id: id
+        }
+    })
 }
 
 export function exportXlsx(data) {
-  return request({
-    method: 'post',
-    data: Qs.stringify({
-      _gp: 'admin.customerbilling',
-      _mt: 'export',
-      CustomerBillingInfoDTO: JSON.stringify(data),
-      response: 'blob'
+    return request({
+        method: 'post',
+        data: Qs.stringify({
+            _gp: 'admin.customerbilling',
+            _mt: 'export',
+            CustomerBillingInfoDTO: JSON.stringify(data),
+            response: 'blob'
+        })
     })
-  })
 }
+
+export function importWord(data) {
+    return request({
+        method: 'post',
+        data: Qs.stringify({
+            _gp: 'admin.customerbilling',
+            _mt: 'createAll',
+            CustomerBillingInfoDTO: JSON.stringify(data)
+        })
+    })
+}

+ 127 - 153
unimall-admin/src/router/route.json

@@ -1,155 +1,129 @@
 [{
-	"redirect":"noredirect",
-	"path":"/tools1",
-	"children":[
-		{
-			"path":"generator",
-			"meta":{
-				"noCache":true,
-				"perms":[
-					""
-				],
-				"title":"代码生成器"
-			},
-			"name":"tools",
-			"page":"/tools/generator"
-		}
-	],
-	"meta":{
-		"icon":"tools",
-		"title":"实用工具"
-	},
-	"name":"toolsManage",
-	"alwaysShow":true
-},
-	{
-		"redirect":"noredirect",
-		"path":"/tools",
-		"children":[
-			{
-				"path":"country",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"地区"
-				},
-				"name":"country",
-				"page":"/country/country"
-			},
-			{
-				"path":"collectionPayment",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"收款"
-				},
-				"name":"collectionPayment",
-				"page":"/collectionPayment/collectionPayment"
-			},
-			{
-				"path":"collectionPayment1",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"提款"
-				},
-				"name":"collectionPayment1",
-				"page":"/collectionPayment/collectionPayment1"
-			}
-		],
-		"meta":{
-			"icon":"tools",
-			"title":"账单管理"
-		},
-		"name":"toolsManage",
-		"alwaysShow":true
-	},
-	{
-		"redirect":"noredirect",
-		"path":"/customerBill",
-		"children":[
-			{
-				"path":"customerBilling",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"客户账单信息"
-				},
-				"name":"customerBilling",
-				"page":"/customerBilling/customerBillingInfo"
-			},
-			{
-				"path":"customerBillingInfoadd",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"客户账单添加"
-				},
-				"name":"customerBillingInfoadd",
-				"page":"/customerBilling/customerBillingInfoadd",
-				"hidden":true
-			},
-			{
-				"path":"customerBillingInfolook",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"客户账单查看"
-				},
-				"name":"customerBillingInfolook",
-				"page":"/customerBilling/customerBillingInfolook",
-				"hidden":true
-			},
-			{
-				"path":"customerBillingInfoedit",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"客户账单编辑"
-				},
-				"name":"customerBillingInfoedit",
-				"page":"/customerBilling/customerBillingInfoedit",
-				"hidden":true
-			},
-			{
-				"path":"customerBillingDetail",
-				"meta":{
-					"noCache":true,
-					"perms":[
-						""
-					],
-					"title":"客户账单详情"
-				},
-				"name":"customerBillingDetail",
-				"page":"/customerBillingDetail/customerBillingDetail",
-				"hidden":true
-			}
-		],
-		"meta":{
-			"icon":"tools",
-			"title":"客户账单"
-		},
-		"name":"toolsManage",
-		"alwaysShow":true
-	},
-	{
-		"redirect":"/404",
-		"path":"*",
-		"hidden":true
-	}
+        "redirect": "noredirect",
+        "path": "/tools",
+        "children": [{
+                "path": "country",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "地区"
+                },
+                "name": "country",
+                "page": "/country/country"
+            },
+            {
+                "path": "collectionPayment",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "收款"
+                },
+                "name": "collectionPayment",
+                "page": "/collectionPayment/collectionPayment"
+            },
+            {
+                "path": "collectionPayment1",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "提款"
+                },
+                "name": "collectionPayment1",
+                "page": "/collectionPayment/collectionPayment1"
+            }
+        ],
+        "meta": {
+            "icon": "tools",
+            "title": "账单管理"
+        },
+        "name": "toolsManage",
+        "alwaysShow": true
+    },
+    {
+        "redirect": "noredirect",
+        "path": "/customerBill",
+        "children": [{
+                "path": "customerBilling",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "客户账单信息"
+                },
+                "name": "customerBilling",
+                "page": "/customerBilling/customerBillingInfo"
+            },
+            {
+                "path": "customerBillingInfoadd",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "客户账单添加"
+                },
+                "name": "customerBillingInfoadd",
+                "page": "/customerBilling/customerBillingInfoadd",
+                "hidden": true
+            },
+            {
+                "path": "customerBillingInfolook",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "客户账单查看"
+                },
+                "name": "customerBillingInfolook",
+                "page": "/customerBilling/customerBillingInfolook",
+                "hidden": true
+            },
+            {
+                "path": "customerBillingInfoedit",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "客户账单编辑"
+                },
+                "name": "customerBillingInfoedit",
+                "page": "/customerBilling/customerBillingInfoedit",
+                "hidden": true
+            },
+            {
+                "path": "customerBillingDetail",
+                "meta": {
+                    "noCache": true,
+                    "perms": [
+                        ""
+                    ],
+                    "title": "客户账单详情"
+                },
+                "name": "customerBillingDetail",
+                "page": "/customerBillingDetail/customerBillingDetail",
+                "hidden": true
+            }
+        ],
+        "meta": {
+            "icon": "tools",
+            "title": "客户账单"
+        },
+        "name": "toolsManage",
+        "alwaysShow": true
+    },
+    {
+        "redirect": "/404",
+        "path": "*",
+        "hidden": true
+    }
 
-]
+]

+ 21 - 5
unimall-admin/src/views/collectionPayment/collectionPayment.vue

@@ -16,11 +16,20 @@
                 style="width: 200px;" placeholder="请输入收款日期" /> -->
       <el-select
         v-model="listQuery.type.receivingWithdrawingRegion"
+        clearable
         placeholder="请选择收款地"
         style="margin:0 20px;"
         size="small">
         <el-option v-for="(item, index) in placeList" :label="item.country" :value="item.country" :key="index"/>
       </el-select>
+      <el-select
+        v-model="listQuery.type.status"
+        clearable
+        placeholder="请选择单据类型"
+        style="margin:0 20px;"
+        size="small">
+        <el-option v-for="(item, index) in typeList" :label="item.label" :value="item.value" :key="index"/>
+      </el-select>
       <el-date-picker
         v-model="selectDate"
         style="margin-right:20px"
@@ -65,7 +74,6 @@
           v-permission="['collectionPayment:collectionpayment:create']"
           class="filter-item"
           type="primary"
-          size="mini"
           icon="el-icon-edit">导入</el-button>
       </el-upload>
 
@@ -154,7 +162,8 @@
         </el-form-item>
         <el-form-item label="收款地" prop="receivingWithdrawingRegion">
           <!-- <el-input v-model="dataForm.receivingWithdrawingRegion" /> -->
-          <el-select v-model="dataForm.receivingWithdrawingRegion" placeholder="请选择收款地点" style="width:100%">
+
+          <el-select v-model="dataForm.receivingWithdrawingRegion" clearable placeholder="请选择收款地点" style="width:100%" >
             <el-option
               v-for="(item, index) in placeList"
               :label="item.country"
@@ -224,6 +233,14 @@ export default {
   components: { Pagination },
   data() {
     return {
+      typeList: [{
+        value: '0',
+        label: '正常单据'
+      },
+      {
+        value: '1',
+        label: '作废单据'
+      }],
       isAllowExport: true,
       countryList: [],
       modification: [],
@@ -249,7 +266,8 @@ export default {
           receivingWithdrawingPeople: '',
           receivingWithdrawingRegion: '',
           startDate: '',
-          endDate: ''
+          endDate: '',
+          status: '0'
         }
       },
       listPlace: {
@@ -281,7 +299,6 @@ export default {
   },
   methods: {
     handleSizeChange(val) {
-      debugger
       console.log(`每页 ${val} 条`)
       this.listQuery.limit = val
       this.getList()
@@ -387,7 +404,6 @@ export default {
             const jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '')
             v = JSON.parse(jsonString)
             const obj = {}
-            debugger
             // xxx代表列名
             obj.receiptPaymentDate = v.收款日期
             obj.receivingWithdrawingRegion = v.收款地

+ 593 - 544
unimall-admin/src/views/collectionPayment/collectionPayment1.vue

@@ -1,147 +1,215 @@
 <template>
-    <div class="app-container">
-        <!-- 查询和其他操作 -->
-        <div class="filter-container">
-            <el-input v-model="listQuery.type.receivingWithdrawingPeople" clearable class="filter-item" size="small"
-                style="width: 200px;" placeholder="请输入提款人姓名" />
-            <!-- <el-input v-model="listQuery.type.receivingWithdrawingRegion" clearable class="filter-item" size="small"
+  <div class="app-container">
+    <!-- 查询和其他操作 -->
+    <div class="filter-container">
+      <el-input
+        v-model="listQuery.type.receivingWithdrawingPeople"
+        clearable
+        class="filter-item"
+        size="small"
+        style="width: 200px;"
+        placeholder="请输入提款人姓名" />
+      <!-- <el-input v-model="listQuery.type.receivingWithdrawingRegion" clearable class="filter-item" size="small"
                 style="width: 200px;" placeholder="请输入提款地" /> -->
 
-            <!-- <el-input v-model="listQuery.receiptPaymentDate" clearable class="filter-item" size="small"
+      <!-- <el-input v-model="listQuery.receiptPaymentDate" clearable class="filter-item" size="small"
                 style="width: 200px;" placeholder="请输入提款日期" /> -->
-            <el-select v-model="listQuery.type.receivingWithdrawingRegion" placeholder="请选择收款地" style="margin:0 20px;"
-                size="small">
-                <el-option :label="item.country" :value="item.country" v-for="(item, index) in placeList" :key="index">
-                </el-option>
-            </el-select>
-            <el-date-picker style="margin-right:20px" size="small" v-model="selectDate" type="daterange" value-format="yyyy-MM-dd"
-                range-separator="至" start-placeholder="开始日期" end-placeholder="结束日期">
-            </el-date-picker>
+      <el-select
+        v-model="listQuery.type.receivingWithdrawingRegion"
+        placeholder="请选择收款地"
+        style="margin:0 20px;"
+        size="small"
+        clearable>
+        <el-option v-for="(item, index) in placeList" :label="item.country" :value="item.country" :key="index"/>
+      </el-select>
+      <el-date-picker
+        v-model="selectDate"
+        style="margin-right:20px"
+        size="small"
+        type="daterange"
+        value-format="yyyy-MM-dd"
+        range-separator="至"
+        start-placeholder="开始日期"
+        end-placeholder="结束日期"/>
+
+      <el-button
+        v-permission="['collectionPayment:collectionpayment:list']"
+        class="filter-item"
+        type="primary"
+        size="mini"
+        icon="el-icon-search"
+        @click="handleFilter">查找</el-button>
+      <el-button
+        v-permission="['collectionPayment:collectionpayment:create']"
+        class="filter-item"
+        type="primary"
+        size="mini"
+        icon="el-icon-edit"
+        @click="handleCreate">添加</el-button>
+      <el-button
+        v-permission="['collectionPayment:collectionpayment:create']"
+        class="filter-item"
+        type="primary"
+        size="mini"
+        icon="el-icon-edit"
+        @click="exportlist">导出</el-button>
+
+      <el-upload
+        :on-change="importClick"
+        :show-file-list="false"
+        :auto-upload="false"
+        style="margin-left: 8px;margin-bottom:0"
+        class="filter-item"
+        action=""
+        accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel">
+        <el-button
+          v-permission="['collectionPayment:collectionpayment:create']"
+          class="filter-item"
+          type="primary"
+          size="mini"
+          icon="el-icon-edit">导入</el-button>
+      </el-upload>
 
-            <el-button v-permission="['collectionPayment:collectionpayment:list']" class="filter-item" type="primary"
-                size="mini" icon="el-icon-search" @click="handleFilter">查找</el-button>
-            <el-button v-permission="['collectionPayment:collectionpayment:create']" class="filter-item" type="primary"
-                size="mini" icon="el-icon-edit" @click="handleCreate">添加</el-button>
-            <el-button v-permission="['collectionPayment:collectionpayment:create']" class="filter-item" type="primary"
-                size="mini" icon="el-icon-edit" @click="exportlist">导出</el-button>
-
-            <el-upload style="margin-left: 8px;margin-bottom:0" class="filter-item" action="" :on-change="importClick"
-                :show-file-list="false"
-                accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel"
-                :auto-upload="false">
-                <el-button v-permission="['collectionPayment:collectionpayment:create']" class="filter-item"
-                    type="primary" size="mini" icon="el-icon-edit">导入</el-button>
-            </el-upload>
-
-        </div>
-
-        <!-- 查询结果 -->
-        <el-table v-loading="listLoading" :data="list" size="small" element-loading-text="正在查询中。。。" border fit
-            highlight-current-row show-summary :summary-method="getSummaries" @selection-change="handleSelectionChange">
-            <el-table-column :selectable="selectInit" type="selection"></el-table-column>
-            <el-table-column type="index" label="序号">
-                <template scope="scope">
-                    <span v-if="scope.$index < 9">0{{ scope.$index + 1 }}</span>
-                    <span v-else>{{ scope.$index + 1 }}</span>
-                </template>
-            </el-table-column>
+    </div>
 
-            <el-table-column align="center" label="提款日期" prop="receiptPaymentDate">
-                <template slot-scope="scope">
-                    {{ scope.row.receiptPaymentDate }}</template>
-            </el-table-column>
-            <el-table-column align="center" label="提款地" prop="receivingWithdrawingRegion" />
-            <el-table-column align="center" label="提款人" prop="receivingWithdrawingPeople" />
-            <el-table-column align="center" label="金额(欧元)" prop="deductionEuro" />
-            <el-table-column align="center" label="金额(人民币)" prop="deductionRmb" />
-            <el-table-column align="center" label="备注1" prop="remarks" />
-            <el-table-column align="center" label="备注2" prop="remark" />
-            <el-table-column align="center" label="状态" prop="status">
-                <template slot-scope="scope">
-                    {{ scope.row.status == 1 ? '已作废' : '' }}</template>
-            </el-table-column>
-            <el-table-column align="center" label="操作人" prop="updatePeople" />
-            <el-table-column align="center" label="操作" class-name="small-padding fixed-width">
-                <template slot-scope="scope">
-                    <el-button v-permission="['collectionPayment:collectionpayment:edit']" type="primary" size="mini"
-                        @click="handleUpdate(scope.row)">编辑</el-button>
-                            <el-button v-permission="['collectionPayment:collectionpayment:edit']" type="primary" size="mini"
-                        @click="updateData1(scope.row)">作废</el-button>
-                    <!-- <el-button v-permission="['collectionPayment:collectionpayment:delete']" type="danger" size="mini"
+    <!-- 查询结果 -->
+    <el-table
+      v-loading="listLoading"
+      :data="list"
+      :summary-method="getSummaries"
+      size="small"
+      element-loading-text="正在查询中。。。"
+      border
+      fit
+      highlight-current-row
+      show-summary
+      @selection-change="handleSelectionChange">
+      <el-table-column :selectable="selectInit" type="selection"/>
+      <el-table-column type="index" label="序号">
+        <template scope="scope">
+          <span v-if="scope.$index < 9">0{{ scope.$index + 1 }}</span>
+          <span v-else>{{ scope.$index + 1 }}</span>
+        </template>
+      </el-table-column>
+
+      <el-table-column align="center" label="提款日期" prop="receiptPaymentDate">
+        <template slot-scope="scope">
+          {{ scope.row.receiptPaymentDate }}</template>
+      </el-table-column>
+      <el-table-column align="center" label="提款地" prop="receivingWithdrawingRegion" />
+      <el-table-column align="center" label="提款人" prop="receivingWithdrawingPeople" />
+      <el-table-column align="center" label="金额(欧元)" prop="deductionEuro" />
+      <el-table-column align="center" label="金额(人民币)" prop="deductionRmb" />
+      <el-table-column align="center" label="备注1" prop="remarks" />
+      <el-table-column align="center" label="备注2" prop="remark" />
+      <el-table-column align="center" label="状态" prop="status">
+        <template slot-scope="scope">
+          {{ scope.row.status == 1 ? '已作废' : '' }}</template>
+      </el-table-column>
+      <el-table-column align="center" label="操作人" prop="updatePeople" />
+      <el-table-column align="center" label="操作" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            v-permission="['collectionPayment:collectionpayment:edit']"
+            type="primary"
+            size="mini"
+            @click="handleUpdate(scope.row)">编辑</el-button>
+          <el-button
+            v-permission="['collectionPayment:collectionpayment:edit']"
+            type="primary"
+            size="mini"
+            @click="updateData1(scope.row)">作废</el-button>
+            <!-- <el-button v-permission="['collectionPayment:collectionpayment:delete']" type="danger" size="mini"
                         @click="handleDelete(scope.row)">删除</el-button> -->
-                </template>
-            </el-table-column>
-        </el-table>
-
-        <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
-            :page-sizes="[100, 200, 300, 400,1000,1500,2000]" :page-size="100" layout="total, sizes, prev, pager, next, jumper"
-            :total="total">
-        </el-pagination>
-
-        <!-- 添加或修改对话框 -->
-        <el-dialog :title="textMap[dialogStatus]" :visible.sync="dialogFormVisible">
-            <el-form ref="dataForm" :rules="rules" :model="dataForm" status-icon label-position="left"
-                label-width="150px" style="width: 400px; margin-left:50px;">
-                <el-form-item label="id" prop="id" hidden>
-                    <el-input v-model="dataForm.id" />
-                </el-form-item>
-                <el-form-item label="提款人" prop="receivingWithdrawingPeople">
-                    <el-input v-model="dataForm.receivingWithdrawingPeople" />
-                </el-form-item>
-                <el-form-item label="提款地" prop="receivingWithdrawingRegion">
-                    <!-- <el-input v-model="dataForm.receivingWithdrawingRegion" /> -->
-                    <el-select v-model="dataForm.receivingWithdrawingRegion" placeholder="请选择提款地点" style="width:100%">
-                        <el-option :label="item.country" :value="item.country" v-for="(item, index) in placeList"
-                            :key="index"></el-option>
-                    </el-select>
-                </el-form-item>
-                <el-form-item label="提款日期" prop="receiptPaymentDate">
-                    <!-- <el-input v-model="dataForm.receiptPaymentDate" /> -->
-                    <el-date-picker v-model="dataForm.receiptPaymentDate" type="date" class="tkdate" value-format="yyyy-MM-dd"
-                        style="width: 100%;">
-                    </el-date-picker>
-                </el-form-item>
-                <el-form-item label="金额(欧元)" prop="deductionEuro">
-                    <el-input v-model="dataForm.deductionEuro" />
-                </el-form-item>
-                <el-form-item label="金额(人民币)" prop="deductionRmb">
-                    <el-input v-model="dataForm.deductionRmb" />
-                </el-form-item>
-                <el-form-item label="备注1" prop="remarks">
-                    <el-input v-model="dataForm.remarks" />
-                </el-form-item>
-                <el-form-item label="备注2" prop="remark">
-                    <el-input v-model="dataForm.remark" />
-                </el-form-item>
-            </el-form>
-            <div slot="footer" class="dialog-footer">
-                <el-button @click="dialogFormVisible = false">取消</el-button>
-                <el-button v-if="dialogStatus == 'create'" :loading="submiting" type="primary" @click="createData">确定
-                </el-button>
-                <el-button v-else type="primary" :loading="submiting" @click="updateData">确定</el-button>
-            </div>
-        </el-dialog>
-    </div>
+        </template>
+      </el-table-column>
+    </el-table>
+
+    <el-pagination
+      :current-page="currentPage"
+      :page-sizes="[100, 200, 300, 400,1000,1500,2000]"
+      :page-size="100"
+      :total="total"
+      layout="total, sizes, prev, pager, next, jumper"
+      @size-change="handleSizeChange"
+      @current-change="handleCurrentChange"/>
+
+    <!-- 添加或修改对话框 -->
+    <el-dialog :title="textMap[dialogStatus]" :visible.sync="dialogFormVisible">
+      <el-form
+        ref="dataForm"
+        :rules="rules"
+        :model="dataForm"
+        status-icon
+        label-position="left"
+        label-width="150px"
+        style="width: 400px; margin-left:50px;">
+        <el-form-item label="id" prop="id" hidden>
+          <el-input v-model="dataForm.id" />
+        </el-form-item>
+        <el-form-item label="提款人" prop="receivingWithdrawingPeople">
+          <el-input v-model="dataForm.receivingWithdrawingPeople" />
+        </el-form-item>
+        <el-form-item label="提款地" prop="receivingWithdrawingRegion">
+          <!-- <el-input v-model="dataForm.receivingWithdrawingRegion" /> -->
+          <el-select v-model="dataForm.receivingWithdrawingRegion" placeholder="请选择提款地点" clearable style="width:100%">
+            <el-option
+              v-for="(item, index) in placeList"
+              :label="item.country"
+              :value="item.country"
+              :key="index"/>
+          </el-select>
+        </el-form-item>
+        <el-form-item label="提款日期" prop="receiptPaymentDate">
+          <!-- <el-input v-model="dataForm.receiptPaymentDate" /> -->
+          <el-date-picker
+            v-model="dataForm.receiptPaymentDate"
+            type="date"
+            class="tkdate"
+            value-format="yyyy-MM-dd"
+            style="width: 100%;"/>
+        </el-form-item>
+        <el-form-item label="金额(欧元)" prop="deductionEuro">
+          <el-input v-model="dataForm.deductionEuro" />
+        </el-form-item>
+        <el-form-item label="金额(人民币)" prop="deductionRmb">
+          <el-input v-model="dataForm.deductionRmb" />
+        </el-form-item>
+        <el-form-item label="备注1" prop="remarks">
+          <el-input v-model="dataForm.remarks" />
+        </el-form-item>
+        <el-form-item label="备注2" prop="remark">
+          <el-input v-model="dataForm.remark" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button @click="dialogFormVisible = false">取消</el-button>
+        <el-button v-if="dialogStatus == 'create'" :loading="submiting" type="primary" @click="createData">确定
+        </el-button>
+        <el-button v-else :loading="submiting" type="primary" @click="updateData">确定</el-button>
+      </div>
+    </el-dialog>
+  </div>
 </template>
 
 <script>
 import {
-    dayjs,
-    EventBus
+  dayjs,
+  EventBus
 } from 'base-core-lib'
 import {
-    listCountry
+  listCountry
 } from '@/api/country'
 import {
-    downloadFile
+  downloadFile
 } from '@/utils/batchDown'
 import {
-    importWord,
-    listCollectionPayment,
-    createCollectionPayment,
-    updateCollectionPayment,
-    deleteCollectionPayment,
-    exportXlsx
+  importWord,
+  listCollectionPayment,
+  createCollectionPayment,
+  updateCollectionPayment,
+  deleteCollectionPayment,
+  exportXlsx
 } from '@/api/collectionPayment'
 // import {
 //     exportXlsx
@@ -150,439 +218,420 @@ import {
 import Pagination from '@/components/Pagination'
 import store from '@/store'
 export default {
-    name: 'CollectionPayment',
-    components: { Pagination },
-    data() {
-        return {
-            isAllowExport: true,
-            countryList: [],
-            modification: [],
-            selectDate: '',
-            date: {
-                year: dayjs().format('YYYY'),
-                month: dayjs().format('MM'),
-            },
-            accessoryTFs: false,
-            fileList: [],
-            appendixIdsAdd: '',
-            excelFreightspace: [],
-            fileTemp: null,
-            placeList: [],
-            list: null,
-            total: 0,
-            listLoading: true,
-            listQuery: {
-                page: 1,
-                limit: 100,
-                type: {
-                    businessType: 2,
-                    receivingWithdrawingPeople: '',
-                    receivingWithdrawingRegion: '',
-                    startDate: '',
-                    endDate: '',
-                },
-            },
-            listPlace: {
-                page: 1,
-                limit: 2000,
-                type: {
-                    country: ''
-                }
-            },
-            dataForm: {
-                id: undefined
-            },
-            dialogFormVisible: false,
-            submiting: false,
-            dialogStatus: '',
-            textMap: {
-                update: '编辑',
-                create: '创建'
-            },
-            rules: {
-            }
+  name: 'CollectionPayment',
+  components: { Pagination },
+  data() {
+    return {
+      isAllowExport: true,
+      countryList: [],
+      modification: [],
+      selectDate: '',
+      date: {
+        year: dayjs().format('YYYY'),
+        month: dayjs().format('MM')
+      },
+      accessoryTFs: false,
+      fileList: [],
+      appendixIdsAdd: '',
+      excelFreightspace: [],
+      fileTemp: null,
+      placeList: [],
+      list: null,
+      total: 0,
+      listLoading: true,
+      listQuery: {
+        page: 1,
+        limit: 100,
+        type: {
+          businessType: 2,
+          receivingWithdrawingPeople: '',
+          receivingWithdrawingRegion: '',
+          startDate: '',
+          endDate: ''
         }
+      },
+      listPlace: {
+        page: 1,
+        limit: 2000,
+        type: {
+          country: ''
+        }
+      },
+      dataForm: {
+        id: undefined
+      },
+      dialogFormVisible: false,
+      submiting: false,
+      dialogStatus: '',
+      textMap: {
+        update: '编辑',
+        create: '创建'
+      },
+      rules: {
+      }
+    }
+  },
+  created() {
+    this.getList()
+  },
+  methods: {
+    handleSizeChange(val) {
+      console.log(`每页 ${val} 条`)
+      this.listQuery.limit = val
+      this.getList()
     },
-    created() {
-        this.getList()
+    handleCurrentChange(val) {
+      this.listQuery.page = val
+      console.log(`当前页: ${val}`)
+      this.getList()
     },
-    methods: {
-          handleSizeChange(val) {
-            console.log(`每页 ${val} 条`)
-            this.listQuery.limit = val
-            this.getList()
-        },
-        handleCurrentChange(val) {
-            this.listQuery.page = val
-            console.log(`当前页: ${val}`)
-            this.getList()
-        },
-        handleSelectionChange(val) {
-            this.modification = val
-        },
-        selectInit(row) {
-            return true
-        },
-        async exportlist() {
-            if (this.modification.length == 0) {
-                this.$message.warning('请选择要导出的条目!')
-            } else {
-                console.log('导出数据', this.modification)
-                let _data = {
-                    collectionPaymentTiDTOList: this.modification,
-                }
-                const {
-                    data
-                } = await exportXlsx(_data).then((response) => {
-                    this.download(response.data.data)
-                    //   downloadFile({
-                    //     res: data,
-                    //     fileName: `${
-                    //     this.date.year + (this.date.month ? `-${this.date.month}` : '')
-                    //     }提款信息`,
-                    //     type: 'xls',
-                    //     })
-
-                    if (response.status == '200') {
-
-                    }
-                })
-
+    handleSelectionChange(val) {
+      this.modification = val
+    },
+    selectInit(row) {
+      return true
+    },
+    async exportlist() {
+      if (this.modification.length == 0) {
+        this.$message.warning('请选择要导出的条目!')
+      } else {
+        console.log('导出数据', this.modification)
+        const _data = {
+          collectionPaymentTiDTOList: this.modification
+        }
+        const {
+          data
+        } = await exportXlsx(_data).then((response) => {
+          this.download(response.data.data)
+          //   downloadFile({
+          //     res: data,
+          //     fileName: `${
+          //     this.date.year + (this.date.month ? `-${this.date.month}` : '')
+          //     }提款信息`,
+          //     type: 'xls',
+          //     })
+
+          if (response.status == '200') {
+
+          }
+        })
+      }
+    },
+    importClick(file, fileList) {
+      this.fileTemp = file.raw
+      const fileName = file.raw.name
+      const fileType = fileName.substring(fileName.lastIndexOf('.') + 1)
+      // 判断上传文件格式
+      if (this.fileTemp) {
+        if (fileType == 'xlsx' || fileType == 'xls') {
+          this.importf(this.fileTemp)
+        } else {
+          this.$message({
+            type: 'warning',
+            message: '附件格式错误,请删除后重新上传!'
+          })
+        }
+      } else {
+        this.$message({
+          type: 'warning',
+          message: '请上传附件!'
+        })
+      }
+    },
+    importf(obj) {
+      this.excelFreightspace = []
+      // this.dialogVisible = true;
+      const _this = this
+      const inputDOM = this.$refs.inputer // 通过DOM取文件数据
+      this.file = event.currentTarget.files[0]
+      var rABS = false // 是否将文件读取为二进制字符串
+      var f = this.file
+      var reader = new FileReader()
+      // if (!FileReader.prototype.readAsBinaryString) {
+      FileReader.prototype.readAsBinaryString = function (f) {
+        var binary = ''
+        var rABS = false // 是否将文件读取为二进制字符串
+        var pt = this
+        var wb // 读取完成的数据
+        var outdata
+        var reader = new FileReader()
+        reader.onload = function (e) {
+          var bytes = new Uint8Array(reader.result)
+          var length = bytes.byteLength
+          for (var i = 0; i < length; i++) {
+            binary += String.fromCharCode(bytes[i])
+          }
+          var XLSX = require('xlsx')
+          if (rABS) {
+            wb = XLSX.read(btoa(fixdata(binary)), { // 手动转化
+              type: 'base64',
+              cellDates: true
+            })
+          } else {
+            wb = XLSX.read(binary, {
+              type: 'binary'
+            })
+          }
+          // outdata就是你想要的东西 excel导入的数据
+          outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]])
+          // excel 数据再处理
+          const arr = []
+          outdata.map(v => {
+            // let jsonString = JSON.stringify(v).replace(/\*/g, '').replace(/\s/ig,'');
+            const jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '')
+            v = JSON.parse(jsonString)
+            const obj = {}
+
+            // xxx代表列名
+            obj.receiptPaymentDate = v.提款日期
+            obj.receivingWithdrawingRegion = v.提款地
+            obj.receivingWithdrawingPeople = v.提款人
+            obj.deductionEuro = v.金额EUR
+            obj.deductionRmb = v.金额RMB
+            obj.businessType = 2
+            obj.remarks = v.备注1
+            obj.remark = v.备注2
+            obj.updatePeople = _this.$store.getters.name
+            if (!obj.deductionEuro) {
+              obj.deductionEuro = 0
             }
-
-
-
-
-
-
-
-
-
-        },
-        importClick(file, fileList) {
-            this.fileTemp = file.raw
-            let fileName = file.raw.name
-            let fileType = fileName.substring(fileName.lastIndexOf('.') + 1)
-            // 判断上传文件格式
-            if (this.fileTemp) {
-                if (fileType == 'xlsx' || fileType == 'xls') {
-                    this.importf(this.fileTemp)
-                } else {
-                    this.$message({
-                        type: 'warning',
-                        message: '附件格式错误,请删除后重新上传!',
-                    })
-                }
-            } else {
-                this.$message({
-                    type: 'warning',
-                    message: '请上传附件!',
-                })
+            if (!obj.deductionRmb) {
+              obj.deductionRmb = 0
             }
-        },
-        importf(obj) {
-            this.excelFreightspace = []
-            // this.dialogVisible = true;
-            let _this = this;
-            let inputDOM = this.$refs.inputer; // 通过DOM取文件数据
-            this.file = event.currentTarget.files[0];
-            var rABS = false; //是否将文件读取为二进制字符串
-            var f = this.file;
-            var reader = new FileReader();
-            //if (!FileReader.prototype.readAsBinaryString) {
-            FileReader.prototype.readAsBinaryString = function (f) {
-                var binary = '';
-                var rABS = false; //是否将文件读取为二进制字符串
-                var pt = this;
-                var wb; //读取完成的数据
-                var outdata;
-                var reader = new FileReader();
-                reader.onload = function (e) {
-                    var bytes = new Uint8Array(reader.result);
-                    var length = bytes.byteLength;
-                    for (var i = 0; i < length; i++) {
-                        binary += String.fromCharCode(bytes[i]);
-                    }
-                    var XLSX = require('xlsx');
-                    if (rABS) {
-                        wb = XLSX.read(btoa(fixdata(binary)), { //手动转化
-                            type: 'base64',
-                            cellDates: true
-                        });
-                    } else {
-                        wb = XLSX.read(binary, {
-                            type: 'binary'
-                        });
-                    }
-                    // outdata就是你想要的东西 excel导入的数据
-                    outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]]);
-                    // excel 数据再处理
-                    let arr = []
-                    outdata.map(v => {
-                        // let jsonString = JSON.stringify(v).replace(/\*/g, '').replace(/\s/ig,'');
-                        let jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '');
-                        v = JSON.parse(jsonString);
-                        let obj = {}
-
-                        //xxx代表列名
-                        obj.receiptPaymentDate = v.提款日期
-                        obj.receivingWithdrawingRegion = v.提款地
-                        obj.receivingWithdrawingPeople = v.提款人
-                        obj.deductionEuro = v.金额EUR
-                        obj.deductionRmb = v.金额RMB
-                        obj.businessType = 2
-                        obj.remarks = v.备注1
-                        obj.remark = v.备注2
-                        obj.updatePeople = _this.$store.getters.name
-                        if (!obj.deductionEuro) {
-                            obj.deductionEuro = 0
-                        }
-                        if (!obj.deductionRmb) {
-                            obj.deductionRmb = 0
-                        }
-                        for (let i = 0; i < _this.placeList.length; i++) {
-                            _this.countryList.push(_this.placeList[i].country)
-                        }
-                        if (!_this.countryList.includes(obj.receivingWithdrawingRegion)) {
-                            _this.isAllowExport = false
-                            _this.$notify({
-                                title: '失败',
-                                message: '导入失败,导入数据中收款地在系统中不存在,请重新编辑',
-                                type: 'error'
-                            });
-                            return
-                        } else {
-                            _this.excelFreightspace.push(obj)
-                            _this.isAllowExport = true
-                        }
-                    })
-                    if (_this.excelFreightspace && _this.isAllowExport) {
-                        importWord(_this.excelFreightspace).then((response) => {
-
-                            if (response.status == '200') {
-                                _this.$notify({
-                                    title: '成功',
-                                    message: '导入成功',
-                                    type: 'success'
-                                });
-                                _this.getList()
-                            }
-                        })
-
-                    }
-                }
-                reader.readAsArrayBuffer(f);
+            for (let i = 0; i < _this.placeList.length; i++) {
+              _this.countryList.push(_this.placeList[i].country)
             }
-            if (rABS) {
-                reader.readAsArrayBuffer(f);
+            if (!_this.countryList.includes(obj.receivingWithdrawingRegion)) {
+              _this.isAllowExport = false
+              _this.$notify({
+                title: '失败',
+                message: '导入失败,导入数据中收款地在系统中不存在,请重新编辑',
+                type: 'error'
+              })
+              return
             } else {
-                reader.readAsBinaryString(f);
+              _this.excelFreightspace.push(obj)
+              _this.isAllowExport = true
             }
-
-        },
-        formatDate(numb, format) {
-            const old = numb - 1;
-            const t = Math.round((old - Math.floor(old)) * 24 * 60 * 60);
-            const time = new Date(1900, 0, old, 0, 0, t)
-            const year = time.getFullYear();
-            const month = time.getMonth() + 1;
-            const date = time.getDate();
-            return year + format + (month < 10 ? '0' + month : month) + format + (date < 10 ? '0' + date : date) + ' 00:00:00'
-        },
-        getSummaries(param) {
-
-            const { columns, data } = param;
-            const sums = [];
-            columns.forEach((column, index) => {
-                if (index === 0) {
-                    sums[index] = "合计";
-                    return;
-                } else if (index == 5 || index == 6) {
-                    const values = data.map((item) => Number(item[column.property]));
-                    if (!values.every((value) => isNaN(value))) {
-                        sums[index] = values.reduce((prev, curr) => {
-                            const value = Number(curr);
-                            if (!isNaN(value)) {
-                                return prev + curr;
-                            } else {
-                                return prev;
-                            }
-                        }, 0);
-                        sums[index] += "";
-                    } else {
-                        sums[index] = "--";
-                    }
-                } else {
-                    // sums[index] = "--";
-                }
-            });
-
-            return sums;
-
-        },
-        getList() {
-
-            console.log(this.selectDate)
-            listCountry(this.listPlace).then(response => {
-                this.placeList = response.data.data.items
-            })
-                .catch(() => {
-                    this.placeList = []
+          })
+          if (_this.excelFreightspace && _this.isAllowExport) {
+            importWord(_this.excelFreightspace).then((response) => {
+              if (response.status == '200') {
+                _this.$notify({
+                  title: '成功',
+                  message: '导入成功',
+                  type: 'success'
                 })
-            this.listLoading = true
-            console.log(this.selectDate)
-            if (this.selectDate&&this.selectDate.length > 0) {
-
-                this.listQuery.type.startDate = dayjs(this.selectDate[0]).format('YYYY-MM-DD')
-                this.listQuery.type.endDate = dayjs(this.selectDate[1]).format('YYYY-MM-DD')
-            }else{
-                 this.listQuery.type.startDate = ""
-                this.listQuery.type.endDate = ""
-            }
-
-            listCollectionPayment(this.listQuery).then(response => {
-                this.list = response.data.data.items
-                this.total = response.data.data.total
-                this.listLoading = false
+                _this.getList()
+              }
             })
-                .catch(() => {
-                    this.list = []
-                    this.total = 0
-                    this.listLoading = false
-                })
-        },
-        handleFilter() {
-            this.listQuery.page = 1
-            this.getList()
-        },
-        resetForm() {
-            this.dataForm = {
-                id: undefined
-            }
-        },
-        handleCreate() {
-            this.resetForm()
-            this.dialogStatus = 'create'
-            this.dialogFormVisible = true
-            this.$nextTick(() => {
-                this.$refs['dataForm'].clearValidate()
-            })
-        },
-        createData() {
-            this.$refs['dataForm'].validate(valid => {
-                if (valid) {
-                    this.submiting = true
-                    this.dataForm.businessType = 2
-                    this.dataForm.updatePeople = this.$store.getters.name
-                    if (!this.dataForm.deductionEuro) {
-                        this.dataForm.deductionEuro = 0
-                    }
-                    if (!this.dataForm.deductionRmb) {
-                        this.dataForm.deductionRmb = 0
-                    }
-                    createCollectionPayment(this.dataForm).then(response => {
-                        this.list.unshift(response.data.data)
-                        this.dialogFormVisible = false
-                        this.$notify.success({
-                            title: '成功',
-                            message: '添加成功'
-                        })
-                        this.submiting = false
-                    })
-                        .catch(response => {
-                            this.$notify.error({
-                                title: '失败',
-                                message: response.data.errmsg
-                            })
-                            this.submiting = false
-                        })
-                }
-            })
-        },
-        handleUpdate(row) {
-            this.dataForm = Object.assign({}, row)
-            this.dialogStatus = 'update'
-            this.dialogFormVisible = true
-            this.$nextTick(() => {
-                this.$refs['dataForm'].clearValidate()
+          }
+        }
+        reader.readAsArrayBuffer(f)
+      }
+      if (rABS) {
+        reader.readAsArrayBuffer(f)
+      } else {
+        reader.readAsBinaryString(f)
+      }
+    },
+    formatDate(numb, format) {
+      const old = numb - 1
+      const t = Math.round((old - Math.floor(old)) * 24 * 60 * 60)
+      const time = new Date(1900, 0, old, 0, 0, t)
+      const year = time.getFullYear()
+      const month = time.getMonth() + 1
+      const date = time.getDate()
+      return year + format + (month < 10 ? '0' + month : month) + format + (date < 10 ? '0' + date : date) + ' 00:00:00'
+    },
+    getSummaries(param) {
+      const { columns, data } = param
+      const sums = []
+      columns.forEach((column, index) => {
+        if (index === 0) {
+          sums[index] = '合计'
+          return
+        } else if (index == 5 || index == 6) {
+          const values = data.map((item) => Number(item[column.property]))
+          if (!values.every((value) => isNaN(value))) {
+            sums[index] = values.reduce((prev, curr) => {
+              const value = Number(curr)
+              if (!isNaN(value)) {
+                return prev + curr
+              } else {
+                return prev
+              }
+            }, 0)
+            sums[index] += ''
+          } else {
+            sums[index] = '--'
+          }
+        } else {
+          // sums[index] = "--";
+        }
+      })
+
+      return sums
+    },
+    getList() {
+      console.log(this.selectDate)
+      listCountry(this.listPlace).then(response => {
+        this.placeList = response.data.data.items
+      })
+        .catch(() => {
+          this.placeList = []
+        })
+      this.listLoading = true
+      console.log(this.selectDate)
+      if (this.selectDate&&this.selectDate.length > 0) {
+        this.listQuery.type.startDate = dayjs(this.selectDate[0]).format('YYYY-MM-DD')
+        this.listQuery.type.endDate = dayjs(this.selectDate[1]).format('YYYY-MM-DD')
+      } else {
+        this.listQuery.type.startDate = ''
+        this.listQuery.type.endDate = ''
+      }
+
+      listCollectionPayment(this.listQuery).then(response => {
+        this.list = response.data.data.items
+        this.total = response.data.data.total
+        this.listLoading = false
+      })
+        .catch(() => {
+          this.list = []
+          this.total = 0
+          this.listLoading = false
+        })
+    },
+    handleFilter() {
+      this.listQuery.page = 1
+      this.getList()
+    },
+    resetForm() {
+      this.dataForm = {
+        id: undefined
+      }
+    },
+    handleCreate() {
+      this.resetForm()
+      this.dialogStatus = 'create'
+      this.dialogFormVisible = true
+      this.$nextTick(() => {
+        this.$refs['dataForm'].clearValidate()
+      })
+    },
+    createData() {
+      this.$refs['dataForm'].validate(valid => {
+        if (valid) {
+          this.submiting = true
+          this.dataForm.businessType = 2
+          this.dataForm.updatePeople = this.$store.getters.name
+          if (!this.dataForm.deductionEuro) {
+            this.dataForm.deductionEuro = 0
+          }
+          if (!this.dataForm.deductionRmb) {
+            this.dataForm.deductionRmb = 0
+          }
+          createCollectionPayment(this.dataForm).then(response => {
+            this.list.unshift(response.data.data)
+            this.dialogFormVisible = false
+            this.$notify.success({
+              title: '成功',
+              message: '添加成功'
             })
-        },
-        updateData() {
-            this.$refs['dataForm'].validate(valid => {
-                if (valid) {
-                    this.submiting = true
-                    this.dataForm.updatePeople = this.$store.getters.name
-                    updateCollectionPayment(this.dataForm).then(() => {
-                        for (const v of this.list) {
-                            if (v.id === this.dataForm.id) {
-                                const index = this.list.indexOf(v)
-                                this.list.splice(index, 1, this.dataForm)
-                                break
-                            }
-                        }
-                        this.dialogFormVisible = false
-                        this.submiting = false
-                        this.$notify.success({
-                            title: '成功',
-                            message: '更新成功'
-                        })
-                    })
-                        .catch(response => {
-                            this.$notify.error({
-                                title: '失败',
-                                message: response.data.errmsg
-                            })
-                            this.submiting = false
-                        })
-                }
+            this.submiting = false
+          })
+            .catch(response => {
+              this.$notify.error({
+                title: '失败',
+                message: response.data.errmsg
+              })
+              this.submiting = false
             })
-        },
-        updateData1(row) {
-            this.dataForm.flag = 1
-            this.dataForm.id = row.id
-            updateCollectionPayment(this.dataForm).then(() => {
-
-                this.submiting = false
-                this.$notify.success({
-                    title: '成功',
-                    message: '更新成功',
-                })
-                this.getList()
+        }
+      })
+    },
+    handleUpdate(row) {
+      this.dataForm = Object.assign({}, row)
+      this.dialogStatus = 'update'
+      this.dialogFormVisible = true
+      this.$nextTick(() => {
+        this.$refs['dataForm'].clearValidate()
+      })
+    },
+    updateData() {
+      this.$refs['dataForm'].validate(valid => {
+        if (valid) {
+          this.submiting = true
+          this.dataForm.updatePeople = this.$store.getters.name
+          updateCollectionPayment(this.dataForm).then(() => {
+            for (const v of this.list) {
+              if (v.id === this.dataForm.id) {
+                const index = this.list.indexOf(v)
+                this.list.splice(index, 1, this.dataForm)
+                break
+              }
+            }
+            this.dialogFormVisible = false
+            this.submiting = false
+            this.$notify.success({
+              title: '成功',
+              message: '更新成功'
             })
-                .catch(response => {
-                    this.$notify.error({
-                        title: '失败',
-                        message: response.data.errmsg
-                    })
-                    this.submiting = false
-                })
-
-        },
-        handleDelete(row) {
-            this.$confirm('此操作将永久删除该记录---' + row.id + '---, 是否继续?', '提示', {
-                confirmButtonText: '确定',
-                cancelButtonText: '取消',
-                type: 'warning'
-            }).then(() => {
-                deleteCollectionPayment(row.id).then(response => {
-                    this.$notify.success({
-                        title: '成功',
-                        message: '删除成功'
-                    })
-                    const index = this.list.indexOf(row)
-                    this.list.splice(index, 1)
-                })
-                    .catch(response => {
-                        this.$notify.error({
-                            title: '失败',
-                            message: response.data.errmsg
-                        })
-                    })
-            }).catch(() => {
-                return false
+          })
+            .catch(response => {
+              this.$notify.error({
+                title: '失败',
+                message: response.data.errmsg
+              })
+              this.submiting = false
             })
         }
+      })
+    },
+    updateData1(row) {
+      this.dataForm.flag = 1
+      this.dataForm.id = row.id
+      updateCollectionPayment(this.dataForm).then(() => {
+        this.submiting = false
+        this.$notify.success({
+          title: '成功',
+          message: '更新成功'
+        })
+        this.getList()
+      })
+        .catch(response => {
+          this.$notify.error({
+            title: '失败',
+            message: response.data.errmsg
+          })
+          this.submiting = false
+        })
+    },
+    handleDelete(row) {
+      this.$confirm('此操作将永久删除该记录---' + row.id + '---, 是否继续?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      }).then(() => {
+        deleteCollectionPayment(row.id).then(response => {
+          this.$notify.success({
+            title: '成功',
+            message: '删除成功'
+          })
+          const index = this.list.indexOf(row)
+          this.list.splice(index, 1)
+        })
+          .catch(response => {
+            this.$notify.error({
+              title: '失败',
+              message: response.data.errmsg
+            })
+          })
+      }).catch(() => {
+        return false
+      })
     }
+  }
 }
 </script>
 <style>

+ 140 - 5
unimall-admin/src/views/customerBilling/customerBillingInfo.vue

@@ -8,7 +8,14 @@
         size="small"
         style="width: 200px;"
         placeholder="请输入编号" />
-      <el-select v-model="listQuery.type.status" size="small" placeholder="请选择收款状态">
+      <el-input
+        v-model="listQuery.type.customer"
+        clearable
+        class="filter-item"
+        size="small"
+        style="width: 200px;"
+        placeholder="请输入客户" />
+      <el-select v-model="listQuery.type.status" size="small" clearable placeholder="请选择收款状态">
         <el-option
           v-for="item in skList"
           :label="item.label"
@@ -52,7 +59,19 @@
         size="mini"
         icon="el-icon-edit"
         @click="exportlist">导出</el-button>
-
+      <el-upload
+        :on-change="importClick"
+        :show-file-list="false"
+        :auto-upload="false"
+        style="margin-left: 8px;margin-bottom:0"
+        class="filter-item"
+        action=""
+        accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel">
+        <el-button
+          class="filter-item"
+          type="primary"
+          icon="el-icon-edit">导入</el-button>
+      </el-upload>
     </div>
 
     <el-table
@@ -81,8 +100,8 @@
           {{ scope.row.businessType==1?'正常单据':'结转单据' }}
         </template>
       </el-table-column>
-      <el-table-column align="center" label="结账日期" prop="closingDate" />
-      <el-table-column align="center" label="付金额" prop="amountIng" />
+      <el-table-column align="center" label="装车日期" prop="closingDate" />
+      <el-table-column align="center" label="付金额" prop="amountIng" />
       <el-table-column align="center" label="已付金额" prop="amountPaid" />
       <el-table-column align="center" label="未付金额" prop="unpaidAmount" />
       <el-table-column align="center" label="备注1" prop="remarks" />
@@ -148,7 +167,7 @@
         <el-form-item label="单据类型" prop="businessType">
           <el-input v-model="dataForm.businessType" />
         </el-form-item>
-        <el-form-item label="结账日期" prop="closingDate">
+        <el-form-item label="装车日期" prop="closingDate">
           <el-input v-model="dataForm.closingDate" />
         </el-form-item>
         <el-form-item label="已付金额" prop="amountPaid">
@@ -179,6 +198,7 @@
 
 <script>
 import {
+  importWord,
   listCustomerBillingInfo,
   createCustomerBillingInfo,
   updateCustomerBillingInfo,
@@ -191,6 +211,16 @@ export default {
   components: { Pagination },
   data() {
     return {
+      khList: [
+        {
+          value: '小李',
+          label: '小李'
+        },
+        {
+          value: '小李',
+          label: '小张'
+        }
+      ],
       skList: [
         {
           value: 1,
@@ -244,6 +274,111 @@ export default {
     this.currentPage = 1
   },
   methods: {
+    importClick(file, fileList) {
+      this.fileTemp = file.raw
+      const fileName = file.raw.name
+      const fileType = fileName.substring(fileName.lastIndexOf('.') + 1)
+      // 判断上传文件格式
+      if (this.fileTemp) {
+        if (fileType == 'xlsx' || fileType == 'xls') {
+          this.importf(this.fileTemp)
+        } else {
+          this.$message({
+            type: 'warning',
+            message: '附件格式错误,请删除后重新上传!'
+          })
+        }
+      } else {
+        this.$message({
+          type: 'warning',
+          message: '请上传附件!'
+        })
+      }
+    },
+    importf(obj) {
+      this.excelFreightspace = []
+      // this.dialogVisible = true;
+      const _this = this
+      const inputDOM = this.$refs.inputer // 通过DOM取文件数据
+      this.file = event.currentTarget.files[0]
+      var rABS = false // 是否将文件读取为二进制字符串
+      var f = this.file
+      var reader = new FileReader()
+      // if (!FileReader.prototype.readAsBinaryString) {
+      FileReader.prototype.readAsBinaryString = function (f) {
+        var binary = ''
+        var rABS = false // 是否将文件读取为二进制字符串
+        var pt = this
+        var wb // 读取完成的数据
+        var outdata
+        var reader = new FileReader()
+        reader.onload = function (e) {
+          var bytes = new Uint8Array(reader.result)
+          var length = bytes.byteLength
+          for (var i = 0; i < length; i++) {
+            binary += String.fromCharCode(bytes[i])
+          }
+          var XLSX = require('xlsx')
+          if (rABS) {
+            wb = XLSX.read(btoa(fixdata(binary)), { // 手动转化
+              type: 'base64',
+              cellDates: true
+            })
+          } else {
+            wb = XLSX.read(binary, {
+              type: 'binary'
+            })
+          }
+          // outdata就是你想要的东西 excel导入的数据
+          outdata = XLSX.utils.sheet_to_json(wb.Sheets[wb.SheetNames[0]])
+          // excel 数据再处理
+          const arr = []
+          outdata.map(v => {
+            // let jsonString = JSON.stringify(v).replace(/\*/g, '').replace(/\s/ig,'');
+            const jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '')
+            v = JSON.parse(jsonString)
+            const obj = {}
+            // xxx代表列名
+            obj.cabinetNo = v.柜号
+            obj.customer = v.客户
+            obj.arrivalDate = v.到港日期
+            obj.closingDate = v.装车日期
+            obj.deliveryPlace = v.目的地
+            obj.product = v.货品
+            obj.clearanceFee = v.清关费
+            obj.clearanceCost = v.清关成本
+            obj.truck = v.卡车费
+            obj.truckCost = v.卡车成本
+            obj.otherExpenses = v.其他费用
+            obj.otherCost = v.其他成本
+            obj.pricePayable = v.合计应收
+            obj.cost = v.合计成本
+            obj.sendComp = v.发货公司
+            obj.carTeam = v.车队
+
+            _this.excelFreightspace.push(obj)
+          })
+          if (_this.excelFreightspace) {
+            importWord(_this.excelFreightspace).then((response) => {
+              if (response.status == '200') {
+                _this.$notify({
+                  title: '成功',
+                  message: '导入成功',
+                  type: 'success'
+                })
+                _this.getList()
+              }
+            })
+          }
+        }
+        reader.readAsArrayBuffer(f)
+      }
+      if (rABS) {
+        reader.readAsArrayBuffer(f)
+      } else {
+        reader.readAsBinaryString(f)
+      }
+    },
     async exportlist() {
       if (this.modification.length == 0) {
         this.$message.warning('请选择要导出的条目!')

+ 55 - 41
unimall-admin/src/views/customerBilling/customerBillingInfoadd.vue

@@ -27,11 +27,12 @@
           <el-input v-model="dataForm.payNo" class="input-width" />
         </el-form-item>
         <el-form-item label="客户:" prop="customer" style="margin-right:50px">
-          <el-input v-model="dataForm.customer" class="input-width" />
+          <el-input v-model="dataForm.customer" :disabled="isJz" class="input-width"/>
         </el-form-item>
         <el-form-item label="单据类型:" prop="businessType" style="margin-right:50px">
           <el-select
             v-model="dataForm.businessType"
+            clearable
             placeholder="请选择单据类型"
             class="input-width"
             @change="changeBusinessType"
@@ -44,23 +45,23 @@
             />
           </el-select>
         </el-form-item>
-
-        <el-form-item label="结账日期" prop="closingDate" style="margin-right:50px">
+        <el-form-item label="装车日期" prop="closingDate" style="margin-right:50px">
           <el-date-picker
             v-model="dataForm.closingDate"
+            :disabled="isJz"
             type="date"
             value-format="yyyy-MM-dd"
             style="width:200px"
           />
         </el-form-item>
         <el-form-item label="应付金额:" prop="amountIng" style="margin-right:50px">
-          <el-input v-model="dataForm.amountIng" class="input-width" />
+          <el-input v-model="dataForm.amountIng" class="input-width" @input="priceChange"/>
         </el-form-item>
         <el-form-item label="已付金额:" prop="amountPaid" style="margin-right:50px">
-          <el-input v-model="dataForm.amountPaid" class="input-width" />
+          <el-input v-model="dataForm.amountPaid" class="input-width" @input="priceChange"/>
         </el-form-item>
         <el-form-item label="未付金额:" prop="unpaidAmount" style="margin-right:50px">
-          <el-input v-model="dataForm.unpaidAmount" class="input-width" />
+          <el-input v-model="dataForm.unpaidAmount" class="input-width" disabled/>
         </el-form-item>
         <el-form-item label="备注1:" prop="remarks" style="margin-right:50px">
           <el-input v-model="dataForm.remarks" class="input-width" />
@@ -69,7 +70,7 @@
           <el-input v-model="dataForm.remark" class="input-width" />
         </el-form-item>
         <el-form-item label="状态:" prop="status" style="margin-right:50px">
-          <el-select v-model="dataForm.status" placeholder="请选择收款状态" class="input-width">
+          <el-select v-model="dataForm.status" placeholder="请选择收款状态" clearable class="input-width">
             <el-option
               v-for="item in skList"
               :label="item.label"
@@ -90,22 +91,6 @@
           style="margin-bottom:20px"
           @click="addDetail"
         >添加</el-button>
-        <el-upload
-          v-if="!isJz"
-          :on-change="importClick"
-          :show-file-list="false"
-          :auto-upload="false"
-          style="margin-left: 8px;margin-bottom:0"
-          class="filter-item"
-          action=""
-          accept=".csv, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet, application/vnd.ms-excel">
-          <el-button
-            class="filter-item"
-            type="primary"
-            size="mini"
-            icon="el-icon-edit">导入</el-button>
-        </el-upload>
-
       </div>
 
       <el-table
@@ -129,34 +114,53 @@
         </el-table-column>
         <el-table-column align="center" label="柜号" prop="cabinetNo">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.cabinetNo" />
+            <el-input v-model="scope.row.cabinetNo" :disabled="isJz"/>
           </template>
         </el-table-column>
         <el-table-column align="center" label="到港日期" prop="arrivalDate" width="170px">
           <template slot-scope="scope">
             <el-date-picker
               v-model="scope.row.arrivalDate"
+              :disabled="isJz"
               type="date"
               value-format="yyyy-MM-dd"
               style="width:140px"
             />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="送货地点" prop="deliveryPlace">
+        <el-table-column align="center" label="发货公司" prop="sendComp">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.deliveryPlace" />
+            <el-input
+              v-model="scope.row.sendComp"
+              :disabled="isJz"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="产品" prop="product">
+        <el-table-column align="center" label="车队" prop="carTeam">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.product" />
+            <el-input
+              v-model="scope.row.carTeam"
+              :disabled="isJz"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="重量" prop="weight">
+        <el-table-column align="center" label="货品" prop="product">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.weight" />
+            <el-input
+              v-model="scope.row.product"
+              :disabled="isJz"/>
+          </template>
+        </el-table-column>
+        <el-table-column align="center" label="目的地" prop="deliveryPlace">
+          <template slot-scope="scope">
+            <el-input
+              v-model="scope.row.deliveryPlace"
+              :disabled="isJz"/>
           </template>
         </el-table-column>
+        <!-- <el-table-column align="center" label="重量" prop="weight">
+          <template slot-scope="scope">
+            <el-input v-model="scope.row.weight" />
+          </template>
+        </el-table-column> -->
         <el-table-column align="center" label="清关费" prop="clearanceFee">
           <template slot-scope="scope">
             <el-input v-model="scope.row.clearanceFee" />
@@ -167,7 +171,7 @@
             <el-input v-model="scope.row.clearanceCost" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="卡车" prop="truck">
+        <el-table-column align="center" label="卡车" prop="truck">
           <template slot-scope="scope">
             <el-input v-model="scope.row.truck" />
           </template>
@@ -187,12 +191,12 @@
             <el-input v-model="scope.row.otherCost" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="应付金额" prop="pricePayable">
+        <el-table-column align="center" label="合计应收" prop="pricePayable">
           <template slot-scope="scope">
             <el-input v-model="scope.row.pricePayable" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="成本价格" prop="cost">
+        <el-table-column align="center" label="合计成本" prop="cost">
           <template slot-scope="scope">
             <el-input v-model="scope.row.cost" />
           </template>
@@ -234,8 +238,8 @@
             />
           </el-select>
         </el-form-item>
-        <el-form-item label="日期" prop>
-          <el-select v-model="jzDataForm.closingDate" placeholder="请选择日期" style="width:100%" clearable @change="getcabineNoList">
+        <el-form-item label="装车日期" prop>
+          <el-select v-model="jzDataForm.closingDate" placeholder="请选择装车日期" style="width:100%" clearable @change="getcabineNoList">
             <el-option
               v-for="(item, index) in cusDateList"
               :label="item.closingDate"
@@ -337,7 +341,10 @@ export default {
         limit: 100
       },
       dataForm: {
-        id: undefined
+        id: undefined,
+        amountPaid: '0',
+        amountIng: '0'
+
       },
       dialogFormVisible: false,
       submiting: false,
@@ -354,6 +361,11 @@ export default {
     this.list = []
   },
   methods: {
+    priceChange() {
+      if (this.dataForm.amountIng&&this.dataForm.amountPaid) {
+        this.dataForm.unpaidAmount = Number(this.dataForm.amountIng) - Number(this.dataForm.amountPaid)
+      }
+    },
     getCusDateList(val) {
       this.jzDataForm.closingDate=''
       this.jzDataForm.cabinetNo=''
@@ -383,9 +395,10 @@ export default {
       // 结转单据
 
       if (e == 2) {
-        debugger
         this.isJz = true
         this.getCustomerList()
+      } else {
+        this.isJz = false
       }
     },
     returnsales() {
@@ -407,13 +420,14 @@ export default {
           sums[index] = '合计'
           return
         } else if (
-          index == 7 ||
+          index == 9 ||
           index == 8 ||
           index == 10 ||
           index == 11 ||
           index == 12 ||
           index == 13 ||
-          index == 14
+          index == 14||
+          index == 15
         ) {
           const values = data.map(item => Number(item[column.property]))
           if (!values.every(value => isNaN(value))) {
@@ -490,6 +504,7 @@ export default {
       })
     },
     createData() {
+      this.listLoading = true
       this.$refs['dataForm'].validate(valid => {
         if (valid) {
           this.submiting = true
@@ -524,8 +539,8 @@ export default {
       })
     },
     updateData() {
-      debugger
       this.dataForm.customer = this.jzDataForm.customer
+      this.dataForm.closingDate = this.jzDataForm.closingDate
       for (let i = 0; i<this.cabinetNoList.length; i++) {
         if (this.cabinetNoList[i].cabinetNo==this.jzDataForm.cabinetNo) {
           this.list =[this.cabinetNoList[i]]
@@ -602,7 +617,6 @@ export default {
             const jsonString = JSON.stringify(v).replace(/\//g, '').replace(/\s/ig, '')
             v = JSON.parse(jsonString)
             const obj = {}
-            debugger
             // xxx代表列名
             obj.cabinetNo = v.柜号
             obj.arrivalDate = v.到港日期

+ 42 - 25
unimall-admin/src/views/customerBilling/customerBillingInfoedit.vue

@@ -24,13 +24,13 @@
           <el-input v-model="dataForm.id"/>
         </el-form-item>
         <el-form-item label="编号:" prop="payNo" style="margin-right:50px">
-          <el-input v-model="dataForm.payNo" class="input-width" disabled="true"/>
+          <el-input v-model="dataForm.payNo" :disabled="true" class="input-width"/>
         </el-form-item>
         <el-form-item label="客户:" prop="customer" style="margin-right:50px">
-          <el-input v-model="dataForm.customer" class="input-width" disabled="true"/>
+          <el-input v-model="dataForm.customer" :disabled="true" class="input-width"/>
         </el-form-item>
         <el-form-item label="单据类型:" prop="businessType" style="margin-right:50px">
-          <el-select v-model="dataForm.businessType" placeholder="请选择单据类型" class="input-width" disabled="true">
+          <el-select v-model="dataForm.businessType" :disabled="true" placeholder="请选择单据类型" clearable class="input-width">
             <el-option
               v-for="item in djList"
               :label="item.label"
@@ -40,7 +40,7 @@
           </el-select>
         </el-form-item>
 
-        <el-form-item label="结账日期" prop="closingDate" style="margin-right:50px">
+        <el-form-item label="装车日期" prop="closingDate" style="margin-right:50px">
           <el-date-picker
             v-model="dataForm.closingDate"
             type="date"
@@ -49,13 +49,13 @@
           />
         </el-form-item>
         <el-form-item label="应付金额:" prop="amountIng" style="margin-right:50px">
-          <el-input v-model="dataForm.amountIng" class="input-width"/>
+          <el-input v-model="dataForm.amountIng" class="input-width" @input="priceChange"/>
         </el-form-item>
         <el-form-item label="已付金额:" prop="amountPaid" style="margin-right:50px">
-          <el-input v-model="dataForm.amountPaid" class="input-width"/>
+          <el-input v-model="dataForm.amountPaid" class="input-width" @input="priceChange"/>
         </el-form-item>
         <el-form-item label="未付金额:" prop="unpaidAmount" style="margin-right:50px">
-          <el-input v-model="dataForm.unpaidAmount" class="input-width"/>
+          <el-input v-model="dataForm.unpaidAmount" :disabled="true" class="input-width"/>
         </el-form-item>
         <el-form-item label="备注1:" prop="remarks" style="margin-right:50px">
           <el-input v-model="dataForm.remarks" class="input-width"/>
@@ -64,7 +64,7 @@
           <el-input v-model="dataForm.remark" class="input-width"/>
         </el-form-item>
         <el-form-item label="状态:" prop="status" style="margin-right:50px">
-          <el-select v-model="dataForm.status" placeholder="请选择收款状态" class="input-width">
+          <el-select v-model="dataForm.status" clearable placeholder="请选择收款状态" class="input-width">
             <el-option
               v-for="item in skList"
               :label="item.label"
@@ -75,7 +75,7 @@
         </el-form-item>
       </div>
       <div class="small-title" style="font-size: 16px">详情</div>
-      <el-button style="margin-bottom:20px" @click="addDetail">添加</el-button>
+      <!-- <el-button style="margin-bottom:20px" @click="addDetail">添加</el-button> -->
 
       <el-table
         v-loading="listLoading"
@@ -111,19 +111,28 @@
             />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="送货地点" prop="deliveryPlace">
+        <el-table-column align="center" label="发货公司" prop="sendComp">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.deliveryPlace" />
+            <el-input
+              v-model="scope.row.sendComp"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="产品" prop="product">
+        <el-table-column align="center" label="车队" prop="carTeam">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.product" />
+            <el-input
+              v-model="scope.row.carTeam"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="重量" prop="weight">
+        <el-table-column align="center" label="货品" prop="product">
           <template slot-scope="scope">
-            <el-input v-model="scope.row.weight" />
+            <el-input
+              v-model="scope.row.product"/>
+          </template>
+        </el-table-column>
+        <el-table-column align="center" label="目的地" prop="deliveryPlace">
+          <template slot-scope="scope">
+            <el-input
+              v-model="scope.row.deliveryPlace"/>
           </template>
         </el-table-column>
         <el-table-column align="center" label="清关费" prop="clearanceFee">
@@ -136,7 +145,7 @@
             <el-input v-model="scope.row.clearanceCost" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="卡车" prop="truck">
+        <el-table-column align="center" label="卡车" prop="truck">
           <template slot-scope="scope">
             <el-input v-model="scope.row.truck" />
           </template>
@@ -156,12 +165,12 @@
             <el-input v-model="scope.row.otherCost" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="应付金额" prop="pricePayable">
+        <el-table-column align="center" label="合计应收" prop="pricePayable">
           <template slot-scope="scope">
             <el-input v-model="scope.row.pricePayable" />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="成本价格" prop="cost">
+        <el-table-column align="center" label="合计成本" prop="cost">
           <template slot-scope="scope">
             <el-input v-model="scope.row.cost" />
           </template>
@@ -250,7 +259,9 @@ export default {
         limit: 100
       },
       dataForm: {
-        id: undefined
+        id: undefined,
+        amountPaid: '0',
+        amountIng: '0'
       },
       dialogFormVisible: false,
       submiting: false,
@@ -262,16 +273,20 @@ export default {
       rules: {}
     }
   },
-  created() { debugger
+  created() {
     this.listQuery.id = this.$route.query.id
     this.getList()
   },
   methods: {
+    priceChange() {
+      if (this.dataForm.amountIng&&this.dataForm.amountPaid) {
+        this.dataForm.unpaidAmount = Number(this.dataForm.amountIng) - Number(this.dataForm.amountPaid)
+      }
+    },
     getList() {
       this.listLoading = true
       listCustomerBillingDetail(this.listQuery)
         .then(response => {
-          debugger
           this.dataForm = response.data.data
           this.list = response.data.data.customerBillingDetailDOList
           this.total = response.data.data.total
@@ -302,13 +317,14 @@ export default {
           sums[index] = '合计'
           return
         } else if (
-          index == 7 ||
+          index == 9 ||
           index == 8 ||
           index == 10 ||
           index == 11 ||
-          index == 12||
-           index == 13||
-            index == 14
+          index == 12 ||
+          index == 13 ||
+          index == 14||
+          index == 15
         ) {
           const values = data.map(item => Number(item[column.property]))
           if (!values.every(value => isNaN(value))) {
@@ -370,6 +386,7 @@ export default {
       })
     },
     editData() {
+      this.listLoading = true
       this.$refs['dataForm'].validate(valid => {
         if (valid) {
           this.submiting = true

+ 30 - 16
unimall-admin/src/views/customerBilling/customerBillingInfolook.vue

@@ -33,6 +33,7 @@
           <el-select
             v-model="dataForm.businessType"
             :disabled="true"
+            clearable
             placeholder="请选择单据类型"
             class="input-width">
             <el-option
@@ -44,7 +45,7 @@
           </el-select>
         </el-form-item>
 
-        <el-form-item :disabled="true" label="结账日期" prop="closingDate" style="margin-right:50px">
+        <el-form-item :disabled="true" label="装车日期" prop="closingDate" style="margin-right:50px">
           <el-date-picker
             v-model="dataForm.closingDate"
             :disabled="true"
@@ -69,7 +70,7 @@
           <el-input v-model="dataForm.remark" :disabled="true" class="input-width"/>
         </el-form-item>
         <el-form-item label="状态:" prop="status" style="margin-right:50px">
-          <el-select v-model="dataForm.status" :disabled="true" placeholder="请选择收款状态" class="input-width">
+          <el-select v-model="dataForm.status" :disabled="true" clearable placeholder="请选择收款状态" class="input-width">
             <el-option
               v-for="item in skList"
               :label="item.label"
@@ -119,27 +120,41 @@
             />
           </template>
         </el-table-column>
-        <el-table-column align="center" label="送货地点" prop="deliveryPlace">
+        <el-table-column align="center" label="发货公司" prop="sendComp">
           <template slot-scope="scope">
             <el-input
-              v-model="scope.row.deliveryPlace"
+              v-model="scope.row.sendComp"
+              :disabled="true"/>
+          </template>
+        </el-table-column>
+        <el-table-column align="center" label="车队" prop="carTeam">
+          <template slot-scope="scope">
+            <el-input
+              v-model="scope.row.carTeam"
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="产品" prop="product">
+        <el-table-column align="center" label="品" prop="product">
           <template slot-scope="scope">
             <el-input
               v-model="scope.row.product"
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="重量" prop="weight">
+        <el-table-column align="center" label="目的地" prop="deliveryPlace">
           <template slot-scope="scope">
             <el-input
-              v-model="scope.row.weight"
+              v-model="scope.row.deliveryPlace"
               :disabled="true"/>
           </template>
         </el-table-column>
+        <!-- <el-table-column align="center" label="重量" prop="weight">
+          <template slot-scope="scope">
+            <el-input
+              v-model="scope.row.weight"
+              :disabled="true"/>
+          </template>
+        </el-table-column> -->
         <el-table-column align="center" label="清关费" prop="clearanceFee">
           <template slot-scope="scope">
             <el-input
@@ -154,7 +169,7 @@
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="卡车" prop="truck">
+        <el-table-column align="center" label="卡车" prop="truck">
           <template slot-scope="scope">
             <el-input
               v-model="scope.row.truck"
@@ -182,27 +197,27 @@
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="应付金额" prop="pricePayable">
+        <el-table-column align="center" label="合计应收" prop="pricePayable">
           <template slot-scope="scope">
             <el-input
               v-model="scope.row.pricePayable"
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="成本价格" prop="cost">
+        <el-table-column align="center" label="合计成本" prop="cost">
           <template slot-scope="scope">
             <el-input
               v-model="scope.row.cost"
               :disabled="true"/>
           </template>
         </el-table-column>
-        <el-table-column align="center" label="备注1" prop="remarks">
+        <!-- <el-table-column align="center" label="备注1" prop="remarks">
           <template slot-scope="scope">
             <el-input
               v-model="scope.row.remarks"
               :disabled="true"/>
           </template>
-        </el-table-column>
+        </el-table-column> -->
         <!-- <el-table-column align="center" label="备注2" prop="remark">
           <template slot-scope="scope">
             <el-input v-model="scope.row.remark" />
@@ -298,7 +313,6 @@ export default {
     }
   },
   created() {
-    debugger
     // console.log(JSON.parse(this.$route.query.rowData))
     // this.dataForm = JSON.parse(this.$route.query.rowData)
     this.listQuery.id = this.$route.query.id
@@ -324,13 +338,14 @@ export default {
           sums[index] = '合计'
           return
         } else if (
-          index == 7 ||
+          index == 9 ||
           index == 8 ||
           index == 10 ||
           index == 11 ||
           index == 12 ||
           index == 13 ||
-          index == 14
+          index == 14||
+          index == 15
         ) {
           const values = data.map(item => Number(item[column.property]))
           if (!values.every(value => isNaN(value))) {
@@ -378,7 +393,6 @@ export default {
       this.listLoading = true
       listCustomerBillingDetail(this.listQuery)
         .then(response => {
-          debugger
           this.dataForm = response.data.data
           this.list = response.data.data.customerBillingDetailDOList
           this.total = response.data.data.total

+ 27 - 30
unimall-admin/src/views/dashboard/index.vue

@@ -1,7 +1,6 @@
 <template>
   <div class="dashboard-container">
 
-
     <div class="border">
       <div class="dashboard-text">账单总览</div>
       <div class="all">
@@ -55,11 +54,19 @@
     <div class="border">
       <div class="dashboard-text">地区账单明细</div>
       <div class="select-style">
-        <el-select v-model="dataForm.receivingWithdrawingRegion" placeholder="请选择收款地"
-          style="margin: 20px; font-size: 30px;" @change="getList1()" size="medium">
-          <el-option :label="item.country" :value="item.country" v-for="(item, index) in placeList" :key="index"
-            style="font-size: 30px;height: 50px;line-height: 50px;">
-          </el-option>
+        <el-select
+          v-model="dataForm.receivingWithdrawingRegion"
+          clearable
+          placeholder="请选择收款地"
+          style="margin: 20px; font-size: 30px;"
+          size="medium"
+          @change="getList1()">
+          <el-option
+            v-for="(item, index) in placeList"
+            :label="item.country"
+            :value="item.country"
+            :key="index"
+            style="font-size: 30px;height: 50px;line-height: 50px;"/>
         </el-select>
         <div class="all place-price">
           <div class="item">
@@ -115,7 +122,7 @@
 </template>
 
 <script>
-import { mapGetters } from "vuex";
+import { mapGetters } from 'vuex'
 import {
   listCountry
 } from '@/api/country'
@@ -123,16 +130,16 @@ import {
   getList1
 } from '@/api/country'
 export default {
-  name: "Dashboard",
+  name: 'Dashboard',
   computed: {
-    ...mapGetters(["name"]),
+    ...mapGetters(['name'])
   },
   data() {
     return {
       placeList: [],
       tjList1: {},
       tjList2: {
-        deductionRmbtj:''
+        deductionRmbtj: ''
       },
       tjList3: {},
       tjList11: {},
@@ -149,16 +156,16 @@ export default {
         }
       },
       form: {
-        name: "",
-        region: "",
-        date1: "",
-        date2: "",
+        name: '',
+        region: '',
+        date1: '',
+        date2: '',
         delivery: false,
         type: [],
-        resource: "",
-        desc: "",
-      },
-    };
+        resource: '',
+        desc: ''
+      }
+    }
   },
   created() {
     this.getList()
@@ -166,13 +173,11 @@ export default {
   methods: {
     getList1() {
       getList1(this.dataForm.receivingWithdrawingRegion).then(response => {
-
         if (response.data.errno == 200) {
           this.tjList11 = response.data.data[0]
           this.tjList22 = response.data.data[1]
           this.tjList33 = response.data.data[2]
         }
-
       })
         .catch(() => {
           this.tjList = []
@@ -180,7 +185,6 @@ export default {
     },
     getList() {
       listCountry(this.listPlace).then(response => {
-
         this.placeList = response.data.data.items
         this.dataForm.receivingWithdrawingRegion = this.placeList[0].country
         getList1().then(response => {
@@ -189,20 +193,17 @@ export default {
             this.tjList2 = response.data.data[1]
             this.tjList3 = response.data.data[2]
           }
-
         })
           .catch(() => {
             this.tjList = []
           })
 
         getList1(this.dataForm.receivingWithdrawingRegion).then(response => {
-
           if (response.data.errno == 200) {
             this.tjList11 = response.data.data[0]
             this.tjList22 = response.data.data[1]
             this.tjList33 = response.data.data[2]
           }
-
         })
           .catch(() => {
             this.tjList = []
@@ -211,12 +212,10 @@ export default {
         .catch(() => {
           this.placeList = []
         })
-
-
     }
 
-  },
-};
+  }
+}
 </script>
 
 <style lang="scss">
@@ -283,8 +282,6 @@ export default {
     font-size: 30px !important;
   }
 
-
 }
 </style>
 
-

+ 1 - 1
unimall-admin/src/views/news/news.vue

@@ -137,7 +137,7 @@
           <el-input v-model="dataForm.id" />
         </el-form-item>
         <el-form-item label="类别" prop="category">
-          <el-select v-model="dataForm.category" placeholder="请选择类别">
+          <el-select v-model="dataForm.category" clearable placeholder="请选择类别">
             <el-option
               v-for="(dict, index) in options"
               :key="index"

+ 2 - 2
unimall-admin/src/views/sys/admin.vue

@@ -81,7 +81,7 @@
           <el-input v-model="dataForm.realname" />
         </el-form-item>
         <el-form-item label="授权角色" prop="roleIds">
-          <el-select v-model="dataForm.roleIds" multiple placeholder="请选择">
+          <el-select v-model="dataForm.roleIds" clearable multiple placeholder="请选择">
             <el-option
               v-for="item in roleOptions"
               :key="item.value"
@@ -91,7 +91,7 @@
           </el-select>
         </el-form-item>
         <el-form-item label="授权库点" prop="storeIds">
-          <el-select v-model="dataForm.storeIds" style="width:200%" multiple placeholder="请选择">
+          <el-select v-model="dataForm.storeIds" style="width:200%" clearable multiple placeholder="请选择">
             <el-option
               v-for="item in storeOptions"
               :key="item.id"