Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
J
jiedao-api-boot-master
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lanbaoming
jiedao-api-boot-master
Commits
655acdc5
Commit
655acdc5
authored
Sep 05, 2024
by
yanghao
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'release-fix' into release
parents
0678b7da
d9e2e600
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
50 additions
and
0 deletions
+50
-0
20240830.sql
sql/v2.1/20240830.sql
+50
-0
No files found.
sql/v2.1/20240830.sql
View file @
655acdc5
...
@@ -82,6 +82,44 @@ VALUES (1, '1', '等待消息', 'Waiting for message', 'customer_followup_result
...
@@ -82,6 +82,44 @@ VALUES (1, '1', '等待消息', 'Waiting for message', 'customer_followup_result
-- ----------------------------
-- Table structure for ecw_customer_followup
-- ----------------------------
DROP
TABLE
IF
EXISTS
`ecw_customer_followup`
;
CREATE
TABLE
`ecw_customer_followup`
(
`id`
bigint
NOT
NULL
AUTO_INCREMENT
COMMENT
'主键'
,
`number`
varchar
(
64
)
NULL
DEFAULT
NULL
COMMENT
'编号'
,
`parent_number`
varchar
(
64
)
NULL
DEFAULT
NULL
COMMENT
'上一级跟进单号'
,
`status`
int
NULL
DEFAULT
NULL
COMMENT
'状态 字典customer_followup_status'
,
`customer_id`
bigint
NULL
DEFAULT
NULL
COMMENT
'客户编号'
,
`offer_id`
bigint
NULL
DEFAULT
NULL
COMMENT
'报价单'
,
`follow_type`
tinyint
NULL
DEFAULT
NULL
COMMENT
'跟进类型 字典customer_followup_type'
,
`follow_time`
datetime
NULL
DEFAULT
NULL
COMMENT
'跟进时间'
,
`contact_name`
varchar
(
63
)
NULL
DEFAULT
NULL
COMMENT
'联系人'
,
`follow_method`
tinyint
NULL
DEFAULT
NULL
COMMENT
'跟进方式 字典customer_followup_method'
,
`follow_user_id`
bigint
NULL
DEFAULT
NULL
COMMENT
'客户经理/跟进业务员id'
,
`purpose`
varchar
(
512
)
NULL
DEFAULT
NULL
COMMENT
'目的'
,
`result_type`
tinyint
NULL
DEFAULT
NULL
COMMENT
'跟进结果 字典customer_followup_result_type'
,
`feedback`
varchar
(
2048
)
NULL
DEFAULT
NULL
COMMENT
'客户反馈'
,
`attatchment`
varchar
(
2048
)
NULL
DEFAULT
NULL
COMMENT
'附件 多个以逗号分隔'
,
`next_time`
datetime
NULL
DEFAULT
NULL
COMMENT
'下次跟进时间'
,
`next_plan`
varchar
(
2048
)
NULL
DEFAULT
NULL
COMMENT
'下次跟进计划'
,
`creator`
varchar
(
63
)
NOT
NULL
DEFAULT
''
COMMENT
'创建者'
,
`create_time`
datetime
NOT
NULL
DEFAULT
CURRENT_TIMESTAMP
COMMENT
'创建时间'
,
`updater`
varchar
(
63
)
NULL
DEFAULT
''
COMMENT
'更新者'
,
`update_time`
datetime
NOT
NULL
DEFAULT
CURRENT_TIMESTAMP
ON
UPDATE
CURRENT_TIMESTAMP
COMMENT
'更新时间'
,
`deleted`
bit
(
1
)
NOT
NULL
DEFAULT
b
'0'
COMMENT
'是否删除'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
AUTO_INCREMENT
=
1
COMMENT
=
'客户跟进表'
;
-- 下面为刷新数据的sql
-- 更新客户角色
-- 更新客户角色
update
ecw_customer
set
roles
=
'2'
where
FIND_IN_SET
(
2
,
type
)
!=
0
;
update
ecw_customer
set
roles
=
'2'
where
FIND_IN_SET
(
2
,
type
)
!=
0
;
update
ecw_customer
set
roles
=
'3'
where
FIND_IN_SET
(
3
,
type
)
!=
0
;
update
ecw_customer
set
roles
=
'3'
where
FIND_IN_SET
(
3
,
type
)
!=
0
;
...
@@ -96,3 +134,15 @@ update ecw_customer a
...
@@ -96,3 +134,15 @@ update ecw_customer a
set
a
.
customer_service_confirmed_time
=
b
.
maxtime
set
a
.
customer_service_confirmed_time
=
b
.
maxtime
where
a
.
deleted
=
0
;
where
a
.
deleted
=
0
;
-- 刷新客户跟进数据
insert
into
ecw_customer_followup
(
id
,
number
,
parent_number
,
`status`
,
customer_id
,
offer_id
,
follow_type
,
follow_time
,
contact_name
,
follow_method
,
follow_user_id
,
purpose
,
result_type
,
feedback
,
attatchment
,
next_time
,
next_plan
,
creator
,
create_time
,
updater
,
update_time
,
deleted
)
select
null
,
null
,
null
,
1
,
customer_id
,
null
,
1
,
follow_time
,
contact_name
,
follow_method
,
follow_user_id
,
null
,
1
,
CONCAT
(
'【客户反馈:】
\r\n
'
,
feedback
,
'
\r\n\r\n
【处理结果:】
\r\n
'
,
result
),
null
,
null
,
null
,
creator
,
create_time
,
updater
,
update_time
,
deleted
from
ecw_customer_follow
;
-- 更新客户跟进编号
update
ecw_customer_followup
set
number
=
CONCAT
(
'GJ'
,
2024000000
+
id
);
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