Browse Source

供应商发票修改

master_hella_20240701
zhaoxuebing 8 months ago
parent
commit
de6146e9ea
  1. 18
      src/api/wms/supplierinvoiceRequestMain/index.ts
  2. 179
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue
  3. 596
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

18
src/api/wms/supplierinvoiceRequestMain/index.ts

@ -68,14 +68,24 @@ export const cloSupplierinvoiceRequestMain = async (id: number) => {
export const subSupplierinvoiceRequestMain = async (id: number) => { export const subSupplierinvoiceRequestMain = async (id: number) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/sub?id=` + id }) return await request.post({ url: `/wms/supplierinvoice-request-main/sub?id=` + id })
} }
// 审批通过供应商发货申请主 // 供应商--审批通过供应商发货申请主
export const appSupplierinvoiceRequestMain = async (id: number) => { export const appSupplierinvoiceRequestMain = async (id: number) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/app?id=` + id }) return await request.post({ url: `/wms/supplierinvoice-request-main/app?id=` + id })
} }
// 驳回供应商发货申请主 // 供应商--驳回供应商发货申请主
export const rejSupplierinvoiceRequestMain = async (id: number) => { export const rejSupplierinvoiceRequestMain = async (id: number) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/rej?id=` + id }) return await request.post({ url: `/wms/supplierinvoice-request-main/rej?id=` + id })
} }
// 财务--审批通过供应商发货申请主
export const financeappSupplierinvoiceRequestMain = async (id: number) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/financeApp?id=` + id })
}
// 财务--驳回供应商发货申请主
export const financerejSupplierinvoiceRequestMain = async (id: number) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/financeRej?id=` + id })
}
// 生成记录 // 生成记录
export const genRecordsSupplierinvoiceRequestMain = async (id) => { export const genRecordsSupplierinvoiceRequestMain = async (id) => {
return await request.post({ url: `/wms/supplierinvoice-request-main/genRecords?id=` + id }) return await request.post({ url: `/wms/supplierinvoice-request-main/genRecords?id=` + id })
@ -89,3 +99,7 @@ export const exportSupplierinvoiceRequestMain = async (params) => {
} }
} }
// 下载用户导入模板
export const importTemplate = () => {
return request.download({ url: '/wms/supplierinvoice-request-main/get-import-template' })
}

179
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

@ -65,6 +65,17 @@
:Echo="Echo" :Echo="Echo"
/> />
<!-- 导入 -->
<ImportForm
ref="importFormRef"
url="/wms/supplierinvoice-request-main/import"
:importTemplateData="importTemplateData"
@success="importSuccess"
:updateIsDisable="true"
:coverIsDisable="true"
:mode="2"
/>
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
@ -112,57 +123,25 @@
// //
row[formField] = val[0][searchField] row[formField] = val[0][searchField]
if (formField == 'poLine') { if (formField == 'poLine') {
row['poNumber'] = val[0]['poNumber']
row['poLine'] = val[0]['poLine'] row['poLine'] = val[0]['poLine']
row['tax'] = val[0]['tax']
row['projectCode'] = val[0]['projectCode']
row['billType'] = val[0]['billType']
row['recvBillNum'] = val[0]['recvBillNum']
row['asnBillNum'] = val[0]['asnBillNum']
row['supplierCode'] = val[0]['supplierCode']
row['purchasePrice'] = val[0]['purchasePrice']
row['invoicableQuantity'] = val[0]['invoicableQuantity']
row['itemCode'] = val[0]['itemCode'] row['itemCode'] = val[0]['itemCode']
row['ownerCode'] = val[0]['ownerCode']
row['batch'] = val[0]['batch']
row['singlePrice'] = val[0]['singlePrice']
row['qty'] = val[0]['qty']
row['amount'] = val[0]['amount']
} }
} else { } else {
console.log(searchFormRef.formModel);
const setV = {} const setV = {}
if(formField == 'recvBillNum'){
setV['recvBillNum'] = val[0]['number']
setV['asnBillNum'] = val[0]['asnNumber']
let params = {
'billType':searchFormRef.formModel.billType,
'recordNumber':val[0]['number']
}
let orderNoFlag = false;
SupplierinvoiceRequestDetailApi.getPoNumber(params).then(res =>{
console.log("返回结果:",res)
if(res.length == 0){
orderNoFlag = true
return
}
let options = [];
for(let i=0;i<res.length;i++){
let option = {
label:res[i],
value:res[i]
}
options.push(option)
}
SupplierinvoiceRequestMain.allSchemas.formSchema.forEach(item => {
if (item.field == 'poBillNum') {
item.componentProps.options = options
}
})
})
if(orderNoFlag){
message.error("选择的记录单号没有订单")
return;
}
}
setV[formField] = val[0][searchField] setV[formField] = val[0][searchField]
searchFormRef.setValues(setV) searchFormRef.setValues(setV)
} }
}) })
} }
//
// const Echo = ['ppNumber','poLine', 'batch', 'altBatch', 'itemCode', 'itemName', 'itemDesc1', 'itemDesc2', 'projectCode', 'qty', 'uom']
const Echo = [] const Echo = []
const { tableObject, tableMethods } = useTable({ const { tableObject, tableMethods } = useTable({
@ -175,7 +154,8 @@
// //
const HeadButttondata = [ const HeadButttondata = [
defaultButtons.defaultAddBtn({ hasPermi: 'wms:supplierinvoice-request-main:create' }), // defaultButtons.defaultAddBtn({ hasPermi: 'wms:supplierinvoice-request-main:create' }), //
defaultButtons.defaultExportBtn({ hasPermi: 'wms:supplierinvoice-request-main:export' }), // defaultButtons.defaultImportBtn(null), //
defaultButtons.defaultExportBtn(null), //
defaultButtons.defaultFreshBtn(null), // defaultButtons.defaultFreshBtn(null), //
defaultButtons.defaultFilterBtn(null), // defaultButtons.defaultFilterBtn(null), //
defaultButtons.defaultSetBtn(null), // defaultButtons.defaultSetBtn(null), //
@ -223,28 +203,68 @@
// - // -
const butttondata = (row) => { const butttondata = (row) => {
return [ return [
defaultButtons.mainListPurchasePlanOpeBtn({ hide: isShowMainButton(row, ['5']) }), // defaultButtons.mainListPurchasePlanOpeBtn({ hide: isShowMainButton(row, ['1',, '2','4']) }), //
defaultButtons.mainListPurchasePlanCloBtn({ hide: isShowMainButton(row, ['1', '2', '4']) }), //
defaultButtons.mainListPlanSubBtn({ hide: isShowMainButton(row, ['1']) }), // defaultButtons.mainListPlanSubBtn({ hide: isShowMainButton(row, ['1']) }), //
defaultButtons.mainListPlanAppBtn({ hide: isShowMainButton(row, ['2']) }), //
defaultButtons.mainListPlanTurBtn({ hide: isShowMainButton(row, ['2']) }), //
defaultButtons.mainListEditBtn({ hasPermi: 'wms:supplierinvoice-request-main:update' , hide: isShowMainButton(row, ['1'])}), //
//
{ {
label: '处理', label: '采购审批通过',
name: 'genRecords', name: 'purchase_mainPlanSub',
hide: isShowMainButton(row, ['3']), hide: isShowMainButton(row, ['2','7']),
type: 'primary', type: 'primary',
icon: '', icon: '',
color: '', color: '',
hasPermi: '', hasPermi: '',
link: true, // link: true, //
},{
label: '采购驳回',
name: 'purchase_mainPlanTur',
hide: isShowMainButton(row, ['2','7']),
type: 'danger',
color: '',
link: true, //
hasPermi: ''
}, },
{
label: '财务审批通过',
name: 'finance_mainPlanSub',
hide: isShowMainButton(row, ['4']),
type: 'primary',
icon: '',
color: '',
hasPermi: '',
link: true, //
},{
label: '财务驳回',
name: 'finance_mainPlanTur',
hide: isShowMainButton(row, ['4']),
type: 'danger',
color: '',
link: true, //
hasPermi: ''
},
// defaultButtons.mainListPlanAppBtn({ hide: isShowMainButton(row, ['2']) }), //
//defaultButtons.mainListPlanTurBtn({ hide: isShowMainButton(row, ['2']) }), //
defaultButtons.mainListEditBtn({ hasPermi: 'wms:supplierinvoice-request-main:update' , hide: isShowMainButton(row, ['1','6'])}), //
defaultButtons.mainListPurchasePlanCloBtn({ hide: isShowMainButton(row, ['1', '2','4']) }), //
//
// {
// label: '',
// name: 'genRecords',
// hide: isShowMainButton(row, ['3']),
// type: 'primary',
// icon: '',
// color: '',
// hasPermi: '',
// link: true, //
// },
// defaultButtons.mainListDeleteBtn({hasPermi:'wms:supplierinvoice-request-main:delete'}), // // defaultButtons.mainListDeleteBtn({hasPermi:'wms:supplierinvoice-request-main:delete'}), //
] ]
} }
/** 导入 */
const importFormRef = ref()
const handleImport = () => {
importFormRef.value.open()
}
// - // -
const buttonTableClick = async (val, row) => { const buttonTableClick = async (val, row) => {
@ -254,10 +274,14 @@
handleClo(row.id) handleClo(row.id)
} else if (val == 'mainPlanSub') { // } else if (val == 'mainPlanSub') { //
handleSub(row.id) handleSub(row.id)
} else if (val == 'mainPlanApp') { // } else if (val == 'purchase_mainPlanSub') { //
handleApp(row.id) handleApp(row.id)
} else if (val == 'mainPlanTur') { // } else if (val == 'purchase_mainPlanTur') { //
handleTur(row.id) handleTur(row.id)
} else if(val == 'finance_mainPlanSub'){ //
handleFinanceApp(row.id)
} else if(val == 'finance_mainPlanTur'){ //
handleFinaceTur(row.id)
} else if (val == 'genRecords') { // } else if (val == 'genRecords') { //
genRecords(row.id) genRecords(row.id)
} else if (val == 'edit') { // } else if (val == 'edit') { //
@ -369,6 +393,24 @@
} }
} }
/** 审批通过按钮操作 */
const handleFinanceApp = async (id : number) => {
try {
//
await message.confirm('是否审批通过所选中数据?')
tableObject.loading = true
//
await SupplierinvoiceRequestMainApi.financeappSupplierinvoiceRequestMain(id)
message.success(t('审批通过成功!'))
tableObject.loading = false
//
await getList()
} catch { }finally{
tableObject.loading = false
}
}
/** 驳回按钮操作 */ /** 驳回按钮操作 */
const handleTur = async (id : number) => { const handleTur = async (id : number) => {
try { try {
@ -386,6 +428,23 @@
} }
} }
/** 驳回按钮操作 */
const handleFinaceTur = async (id : number) => {
try {
//
await message.confirm('是否驳回所选中数据?')
tableObject.loading = true
//
await SupplierinvoiceRequestMainApi.financerejSupplierinvoiceRequestMain(id)
message.success(t('驳回成功!'))
tableObject.loading = false
//
await getList()
} catch { }finally{
tableObject.loading = false
}
}
/** 处理按钮操作 */ /** 处理按钮操作 */
const genRecords = async (id : number) => { const genRecords = async (id : number) => {
try { try {
@ -456,6 +515,17 @@
} }
} }
//
const importTemplateData = reactive({
templateUrl: '',
templateTitle: '供应商发货申请主导入模版.xlsx'
})
//
const importSuccess = () => {
getList()
}
// //
const searchFormClick = (searchData) => { const searchFormClick = (searchData) => {
tableObject.params = { tableObject.params = {
@ -468,5 +538,6 @@
/** 初始化 **/ /** 初始化 **/
onMounted(async () => { onMounted(async () => {
getList() getList()
importTemplateData.templateUrl = await SupplierinvoiceRequestMainApi.importTemplate()
}) })
</script> </script>

596
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/supplierinvoiceRequestMain.data.ts

@ -5,7 +5,6 @@ import { Supplier } from '@/views/wms/basicDataManage/supplierManage/supplier/su
const { t } = useI18n() // 国际化 const { t } = useI18n() // 国际化
import * as getRequestsettingApi from '@/api/wms/requestsetting/index' import * as getRequestsettingApi from '@/api/wms/requestsetting/index'
import * as supplierinvoiceRequestMainApi from '@/api/wms/supplierinvoiceRequestMain'
import * as supplierinvoiceRequestDetailApi from '@/api/wms/supplierinvoiceRequestDetail' import * as supplierinvoiceRequestDetailApi from '@/api/wms/supplierinvoiceRequestDetail'
// 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值 // 获取自动提交自动通过自动执行,跳过任务直接删生成记录的默认值
@ -27,47 +26,30 @@ const requestsettingData = data?.list[0] || {}
const userDeptArray:any = [userDept] const userDeptArray:any = [userDept]
/**
export const PurchaseReceiptOrReturnRecordMain = useCrudSchemas(reactive<CrudSchema[]>([ * @returns {Array} 退
*/
export const PurchaseReceiptOrReturnRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: '单据号', label: '项目编码',
field: 'number' field: 'projectCode'
}, },
{ {
label: '供应商代码', label: '单据类型',
field: 'supplierCode' field: 'billType'
}, },
{ {
label: '发货单号', label: '单号',
field: 'asnNumber' field: 'recvBillNum'
}, },
{ {
label: '备注', label: '发货单号',
field: 'remark', field: 'asnBillNum'
}, },
{ {
label: '创建时间', label: '供应商代码',
field: 'createTime', field: 'supplierCode'
isTable: true,
formatter: dateFormatter,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
isTableForm: false,
isForm: false
}, },
{
label: '创建者',
field: 'creator',
isTableForm: false,
isForm: false
}
]))
/**
* @returns {Array} 退
*/
export const PurchaseReceiptOrReturnRecordDetail = useCrudSchemas(reactive<CrudSchema[]>([
{ {
label: '订单号', label: '订单号',
field: 'poNumber' field: 'poNumber'
@ -77,41 +59,16 @@ export const PurchaseReceiptOrReturnRecordDetail = useCrudSchemas(reactive<CrudS
field: 'poLine' field: 'poLine'
}, },
{ {
label: '物料代码', label: '采购价格',
field: 'itemCode' field: 'purchasePrice'
},
{
label: '货主代码',
field: 'ownerCode'
},
{
label: '批次',
field: 'batch'
}, },
{ {
label: '数量', label: '可开票数量',
field: 'qty', field: 'invoicableQuantity'
form: {
component: 'InputNumber',
}
}, },
{ {
label: '单价', label: '物料代码',
field: 'singlePrice', field: 'itemCode'
form: {
component: 'InputNumber',
}
},
{
label: '金额',
field: 'amount',
form: {
component: 'InputNumber',
}
},
{
label: '备注',
field: 'remark',
}, },
{ {
label: '创建时间', label: '创建时间',
@ -123,12 +80,6 @@ export const PurchaseReceiptOrReturnRecordDetail = useCrudSchemas(reactive<CrudS
}, },
isTableForm: false, isTableForm: false,
isForm: false isForm: false
},
{
label: '创建者',
field: 'creator',
isTableForm: false,
isForm: false
} }
])) ]))
@ -169,130 +120,173 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
} }
}, },
{ {
label: '单据类型', label: '状态',
field: 'billType', field: 'status',
dictType: DICT_TYPE.BILL_TYPE, dictType: DICT_TYPE.SUPPLIERINVOICE_REQUEST_STATUS,
dictClass: 'string', dictClass: 'string',
isTable: true, isTable: true,
isSearch: true,
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
isSearch: true,
form: {
value: '1',
componentProps: {
disabled: true
}
}
}, },
{ {
label: '记录单号', label: '金额',
field: 'recvBillNum', field: 'amount',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
form: { form: {
// labelMessage: '信息提示说明!!!', component: 'InputNumber',
componentProps: { componentProps: {
isSearchList: true, // 开启查询弹窗 min: 0,
searchListPlaceholder: '请选择单号', // 输入框占位文本 precision: 6,
searchField: 'number', // 查询弹窗赋值字段
searchTitle: '单号信息', // 查询弹窗标题
searchAllSchemas: PurchaseReceiptOrReturnRecordMain.allSchemas,
searchPage: supplierinvoiceRequestMainApi.getNumber,
searchCondition: [{
key: 'supplierCode',
value: 'supplierCode',
message: '请填写供应商代码!',
isMainValue: true
},
{
key: 'billType',
value: 'billType',
message: '请填写单据类型!',
isMainValue: true
}]
} }
}, },
tableForm: { tableForm: {
isInpuFocusShow: true, type: 'InputNumber',
searchListPlaceholder: '请选择单号', min: 0,
searchField: 'number', precision: 6,
searchTitle: '单号信息',
searchAllSchemas: PurchaseReceiptOrReturnRecordMain.allSchemas,
searchPage: supplierinvoiceRequestMainApi.getNumber,
searchCondition: [{
key: 'supplierCode',
value: 'supplierCode',
message: '请填写供应商代码!',
isMainValue: true
},
{
key: 'billType',
value: 'billType',
message: '请填写单据类型!',
isMainValue: true
}]
} }
}, },
{ {
label: '发货单号', label: '税率',
field: 'asnBillNum', field: 'taxRate',
table: {
width: 150
},
form: { form: {
component: 'InputNumber',
componentProps: { componentProps: {
disabled: true min: 0,
precision: 6,
} }
}, },
tableForm: { tableForm: {
disabled: true type: 'InputNumber',
min: 0,
precision: 6,
} }
}, },
{ {
label: '订单号', label: '税额',
field: 'poBillNum', field: 'taxAmount',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
form: { form: {
component: 'Select', component: 'InputNumber',
componentProps:{ componentProps: {
options:[{label:'',value:''}] min: 0,
precision: 6,
} }
}, },
tableForm: { tableForm: {
type: 'Select', type: 'InputNumber',
options:[{label:'',value:''}] min: 0,
precision: 6,
} }
}, },
{ {
label: '调增金额', label: '税后金额',
field: 'adjustAmount', field: 'afterTaxAmount',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
isForm:false,
isTable:false,
form: { form: {
component: 'InputNumber', component: 'InputNumber',
componentProps: {
min: 0,
precision: 6,
}
}, },
tableForm: {
type: 'InputNumber',
min: 0,
precision: 6,
}
}, },
{ {
label: '业务类型', label: '索赔金额',
field: 'businessType', field: 'claimAmount',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
isTable:false,
isForm:false,
form: { form: {
value: 'SupplierInvoice', component: 'InputNumber',
componentProps: { componentProps: {
disabled: true, min: 0,
precision: 6,
} }
},
tableForm: {
type: 'InputNumber',
min: 0,
precision: 6,
} }
}, },
{ {
label: '申请时间', label: '折扣金额',
field: 'requestTime', field: 'discountAmount',
table: {
width: 150
},
form: {
component: 'InputNumber',
componentProps: {
min: 0,
precision: 6,
}
},
tableForm: {
type: 'InputNumber',
min: 0,
precision: 6,
}
},
{
label: '调整税额',
field: 'adjustingTaxAmount',
table: {
width: 150
},
form: {
component: 'InputNumber',
componentProps: {
min: 0,
precision: 6,
}
},
tableForm: {
type: 'InputNumber',
min: 0,
precision: 6,
}
},
{
label: '金税票号',
field: 'afterTaxAmount',
table: {
width: 150
},
},
{
label: '快递单号',
field: 'expressTrackingNumber',
table: {
width: 150
},
},
{
label: '发票时间',
field: 'invoiceTime',
formatter: dateFormatter, formatter: dateFormatter,
detail: { detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss' dateFormat: 'YYYY-MM-DD HH:mm:ss'
@ -301,19 +295,20 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
table: { table: {
width: 180 width: 180
}, },
isForm:false,
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
style: {width:'100%'},
type: 'datetime', type: 'datetime',
dateFormat: 'YYYY-MM-DD HH:mm:ss', dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x', valueFormat: 'x',
} }
}, },
}, },
{ {
label: '截止时间', label: '申请时间',
field: 'dueTime', field: 'requestTime',
formatter: dateFormatter, formatter: dateFormatter,
detail: { detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss' dateFormat: 'YYYY-MM-DD HH:mm:ss'
@ -323,7 +318,6 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
width: 180 width: 180
}, },
isForm:false, isForm:false,
isTable:false,
form: { form: {
component: 'DatePicker', component: 'DatePicker',
componentProps: { componentProps: {
@ -356,33 +350,6 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
} }
} }
}, },
{
label: '状态',
field: 'status',
dictType: DICT_TYPE.REQUEST_STATUS,
dictClass: 'string',
isTable: true,
sort: 'custom',
table: {
width: 150
},
isSearch: true,
form: {
value: '1',
componentProps: {
disabled: true
}
}
},
{
label: '备注',
field: 'remark',
sort: 'custom',
table: {
width: 150
},
isTable: false,
},
{ {
label: '创建者', label: '创建者',
field: 'creator', field: 'creator',
@ -437,6 +404,15 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
} }
}, },
}, },
{
label: '备注',
field: 'remark',
sort: 'custom',
table: {
width: 150
},
isTable: false,
},
{ {
label: '自动提交', label: '自动提交',
field: 'autoCommit', field: 'autoCommit',
@ -444,6 +420,8 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
dictClass: 'string', dictClass: 'string',
isTable: false, isTable: false,
isForm:false, isForm:false,
isTableForm:false,
isDetail:false,
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -464,7 +442,9 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
dictType: DICT_TYPE.TRUE_FALSE, dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', dictClass: 'string',
isTable: false, isTable: false,
isForm: false, isForm:false,
isTableForm:false,
isDetail:false,
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -485,7 +465,9 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
dictType: DICT_TYPE.TRUE_FALSE, dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', dictClass: 'string',
isTable: false, isTable: false,
isForm: false, isForm:false,
isTableForm:false,
isDetail:false,
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -505,8 +487,10 @@ export const SupplierinvoiceRequestMain = useCrudSchemas(reactive<CrudSchema[]>(
field: 'directCreateRecord', field: 'directCreateRecord',
dictType: DICT_TYPE.TRUE_FALSE, dictType: DICT_TYPE.TRUE_FALSE,
dictClass: 'string', dictClass: 'string',
isForm: false,
isTable: false, isTable: false,
isForm:false,
isTableForm:false,
isDetail:false,
sort: 'custom', sort: 'custom',
table: { table: {
width: 150 width: 150
@ -566,35 +550,41 @@ export const SupplierinvoiceRequestMainRules = reactive({
* @returns {Array} * @returns {Array}
*/ */
export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]>([ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]>([
{
label: '订单号',
field: 'poNumber',
form: {
componentProps: {
disabled: true
}
},
table: {
width: 150
},
tableForm:{
disabled: true
}
},
{ {
label: '订单行', label: '订单行',
field: 'poLine', field: 'poLine',
table: {
width: 150
},
form: { form: {
// labelMessage: '信息提示说明!!!', // labelMessage: '信息提示说明!!!',
componentProps: { componentProps: {
isSearchList: true, isSearchList: true,
searchListPlaceholder: '请选择订单号', searchListPlaceholder: '请选择订单',
searchField: 'number', searchField: 'poLine',
searchTitle: '订单号信息', searchTitle: '待开票列表',
searchAllSchemas: PurchaseReceiptOrReturnRecordDetail.allSchemas, searchAllSchemas: PurchaseReceiptOrReturnRecordDetail.allSchemas,
searchPage: supplierinvoiceRequestDetailApi.getPoNumberPoLineInfo, searchPage: supplierinvoiceRequestDetailApi.getPoNumberPoLineInfo,
searchCondition: [ searchCondition: [
{ {
key: 'recordNumber', key: 'supplierCode',
value: 'recvBillNum', value: 'supplierCode',
message: '请填写单号!', message: '请填供应商信息!',
isMainValue: true
},
{
key: 'billType',
value: 'billType',
message: '请填写单号类型!',
isMainValue: true
},
{
key: 'poNumber',
value: 'poBillNum',
message: '请选择订单号',
isMainValue: true isMainValue: true
} }
] ]
@ -602,150 +592,188 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
}, },
tableForm: { tableForm: {
isInpuFocusShow: true, isInpuFocusShow: true,
searchListPlaceholder: '请选择订单', searchListPlaceholder: '请选择订单',
searchField: 'number', searchField: 'poLine',
searchTitle: '订单号信息', searchTitle: '待开票列表',
searchAllSchemas: PurchaseReceiptOrReturnRecordDetail.allSchemas, searchAllSchemas: PurchaseReceiptOrReturnRecordDetail.allSchemas,
searchPage: supplierinvoiceRequestDetailApi.getPoNumberPoLineInfo, searchPage: supplierinvoiceRequestDetailApi.getPoNumberPoLineInfo,
searchCondition: [ searchCondition: [
{ {
key: 'recordNumber', key: 'supplierCode',
value: 'recvBillNum', value: 'supplierCode',
message: '请填写单号!', message: '请填供应商信息!',
isMainValue: true
},
{
key: 'billType',
value: 'billType',
message: '请填写单号类型!',
isMainValue: true
},
{
key: 'poNumber',
value: 'poBillNum',
message: '请选择订单号',
isMainValue: true isMainValue: true
} }
] ]
} }
}, },
{ {
label: '物料代码', label: '供应商税率',
field: 'itemCode', field: 'tax',
table: {
width: 150
},
form: { form: {
componentProps: { componentProps: {
disabled: true disabled: true
} }
}, },
tableForm: { tableForm:{
disabled: true disabled: true
} }
}, },
{ {
label: '货主代码', label: '项目编码',
field: 'ownerCode' field: 'projectCode',
table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
}
}, },
{ {
label: '批次', label: '单据类型',
field: 'batch', field: 'billType',
disabled:true, table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
}
}, },
{ {
label: '数量', label: '发货单号',
field: 'qty', field: 'asnBillNum',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
form: { form: {
component: 'InputNumber',
componentProps: { componentProps: {
disabled:true, disabled: true
min: 0, }
precision: 6
},
}, },
tableForm: { tableForm:{
type: 'InputNumber', disabled: true
disabled:true, }
min: 0, },
precision: 6 {
label: '供应商代码',
field: 'supplierCode',
table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
} }
}, },
{ {
label: '单价', label: '单价',
field: 'singlePrice', field: 'singlePrice',
table: {
width: 150
},
form: { form: {
component: 'InputNumber', component: 'InputNumber',
componentProps: { componentProps: {
disabled:true,
min: 0, min: 0,
precision: 6 precision: 6,
}, }
}, },
tableForm: { tableForm: {
type: 'InputNumber', type: 'InputNumber',
disabled:true,
min: 0, min: 0,
precision: 6 precision: 6,
} }
}, },
{ {
label: '金额', label: '采购价格',
field: 'amount', field: 'purchasePrice',
table: {
width: 150
},
form: { form: {
component: 'InputNumber',
componentProps: { componentProps: {
disabled:true, disabled: true
min: 0, }
precision: 6
},
}, },
tableForm: { tableForm:{
type: 'InputNumber', disabled: true
disabled:true,
min: 0,
precision: 6
} }
}, },
{ {
label: '税率', label: '可开票数量',
field: 'tax', field: 'invoicableQuantity',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
form: { form: {
component: 'InputNumber',
componentProps: { componentProps: {
min: 0, disabled: true
precision: 6 }
},
}, },
tableForm: { tableForm:{
type: 'InputNumber', disabled: true
min: 0,
precision: 6
} }
}, },
{ {
label: '比率', label: '物料代码',
field: 'rate', field: 'itemCode',
sort: 'custom',
table: { table: {
width: 150 width: 150
}, },
form: { form: {
component: 'InputNumber',
componentProps: { componentProps: {
min: 0, disabled: true
precision: 6 }
},
}, },
tableForm: { tableForm:{
type: 'InputNumber', disabled: true
min: 0, }
precision: 6 },
{
label: '物料名称',
field: 'itemName',
table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
}
},
{
label: '货币',
field: 'currency',
table: {
width: 150
},
form: {
componentProps: {
disabled: true
}
},
tableForm:{
disabled: true
} }
}, },
{ {
@ -756,6 +784,9 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
label: '创建时间', label: '创建时间',
field: 'createTime', field: 'createTime',
isTable: true, isTable: true,
table: {
width: 150
},
formatter: dateFormatter, formatter: dateFormatter,
detail: { detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss' dateFormat: 'YYYY-MM-DD HH:mm:ss'
@ -767,7 +798,10 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
label: '创建者', label: '创建者',
field: 'creator', field: 'creator',
isTableForm: false, isTableForm: false,
isForm: false isForm: false,
table: {
width: 150
},
}, },
{ {
label: '操作', label: '操作',
@ -784,25 +818,5 @@ export const SupplierinvoiceRequestDetail = useCrudSchemas(reactive<CrudSchema[]
//表单校验 //表单校验
export const SupplierinvoiceRequestDetailRules = reactive({ export const SupplierinvoiceRequestDetailRules = reactive({
packingNumber: [
{ required: true, message: '请输入包装号', trigger: 'blur' }
],
poNumber: [
{ required: true, message: '请输入订单号', trigger: 'blur' }
],
poLine: [
{ required: true, message: '请输入订单行', trigger: 'blur' }
],
packQty: [
{ required: true, message: '请输入包装数量', trigger: 'blur' }
],
packUnit: [
{ required: true, message: '请输入包装规格', trigger: 'blur' }
],
convertRate: [
{ required: true, message: '请输入转换率', trigger: 'blur' }
],
itemCode: [
{ required: true, message: '请输入物料代码', trigger: 'blur' }
]
}) })

Loading…
Cancel
Save