|
@@ -268,7 +268,7 @@
|
|
|
<declareElements-modal ref="declareElementsModal" @table="getShipmentList" @close-declare="closeDeclare"></declareElements-modal>
|
|
|
|
|
|
<!-- 维护款号成分 -->
|
|
|
- <itemNumEle-modal ref="itemNumEleModal" :fatherList="getShipmentList"></itemNumEle-modal>
|
|
|
+ <itemNumEle-modal ref="itemNumEleModal" @close="judageAdd"></itemNumEle-modal>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -435,17 +435,6 @@ export default {
|
|
|
ellipsis: true,
|
|
|
className: 'replacecolor'
|
|
|
},
|
|
|
- // {
|
|
|
- // title: '预完工日期',
|
|
|
- // dataIndex: 'preCompletionDate',
|
|
|
- // width: 120,
|
|
|
- // customRender: text => {
|
|
|
- // if (text == "" || text == null)
|
|
|
- // return "";
|
|
|
- // return moment(text).format('YYYY-MM-DD')
|
|
|
- // },
|
|
|
- // className: 'replacecolor'
|
|
|
- // },
|
|
|
|
|
|
{
|
|
|
title: '存货名称',
|
|
@@ -476,13 +465,6 @@ export default {
|
|
|
// customRender: t => ellipsis(t),
|
|
|
ellipsis: true,
|
|
|
},
|
|
|
- // {
|
|
|
- // title: '单价(销售)',
|
|
|
- // dataIndex: 'salesUnitPrice',
|
|
|
- // width: 120,
|
|
|
- // className: 'replacecolor',
|
|
|
-
|
|
|
- // },
|
|
|
|
|
|
{
|
|
|
title: '采购/委外订单号',
|
|
@@ -491,25 +473,6 @@ export default {
|
|
|
className: 'replacecolor',
|
|
|
ellipsis: true,
|
|
|
},
|
|
|
- // {
|
|
|
- // title: '订单类型',
|
|
|
- // dataIndex: 'orderType',
|
|
|
- // width: 120,
|
|
|
- // className: 'replacecolor'
|
|
|
- // },
|
|
|
- // {
|
|
|
- // // (采购/委外单价)
|
|
|
- // title: '工厂单价',
|
|
|
- // dataIndex: 'factoryUnitPrice',
|
|
|
- // width: 120,
|
|
|
- // className: 'replacecolor'
|
|
|
- // },
|
|
|
- // {
|
|
|
- // title: '申报要素(单证维护)',
|
|
|
- // dataIndex: 'declarationElements',
|
|
|
- // width: 120,
|
|
|
- // className: 'replacecolor'
|
|
|
- // },
|
|
|
{
|
|
|
// (存货自定义项)
|
|
|
title: '套装件数',
|
|
@@ -577,21 +540,6 @@ export default {
|
|
|
|
|
|
// 查询条件
|
|
|
queryParam: {
|
|
|
- // orderNumber: '', // 订单号
|
|
|
- // startTime: '',
|
|
|
- // supplier:'',//供应商
|
|
|
- // endTime: '',
|
|
|
- // preDeliveryDateB:'',//预发货日期开始时间
|
|
|
- // preDeliveryDateE:'',//预发货日期结束时间
|
|
|
- // // timeRange: [], // 查询条件 时间范围
|
|
|
- // // preDeliveryDate: '',
|
|
|
- // isElement:'',//申报要素是否维护
|
|
|
- // salesman: '',
|
|
|
- // itemNumber: '', // 款号
|
|
|
- // refer: '',
|
|
|
- // flourOrGarment: '', //类型
|
|
|
- // pageSize:20,//每页条数
|
|
|
- // pageNo: '' // 点击的页数
|
|
|
},
|
|
|
selectedRowKeys:[],
|
|
|
selectedRows:[],
|
|
@@ -663,20 +611,8 @@ export default {
|
|
|
//关闭申报要素弹窗
|
|
|
async closeDeclare(){
|
|
|
//判断是否是新增的数据
|
|
|
- if(!this.queryParam.flourOrGarment || this.queryParam.flourOrGarment == ''){
|
|
|
- this.queryParam ={}
|
|
|
- this.queryParam.id = this.returnId
|
|
|
- this.queryParam.flourOrGarment =this.returnFlourOrGarment
|
|
|
- await this.getShipmentList()
|
|
|
- this.queryParam = {}
|
|
|
- this.defalutDate()
|
|
|
- }else{
|
|
|
- await this.getShipmentList()
|
|
|
- }
|
|
|
-
|
|
|
- // this.getShipmentList()
|
|
|
+ await this.judageAdd()
|
|
|
var cc = []
|
|
|
- // for(var i= 0;i<this.shipmentListData)
|
|
|
this.shipmentListData.map(item =>{
|
|
|
this.selectedRows.map(item1 =>{
|
|
|
if(item.itemIds == item1.itemIds){
|
|
@@ -697,19 +633,11 @@ export default {
|
|
|
//参照订单数据
|
|
|
referOrderDataOpen(){
|
|
|
this.$refs.referOrderDataModal.referOrderDataModVis = true
|
|
|
- // this.defalutDate()
|
|
|
this.$refs.referOrderDataModal.range.push(this.monthStartDate)
|
|
|
this.$refs.referOrderDataModal.queryParam.preDeliveryDateS = this.monthStartDate;
|
|
|
this.$refs.referOrderDataModal.queryParam.preDeliveryDateE = '';
|
|
|
},
|
|
|
|
|
|
- // //参照数据重置,恢复默认值
|
|
|
- // defaultReset() {
|
|
|
- // this.defalutDate()
|
|
|
- // this.$refs.referOrderDataModal.range.push(this.monthStartDate)
|
|
|
- // this.$refs.referOrderDataModal.queryParam.preDeliveryDateS = this.monthStartDate;
|
|
|
- // this.$refs.referOrderDataModal.queryParam.preDeliveryDateE = '';
|
|
|
- // },
|
|
|
|
|
|
// 申报要素
|
|
|
declareElements(record) {
|
|
@@ -761,6 +689,21 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
|
|
|
+ //判断是否是新增的数据
|
|
|
+ async judageAdd(){
|
|
|
+ if(!this.queryParam.flourOrGarment || this.queryParam.flourOrGarment == ''){
|
|
|
+ this.queryParam ={}
|
|
|
+ this.queryParam.id = this.returnId
|
|
|
+ this.queryParam.flourOrGarment =this.returnFlourOrGarment
|
|
|
+ await this.getShipmentList()
|
|
|
+ this.queryParam = {}
|
|
|
+ this.defalutDate()
|
|
|
+ }else{
|
|
|
+ await this.getShipmentList()
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+
|
|
|
// 导出
|
|
|
handleExportXls(fileName) {
|
|
|
|
|
@@ -843,7 +786,6 @@ export default {
|
|
|
// 详情
|
|
|
details(record) {
|
|
|
this.$refs.detailsShipDetDrawer.visible = true
|
|
|
- // console.log('点击项的ID', record.id)
|
|
|
queryByDetails({ id: record.id,itemIds: record.itemIds}).then(res => {
|
|
|
if (res.success) {
|
|
|
console.log('点击的对象', res.result)
|
|
@@ -856,7 +798,6 @@ export default {
|
|
|
|
|
|
// 提交
|
|
|
submit() {
|
|
|
- // console.log('点击id:', record.id)
|
|
|
this.$nextTick(() => {
|
|
|
// for(var i =0;i<this.selectedRows.length;i++){
|
|
|
// var selectRow = this.selectedRows[i]
|
|
@@ -878,9 +819,12 @@ export default {
|
|
|
console.log('提交成功,单据状态改为【已提交】')
|
|
|
this.shipmentListData.submitStatus = '1'
|
|
|
this.selectedRowKeys =[]
|
|
|
- this.getShipmentList() // 渲染 发运明细列表
|
|
|
+ //判断是否是新增的数据
|
|
|
+ this.judageAdd()
|
|
|
+ // 渲染 发运明细列表
|
|
|
this.$message.success('提交成功')
|
|
|
}else {
|
|
|
+ this.judageAdd()
|
|
|
this.$message.error(res.message)
|
|
|
}
|
|
|
})
|
|
@@ -895,7 +839,7 @@ export default {
|
|
|
console.log('取消提交成功,单据状态改为【仅保存】')
|
|
|
this.shipmentListData.submitStatus = '0'
|
|
|
this.selectedRowKeys = []
|
|
|
- this.getShipmentList() // 渲染 发运明细列表
|
|
|
+ this.judageAdd()
|
|
|
this.$message.success('取消提交成功')
|
|
|
}else {
|
|
|
this.$message.error(res.message)
|
|
@@ -915,7 +859,7 @@ export default {
|
|
|
if (res.success) {
|
|
|
console.log('推送成功,推送状态【推送成功】')
|
|
|
this.shipmentListData.pushState = '1'
|
|
|
- this.getShipmentList() // 渲染 发运明细列表
|
|
|
+ this.judageAdd()
|
|
|
this.$message.success('推送成功')
|
|
|
}else {
|
|
|
this.$message.error(res.message)
|
|
@@ -937,7 +881,7 @@ export default {
|
|
|
if (res.success) {
|
|
|
console.log('重新推送成功,推送状态【推送成功】')
|
|
|
this.shipmentListData.pushState = '1'
|
|
|
- this.getShipmentList() // 渲染 发运明细列表
|
|
|
+ this.judageAdd()
|
|
|
this.$message.success('重新推送成功')
|
|
|
}else {
|
|
|
this.$message.error(res.message)
|
|
@@ -954,7 +898,7 @@ export default {
|
|
|
this.$nextTick(() => {
|
|
|
deleteShipment({ id: record.id,itemIds: record.itemIds }).then(res => {
|
|
|
console.log('res:', res)
|
|
|
- this.getShipmentList() // 渲染 发运明细列表
|
|
|
+ this.judageAdd() // 渲染 发运明细列表
|
|
|
this.$message.success('删除成功')
|
|
|
})
|
|
|
})
|
|
@@ -1004,25 +948,12 @@ export default {
|
|
|
},
|
|
|
|
|
|
searchReset() {
|
|
|
- // this.queryParam.isElement = ''
|
|
|
- // this.queryParam.orderNumber = ''
|
|
|
- // this.queryParam.supplier = ''
|
|
|
this.queryParam = {}
|
|
|
this.timeRange = []
|
|
|
this.preDeliveryDate = []
|
|
|
this.defalutDate()
|
|
|
- // this.queryParam.startTime = ''
|
|
|
- // this.queryParam.endTime = ''
|
|
|
- // this.queryParam.preDeliveryDateB = ''
|
|
|
- // this.queryParam.preDeliveryDateE = ''
|
|
|
- // this.queryParam.salesman = ''
|
|
|
- // this.queryParam.itemNumber = ''
|
|
|
- // this.queryParam.refer = ''
|
|
|
- // this.queryParam.isTc = ''
|
|
|
- // this.queryParam.pageSize = 20
|
|
|
this.selectedRows = []
|
|
|
this.selectedRowKeys = []
|
|
|
- // this.queryParam.flourOrGarment = '', //类型
|
|
|
this.shipmentListData = [] // 渲染 发运明细列表
|
|
|
},
|
|
|
|
|
@@ -1046,27 +977,12 @@ export default {
|
|
|
//其他地方使用
|
|
|
this.returnId = id
|
|
|
this.returnFlourOrGarment = data
|
|
|
- // this.timeRange = []
|
|
|
- // this.preDeliveryDate = []
|
|
|
- // this.shipmentListData = [] // 渲染 发运明细列表
|
|
|
await this.getShipmentList()
|
|
|
this.queryParam = {}
|
|
|
this.defalutDate()
|
|
|
},
|
|
|
async closeAddEdit(){
|
|
|
- // if(!this.queryParam.flourOrGarment || this.queryParam.flourOrGarment == ''){
|
|
|
- // this.queryParam ={}
|
|
|
- // this.queryParam.id = this.returnId
|
|
|
- // this.queryParam.flourOrGarment =this.returnFlourOrGarment
|
|
|
- // await this.getShipmentList()
|
|
|
- // this.queryParam = {}
|
|
|
- // this.defalutDate()
|
|
|
- // }else{
|
|
|
- // await this.getShipmentList()
|
|
|
- // }
|
|
|
- // this.queryParam.preDeliveryDateB='',
|
|
|
- // this.queryParam.preDeliveryDateE = ''
|
|
|
- await this.getShipmentList()
|
|
|
+ this.judageAdd()
|
|
|
}
|
|
|
}
|
|
|
}
|