Browse Source

BUG修改

master
yejiaxing 12 months ago
parent
commit
219b5c1795
  1. 189
      src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/supplierdeliverRecordMain.data.ts
  2. 71
      src/views/wms/supplierManage/purchaseclaim/purchaseclaimRequestMain/index.vue

189
src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRecordMain/supplierdeliverRecordMain.data.ts

@ -391,57 +391,136 @@ export const SupplierdeliverRecordMainRules = reactive({
* @returns {Array}
*/
export const SupplierdeliverRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
// {
// label: '从包装号',
// field: 'fromPackingNumber',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '到包装号',
// field: 'toPackingNumber',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '从批次',
// field: 'fromBatch',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '到批次',
// field: 'toBatch',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '替代批次',
// field: 'altBatch',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '从器具号',
// field: 'fromContainerNumber',
// sort: 'custom',
// table: {
// width: 150
// },
// },
// {
// label: '到器具号',
// field: 'toContainerNumber',
// sort: 'custom',
// table: {
// width: 150
// },
// },
{
label: '订单号',
field: 'poNumber',
sort: 'custom',
table: {
width: 150
},
},
{
label: '从包装号',
field: 'fromPackingNumber',
label: '订单行',
field: 'poLine',
sort: 'custom',
table: {
width: 150
},
},
{
label: '到包装号',
field: 'toPackingNumber',
label: '物品代码',
field: 'itemCode',
sort: 'custom',
table: {
width: 150
},
},
{
label: '从批次',
field: 'fromBatch',
label: '数量',
field: 'qty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '到批次',
field: 'toBatch',
label: '标包数量',
field: 'stdPackQty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '替代批次',
field: 'altBatch',
label: '标包单位',
field: 'stdPackUnit',
dictType: DICT_TYPE.PACK_UNIT,
dictClass: 'string',
isTable: true,
sort: 'custom',
table: {
width: 150
},
},
{
label: '从器具号',
field: 'fromContainerNumber',
label: '供应商计量数量',
field: 'supplierQty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '到器具号',
field: 'toContainerNumber',
label: '供应商计量单位',
field: 'supplierUom',
dictType: DICT_TYPE.UOM,
dictClass: 'string',
isTable: true,
sort: 'custom',
table: {
width: 150
@ -507,66 +586,7 @@ export const SupplierdeliverRecordDetail = useCrudSchemas(reactive<CrudSchema[]>
}
},
},
{
label: '订单号',
field: 'poNumber',
sort: 'custom',
table: {
width: 150
},
},
{
label: '订单行',
field: 'poLine',
sort: 'custom',
table: {
width: 150
},
},
{
label: '标包数量',
field: 'stdPackQty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '标包单位',
field: 'stdPackUnit',
dictType: DICT_TYPE.PACK_UNIT,
dictClass: 'string',
isTable: true,
sort: 'custom',
table: {
width: 150
},
},
{
label: '供应商计量数量',
field: 'supplierQty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '供应商计量单位',
field: 'supplierUom',
dictType: DICT_TYPE.UOM,
dictClass: 'string',
isTable: true,
sort: 'custom',
table: {
width: 150
},
},
{
label: '从库位代码',
field: 'fromLocationCode',
@ -631,14 +651,7 @@ export const SupplierdeliverRecordDetail = useCrudSchemas(reactive<CrudSchema[]>
width: 150
},
},
{
label: '物品代码',
field: 'itemCode',
sort: 'custom',
table: {
width: 150
},
},
{
label: '物品名称',
field: 'itemName',
@ -671,17 +684,7 @@ export const SupplierdeliverRecordDetail = useCrudSchemas(reactive<CrudSchema[]>
width: 150
},
},
{
label: '数量',
field: 'qty',
sort: 'custom',
table: {
width: 150
},
form: {
component: 'InputNumber',
}
},
{
label: '计量单位',
field: 'uom',

71
src/views/wms/supplierManage/purchaseclaim/purchaseclaimRequestMain/index.vue

@ -7,19 +7,13 @@
</ContentWrap>
<!-- 列表头部 -->
<TableHead
:HeadButttondata="HeadButttondata"
@button-base-click="buttonBaseClick"
:routeName="routeName"
@updataTableColumns="updataTableColumns"
@searchFormClick="searchFormClick"
:allSchemas="PurchaseclaimRequestMain.allSchemas"
/>
<TableHead :HeadButttondata="HeadButttondata" @button-base-click="buttonBaseClick" :routeName="routeName"
@updataTableColumns="updataTableColumns" @searchFormClick="searchFormClick"
:allSchemas="PurchaseclaimRequestMain.allSchemas" />
<!-- 列表 -->
<ContentWrap>
<Table :columns="tableColumns" :data="tableObject.tableList"
:loading="tableObject.loading" :pagination="{
<Table :columns="tableColumns" :data="tableObject.tableList" :loading="tableObject.loading" :pagination="{
total: tableObject.total
}" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage"
v-model:sort="tableObject.sort">
@ -35,36 +29,22 @@
</ContentWrap>
<!-- 表单弹窗添加/修改 -->
<BasicForm
ref="formRef"
@success="getList"
:rules="PurchaseclaimRequestMainRules"
:formAllSchemas="PurchaseclaimRequestMain.allSchemas"
:tableAllSchemas="PurchaseclaimRequestDetail.allSchemas"
:tableFormRules="PurchaseclaimRequestDetailRules"
:tableData="tableData"
<BasicForm ref="formRef" @success="getList" :rules="PurchaseclaimRequestMainRules"
:formAllSchemas="PurchaseclaimRequestMain.allSchemas" :tableAllSchemas="PurchaseclaimRequestDetail.allSchemas"
:tableFormRules="PurchaseclaimRequestDetailRules" :tableData="tableData"
:apiUpdate="PurchaseclaimRequestMainApi.updatePurchaseclaimRequestMain"
:apiCreate="PurchaseclaimRequestMainApi.createPurchaseclaimRequestMain"
:isBusiness="true"
@handleAddTable="handleAddTable"
@handleDeleteTable="handleDeleteTable"
@searchTableSuccess="searchTableSuccess"
@submitForm="submitForm"
/>
:apiCreate="PurchaseclaimRequestMainApi.createPurchaseclaimRequestMain" :isBusiness="true"
@handleAddTable="handleAddTable" @handleDeleteTable="handleDeleteTable" @searchTableSuccess="searchTableSuccess"
@submitForm="submitForm" />
<!-- 详情 -->
<Detail
ref="detailRef"
:isBasic="false"
:allSchemas="PurchaseclaimRequestMain.allSchemas"
:detailAllSchemas="PurchaseclaimRequestDetail.allSchemas"
:detailAllSchemasRules="PurchaseclaimRequestDetailRules"
<Detail ref="detailRef" :isBasic="false" :allSchemas="PurchaseclaimRequestMain.allSchemas"
:detailAllSchemas="PurchaseclaimRequestDetail.allSchemas" :detailAllSchemasRules="PurchaseclaimRequestDetailRules"
:apiCreate="PurchaseclaimRequestDetailApi.createPurchaseclaimRequestDetail"
:apiUpdate="PurchaseclaimRequestDetailApi.updatePurchaseclaimRequestDetail"
:apiPage="PurchaseclaimRequestDetailApi.getPurchaseclaimRequestDetailPage"
:apiDelete="PurchaseclaimRequestDetailApi.deletePurchaseclaimRequestDetail"
@searchTableSuccessDetail="searchTableSuccessDetail"
/>
@searchTableSuccessDetail="searchTableSuccessDetail" />
<!-- 导入 -->
<ImportForm ref="importFormRef" url="/wms/purchaseclaim-request-main/import" :importTemplateData="importTemplateData"
@ -99,8 +79,10 @@ const updataTableColumns = (val) => {
//
const searchTableSuccess = (formField, searchField, val, formRef, type, row) => {
nextTick(() => {
if (type == 'tableForm') {
//
row[formField] = val[0][searchField]
row['poLine'] = val[0]['poLine']
@ -117,6 +99,25 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
//
const setV = {}
setV[formField] = val[0][searchField]
if(formField=='asnNumber'){
// getBomDisassemble
PurchasePlanDetailApi.getPurchasePlanDetailList({
number: val[0]['asnNumber']}).then(res => {
if (res) tableData.value = res;
tableData.value.forEach(item=>{
item.batch = item.toBatch
item.qty = 1
})
}).catch(err => {
console.log(err)
})
}
setV['ppNumber'] = val[0]['ppNumber']
setV['supplierCode'] = val[0]['supplierCode']
formRef.setValues(setV)
@ -125,7 +126,9 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
}
//
const searchTableSuccessDetail = (formField, searchField, val, formRef) => {
console.log(456)
nextTick(() => {
const setV = {}
setV[formField] = val[0][searchField]
setV['poLine'] = val[0]['poLine']
@ -314,9 +317,7 @@ const submitForm = async (formType, data) => {
getList()
} finally {
formRef.value.formLoading = false
}
}
/** 导入 */

Loading…
Cancel
Save