|
|
@@ -2,7 +2,7 @@
|
|
|
<div>
|
|
|
<detail-template :headData="mainAreaData" :title="'发货单号:' + mainData.billno" :tabs="['发货明细']" size="small" :hideBorder="false" ownertable="sa_dispatch">
|
|
|
<template #tab0>
|
|
|
- <prod-temp ref="prod" :columns="columns" :param="{id:20221115104703,content:{sa_dispatchid:router.currentRoute.value.query.id,pageNumber:1,pageSize:20,where:{condition:search}}}" size="small" :hideBorder="false">
|
|
|
+ <prod-temp ref="prod" :columns="utils.TBLayout('detailsTable')" :param="{id:20221115104703,content:{sa_dispatchid:router.currentRoute.value.query.id,pageNumber:1,pageSize:20,where:{condition:search}}}" size="small" :hideBorder="false">
|
|
|
<template #operation>
|
|
|
<a-input class="search-input" v-model:value="search" @keyup.enter="prod.listData()" placeholder="搜索商品"></a-input>
|
|
|
</template>
|
|
|
@@ -34,74 +34,6 @@ const mainData = ref({})
|
|
|
const mainAreaData = ref([])
|
|
|
const search = ref('')
|
|
|
const prod = ref()
|
|
|
-const columns = [
|
|
|
- {
|
|
|
- title:'订单号',
|
|
|
- dataIndex:'sonum',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'商品名称',
|
|
|
- dataIndex:'itemname',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'商品编号',
|
|
|
- dataIndex:'itemno',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'型号',
|
|
|
- dataIndex:'model',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'规格',
|
|
|
- dataIndex:'spec',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'单价',
|
|
|
- dataIndex:'price',
|
|
|
- width:90,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'单位',
|
|
|
- dataIndex:'unitname',
|
|
|
- width:90,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'数量',
|
|
|
- dataIndex:'qty',
|
|
|
- width:90,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'发货金额',
|
|
|
- dataIndex:'amount',
|
|
|
- width:90,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'未发数量',
|
|
|
- dataIndex:'undeliqty',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- },
|
|
|
- {
|
|
|
- title:'备注',
|
|
|
- dataIndex:'remarks',
|
|
|
- width:180,
|
|
|
- ellipsis:true,
|
|
|
- }
|
|
|
-]
|
|
|
const queryMainData = async () => {
|
|
|
const res = await Api.requested({
|
|
|
"id":20221114135303,
|
|
|
@@ -110,48 +42,10 @@ const queryMainData = async () => {
|
|
|
}
|
|
|
})
|
|
|
mainData.value = res.data
|
|
|
- changeDataStructure()
|
|
|
+ changeDataStructure(res.data)
|
|
|
}
|
|
|
-const changeDataStructure = ()=> {
|
|
|
- mainAreaData.value = [
|
|
|
- {
|
|
|
- label:'订单号',
|
|
|
- value:mainData.value.sonum
|
|
|
- },
|
|
|
- {
|
|
|
- label:'发货日期',
|
|
|
- value:mainData.value.billdate
|
|
|
- },
|
|
|
- {
|
|
|
- label:'经销商编码',
|
|
|
- value:mainData.value.agentnum
|
|
|
- },
|
|
|
- {
|
|
|
- label:'经销商名称',
|
|
|
- value:mainData.value.enterprisename
|
|
|
- },
|
|
|
- {
|
|
|
- label:'状态',
|
|
|
- value:mainData.value.STATUS,
|
|
|
- style:()=>{
|
|
|
- return {color:utils.statusAndColor(mainData.value.STATUS)}
|
|
|
- },
|
|
|
- },
|
|
|
- {
|
|
|
- label:'发货数量',
|
|
|
- value:mainData.value.qty
|
|
|
- },
|
|
|
- {
|
|
|
- label:'发货金额',
|
|
|
- value:mainData.value.sumamount ? utils.formatAmount(mainData.value.sumamount) : '--',
|
|
|
- span:6
|
|
|
- },
|
|
|
- {
|
|
|
- label:'备注',
|
|
|
- value:mainData.value.remarks,
|
|
|
- span:6
|
|
|
- },
|
|
|
- ]
|
|
|
+const changeDataStructure = (data)=> {
|
|
|
+ mainAreaData.value = utils.FormLayout('detailsHead',data)
|
|
|
}
|
|
|
onMounted(()=>{
|
|
|
queryMainData()
|