|
|
@@ -1,48 +1,52 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<basic-container v-show="!detailsOpen">
|
|
|
- <avue-crud :option="option" :search.sync="search" v-model="form" :table-loading="loading" :data="dataList"
|
|
|
- ref="crud" :key="key" @on-load="onLoad" @search-change="searchChange" @row-del="rowDel"
|
|
|
- @expand-change="expandChange" @refresh-change="refreshChange"
|
|
|
+ <avue-crud
|
|
|
+ :option="option"
|
|
|
+ :search.sync="search"
|
|
|
+ v-model="form"
|
|
|
+ :table-loading="loading"
|
|
|
+ :data="dataList"
|
|
|
+ ref="crud"
|
|
|
+ :key="key"
|
|
|
+ @on-load="onLoad"
|
|
|
+ @search-change="searchChange"
|
|
|
+ @row-del="rowDel"
|
|
|
+ @expand-change="expandChange"
|
|
|
+ @refresh-change="refreshChange"
|
|
|
@resetColumn="resetColumnTwo('crud', 'option', 'optionList', 317)"
|
|
|
- @saveColumn="saveColumnTwo('crud', 'option', 'optionList', 317)" :page.sync="page">
|
|
|
+ @saveColumn="saveColumnTwo('crud', 'option', 'optionList', 317)"
|
|
|
+ :page.sync="page"
|
|
|
+ >
|
|
|
<template slot-scope="{ row }" slot="expand">
|
|
|
- <avue-crud :data="row.itemData" :option="itemOption" :table-loading="row.itemLoading" :cell-style="cellStyle"
|
|
|
- class="itemTable"></avue-crud>
|
|
|
+ <avue-crud :data="row.itemData" :option="itemOption" :table-loading="row.itemLoading" :cell-style="cellStyle" class="itemTable"></avue-crud>
|
|
|
</template>
|
|
|
- <template slot-scope="{type,size,row,index}" slot="menu">
|
|
|
+ <template slot-scope="{ type, size, row, index }" slot="menu">
|
|
|
<!-- <el-button :size="size" :type="type" @click="check(row)">查看</el-button> -->
|
|
|
- <el-button :size="size" :disabled="row.status !== '录入' && row.item >= 1" :type="type"
|
|
|
- @click="$refs.crud.rowDel(row, index)">删除</el-button>
|
|
|
-<!-- <el-button :size="size" :type="type"-->
|
|
|
-<!-- @click="deliverGoods(row)">发货</el-button>-->
|
|
|
+ <el-button :size="size" :disabled="row.status !== '录入' && row.item >= 1" :type="type" @click="$refs.crud.rowDel(row, index)"
|
|
|
+ >删除</el-button
|
|
|
+ >
|
|
|
+ <!-- <el-button :size="size" :type="type"-->
|
|
|
+ <!-- @click="deliverGoods(row)">发货</el-button>-->
|
|
|
</template>
|
|
|
<template slot="corpNameSearch">
|
|
|
<crop-select v-model="search.corpId" corpType="KH" :refresh="false"></crop-select>
|
|
|
</template>
|
|
|
- <template slot-scope="{type,size,row,$index}" slot="menuLeft">
|
|
|
- <el-button icon="el-icon-plus" type="primary" :size="size" @click="detailsOpen = true;">新建订单</el-button>
|
|
|
+ <template slot-scope="{ type, size, row, $index }" slot="menuLeft">
|
|
|
+ <el-button icon="el-icon-plus" type="primary" :size="size" @click="detailsOpen = true">新建订单</el-button>
|
|
|
<!--<el-button type="warning" icon="el-icon-download" size="small" @click="outExport">导出</el-button>-->
|
|
|
</template>
|
|
|
<template slot-scope="{ row, index }" slot="billno">
|
|
|
- <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 1)">{{ row.billno }}
|
|
|
- </span>
|
|
|
+ <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 1)">{{ row.billno }} </span>
|
|
|
</template>
|
|
|
<template slot-scope="{ row, index }" slot="ordNo">
|
|
|
- <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 2)">{{ row.ordNo }}
|
|
|
- </span>
|
|
|
+ <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 2)">{{ row.ordNo }} </span>
|
|
|
</template>
|
|
|
</avue-crud>
|
|
|
</basic-container>
|
|
|
<detailsPage ref="detailsPageRef" v-if="detailsOpen" :onLoad="form" :detailData="detailData" @backToList="backToList"></detailsPage>
|
|
|
|
|
|
- <el-dialog
|
|
|
- title="发货"
|
|
|
- :visible.sync="dialogVisible"
|
|
|
- append-to-body
|
|
|
- close-on-click-modal
|
|
|
- close-on-press-escape
|
|
|
- width="40%">
|
|
|
+ <el-dialog title="发货" :visible.sync="dialogVisible" append-to-body close-on-click-modal close-on-press-escape width="40%">
|
|
|
<div class="elForm">
|
|
|
<el-form :model="dialogForm" label-position="right">
|
|
|
<el-col :span="24">
|
|
|
@@ -58,22 +62,19 @@
|
|
|
</el-col>
|
|
|
<el-form-item label="配送方式" label-width="100px">
|
|
|
<el-select v-model="dialogForm.shipType" @change="courierTypeChange" style="width: 90%;" placeholder="请选择运输类型">
|
|
|
- <el-option
|
|
|
- v-for="item in courierTypeList"
|
|
|
- :key="item.dictKey"
|
|
|
- :label="item.dictValue"
|
|
|
- :value="item.dictValue">
|
|
|
- </el-option>
|
|
|
+ <el-option v-for="item in courierTypeList" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"> </el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="货运公司" label-width="100px">
|
|
|
- <el-select v-model="dialogForm.logisticsCorpName" filterable allow-create default-first-option style="width: 90%;" placeholder="请选择货运公司">
|
|
|
- <el-option
|
|
|
- v-for="item in courierList"
|
|
|
- :key="item.dictKey"
|
|
|
- :label="item.dictValue"
|
|
|
- :value="item.dictValue">
|
|
|
- </el-option>
|
|
|
+ <el-select
|
|
|
+ v-model="dialogForm.logisticsCorpName"
|
|
|
+ filterable
|
|
|
+ allow-create
|
|
|
+ default-first-option
|
|
|
+ style="width: 90%;"
|
|
|
+ placeholder="请选择货运公司"
|
|
|
+ >
|
|
|
+ <el-option v-for="item in courierList" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"> </el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="货运单号" label-width="100px">
|
|
|
@@ -86,14 +87,13 @@
|
|
|
<el-button size="small" type="primary" @click="confirmShipment">确认发货</el-button>
|
|
|
</span>
|
|
|
</el-dialog>
|
|
|
-
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import { transferAllocateList, remove, getGoodsInfo, getDetails, shipments } from "@/api/tirePartsMall/salesManagement/outboundWorkOrder";
|
|
|
-import detailsPage from "./detailsPage"
|
|
|
-import {getWorkDicts} from "../../../../api/system/dictbiz";
|
|
|
+import detailsPage from "./detailsPage";
|
|
|
+import { getWorkDicts } from "../../../../api/system/dictbiz";
|
|
|
|
|
|
export default {
|
|
|
name: "index",
|
|
|
@@ -126,52 +126,58 @@ export default {
|
|
|
menu: false,
|
|
|
column: [
|
|
|
{
|
|
|
- label: '商品名称',
|
|
|
- prop: 'goodsName',
|
|
|
+ label: "商品名称",
|
|
|
+ prop: "goodsName",
|
|
|
disabled: true,
|
|
|
width: 200,
|
|
|
- overHidden: true,
|
|
|
- }, {
|
|
|
- label: '商品编码',
|
|
|
+ overHidden: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "商品编码",
|
|
|
disabled: true,
|
|
|
- prop: 'goodsNo',
|
|
|
+ prop: "goodsNo",
|
|
|
width: 100
|
|
|
- }, {
|
|
|
- label: '品牌',
|
|
|
- prop: 'brandId',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "品牌",
|
|
|
+ prop: "brandId",
|
|
|
disabled: true,
|
|
|
width: 100,
|
|
|
overHidden: true,
|
|
|
props: {
|
|
|
- label: 'cname',
|
|
|
- value: 'id'
|
|
|
+ label: "cname",
|
|
|
+ value: "id"
|
|
|
},
|
|
|
- dicUrl: '/api/blade-sales-part/brandDesc/listAll?type=PP&enableOrNot=1'
|
|
|
- }, {
|
|
|
- label: '规格型号',
|
|
|
- prop: 'propertyName',
|
|
|
+ dicUrl: "/api/blade-sales-part/brandDesc/listAll?type=PP&enableOrNot=1"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "规格型号",
|
|
|
+ prop: "propertyName",
|
|
|
disabled: true,
|
|
|
width: 100
|
|
|
- }, {
|
|
|
- label: '花纹',
|
|
|
- prop: 'pattern',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "花纹",
|
|
|
+ prop: "pattern",
|
|
|
disabled: true,
|
|
|
width: 100
|
|
|
- }, {
|
|
|
- label: '商品描述',
|
|
|
- prop: 'goodsDescription',
|
|
|
- disabled: true,
|
|
|
- }, {
|
|
|
- label: '批次号',
|
|
|
- prop: 'dot',
|
|
|
- type: 'select',
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "商品描述",
|
|
|
+ prop: "goodsDescription",
|
|
|
+ disabled: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "批次号",
|
|
|
+ prop: "dot",
|
|
|
+ type: "select",
|
|
|
disabled: true,
|
|
|
dicData: [],
|
|
|
props: {
|
|
|
label: "dot",
|
|
|
value: "dot"
|
|
|
},
|
|
|
- dicUrl: "/api/blade-sales-part/stockDesc/dotList",
|
|
|
+ dicUrl: "/api/blade-sales-part/stockDesc/dotList"
|
|
|
}
|
|
|
]
|
|
|
},
|
|
|
@@ -196,155 +202,173 @@ export default {
|
|
|
expand: true,
|
|
|
expandWidth: 60,
|
|
|
dialogWidth: "70%",
|
|
|
- summaryText:this.$t("land118n.total"),
|
|
|
+ summaryText: this.$t("land118n.total"),
|
|
|
showSummary: true,
|
|
|
- sumColumnList: [{
|
|
|
- name: "goodsTotalNum",
|
|
|
- type: "sum",
|
|
|
- decimals: 0
|
|
|
- }],
|
|
|
- column: [{
|
|
|
- label: '调拨单号',
|
|
|
- prop: "billno",
|
|
|
- search: true,
|
|
|
- overHidden: true,
|
|
|
- }, {
|
|
|
- label: '调出仓库',
|
|
|
- prop: "storageId",
|
|
|
- search: true,
|
|
|
- overHidden: true,
|
|
|
- type: 'select',
|
|
|
- props: {
|
|
|
- label: 'cname',
|
|
|
- value: 'id'
|
|
|
+ sumColumnList: [
|
|
|
+ {
|
|
|
+ name: "goodsTotalNum",
|
|
|
+ type: "sum",
|
|
|
+ decimals: 0
|
|
|
+ }
|
|
|
+ ],
|
|
|
+ column: [
|
|
|
+ {
|
|
|
+ label: "调拨单号",
|
|
|
+ prop: "billno",
|
|
|
+ search: true,
|
|
|
+ overHidden: true
|
|
|
},
|
|
|
- dicUrl: '/api/blade-sales-part/storageDesc/listAll',
|
|
|
- },{
|
|
|
- label: '调入仓库',
|
|
|
+ {
|
|
|
+ label: "调出仓库",
|
|
|
+ prop: "storageId",
|
|
|
+ search: true,
|
|
|
+ overHidden: true,
|
|
|
+ type: "select",
|
|
|
+ props: {
|
|
|
+ label: "cname",
|
|
|
+ value: "id"
|
|
|
+ },
|
|
|
+ dicUrl: "/api/blade-sales-part/storageDesc/listAll"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "调入仓库",
|
|
|
prop: "callInStorageId",
|
|
|
search: true,
|
|
|
overHidden: true,
|
|
|
- type: 'select',
|
|
|
+ type: "select",
|
|
|
props: {
|
|
|
- label: 'cname',
|
|
|
- value: 'id'
|
|
|
+ label: "cname",
|
|
|
+ value: "id"
|
|
|
},
|
|
|
- dicUrl: '/api/blade-sales-part/storageDesc/listAll',
|
|
|
- }, {
|
|
|
- label: "调拨数量",
|
|
|
- prop: "goodsTotalNum",
|
|
|
- search: false,
|
|
|
- overHidden: true,
|
|
|
- // width: 120,
|
|
|
- }, {
|
|
|
- label: '状态',
|
|
|
- prop: "statusName",
|
|
|
- search: true,
|
|
|
- overHidden: true,
|
|
|
- type: 'select',
|
|
|
- dicData:[
|
|
|
- {
|
|
|
- dictValue:'录入',
|
|
|
- dictKey:'录入'
|
|
|
- },
|
|
|
- {
|
|
|
- dictValue:'确认调拨',
|
|
|
- dictKey:'确认调拨'
|
|
|
- }
|
|
|
+ dicUrl: "/api/blade-sales-part/storageDesc/listAll"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "调拨数量",
|
|
|
+ prop: "goodsTotalNum",
|
|
|
+ search: false,
|
|
|
+ overHidden: true
|
|
|
+ // width: 120,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "状态",
|
|
|
+ prop: "statusName",
|
|
|
+ search: true,
|
|
|
+ overHidden: true,
|
|
|
+ type: "select",
|
|
|
+ dicData: [
|
|
|
+ {
|
|
|
+ dictValue: "录入",
|
|
|
+ dictKey: "录入"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ dictValue: "确认调拨",
|
|
|
+ dictKey: "确认调拨"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ dictValue: "已出仓",
|
|
|
+ dictKey: "已出仓"
|
|
|
+ }
|
|
|
],
|
|
|
- props: {
|
|
|
- label: "dictValue",
|
|
|
- value: "dictKey"
|
|
|
- }
|
|
|
- }, {
|
|
|
- label: '调拨日期',
|
|
|
- prop: "businesDate",
|
|
|
- overHidden: true,
|
|
|
- searchProp: "businesDateList",
|
|
|
- type: "date",
|
|
|
- search: true,
|
|
|
- width: 100,
|
|
|
- unlinkPanels: true,
|
|
|
- searchRange: true,
|
|
|
- searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
- format: "yyyy-MM-dd",
|
|
|
- valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
- }, {
|
|
|
- label: '库管',
|
|
|
- prop: "stockClerkId",
|
|
|
- type: 'select',
|
|
|
- search: true,
|
|
|
- props: {
|
|
|
- label: 'realName',
|
|
|
- value: 'id'
|
|
|
+ props: {
|
|
|
+ label: "dictValue",
|
|
|
+ value: "dictKey"
|
|
|
+ }
|
|
|
},
|
|
|
- dicUrl: '/api/blade-user/stockClerkList',
|
|
|
- overHidden: true,
|
|
|
- }, {
|
|
|
- label: "制单人",
|
|
|
- prop: "createUserName",
|
|
|
- searchProp: "createUser",
|
|
|
- overHidden: true,
|
|
|
- width: 100,
|
|
|
- filterable: true,
|
|
|
- remote: true,
|
|
|
- type: "select",
|
|
|
- dicUrl: "/api/blade-user/page?size=20¤t=1&account={{key}}",
|
|
|
- props: {
|
|
|
- label: "account",
|
|
|
- value: "id",
|
|
|
- res: 'data.records'
|
|
|
- }
|
|
|
- }, {
|
|
|
- label: "制单日期",
|
|
|
- prop: "createTime",
|
|
|
- searchProp: "createTimeList",
|
|
|
- type: "date",
|
|
|
- overHidden: true,
|
|
|
- width: 100,
|
|
|
- searchRange: true,
|
|
|
- searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
- format: "yyyy-MM-dd",
|
|
|
- valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
- }, {
|
|
|
- label: "更新人",
|
|
|
- prop: "updateUserName",
|
|
|
- searchProp: "updateUser",
|
|
|
- overHidden: true,
|
|
|
- width: 100,
|
|
|
- filterable: true,
|
|
|
- remote: true,
|
|
|
- type: "select",
|
|
|
- dicUrl: "/api/blade-user/page?size=20¤t=1&account={{key}}",
|
|
|
- props: {
|
|
|
- label: "account",
|
|
|
- value: "id",
|
|
|
- res: 'data.records'
|
|
|
+ {
|
|
|
+ label: "调拨日期",
|
|
|
+ prop: "businesDate",
|
|
|
+ overHidden: true,
|
|
|
+ searchProp: "businesDateList",
|
|
|
+ type: "date",
|
|
|
+ search: true,
|
|
|
+ width: 100,
|
|
|
+ unlinkPanels: true,
|
|
|
+ searchRange: true,
|
|
|
+ searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
+ format: "yyyy-MM-dd",
|
|
|
+ valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "库管",
|
|
|
+ prop: "stockClerkId",
|
|
|
+ type: "select",
|
|
|
+ search: true,
|
|
|
+ props: {
|
|
|
+ label: "realName",
|
|
|
+ value: "id"
|
|
|
+ },
|
|
|
+ dicUrl: "/api/blade-user/stockClerkList",
|
|
|
+ overHidden: true
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "制单人",
|
|
|
+ prop: "createUserName",
|
|
|
+ searchProp: "createUser",
|
|
|
+ overHidden: true,
|
|
|
+ width: 100,
|
|
|
+ filterable: true,
|
|
|
+ remote: true,
|
|
|
+ type: "select",
|
|
|
+ dicUrl: "/api/blade-user/page?size=20¤t=1&account={{key}}",
|
|
|
+ props: {
|
|
|
+ label: "account",
|
|
|
+ value: "id",
|
|
|
+ res: "data.records"
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "制单日期",
|
|
|
+ prop: "createTime",
|
|
|
+ searchProp: "createTimeList",
|
|
|
+ type: "date",
|
|
|
+ overHidden: true,
|
|
|
+ width: 100,
|
|
|
+ searchRange: true,
|
|
|
+ searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
+ format: "yyyy-MM-dd",
|
|
|
+ valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "更新人",
|
|
|
+ prop: "updateUserName",
|
|
|
+ searchProp: "updateUser",
|
|
|
+ overHidden: true,
|
|
|
+ width: 100,
|
|
|
+ filterable: true,
|
|
|
+ remote: true,
|
|
|
+ type: "select",
|
|
|
+ dicUrl: "/api/blade-user/page?size=20¤t=1&account={{key}}",
|
|
|
+ props: {
|
|
|
+ label: "account",
|
|
|
+ value: "id",
|
|
|
+ res: "data.records"
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: "更新日期",
|
|
|
+ prop: "updateTime",
|
|
|
+ searchProp: "updateTimeList",
|
|
|
+ type: "date",
|
|
|
+ overHidden: true,
|
|
|
+ width: 100,
|
|
|
+ searchRange: true,
|
|
|
+ searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
+ format: "yyyy-MM-dd",
|
|
|
+ valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
}
|
|
|
- }, {
|
|
|
- label: "更新日期",
|
|
|
- prop: "updateTime",
|
|
|
- searchProp: "updateTimeList",
|
|
|
- type: "date",
|
|
|
- overHidden: true,
|
|
|
- width: 100,
|
|
|
- searchRange: true,
|
|
|
- searchDefaultTime: ["00:00:00", "23:59:59"],
|
|
|
- format: "yyyy-MM-dd",
|
|
|
- valueFormat: "yyyy-MM-dd HH:mm:ss"
|
|
|
- }]
|
|
|
+ ]
|
|
|
}
|
|
|
- }
|
|
|
+ };
|
|
|
},
|
|
|
async created() {
|
|
|
this.option = await this.getColumnData(this.getColumnName(317), this.optionList);
|
|
|
- this.key++
|
|
|
+ this.key++;
|
|
|
let i = 0;
|
|
|
this.option.column.forEach(item => {
|
|
|
- if (item.search) i++
|
|
|
- })
|
|
|
+ if (item.search) i++;
|
|
|
+ });
|
|
|
if (i % 3 !== 0) {
|
|
|
- const num = 3 - Number(i % 3)
|
|
|
+ const num = 3 - Number(i % 3);
|
|
|
this.option.searchMenuSpan = num * 8;
|
|
|
this.option.searchMenuPosition = "right";
|
|
|
}
|
|
|
@@ -355,14 +379,13 @@ export default {
|
|
|
this.detailsOpen = true;
|
|
|
}
|
|
|
console.log(this.$route.query);
|
|
|
-
|
|
|
},
|
|
|
activated() {
|
|
|
- console.log(this.$route.query,400);
|
|
|
- // 主页快捷跳转来的 直接打开新建订单
|
|
|
- if (this.$route.query.showTrue) {
|
|
|
- this.detailsOpen = true;
|
|
|
- }
|
|
|
+ console.log(this.$route.query, 400);
|
|
|
+ // 主页快捷跳转来的 直接打开新建订单
|
|
|
+ if (this.$route.query.showTrue) {
|
|
|
+ this.detailsOpen = true;
|
|
|
+ }
|
|
|
if (this.$route.query.id) {
|
|
|
this.detailData = {
|
|
|
id: this.$route.query.id
|
|
|
@@ -372,43 +395,44 @@ export default {
|
|
|
},
|
|
|
methods: {
|
|
|
check(row) {
|
|
|
- this.form = row
|
|
|
- this.detailsOpen = true
|
|
|
+ this.form = row;
|
|
|
+ this.detailsOpen = true;
|
|
|
},
|
|
|
backToList(type) {
|
|
|
- this.form = {}
|
|
|
- this.detailsOpen = false
|
|
|
+ this.form = {};
|
|
|
+ this.detailsOpen = false;
|
|
|
if (type === 0) {
|
|
|
- this.detailData = {}
|
|
|
+ this.detailData = {};
|
|
|
}
|
|
|
- this.onLoad(this.page, this.search)
|
|
|
+ this.onLoad(this.page, this.search);
|
|
|
},
|
|
|
//刷新
|
|
|
refreshChange() {
|
|
|
- this.onLoad(this.page, this.search)
|
|
|
+ this.onLoad(this.page, this.search);
|
|
|
},
|
|
|
rowDel(form, index) {
|
|
|
console.log(form);
|
|
|
- this.$confirm('此操作将永久删除该行, 是否继续?', '提示', {
|
|
|
- confirmButtonText: '确定',
|
|
|
- cancelButtonText: '取消',
|
|
|
- type: 'warning'
|
|
|
- }).then(() => {
|
|
|
- remove(form.id).then(res => {
|
|
|
- this.$message({
|
|
|
- type: 'success',
|
|
|
- message: '删除成功!'
|
|
|
+ this.$confirm("此操作将永久删除该行, 是否继续?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning"
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ remove(form.id).then(res => {
|
|
|
+ this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: "删除成功!"
|
|
|
+ });
|
|
|
+ this.dataList.splice(index, 1);
|
|
|
+ this.onLoad(this.page);
|
|
|
});
|
|
|
- this.dataList.splice(index, 1);
|
|
|
- this.onLoad(this.page)
|
|
|
})
|
|
|
- }).catch(() => {
|
|
|
- });
|
|
|
+ .catch(() => {});
|
|
|
},
|
|
|
searchChange(params, done) {
|
|
|
- this.page.currentPage = 1
|
|
|
+ this.page.currentPage = 1;
|
|
|
done();
|
|
|
- this.onLoad(this.page, params)
|
|
|
+ this.onLoad(this.page, params);
|
|
|
},
|
|
|
onLoad(page, params = {}) {
|
|
|
console.log(params);
|
|
|
@@ -416,31 +440,33 @@ export default {
|
|
|
...params,
|
|
|
current: page.currentPage,
|
|
|
size: page.pageSize,
|
|
|
- bizTypeName: "DBGD",
|
|
|
+ bizTypeName: "DBGD",
|
|
|
...Object.assign(params, this.search)
|
|
|
- }
|
|
|
- this.loading = true
|
|
|
+ };
|
|
|
+ this.loading = true;
|
|
|
this.dataList.forEach(item => {
|
|
|
this.$refs.crud.toggleRowExpansion(item, false);
|
|
|
});
|
|
|
- transferAllocateList(params).then(res => {
|
|
|
- if (res.data.data.records) {
|
|
|
- res.data.data.records.forEach(e => {
|
|
|
- e.itemLoading = true;
|
|
|
+ transferAllocateList(params)
|
|
|
+ .then(res => {
|
|
|
+ if (res.data.data.records) {
|
|
|
+ res.data.data.records.forEach(e => {
|
|
|
+ e.itemLoading = true;
|
|
|
+ });
|
|
|
+ }
|
|
|
+ this.dataList = res.data.data.records;
|
|
|
+ this.page.total = res.data.data.total;
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.$refs.crud.doLayout();
|
|
|
});
|
|
|
- }
|
|
|
- this.dataList = res.data.data.records
|
|
|
- this.page.total = res.data.data.total
|
|
|
- this.$nextTick(() => {
|
|
|
- this.$refs.crud.doLayout()
|
|
|
+ this.loading = false;
|
|
|
})
|
|
|
- this.loading = false
|
|
|
- }).finally(() => {
|
|
|
- this.loading = false
|
|
|
- })
|
|
|
+ .finally(() => {
|
|
|
+ this.loading = false;
|
|
|
+ });
|
|
|
},
|
|
|
editOpen(row, status) {
|
|
|
- this.form = row
|
|
|
+ this.form = row;
|
|
|
this.detailData = {
|
|
|
id: row.id,
|
|
|
status: status
|
|
|
@@ -460,45 +486,44 @@ export default {
|
|
|
},
|
|
|
// 发货按钮
|
|
|
deliverGoods(row) {
|
|
|
-
|
|
|
// 获取运输类型
|
|
|
getWorkDicts("deliveryMethod").then(res => {
|
|
|
this.courierTypeList = res.data.data;
|
|
|
- })
|
|
|
+ });
|
|
|
// 获取快递公司
|
|
|
getWorkDicts("tyre_express_company").then(res => {
|
|
|
this.courierList = res.data.data;
|
|
|
- })
|
|
|
+ });
|
|
|
|
|
|
- this.dialogForm = row
|
|
|
+ this.dialogForm = row;
|
|
|
|
|
|
- this.dialogVisible = true
|
|
|
+ this.dialogVisible = true;
|
|
|
},
|
|
|
courierTypeChange() {
|
|
|
- this.dialogForm.courierCorporation = null
|
|
|
+ this.dialogForm.courierCorporation = null;
|
|
|
},
|
|
|
// 发货
|
|
|
confirmShipment() {
|
|
|
for (let courierCompanies of this.courierList) {
|
|
|
if (courierCompanies.dictValue === this.dialogForm.logisticsCorpName) {
|
|
|
- this.dialogForm.logisticsCorpId = courierCompanies.dictKey
|
|
|
- break
|
|
|
+ this.dialogForm.logisticsCorpId = courierCompanies.dictKey;
|
|
|
+ break;
|
|
|
}
|
|
|
}
|
|
|
|
|
|
const requestBody = {
|
|
|
- id : this.dialogForm.id,
|
|
|
- logisticsCorpId : this.dialogForm.logisticsCorpId,
|
|
|
- logisticsCorpName : this.dialogForm.logisticsCorpName,
|
|
|
- shipType : this.dialogForm.shipType,
|
|
|
- expressNo : this.dialogForm.expressNo
|
|
|
- }
|
|
|
+ id: this.dialogForm.id,
|
|
|
+ logisticsCorpId: this.dialogForm.logisticsCorpId,
|
|
|
+ logisticsCorpName: this.dialogForm.logisticsCorpName,
|
|
|
+ shipType: this.dialogForm.shipType,
|
|
|
+ expressNo: this.dialogForm.expressNo
|
|
|
+ };
|
|
|
|
|
|
shipments(requestBody).then(res => {
|
|
|
- console.log(res)
|
|
|
+ console.log(res);
|
|
|
this.$message.success("发货成功");
|
|
|
this.dialogVisible = false;
|
|
|
- })
|
|
|
+ });
|
|
|
},
|
|
|
//自定义列保存
|
|
|
async saveColumnTwo(ref, option, optionBack, code) {
|
|
|
@@ -524,7 +549,7 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
-}
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style scoped></style>
|