diff --git a/src/api/ship/OpsPurInt/index.ts b/src/api/ship/OpsPurInt/index.ts index 9946023..8213783 100644 --- a/src/api/ship/OpsPurInt/index.ts +++ b/src/api/ship/OpsPurInt/index.ts @@ -3,7 +3,8 @@ import { defHttp } from '/@/utils/http/axios'; import { ErrorMessageMode } from '/#/axios'; enum Api { - Page = '/ship/opsPurInt/page', + // Page = '/ship/opsPurInt/page', + Page = '/magic-api/ship/opsPurIntPageList', List = '/ship/opsPurInt/list', Info = '/ship/opsPurInt/info', LngOpsPurInt = '/ship/opsPurInt', diff --git a/src/api/ship/ShipSchedule/index.ts b/src/api/ship/ShipSchedule/index.ts index 3a8e8ed..ed708c4 100644 --- a/src/api/ship/ShipSchedule/index.ts +++ b/src/api/ship/ShipSchedule/index.ts @@ -3,17 +3,28 @@ import { defHttp } from '/@/utils/http/axios'; import { ErrorMessageMode } from '/#/axios'; enum Api { - Page = '/ship/shipSchedule/page', + // Page = '/ship/shipSchedule/page', + Page = '/magic-api/ship/shipSchedulePageList', List = '/ship/shipSchedule/list', Info = '/ship/shipSchedule/info', LngShipSchedule = '/ship/shipSchedule', - + ContractPageList = '/magic-api/ship/selectSalesContractPageList', DataLog = '/ship/shipSchedule/datalog', } - +export async function getContractPageList(params: LngShipSchedulePageParams, mode: ErrorMessageMode = 'modal') { + return defHttp.get( + { + url: Api.ContractPageList, + params, + }, + { + errorMessageMode: mode, + }, + ); +} /** * @description: 查询LngShipSchedule分页列表 */ diff --git a/src/components/common/ContractPurIntListModal.vue b/src/components/common/ContractPurIntListModal.vue new file mode 100644 index 0000000..c485c9a --- /dev/null +++ b/src/components/common/ContractPurIntListModal.vue @@ -0,0 +1,134 @@ + + + + diff --git a/src/components/common/lngStationModal.vue b/src/components/common/lngStationModal.vue index d1d11c1..81b7e51 100644 --- a/src/components/common/lngStationModal.vue +++ b/src/components/common/lngStationModal.vue @@ -81,7 +81,7 @@ selectedKeys.value = rowKeys; selectedValues.value = e } - const getTitle = computed(() => (!unref(isUpdate) ? t('列表') : t(''))); + const getTitle = computed(() => (!unref(isUpdate) ? t('接收站列表') : t(''))); function handleCancel () { emit('cancel',); } diff --git a/src/components/common/portListModal.vue b/src/components/common/portListModal.vue new file mode 100644 index 0000000..cf199ea --- /dev/null +++ b/src/components/common/portListModal.vue @@ -0,0 +1,118 @@ + + + + diff --git a/src/components/pcitc/src/DataLog.vue b/src/components/pcitc/src/DataLog.vue index f71093f..42f855b 100644 --- a/src/components/pcitc/src/DataLog.vue +++ b/src/components/pcitc/src/DataLog.vue @@ -7,7 +7,7 @@ @ok="handleOk" @cancel="handleCancel" > - + @@ -16,6 +16,7 @@ import { defHttp } from '/@/utils/http/axios'; import { ErrorMessageMode } from '/#/axios'; import { watch, defineProps, ref, computed, onMounted, onUnmounted, createVNode, reactive, } from 'vue'; + const loading = ref() const columns = [ { title: '表名', @@ -132,8 +133,6 @@ const handleCancel = () => { emit('cancel'); visible.value = false; }; - -console.log(props.logId, 444, props.logPath) interface DataItem { children?: DataItem[]; } @@ -163,8 +162,14 @@ console.log(props.logId, 444, props.logPath) } async function getLog() { - data.value = await getDataLogData(props.logId,props.logPath,{}) - console.log(data.value, 88) + loading.value = true + try { + data.value = await getDataLogData(props.logId,props.logPath,{}) + loading.value = false + } catch (error) { + loading.value = false + } + } onMounted( async() => { diff --git a/src/design/index.less b/src/design/index.less index bb1f4c8..597f3bd 100644 --- a/src/design/index.less +++ b/src/design/index.less @@ -103,4 +103,5 @@ span { .ant-input-affix-wrapper-disabled { border-color: transparent !important; border: 1px solid #fff !important; + background-color: transparent !important; } \ No newline at end of file diff --git a/src/router/routes/basic.ts b/src/router/routes/basic.ts index 49510fd..2c40371 100644 --- a/src/router/routes/basic.ts +++ b/src/router/routes/basic.ts @@ -309,7 +309,23 @@ export const PAGE_CUSTOM_ROUTE: AppRouteRecordRaw[] = [{ meta: { title: (route) => ('管道气采购合同详情') } - } + }, + { + path: '/ship/ShipSchedule/createForm', + name: 'ShipSchedule', + component: () => import('/@/views/ship/ShipSchedule/components/createForm.vue'), + meta: { + title: (route) => route.query.formName + } + }, + { + path: '/ship/OpsPurInt/createForm', + name: 'OpsPurInt', + component: () => import('/@/views/ship/OpsPurInt/components/createForm.vue'), + meta: { + title: (route) => route.query.formName + } + }, ] diff --git a/src/views/contract/ContractFact/index.vue b/src/views/contract/ContractFact/index.vue index 61f974a..7b66427 100644 --- a/src/views/contract/ContractFact/index.vue +++ b/src/views/contract/ContractFact/index.vue @@ -380,7 +380,7 @@ let res = await getAllCom() || [] comIdList.value = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/contract/ContractProc/components/createForm.vue b/src/views/contract/ContractProc/components/createForm.vue index c69d84d..7c1de11 100644 --- a/src/views/contract/ContractProc/components/createForm.vue +++ b/src/views/contract/ContractProc/components/createForm.vue @@ -82,7 +82,7 @@ - + @@ -203,7 +203,7 @@ - + @@ -234,7 +234,7 @@ import correlationApproList from '/@/components/common/correlationApproList.vue'; import correlationContractFactList from '/@/components/common/correlationContractFactList.vue'; import contractFactListModal from '/@/components/common/contractFactListModal.vue'; - import downloadPointModal from '/@/components/common/downloadPointModal.vue'; + import lngStationModal from '/@/components/common/lngStationModal.vue'; import supplierListModal from '/@/components/common/supplierListModal.vue'; import { getAllCurrency } from '/@/api/contract/ContractFact'; import { useUserStore } from '/@/store/modules/user'; @@ -280,7 +280,7 @@ const [register, { openModal:openModal}] = useModal(); const [registerDept, { openModal:openModalDept}] = useModal(); const [registerContractFact, { openModal:openModalContractFact}] = useModal(); - const [registerDownLoad, { openModal:openModalDownLoad}] = useModal(); + const [registerStation, { openModal:openModalStation}] = useModal(); const [registerSupplier, { openModal:openModalSupplier}] = useModal(); const rules= reactive({ kNo: [{ required: true, message: "该项为必填项", trigger: 'change' }], @@ -507,8 +507,8 @@ const onContract = (val)=> { openModalContractFact(true,{isUpdate: false}) } - const onSearchDownLoad = (val, index)=> { - openModalDownLoad(true,{isUpdate: false, type: val}) + const onSearchStation = (val)=> { + openModalStation(true,{isUpdate: false}) } const addProc = () => { @@ -587,7 +587,7 @@ formState.cpCode = formState.cpCode ? formState.cpCode : (res?.lngContractFactCpList || [])[0]?.cpCode } } - const handleSuccessDownLoad = (val) => { + const handleSuccessStation = (val) => { formState.lngContractProcList[0].staCode = val[0].code formState.lngContractProcList[0].staName = val[0].fullName formState.staName = val[0].fullName diff --git a/src/views/contract/ContractPurInt/components/createForm.vue b/src/views/contract/ContractPurInt/components/createForm.vue index 2eac1d1..7ff79eb 100644 --- a/src/views/contract/ContractPurInt/components/createForm.vue +++ b/src/views/contract/ContractPurInt/components/createForm.vue @@ -35,7 +35,7 @@ - + @@ -345,7 +345,7 @@ const [register, { openModal:openModal}] = useModal(); const [registerDept, { openModal:openModalDept}] = useModal(); const [registerContractFact, { openModal:openModalContractFact}] = useModal(); - const [registerSupplier, { openModal:openModalCustomer}] = useModal(); + const [registerSupplier, { openModal:openModalSupplier}] = useModal(); const rules= reactive({ kNo: [{ required: true, message: "该项为必填项", trigger: 'change' }], kName: [{ required: true, message: "该项为必填项", trigger: 'change' }], @@ -573,8 +573,8 @@ const onSearch = (val)=> { openModalDept(true,{isUpdate: false}) } - const onSearchCustomer = () => { - openModalCustomer(true,{isUpdate: false}) + const onSearchSupplier = () => { + openModalSupplier(true,{isUpdate: false}) } const onSearchUser = (val)=> { openModal(true,{isUpdate: false}) diff --git a/src/views/contract/ContractPurInt/index.vue b/src/views/contract/ContractPurInt/index.vue index b696e3a..c2d32cb 100644 --- a/src/views/contract/ContractPurInt/index.vue +++ b/src/views/contract/ContractPurInt/index.vue @@ -325,7 +325,7 @@ if (v.field == 'comId') { v.componentProps.options = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/contract/ContractPurPng/index.vue b/src/views/contract/ContractPurPng/index.vue index 6ff5ea6..4319206 100644 --- a/src/views/contract/ContractPurPng/index.vue +++ b/src/views/contract/ContractPurPng/index.vue @@ -329,7 +329,7 @@ if (v.field == 'comId') { v.componentProps.options = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/contract/ContractSales/index.vue b/src/views/contract/ContractSales/index.vue index b758019..54f85bf 100644 --- a/src/views/contract/ContractSales/index.vue +++ b/src/views/contract/ContractSales/index.vue @@ -327,7 +327,7 @@ if (v.field == 'comId') { v.componentProps.options = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/contract/ContractSalesInt/index.vue b/src/views/contract/ContractSalesInt/index.vue index 56bf654..c35fafa 100644 --- a/src/views/contract/ContractSalesInt/index.vue +++ b/src/views/contract/ContractSalesInt/index.vue @@ -326,7 +326,7 @@ if (v.field == 'comId') { v.componentProps.options = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/contract/ContractSalesLng/index.vue b/src/views/contract/ContractSalesLng/index.vue index e12185f..8001b77 100644 --- a/src/views/contract/ContractSalesLng/index.vue +++ b/src/views/contract/ContractSalesLng/index.vue @@ -330,7 +330,7 @@ if (v.field == 'comId') { v.componentProps.options = res.map(v=> { return { - label: v.name, + label: v.shortName, value: v.id } }) diff --git a/src/views/dayPlan/PngSettleHdr/components/createForm.vue b/src/views/dayPlan/PngSettleHdr/components/createForm.vue index 09f8cfe..07a92f1 100644 --- a/src/views/dayPlan/PngSettleHdr/components/createForm.vue +++ b/src/views/dayPlan/PngSettleHdr/components/createForm.vue @@ -28,7 +28,7 @@ - {{ item.name }} + {{ item.shortName }} diff --git a/src/views/dayPlan/PngSettleHdrPur/components/createForm.vue b/src/views/dayPlan/PngSettleHdrPur/components/createForm.vue index 2c6f991..a143357 100644 --- a/src/views/dayPlan/PngSettleHdrPur/components/createForm.vue +++ b/src/views/dayPlan/PngSettleHdrPur/components/createForm.vue @@ -28,7 +28,7 @@ - {{ item.name }} + {{ item.shortName }} diff --git a/src/views/ship/OpsPurInt/components/config.ts b/src/views/ship/OpsPurInt/components/config.ts index b6427ca..518aa4d 100644 --- a/src/views/ship/OpsPurInt/components/config.ts +++ b/src/views/ship/OpsPurInt/components/config.ts @@ -6,96 +6,68 @@ export const formConfig = { }; export const searchFormSchema: FormSchema[] = [ - { - field: 'id', - label: 'id', - component: 'Input', - }, { field: 'ssNo', label: '船期编号', component: 'Input', }, { - field: 'kId', + field: 'kN', label: '合同', component: 'Input', }, - { - field: 'longSpotCode', - label: '长协/现货', - component: 'Input', - }, - { - field: 'comId', - label: '交易主体', - component: 'Input', - }, { field: 'dateEta', label: '卸港ETA', component: 'Input', }, - { - field: 'staCode', - label: '接收站', - component: 'Input', - }, + { field: 'suName', label: '供应商', component: 'Input', }, { - field: 'ssTypeCode', - label: '业务类型', + field: 'staName', + label: '接收站', component: 'Input', }, ]; export const columns: BasicColumn[] = [ - { - dataIndex: 'id', - title: 'id', - componentType: 'input', - align: 'left', - - sorter: true, - }, - { dataIndex: 'ssNo', title: '船期编号', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'kId', + dataIndex: 'kName', title: '合同', componentType: 'input', align: 'left', - + width: 150, sorter: true, }, { - dataIndex: 'longSpotCode', + dataIndex: 'longSpotName', title: '长协/现货', componentType: 'input', align: 'left', - + width: 100, sorter: true, }, { - dataIndex: 'comId', + dataIndex: 'comName', title: '交易主体', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, @@ -104,16 +76,16 @@ export const columns: BasicColumn[] = [ title: '卸港ETA', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'staCode', + dataIndex: 'staName', title: '接收站', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, @@ -122,16 +94,16 @@ export const columns: BasicColumn[] = [ title: '供应商', componentType: 'input', align: 'left', - + width: 150, sorter: true, }, { - dataIndex: 'ssTypeCode', + dataIndex: 'ssTypeName', title: '业务类型', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, ]; diff --git a/src/views/ship/OpsPurInt/components/createForm.vue b/src/views/ship/OpsPurInt/components/createForm.vue new file mode 100644 index 0000000..adca31b --- /dev/null +++ b/src/views/ship/OpsPurInt/components/createForm.vue @@ -0,0 +1,648 @@ + + + + + diff --git a/src/views/ship/OpsPurInt/index.vue b/src/views/ship/OpsPurInt/index.vue index 67b563c..a02a5dc 100644 --- a/src/views/ship/OpsPurInt/index.vue +++ b/src/views/ship/OpsPurInt/index.vue @@ -51,6 +51,7 @@ import Icon from '/@/components/Icon/index'; import useEventBus from '/@/hooks/event/useEventBus'; import { cloneDeep } from 'lodash-es'; + import dayjs from 'dayjs'; const { bus, CREATE_FLOW, FLOW_PROCESSED, FORM_LIST_MODIFIED } = useEventBus(); @@ -89,8 +90,9 @@ formIdComputedRef.value = currentRoute.value.meta.formId const schemaIdComputedRef = ref(); schemaIdComputedRef.value = currentRoute.value.meta.schemaId + const defaultDate = ref([dayjs().startOf('year').format('YYYY-MM-DD'), dayjs().add(1, 'year').endOf('year').format('YYYY-MM-DD')]); const [registerModal, { openModal }] = useModal(); - const formName='采购执行'; + const formName=currentRoute.value.meta?.title; const [registerTable, { reload, }] = useTable({ title: '' || (formName + '列表'), api: getLngOpsPurIntPage, @@ -100,10 +102,38 @@ rowProps: { gutter: 16, }, - schemas: customSearchFormSchema, - fieldMapToTime: [], - showResetButton: false, + schemas: [ + { + field: 'dateEta', + label: '卸港ETA', + component: 'RangePicker', + defaultValue: defaultDate.value, + componentProps: { + format: 'YYYY-MM-DD', + style: { width: '100%' }, + getPopupContainer: () => document.body, + }, + }, + { + field: 'ssNo', + label: '船期编号', + component: 'Input', + }, + { + field: 'suName', + label: '供应商', + component: 'Input', + }, + { + field: 'staName', + label: '接收站', + component: 'Input', + }, + ], + fieldMapToTime: [['dateEta', ['startDate', 'endDate'], 'YYYY-MM-DD']], + showResetButton: true, }, + immediate: false, beforeFetch: (params) => { return { ...params, FormId: formIdComputedRef.value, PK: 'id' }; }, @@ -180,10 +210,10 @@ }); } else { router.push({ - path: '/form/OpsPurInt/0/createForm', + path: '/ship/OpsPurInt/createForm', query: { formPath: 'ship/OpsPurInt', - formName: formName, + formName: '新建'+formName, formId:currentRoute.value.meta.formId } }); @@ -237,7 +267,7 @@ } onMounted(() => { - + reload({ searchInfo: { startDate: defaultDate.value[0], endDate: defaultDate.value[1] }}); if (schemaIdComputedRef.value) { bus.on(FLOW_PROCESSED, handleRefresh); bus.on(CREATE_FLOW, handleRefresh); @@ -305,4 +335,18 @@ .hide{ display: none !important; } + :deep( .ant-col-8:nth-child(1)) { + width: 320px !important; + max-width: 320px !important;; + } + :deep(.ant-col-8:nth-child(1) .ant-form-item-label) { + width: 80px !important; + } + :deep( .ant-col-8:nth-child(4)) { + width: 320px !important; + max-width: 320px !important;; + } + :deep(.ant-col-8:nth-child(4) .ant-form-item-label) { + width: 80px !important; + } \ No newline at end of file diff --git a/src/views/ship/ShipSchedule/components/config.ts b/src/views/ship/ShipSchedule/components/config.ts index ff98787..781c399 100644 --- a/src/views/ship/ShipSchedule/components/config.ts +++ b/src/views/ship/ShipSchedule/components/config.ts @@ -29,34 +29,34 @@ export const columns: BasicColumn[] = [ title: '船期编号', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'kId', + dataIndex: 'kName', title: '合同', componentType: 'input', align: 'left', - + width: 150, sorter: true, }, { - dataIndex: 'longSpotCode', + dataIndex: 'longSpotName', title: '长协/现货', componentType: 'input', align: 'left', - + width: 100, sorter: true, }, { - dataIndex: 'comId', + dataIndex: 'comName', title: '交易主体', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, @@ -65,16 +65,16 @@ export const columns: BasicColumn[] = [ title: '卸港ETA', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'staCode', + dataIndex: 'staName', title: '接收站', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, @@ -83,34 +83,34 @@ export const columns: BasicColumn[] = [ title: '供应商', componentType: 'input', align: 'left', - + width: 150, sorter: true, }, { - dataIndex: 'ssTypeCode', + dataIndex: 'ssTypeName', title: '业务类型', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'opsPurId', + dataIndex: 'opsPurName', title: '采购执行状态', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, { - dataIndex: 'opsSalesId', + dataIndex: 'opsSalesName', title: '销售执行状态', componentType: 'input', align: 'left', - + width: 120, sorter: true, }, ]; diff --git a/src/views/ship/ShipSchedule/components/createForm.vue b/src/views/ship/ShipSchedule/components/createForm.vue new file mode 100644 index 0000000..86c23ff --- /dev/null +++ b/src/views/ship/ShipSchedule/components/createForm.vue @@ -0,0 +1,509 @@ + + + + + diff --git a/src/views/ship/ShipSchedule/index.vue b/src/views/ship/ShipSchedule/index.vue index 2e7b066..6dc6a43 100644 --- a/src/views/ship/ShipSchedule/index.vue +++ b/src/views/ship/ShipSchedule/index.vue @@ -1,5 +1,5 @@