船期 采购销售执行优化
This commit is contained in:
@ -9,11 +9,23 @@ enum Api {
|
|||||||
Info = '/ship/shipSchedule/info',
|
Info = '/ship/shipSchedule/info',
|
||||||
LngShipSchedule = '/ship/shipSchedule',
|
LngShipSchedule = '/ship/shipSchedule',
|
||||||
ContractPageList = '/magic-api/ship/selectSalesContractPageList',
|
ContractPageList = '/magic-api/ship/selectSalesContractPageList',
|
||||||
|
ContractPageListSales = '/magic-api/ship/selectSalesIntContractPageList',
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
DataLog = '/ship/shipSchedule/datalog',
|
DataLog = '/ship/shipSchedule/datalog',
|
||||||
}
|
}
|
||||||
|
export async function getContractPageListSales(params: LngShipSchedulePageParams, mode: ErrorMessageMode = 'modal') {
|
||||||
|
return defHttp.get<LngShipSchedulePageResult>(
|
||||||
|
{
|
||||||
|
url: Api.ContractPageListSales,
|
||||||
|
params,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
errorMessageMode: mode,
|
||||||
|
},
|
||||||
|
);
|
||||||
|
}
|
||||||
export async function getContractPageList(params: LngShipSchedulePageParams, mode: ErrorMessageMode = 'modal') {
|
export async function getContractPageList(params: LngShipSchedulePageParams, mode: ErrorMessageMode = 'modal') {
|
||||||
return defHttp.get<LngShipSchedulePageResult>(
|
return defHttp.get<LngShipSchedulePageResult>(
|
||||||
{
|
{
|
||||||
|
|||||||
@ -13,7 +13,7 @@
|
|||||||
import { BasicTable, useTable, FormSchema, BasicColumn, TableAction } from '/@/components/Table';
|
import { BasicTable, useTable, FormSchema, BasicColumn, TableAction } from '/@/components/Table';
|
||||||
import { useMessage } from '/@/hooks/web/useMessage';
|
import { useMessage } from '/@/hooks/web/useMessage';
|
||||||
import { useI18n } from '/@/hooks/web/useI18n';
|
import { useI18n } from '/@/hooks/web/useI18n';
|
||||||
import { getContractPageList} from '/@/api/ship/ShipSchedule';
|
import { getContractPageList,getContractPageListSales} from '/@/api/ship/ShipSchedule';
|
||||||
|
|
||||||
const { t } = useI18n();
|
const { t } = useI18n();
|
||||||
const codeFormSchema: FormSchema[] = [
|
const codeFormSchema: FormSchema[] = [
|
||||||
@ -34,12 +34,13 @@
|
|||||||
{ title: t('合同号'), dataIndex: 'kNo', },
|
{ title: t('合同号'), dataIndex: 'kNo', },
|
||||||
{ title: t('合同名称'), dataIndex: 'kName', },
|
{ title: t('合同名称'), dataIndex: 'kName', },
|
||||||
{ title: t('供应商'), dataIndex: 'suName' ,},
|
{ title: t('供应商'), dataIndex: 'suName' ,},
|
||||||
{ title: '有效期开始',dataIndex: 'dateFrom', width: 120,},
|
{ title: t('供应商简称'), dataIndex: 'suSname' ,},
|
||||||
{ title: '有效期结束',dataIndex: 'dateTo', width: 120},
|
{ title: '有效期开始',dataIndex: 'dateFrom', width: 100,},
|
||||||
{ title: t('合同主体'), dataIndex: 'comName', },
|
{ title: '有效期结束',dataIndex: 'dateTo', width: 100},
|
||||||
{ title: t('长协/现货'), dataIndex: 'longSpotName'},
|
{ title: t('合同主体'), dataIndex: 'comName', width: 100},
|
||||||
|
{ title: t('长协/现货'), dataIndex: 'longSpotName', width: 100},
|
||||||
{ title: t('气源地'), dataIndex: 'sourceName'},
|
{ title: t('气源地'), dataIndex: 'sourceName'},
|
||||||
{ title: t('价格条款'), dataIndex: 'prcTermName'},
|
{ title: t('价格条款'), dataIndex: 'prcTermName', width: 100},
|
||||||
|
|
||||||
];
|
];
|
||||||
|
|
||||||
@ -52,6 +53,7 @@
|
|||||||
const selectedValues = ref([]);
|
const selectedValues = ref([]);
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
selectType: { type: String, default: 'checkbox' },
|
selectType: { type: String, default: 'checkbox' },
|
||||||
|
pageType: { type: String, default: 'pur' },
|
||||||
|
|
||||||
});
|
});
|
||||||
const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data) => {
|
const [registerModal, { setModalProps, closeModal }] = useModalInner(async (data) => {
|
||||||
@ -63,7 +65,7 @@
|
|||||||
|
|
||||||
const [registerTable, { getDataSource, setTableData, updateTableDataRecord, reload }] = useTable({
|
const [registerTable, { getDataSource, setTableData, updateTableDataRecord, reload }] = useTable({
|
||||||
title: t('国际采购合同列表'),
|
title: t('国际采购合同列表'),
|
||||||
api: getContractPageList,
|
api: props.pageType=='pur'? getContractPageList : getContractPageListSales,
|
||||||
columns,
|
columns,
|
||||||
|
|
||||||
bordered: true,
|
bordered: true,
|
||||||
@ -95,7 +97,7 @@
|
|||||||
selectedKeys.value = rowKeys;
|
selectedKeys.value = rowKeys;
|
||||||
selectedValues.value = e
|
selectedValues.value = e
|
||||||
}
|
}
|
||||||
const getTitle = computed(() => (!unref(isUpdate) ? t('国际采购合同列表') : t('')));
|
const getTitle = computed(() => (!unref(isUpdate) ? (props.pageType=='pur'?t('国际采购合同列表'):'国际销售合同列表') : t('')));
|
||||||
|
|
||||||
async function handleSubmit() {
|
async function handleSubmit() {
|
||||||
if (!selectedValues.value.length) {
|
if (!selectedValues.value.length) {
|
||||||
|
|||||||
@ -357,7 +357,7 @@
|
|||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
<deptUserModal @register="register" @success="handleSuccess"/>
|
<deptUserModal @register="register" @success="handleSuccess"/>
|
||||||
<contractPurIntListModal @register="registerContractPurInt" @success="handleSuccessContractPurInt" selectType="radio" />
|
<contractPurIntListModal @register="registerContractPurInt" @success="handleSuccessContractPurInt" selectType="radio" pageType="pur"/>
|
||||||
<lngStationModal @register="registerStation" @success="handleSuccessStation"/>
|
<lngStationModal @register="registerStation" @success="handleSuccessStation"/>
|
||||||
<portListModal @register="registerPort" @success="handleSuccessPort"/>
|
<portListModal @register="registerPort" @success="handleSuccessPort"/>
|
||||||
<shipScheduleListModal @register="registerShip" @success="handleSuccessShip" />
|
<shipScheduleListModal @register="registerShip" @success="handleSuccessShip" />
|
||||||
@ -709,7 +709,7 @@
|
|||||||
formState.kName = val[0].kName
|
formState.kName = val[0].kName
|
||||||
formState.comId = val[0].comId
|
formState.comId = val[0].comId
|
||||||
formState.suCode = val[0].suCode
|
formState.suCode = val[0].suCode
|
||||||
formState.suName = val[0].suName
|
formState.suName = val[0].suSname
|
||||||
formState.longSpotCode = val[0].longSpotCode
|
formState.longSpotCode = val[0].longSpotCode
|
||||||
formState.prcTermCode = val[0].prcTermCode
|
formState.prcTermCode = val[0].prcTermCode
|
||||||
formState.sourceName = val[0].sourceName
|
formState.sourceName = val[0].sourceName
|
||||||
|
|||||||
@ -326,7 +326,7 @@
|
|||||||
</a-form>
|
</a-form>
|
||||||
</div>
|
</div>
|
||||||
<deptUserModal @register="register" @success="handleSuccess"/>
|
<deptUserModal @register="register" @success="handleSuccess"/>
|
||||||
<contractPurIntListModal @register="registerContractPurInt" @success="handleSuccessContractPurInt" selectType="radio" />
|
<contractPurIntListModal @register="registerContractPurInt" @success="handleSuccessContractPurInt" selectType="radio" pageType="sales"/>
|
||||||
<lngStationModal @register="registerStation" @success="handleSuccessStation"/>
|
<lngStationModal @register="registerStation" @success="handleSuccessStation"/>
|
||||||
<portListModal @register="registerPort" @success="handleSuccessPort"/>
|
<portListModal @register="registerPort" @success="handleSuccessPort"/>
|
||||||
<shipScheduleListModal @register="registerShip" @success="handleSuccessShip" />
|
<shipScheduleListModal @register="registerShip" @success="handleSuccessShip" />
|
||||||
|
|||||||
@ -424,14 +424,14 @@
|
|||||||
}
|
}
|
||||||
const handleSuccessSupplier = (val) => {
|
const handleSuccessSupplier = (val) => {
|
||||||
formState.suCode = val[0].suCode
|
formState.suCode = val[0].suCode
|
||||||
formState.suName = val[0].suName
|
formState.suName = val[0].suSname
|
||||||
}
|
}
|
||||||
const handleSuccessContractPurInt = (val) => {
|
const handleSuccessContractPurInt = (val) => {
|
||||||
formState.kId = val[0].id
|
formState.kId = val[0].id
|
||||||
formState.kName = val[0].kName
|
formState.kName = val[0].kName
|
||||||
formState.comId = val[0].comId
|
formState.comId = val[0].comId
|
||||||
formState.suCode = val[0].suCode
|
formState.suCode = val[0].suCode
|
||||||
formState.suName = val[0].suName
|
formState.suName = val[0].suSname
|
||||||
formState.longSpotCode = val[0].longSpotCode
|
formState.longSpotCode = val[0].longSpotCode
|
||||||
formState.prcTermCode = val[0].prcTermCode
|
formState.prcTermCode = val[0].prcTermCode
|
||||||
formState.sourceName = val[0].sourceName
|
formState.sourceName = val[0].sourceName
|
||||||
|
|||||||
Reference in New Issue
Block a user