diff --git a/src/api/crm/business/index.ts b/src/api/crm/business/index.ts index 810ec6e9..314eb389 100644 --- a/src/api/crm/business/index.ts +++ b/src/api/crm/business/index.ts @@ -1,4 +1,5 @@ import request from '@/config/axios' +import { TransferReqVO } from '@/api/crm/customer' export interface BusinessVO { id: number @@ -70,3 +71,8 @@ export const getBusinessPageByContact = async (params) => { export const getBusinessListByIds = async (val: number[]) => { return await request.get({ url: '/crm/business/list-by-ids', params: { ids: val.join(',') } }) } + +// 商机转移 +export const transfer = async (data: TransferReqVO) => { + return await request.put({ url: '/crm/business/transfer', data }) +} diff --git a/src/api/crm/contract/index.ts b/src/api/crm/contract/index.ts index 3498e843..527eb5c7 100644 --- a/src/api/crm/contract/index.ts +++ b/src/api/crm/contract/index.ts @@ -1,4 +1,5 @@ import request from '@/config/axios' +import { ProductExpandVO } from '@/api/crm/product' export interface ContractVO { id: number @@ -20,6 +21,7 @@ export interface ContractVO { signUserId: number contactLastTime: Date remark: string + productItems: ProductExpandVO[] } // 查询 CRM 合同列表 diff --git a/src/api/crm/product/index.ts b/src/api/crm/product/index.ts index c6d5dfdb..e6508fb4 100644 --- a/src/api/crm/product/index.ts +++ b/src/api/crm/product/index.ts @@ -12,6 +12,12 @@ export interface ProductVO { ownerUserId: number } +export interface ProductExpandVO extends ProductVO { + count: number + discountPercent: number + totalPrice: number +} + // 查询产品列表 export const getProductPage = async (params) => { return await request.get({ url: `/crm/product/page`, params }) diff --git a/src/components/Table/index.ts b/src/components/Table/index.ts index 689f64a8..9f893171 100644 --- a/src/components/Table/index.ts +++ b/src/components/Table/index.ts @@ -1,6 +1,7 @@ import Table from './src/Table.vue' import { ElTable } from 'element-plus' import { TableSetPropsType } from '@/types/table' +import TableSelectForm from './src/TableSelectForm.vue' export interface TableExpose { setProps: (props: Recordable) => void @@ -9,4 +10,4 @@ export interface TableExpose { elTableRef: ComponentRef } -export { Table } +export { Table, TableSelectForm } diff --git a/src/components/Table/src/TableSelectForm.vue b/src/components/Table/src/TableSelectForm.vue new file mode 100644 index 00000000..55b2855e --- /dev/null +++ b/src/components/Table/src/TableSelectForm.vue @@ -0,0 +1,90 @@ + + + diff --git a/src/views/crm/contract/ContractForm.vue b/src/views/crm/contract/ContractForm.vue index 5d5578f9..a9271ce5 100644 --- a/src/views/crm/contract/ContractForm.vue +++ b/src/views/crm/contract/ContractForm.vue @@ -1,54 +1,108 @@ - diff --git a/src/views/crm/contract/components/ProductList.vue b/src/views/crm/contract/components/ProductList.vue new file mode 100644 index 00000000..6c4ca350 --- /dev/null +++ b/src/views/crm/contract/components/ProductList.vue @@ -0,0 +1,112 @@ + + +