diff --git a/src/views/operation/seaexport/columns.tsx b/src/views/operation/seaexport/columns.tsx index def55fa2..151d6968 100644 --- a/src/views/operation/seaexport/columns.tsx +++ b/src/views/operation/seaexport/columns.tsx @@ -121,7 +121,9 @@ const FnsaleId: any = await GetSaleUserList() if (FnsaleId.succeeded) { ListData.saleId = [] FnsaleId.data.forEach((e) => { - ListData.saleId.push({ label: e.userName, value: e.id }) + console.log(e, 111) + + ListData.saleId.push({ ...e, label: `${e.userName}/${e.userCode}`, value: e.id }) }) } const FnreceiptPlaceId: any = await GetClientPortSelectList() @@ -1032,7 +1034,13 @@ export const searchFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1050,7 +1058,13 @@ export const searchFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, onChange: (e) => { if (e) { @@ -1220,7 +1234,13 @@ export const searchFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1402,7 +1422,7 @@ export const basicInfoFormSchema: FormSchema[] = [ label: '结算方式', component: 'Select', required: false, - dynamicDisabled: false, + dynamicDisabled: true, defaultValue: '', colProps: { span: 4 }, componentProps: { @@ -1419,7 +1439,7 @@ export const basicInfoFormSchema: FormSchema[] = [ label: '结算日期', component: 'DatePicker', required: false, - dynamicDisabled: false, + dynamicDisabled: true, defaultValue: '', colProps: { span: 4 }, componentProps: { @@ -1464,10 +1484,18 @@ export const basicInfoFormSchema: FormSchema[] = [ colProps: { span: 4 }, componentProps: { allowClear: true, - options: ListData.carrier, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1481,10 +1509,18 @@ export const basicInfoFormSchema: FormSchema[] = [ colProps: { span: 4 }, componentProps: { allowClear: true, - options: ListData.forwarderId, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1609,10 +1645,18 @@ export const basicInfoFormSchema: FormSchema[] = [ colProps: { span: 4 }, componentProps: { allowClear: true, - options: ListData.shipAgencyId, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1637,7 +1681,13 @@ export const basicInfoFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, onChange: (e) => { if (e) { @@ -1666,7 +1716,13 @@ export const basicInfoFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1683,7 +1739,13 @@ export const basicInfoFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1700,7 +1762,13 @@ export const basicInfoFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -1724,9 +1792,25 @@ export const basicInfoFormSchema: FormSchema[] = [ { label: '海外客服', field: 'foreignCustomerService', - component: 'Input', + component: 'Select', required: false, + dynamicDisabled: false, + defaultValue: '', colProps: { span: 4 }, + componentProps: { + allowClear: true, + options: ListData.saleId, + showSearch: true, + filterOption: (input: string, option: any) => { + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData + }, + }, }, { label: '所属部门', @@ -1915,11 +1999,19 @@ export const mailingInfoFormSchemaR: FormSchema[] = [ defaultValue: '', colProps: { span: 5 }, componentProps: { - options: ListData.yard, allowClear: true, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -2072,11 +2164,19 @@ export const mailingInfoFormSchemaR: FormSchema[] = [ defaultValue: '', colProps: { span: 5 }, componentProps: { - options: ListData.customser, allowClear: true, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -2145,11 +2245,19 @@ export const mailingInfoFormSchemaR: FormSchema[] = [ defaultValue: '', colProps: { span: 5 }, componentProps: { - options: ListData.trucker, allowClear: true, + options: ListData.customername, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.codeName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.shortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.enShortName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -2645,7 +2753,7 @@ export const cargoInfoFormSchema2: FormSchema[] = [ defaultValue: '', colProps: { span: 6 }, componentProps: { - options: ListData.FngoodsName, + options: ListData.goodsName, allowClear: true, showSearch: true, filterOption: (input: string, option: any) => { @@ -3696,7 +3804,13 @@ export const BatchModificationFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, onChange: (e) => { if (e) { @@ -3914,7 +4028,13 @@ export const BatchModificationFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -3962,7 +4082,13 @@ export const BatchModificationFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, @@ -4068,7 +4194,13 @@ export const BatchModificationFormSchema: FormSchema[] = [ options: ListData.saleId, showSearch: true, filterOption: (input: string, option: any) => { - return option.label.toLowerCase().indexOf(input.toLowerCase()) >= 0 + let RData = false + if (option.userName.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } else if (option.userCode.toLowerCase().indexOf(input.toLowerCase()) >= 0) { + RData = true + } + return RData }, }, }, diff --git a/src/views/operation/seaexport/components/SelectTextArea.vue b/src/views/operation/seaexport/components/SelectTextArea.vue index 7ad40bef..63294a04 100644 --- a/src/views/operation/seaexport/components/SelectTextArea.vue +++ b/src/views/operation/seaexport/components/SelectTextArea.vue @@ -34,7 +34,7 @@ type="Content" :openToCDB="true" @getTextareaChange="getTextareaChange" - :height="174.5" + :height="140" />
{{ num.length }}
diff --git a/src/views/operation/seaexport/detail/modules/goodsTable.vue b/src/views/operation/seaexport/detail/modules/goodsTable.vue index 0294be4e..4f77550a 100644 --- a/src/views/operation/seaexport/detail/modules/goodsTable.vue +++ b/src/views/operation/seaexport/detail/modules/goodsTable.vue @@ -76,22 +76,6 @@
- - -
暂无数据
加载中 ...
@@ -128,17 +112,7 @@ :settings="moreSettings" v-if="moreSelectLoad" > - + @@ -203,6 +177,7 @@ import { useRoute } from 'vue-router' import { HotTable } from '@handsontable/vue3' import { getDictDropDown } from '/@/api/common' + import { GetPackageSelectList } from '/@/views/operation/seaexport/api/BookingLedger' const route = useRoute() const props = defineProps({ details: { type: Object, default: {} }, @@ -268,6 +243,8 @@ const dataSource = ref([]) // 箱型字段 const ctnDict = ref([]) + //包装 + const kindPkgsDict = ref([]) // 费用名称字典 const feeDict = ref([]) // 费用标准字典 @@ -290,11 +267,11 @@ className: 'htCenter', readOnly: false, }, - { - title: '箱型代码', - width: 120, - data: 'ctnCode', - }, + // { + // title: '箱型代码', + // width: 120, + // data: 'ctnCode', + // }, { title: '箱型', width: 120, @@ -340,6 +317,18 @@ title: '包装', width: 80, data: 'kindPkgs', + type: 'dropdown', + // 下拉框数据,可以同步或者异步返回(异步需要process返回) + source: async (query, process) => { + const res = kindPkgsDict.value.length + ? kindPkgsDict.value + : (await GetPackageSelectList())?.data + if (!kindPkgsDict.value.length) kindPkgsDict.value = res + const dict = res.map((res) => { + return res.packageName + }) + process(dict) + }, }, { title: '毛重', @@ -366,6 +355,17 @@ title: '称重方式', width: 80, data: 'weightType', + type: 'dropdown', + source: async (query, process) => { + const res = ctnDict.value.length + ? ctnDict.value + : (await getDictDropDown({ code: 'weight_type' }))?.data + if (!ctnDict.value.length) ctnDict.value = res + const dict = res.map((res) => { + return res.name + }) + process(dict) + }, }, { title: '称重重量', @@ -1670,88 +1670,6 @@ const childModelSelectIndex: Ref = ref(null) const childTableData: Ref = ref([]) const selectChildArr = ref([]) - const childColumns = ref([ - { - field: '', - key: 'checkbox', - type: 'checkbox', - title: '', - width: 40, - operationColumn: true, - align: 'center', - }, - { - field: 'pkgs', - key: 'pkgs', - title: '件数', - align: 'left', - edit: true, - }, - { - field: 'kindpkgs', - key: 'kindpkgs', - title: '包装', - align: 'left', - edit: false, - width: 130, - // renderBodyCell: ({ row, column, rowIndex }, h) => { - // return ( - // { - // const data = this.packageList[val] - // row['kindpkgs'] = data.name - // childTableData.value[rowIndex].kindpkgs = data.name - // this.$forceUpdate() - // }} - // > - // {this.packageList.map((item, index) => { - // return {item.name} - // })} - // - // ) - // }, - }, - { - field: 'kgs', - key: 'kgs', - title: '毛重', - align: 'left', - edit: true, - }, - { - field: 'cbm', - key: 'cbm', - title: '尺码', - align: 'left', - edit: true, - }, - { - field: 'hscode', - key: 'hscode', - title: 'HS代码', - align: 'left', - edit: true, - }, - { - field: 'marks', - key: 'marks', - title: '唛头', - align: 'left', - edit: true, - }, - { - field: 'description', - key: 'description', - title: '货描', - align: 'left', - width: '25%', - edit: true, - }, - ]) const editChildOption = ref({ beforeCellValueChange: ({ row, column, changeValue }) => { if (