merge_data/收银机数据迁移关系.md

67 lines
1.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 收银机数据迁移关系
## 1 系统用户、商户、员工
### 1.1 系统用户
1. 系统用户全部迁移到新数据库
2. 密码默认为 czg123456
### 1.2 商户
1. 迁移所有商户数据
2. 根据 account -> 对应 sys_user username 将shop_info id设置为 sys_user id
#### 1.2.1 保存新的 shop_id 和 原来shop_id 对应关系
> 表名shop_id_relation
## 接口执行顺序
### 1. 迁移系统用户
> /merge/user/mergeShopInfo
#### 执行表
- sys_user 表
- tb_shop_info 表
- tb_shop_staff 表
- staff_id_relation 表
### 2. 用户
> /merge/user/mergeShopUser
#### 执行表
- tb_user_info 表
- tb_shop_user 表
### 3. 用户余额流水 支付记录
> /merge/user/userFlow
#### 执行表
- tb_shop_user_flow 表
- tb_order_payment 表
### 4. 用户积分流水
> /merge/points/mergePoints
#### 执行表
- tb_points_basic_setting 表
- tb_points_exchange_record 表
- tb_points_goods_setting 表
- tb_member_points_log 表
### 5. 活动
> /merge/activate/mergeActivate
>
> 线上暂时没用使用优惠券,清空记录不迁移
#### 执行表
- tb_shop_activate 表
- tb_shop_activate_coupon_record 表
- tb_shop_coupon 表
### 6. 团购优惠券
> /merge/activate/group
#### 执行表
- tb_coupon_category 表
- tb_group_order_coupon 表