diff --git a/src/api/wms/customerStatementDetail/index.ts b/src/api/wms/customerStatementDetail/index.ts new file mode 100644 index 000000000..0c4729f6d --- /dev/null +++ b/src/api/wms/customerStatementDetail/index.ts @@ -0,0 +1,77 @@ +import request from '@/config/axios' + +export interface CustomerStatementDetailVO { + id: number + number: string + masterId: number + invoiceType: string + releaseNumber: string + ingress: string + ingress2: string + itemCode: string + articleNumber: string + articleName: string + backNumber: string + checkTime: Date + uom: string + qty: number + price: number + amount: number + allocationPrice: number + tftmQuantity: number + intexQuantity: number + quantityVariance: number + tftmPrice: number + intexPrice: number + priceVariance: number + tftmAmount: number + intexAmount: number + amountVariance: number + dischargingTime: Date + acceptCheckTime: Date + remark: string + available: string + siteId: string + concurrencyStamp: string +} + +// 查询客户对账单子信息表(WMS)列表 +export const getCustomerStatementDetailPage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/wms/customer-statement-detail/senior', data }) + } else { + return await request.get({ url: `/wms/customer-statement-detail/page`, params }) + } +} + +// 查询客户对账单子信息表(WMS)详情 +export const getCustomerStatementDetail = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-detail/get?id=` + id }) +} + +// 新增客户对账单子信息表(WMS) +export const createCustomerStatementDetail = async (data: CustomerStatementDetailVO) => { + return await request.post({ url: `/wms/customer-statement-detail/create`, data }) +} + +// 修改客户对账单子信息表(WMS) +export const updateCustomerStatementDetail = async (data: CustomerStatementDetailVO) => { + return await request.put({ url: `/wms/customer-statement-detail/update`, data }) +} + +// 删除客户对账单子信息表(WMS) +export const deleteCustomerStatementDetail = async (id: number) => { + return await request.delete({ url: `/wms/customer-statement-detail/delete?id=` + id }) +} + +// 导出客户对账单子信息表(WMS) Excel +export const exportCustomerStatementDetail = async (params) => { + return await request.download({ url: `/wms/customer-statement-detail/export-excel`, params }) +} + +// 下载用户导入模板 +export const importTemplate = () => { + return request.download({ url: '/wms/customer-statement-detail/get-import-template' }) +} \ No newline at end of file diff --git a/src/api/wms/customerStatementMain/index.ts b/src/api/wms/customerStatementMain/index.ts new file mode 100644 index 000000000..1b7d899cb --- /dev/null +++ b/src/api/wms/customerStatementMain/index.ts @@ -0,0 +1,98 @@ +import request from '@/config/axios' + +export interface CustomerStatementMainVO { + id: number + number: string + customerCode: string + customerName: string + yearsMonth: Date + status: string + comparisonTime: Date + publishTime: Date + shareTime: Date + beInvoicedTime: Date + invoicedTime: Date + issuedInvoicedTime: Date + abrogateTime: Date + versionNumber: string + remark: string + available: string + siteId: string + concurrencyStamp: string +} + +// 查询客户对账单主信息表(WMS)列表 +export const getCustomerStatementMainPage = async (params) => { + if (params.isSearch) { + delete params.isSearch + const data = {...params} + return await request.post({ url: '/wms/customer-statement-main/senior', data }) + } else { + return await request.get({ url: `/wms/customer-statement-main/page`, params }) + } +} + +// 查询客户对账单主信息表(WMS)详情 +export const getCustomerStatementMain = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/get?id=` + id }) +} + +// 新增客户对账单主信息表(WMS) +export const createCustomerStatementMain = async (data: CustomerStatementMainVO) => { + return await request.post({ url: `/wms/customer-statement-main/create`, data }) +} + +// 修改客户对账单主信息表(WMS) +export const updateCustomerStatementMain = async (data: CustomerStatementMainVO) => { + return await request.put({ url: `/wms/customer-statement-main/update`, data }) +} + +// 删除客户对账单主信息表(WMS) +export const deleteCustomerStatementMain = async (id: number) => { + return await request.delete({ url: `/wms/customer-statement-main/delete?id=` + id }) +} + +// 导出客户对账单主信息表(WMS) Excel +export const exportCustomerStatementMain = async (params) => { + return await request.download({ url: `/wms/customer-statement-main/export-excel`, params }) +} + +// 下载客户对账单导入模板 +export const importTemplate = () => { + return request.download({ url: '/wms/customer-statement-main/get-import-template' }) +} + +// 导入客户对账单前校验是否有相同客户代码和年月的数据存在 +export const verifyDataExist = async (yearsMonthStr: String,customerCode:String) => { + return await request.get({ url: `/wms/customer-statement-main/verifyDataExist?yearsMonthStr=` + yearsMonthStr+'&customerCode='+customerCode }) +} + +// 客户对账单重新比对 +export const recontrast = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/recontrast?id=` + id}) +} + +// 客户对账单确认比对结果 +export const confirmationContrast = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/confirmationContrast?id=` + id}) +} + +// 客户对账单废除数据 +export const nodeAbrogate = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/nodeAbrogate?id=` + id}) +} + +// 客户对账单退回操作 +export const sendBack = async (id: number) => { + return await request.get({ url: `/wms/customer-statement-main/sendBack?id=` + id}) +} + +// 导入客户模具分摊对账单前校验该客户对账单下是否存在已分摊的模具分摊对账单如果有提示 +export const verifyDataExistShare = async (customerId:number) => { + return await request.get({ url: `/wms/customer-tool-apport-statement-detail/verifyDataExist?customerId=` + customerId }) +} + +// 下载客户模具分摊对账单导入模板 +export const importShareTemplate = () => { + return request.download({ url: '/wms/customer-tool-apport-statement-detail/get-import-template' }) +} \ No newline at end of file diff --git a/src/components/ImportForm/src/ImportCustomerStatementForm.vue b/src/components/ImportForm/src/ImportCustomerStatementForm.vue new file mode 100644 index 000000000..817b28da3 --- /dev/null +++ b/src/components/ImportForm/src/ImportCustomerStatementForm.vue @@ -0,0 +1,466 @@ + + + + + + + + + + + + + + + + + + {{t('ts.将文件拖到此处,或')}}{{t('ts.点击上传')}} + + + + + + + + {{ t('ts.下载模板') }} + + + {{ t('ts.确 定') }} + {{ t('ts.取 消') }} + + + + + + + diff --git a/src/components/ImportForm/src/ImportCustomerStatementShareForm.vue b/src/components/ImportForm/src/ImportCustomerStatementShareForm.vue new file mode 100644 index 000000000..3881ebadf --- /dev/null +++ b/src/components/ImportForm/src/ImportCustomerStatementShareForm.vue @@ -0,0 +1,427 @@ + + + + + + {{t('ts.将文件拖到此处,或')}}{{t('ts.点击上传')}} + + + + + + + + {{ t('ts.下载模板') }} + + + {{ t('ts.确 定') }} + {{ t('ts.取 消') }} + + + + + + + diff --git a/src/utils/dict.ts b/src/utils/dict.ts index cfb938dbc..91bca1bd4 100644 --- a/src/utils/dict.ts +++ b/src/utils/dict.ts @@ -406,4 +406,5 @@ export enum DICT_TYPE { SCRAPPING_REASON = 'scrapping_reason', //制品子件报废原因 RECEIVE_STATUS = 'receive_status', // 收货确认状态 LINE_SCRAP_REASON = 'Reason_or_scrapping_of_production_line', // 线边报废原因(现场史力维护的字典) + CUSTOMER_STATEMENT_TYPE = 'customer_statement_type', // wms客户对账单 模具分摊状态 } diff --git a/src/utils/disposition/defaultButtons.ts b/src/utils/disposition/defaultButtons.ts index 4bf0a9845..13fce99ac 100644 --- a/src/utils/disposition/defaultButtons.ts +++ b/src/utils/disposition/defaultButtons.ts @@ -1416,6 +1416,18 @@ export function retryBtn(option: any) { hasPermi: '' }) } +// 主列表-退回 +export function mainSendBackBtn(option: any) { + return __defaultBtnOption(option, { + label: t(`ts.退回`).replace('ts.', ''), + name: 'sendBack', + hide: false, + type: 'warning', + color: '', + link: true, // 文本展现按钮 + hasPermi: '' + }) +} // 默认按钮规则 function __defaultBtnOption(option: any, specific: any) { return { diff --git a/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerSaleInvoiceDetail.data.ts b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerSaleInvoiceDetail.data.ts new file mode 100644 index 000000000..f2bb64ea2 --- /dev/null +++ b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerSaleInvoiceDetail.data.ts @@ -0,0 +1,121 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' + +// 表单校验 +export const CustomerSaleInvoiceDetailRules = reactive({ + itemCode: [required], + articleNumber: [required], + qty: [required], + price: [required], + allocationPrice: [required], + sumPrice: [required], + afterTaxAmount: [required], + beforeTaxAmount: [required], + taxAmount: [required], +}) + +export const CustomerSaleInvoiceDetail = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + sort: 'custom', + isTable: false, + isForm: false, + }, + { + label: '单据号', + field: 'number', + sort: 'custom', + }, + { + label: '主id', + field: 'masterId', + sort: 'custom', + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '品番即物料代码', + field: 'itemCode', + sort: 'custom', + isSearch: true, + }, + { + label: '品号即品番2', + field: 'articleNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '数量', + field: 'qty', + sort: 'custom', + }, + { + label: '单价', + field: 'price', + sort: 'custom', + }, + { + label: '模具分摊单价', + field: 'allocationPrice', + sort: 'custom', + }, + { + label: '合计单价', + field: 'sumPrice', + sort: 'custom', + }, + { + label: '含税金额', + field: 'afterTaxAmount', + sort: 'custom', + }, + { + label: '未税金额', + field: 'beforeTaxAmount', + sort: 'custom', + }, + { + label: '税额', + field: 'taxAmount', + sort: 'custom', + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + }, + { + label: '是否可用默认TRUE', + field: 'available', + sort: 'custom', + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) diff --git a/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerStatementMain.data.ts b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerStatementMain.data.ts new file mode 100644 index 000000000..4e81001b8 --- /dev/null +++ b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/customerStatementMain.data.ts @@ -0,0 +1,275 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' + +// 表单校验 +export const CustomerStatementMainRules = reactive({ + customerCode: [required], + customerName: [required], + yearsMonth: [required], +}) + +export const CustomerStatementMain = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + isDetail:false, + sort: 'custom', + isTable: false, + isForm: false, + }, + { + label: '单据号', + field: 'number', + sort: 'custom', + isSearch: true, + }, + { + label: '客户编号', + field: 'customerCode', + sort: 'custom', + isSearch: true, + }, + { + label: '客户名称', + field: 'customerName', + sort: 'custom', + isSearch: true, + }, + { + label: '年月', + field: 'yearsMonth', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + detail: { + dateFormat: 'YYYY-MM' + }, + table: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'YYYY-MM' + } + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'YYYY-MM' + } + }, + }, + { + label: '状态', + field: 'status', + sort: 'custom', + dictType: DICT_TYPE.CUSTOMER_STATEMENT_TYPE, + dictClass: 'string', + isSearch: true, + form: { + //value: '',//可以添加默认值 有无都可 + component: 'Select', + }, + }, + { + label: '重新比对时间', + field: 'comparisonTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '发布时间', + field: 'publishTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '已分摊时间', + field: 'shareTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '待开票时间', + field: 'beInvoicedTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '开票中时间', + field: 'invoicedTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '已开票时间', + field: 'issuedInvoicedTime', + sort: 'custom', + isTable:false, + formatter: dateFormatter, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '已作废时间', + field: 'abrogateTime', + sort: 'custom', + isTable:false, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '操作人', + field: 'creator', + sort: 'custom', + }, + { + label: '版本号', + field: 'versionNumber', + sort: 'custom', + }, + // { + // label: '备注', + // field: 'remark', + // sort: 'custom', + // }, + // { + // label: '是否可用默认TRUE', + // field: 'available', + // sort: 'custom', + // }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + detail: { + dateFormat: 'YYYY-MM-DD HH:mm:ss' + }, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + // { + // label: '地点ID', + // field: 'siteId', + // sort: 'custom', + // }, + // { + // label: '并发乐观锁', + // field: 'concurrencyStamp', + // sort: 'custom', + // }, + { + label: '操作', + isDetail:false, + field: 'action', + isForm: false, + table: { + width: 300, + fixed: 'right' + } + } +])) + +// 表单校验 +export const CustomerStatementDetailRules = reactive({ + releaseNumber: [required], + ingress: [required], + ingress2: [required], + itemCode: [required], + articleNumber: [required], + articleName: [required], + checkTime: [required], + uom: [required], + qty: [required], + price: [required], + amount: [required], +}) diff --git a/src/views/wms/deliversettlementManage/customerStatement/customerStatement/index.vue b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/index.vue new file mode 100644 index 000000000..9310f01fb --- /dev/null +++ b/src/views/wms/deliversettlementManage/customerStatement/customerStatement/index.vue @@ -0,0 +1,346 @@ + + + + + + + + + + + + + + + {{ row.number }} + + + + + + + + + + + + + + + + + + + + diff --git a/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/customerToolApportStatementDetail.data.ts b/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/customerToolApportStatementDetail.data.ts new file mode 100644 index 000000000..9e047ee33 --- /dev/null +++ b/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/customerToolApportStatementDetail.data.ts @@ -0,0 +1,173 @@ +import type { CrudSchema } from '@/hooks/web/useCrudSchemas' +import { dateFormatter } from '@/utils/formatTime' + +// 表单校验 +export const CustomerToolApportStatementDetailRules = reactive({ + invoiceNumber: [required], + articleNumber: [required], + vehicleType: [required], + amount: [required], + qty: [required], + allocationPrice: [required], + adjustmentAmount: [required], +}) + +export const CustomerToolApportStatementDetail = useCrudSchemas(reactive([ + { + label: 'id', + field: 'id', + sort: 'custom', + isTable: false, + isForm: false, + }, + { + label: '客户对账单单据号', + field: 'customerStatementNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '年月预留字段', + field: 'yearsMonth', + sort: 'custom', + }, + { + label: '客户对账单主id', + field: 'masterId', + sort: 'custom', + form: { + component: 'InputNumber', + value: 0 + }, + }, + { + label: '账票号', + field: 'invoiceNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '品号', + field: 'articleNumber', + sort: 'custom', + isSearch: true, + }, + { + label: '车型', + field: 'vehicleType', + sort: 'custom', + isSearch: true, + form: { + component: 'SelectV2' + }, + }, + { + label: '金额', + field: 'amount', + sort: 'custom', + }, + { + label: '数量', + field: 'qty', + sort: 'custom', + }, + { + label: '模具分摊单价', + field: 'allocationPrice', + sort: 'custom', + }, + { + label: '调整金额', + field: 'adjustmentAmount', + sort: 'custom', + }, + { + label: '确认分摊时间', + field: 'verifyTime', + sort: 'custom', + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '已作废时间', + field: 'abrogateTime', + sort: 'custom', + formatter: dateFormatter, + form: { + component: 'DatePicker', + componentProps: { + type: 'datetime', + valueFormat: 'x' + } + }, + }, + { + label: '0:新增1:已作废', + field: 'status', + sort: 'custom', + isSearch: true, + form: { + component: 'SelectV2' + }, + }, + { + label: '版本号', + field: 'versionNumber', + sort: 'custom', + }, + { + label: '备注', + field: 'remark', + sort: 'custom', + }, + { + label: '是否可用默认TRUE', + field: 'available', + sort: 'custom', + }, + { + label: '创建时间', + field: 'createTime', + sort: 'custom', + formatter: dateFormatter, + isSearch: true, + search: { + component: 'DatePicker', + componentProps: { + valueFormat: 'YYYY-MM-DD HH:mm:ss', + type: 'daterange', + defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')] + } + }, + isForm: false, + }, + { + label: '地点ID', + field: 'siteId', + sort: 'custom', + isTable: false, + isSearch: true, + }, + { + label: '并发乐观锁', + field: 'concurrencyStamp', + sort: 'custom', + isTable: false, + isSearch: true, + }, + { + label: '操作', + field: 'action', + isForm: false, + table: { + width: 150, + fixed: 'right' + } + } +])) diff --git a/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/index.vue b/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/index.vue new file mode 100644 index 000000000..0dce2c81b --- /dev/null +++ b/src/views/wms/deliversettlementManage/customerStatement/customerToolApportStatement/index.vue @@ -0,0 +1,244 @@ + + + + + + + + + + + + + + + {{ row.code }} + + + + + + + + + + + + + + + + + + + diff --git a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue index 14d3475d7..56b4360ef 100644 --- a/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue +++ b/src/views/wms/purchasereceiptManage/supplierdeliver/supplierdeliverRequestMain/index.vue @@ -533,10 +533,10 @@ const butttondata = (row, $index) => { // hide: isShowMainButton(row, ['5']), // hasPermi: 'wms:supplierdeliver-request-main:open' // }), // 打开 - defaultButtons.mainListPlanUploadQualityReportBtn({ - hide: isShowMainButton(row, ['1', '2', '3']), - hasPermi: 'wms:supplierdeliver-request-main:uploadCheck' - }), // 上传质量报告 + // defaultButtons.mainListPlanUploadQualityReportBtn({ + // hide: isShowMainButton(row, ['1', '2', '3']), + // hasPermi: 'wms:supplierdeliver-request-main:uploadCheck' + // }), // 上传质量报告 { label: t('ts.上传履历表'), name: 'mainPlanCurriculumVitae',