diff --git a/src/api/oa/base/paymentStage/index.ts b/src/api/oa/base/paymentStage/index.ts new file mode 100644 index 0000000..0fe51b7 --- /dev/null +++ b/src/api/oa/base/paymentStage/index.ts @@ -0,0 +1,76 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { PaymentStageVO, PaymentStageForm, PaymentStageQuery } from '@/api/oa/base/paymentStage/types'; + +/** + * 查询回款阶段列表 + * @param query + * @returns {*} + */ + +export const listPaymentStage = (query?: PaymentStageQuery): AxiosPromise => { + return request({ + url: '/oa/base/paymentStage/list', + method: 'get', + params: query + }); +}; + +/** + * 查询回款阶段详细 + * @param paymentStageId + */ +export const getPaymentStage = (paymentStageId: string | number): AxiosPromise => { + return request({ + url: '/oa/base/paymentStage/' + paymentStageId, + method: 'get' + }); +}; + +/** + * 新增回款阶段 + * @param data + */ +export const addPaymentStage = (data: PaymentStageForm) => { + return request({ + url: '/oa/base/paymentStage', + method: 'post', + data: data + }); +}; + +/** + * 修改回款阶段 + * @param data + */ +export const updatePaymentStage = (data: PaymentStageForm) => { + return request({ + url: '/oa/base/paymentStage', + method: 'put', + data: data + }); +}; + +/** + * 删除回款阶段 + * @param paymentStageId + */ +export const delPaymentStage = (paymentStageId: string | number | Array) => { + return request({ + url: '/oa/base/paymentStage/' + paymentStageId, + method: 'delete' + }); +}; + +/** + * 下拉框查询回款阶段列表 + * @param query + * @returns {*} + */ +export function getBasePaymentStageList (query) { + return request({ + url: '/oa/base/paymentStage/getBasePaymentStageList', + method: 'get', + params: query + }); +}; diff --git a/src/api/oa/base/paymentStage/types.ts b/src/api/oa/base/paymentStage/types.ts new file mode 100644 index 0000000..211e5b6 --- /dev/null +++ b/src/api/oa/base/paymentStage/types.ts @@ -0,0 +1,116 @@ +export interface PaymentStageVO { + /** + * 回款阶段ID + */ + paymentStageId: string | number; + + /** + * 阶段编码 + */ + stageCode: string; + + /** + * 阶段名称 + */ + stageName: string; + + /** + * 回款阶段(关联各节点,提示用) + */ + collectionStage: string; + + /** + * 排序号 + */ + sortOrder: number; + + /** + * 备注 + */ + remark: string; + + /** + * 创建者 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新者 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + +} + +export interface PaymentStageForm extends BaseEntity { + /** + * 回款阶段ID + */ + paymentStageId?: string | number; + + /** + * 阶段编码 + */ + stageCode?: string; + + /** + * 阶段名称 + */ + stageName?: string; + + /** + * 回款阶段(关联各节点,提示用) + */ + collectionStage?: string; + + /** + * 排序号 + */ + sortOrder?: number; + + /** + * 备注 + */ + remark?: string; + +} + +export interface PaymentStageQuery extends PageQuery { + + /** + * 阶段编码 + */ + stageCode?: string; + + /** + * 阶段名称 + */ + stageName?: string; + + /** + * 回款阶段(关联各节点,提示用) + */ + collectionStage?: string; + + /** + * 排序号 + */ + sortOrder?: number; + + /** + * 日期范围参数 + */ + params?: any; +} + + + diff --git a/src/api/oa/erp/contractInfo/types.ts b/src/api/oa/erp/contractInfo/types.ts index 0cf3d50..42e8685 100644 --- a/src/api/oa/erp/contractInfo/types.ts +++ b/src/api/oa/erp/contractInfo/types.ts @@ -157,7 +157,7 @@ export interface ContractInfoVO { /** * 合同负责人 */ - contractManagerId: string | number; + contractManagerId: number; /** * 合同负责人名称 @@ -335,7 +335,7 @@ export interface ContractInfoForm extends BaseEntity { /** * 合同负责人 */ - contractManagerId?: string | number; + contractManagerId?: number; /** * 合同大写金额 @@ -506,7 +506,7 @@ export interface ContractInfoQuery extends PageQuery { /** * 合同负责人 */ - contractManagerId?: string | number; + contractManagerId?: number; /** * 合同大写金额 diff --git a/src/api/oa/erp/contractOrder/index.ts b/src/api/oa/erp/contractOrder/index.ts new file mode 100644 index 0000000..87ec5ae --- /dev/null +++ b/src/api/oa/erp/contractOrder/index.ts @@ -0,0 +1,51 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { ProjectInfoVO, ProjectInfoForm } from '@/api/oa/erp/projectInfo/types'; + +/** + * 暂存合同订单(项目信息) + * @param data + */ +export const saveContractOrder = (data: ProjectInfoForm): AxiosPromise => { + return request({ + url: '/oa/erp/contractOrder/save', + method: 'post', + data: data + }); +}; + +/** + * 提交合同订单并提交流程 + * @param data + */ +export const submitContractOrderAndFlowStart = (data: ProjectInfoForm): AxiosPromise => { + return request({ + url: '/oa/erp/contractOrder/submitAndFlowStart', + method: 'post', + data: data + }); +}; + +/** + * 修改合同订单(项目信息) + * @param data + */ +export const updateContractOrder = (data: ProjectInfoForm): AxiosPromise => { + return request({ + url: '/oa/erp/contractOrder', + method: 'put', + data: data + }); +}; + +/** + * 查询合同订单详细信息 + * @param projectId + */ +export const getContractOrder = (projectId: string | number): AxiosPromise => { + return request({ + url: '/oa/erp/contractOrder/' + projectId, + method: 'get' + }); +}; + diff --git a/src/api/oa/erp/contractPaymentStage/index.ts b/src/api/oa/erp/contractPaymentStage/index.ts new file mode 100644 index 0000000..c8f604a --- /dev/null +++ b/src/api/oa/erp/contractPaymentStage/index.ts @@ -0,0 +1,76 @@ +import request from '@/utils/request'; +import { AxiosPromise } from 'axios'; +import { ContractPaymentStageVO, ContractPaymentStageForm, ContractPaymentStageQuery } from '@/api/oa/erp/contractPaymentStage/types'; + +/** + * 查询合同回款阶段列表 + * @param query + * @returns {*} + */ + +export const listContractPaymentStage = (query?: ContractPaymentStageQuery): AxiosPromise => { + return request({ + url: '/oa/erp/contractPaymentStage/list', + method: 'get', + params: query + }); +}; + +/** + * 查询合同回款阶段详细 + * @param contractStageId + */ +export const getContractPaymentStage = (contractStageId: string | number): AxiosPromise => { + return request({ + url: '/oa/erp/contractPaymentStage/' + contractStageId, + method: 'get' + }); +}; + +/** + * 新增合同回款阶段 + * @param data + */ +export const addContractPaymentStage = (data: ContractPaymentStageForm) => { + return request({ + url: '/oa/erp/contractPaymentStage', + method: 'post', + data: data + }); +}; + +/** + * 修改合同回款阶段 + * @param data + */ +export const updateContractPaymentStage = (data: ContractPaymentStageForm) => { + return request({ + url: '/oa/erp/contractPaymentStage', + method: 'put', + data: data + }); +}; + +/** + * 删除合同回款阶段 + * @param contractStageId + */ +export const delContractPaymentStage = (contractStageId: string | number | Array) => { + return request({ + url: '/oa/erp/contractPaymentStage/' + contractStageId, + method: 'delete' + }); +}; + +/** + * 下拉框查询合同回款阶段列表 + * @param query + * @returns {*} + */ +export function getErpContractPaymentStageList (query) { + return request({ + url: '/oa/erp/contractPaymentStage/getErpContractPaymentStageList', + method: 'get', + params: query + }); +}; diff --git a/src/api/oa/erp/contractPaymentStage/types.ts b/src/api/oa/erp/contractPaymentStage/types.ts new file mode 100644 index 0000000..792a70f --- /dev/null +++ b/src/api/oa/erp/contractPaymentStage/types.ts @@ -0,0 +1,256 @@ +export interface ContractPaymentStageVO { + /** + * 合同回款阶段ID + */ + contractStageId: string | number; + + /** + * 合同ID + */ + contractId: string | number; + + /** + * 回款阶段ID + */ + paymentStageId: string | number; + + /** + * 阶段名称 + */ + stageName: string; + + /** + * 回款阶段 + */ + collectionStage: string; + + /** + * 回款比例(%) + */ + repaymentRate: number; + + /** + * 预计回款日期 + */ + expectRepaymentDate: string; + + /** + * 回款延期天数 + */ + delayDay: number; + + /** + * 实际回款日期 + */ + actualRepaymentDate: string; + + /** + * 回款标识(0否 1是) + */ + repaymentFlag: string; + + /** + * 原因说明 + */ + reasonsExplanation: string; + + /** + * 进度备注 + */ + scheduleRemark: string; + + /** + * 回款金额(预留) + */ + repaymentAmount: number; + + /** + * 排序号 + */ + sortOrder: number; + + /** + * 备注 + */ + remark: string; + + /** + * 创建部门 + */ + createDept: number; + + /** + * 创建者 + */ + createBy: number; + + /** + * 创建时间 + */ + createTime: string; + + /** + * 更新者 + */ + updateBy: number; + + /** + * 更新时间 + */ + updateTime: string; + +} + +export interface ContractPaymentStageForm extends BaseEntity { + /** + * 合同回款阶段ID + */ + contractStageId?: string | number; + + /** + * 合同ID + */ + contractId?: string | number; + + /** + * 回款阶段ID + */ + paymentStageId?: string | number; + + /** + * 阶段名称 + */ + stageName?: string; + + /** + * 回款阶段 + */ + collectionStage?: string; + + /** + * 回款比例(%) + */ + repaymentRate?: number; + + /** + * 预计回款日期 + */ + expectRepaymentDate?: string; + + /** + * 回款延期天数 + */ + delayDay?: number; + + /** + * 实际回款日期 + */ + actualRepaymentDate?: string; + + /** + * 回款标识(0否 1是) + */ + repaymentFlag?: string; + + /** + * 原因说明 + */ + reasonsExplanation?: string; + + /** + * 进度备注 + */ + scheduleRemark?: string; + + /** + * 回款金额(预留) + */ + repaymentAmount?: number; + + /** + * 排序号 + */ + sortOrder?: number; + + /** + * 备注 + */ + remark?: string; + +} + +export interface ContractPaymentStageQuery extends PageQuery { + + /** + * 合同ID + */ + contractId?: string | number; + + /** + * 回款阶段ID + */ + paymentStageId?: string | number; + + /** + * 阶段名称 + */ + stageName?: string; + + /** + * 回款阶段 + */ + collectionStage?: string; + + /** + * 回款比例(%) + */ + repaymentRate?: number; + + /** + * 预计回款日期 + */ + expectRepaymentDate?: string; + + /** + * 回款延期天数 + */ + delayDay?: number; + + /** + * 实际回款日期 + */ + actualRepaymentDate?: string; + + /** + * 回款标识(0否 1是) + */ + repaymentFlag?: string; + + /** + * 原因说明 + */ + reasonsExplanation?: string; + + /** + * 进度备注 + */ + scheduleRemark?: string; + + /** + * 回款金额(预留) + */ + repaymentAmount?: number; + + /** + * 排序号 + */ + sortOrder?: number; + + /** + * 日期范围参数 + */ + params?: any; +} + + + diff --git a/src/components/SaleMaterialSelect/index.vue b/src/components/SaleMaterialSelect/index.vue index 768b3ec..a72e00e 100644 --- a/src/components/SaleMaterialSelect/index.vue +++ b/src/components/SaleMaterialSelect/index.vue @@ -32,7 +32,7 @@ - + @@ -575,4 +583,27 @@ const contractView = (e) => { const canViewDetail = (row: ContractInfoVO) => { return row.contractStatus !== '1'; }; + +/** 判断是否可以激活合同订单 */ +const canActivateOrder = (row: ContractInfoVO) => { + // 合同大类是产品销售且合同状态为可用(3) + if (row.contractStatus !== '3') { + return false; + } + // "合同大类(1市场实施 2产品销售) + return row.contractCategory === '2'; +}; + +/** 订单激活按钮操作 */ +const handleOrderActivate = (row?: ContractInfoVO) => { + const _contractId = row?.contractId; + proxy.$tab.closePage(route); + router.push({ + path: '/contract/contractInfo/orderActivate', + query: { + contractId: _contractId, + type: 'add', + } + }); +}; diff --git a/src/views/oa/erp/contractInfo/orderActivate.vue b/src/views/oa/erp/contractInfo/orderActivate.vue new file mode 100644 index 0000000..5f26ab1 --- /dev/null +++ b/src/views/oa/erp/contractInfo/orderActivate.vue @@ -0,0 +1,726 @@ + + + + + diff --git a/src/views/oa/erp/contractPaymentStage/index.vue b/src/views/oa/erp/contractPaymentStage/index.vue new file mode 100644 index 0000000..93647b3 --- /dev/null +++ b/src/views/oa/erp/contractPaymentStage/index.vue @@ -0,0 +1,411 @@ + + +