|
@@ -1,10 +1,17 @@
|
|
|
<template>
|
|
|
<div>
|
|
|
<basic-container v-show="show" class="page-crad">
|
|
|
+ <div style="display:flex;">
|
|
|
+ <el-badge v-for="item of badgeList" :value="item.count" :max="99" class="item" type="danger">
|
|
|
+ <el-button :type="search.status == item.status?'primary':''" size="mini" @click="query(item.status)">
|
|
|
+ {{ item.dictionaryStatus }}
|
|
|
+ </el-button>
|
|
|
+ </el-badge>
|
|
|
+ </div>
|
|
|
<avue-crud :key="key" ref="crud" :option="option" :data="dataList" :page.sync="page" :search.sync="search"
|
|
|
- @search-change="searchChange" @current-change="currentChange" @size-change="sizeChange"
|
|
|
- @refresh-change="refreshChange" @on-load="onLoad" :table-loading="loading" @saveColumn="saveColumn"
|
|
|
- @resetColumn="resetColumn" :cell-style="cellStyle" @search-criteria-switch="searchCriteriaSwitch">
|
|
|
+ @search-change="searchChange" @current-change="currentChange" @size-change="sizeChange"
|
|
|
+ @refresh-change="refreshChange" @on-load="onLoad" :table-loading="loading" @saveColumn="saveColumn"
|
|
|
+ @resetColumn="resetColumn" :cell-style="cellStyle" @search-criteria-switch="searchCriteriaSwitch">
|
|
|
<template slot="menuLeft">
|
|
|
<el-button type="primary" size="mini" @click.stop="newAdd()">新建销售单
|
|
|
</el-button>
|
|
@@ -13,8 +20,7 @@
|
|
|
<crop-select v-model="search.corpId" corpType="KH"></crop-select>
|
|
|
</template>
|
|
|
<template slot-scope="{ row, index }" slot="corpId">
|
|
|
- <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 1)">{{ row.corpsName }}
|
|
|
- </span>
|
|
|
+ <span style="color: #409EFF;cursor: pointer" @click.stop="editOpen(row, 1)">{{ row.corpsName }}</span>
|
|
|
</template>
|
|
|
<template slot="businesDateSearch">
|
|
|
<el-date-picker v-model="search.businesDate" type="daterange" start-placeholder="开始日期" end-placeholder="结束日期"
|
|
@@ -27,20 +33,20 @@
|
|
|
<i class="tradingIcon icon-add" />
|
|
|
</el-tooltip> -->
|
|
|
<el-tooltip class="item" effect="dark" content="删除" placement="top">
|
|
|
- <i class="tradingIcon icon-del" v-if="row.confirmStatus == 0" @click.stop="rowDel(row, index)" />
|
|
|
- </el-tooltip>
|
|
|
- <!-- <el-tooltip class="item" effect="dark" content="编辑" placement="top">
|
|
|
- <i class="tradingIcon icon-edit" />
|
|
|
- </el-tooltip>
|
|
|
- <el-tooltip class="item" effect="dark" content="收款" placement="top">
|
|
|
- <i class="tradingIcon icon-proceeds" />
|
|
|
+ <i class="tradingIcon icon-del" v-if="row.confirmStatus == 0" @click.stop="rowDel(row, index)"/>
|
|
|
</el-tooltip>
|
|
|
+ <!-- <el-tooltip class="item" effect="dark" content="编辑" placement="top">-->
|
|
|
+ <!-- <i class="tradingIcon icon-edit" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
+ <!-- <el-tooltip class="item" effect="dark" content="收款" placement="top">-->
|
|
|
+ <!-- <i class="tradingIcon icon-proceeds" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
<el-tooltip class="item" effect="dark" content="发货" placement="top">
|
|
|
- <i class="tradingIcon icon-deliver" />
|
|
|
+ <i class="tradingIcon icon-deliver" v-if="row.status == 6" @click.stop="deliverGoods(row, index)"/>
|
|
|
</el-tooltip>
|
|
|
- <el-tooltip class="item" effect="dark" content="对账" placement="top">
|
|
|
- <i class="tradingIcon icon-reconciliation" />
|
|
|
- </el-tooltip> -->
|
|
|
+ <!-- <el-tooltip class="item" effect="dark" content="对账" placement="top">-->
|
|
|
+ <!-- <i class="tradingIcon icon-reconciliation" />-->
|
|
|
+ <!-- </el-tooltip>-->
|
|
|
<!-- <el-button type="text" size="small" @click.stop="editOpen(row, 2)">
|
|
|
查看
|
|
|
</el-button>
|
|
@@ -50,26 +56,64 @@
|
|
|
</template>
|
|
|
</avue-crud>
|
|
|
</basic-container>
|
|
|
- <details-page v-if="!show" @goBack="goBack()" :detailData="detailData" />
|
|
|
+ <details-page v-if="!show" @goBack="goBack()" :detailData="detailData"/>
|
|
|
+ <el-dialog
|
|
|
+ title="发货"
|
|
|
+ :visible.sync="dialogVisible"
|
|
|
+ append-to-body
|
|
|
+ close-on-click-modal
|
|
|
+ close-on-press-escape
|
|
|
+ width="60%">
|
|
|
+ <div>
|
|
|
+ <el-form :model="form" label-position="right">
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="快递公司:" label-width="100px">
|
|
|
+ <el-input v-model="form.courierCorporation" placeholder="请输入快递公司" size="small" style="width: 100%;"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-form-item label="快递单号:" label-width="100px">
|
|
|
+ <el-input v-model="form.courierNumber" placeholder="请输入快递单号" size="small" style="width: 100%;"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+ <span slot="footer" class="dialog-footer">
|
|
|
+ <el-button size="small" @click="dialogVisible = false">取 消</el-button>
|
|
|
+ <el-button size="small" type="primary" @click="confirmShipment">确认发货</el-button>
|
|
|
+ </span>
|
|
|
+ </el-dialog>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
import detailsPage from "./detailsPage";
|
|
|
-import { option } from "./js/optionList";
|
|
|
-import { getList, getCorpsAll, gainUser, getCorpType, orderRemove } from "@/api/basicData/salesOrder";
|
|
|
+import {option} from "./js/optionList";
|
|
|
+import {
|
|
|
+ getListTwo,
|
|
|
+ getCorpsAll,
|
|
|
+ gainUser,
|
|
|
+ getCorpType,
|
|
|
+ orderRemove,
|
|
|
+ statusStatisticsApi,
|
|
|
+ delivery
|
|
|
+} from "@/api/basicData/salesOrder";
|
|
|
+
|
|
|
export default {
|
|
|
name: "index",
|
|
|
data() {
|
|
|
return {
|
|
|
src: '',
|
|
|
+ form: {},
|
|
|
+ dialogVisible: false,
|
|
|
+ badgeList: [],
|
|
|
show: true,
|
|
|
loading: false,
|
|
|
search: {},
|
|
|
detailData: {},
|
|
|
dataList: [],
|
|
|
selectionList: [],
|
|
|
- key:0,
|
|
|
+ key: 0,
|
|
|
page: {
|
|
|
pageSize: 20,
|
|
|
currentPage: 1,
|
|
@@ -183,11 +227,27 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
+ confirmShipment(){
|
|
|
+ delivery({
|
|
|
+ id:this.form.id,
|
|
|
+ courierNumber:this.form.courierNumber,
|
|
|
+ courierCorporation:this.form.courierCorporation
|
|
|
+ }).then(res=>{
|
|
|
+ this.$message.success("发货成功")
|
|
|
+ this.dialogVisible = false
|
|
|
+ this.onLoad(this.page)
|
|
|
+ })
|
|
|
+ },
|
|
|
+ query(status) {
|
|
|
+ this.search.status = status
|
|
|
+ this.page.currentPage = 1;
|
|
|
+ this.onLoad(this.page)
|
|
|
+ },
|
|
|
getAllWorkDicts() {
|
|
|
gainUser().then(res => {
|
|
|
this.findObject(this.option.column, "createUser").dicData = res.data.data;
|
|
|
})
|
|
|
- getCorpType({ corpType: 'KH' }).then(res => {
|
|
|
+ getCorpType({corpType: 'KH'}).then(res => {
|
|
|
this.findObject(this.option.column, "corpType").dicData = res.data.data
|
|
|
});
|
|
|
this.$refs.crud.init();
|
|
@@ -217,6 +277,9 @@ export default {
|
|
|
this.$store.commit("IN_PJXS_STATUS");
|
|
|
},
|
|
|
onLoad(page, params = {}) {
|
|
|
+ statusStatisticsApi().then(res => {
|
|
|
+ this.badgeList = res.data.data;
|
|
|
+ })
|
|
|
let data = this.deepClone(Object.assign(params, this.search));
|
|
|
data.billType = 'XS';
|
|
|
data.tradeType = 'YPJ';
|
|
@@ -226,7 +289,7 @@ export default {
|
|
|
}
|
|
|
delete data.businesDate
|
|
|
this.loading = true;
|
|
|
- getList(
|
|
|
+ getListTwo(
|
|
|
page.currentPage,
|
|
|
page.pageSize,
|
|
|
data
|
|
@@ -271,10 +334,14 @@ export default {
|
|
|
});
|
|
|
});
|
|
|
},
|
|
|
+ deliverGoods(row, index) {
|
|
|
+ this.form = row
|
|
|
+ this.dialogVisible = true
|
|
|
+ },
|
|
|
async saveColumn() {
|
|
|
const inSave = await this.saveColumnData(
|
|
|
- this.getColumnName(211),
|
|
|
- this.option
|
|
|
+ this.getColumnName(211),
|
|
|
+ this.option
|
|
|
);
|
|
|
if (inSave) {
|
|
|
this.$nextTick(() => {
|
|
@@ -319,6 +386,15 @@ export default {
|
|
|
height: 94.2vh;
|
|
|
}
|
|
|
|
|
|
+::v-deep .el-badge__content.is-fixed {
|
|
|
+ z-index: 10;
|
|
|
+}
|
|
|
+
|
|
|
+.item {
|
|
|
+ margin-right: 20px;
|
|
|
+ margin-bottom: 10px;
|
|
|
+}
|
|
|
+
|
|
|
.stat-td {
|
|
|
text-align: center;
|
|
|
position: relative;
|
|
@@ -349,4 +425,17 @@ export default {
|
|
|
margin-bottom: 0px;
|
|
|
}
|
|
|
}
|
|
|
+::v-deep .el-form-item__content{
|
|
|
+ margin-left: 90px;
|
|
|
+}
|
|
|
+::v-deep .el-form-item__label {
|
|
|
+ //text-align: right;
|
|
|
+ //vertical-align: middle;
|
|
|
+ //float: left;
|
|
|
+ //font-size: 14px;
|
|
|
+ //color: #606266;
|
|
|
+ //line-height: 40px;
|
|
|
+ padding: 0 4px 0 0;
|
|
|
+ //box-sizing: border-box;
|
|
|
+}
|
|
|
</style>
|