Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
phsl
/
admin
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
9fa769b1
authored
Jan 15, 2024
by
YunaiV
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
📖
CRM:跟进记录的 code review
parent
163613e9
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
40 additions
and
44 deletions
+40
-44
src/api/crm/business/index.ts
+1
-1
src/api/crm/followup/index.ts
+8
-16
src/components/OperateLogV2/src/OperateLogV2.vue
+1
-1
src/router/modules/remaining.ts
+1
-1
src/utils/dict.ts
+2
-4
src/views/crm/customer/detail/index.vue
+7
-7
src/views/crm/customer/index.vue
+1
-1
src/views/crm/customer/pool/index.vue
+1
-1
src/views/crm/followup/FollowUpRecordForm.vue
+3
-1
src/views/crm/followup/index.vue
+5
-3
src/views/crm/permission/components/TransferForm.vue
+2
-0
src/views/crm/product/ProductForm.vue
+1
-1
src/views/crm/product/detail/ProductDetailsHeader.vue
+1
-1
src/views/crm/product/detail/ProductDetailsInfo.vue
+5
-5
src/views/crm/product/index.vue
+1
-1
No files found.
src/api/crm/business/index.ts
View file @
9fa769b1
...
...
@@ -61,7 +61,7 @@ export const exportBusiness = async (params) => {
return
await
request
.
download
({
url
:
`/crm/business/export-excel`
,
params
})
}
//联系人关联商机列表
//
联系人关联商机列表
export
const
getBusinessPageByContact
=
async
(
params
)
=>
{
return
await
request
.
get
({
url
:
`/crm/business/page-by-contact`
,
params
})
}
...
...
src/api/crm/followup/index.ts
View file @
9fa769b1
...
...
@@ -2,22 +2,14 @@ import request from '@/config/axios'
// 跟进记录 VO
export
interface
FollowUpRecordVO
{
// 编号
id
:
number
// 数据类型
bizType
:
number
// 数据编号
bizId
:
number
// 跟进类型
type
:
number
// 跟进内容
content
:
string
// 下次联系时间
nextTime
:
Date
// 关联的商机编号数组
businessIds
:
number
[]
// 关联的联系人编号数组
contactIds
:
number
[]
id
:
number
// 编号
bizType
:
number
// 数据类型
bizId
:
number
// 数据编号
type
:
number
// 跟进类型
content
:
string
// 跟进内容
nextTime
:
Date
// 下次联系时间
businessIds
:
number
[]
// 关联的商机编号数组
contactIds
:
number
[]
// 关联的联系人编号数组
}
// 跟进记录 API
...
...
src/components/OperateLogV2/src/OperateLogV2.vue
View file @
9fa769b1
<!-- 某个记录的操作日志列表,目前主要用于 CRM 客户、商机等详情界面 -->
<
template
>
<!-- TODO @puhui999:左边不用有空隙哈 -->
<div
class=
"pt-20px"
>
<el-timeline>
<el-timeline-item
...
...
src/router/modules/remaining.ts
View file @
9fa769b1
...
...
@@ -503,7 +503,7 @@ const remainingRouter: AppRouteRecordRaw[] = [
title
:
'客户详情'
,
noCache
:
true
,
hidden
:
true
,
activeMenu
:
'/crm/customer
/index
'
activeMenu
:
'/crm/customer'
},
component
:
()
=>
import
(
'@/views/crm/customer/detail/index.vue'
)
},
...
...
src/utils/dict.ts
View file @
9fa769b1
/**
* 数据字典工具类
*/
import
{
useDictStoreWithOut
}
from
'@/store/modules/dict'
import
{
ElementPlusInfoType
}
from
'@/types/elementPlus'
import
{
useDictStoreWithOut
}
from
'@/store/modules/dict'
import
{
ElementPlusInfoType
}
from
'@/types/elementPlus'
const
dictStore
=
useDictStoreWithOut
()
...
...
@@ -162,9 +162,7 @@ export enum DICT_TYPE {
MEMBER_EXPERIENCE_BIZ_TYPE
=
'member_experience_biz_type'
,
// 会员经验业务类型
// ========== MALL - 商品模块 ==========
PRODUCT_UNIT
=
'product_unit'
,
// 商品单位
PRODUCT_SPU_STATUS
=
'product_spu_status'
,
//商品状态
PROMOTION_TYPE_ENUM
=
'promotion_type_enum'
,
// 营销类型枚举
// ========== MALL - 交易模块 ==========
EXPRESS_CHARGE_MODE
=
'trade_delivery_express_charge_mode'
,
//快递的计费方式
...
...
src/views/crm/customer/detail/index.vue
View file @
9fa769b1
...
...
@@ -36,15 +36,12 @@
</CustomerDetailsHeader>
<el-col>
<el-tabs>
<el-tab-pane
label=
"详细资料"
>
<CustomerDetailsInfo
:customer=
"customer"
/>
</el-tab-pane>
<el-tab-pane
label=
"操作日志"
>
<OperateLogV2
:log-list=
"logList"
/>
</el-tab-pane>
<el-tab-pane
label=
"跟进"
>
<el-tab-pane
label=
"跟进记录"
>
<FollowUpList
:biz-id=
"customerId"
:biz-type=
"BizTypeEnum.CRM_CUSTOMER"
/>
</el-tab-pane>
<el-tab-pane
label=
"基本信息"
>
<CustomerDetailsInfo
:customer=
"customer"
/>
</el-tab-pane>
<el-tab-pane
label=
"联系人"
lazy
>
<ContactList
:biz-id=
"customer.id!"
:biz-type=
"BizTypeEnum.CRM_CUSTOMER"
/>
</el-tab-pane>
...
...
@@ -66,6 +63,9 @@
<ReceivablePlanList
:biz-id=
"customer.id!"
:biz-type=
"BizTypeEnum.CRM_CUSTOMER"
/>
<ReceivableList
:biz-id=
"customer.id!"
:biz-type=
"BizTypeEnum.CRM_CUSTOMER"
/>
</el-tab-pane>
<el-tab-pane
label=
"操作日志"
>
<OperateLogV2
:log-list=
"logList"
/>
</el-tab-pane>
<el-tab-pane
label=
"回访"
lazy
>
TODO 待开发
</el-tab-pane>
</el-tabs>
</el-col>
...
...
src/views/crm/customer/index.vue
View file @
9fa769b1
...
...
@@ -146,7 +146,7 @@
</
template
>
</el-table-column>
<el-table-column
align=
"center"
label=
"距离进入公海"
prop=
"poolDay"
>
<
template
#
default=
"scope"
>
{{
scope
.
row
.
poolDay
}}
天
</
template
>
<
template
#
default=
"scope"
>
{{
scope
.
row
.
poolDay
}}
天
</
template
>
</el-table-column>
<el-table-column
:formatter=
"dateFormatter"
...
...
src/views/crm/customer/pool/index.vue
View file @
9fa769b1
...
...
@@ -187,7 +187,7 @@ import { dateFormatter } from '@/utils/formatTime'
import
download
from
'@/utils/download'
import
*
as
CustomerApi
from
'@/api/crm/customer'
defineOptions
({
name
:
'CrmCustomer'
})
defineOptions
({
name
:
'CrmCustomer
Pool
'
})
const
message
=
useMessage
()
// 消息弹窗
...
...
src/views/crm/followup/FollowUpRecordForm.vue
View file @
9fa769b1
<!-- 跟进记录的添加表单弹窗 -->
<
template
>
<Dialog
v-model=
"dialogVisible"
:title=
"dialogTitle"
width=
"50%"
>
<el-form
...
...
@@ -30,11 +31,13 @@
/>
</el-form-item>
</el-col>
<!-- TODO @puhui999:不搞富文本哈;然后加个附件、图片两个 form-item 哈 -->
<el-col
:span=
"24"
>
<el-form-item
label=
"跟进内容"
prop=
"content"
>
<Editor
v-model=
"formData.content"
height=
"300px"
/>
</el-form-item>
</el-col>
<!-- TODO @puhui999:因为不考虑编辑的情况,是不是关联要是个弹窗选择哈? -->
<el-col
:span=
"24"
>
<el-form-item
label=
"关联联系人"
prop=
"contactIds"
>
<el-select
v-model=
"formData.contactIds"
multiple
placeholder=
"请选择"
>
...
...
@@ -90,7 +93,6 @@ import { BusinessList, ContactList } from './components'
import
*
as
ContactApi
from
'@/api/crm/contact'
import
*
as
BusinessApi
from
'@/api/crm/business'
/** 跟进记录 表单 */
defineOptions
({
name
:
'FollowUpRecordForm'
})
const
{
t
}
=
useI18n
()
// 国际化
...
...
src/views/crm/followup/index.vue
View file @
9fa769b1
<!-- 某个记录的跟进记录列表,目前主要用于 CRM 客户、商机等详情界面 -->
<
template
>
<!-- 操作栏 -->
<el-row
class=
"mb-10px"
justify=
"end"
>
...
...
@@ -24,7 +25,9 @@
prop=
"nextTime"
width=
"180px"
/>
<!-- TODO @puhui999:点击后,查看关联联系人 -->
<el-table-column
align=
"center"
label=
"关联联系人"
prop=
"contactIds"
/>
<!-- TODO @puhui999:点击后,查看关联商机 -->
<el-table-column
align=
"center"
label=
"关联商机"
prop=
"businessIds"
/>
<el-table-column
:formatter=
"dateFormatter"
...
...
@@ -73,7 +76,7 @@ import { DICT_TYPE } from '@/utils/dict'
import
{
FollowUpRecordApi
,
FollowUpRecordVO
}
from
'@/api/crm/followup'
import
FollowUpRecordForm
from
'./FollowUpRecordForm.vue'
/** 跟进记录
列表 */
/** 跟进记录列表 */
defineOptions
({
name
:
'FollowUpRecord'
})
const
props
=
defineProps
<
{
bizType
:
number
...
...
@@ -84,8 +87,7 @@ const { t } = useI18n() // 国际化
const
loading
=
ref
(
true
)
// 列表的加载中
const
list
=
ref
<
FollowUpRecordVO
[]
>
([])
// 列表的数据
// 列表的总页数
const
total
=
ref
(
0
)
const
total
=
ref
(
0
)
// 列表的总页数
const
queryParams
=
reactive
({
pageNo
:
1
,
pageSize
:
10
,
...
...
src/views/crm/permission/components/TransferForm.vue
View file @
9fa769b1
<!-- 转移数据的表单弹窗,目前主要用于 CRM 客户、商机等详情界面 -->
<
template
>
<Dialog
v-model=
"dialogVisible"
:title=
"dialogTitle"
width=
"30%"
>
<el-form
...
...
@@ -39,6 +40,7 @@
</el-radio-group>
</el-form-item>
</el-form>
<!-- TODO 转移客户时,需要额外有【联系人】【商机】【合同】的 checkbox 选择 -->
<
template
#
footer
>
<el-button
:disabled=
"formLoading"
type=
"primary"
@
click=
"submitForm"
>
确 定
</el-button>
<el-button
@
click=
"dialogVisible = false"
>
取 消
</el-button>
...
...
src/views/crm/product/ProductForm.vue
View file @
9fa769b1
...
...
@@ -47,7 +47,7 @@
<el-form-item
label=
"产品单位"
prop=
"unit"
>
<el-select
v-model=
"formData.unit"
class=
"w-1/1"
placeholder=
"请选择单位"
>
<el-option
v-for=
"dict in getIntDictOptions(DICT_TYPE.PRODUCT_UNIT)"
v-for=
"dict in getIntDictOptions(DICT_TYPE.
CRM_
PRODUCT_UNIT)"
:key=
"dict.value"
:label=
"dict.label"
:value=
"dict.value"
...
...
src/views/crm/product/detail/ProductDetailsHeader.vue
View file @
9fa769b1
...
...
@@ -22,7 +22,7 @@
{{
productCategoryList
?.
find
((
c
)
=>
c
.
id
===
product
.
categoryId
)?.
name
}}
</el-descriptions-item>
<el-descriptions-item
label=
"产品单位"
>
<dict-tag
:type=
"DICT_TYPE.PRODUCT_UNIT"
:value=
"product.unit"
/>
<dict-tag
:type=
"DICT_TYPE.
CRM_
PRODUCT_UNIT"
:value=
"product.unit"
/>
</el-descriptions-item>
<el-descriptions-item
label=
"产品价格"
>
{{
fenToYuan
(
product
.
price
)
}}
元
</el-descriptions-item>
<el-descriptions-item
label=
"产品编码"
>
{{
product
.
no
}}
</el-descriptions-item>
...
...
src/views/crm/product/detail/ProductDetailsInfo.vue
View file @
9fa769b1
...
...
@@ -14,10 +14,10 @@
{{ productCategoryList?.find((c) => c.id === product.categoryId)?.name }}
</el-descriptions-item>
<el-descriptions-item
label=
"是否上下架"
>
<dict-tag
:type=
"DICT_TYPE.CRM_PRODUCT_STATUS"
:value=
"product.status"
/>
<dict-tag
:type=
"DICT_TYPE.CRM_PRODUCT_STATUS"
:value=
"product.status"
/>
</el-descriptions-item>
<el-descriptions-item
label=
"单位"
>
<dict-tag
:type=
"DICT_TYPE.
PRODUCT_UNIT"
:value=
"product.unit"
/>
<dict-tag
:type=
"DICT_TYPE.
CRM_PRODUCT_UNIT"
:value=
"product.unit"
/>
</el-descriptions-item>
</el-descriptions>
</el-collapse-item>
...
...
@@ -25,12 +25,12 @@
</ContentWrap>
</template>
<
script
setup
lang=
"ts"
>
import
{
DICT_TYPE
}
from
'@/utils/dict'
import
{
DICT_TYPE
}
from
'@/utils/dict'
import
*
as
ProductApi
from
'@/api/crm/product'
import
{
fenToYuan
}
from
'@/utils'
import
{
fenToYuan
}
from
'@/utils'
import
*
as
ProductCategoryApi
from
'@/api/crm/product/productCategory'
const
{
product
}
=
defineProps
<
{
const
{
product
}
=
defineProps
<
{
product
:
ProductApi
.
ProductVO
}
>
()
...
...
src/views/crm/product/index.vue
View file @
9fa769b1
...
...
@@ -60,7 +60,7 @@
<el-table-column
label=
"产品类型"
align=
"center"
prop=
"categoryName"
width=
"160"
/>
<el-table-column
label=
"产品单位"
align=
"center"
prop=
"unit"
>
<
template
#
default=
"scope"
>
<dict-tag
:type=
"DICT_TYPE.PRODUCT_UNIT"
:value=
"scope.row.unit"
/>
<dict-tag
:type=
"DICT_TYPE.
CRM_
PRODUCT_UNIT"
:value=
"scope.row.unit"
/>
</
template
>
</el-table-column>
<el-table-column
label=
"产品编码"
align=
"center"
prop=
"no"
/>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment