Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit b4be6281
authored
Dec 30, 2020
by
水库浪子
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
更新数据库脚本
1 parent
4f8b0d94
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
80 additions
and
16 deletions
sql/link-wechat.sql
sql/link-wechat.sql
View file @
b4be628
...
...
@@ -10,7 +10,7 @@ Target Server Type : MYSQL
Target Server Version : 50718
File Encoding : 65001
Date: 2020-12-
25 14:01:49
Date: 2020-12-
30 10:16:02
*/
SET
FOREIGN_KEY_CHECKS
=
0
;
...
...
@@ -5678,6 +5678,24 @@ CREATE TABLE `we_category` (
-- ----------------------------
-- ----------------------------
-- Table structure for we_chat_contact_mapping
-- ----------------------------
DROP
TABLE
IF
EXISTS
`we_chat_contact_mapping`
;
CREATE
TABLE
`we_chat_contact_mapping`
(
`id`
bigint
(
20
)
NOT
NULL
AUTO_INCREMENT
COMMENT
'主键id'
,
`from_id`
varchar
(
32
)
NOT
NULL
COMMENT
'发送人id'
,
`receive_id`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'接收人id'
,
`room_id`
varchar
(
32
)
DEFAULT
NULL
COMMENT
'群聊id'
,
`is_custom`
tinyint
(
4
)
DEFAULT
NULL
COMMENT
'接收人是否为客户 0-成员 1-客户 2-机器人'
,
PRIMARY
KEY
(
`id`
),
KEY
`we_chat_contact_mapping_from_id_IDX`
(
`from_id`
,
`is_custom`
)
USING
BTREE
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
ROW_FORMAT
=
DYNAMIC
;
-- ----------------------------
-- Records of we_chat_contact_mapping
-- ----------------------------
-- ----------------------------
-- Table structure for we_config
-- ----------------------------
DROP
TABLE
IF
EXISTS
`we_config`
;
...
...
@@ -5705,6 +5723,7 @@ CREATE TABLE `we_corp_account` (
`contact_secret`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'外部联系人密钥'
,
`wx_qr_login_redirect_uri`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'企业微信扫码登陆系统回调地址'
,
`provider_secret`
varchar
(
64
)
DEFAULT
NULL
,
`chat_secret`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'会话存档密钥'
,
`agent_id`
varchar
(
64
)
DEFAULT
NULL
COMMENT
'应用id'
,
`status`
char
(
1
)
DEFAULT
'1'
COMMENT
'帐号状态(0正常 1停用)'
,
`del_flag`
char
(
1
)
DEFAULT
'0'
COMMENT
'删除标志(0代表存在 2代表删除)'
,
...
...
@@ -5798,6 +5817,8 @@ CREATE TABLE `we_customer_message` (
`sender`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'发送企业群发消息的成员userid,当类型为发送给客户群时必填(和企微客户沟通后确认是群主id)'
,
`check_status`
varchar
(
2
)
DEFAULT
NULL
COMMENT
'消息发送状态 0 未发送 1 已发送'
,
`msgid`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'企业群发消息的id,可用于<a href="https://work.weixin.qq.com/api/doc/90000/90135/92136">获取群发消息发送结果</a>'
,
`content`
text
COMMENT
'消息内容'
,
`send_info`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'发送情况 ps:显示样式 1)定时任务 发送时间:2020-12-25 10:00:00 2) 预计发送3190人,已成功发送0人 3)预计发送2个群,已成功发送0个群 '
,
`create_by`
varchar
(
64
)
DEFAULT
NULL
,
`create_time`
datetime
DEFAULT
NULL
,
`update_by`
varchar
(
64
)
DEFAULT
NULL
,
...
...
@@ -5847,11 +5868,16 @@ CREATE TABLE `we_customer_messgaeResult` (
`userid`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'企业服务人员的userid'
,
`status`
varchar
(
2
)
DEFAULT
NULL
COMMENT
'发送状态 0-未发送 1-已发送 2-因客户不是好友导致发送失败 3-因客户已经收到其他群发消息导致发送失败'
,
`send_time`
varchar
(
40
)
DEFAULT
NULL
,
`external_name`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'外部联系人名称'
,
`user_name`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'企业服务人员的名称'
,
`send_type`
varchar
(
1
)
DEFAULT
NULL
COMMENT
'0 发给客户 1 发给客户群 2 定时发送'
,
`setting_time`
varchar
(
40
)
DEFAULT
NULL
COMMENT
'定时发送时间'
,
`create_by`
varchar
(
64
)
DEFAULT
NULL
,
`create_time`
datetime
DEFAULT
NULL
,
`update_by`
varchar
(
64
)
DEFAULT
NULL
,
`update_time`
datetime
DEFAULT
NULL
,
`del_flag`
int
(
2
)
DEFAULT
'0'
,
`chat_name`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'外部客户群名称'
,
PRIMARY
KEY
(
`messgae_result_id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
COMMENT
=
'群发消息 微信消息发送结果'
;
...
...
@@ -5883,6 +5909,37 @@ CREATE TABLE `we_customer_miniprogramMessage` (
-- ----------------------------
-- ----------------------------
-- Table structure for we_customer_seedMessage
-- ----------------------------
DROP
TABLE
IF
EXISTS
`we_customer_seedMessage`
;
CREATE
TABLE
`we_customer_seedMessage`
(
`image_message_id`
bigint
(
64
)
DEFAULT
NULL
,
`message_id`
bigint
(
64
)
DEFAULT
NULL
COMMENT
'微信消息表id'
,
`content`
text
COMMENT
'消息文本内容,最多4000个字节'
,
`media_id`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'图片消息:图片的media_id,可以通过 <a href="https://work.weixin.qq.com/api/doc/90000/90135/90253">素材管理接口</a>获得'
,
`pic_url`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'图片消息:图片的链接,仅可使用<a href="https://work.weixin.qq.com/api/doc/90000/90135/90256">上传图片接口</a>得到的链接'
,
`link_title`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'链接消息:图文消息标题'
,
`link_picurl`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'链接消息:图文消息封面的url'
,
`lin_desc`
varchar
(
1000
)
DEFAULT
NULL
COMMENT
'链接消息:图文消息的描述,最多512个字节'
,
`link_url`
varchar
(
1000
)
DEFAULT
NULL
COMMENT
'链接消息:图文消息的链接'
,
`miniprogram_title`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'小程序消息标题,最多64个字节'
,
`miniprogram_media_id`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'小程序消息封面的mediaid,封面图建议尺寸为520*416'
,
`appid`
varchar
(
100
)
DEFAULT
NULL
COMMENT
'小程序appid,必须是关联到企业的小程序应用'
,
`page`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'小程序page路径'
,
`create_by`
varchar
(
64
)
DEFAULT
NULL
,
`create_time`
datetime
DEFAULT
NULL
,
`update_by`
varchar
(
255
)
DEFAULT
NULL
,
`update_time`
datetime
DEFAULT
NULL
,
`del_flag`
int
(
1
)
DEFAULT
'0'
,
`seed_message_id`
bigint
(
20
)
NOT
NULL
,
PRIMARY
KEY
(
`seed_message_id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
ROW_FORMAT
=
DYNAMIC
;
-- ----------------------------
-- Records of we_customer_seedMessage
-- ----------------------------
-- ----------------------------
-- Table structure for we_customer_textMessage
-- ----------------------------
DROP
TABLE
IF
EXISTS
`we_customer_textMessage`
;
...
...
@@ -6190,17 +6247,19 @@ CREATE TABLE `we_msg_tlp_scope` (
DROP
TABLE
IF
EXISTS
`we_poster`
;
CREATE
TABLE
`we_poster`
(
`id`
bigint
(
20
)
NOT
NULL
,
`del_flag`
tinyint
(
255
)
DEFAULT
NULL
,
`del_flag`
tinyint
(
255
)
DEFAULT
NULL
COMMENT
'0 正常 1 删除'
,
`create_by`
varchar
(
50
)
DEFAULT
NULL
,
`create_time`
timestamp
NULL
DEFAULT
NULL
,
`update_by`
varchar
(
50
)
DEFAULT
NULL
,
`update_time`
timestamp
NULL
DEFAULT
NULL
,
`title`
varchar
(
30
)
DEFAULT
NULL
,
`background_img_path`
varchar
(
255
)
DEFAULT
NULL
,
`sample_img_path`
varchar
(
255
)
DEFAULT
NULL
,
`type`
bigint
(
255
)
DEFAULT
NULL
,
`width`
int
(
255
)
DEFAULT
NULL
,
`height`
int
(
11
)
DEFAULT
NULL
,
`title`
varchar
(
30
)
DEFAULT
NULL
COMMENT
'图片标题'
,
`background_img_path`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'背景图层图片地址'
,
`sample_img_path`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'示例图'
,
`type`
bigint
(
255
)
DEFAULT
NULL
COMMENT
'类型 1 通用海报'
,
`width`
int
(
255
)
DEFAULT
NULL
COMMENT
'背景图片宽'
,
`height`
int
(
11
)
DEFAULT
NULL
COMMENT
'背景图片高'
,
`media_type`
varchar
(
255
)
DEFAULT
NULL
,
`category_id`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'分类id'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
;
...
...
@@ -6222,6 +6281,8 @@ CREATE TABLE `we_poster_font` (
`create_time`
timestamp
NULL
DEFAULT
NULL
,
`update_by`
varchar
(
50
)
DEFAULT
NULL
,
`update_time`
timestamp
NULL
DEFAULT
NULL
,
`media_type`
int
(
11
)
DEFAULT
NULL
,
`category_id`
bigint
(
20
)
DEFAULT
NULL
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
;
...
...
@@ -6243,15 +6304,18 @@ CREATE TABLE `we_poster_subassembly` (
`poster_id`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'海报id'
,
`left`
int
(
255
)
DEFAULT
NULL
,
`top`
int
(
255
)
DEFAULT
NULL
,
`width`
int
(
11
)
DEFAULT
NULL
,
`height`
int
(
11
)
DEFAULT
NULL
,
`type`
int
(
255
)
DEFAULT
NULL
,
`font_size`
int
(
11
)
DEFAULT
NULL
,
`font_color`
varchar
(
10
)
DEFAULT
NULL
,
`img_path`
varchar
(
255
)
DEFAULT
NULL
,
`font_id`
bigint
(
20
)
DEFAULT
NULL
,
`font_text_align`
int
(
255
)
DEFAULT
NULL
,
`width`
int
(
11
)
DEFAULT
NULL
COMMENT
'宽'
,
`height`
int
(
11
)
DEFAULT
NULL
COMMENT
'高'
,
`type`
int
(
255
)
DEFAULT
NULL
COMMENT
'1 文本 2 图片 3 二维码'
,
`font_size`
int
(
11
)
DEFAULT
NULL
COMMENT
'字体大小'
,
`font_color`
varchar
(
10
)
DEFAULT
NULL
COMMENT
'字体颜色'
,
`img_path`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'图片地址'
,
`font_id`
bigint
(
20
)
DEFAULT
NULL
COMMENT
'字体id'
,
`font_text_align`
int
(
255
)
DEFAULT
NULL
COMMENT
'水平对齐'
,
`content`
varchar
(
255
)
DEFAULT
NULL
COMMENT
'内容'
,
`vertical_type`
tinyint
(
255
)
DEFAULT
NULL
COMMENT
'垂直对齐方式'
,
`word_space`
int
(
255
)
DEFAULT
NULL
COMMENT
'字间距'
,
`line_space`
int
(
255
)
DEFAULT
NULL
COMMENT
'行间距'
,
PRIMARY
KEY
(
`id`
)
)
ENGINE
=
InnoDB
DEFAULT
CHARSET
=
utf8mb4
;
Write
Preview
Markdown
is supported
Attach a file
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 post a comment