|
|
|
@ -1,7 +1,7 @@
|
|
|
|
|
<template> |
|
|
|
|
<basic-container> |
|
|
|
|
<div class="avue-crud"> |
|
|
|
|
<el-row v-if="!search" style="margin-bottom: 1%"> |
|
|
|
|
<el-row v-if="!search" style="margin-bottom: 1%"> |
|
|
|
|
<!-- 列表模块 --> |
|
|
|
|
<el-table |
|
|
|
|
ref="table" |
|
|
|
@ -111,7 +111,6 @@
|
|
|
|
|
> |
|
|
|
|
</div> |
|
|
|
|
<el-row> |
|
|
|
|
|
|
|
|
|
<!-- 列表模块 --> |
|
|
|
|
<tablecmt |
|
|
|
|
:columnList="columnList" |
|
|
|
@ -192,7 +191,7 @@
|
|
|
|
|
@size-change="sizeChange" |
|
|
|
|
@current-change="currentChange" |
|
|
|
|
:current-page="page.currentPage" |
|
|
|
|
:page-sizes="[30, 50,80, 120]" |
|
|
|
|
:page-sizes="[30, 50, 80, 120]" |
|
|
|
|
:page-size="page.pageSize" |
|
|
|
|
layout="total, sizes, prev, pager, next, jumper" |
|
|
|
|
:total="page.total" |
|
|
|
@ -331,10 +330,7 @@
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
<script> |
|
|
|
|
|
|
|
|
|
import { |
|
|
|
|
Search |
|
|
|
|
} from '@element-plus/icons-vue' |
|
|
|
|
import { Search } from '@element-plus/icons-vue'; |
|
|
|
|
|
|
|
|
|
import { |
|
|
|
|
getList, |
|
|
|
@ -447,7 +443,8 @@ export default {
|
|
|
|
|
fixed: true, |
|
|
|
|
sortable: true, |
|
|
|
|
head: false, |
|
|
|
|
}, { |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
prop: 'orderCode', |
|
|
|
|
label: '订单自编号', |
|
|
|
|
type: 2, |
|
|
|
@ -726,11 +723,10 @@ export default {
|
|
|
|
|
'$route.query.id': { |
|
|
|
|
handler(newVal, oldVal) { |
|
|
|
|
// console.log(newVal, oldVal); |
|
|
|
|
if(!!this.$route.query.id){ |
|
|
|
|
if (!!this.$route.query.id) { |
|
|
|
|
this.onLoad(this.page); |
|
|
|
|
this.onLoadOwn(this.page); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
deep: true, |
|
|
|
|
immediate: true, |
|
|
|
@ -844,13 +840,22 @@ export default {
|
|
|
|
|
this.onLoadOwn(this.page); |
|
|
|
|
}, |
|
|
|
|
printTemplate() { |
|
|
|
|
console.log('111 :>> ', 111); |
|
|
|
|
const orderNodeList = document.querySelectorAll('.el-dialog__body>div>div>div'); |
|
|
|
|
orderNodeList.forEach(orderNode => { |
|
|
|
|
console.log('orderNode :>> ', orderNode); |
|
|
|
|
// console.log('orderNode.innerHTML :>> ', orderNode.innerHTML); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
let LODOP = getLodop(); |
|
|
|
|
console.log("LODOP>>>>>",LODOP); |
|
|
|
|
console.log('LODOP>>>>>', LODOP); |
|
|
|
|
// console.log("this.ids>>>>>",this.selectionList); |
|
|
|
|
// if (this.selectionList.length === 0){ |
|
|
|
|
// this.$message.warning("请选择至少一条数据"); |
|
|
|
|
// return; |
|
|
|
|
// } |
|
|
|
|
|
|
|
|
|
// 注释 |
|
|
|
|
getStockTemplate({ id: this.materialQRCode.id }).then(res => { |
|
|
|
|
console.log('返回的数据', res.data.data); |
|
|
|
|
let templateData = res.data.data; |
|
|
|
@ -858,7 +863,7 @@ export default {
|
|
|
|
|
// console.log(templateData); |
|
|
|
|
LODOP.PRINT_INITA(1, 1, 900, 660, '测试预览功能'); |
|
|
|
|
LODOP.SET_PRINT_MODE('WINDOW_DEFPRINTER', 'Godex G500'); |
|
|
|
|
LODOP.SET_PRINT_STYLEA(0,"TextNeatRow",true);//允许标点溢出,且英文单词拆开 |
|
|
|
|
LODOP.SET_PRINT_STYLEA(0, 'TextNeatRow', true); //允许标点溢出,且英文单词拆开 |
|
|
|
|
// // 设置打印整宽且不变形 |
|
|
|
|
LODOP.SET_PRINT_MODE('PRINT_PAGE_PERCENT', 'Auto-Width'); |
|
|
|
|
// // 设置打印后自动关闭 |
|
|
|
@ -867,7 +872,6 @@ export default {
|
|
|
|
|
LODOP.ADD_PRINT_HTM('0%', '0%', '100%', '100%', templateData); |
|
|
|
|
// LODOP.PREVIEW(); //预览(预览打印无脚标) |
|
|
|
|
LODOP.PRINT(); //直接打印 |
|
|
|
|
|
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
//提交物品数据 |
|
|
|
@ -887,9 +891,9 @@ export default {
|
|
|
|
|
// console.log("包含非数字字符"); |
|
|
|
|
asm.materialId = this.formMaterial.materialCode; |
|
|
|
|
} |
|
|
|
|
if(!!this.formMaterial.id){ |
|
|
|
|
if (!!this.formMaterial.id) { |
|
|
|
|
id.push(this.formMaterial.id); |
|
|
|
|
}else{ |
|
|
|
|
} else { |
|
|
|
|
if (this.selectionList.length > 0) { |
|
|
|
|
this.selectionList.forEach(i => { |
|
|
|
|
id.push(i.id); |
|
|
|
@ -1101,12 +1105,14 @@ export default {
|
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
getDictionaryBiz('order_package_grounding_status').then(res => { |
|
|
|
|
this.$functions.checkcColumnList('orderPackageGroundingStatusName', this.columnList).checkarr = |
|
|
|
|
res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
this.$functions.checkcColumnList( |
|
|
|
|
'orderPackageGroundingStatusName', |
|
|
|
|
this.columnList |
|
|
|
|
).checkarr = res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
getDictionaryBiz('order_package_freeze_status').then(res => { |
|
|
|
|
this.$functions.checkcColumnList('orderPackageFreezeStatusName', this.columnList).checkarr = |
|
|
|
@ -1117,20 +1123,24 @@ export default {
|
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
getDictionaryBiz('order_package_stockup_status').then(res => { |
|
|
|
|
this.$functions.checkcColumnList('orderPackageStockupStatusName', this.columnList).checkarr = |
|
|
|
|
res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
this.$functions.checkcColumnList( |
|
|
|
|
'orderPackageStockupStatusName', |
|
|
|
|
this.columnList |
|
|
|
|
).checkarr = res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
getDictionaryBiz('order_package_reservation_status').then(res => { |
|
|
|
|
this.$functions.checkcColumnList('orderPackageReservationStatusName', this.columnList).checkarr = |
|
|
|
|
res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
this.$functions.checkcColumnList( |
|
|
|
|
'orderPackageReservationStatusName', |
|
|
|
|
this.columnList |
|
|
|
|
).checkarr = res.data.data.map(item => { |
|
|
|
|
item.value = item.dictKey; |
|
|
|
|
item.label = item.dictValue; |
|
|
|
|
return item; |
|
|
|
|
}); |
|
|
|
|
}); |
|
|
|
|
}, |
|
|
|
|
searchHide() { |
|
|
|
@ -1252,17 +1262,17 @@ export default {
|
|
|
|
|
this.materialBox = true; |
|
|
|
|
this.formMaterial.id = row.id; |
|
|
|
|
}, |
|
|
|
|
allhandleQRCode(){ |
|
|
|
|
console.log(this.selectionList) |
|
|
|
|
if(this.selectionList.length==0){ |
|
|
|
|
this.$message.error({message:'请先选择包件'}) |
|
|
|
|
return |
|
|
|
|
allhandleQRCode() { |
|
|
|
|
console.log(this.selectionList); |
|
|
|
|
if (this.selectionList.length == 0) { |
|
|
|
|
this.$message.error({ message: '请先选择包件' }); |
|
|
|
|
return; |
|
|
|
|
} |
|
|
|
|
let checkcode=[] |
|
|
|
|
this.selectionList.map(item=>{ |
|
|
|
|
checkcode.push(item.id) |
|
|
|
|
let checkcode = []; |
|
|
|
|
this.selectionList.map(item => { |
|
|
|
|
checkcode.push(item.id); |
|
|
|
|
// checkcode.push(item.orderPackageCode) |
|
|
|
|
}) |
|
|
|
|
}); |
|
|
|
|
// return |
|
|
|
|
let qr = { |
|
|
|
|
ids: checkcode.join(','), |
|
|
|
@ -1271,9 +1281,8 @@ export default {
|
|
|
|
|
showOrderPackgeCode(qr).then(res => { |
|
|
|
|
// this.orderPackageCode = res.data |
|
|
|
|
console.log(res.data); |
|
|
|
|
this.html='' |
|
|
|
|
this.html=this.getHtmls(res.data.data.dataList,res.data.data.templateHtml) |
|
|
|
|
|
|
|
|
|
this.html = ''; |
|
|
|
|
this.html = this.getHtmls(res.data.data.dataList, res.data.data.templateHtml); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
this.dialogVisible = true; |
|
|
|
@ -1290,9 +1299,8 @@ export default {
|
|
|
|
|
showOrderPackgeCode(qr).then(res => { |
|
|
|
|
// this.orderPackageCode = res.data |
|
|
|
|
console.log(res.data); |
|
|
|
|
this.html='' |
|
|
|
|
this.html=this.getHtmls(res.data.data.dataList,res.data.data.templateHtml) |
|
|
|
|
|
|
|
|
|
this.html = ''; |
|
|
|
|
this.html = this.getHtmls(res.data.data.dataList, res.data.data.templateHtml); |
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
this.dialogVisible = true; |
|
|
|
@ -1370,13 +1378,13 @@ export default {
|
|
|
|
|
}, |
|
|
|
|
onLoad(page, params = {}) { |
|
|
|
|
this.loading = true; |
|
|
|
|
console.log("执行了查询零零零零"); |
|
|
|
|
console.log('执行了查询零零零零'); |
|
|
|
|
this.query.ids = this.$route.query.id; |
|
|
|
|
getDetail(this.$route.query.id).then(res => { |
|
|
|
|
console.log("返回的数据》》》》",res.data.data); |
|
|
|
|
console.log('返回的数据》》》》', res.data.data); |
|
|
|
|
const data = res.data.data; |
|
|
|
|
// this.page.total = data.total; |
|
|
|
|
this.data[0]= data; |
|
|
|
|
this.data[0] = data; |
|
|
|
|
|
|
|
|
|
this.loading = false; |
|
|
|
|
this.selectionClear(); |
|
|
|
@ -1414,7 +1422,7 @@ export default {
|
|
|
|
|
}; |
|
|
|
|
</script> |
|
|
|
|
<style lang="scss" scoped> |
|
|
|
|
.plck{ |
|
|
|
|
.plck { |
|
|
|
|
display: flex; |
|
|
|
|
align-items: center; |
|
|
|
|
justify-content: flex-end; |
|
|
|
|