Browse Source

Merge branch 'intex' of http://dev.ccwin-in.com:3000/sfms3.0/sfms3.0-ui into intex

intex_online20241111
ljlong_2630 4 months ago
parent
commit
2ea6d335fb
  1. 5
      src/api/wms/customer/index.ts
  2. 3
      src/components/ImportForm/src/ImportCustomerStatementForm.vue
  3. 51
      src/views/wms/basicDataManage/itemManage/itemSyntheticRelation/itemSyntheticRelation.data.ts
  4. 44
      src/views/wms/deliversettlementManage/moldAllocation/customerStatement/customerStatementMain.data.ts
  5. 5
      src/views/wms/deliversettlementManage/moldAllocation/customerStatement/index.vue
  6. 22
      src/views/wms/inventoryManage/balance/index.vue
  7. 8
      src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/unplannedreceiptRequestMain.data.ts
  8. 19
      src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts
  9. 18
      src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue
  10. 59
      src/views/wms/moveManage/inventorymove/inventorymoveRequestMainHOLDWIP/index.vue
  11. 14
      src/views/wms/moveManage/inventorymove/inventorymoveRequestMainHOLDWIP/inventorymoveRequestMain.data.ts
  12. 4
      src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRecord/purchaseBarterRecordMain.data.ts
  13. 34
      src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue
  14. 5
      src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/purchaseBarterRequestMain.data.ts
  15. 9
      src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts
  16. 20
      src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts
  17. 1710
      src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts
  18. 2
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

5
src/api/wms/customer/index.ts

@ -35,6 +35,11 @@ export const getCustomerPage = async (params) => {
export const getCustomerList = async (params) => {
return await request.get({ url: `/wms/customer/list`, params })
}
// 查询客户列表
export const getCustomerListPc = async (params) => {
return await request.get({ url: `/wms/customer/listPc`, params })
}
// 查询客户详情
export const getCustomer = async (id: number) => {
return await request.get({ url: `/wms/customer/get?id=` + id })

3
src/components/ImportForm/src/ImportCustomerStatementForm.vue

@ -318,7 +318,6 @@ const verifyData = async () => {
// buttonBaseClick('refresh',null)
} catch {
//
alert(123);
}
}else if(data.status==3){
await message.alertWarning('已存在相同客户编号及年月的对账单,且已提交,无法导入。')
@ -438,7 +437,7 @@ const queryParams = reactive({
const getCustomerList = async () => {//
var param ={}
const list = await CustomerApi.getCustomerList(param);
const list = await CustomerApi.getCustomerListPc(param);
customerList.value = list;
}

51
src/views/wms/basicDataManage/itemManage/itemSyntheticRelation/itemSyntheticRelation.data.ts

@ -1,6 +1,7 @@
import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
import {Itembasic} from "@/views/wms/basicDataManage/itemManage/itembasic/itembasic.data";
import * as ItembasicApi from "@/api/wms/itembasic";
import {dateFormatter} from "@/utils/formatTime";
// 表单校验
export const ItemSyntheticRelationRules = reactive({
@ -76,6 +77,56 @@ export const ItemSyntheticRelation = useCrudSchemas(reactive<CrudSchema[]>([
isSearch: false,
isForm:false,
},
{
label: '生效时间',
field: 'effectiveDate',
sort: 'custom',
formatter: dateFormatter,
isSearch: false,
isTable: true,
isForm: true,
isDetail: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')]
}
},
form: {
component: 'DatePicker',
componentProps: {
type: 'datetime',
valueFormat: 'x'
}
},
},
{
label: '失效时间',
field: 'expirationDate',
sort: 'custom',
formatter: dateFormatter,
isSearch: false,
isTable: true,
isForm: true,
isDetail: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')]
}
},
form: {
component: 'DatePicker',
componentProps: {
type: 'datetime',
valueFormat: 'x'
}
},
},
{
label: '备注',
field: 'remark',

44
src/views/wms/deliversettlementManage/moldAllocation/customerStatement/customerStatementMain.data.ts

@ -62,15 +62,15 @@ export const CustomerStatementMain = useCrudSchemas(reactive<CrudSchema[]>([
}
},
},
{
label: '年月',
field: 'yearsMonthStr',
sort: 'custom',
detail: {
dateFormat: 'YYYY-MM'
},
isForm:false,
},
// {
// label: '年月',
// field: 'yearsMonthStr',
// sort: 'custom',
// detail: {
// dateFormat: 'YYYY-MM'
// },
// isForm:false,
// },
{
label: '状态',
field: 'status',
@ -92,12 +92,26 @@ export const CustomerStatementMain = useCrudSchemas(reactive<CrudSchema[]>([
{
label: '创建时间',
field: 'createTime',
sort: 'custom',
isTable:true,
formatter: dateFormatter,
isSearch: false,
detail: {
dateFormat: 'YYYY-MM-DD HH:mm:ss'
},
sort: 'custom',
isForm: false,
table: {
width: 180
},
form: {
component: 'DatePicker',
componentProps: {
style: {width:'100%'},
type: 'datetime',
dateFormat: 'YYYY-MM-DD HH:mm:ss',
valueFormat: 'x',
}
},
isSearch: true,
search: {
component: 'DatePicker',
componentProps: {
@ -106,7 +120,6 @@ export const CustomerStatementMain = useCrudSchemas(reactive<CrudSchema[]>([
defaultTime: [new Date('1 00:00:00'), new Date('1 23:59:59')]
}
},
isForm: false,
},
{
label: '操作',
@ -283,9 +296,10 @@ export const CustomerStatementReconciliation = useCrudSchemas(reactive<CrudSchem
},
{
label: '验收日期',
field: 'acceptCheckTime',
field: 'checkTime',
sort: 'custom',
isForm: false,
formatter: dateFormatter,
},
{
label: '订单号',
@ -295,7 +309,7 @@ export const CustomerStatementReconciliation = useCrudSchemas(reactive<CrudSchem
},
{
label: '数量-INTEX',
field: 'tftmQuantity',
field: 'intexQuantity',
sort: 'custom',
isForm: false,
},
@ -398,7 +412,7 @@ export const CustomerStatementShareReconciliation = useCrudSchemas(reactive<Crud
},
{
label: '模具分摊金额',
field: 'allocationPrice',
field: 'amount',
sort: 'custom',
isForm: false,
},

5
src/views/wms/deliversettlementManage/moldAllocation/customerStatement/index.vue

@ -293,7 +293,7 @@ const butttondata = (row, $index) => {
hide: isShowMainButton(row, ['3', '4', '5'])
}), // 退
defaultButtons.mainListCancelBtn({
hasPermi: 'wms:customer-statement-main:publish',
hasPermi: 'wms:customer-statement-main:nodeAbrogate',
hide: isShowMainButton(row, ['2', '3', '4', '5'])
}) //
]
@ -432,7 +432,10 @@ const searchFormClick = (searchData) => {
/** 初始化 **/
onMounted(async () => {
getList()
//
importTemplateData.templateUrl = await CustomerStatementMainApi.importTemplate()
//
importShareTemplateData.templateUrl = await CustomerStatementMainApi.importShareTemplate()
})
//
const tapRematch = async (id: number) => {

22
src/views/wms/inventoryManage/balance/index.vue

@ -250,17 +250,17 @@ const handleSelectionPoint = async () => {
}
// -
const butttondata = [
{
label: '标签信息',
name: 'bqxx',
hide: false,
type: 'primary',
icon: '',
color: '',
link: true,
float: 'right',
hasPermi: ''
},
// {
// label: '',
// name: 'bqxx',
// hide: false,
// type: 'primary',
// icon: '',
// color: '',
// link: true,
// float: 'right',
// hasPermi: ''
// },
defaultButtons.mainListPointBtn(null) //
// defaultButtons.mainListEditBtn({hasPermi:'wms:balance:update'}), //
// defaultButtons.mainListDeleteBtn({hasPermi:'wms:balance:delete'}), //

8
src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/unplannedreceiptRequestMain.data.ts

@ -530,7 +530,7 @@ export const UnplannedreceiptRequestMain = useCrudSchemas(reactive<CrudSchema[]>
},
form: {
component: 'Switch',
value: requestsettingData.directCreateRecord,
value: 'FALSE',
componentProps: {
inactiveValue: 'FALSE',
activeValue: 'TRUE'
@ -804,9 +804,9 @@ export const UnplannedreceiptRequestDetail = useCrudSchemas(reactive<CrudSchema[
table: {
width: 150
},
tableForm: {
disabled: true
}
// tableForm: {
// disabled: true
// }
},
// {
// label: '包装号',

19
src/views/wms/issueManage/preparetoissueplan/preparetoissueMain/preparetoissueMain.data.ts

@ -293,15 +293,16 @@ export const PreparetoissueMain = useCrudSchemas(reactive<CrudSchema[]>([
}
}
},
// {
// label: '备注',
// field: 'remark',
// sort: 'custom',
// table: {
// width: 150
// },
// isTable: false
// },
{
label: '备注',
field: 'remark',
sort: 'custom',
table: {
width: 150
},
isTable: true,
isForm:false,
},
{
label: '是否可用',
field: 'available',

18
src/views/wms/moveManage/inventorymove/inventorymoveRequestMain/index.vue

@ -384,6 +384,7 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
newRow['fromLocationCode'] = item['locationCode']
newRow['uom'] = item['uom']
newRow['qty'] = item['qty']
newRow['inventoryQty'] = item['qty']
if(routeName.value == 'NoktoholdRequestMain'){
newRow['toInventoryStatus'] = "HOLD"
}else if ( routeName.value == 'HoldtookRequestMain') {
@ -606,11 +607,11 @@ const buttonTableClick = async (val, row) => {
/** 添加/修改操作 */
const formRef = ref()
const openForm =async (type: string, row?: number) => {
InventorymoveRequestDetail.allSchemas.tableFormColumns.forEach(item=>{
if(item.field == 'qty'){
item.tableForm.disabled = routeName.value == "HoldtookRequestMain"
}
})
// InventorymoveRequestDetail.allSchemas.tableFormColumns.forEach(item=>{
// if(item.field == 'qty'){
// item.tableForm.disabled = routeName.value == "HoldtookRequestMain"
// }
// })
tableData.value = [] //
formRef.value.open(type, row)
}
@ -768,6 +769,13 @@ const submitForm = async (formType, submitData) => {
}
formRef.value.formLoading = true
try {
const cmdExists = data.subList.some(filter =>
parseFloat(filter.inventoryQty) < parseFloat(filter.qty)
);
if(cmdExists){
message.warning("数量不能大于库存数量")
return
}
if (formType === 'create') {
await InventorymoveRequestMainApi.createInventorymoveRequestMain(data)
message.success(t('common.createSuccess'))

59
src/views/wms/moveManage/inventorymove/inventorymoveRequestMainHOLDWIP/index.vue

@ -91,6 +91,7 @@ import * as defaultButtons from '@/utils/disposition/defaultButtons'
import { formatDate } from '@/utils/formatTime'
import { usePageLoading } from '@/hooks/web/usePageLoading'
import {importTemplateHoldOk} from "@/api/wms/inventorymoveRequestMain";
import * as ruleApi from '@/api/wms/rule/index'
const { loadStart, loadDone } = usePageLoading()
// 线HoldtoWipRequestMain
// 线使
@ -288,16 +289,18 @@ InventorymoveRequestDetail.allSchemas.tableFormColumns.map(item => {
const updataTableColumns = (val) => {
tableColumns.value = val
}
const fromManagementPrecision = ref('')
const toManagementPrecision = ref('')
//
const searchTableSuccess = (formField, searchField, val, formRef, type, row ) => {
nextTick(() => {
nextTick(async () => {
console.log(formField)
if (type == 'tableForm') {
if(formField == 'fromPackingNumber'){
val = val.filter(item=>!tableData.value.find(item1=>item1['itemCode']==item['itemCode']&&item1['fromBatch']==item['batch']&&item1['fromPackingNumber']==item['packingNumber']&&item1['fromLocationCode']==item['locationCode']&&item1['fromInventoryStatus']==item['inventoryStatus']))
if(val.length==0) return
val.forEach(item=>{
const newRow = JSON.parse(JSON.stringify({...tableFormKeys,...item}))
if (formField == 'fromPackingNumber') {
val = val.filter(item => !tableData.value.find(item1 => item1['itemCode'] == item['itemCode'] && item1['fromBatch'] == item['batch'] && item1['fromPackingNumber'] == item['packingNumber'] && item1['fromLocationCode'] == item['locationCode'] && item1['fromInventoryStatus'] == item['inventoryStatus']))
if (val.length == 0) return
val.forEach(item => {
const newRow = JSON.parse(JSON.stringify({ ...tableFormKeys, ...item }))
newRow['fromPackingNumber'] = item['packingNumber']
newRow['fromContainerNumber'] = item['containerNumber']
newRow['itemCode'] = item['itemCode']
@ -306,12 +309,41 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
newRow['fromLocationCode'] = item['locationCode']
newRow['uom'] = item['uom']
newRow['qty'] = item['qty']
newRow['toInventoryStatus'] = "OK" //HoldtoWipRequestMain 线
tableData.value.push(newRow)
})
} else {
row[formField] = val[0][searchField]
} else if (formField == 'toLocationCode') {//
//
await ruleApi.getManagementPrecision({
itemCodes: [row['itemCode']],
locationCode: row['fromLocationCode']
}).then((res) => {
fromManagementPrecision.value = res[0].ManagementPrecision
})
if (fromManagementPrecision.value == 'BY_QUANTITY') {//+
//
await ruleApi.getManagementPrecision({
itemCodes: [row['itemCode']],
locationCode: val[0][searchField]
}).then((res) => {
toManagementPrecision.value = res[0].ManagementPrecision
})
if (toManagementPrecision.value != 'BY_QUANTITY') {//+
if (row['fromBatch'] == '') {
row['fromBatch'] = getFormattedDate(); // YYYYMMDD
}
row['fromBatchFormItemType'] = 'FormDate'
row['disabled_fromBatch'] = false
} else {
row['fromBatchFormItemType'] = ''
row['disabled_fromBatch'] = true
}
row[formField] = val[0][searchField]
} else {
row[formField] = val[0][searchField]
}
}
} else {
const setV = {}
@ -708,4 +740,11 @@ onMounted(async () => {
importTemplateData.templateUrl = await InventorymoveRequestMainApi.importTemplateExceptMove()
})
const getFormattedDate = () =>{
const a = new Date();
const year = a.getFullYear();
const month = String(a.getMonth() + 1).padStart(2, '0');
const day = String(a.getDate()).padStart(2, '0');
return `${year}${month}${day}`;
}
</script>

14
src/views/wms/moveManage/inventorymove/inventorymoveRequestMainHOLDWIP/inventorymoveRequestMain.data.ts

@ -557,11 +557,15 @@ export const InventorymoveRequestDetail = useCrudSchemas(reactive<CrudSchema[]>(
width: 150
},
tableForm: {
disabled: true
disabled: true,
placeholder: '请选择从批次',
valueFormat: 'YYYYMMDD',
format: 'YYYYMMDD',
},
form: {
componentProps: {
disabled: true
disabled: true,
valueFormat: 'YYYYMMDD',
}
}
},
@ -932,9 +936,9 @@ export const InventorymoveRequestDetailRules = reactive({
fromLocationCode: [
{ required: true, message: '请选择从库位代码', trigger: 'change' }
],
fromPackingNumber: [
{ required: true, message: '请选择从包装号', trigger: 'change' }
],
// fromPackingNumber: [
// { required: true, message: '请选择从包装号', trigger: 'change' }
// ],
fromInventoryStatus: [
{ required: true, message: '请选择从库存状态', trigger: 'change' }
],

4
src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRecord/purchaseBarterRecordMain.data.ts

@ -26,7 +26,7 @@ export const PurchaseBarterRecordMain = useCrudSchemas(reactive<CrudSchema[]>([
label: '状态',
field: 'status',
sort: 'custom',
isSearch: true,
isSearch: false,
isForm: false,
dictType: DICT_TYPE.REQUEST_STATUS,
dictClass: 'string',
@ -66,6 +66,8 @@ export const PurchaseBarterRecordDetail = useCrudSchemas(reactive<CrudSchema[]>(
field: 'uom',
sort: 'custom',
isSearch: false,
dictType: DICT_TYPE.UOM,
dictClass: 'string',
},
{
label: '批次',

34
src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/index.vue

@ -59,7 +59,6 @@
@tableSelectionDelete="tableSelectionDelete"
@searchTableSuccess="searchTableSuccess"
@submitForm="submitForm"
@inputNumberChange="inputNumberChange"
@tableFormSelectOnBlur="tableFormSelectOnBlur"
>
</BasicForm>
@ -76,7 +75,6 @@
:Echo="Echo"
@searchTableSuccessDetail="searchTableSuccessDetail"
:detailValidate="detailValidate"
@detailOpenForm="detailOpenForm"
@onBlur="onBlur"
/>
@ -162,6 +160,10 @@ const searchTableSuccess = (formField, searchField, val, formRef, type, row ) =>
})
}
const handleDetailSubmitForm = async (formType, data) => {
if(data.qty > data.inventoryQty){
message.warning("换货数量不能大于库存数量")
return
}
if (formType === 'create') {
await PurchaseBarterRequestDetailApi.createPurchaseBarterRequestDetail(data)
message.success(t('common.createSuccess'))
@ -171,7 +173,7 @@ const handleDetailSubmitForm = async (formType, data) => {
message.success(t('common.updateSuccess'))
}
detailRef.value.submitUpdateList()
getList()
}
//
const searchTableSuccessDetail = (formField, searchField, val, formRef ) => {
@ -181,9 +183,12 @@ const searchTableSuccessDetail = (formField, searchField, val, formRef ) => {
if(formField == 'itemCode'){
setV['itemCode'] = val[0]['itemCode']
setV['itemName'] = val[0]['itemName']
setV['uom'] = val[0]['supplierUom']
setV['packUnit'] = val[0]['packUnit']
setV['batch'] = formatTime(new Date(), 'yyyyMMdd')
setV['uom'] = val[0]['uom']
setV['batch'] = val[0]['batch']
setV['location'] = val[0]['batch']
setV['inventoryQty'] = val[0]['qty']
setV['locationCode'] = val[0]['locationCode']
setV['inventoryStatus'] = val[0]['inventoryStatus']
}
formRef.setValues(setV)
})
@ -490,6 +495,10 @@ const submitForm = async (formType, submitData) => {
data.id = data.masterId
}
data.subList = tableData.value //
const cmdExists = data.subList.some(filter =>
parseFloat(filter.inventoryQty) < parseFloat(filter.qty)
);
try {
if (formType === 'create') {
if(data.subList.length == 0){
@ -507,6 +516,10 @@ const submitForm = async (formType, submitData) => {
if(flag){
return
}
if(cmdExists){
message.warning("换货数量不能大于库存数量")
return
}
formRef.value.formLoading = true
await PurchaseBarterRequestMainApi.createPurchaseBarterRequestMain(data)
message.success(t('common.createSuccess'))
@ -566,14 +579,6 @@ const searchFormClick = (searchData) => {
getList() //
}
//
const inputNumberChange = (field, index, row, val) => {
if(field == 'qty' || field == 'singlePrice'){
row.amount = row.qty * row.singlePrice
}
}
let validityDays = 0
const detailOpenForm = (type, row)=>{
console.log('detailOpenForm',row)
@ -607,7 +612,6 @@ const tableFormSelectOnBlur = (field, val, row, index) => {
tableData.value[index][field] = val.target.value
}
}
/** 初始化 **/
onMounted(async () => {
getList()

5
src/views/wms/purchasereceiptManage/purchaseBarter/purchaseBarterRequest/purchaseBarterRequestMain.data.ts

@ -153,7 +153,7 @@ export const PurchaseBarterRequestDetail = useCrudSchemas(reactive<CrudSchema[]>
isFormModel:true, // filters中添加筛选的数据--取于formModel
required:true, // 前置添加必有,和isFormModel结合使用
isSearch: true,
isMainValue: false
isMainValue: true
}],
verificationParams: [
{
@ -297,4 +297,7 @@ export const PurchaseBarterRequestDetailRules = reactive({
qty:[
{ validator:validateQty, message: '换货数量必须是一个正数', trigger: 'change'}
],
itemCode: [
{ required: true, message: '请输入物料代码', trigger: 'blur' }
],
})

9
src/views/wms/purchasereceiptManage/sparereceipt/sparereceiptRequestMain/sparereceiptRequestMain.data.ts

@ -658,7 +658,14 @@ export const PurchasereceiptRequestDetail = useCrudSchemas(reactive<CrudSchema[]
action: '==', // 查询拼接条件
isSearch: true, // 使用自定义拼接条件
isMainValue: false // 拼接条件必须要 false 同时不能与 isMainValue: true 同用
}]
},
{
key: 'itemStatus', // 查询列表中字段
value: 'E', // 指查询具体值
action: '==', // 查询拼接条件
isSearch: true, // 使用自定义拼接条件
isMainValue: false // 拼接条件必须要 false 同时不能与 isMainValue: true 同用
}]
},
form: {
labelMessage: '该订单号会影响订单行的选择',

20
src/views/wms/purchasereceiptManage/supplierdeliver/purchaseMain/purchaseMain.data.ts

@ -549,6 +549,26 @@ export const PurchaseDetail = useCrudSchemas(reactive<CrudSchema[]>([
precision: 6
},
},
{
label: '默认收货库区',
field: 'defaultAreaCode',
table: {
width: 150
},
isTableForm: false,
isForm: false,
isTable: true,
},
{
label: '库区描述',
field: 'areaDescription',
table: {
width: 150
},
isTableForm: false,
isForm: false,
isTable: true,
},
// {
// label: 'ERP库位',
// field: 'erpLocationCode',

1710
src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/purchasePlanMain.data.ts

File diff suppressed because it is too large

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

@ -882,7 +882,7 @@ const openForm = async (type: string, row?: any) => {
if (
item.field == 'taxRate' ||
item.field == 'procurementCreator' ||
item.field == 'beforeTaxAmount' ||
// item.field == 'beforeTaxAmount' ||
item.field == 'totalTaxAmount' ||
item.field == 'goldenTaxInvoiceNumber' ||
item.field == 'invoiceTime' ||

Loading…
Cancel
Save