ソースを参照

redisign support and course or self relation

huodongdong 7 年 前
コミット
2352404bd1
3 ファイル変更16 行追加3 行削除
  1. 0 1
      db/lj_course_support_relation.md
  2. 2 2
      db/lj_item.md
  3. 14 0
      db/lj_support_circle_relation.md

+ 0 - 1
db/lj_course_support_relation.md

@@ -8,7 +8,6 @@
 | cid | varchar(512) | no | | 课程编码 | |
 | sid | varchar(512) | no | | 周边编码 | |
 | merchant_id | bigint | no | | 渠道id | |
-| status | smallint | no | | 状态 | |
 | create_time | smallint | no | now | 创建时间 | | |
 
 ##### index

+ 2 - 2
db/lj_item.md

@@ -5,9 +5,9 @@
 | field | type | null | default | desc | extra |
 |----|:-----|:-------|:------|:-----|:-----|
 | id | bigint | no | | 主键 | pri |
-| cid | varchar(512) | no | | 课程编码 | |
+| oid | varchar(512) | no | | 课程编码 | |
+| type | smallint | no | | 商品类型, 课程/周边 | |
 | merchant_id | bigint | no | | 渠道id | |
-| is_unit | smallint | no | 0 | 是否分单元 | |
 | cost_price | double(16,2) | no | 0 | 成本价 | |
 | sale_price | double(16,2) | no | 0 | 渠道价格 | |
 | market_price | double(16,2) | no | 0 | 终端价格 | |

+ 14 - 0
db/lj_support_circle_relation.md

@@ -0,0 +1,14 @@
+### lj_support_circle_relation table structure
+> 此表为周边与周边关系的数据结构
+
+
+| field | type | null | default | desc | extra |
+|----|:-----|:-------|:------|:-----|:-----|
+| id | bigint | no | | 主键 | pri |
+| fid | varchar(512) | no | | 课程编码 | |
+| tid | varchar(512) | no | | 课程编码 | |
+| merchant_id | bigint | no | | 渠道id | |
+| create_time | smallint | no | now | 创建时间 | | |
+
+##### index
+> unique index on(fid, tid, merchant_id)