Commit a81d99d4 authored by 邓春圆's avatar 邓春圆

Merge remote-tracking branch 'origin/dev' into dev

parents 56796bc1 86ac0e37
...@@ -46,6 +46,9 @@ export default { ...@@ -46,6 +46,9 @@ export default {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
} }
.items-center{
align-items: center;
}
.empty-placeholder{ .empty-placeholder{
padding: 50px; padding: 50px;
text-align: center; text-align: center;
......
...@@ -748,4 +748,58 @@ export function splitItemUpdate(data){ ...@@ -748,4 +748,58 @@ export function splitItemUpdate(data){
data data
}) })
} }
// 可出订单列表
export function canShipmentPage(params){
return request({
url: '/air/order/can/shipment/page',
method: 'get',
params
})
}
// 待出订单列表
export function waitingShipmentPage(params){
return request({
url: '/air/order/waiting/shipment/page',
method: 'get',
params
})
}
// 备货订单列表
export function canReadyStockShipmentPage(params){
return request({
url: '/air/order/can-ready-stock/shipment/page',
method: 'get',
params
})
}
// 确认订单可出
export function setCanShipment(orderId){
return request({
url: '/air/order/can/shipment/' + orderId,
method: 'put',
})
}
// 批量可出
export function batchCanShipment(orderIdList){
return request({
url: '/air/order/can/shipment/',
method: 'put',
data: {orderIdList}
})
}
// 批量转异
export function batchException(ids){
throw new Error('接口未出,待完善,以下代码是copilot生成')
}
// 导出备货订单
export function exportReadyStock(params){
return request({
url: '/ecw/order/export/ready-stock/search',
method: 'get',
params,
responseType: 'blob'
})
}
...@@ -107,3 +107,12 @@ export function getProductPriceGetPrice(query) { ...@@ -107,3 +107,12 @@ export function getProductPriceGetPrice(query) {
params: query params: query
}) })
} }
// 更新单询
export function updateOrderInquiry(data) {
return request({
url: '/ecw/product-price/updateOrderInquiry',
method: 'put',
data: data
})
}
...@@ -57,8 +57,11 @@ export default { ...@@ -57,8 +57,11 @@ export default {
} }
}, },
computed:{ computed:{
dicts(){
return this.getList(this.type)
},
dictList(){ dictList(){
return this.getList(this.type).filter(this.filter) return this.dicts.filter(this.filter)
}, },
formattedList(){ formattedList(){
let arr = [] let arr = []
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<div> <div>
<div class="filters mb-10"> <div class="filters mb-10">
{{$t('运输方式')}} {{$t('运输方式')}}
<dict-selector :type='DICT_TYPE.ECW_TRANSPORT_TYPE' v-model="transportType" :placeholder="$t('请选择运输方式')" style="width:150px" /> <dict-selector :type='DICT_TYPE.ECW_TRANSPORT_TYPE' v-model="transportType" :placeholder="$t('请选择运输方式')" :filter="transportFilter" style="width:150px" />
{{$t('始发地')}} {{$t('始发地')}}
<el-select :placeholder="$t('请选择始发地')" v-model="exportCity" clearable> <el-select :placeholder="$t('请选择始发地')" v-model="exportCity" clearable>
...@@ -50,6 +50,11 @@ ...@@ -50,6 +50,11 @@
{{$l(row.channel, 'name')}} {{$l(row.channel, 'name')}}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column v-if="showAttr" :label="$t('商品特性')" prop="startTitleZh">
<template slot-scope="{row}">
{{ getAttrNames(row.attrId) }}
</template>
</el-table-column>
<el-table-column :label="$t('操作')" prop=""> <el-table-column :label="$t('操作')" prop="">
<template slot="header"> <template slot="header">
<el-checkbox @change="toggleGroupChecker(index, $event)" v-model="groupChecker[item.value]"></el-checkbox> <el-checkbox @change="toggleGroupChecker(index, $event)" v-model="groupChecker[item.value]"></el-checkbox>
...@@ -69,12 +74,15 @@ ...@@ -69,12 +74,15 @@
import {getChannelList} from '@/api/ecw/channel' import {getChannelList} from '@/api/ecw/channel'
import {getTradeCityList} from '@/api/ecw/region' import {getTradeCityList} from '@/api/ecw/region'
import {openedRouterList} from '@/api/ecw/warehouse' import {openedRouterList} from '@/api/ecw/warehouse'
import {getProductAttrList} from "@/api/ecw/productAttr";
export default { export default {
props:{ props:{
value: { value: {
type: Array type: Array
}, },
option: Object option: Object,
// 类型,sea海运,air空运
type: String
}, },
data(){ data(){
return { return {
...@@ -90,7 +98,7 @@ export default { ...@@ -90,7 +98,7 @@ export default {
hideMap: {}, // 折叠状态 hideMap: {}, // 折叠状态
checkAll: null, checkAll: null,
groupChecker: {}, // 分组全选状态 groupChecker: {}, // 分组全选状态
attrList:[], // 商品特性
} }
}, },
computed:{ computed:{
...@@ -114,12 +122,14 @@ export default { ...@@ -114,12 +122,14 @@ export default {
}) })
return ids return ids
}, },
// 根据选择的渠道筛选
availChannelList(){ availChannelList(){
return this.channelList.filter(item => !this.channelId || this.channelId == item.channelId) return this.channelList.filter(item => !this.channelId || this.channelId == item.channelId)
}, },
filteredRouterList(){ filteredRouterList(){
let transportTypeList = [] let transportTypeList = []
this.transportTypeDicts this.transportTypeDicts
.filter(this.transportFilter)
.filter(transport => !this.channelId || transport.cssClass == 'channel') .filter(transport => !this.channelId || transport.cssClass == 'channel')
.forEach(item => { .forEach(item => {
if(this.transportType === null || this.transportType == '' || this.transportType == item.value){ if(this.transportType === null || this.transportType == '' || this.transportType == item.value){
...@@ -151,6 +161,25 @@ export default { ...@@ -151,6 +161,25 @@ export default {
} }
}) })
return transportTypeList return transportTypeList
},
// 是否显示商品特性(渠道)
showAttr(){
return this.type == 'air'
},
// 显示产品特性
getAttrName(){
return (id) => {
let item = this.attrList.find(item => item.id == id)
if(!item) return ''
return this.$l(item, 'attrName')
}
},
// 显示多个商品特性
getAttrNames(){
return (ids) => {
if(!ids) return ''
return ids.split(',').filter( item => !!item).map(id => this.getAttrName(id)).join(',')
}
} }
}, },
watch:{ watch:{
...@@ -209,8 +238,18 @@ export default { ...@@ -209,8 +238,18 @@ export default {
this.changeOption() this.changeOption()
} }
// 如果显示特性,则需要查询特数据备用
if(this.showAttr){
this.getAttrList()
}
}, },
methods:{ methods:{
getAttrList(){
getProductAttrList().then(res => {
this.attrList = res.data
})
},
changeOption(){ changeOption(){
if(!this.option) return if(!this.option) return
this.importCity = +this.option.importCity || null this.importCity = +this.option.importCity || null
...@@ -265,15 +304,6 @@ export default { ...@@ -265,15 +304,6 @@ export default {
return this.selectedRoutes.findIndex(item => { return this.selectedRoutes.findIndex(item => {
return item.lineId == router.id && item.channelId == router.channel.channelId return item.lineId == router.id && item.channelId == router.channel.channelId
}) })
/* let index = null
this.selectedRoutes.forEach((item, i)=>{
if(item.lineId == router.id && item.shippingChannelId == router.channel.channelId){
index = i
// break
}
})
return index */
}, },
SpanMethod({ row, column, rowIndex, columnIndex }){ SpanMethod({ row, column, rowIndex, columnIndex }){
if (columnIndex < 2 ) { if (columnIndex < 2 ) {
...@@ -290,7 +320,11 @@ export default { ...@@ -290,7 +320,11 @@ export default {
// 折叠,展开 // 折叠,展开
toggleHide(value){ toggleHide(value){
this.$set(this.hideMap, value, !this.hideMap[value]) this.$set(this.hideMap, value, !this.hideMap[value])
} },
// 运输方式筛选
transportFilter(item){
return (this.type == 'sea' ? ['1','2'] : ['3', '4']).indexOf(item.value) > -1
},
} }
} }
</script> </script>
......
...@@ -188,6 +188,8 @@ export const DICT_TYPE = { ...@@ -188,6 +188,8 @@ export const DICT_TYPE = {
WAREHOUSING_SPECIFICATION_TYPE: 'warehousing_specification_type', WAREHOUSING_SPECIFICATION_TYPE: 'warehousing_specification_type',
ECW_AUTH_TYPE:'auth_type',//品牌授权 ECW_AUTH_TYPE:'auth_type',//品牌授权
NEED_ORDER_INQUIRY: 'need_order_inquiry', // 是否需要単询
ECASH_INIT:'ecash_init', //e-cash ECASH_INIT:'ecash_init', //e-cash
FEE_TYPE:'receivable_fee_type', FEE_TYPE:'receivable_fee_type',
// PAY_TYPE:'payment_type', // PAY_TYPE:'payment_type',
......
<template> <template>
<div class="app-container"> <div class="app-container">
<!--初始化过程中不渲染页面,利用此特性在新建订单后重新初始化表单(字典选择组件默认值)-->
<el-form ref="form" :model="form" :rules="rules" label-position="left" inline :disabled="updateChannel"> <el-form v-if="!initing" ref="form" :model="form" :rules="rules" label-position="left" inline :disabled="updateChannel">
<el-card v-if="form.applyStatus == 1" class="mb-10"> <el-card v-if="form.applyStatus == 1" class="mb-10">
<div slot="header" class="card-title">{{$t('以下信息修改审核中')}}</div> <div slot="header" class="card-title">{{$t('以下信息修改审核中')}}</div>
<el-table :data="form.applyInfoList"> <el-table :data="form.applyInfoList">
...@@ -1256,15 +1256,18 @@ export default { ...@@ -1256,15 +1256,18 @@ export default {
// 添加的提交 // 添加的提交
createOrder(data).then(response => { createOrder(data).then(response => {
this.$modal.msgSuccess(this.$t("新增成功")); this.$modal.msgSuccess(this.$t("新增成功"));
this.initing = true
// 重置数据 // 重置数据
this.form = {...makeDefaultFormData()} this.form = {...makeDefaultFormData()}
this.routerList = [] this.routerList = []
this.addProduct() this.addProduct()
this.$nextTick(() =>{ this.$nextTick(() =>{
this.$refs.form.clearValidate() this.initing = false
this.$nextTick(() => {
this.$refs.form.clearValidate
this.$redirect('success?orderId=' + response.data) this.$redirect('success?orderId=' + response.data)
}) })
})
}); });
......
...@@ -427,6 +427,19 @@ ...@@ -427,6 +427,19 @@
<el-dropdown-item @click.native="$router.push({path:'/order/transfer-to-warehouse/' + scope.row.orderId + '/' + 2 })" v-hasPermi="['ecw:order:warehouse_arrive']">{{$t('调拨到仓')}}</el-dropdown-item> <el-dropdown-item @click.native="$router.push({path:'/order/transfer-to-warehouse/' + scope.row.orderId + '/' + 2 })" v-hasPermi="['ecw:order:warehouse_arrive']">{{$t('调拨到仓')}}</el-dropdown-item>
</template> </template>
<!--开始备货-->
<template v-if="
include(scope.row.airShipment, [2])
">
<el-dropdown-item @click.native="$router.push({path:'/order/stocking?id=' + scope.row.orderId})" v-hasPermi="['ecw:order:stocking']">{{$t('开始备货')}}</el-dropdown-item>
</template>
<!--修改备货-->
<template v-if="
include(scope.row.airShipment, [3, 4, 10])
">
<el-dropdown-item @click.native="$router.push({path:'/order/stocking?action=update&id=' + scope.row.orderId})" v-hasPermi="['ecw:order:stocking_update']">{{$t('修改备货')}}</el-dropdown-item>
</template>
</el-dropdown-menu> </el-dropdown-menu>
</el-dropdown> </el-dropdown>
</template> </template>
...@@ -511,7 +524,7 @@ import { ...@@ -511,7 +524,7 @@ import {
exportCustomsDatas, exportCustomsDatas,
exportShippingDatas, exportShippingDatas,
exportShipFee, exportShipFee,
exportUnload, splitCancelApply, orderSplitRevoke exportUnload, splitCancelApply, orderSplitRevoke, setCanShipment
} from "@/api/ecw/order"; } from "@/api/ecw/order";
/* import { getDictDatas, DICT_TYPE } from '@/utils/dict'; */ /* import { getDictDatas, DICT_TYPE } from '@/utils/dict'; */
import PrintTag from './components/PrintTag' import PrintTag from './components/PrintTag'
......
...@@ -104,8 +104,8 @@ ...@@ -104,8 +104,8 @@
<!-- 操作工具栏 --> <!-- 操作工具栏 -->
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="$alert('//TODO')" v-hasPermi="['ecw:order:peddingList:batch_avail4shpiing']">{{$t('批量可出')}}</el-button> <el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="batchCanShipment" v-hasPermi="['ecw:order:peddingList:batch_can_shipment']">{{$t('批量可出')}}</el-button>
<el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="$alert('//TODO')" v-hasPermi="['ecw:order:peddingList:batch_exception']">{{$t('批量转异')}}</el-button> <el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="batchException" v-hasPermi="['ecw:order:peddingList:batch_exception']">{{$t('批量转异')}}</el-button>
</el-col> </el-col>
</el-row> </el-row>
...@@ -172,7 +172,7 @@ ...@@ -172,7 +172,7 @@
<el-table-column :label="$t('操作')" align="center" class-name="small-padding fixed-width actions" width="150px"> <el-table-column :label="$t('操作')" align="center" class-name="small-padding fixed-width actions" width="150px">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" @click="$alert('// TODO')" v-hasPermi="['ecw:order:peddingList:avail4shpiing']">{{$t('可出')}}</el-button> <el-button type="text" @click="setCanShipment(scope.row)" v-hasPermi="['ecw:order:peddingList:can_shipment']">{{$t('可出')}}</el-button>
<el-button type="text" @click="printTagOrderId=scope.row.orderId" v-hasPermi="['ecw:order:peddingList:print_tag']">{{$t('打印标签')}}</el-button> <el-button type="text" @click="printTagOrderId=scope.row.orderId" v-hasPermi="['ecw:order:peddingList:print_tag']">{{$t('打印标签')}}</el-button>
</template> </template>
</el-table-column> </el-table-column>
...@@ -182,6 +182,27 @@ ...@@ -182,6 +182,27 @@
@pagination="getList" /> @pagination="getList" />
<print-tag v-if="printTagOrderId !== null" :order-id="printTagOrderId" @close="printTagOrderId=null" /> <print-tag v-if="printTagOrderId !== null" :order-id="printTagOrderId" @close="printTagOrderId=null" />
<el-dialog :title="$t('订单转异')" center :visible.sync="showBatchException">
<el-form label-position="top" label-width="200" ref="batchExceptionForm" :model="batchExceptionForm" :rules="exceptionRules">
<el-form-item :label="$t('订单号')" prop="manualExceptionType">
{{multipleSelection.map(item => item.orderNo).join(',')}}
</el-form-item>
<el-form-item :label="$t('原因类型')" prop="manualExceptionType">
<dict-selector v-model="batchExceptionForm.manualExceptionType" form-type="checkbox" :type="DICT_TYPE.MANUAL_EXCEPTION_TYPE" multiple ></dict-selector>
</el-form-item>
<el-form-item :label="$t('附件')">
<image-upload v-model="batchExceptionForm.exceptionUrls"></image-upload>
</el-form-item>
<el-form-item :label="$t('详细信息')">
<el-input v-model="batchExceptionForm.descZh" type="textarea"></el-input>
</el-form-item>
</el-form>
<span slot="footer" class="dialog-footer">
<el-button type="primary" @click="handleBatchException">{{$t('确认转异')}}</el-button>
<el-button @click="showBatchException = false">{{$t('取消')}}</el-button>
</span>
</el-dialog>
</div> </div>
</template> </template>
...@@ -216,7 +237,7 @@ import { ...@@ -216,7 +237,7 @@ import {
exportCustomsDatas, exportCustomsDatas,
exportShippingDatas, exportShippingDatas,
exportShipFee, exportShipFee,
exportUnload exportUnload, setCanShipment, canShipmentPage, batchCanShipment, batchException, waitingShipmentPage
} from "@/api/ecw/order"; } from "@/api/ecw/order";
import PrintTag from './components/PrintTag' import PrintTag from './components/PrintTag'
import PrintWarehouseReceipt from './components/PrintWarehouseReceipt' import PrintWarehouseReceipt from './components/PrintWarehouseReceipt'
...@@ -278,7 +299,25 @@ export default { ...@@ -278,7 +299,25 @@ export default {
rows: 20, rows: 20,
}, },
currencyList:[], currencyList:[],
channelList:[] channelList:[],
// 是否显示批量转异弹层
showBatchException: false,
// 批量转异表单
batchExceptionForm: {},
// 批量转异表单验证规则
exceptionRules: {
manualExceptionType: [
{ required: true, message: '请勾选原因类型', trigger: 'change' },
{
validator: (rule, value, callback) => {
if (value.length <= 0) {
callback(new Error('请勾选原因类型'))
}
callback()
}, trigger: 'change'
}
]
}
}; };
}, },
watch:{ watch:{
...@@ -323,7 +362,7 @@ export default { ...@@ -323,7 +362,7 @@ export default {
getList() { getList() {
this.loading = true; this.loading = true;
// 执行查询 // 执行查询
getOrderPage(this.combinedQueryParams).then(response => { waitingShipmentPage(this.combinedQueryParams).then(response => {
// 部分情况下,订单后面的操作下拉菜单会显示按钮,但是下来没有选项,在elTable组件更新的时候会导致渲染错误,所以要在更新渲染前清空一次list让table彻底重新渲染,避免部分更新导致异常 // 部分情况下,订单后面的操作下拉菜单会显示按钮,但是下来没有选项,在elTable组件更新的时候会导致渲染错误,所以要在更新渲染前清空一次list让table彻底重新渲染,避免部分更新导致异常
this.list = [] this.list = []
this.$nextTick(() => { this.$nextTick(() => {
...@@ -361,6 +400,45 @@ export default { ...@@ -361,6 +400,45 @@ export default {
this.ids = selection.map(item => item.orderId) this.ids = selection.map(item => item.orderId)
this.single = selection.length !== 1 this.single = selection.length !== 1
this.multiple = !selection.length this.multiple = !selection.length
},
// 设置可出
setCanShipment(row){
this.$confirm(this.$t(`您确定要将订单{orderNo}设置为可出吗?`, {orderNo: row.orderNo})).then(() =>{
return setCanShipment(row.orderId)
}).then(res =>{
this.$message.success(res.message || this.$t('操作成功'))
this.getList()
})
},
// 批量可出
batchCanShipment(){
let orderNos = this.multipleSelection.map(item => item.orderNo).join(',')
this.$confirm(this.$t(`您确定要将订单{orderNos}设置为可出吗?`, {orderNos})).then(() =>{
return batchCanShipment(this.ids)
}).then(res =>{
this.$message.success(res.message || this.$t('操作成功'))
this.getList()
})
},
// 批量转异
batchException(){
if(!this.multipleSelection.length){
return this.$message.error("暂无选择订单")
}
this.showBatchException = true
},
handleBatchException(){
// 以下代码是copilot生成,暂无接口,回头在改
this.$refs.batchExceptionForm.validate(valid => {
if (valid) {
let params = Object.assign({}, this.batchExceptionForm, {orderIds: this.ids})
batchException(params).then(res =>{
this.$message.success(res.message || this.$t('操作成功'))
this.showBatchException = false
this.getList()
})
}
})
} }
} }
}; };
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<el-form ref="form" :model="form" label-width="120px" :rules="rules"> <el-form ref="form" :model="form" label-width="120px" :rules="rules">
<!-- 海运是重货,空运是泡货 --> <!-- 海运是重货,空运是泡货 -->
<template v-if="order.transportId === 1 || order.transportId === 2"> <template v-if="applyType == 4">
<el-form-item :label="$t('原重货标准')"> <el-form-item :label="$t('原重货标准')">
{{form.orgWVolume}} kg/cbm {{form.orgWVolume}} kg/cbm
</el-form-item> </el-form-item>
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
<el-input v-model="form.wvolume" type="number" class="w-100" /> kg/cbm <el-input v-model="form.wvolume" type="number" class="w-100" /> kg/cbm
</el-form-item> </el-form-item>
</template> </template>
<template v-else> <template v-else-if="applyType == 5">
<el-form-item :label="$t('原泡货标准')"> <el-form-item :label="$t('原泡货标准')">
{{form.orgVWeight}} kg {{form.orgVWeight}} kg
</el-form-item> </el-form-item>
...@@ -19,9 +19,17 @@ ...@@ -19,9 +19,17 @@
<el-input v-model="form.vweight" type="number" class="w-100" /> kg <el-input v-model="form.vweight" type="number" class="w-100" /> kg
</el-form-item> </el-form-item>
</template> </template>
<template v-else-if="applyType == 29">
<el-form-item :label="$t('现订单泡重')">
{{form.orgVWeight}} kg
</el-form-item>
<el-form-item :label="$t('新订单泡重')" style="width: 400px" prop="clearanceFreight">
<el-input v-model="form.vweight" type="number" class="w-100" /> kg
</el-form-item>
</template>
</el-form> </el-form>
<div class="page-title">{{ $t('审批流程') }}</div> <div class="page-title">{{ $t('审批流程') }}</div>
<work-flow xmlkey="special_apply" v-model="ccIdArr" /> <work-flow :xmlkey="workFlowKey" v-model="ccIdArr" />
<div v-if="form.applyStatus != 1"> <div v-if="form.applyStatus != 1">
<el-button type="primary" @click="handleSubmit">{{ $t('提交') }}</el-button> <el-button type="primary" @click="handleSubmit">{{ $t('提交') }}</el-button>
</div> </div>
...@@ -50,7 +58,7 @@ export default { ...@@ -50,7 +58,7 @@ export default {
props: { props: {
order: Object, order: Object,
orderItem: Object, orderItem: Object,
applyType: Number // 4是重货优惠5是泡货优惠 applyType: Number // 4是重货标准优惠5是泡货标准优惠,29泡货优惠
}, },
components: { components: {
WorkFlow WorkFlow
...@@ -79,7 +87,21 @@ export default { ...@@ -79,7 +87,21 @@ export default {
}, },
computed:{ computed:{
title(){ title(){
return this.applyType == 4 ? this.$t('重货优惠申请') : this.$t('泡货优惠申请') return {
4: this.$t('重货标准优惠申请'),
5: this.$t('泡货标准优惠申请'),
29: this.$t('泡货优惠申请')
}[this.applyType]
// return this.applyType == 4 ? this.$t('重货优惠申请') : this.$t('泡货优惠申请')
},
// 流程key
workFlowKey(){
// 泡货优惠申请审核
if(this.applyType == 29){
return 'shipment_bulky_cargo'
}
// 订单特价审核
return 'special_apply'
} }
}, },
methods: { methods: {
......
...@@ -111,7 +111,10 @@ ...@@ -111,7 +111,10 @@
2.空运专线、海空联运显示泡货优惠 3,4 2.空运专线、海空联运显示泡货优惠 3,4
--> -->
<el-button v-hasPermi="['ecw:order:heavy']" type="primary" @click="showPreferentialType=4" v-if="order.transportId === 1 || order.transportId === 2">{{$t('申请重货优惠')}}</el-button> <el-button v-hasPermi="['ecw:order:heavy']" type="primary" @click="showPreferentialType=4" v-if="order.transportId === 1 || order.transportId === 2">{{$t('申请重货优惠')}}</el-button>
<el-button v-hasPermi="['ecw:order:bulky']" type="primary" @click="showPreferentialType=5" v-else>{{$t('申请泡货优惠')}}</el-button> <template v-else>
<el-button v-hasPermi="['ecw:order:bulky2']" type="primary" @click="showPreferentialType=29">{{$t('申请泡货优惠')}}</el-button>
<el-button v-hasPermi="['ecw:order:bulky']" type="primary" @click="showPreferentialType=5">{{$t('申请泡货标准优惠')}}</el-button>
</template>
<el-button type="primary" @click="$tab.closePage()">{{$t('关闭窗口')}}</el-button> <el-button type="primary" @click="$tab.closePage()">{{$t('关闭窗口')}}</el-button>
</div> </div>
</el-card> </el-card>
...@@ -122,7 +125,7 @@ ...@@ -122,7 +125,7 @@
<discount v-if="!!showAllowanceItem" :order="order" :orderItem="showAllowanceItem" @close="showAllowanceItem=null" :applyType="2" @success="onDiscountSuccess" /> <discount v-if="!!showAllowanceItem" :order="order" :orderItem="showAllowanceItem" @close="showAllowanceItem=null" :applyType="2" @success="onDiscountSuccess" />
<!-- 佣金规则 --> <!-- 佣金规则 -->
<commission v-if="!!showCommissionItem" :order="order" :orderItem="showCommissionItem" @close="showCommissionItem=null" @success="onCommissionSuccess" /> <commission v-if="!!showCommissionItem" :order="order" :orderItem="showCommissionItem" @close="showCommissionItem=null" @success="onCommissionSuccess" />
<!-- 重泡货优惠 --> <!-- 重泡货(标准)优惠 -->
<preferential v-if="!!showPreferentialType" :applyType="showPreferentialType" :order="order" @close="showPreferentialType=null" @success="onPreferentialSuccess" /> <preferential v-if="!!showPreferentialType" :applyType="showPreferentialType" :order="order" @close="showPreferentialType=null" @success="onPreferentialSuccess" />
</div> </div>
</template> </template>
......
...@@ -104,8 +104,8 @@ ...@@ -104,8 +104,8 @@
<!-- 操作工具栏 --> <!-- 操作工具栏 -->
<el-row :gutter="10" class="mb8"> <el-row :gutter="10" class="mb8">
<el-col :span="1.5"> <el-col :span="1.5">
<el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="$alert('//TODO')" v-hasPermi="['ecw:order:stockingList:export_selected']">{{$t('导出所选')}}</el-button> <el-button :disabled="!multipleSelection.length" type="primary" :loading="exporting" plain size="mini" @click="exportXls(ids)" v-hasPermi="['ecw:order:stockingList:export_selected']">{{$t('导出所选')}}</el-button>
<el-button :disabled="!multipleSelection.length" type="primary" plain size="mini" @click="$alert('//TODO')" v-hasPermi="['ecw:order:stockingList:export_search']">{{$t('导出搜索')}}</el-button> <el-button type="primary" :loading="exporting" plain size="mini" @click="exportXls(queryParams)" v-hasPermi="['ecw:order:stockingList:export_search']">{{$t('导出搜索')}}</el-button>
</el-col> </el-col>
</el-row> </el-row>
...@@ -192,7 +192,7 @@ import { getProductAttrList } from '@/api/ecw/productAttr' ...@@ -192,7 +192,7 @@ import { getProductAttrList } from '@/api/ecw/productAttr'
import CustomerSelector from '@/components/CustomerSelector' import CustomerSelector from '@/components/CustomerSelector'
import specialNeeds from '@/views/ecw/order/components/specialNeeds'; import specialNeeds from '@/views/ecw/order/components/specialNeeds';
import { getOrderPage } from "@/api/ecw/order"; import {canReadyStockShipmentPage, exportReadyStock, getOrderPage} from "@/api/ecw/order";
import PrintTag from './components/PrintTag' import PrintTag from './components/PrintTag'
import PrintWarehouseReceipt from './components/PrintWarehouseReceipt' import PrintWarehouseReceipt from './components/PrintWarehouseReceipt'
import PrintLadingBill from './components/PrintLadingBill' import PrintLadingBill from './components/PrintLadingBill'
...@@ -298,7 +298,7 @@ export default { ...@@ -298,7 +298,7 @@ export default {
getList() { getList() {
this.loading = true; this.loading = true;
// 执行查询 // 执行查询
getOrderPage(this.combinedQueryParams).then(response => { canReadyStockShipmentPage(this.combinedQueryParams).then(response => {
// 部分情况下,订单后面的操作下拉菜单会显示按钮,但是下来没有选项,在elTable组件更新的时候会导致渲染错误,所以要在更新渲染前清空一次list让table彻底重新渲染,避免部分更新导致异常 // 部分情况下,订单后面的操作下拉菜单会显示按钮,但是下来没有选项,在elTable组件更新的时候会导致渲染错误,所以要在更新渲染前清空一次list让table彻底重新渲染,避免部分更新导致异常
this.list = [] this.list = []
this.$nextTick(() => { this.$nextTick(() => {
...@@ -336,6 +336,15 @@ export default { ...@@ -336,6 +336,15 @@ export default {
this.ids = selection.map(item => item.orderId) this.ids = selection.map(item => item.orderId)
this.single = selection.length !== 1 this.single = selection.length !== 1
this.multiple = !selection.length this.multiple = !selection.length
},
// 导出
exportXls(params){
this.exporting = true
exportReadyStock(params).then(res => {
this.$download.excel(res, this.$t('备货订单') + '.xls');
}).finally(() => {
this.exporting = false
})
} }
} }
}; };
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment