commit | author | age
|
2207d6
|
1 |
<?php |
W |
2 |
|
|
3 |
return [ |
|
4 |
'4.0.0' => function () { |
|
5 |
$installSql = file_get_contents(__DIR__ . '/forms/install/install.sql'); |
|
6 |
sql_execute($installSql, true, false); |
|
7 |
}, |
|
8 |
|
|
9 |
'4.0.1' => function () { |
|
10 |
}, |
|
11 |
|
|
12 |
'4.0.2' => function () { |
|
13 |
}, |
|
14 |
|
|
15 |
'4.0.3' => function () { |
|
16 |
}, |
|
17 |
|
|
18 |
'4.0.4' => function () { |
|
19 |
$sql = <<<EOF |
|
20 |
ALTER TABLE `zjhj_bd_delivery` ADD COLUMN `is_goods` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否商品信息' AFTER `deleted_at`; |
|
21 |
ALTER TABLE `zjhj_bd_mch` ALTER column `user_id` SET DEFAULT '0'; |
|
22 |
ALTER TABLE `zjhj_bd_lottery` ADD COLUMN `buy_goods_id` int(11) NOT NULL COMMENT '购买商品id' AFTER `code_num`; |
|
23 |
ALTER TABLE `zjhj_bd_bargain_banner` ADD COLUMN `deleted_at` timestamp NOT NULL AFTER `created_at`; |
|
24 |
EOF; |
|
25 |
sql_execute($sql); |
|
26 |
}, |
|
27 |
|
|
28 |
'4.0.5' => function () { |
|
29 |
}, |
|
30 |
|
|
31 |
'4.0.7' => function () { |
|
32 |
}, |
|
33 |
|
|
34 |
'4.0.8' => function () { |
|
35 |
$sql = <<<EOF |
|
36 |
ALTER TABLE `zjhj_bd_banner` |
|
37 |
ADD COLUMN `open_type` varchar(65) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '打开方式' AFTER `page_url`, |
|
38 |
ADD COLUMN `params` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '导航参数' AFTER `open_type`; |
|
39 |
alter table `zjhj_bd_core_action_log` modify column `before_update` LONGTEXT; |
|
40 |
alter table `zjhj_bd_core_action_log` modify column `after_update` LONGTEXT; |
|
41 |
|
|
42 |
ALTER TABLE `zjhj_bd_user` ADD INDEX `mall_id`(`mall_id`); |
|
43 |
ALTER TABLE `zjhj_bd_user_info` ADD INDEX `user_id`(`user_id`); |
|
44 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `name`(`name`); |
|
45 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `mall_id`(`mall_id`); |
|
46 |
ALTER TABLE `zjhj_bd_order_detail` ADD INDEX `order_id`(`order_id`); |
|
47 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `mall_id`(`mall_id`); |
|
48 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `user_id`(`user_id`); |
|
49 |
ALTER TABLE `zjhj_bd_user_card` ADD INDEX `mall_id`(`mall_id`); |
|
50 |
ALTER TABLE `zjhj_bd_user_card` ADD INDEX `user_id`(`user_id`); |
|
51 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `mall_id`(`mall_id`); |
|
52 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `goods_warehouse_id`(`goods_warehouse_id`); |
|
53 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `sign`(`sign`); |
|
54 |
ALTER TABLE `zjhj_bd_goods_member_price` ADD INDEX `goods_attr_id`(`goods_attr_id`); |
|
55 |
ALTER TABLE `zjhj_bd_goods_share` ADD INDEX `goods_attr_id`(`goods_attr_id`); |
|
56 |
ALTER TABLE `zjhj_bd_goods_attr` ADD INDEX `goods_id`(`goods_id`); |
|
57 |
ALTER TABLE `zjhj_bd_goods_share` ADD INDEX `goods_id`(`goods_id`); |
|
58 |
ALTER TABLE `zjhj_bd_goods_cat_relation` ADD INDEX `goods_warehouse_id`(`goods_warehouse_id`); |
|
59 |
EOF; |
|
60 |
sql_execute($sql); |
|
61 |
}, |
|
62 |
|
|
63 |
'4.0.9' => function () { |
|
64 |
$sql = <<<EOF |
|
65 |
ALTER TABLE `zjhj_bd_admin_info` ADD COLUMN `is_default` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否使用默认权限'; |
|
66 |
alter table `zjhj_bd_core_action_log` add `remark` varchar(255) not null default ''; |
|
67 |
EOF; |
|
68 |
sql_execute($sql); |
|
69 |
}, |
|
70 |
|
|
71 |
'4.0.10' => function () { |
|
72 |
}, |
|
73 |
|
|
74 |
'4.0.11' => function () { |
|
75 |
}, |
|
76 |
|
|
77 |
'4.0.12' => function () { |
|
78 |
$sql = <<<EOF |
|
79 |
alter table `zjhj_bd_mall_members` add `bg_pic_url` varchar(255) not null; |
|
80 |
EOF; |
|
81 |
sql_execute($sql); |
|
82 |
}, |
|
83 |
'4.0.13' => function () { |
|
84 |
$sql = <<<EOF |
|
85 |
alter table `zjhj_bd_pintuan_order_relation` add `robot_id` int(11) not null default 0; |
|
86 |
CREATE TABLE `zjhj_bd_pintuan_robots` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `nickname` varchar(65) NOT NULL DEFAULT '' COMMENT '机器人昵称', `avatar` varchar(255) NOT NULL DEFAULT '', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=10 DEFAULT CHARSET=utf8mb4; |
|
87 |
EOF; |
|
88 |
sql_execute($sql); |
|
89 |
}, |
|
90 |
|
|
91 |
'4.0.14' => function () { |
|
92 |
}, |
|
93 |
|
|
94 |
'4.0.15' => function () { |
|
95 |
$sql = <<<EOF |
|
96 |
CREATE TABLE `zjhj_bd_diy_form` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `form_data` longtext NOT NULL, `created_at` datetime NOT NULL, `is_delete` tinyint(1) NOT NULL, `updated_at` datetime NOT NULL, `deleted_at` datetime NOT NULL, PRIMARY KEY (`id`), KEY `user_id` (`user_id`) USING BTREE, KEY `mall_id` (`mall_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='diy表单信息'; |
|
97 |
EOF; |
|
98 |
sql_execute($sql); |
|
99 |
}, |
|
100 |
|
|
101 |
'4.0.16' => function () { |
|
102 |
$sql = <<<EOF |
|
103 |
ALTER TABLE `zjhj_bd_booking_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `payment_type`; |
|
104 |
ALTER TABLE `zjhj_bd_integral_mall_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `send_type`; |
|
105 |
ALTER TABLE `zjhj_bd_lottery_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `send_type`; |
|
106 |
ALTER TABLE `zjhj_bd_miaosha_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `send_type`; |
|
107 |
ALTER TABLE `zjhj_bd_pintuan_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `send_type`; |
|
108 |
ALTER TABLE `zjhj_bd_step_setting` ADD COLUMN `goods_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '自定义海报' AFTER `is_territorial_limitation`, ADD COLUMN `step_poster` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '步数海报' AFTER `goods_poster`; |
|
109 |
EOF; |
|
110 |
sql_execute($sql); |
|
111 |
}, |
|
112 |
|
|
113 |
'4.0.17' => function () { |
|
114 |
$sql = <<<EOF |
|
115 |
ALTER TABLE `zjhj_bd_goods_warehouse` MODIFY COLUMN `detail` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '商品详情,图文'; |
|
116 |
EOF; |
|
117 |
sql_execute($sql); |
|
118 |
}, |
|
119 |
|
|
120 |
'4.0.18' => function () { |
|
121 |
}, |
|
122 |
|
|
123 |
'4.0.19' => function () { |
|
124 |
$sql = <<<EOF |
|
125 |
ALTER TABLE `zjhj_bd_lottery_setting` ADD COLUMN `is_sms` tinyint(1) NOT NULL DEFAULT 0 COMMENT '开启短信提醒' AFTER `goods_poster`, ADD COLUMN `is_mail` tinyint(1) NOT NULL DEFAULT 0 COMMENT '开启邮件提醒' AFTER `is_sms`, ADD COLUMN `is_print` tinyint(1) NOT NULL DEFAULT 0 COMMENT '开启打印' AFTER `is_mail`; |
|
126 |
EOF; |
|
127 |
sql_execute($sql); |
|
128 |
}, |
|
129 |
|
|
130 |
'4.0.20' => function () { |
|
131 |
$sql = <<<EOF |
|
132 |
ALTER TABLE `zjhj_bd_attachment_storage` ADD COLUMN `user_id` int NOT NULL DEFAULT 1 COMMENT '存储设置所属账号'; |
|
133 |
ALTER TABLE `zjhj_bd_admin_info` ADD COLUMN `secondary_permissions` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '二级权限'; |
|
134 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_captain` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `name` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '队长姓名' , `mobile` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '队长手机' , `user_id` int(11) NOT NULL , `all_bonus` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '累计分红' , `total_bonus` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '已分红' , `expect_bonus` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '预计分红,未到账分红' , `reason` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '描述' , `status` tinyint(1) NOT NULL DEFAULT 0 COMMENT '-1重新申请未提交 0--申请中 1--成功 2--失败 3--处理中' , `all_member` int(11) NOT NULL DEFAULT 0 COMMENT '团员数量' , `created_at` timestamp NOT NULL , `updated_at` timestamp NOT NULL , `deleted_at` timestamp NOT NULL , `apply_at` timestamp NULL DEFAULT NULL , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , PRIMARY KEY (`id`), INDEX `user_id` (`user_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='团队分红队长表' AUTO_INCREMENT=1; |
|
135 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_captain_log` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `handler` int(11) NOT NULL DEFAULT 0 COMMENT '操作人' , `user_id` int(11) NOT NULL COMMENT '队长' , `event` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '事件名' , `content` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '记录信息' , `create_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' ON UPDATE CURRENT_TIMESTAMP , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='队长操作日志表' AUTO_INCREMENT=1; |
|
136 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_captain_relation` ( `id` int(11) NOT NULL AUTO_INCREMENT , `captain_id` int(11) NOT NULL COMMENT '队长id' , `user_id` int(11) NOT NULL COMMENT '团队id' , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , `created_at` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP , `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , PRIMARY KEY (`id`), INDEX `user_id` (`user_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1; |
|
137 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_cash` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `user_id` int(11) NOT NULL , `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' , `price` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '提现金额' , `service_charge` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '提现手续费(%)' , `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额' , `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '额外信息 例如微信账号、支付宝账号等' , `status` int(11) NOT NULL DEFAULT 0 COMMENT '提现状态 0--申请 1--同意 2--已打款 3--驳回' , `is_delete` int(11) NOT NULL DEFAULT 0 , `created_at` datetime NOT NULL , `updated_at` datetime NOT NULL , `deleted_at` datetime NOT NULL , `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='提现记录表' AUTO_INCREMENT=1; |
|
138 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_cash_log` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `user_id` int(11) NOT NULL , `type` int(11) NOT NULL DEFAULT 1 COMMENT '类型 1--收入 2--支出' , `price` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '变动佣金' , `desc` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL , `custom_desc` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL , `is_delete` int(11) NOT NULL DEFAULT 0 , `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' , `updated_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' , `deleted_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00' , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1; |
|
139 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_order_log` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL DEFAULT 0 , `order_id` int(11) NOT NULL DEFAULT 0 COMMENT '订单ID' , `from_user_id` int(11) NOT NULL DEFAULT 0 COMMENT '下单用户ID' , `to_user_id` int(11) NOT NULL DEFAULT 0 COMMENT '受益用户ID' , `price` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '订单商品实付金额' , `bonus_price` decimal(10,2) NOT NULL DEFAULT 0.00 COMMENT '分红金额' , `fail_bonus_price` decimal(10,2) NULL DEFAULT 0.00 COMMENT '失败分红金额' , `status` tinyint(2) NOT NULL DEFAULT 0 COMMENT '0预计分红,1完成分红,2分红失败' , `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `is_delete` tinyint(2) NOT NULL DEFAULT 0 , `remark` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注' , `bonus_rate` tinyint(4) NOT NULL DEFAULT 0 COMMENT '下单时的分红比例%' , PRIMARY KEY (`id`), UNIQUE INDEX `order_id` (`order_id`) USING BTREE , INDEX `from_user_id` (`from_user_id`) USING BTREE , INDEX `to_user_id` (`to_user_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1; |
|
140 |
CREATE TABLE IF NOT EXISTS `zjhj_bd_bonus_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `key` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL , `value` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL , `created_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间' , `updated_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间' , `is_delete` int(11) NOT NULL DEFAULT 0 COMMENT '是否删除 0--未删除 1--已删除' , `deleted_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '删除时间' , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='团队分红设置' AUTO_INCREMENT=1; |
|
141 |
EOF; |
|
142 |
sql_execute($sql); |
|
143 |
}, |
|
144 |
|
|
145 |
'4.0.21' => function () { |
|
146 |
$sql = <<<EOF |
|
147 |
alter table `zjhj_bd_mch_setting` add `is_web_service` tinyint(1) NOT NULL default 0; |
|
148 |
alter table `zjhj_bd_mch_setting` add `web_service_url` varchar(255) NOT NULL default ''; |
|
149 |
alter table `zjhj_bd_mch_setting` add `web_service_pic` varchar(255) NOT NULL default ''; |
|
150 |
EOF; |
|
151 |
sql_execute($sql); |
|
152 |
}, |
|
153 |
|
|
154 |
'4.0.22' => function () { |
|
155 |
$sql = <<<EOF |
|
156 |
ALTER TABLE `zjhj_bd_user_card` MODIFY COLUMN `start_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `data`, MODIFY COLUMN `end_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `start_time`; |
|
157 |
EOF; |
|
158 |
sql_execute($sql); |
|
159 |
}, |
|
160 |
|
|
161 |
'4.0.24' => function () { |
|
162 |
$sql = <<<EOF |
|
163 |
ALTER TABLE `zjhj_bd_order` ADD COLUMN `customer_name` VARCHAR(65) DEFAULT '' NULL COMMENT '京东商家编号' AFTER `send_time`; |
|
164 |
ALTER TABLE `zjhj_bd_order_refund` ADD COLUMN `customer_name` VARCHAR(65) DEFAULT '' NULL COMMENT '京东商家编号' AFTER `send_time`, ADD COLUMN `merchant_customer_name` VARCHAR(65) DEFAULT '' NULL COMMENT '商家京东商家编号' AFTER `confirm_time`; |
|
165 |
EOF; |
|
166 |
sql_execute($sql); |
|
167 |
}, |
|
168 |
|
|
169 |
'4.0.25' => function () { |
|
170 |
}, |
|
171 |
|
|
172 |
'4.0.26' => function () { |
|
173 |
}, |
|
174 |
|
|
175 |
'4.0.27' => function () { |
|
176 |
}, |
|
177 |
|
|
178 |
'4.0.28' => function () { |
|
179 |
}, |
|
180 |
|
|
181 |
'4.0.30' => function () { |
|
182 |
$sql = <<<EOF |
|
183 |
alter table zjhj_bd_mall_member_orders change detail detail MEDIUMTEXT; |
|
184 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(255) NOT NULL DEFAULT '' COMMENT '活动名称', `start_time` timestamp NOT NULL COMMENT '活动开始时间', `end_time` timestamp NOT NULL COMMENT '活动结束时间', `send_type` tinyint(1) NOT NULL DEFAULT '2' COMMENT '1.赠送所有规则|2.赠送满足最高规则', `rules` text COMMENT '买单规则', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否启用', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
185 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities_groups` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `name` varchar(255) NOT NULL DEFAULT '', `activity_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
186 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities_groups_level` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `group_id` int(11) NOT NULL, `level` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
187 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities_groups_rules` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `group_id` int(11) NOT NULL, `rules_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '1.赠送规则|2.优惠规则', `consume_money` decimal(10,2) NOT NULL COMMENT '单次消费金额', `send_integral_num` int(11) NOT NULL COMMENT '赠送积分', `send_integral_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '1.固定值|2.百分比', `send_money` decimal(10,2) NOT NULL COMMENT '赠送余额', `preferential_money` decimal(10,2) NOT NULL COMMENT '优惠金额', `integral_deduction` int(11) NOT NULL COMMENT '积分抵扣', `integral_deduction_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '1.固定值|2.百分比', `is_coupon` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否可使用优惠券', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
188 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities_groups_rules_cards` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `group_rule_id` int(11) NOT NULL, `card_id` int(11) NOT NULL, `send_num` int(11) NOT NULL COMMENT '赠送数量', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
189 |
CREATE TABLE `zjhj_bd_scan_code_pay_activities_groups_rules_coupons` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `group_rule_id` int(11) NOT NULL, `coupon_id` int(11) NOT NULL, `send_num` int(11) NOT NULL COMMENT '赠送数量', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
190 |
CREATE TABLE `zjhj_bd_scan_code_pay_orders` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `order_id` int(11) NOT NULL, `activity_preferential_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '活动优惠价格', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
191 |
CREATE TABLE `zjhj_bd_scan_code_pay_setting` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `is_scan_code_pay` tinyint(1) NOT NULL DEFAULT '0', `payment_type` text NOT NULL, `is_share` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否开启分销', `is_sms` tinyint(1) NOT NULL DEFAULT '0', `is_mail` tinyint(1) NOT NULL DEFAULT '0', `share_type` tinyint(4) NOT NULL DEFAULT '1' COMMENT '1.百分比|2.固定金额', `share_commission_first` decimal(10,2) NOT NULL DEFAULT '0.00', `share_commission_second` decimal(10,2) NOT NULL DEFAULT '0.00', `share_commission_third` decimal(10,2) NOT NULL DEFAULT '0.00', `poster` mediumtext NOT NULL COMMENT '自定义海报', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
192 |
|
|
193 |
ALTER TABLE `zjhj_bd_bonus_captain` ADD COLUMN `level` int(11) NOT NULL DEFAULT 0 COMMENT '会员等级:0. 普通成员 关联等级表' AFTER `remark`; |
|
194 |
CREATE TABLE `zjhj_bd_bonus_members` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `level` int(11) UNSIGNED NOT NULL COMMENT '等级' , `name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '等级名称' , `auto_update` tinyint(1) NOT NULL COMMENT '是否开启自动升级' , `update_type` int(11) NOT NULL DEFAULT 0 COMMENT '升级条件类型' , `update_condition` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '升级条件' , `rate` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '0' COMMENT '分红比例' , `status` tinyint(4) NOT NULL DEFAULT 1 COMMENT '状态 0--禁用 1--启用' , `created_at` timestamp NOT NULL , `updated_at` timestamp NOT NULL , `deleted_at` timestamp NOT NULL , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1 ROW_FORMAT=DYNAMIC ; |
|
195 |
EOF; |
|
196 |
sql_execute($sql); |
|
197 |
}, |
|
198 |
|
|
199 |
'4.0.32' => function () { |
|
200 |
}, |
|
201 |
|
|
202 |
'4.0.34' => function () { |
|
203 |
$sql = <<<EOF |
|
204 |
alter table `zjhj_bd_goods_cats` add `is_show` tinyint(1) default '1'; |
|
205 |
EOF; |
|
206 |
sql_execute($sql); |
|
207 |
}, |
|
208 |
|
|
209 |
'4.0.35' => function () { |
|
210 |
}, |
|
211 |
|
|
212 |
'4.0.36' => function () { |
|
213 |
}, |
|
214 |
|
|
215 |
'4.0.37' => function () { |
|
216 |
$sql = <<<EOF |
|
217 |
ALTER TABLE `zjhj_bd_user_info` ADD INDEX `parent_id`(`parent_id`); |
|
218 |
ALTER TABLE `zjhj_bd_booking_setting` ADD INDEX `mall_id`(`mall_id`); |
|
219 |
ALTER TABLE `zjhj_bd_share` ADD INDEX `mall_id`(`mall_id`), ADD INDEX `is_delete`(`is_delete`); |
|
220 |
|
|
221 |
ALTER TABLE `zjhj_bd_lottery_setting` |
|
222 |
ADD COLUMN `cs_status` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否开启客服提示' AFTER `is_print`, |
|
223 |
ADD COLUMN `cs_prompt_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '客服提示图片' AFTER `cs_status`, |
|
224 |
ADD COLUMN `cs_wechat` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '客服微信号' AFTER `cs_prompt_pic`, |
|
225 |
ADD COLUMN `cs_wechat_flock_qrcode_pic` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '微信群' AFTER `cs_wechat`; |
|
226 |
|
|
227 |
alter table zjhj_bd_printer_setting add store_id int(11) default '0' not null; |
|
228 |
alter table zjhj_bd_pintuan_goods_groups add group_num int(11) default '0' not null; |
|
229 |
alter table zjhj_bd_mall add expired_at TIMESTAMP default '0000-00-00 00:00:00' not null; |
|
230 |
EOF; |
|
231 |
sql_execute($sql); |
|
232 |
}, |
|
233 |
|
|
234 |
'4.0.38' => function () { |
|
235 |
}, |
|
236 |
|
|
237 |
'4.0.39' => function () { |
|
238 |
}, |
|
239 |
|
|
240 |
'4.0.40' => function () { |
|
241 |
}, |
|
242 |
|
|
243 |
'4.1.0' => function () { |
|
244 |
$sql = <<<EOF |
|
245 |
ALTER TABLE `zjhj_bd_integral_mall_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
246 |
ALTER TABLE `zjhj_bd_lottery_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
247 |
ALTER TABLE `zjhj_bd_miaosha_setting` MODIFY COLUMN `send_type` longtext NOT NULL; |
|
248 |
ALTER TABLE `zjhj_bd_pintuan_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
249 |
ALTER TABLE `zjhj_bd_pond_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
250 |
ALTER TABLE `zjhj_bd_scratch_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
251 |
ALTER TABLE `zjhj_bd_step_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
252 |
ALTER TABLE `zjhj_bd_mch_setting` MODIFY COLUMN `send_type` longtext NOT NULL COMMENT '发货方式'; |
|
253 |
ALTER TABLE `zjhj_bd_order` ADD COLUMN `distance` INT DEFAULT -1 NULL COMMENT '同城配送距离,-1不在范围内,正数为距离KM' AFTER `auto_sales_time`, ADD COLUMN `city_mobile` VARCHAR(100) DEFAULT '' NULL COMMENT '同城配送联系方式' AFTER `distance`; |
|
254 |
CREATE TABLE `zjhj_bd_city_delivery_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `key` varchar(60) DEFAULT NULL, `value` text, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(2) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
255 |
DROP TABLE IF EXISTS `zjhj_bd_aliapp_config`; |
|
256 |
CREATE TABLE `zjhj_bd_aliapp_config` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `appid` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `app_private_key` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `alipay_public_key` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `cs_tnt_inst_id` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `cs_scene` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `app_aes_secret` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '内容加密AES密钥', `transfer_app_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '打款到用户app_id', `transfer_app_private_key` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '打款到用户app_private_key', `transfer_alipay_public_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `transfer_appcert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '应用公钥证书', `transfer_alipay_rootcert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝根证书', `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
257 |
CREATE TABLE `zjhj_bd_aliapp_template` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `tpl_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `tpl_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `created_at` timestamp(0) NULL DEFAULT NULL, `updated_at` timestamp(0) NULL DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
258 |
CREATE TABLE `zjhj_bd_bdapp_config` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `created_at` timestamp(0) NULL DEFAULT NULL, `updated_at` timestamp(0) NULL DEFAULT NULL, `app_id` varchar(16) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `app_key` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `app_secret` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `pay_dealid` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `pay_public_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `pay_private_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `pay_app_key` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Compact; |
|
259 |
CREATE TABLE `zjhj_bd_bdapp_order` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号', `bd_user_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `bd_order_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '百度平台订单ID', `bd_refund_batch_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '百度平台退款批次号', `bd_refund_money` int(11) NOT NULL DEFAULT 0, `refund_money` decimal(10, 2) NOT NULL DEFAULT 0.00, `is_refund` tinyint(4) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '百度订单号与商城订单号关联表' ROW_FORMAT = Dynamic; |
|
260 |
CREATE TABLE `zjhj_bd_bdapp_template` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `tpl_name` varchar(65) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `tpl_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
261 |
CREATE TABLE `zjhj_bd_ttapp_config` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商户号', `app_key` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `app_secret` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `pay_app_secret` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `pay_app_id` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `alipay_app_id` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `alipay_public_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `alipay_private_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `created_at` timestamp(0) NULL DEFAULT NULL, `updated_at` timestamp(0) NULL DEFAULT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Compact; |
|
262 |
CREATE TABLE `zjhj_bd_ttapp_template` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `tpl_name` varchar(65) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `tpl_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
263 |
EOF; |
|
264 |
sql_execute($sql); |
|
265 |
}, |
|
266 |
|
|
267 |
'4.1.1' => function () { |
|
268 |
$sql = <<<EOF |
|
269 |
ALTER TABLE `zjhj_bd_address` ADD COLUMN `latitude` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '经度' AFTER `deleted_at`, ADD COLUMN `longitude` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '纬度' AFTER `latitude`, ADD COLUMN `location` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '位置' AFTER `longitude`; |
|
270 |
EOF; |
|
271 |
sql_execute($sql); |
|
272 |
}, |
|
273 |
|
|
274 |
'4.1.2' => function () { |
|
275 |
}, |
|
276 |
|
|
277 |
'4.1.3' => function () { |
|
278 |
}, |
|
279 |
|
|
280 |
'4.1.4' => function () { |
|
281 |
$sql = <<<EOF |
|
282 |
ALTER TABLE `zjhj_bd_bonus_order_log` CHANGE `bonus_rate` `bonus_rate` VARCHAR(32) DEFAULT '0' NOT NULL COMMENT '下单时的分红比例%'; |
|
283 |
EOF; |
|
284 |
sql_execute($sql); |
|
285 |
}, |
|
286 |
|
|
287 |
'4.1.5' => function () { |
|
288 |
$sql = <<<EOF |
|
289 |
ALTER TABLE `zjhj_bd_order` ADD COLUMN `location` varchar(255) NULL, ADD COLUMN `city_name` varchar(255) NULL, ADD COLUMN `city_info` varchar(255) NULL; |
|
290 |
ALTER TABLE `zjhj_bd_order` CHANGE COLUMN `is_offline` `send_type` tinyint(1) NOT NULL DEFAULT 0 COMMENT '配送方式:0--快递配送 1--到店自提 2--同城配送'; |
|
291 |
CREATE TABLE `zjhj_bd_city_deliveryman` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `mch_id` int(11) NOT NULL DEFAULT '0', `name` varchar(255) NOT NULL COMMENT '配送员名称', `mobile` varchar(255) NOT NULL COMMENT '联系方式', `is_delete` tinyint(1) NOT NULL, `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
292 |
EOF; |
|
293 |
sql_execute($sql); |
|
294 |
}, |
|
295 |
|
|
296 |
'4.1.6' => function () { |
|
297 |
$sql = <<<EOF |
|
298 |
ALTER TABLE `zjhj_bd_topic` ADD COLUMN `pic_list` longtext NULL, ADD COLUMN `detail` longtext NULL, ADD COLUMN `abstract` varchar(255) NOT NULL DEFAULT '' COMMENT '摘要'; |
|
299 |
EOF; |
|
300 |
sql_execute($sql); |
|
301 |
}, |
|
302 |
|
|
303 |
'4.1.7' => function () { |
|
304 |
$sql = <<<EOF |
|
305 |
alter table `zjhj_bd_pintuan_order_relation` add cancel_status tinyint(1) not NULL default '0' COMMENT '拼团订单取消状态:0.未取消|1.超出拼团总人数取消'; |
|
306 |
EOF; |
|
307 |
sql_execute($sql); |
|
308 |
}, |
|
309 |
|
|
310 |
'4.1.8' => function () { |
|
311 |
$sql = <<<EOF |
|
312 |
CREATE TABLE `zjhj_bd_advance_banner` ( `id` int(11) NOT NULL AUTO_INCREMENT, `banner_id` int(11) NOT NULL, `mall_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL, `created_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='预售轮播图'; |
|
313 |
CREATE TABLE `zjhj_bd_advance_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `goods_id` int(11) NOT NULL, `mall_id` int(11) NOT NULL, `ladder_rules` varchar(4096) NOT NULL DEFAULT '' COMMENT '阶梯规则', `deposit` decimal(10,2) NOT NULL DEFAULT '0.00', `swell_deposit` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '定金膨胀金', `start_prepayment_at` timestamp NOT NULL COMMENT '预售开始时间', `end_prepayment_at` timestamp NOT NULL COMMENT '预售结束时间', `pay_limit` int(11) NOT NULL COMMENT '尾款支付时间 -1:无限制', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC; |
|
314 |
CREATE TABLE `zjhj_bd_advance_goods_attr` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `deposit` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '商品所需定金', `swell_deposit` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '定金膨胀金', `goods_id` int(11) NOT NULL, `goods_attr_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', `advance_num` int(11) NOT NULL DEFAULT '0' COMMENT '预约数量', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8 ROW_FORMAT=DYNAMIC; |
|
315 |
CREATE TABLE `zjhj_bd_advance_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL COMMENT '商品ID', `goods_attr_id` int(11) NOT NULL COMMENT '规格ID', `goods_num` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `order_no` varchar(255) NOT NULL DEFAULT '0', `advance_no` varchar(255) NOT NULL COMMENT '定金订单号', `deposit` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '定金', `swell_deposit` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '膨胀金', `is_cancel` tinyint(2) NOT NULL DEFAULT '0' COMMENT '1取消', `cancel_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_refund` tinyint(2) NOT NULL DEFAULT '0' COMMENT '1退款', `is_delete` tinyint(2) NOT NULL DEFAULT '0' COMMENT '1删除', `is_pay` tinyint(2) NOT NULL DEFAULT '0' COMMENT '是否支付:0.未支付|1.已支付', `is_recycle` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否加入回收站 0.否|1.是', `pay_type` tinyint(1) NOT NULL DEFAULT '0' COMMENT '支付方式:1.在线支付 2.货到付款 3.余额支付', `pay_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `remark` varchar(255) NOT NULL DEFAULT '' COMMENT '备注', `auto_cancel_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '自动取消时间', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `goods_info` longtext NOT NULL, `token` varchar(32) NOT NULL, `order_token` varchar(32) DEFAULT NULL, `preferential_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '活动优惠金额', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
316 |
CREATE TABLE `zjhj_bd_advance_order_submit_result` ( `id` int(11) NOT NULL AUTO_INCREMENT, `token` varchar(32) NOT NULL, `data` longtext, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
317 |
CREATE TABLE `zjhj_bd_advance_setting` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `is_advance` tinyint(1) NOT NULL DEFAULT '1', `payment_type` text NOT NULL, `deposit_payment_type` varchar(255) NOT NULL DEFAULT '', `is_share` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否开启分销', `is_sms` tinyint(1) NOT NULL DEFAULT '0', `is_mail` tinyint(1) NOT NULL DEFAULT '0', `is_print` tinyint(1) NOT NULL DEFAULT '0', `is_territorial_limitation` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否开启区域允许购买', `goods_poster` longtext NOT NULL, `send_type` varchar(255) NOT NULL DEFAULT '' COMMENT '发货方式', `over_time` int(11) NOT NULL DEFAULT '0' COMMENT '未支付定金订单超时时间', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
318 |
EOF; |
|
319 |
sql_execute($sql); |
|
320 |
}, |
|
321 |
|
|
322 |
'4.1.9' => function () { |
|
323 |
}, |
|
324 |
|
|
325 |
'4.1.10' => function () { |
|
326 |
}, |
|
327 |
|
|
328 |
'4.1.11' => function () { |
|
329 |
$sql = <<<EOF |
|
330 |
-- 首页接口索引优化 |
|
331 |
ALTER TABLE `zjhj_bd_goods_cats` ADD INDEX `index1`(`is_delete`,`status`,`is_show`,`mch_id`,`mall_id`); |
|
332 |
ALTER TABLE `zjhj_bd_goods_member_price` ADD INDEX `index1`(`is_delete`,`goods_id`,`level`); |
|
333 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD INDEX `index1`(`is_delete`,`open_date`,`open_time`); |
|
334 |
ALTER TABLE `zjhj_bd_mall_goods` ADD INDEX `index1`(`goods_id`); |
|
335 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD INDEX `index2`(`is_delete`,`goods_id`); |
|
336 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `index1`(`mall_id`,`is_delete`,`sign`,`status`,`goods_warehouse_id`); |
|
337 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index1`(`mall_id`,`is_delete`,`is_pay`,`pay_type`,`cancel_status`); |
|
338 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `index2`(`is_delete`,`mall_id`,`status`); |
|
339 |
|
|
340 |
-- 超级会员卡 |
|
341 |
CREATE TABLE `zjhj_bd_vip_card` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(255) NOT NULL DEFAULT '' COMMENT '会员卡名称', `cover` varchar(2048) NOT NULL DEFAULT '' COMMENT '卡片样式', `type` tinyint(4) NOT NULL DEFAULT '0' COMMENT '0:指定商品类别 1:指定商品 2:全场通用', `type_info` varchar(2048) NOT NULL DEFAULT '', `discount` decimal(11,1) NOT NULL DEFAULT '0.0' COMMENT '折扣', `is_discount` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:关闭 1开启', `is_free_delivery` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:不包邮 1:包邮', `status` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
342 |
CREATE TABLE `zjhj_bd_vip_card_appoint_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `goods_id` int(11) NOT NULL, `created_at` timestamp NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
343 |
CREATE TABLE `zjhj_bd_vip_card_cards` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `detail_id` int(11) NOT NULL COMMENT 'vip卡id', `card_id` int(11) NOT NULL COMMENT '卡券id', `send_num` int(11) NOT NULL COMMENT '赠送数量', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
344 |
CREATE TABLE `zjhj_bd_vip_card_coupons` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `detail_id` int(11) NOT NULL, `coupon_id` int(11) NOT NULL, `send_num` int(11) NOT NULL COMMENT '赠送数量', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
345 |
CREATE TABLE `zjhj_bd_vip_card_detail` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `vip_id` int(11) NOT NULL, `name` varchar(255) NOT NULL COMMENT '标题', `cover` varchar(2048) NOT NULL DEFAULT '' COMMENT '子卡封面', `expire_day` int(11) NOT NULL, `price` decimal(10,2) NOT NULL, `num` int(11) NOT NULL DEFAULT '0' COMMENT '库存', `sort` int(11) NOT NULL DEFAULT '100' COMMENT '排序', `send_integral_num` int(11) NOT NULL DEFAULT '0' COMMENT '积分赠送', `send_integral_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '积分赠送类型 1.固定值|2.百分比', `send_balance` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '赠送余额', `title` varchar(255) NOT NULL DEFAULT '' COMMENT '使用说明', `content` varchar(2048) NOT NULL DEFAULT '' COMMENT '使用内容', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:正常 1:停发', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
346 |
CREATE TABLE `zjhj_bd_vip_card_discount` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `order_id` int(11) NOT NULL, `order_detail_id` int(11) NOT NULL, `main_id` int(11) NOT NULL DEFAULT '0', `main_name` varchar(255) NOT NULL DEFAULT '' COMMENT '主卡名称', `detail_id` int(11) NOT NULL DEFAULT '0', `detail_name` varchar(255) NOT NULL DEFAULT '' COMMENT '子卡名称', `discount_num` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '折扣', `discount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '折扣优惠', `created_at` timestamp NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
347 |
CREATE TABLE `zjhj_bd_vip_card_order` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `main_id` int(11) NOT NULL COMMENT '主卡id', `main_name` varchar(255) NOT NULL DEFAULT '' COMMENT '主卡名称', `detail_id` int(11) NOT NULL, `detail_name` varchar(255) NOT NULL DEFAULT '' COMMENT '子卡名称', `price` decimal(10,2) NOT NULL COMMENT '购买价格', `expire` int(11) NOT NULL COMMENT '有效期', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未售 1已售', `all_send` varchar(2048) NOT NULL DEFAULT '', `is_admin_add` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否后台添加', `created_at` timestamp NULL DEFAULT NULL ON UPDATE CURRENT_TIMESTAMP, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
348 |
CREATE TABLE `zjhj_bd_vip_card_setting` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `is_vip_card` tinyint(1) NOT NULL DEFAULT '0', `payment_type` text NOT NULL, `is_share` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否开启分销', `is_sms` tinyint(1) NOT NULL DEFAULT '0', `is_mail` tinyint(1) NOT NULL DEFAULT '0', `is_agreement` tinyint(1) NOT NULL DEFAULT '0', `agreement_title` varchar(255) NOT NULL DEFAULT '', `agreement_content` text NOT NULL, `is_buy_become_share` tinyint(1) NOT NULL DEFAULT '0' COMMENT '购买成为分销商 0:关闭 1开启', `share_type` tinyint(4) NOT NULL DEFAULT '1' COMMENT '1.百分比|2.固定金额', `share_commission_first` decimal(10,2) NOT NULL DEFAULT '0.00', `share_commission_second` decimal(10,2) NOT NULL DEFAULT '0.00', `share_commission_third` decimal(10,2) NOT NULL DEFAULT '0.00', `form` text NOT NULL, `rules` text NOT NULL COMMENT '允许的插件', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
349 |
CREATE TABLE `zjhj_bd_vip_card_user` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `main_id` int(11) NOT NULL DEFAULT '0', `detail_id` int(11) NOT NULL, `image_type` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:指定商品类别 1:指定商品 2:全场通用', `image_type_info` varchar(2048) NOT NULL DEFAULT '', `image_discount` decimal(11,1) NOT NULL DEFAULT '0.0' COMMENT '折扣', `image_is_free_delivery` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:不包邮 1:包邮', `image_main_name` varchar(255) NOT NULL DEFAULT '' COMMENT '主卡名称', `image_name` varchar(255) NOT NULL COMMENT '名称', `all_send` varchar(2048) NOT NULL DEFAULT '' COMMENT '所有赠送信息', `data` longtext COMMENT '额外信息字段', `start_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `end_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`), KEY `mall_id` (`mall_id`) USING BTREE, KEY `user_id` (`user_id`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
350 |
EOF; |
|
351 |
sql_execute($sql); |
|
352 |
}, |
|
353 |
|
|
354 |
'4.1.14' => function () { |
|
355 |
}, |
|
356 |
|
|
357 |
|
|
358 |
'4.1.16' => function () { |
|
359 |
}, |
|
360 |
|
|
361 |
'4.1.17' => function () { |
|
362 |
$sql = <<<EOF |
|
363 |
ALTER TABLE `zjhj_bd_bargain_order` CHANGE `created_at` `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' AFTER `bargain_goods_data`; |
|
364 |
EOF; |
|
365 |
sql_execute($sql); |
|
366 |
}, |
|
367 |
|
|
368 |
'4.2.0' => function () { |
|
369 |
$sql = <<<EOF |
|
370 |
alter table `zjhj_bd_goods` add `confine_order_count` int(11) not NULL default '-1'; |
|
371 |
alter table `zjhj_bd_cart` add `attr_info` text; |
|
372 |
alter table `zjhj_bd_order_refund` add `refund_time` TIMESTAMP not NULL default '0000-00-00 00:00:00'; |
|
373 |
alter table `zjhj_bd_order_refund` add `is_refund` tinyint(1) not NULL default '2' COMMENT '是否打款,2代表旧数据'; |
|
374 |
alter table `zjhj_bd_order_detail` add `goods_no` varchar(60) not NULL default '' comment '商品货号'; |
|
375 |
CREATE TABLE `zjhj_bd_order_detail_express` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL, `order_id` int(11) NOT NULL COMMENT '订单ID', `express` varchar(65) NOT NULL DEFAULT '', `send_type` tinyint(1) NOT NULL COMMENT '1.快递|2.其它方式', `express_no` varchar(255) NOT NULL DEFAULT '', `merchant_remark` varchar(255) NOT NULL DEFAULT '' COMMENT '商家留言', `express_content` varchar(255) NOT NULL DEFAULT '' COMMENT '物流内容', `is_delete` tinyint(4) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
376 |
CREATE TABLE `zjhj_bd_order_detail_express_relation` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `order_detail_id` int(11) NOT NULL, `order_detail_express_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
377 |
CREATE TABLE `zjhj_bd_order_comments_templates` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '模板类型:1.好评|2.中评|3.差评', `title` varchar(65) NOT NULL DEFAULT '' COMMENT '标题', `content` varchar(255) NOT NULL DEFAULT '' COMMENT '内容', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
378 |
|
|
379 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `is_area_limit` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '是否单独区域购买' AFTER `confine_order_count`, ADD COLUMN `area_limit` LONGTEXT CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL AFTER `is_area_limit`; |
|
380 |
ALTER TABLE `zjhj_bd_lottery_log` ADD INDEX `lottery_id` ( `lottery_id` ) USING BTREE, ADD INDEX `user_id` ( `user_id` ) USING BTREE; |
|
381 |
ALTER TABLE `zjhj_bd_attachment_group` ADD COLUMN `is_recycle` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '是否加入回收站 0.否|1.是' AFTER `deleted_at`, ADD COLUMN `type` TINYINT ( 2 ) NOT NULL DEFAULT 0 COMMENT '0 图片 1商品' AFTER `is_recycle`; |
|
382 |
ALTER TABLE `zjhj_bd_attachment` ADD COLUMN `is_recycle` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '是否加入回收站 0.否|1.是' AFTER `is_delete`; |
|
383 |
EOF; |
|
384 |
sql_execute($sql); |
|
385 |
}, |
|
386 |
|
|
387 |
'4.2.1' => function () { |
|
388 |
}, |
|
389 |
|
|
390 |
'4.2.2' => function () { |
|
391 |
}, |
|
392 |
|
|
393 |
'4.2.3' => function () { |
|
394 |
$sql = <<<EOF |
|
395 |
ALTER TABLE zjhj_bd_order_refund ADD reality_refund_price DECIMAL ( 10, 2 ) NOT NULL DEFAULT '0' COMMENT '商家实际退款金额'; |
|
396 |
EOF; |
|
397 |
sql_execute($sql); |
|
398 |
}, |
|
399 |
|
|
400 |
'4.2.4' => function () { |
|
401 |
$sql = <<<EOF |
|
402 |
ALTER TABLE zjhj_bd_order_refund ADD reality_refund_price DECIMAL ( 10, 2 ) NOT NULL DEFAULT '0' COMMENT '商家实际退款金额'; |
|
403 |
EOF; |
|
404 |
sql_execute($sql); |
|
405 |
}, |
|
406 |
|
|
407 |
'4.2.5' => function () { |
|
408 |
$sql = <<<EOF |
|
409 |
CREATE TABLE `zjhj_bd_quick_share_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL DEFAULT '0', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '状态', `share_text` varchar(255) NOT NULL COMMENT '分享文本', `share_pic` longtext NOT NULL COMMENT '素材图片', `material_sort` int(11) NOT NULL DEFAULT '0' COMMENT '素材排序', `is_top` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否置顶', `material_video_url` varchar(255) NOT NULL DEFAULT '' COMMENT '动态视频', `material_cover_url` varchar(255) NOT NULL DEFAULT '' COMMENT '视频封面', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`), KEY `goods_id` (`goods_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
410 |
CREATE TABLE `zjhj_bd_quick_share_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `type` tinyint(1) NOT NULL DEFAULT '0' COMMENT '发圈对象 仅素材 1全部商品', `goods_poster` longtext NOT NULL, `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
411 |
EOF; |
|
412 |
sql_execute($sql); |
|
413 |
}, |
|
414 |
|
|
415 |
'4.2.8' => function () { |
|
416 |
$sql = <<<EOF |
|
417 |
ALTER TABLE zjhj_bd_order_refund ADD merchant_express_content VARCHAR ( 255 ) NOT NULL DEFAULT '' COMMENT '物流内容'; |
|
418 |
EOF; |
|
419 |
sql_execute($sql); |
|
420 |
}, |
|
421 |
|
|
422 |
'4.2.9' => function () { |
|
423 |
$sql = <<<EOF |
|
424 |
ALTER TABLE zjhj_bd_goods_card_relation ADD num INT ( 11 ) NOT NULL DEFAULT 1 COMMENT '卡券数量'; |
|
425 |
EOF; |
|
426 |
sql_execute($sql); |
|
427 |
}, |
|
428 |
|
|
429 |
|
|
430 |
'4.2.10' => function () { |
|
431 |
$sql = <<<EOF |
|
432 |
ALTER TABLE `zjhj_bd_order_detail_express` ADD `customer_name` VARCHAR ( 255 ) NOT NULL DEFAULT '' COMMENT '京东物流编号'; |
|
433 |
|
|
434 |
CREATE TABLE `zjhj_bd_gift_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `num` int(11) NOT NULL DEFAULT '0' COMMENT '礼物总数', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `is_confirm` tinyint(1) NOT NULL DEFAULT '0' COMMENT '送礼状态:0.未完成送礼|1.已完成送礼', `type` varchar(60) NOT NULL COMMENT '送礼方式', `open_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '开奖时间', `open_num` int(11) NOT NULL DEFAULT '0' COMMENT '开奖所需人数', `open_type` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0一人拿奖,1多人各领一份奖', `bless_word` varchar(200) NOT NULL COMMENT '祝福语', `auto_refund_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '自动退款时间', `is_pay` tinyint(1) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `is_cancel` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
435 |
CREATE TABLE `zjhj_bd_gift_lottery` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `send_order_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `is_prize` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未中,1中奖', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; |
|
436 |
CREATE TABLE `zjhj_bd_gift_open_result` ( `id` int(11) NOT NULL AUTO_INCREMENT, `token` varchar(32) NOT NULL, `data` longtext, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
437 |
CREATE TABLE `zjhj_bd_gift_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `order_no` varchar(255) NOT NULL DEFAULT '', `goods_id` int(11) NOT NULL DEFAULT '0', `goods_attr_id` int(11) NOT NULL DEFAULT '0', `num` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0' COMMENT '商城订单ID', `type` varchar(60) NOT NULL COMMENT '送礼方式', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `user_order_id` int(11) NOT NULL DEFAULT '0', `is_refund` tinyint(1) NOT NULL DEFAULT '0' COMMENT '退款,前端显示超时', `buy_order_detail_id` int(11) NOT NULL DEFAULT '0' COMMENT '买礼物的商城订单详情id', `gift_id` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
438 |
CREATE TABLE `zjhj_bd_gift_order_submit_result` ( `id` int(11) NOT NULL AUTO_INCREMENT, `token` varchar(32) NOT NULL, `data` longtext, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
439 |
CREATE TABLE `zjhj_bd_gift_send_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `mch_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `gift_id` int(11) NOT NULL DEFAULT '0' COMMENT 'gift_log的id', `order_no` varchar(60) NOT NULL DEFAULT '', `total_price` decimal(10,2) NOT NULL COMMENT '订单总金额(含运费)', `total_pay_price` decimal(10,2) NOT NULL COMMENT '实际支付总费用(含运费)', `is_pay` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否支付:0.未支付|1.已支付', `pay_type` tinyint(4) NOT NULL DEFAULT '0' COMMENT '支付方式:1.在线支付 2.货到付款 3.余额支付', `pay_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '支付时间', `is_refund` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未退款,1已退款', `is_confirm` tinyint(1) NOT NULL DEFAULT '0' COMMENT '送礼状态:0.未完成送礼|1.已完成送礼', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `support_pay_types` text NOT NULL COMMENT '支持的支付方式,空表示支持系统设置支持的所有方式', `token` varchar(32) NOT NULL, `total_goods_price` decimal(10,2) NOT NULL DEFAULT '0.00', `total_goods_original_price` decimal(10,2) NOT NULL DEFAULT '0.00', `member_discount_price` decimal(10,2) NOT NULL DEFAULT '0.00', `use_user_coupon_id` int(11) NOT NULL DEFAULT '0', `coupon_discount_price` decimal(10,2) NOT NULL DEFAULT '0.00', `use_integral_num` int(11) NOT NULL DEFAULT '0', `integral_deduction_price` decimal(10,2) NOT NULL DEFAULT '0.00', `is_cancel` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
440 |
CREATE TABLE `zjhj_bd_gift_send_order_detail` ( `id` int(11) NOT NULL AUTO_INCREMENT, `send_order_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL, `goods_attr_id` int(11) NOT NULL DEFAULT '0', `goods_info` longtext COMMENT '购买商品信息', `num` int(11) NOT NULL, `unit_price` decimal(10,2) NOT NULL COMMENT '商品单价', `total_original_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '商品原总价(优惠前)', `total_price` decimal(10,2) NOT NULL COMMENT '商品总价(优惠后)', `member_discount_price` decimal(10,2) NOT NULL DEFAULT '0.00', `is_refund` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未退款,1已退款', `refund_status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '售后状态 0--未售后 1--售后中 2--售后结束', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `receive_num` int(11) NOT NULL DEFAULT '0' COMMENT '已领取数量', `refund_price` decimal(10,2) NOT NULL DEFAULT '0.00', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
441 |
CREATE TABLE `zjhj_bd_gift_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `title` varchar(200) NOT NULL, `type` varchar(200) NOT NULL DEFAULT '[]' COMMENT '玩法', `auto_refund` int(11) NOT NULL DEFAULT '0' COMMENT '自动退款天数', `auto_remind` int(11) NOT NULL DEFAULT '0' COMMENT '送礼失败提醒天数', `bless_word` varchar(200) NOT NULL COMMENT '祝福语', `ask_gift` varchar(200) NOT NULL COMMENT '求礼物', `is_share` tinyint(1) NOT NULL DEFAULT '0', `is_sms` tinyint(1) NOT NULL DEFAULT '0', `is_mail` tinyint(1) NOT NULL DEFAULT '0', `is_print` tinyint(1) NOT NULL DEFAULT '0', `payment_type` text NOT NULL, `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `poster` longtext NOT NULL COMMENT '海报', `background` varchar(200) NOT NULL DEFAULT '[]' COMMENT '自定义背景', `theme` text NOT NULL COMMENT '主题色', `send_type` varchar(200) NOT NULL DEFAULT '[]', `explain` text NOT NULL COMMENT '规则说明', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
442 |
CREATE TABLE `zjhj_bd_gift_user_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `gift_id` int(11) NOT NULL DEFAULT '0', `is_turn` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否转赠0未转1已转', `turn_no` varchar(255) NOT NULL DEFAULT '' COMMENT '转赠码', `turn_user_id` int(11) NOT NULL DEFAULT '0' COMMENT '被转赠用户ID', `is_receive` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未领取,1已领取', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `is_win` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0未中,1已中', `token` varchar(32) NOT NULL DEFAULT '', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8; |
|
443 |
EOF; |
|
444 |
sql_execute($sql); |
|
445 |
}, |
|
446 |
|
|
447 |
'4.2.11' => function () { |
|
448 |
$sql = <<<EOF |
|
449 |
ALTER TABLE `zjhj_bd_booking_setting` |
|
450 |
MODIFY COLUMN `created_at` timestamp NOT NULL AFTER `form_data`, |
|
451 |
MODIFY COLUMN `updated_at` timestamp NOT NULL AFTER `created_at`; |
|
452 |
|
|
453 |
ALTER TABLE `zjhj_bd_pond_log_coupon_relation` |
|
454 |
MODIFY COLUMN `created_at` timestamp NOT NULL AFTER `is_delete`, |
|
455 |
MODIFY COLUMN `deleted_at` timestamp NOT NULL AFTER `created_at`; |
|
456 |
|
|
457 |
|
|
458 |
ALTER TABLE `zjhj_bd_pond_order` |
|
459 |
MODIFY COLUMN `created_at` timestamp NOT NULL AFTER `order_id`; |
|
460 |
|
|
461 |
ALTER TABLE `zjhj_bd_scratch_log` |
|
462 |
MODIFY COLUMN `deleted_at` timestamp NOT NULL AFTER `is_delete`; |
|
463 |
|
|
464 |
ALTER TABLE `zjhj_bd_address` |
|
465 |
MODIFY COLUMN `created_at` timestamp NOT NULL AFTER `is_delete`; |
|
466 |
EOF; |
|
467 |
sql_execute($sql); |
|
468 |
}, |
|
469 |
|
|
470 |
'4.2.12' => function () { |
|
471 |
}, |
|
472 |
|
|
473 |
'4.2.13' => function () { |
|
474 |
$sql = <<<EOF |
|
475 |
CREATE TABLE `zjhj_bd_footprint_data_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `key` varchar(60) NOT NULL, `value` varchar(60) NOT NULL, `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `statistics_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '上一次统计的时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
476 |
CREATE TABLE `zjhj_bd_footprint_goods_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `goods_id` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
477 |
|
|
478 |
ALTER TABLE `zjhj_bd_formid` ADD INDEX `user_id`(`user_id`); |
|
479 |
ALTER TABLE `zjhj_bd_formid` ADD INDEX `created_at`(`created_at`); |
|
480 |
ALTER TABLE `zjhj_bd_formid` ADD INDEX `remains`(`remains`); |
|
481 |
|
|
482 |
ALTER TABLE `zjhj_bd_goods_attr` ADD INDEX `goods_id`(`goods_id`); |
|
483 |
ALTER TABLE `zjhj_bd_goods_attr` ADD INDEX `is_delete`(`is_delete`); |
|
484 |
|
|
485 |
ALTER TABLE `zjhj_bd_user_identity` ADD INDEX `user_id`(`user_id`); |
|
486 |
|
|
487 |
ALTER TABLE `zjhj_bd_check_in_user` ADD INDEX `user_id`(`user_id`); |
|
488 |
ALTER TABLE `zjhj_bd_check_in_user` ADD INDEX `mall_id`(`mall_id`); |
|
489 |
ALTER TABLE `zjhj_bd_check_in_user` ADD INDEX `is_delete`(`is_delete`); |
|
490 |
|
|
491 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `attachment_group_id`(`attachment_group_id`); |
|
492 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `mall_id`(`mall_id`); |
|
493 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `mch_id`(`mch_id`); |
|
494 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `type`(`type`); |
|
495 |
|
|
496 |
ALTER TABLE `zjhj_bd_attachment_group` ADD INDEX `mall_id`(`mall_id`); |
|
497 |
ALTER TABLE `zjhj_bd_attachment_group` ADD INDEX `mch_id`(`mch_id`); |
|
498 |
ALTER TABLE `zjhj_bd_attachment_group` ADD INDEX `type`(`type`); |
|
499 |
|
|
500 |
ALTER TABLE `zjhj_bd_balance_log` ADD INDEX `mall_id`(`mall_id`); |
|
501 |
ALTER TABLE `zjhj_bd_balance_log` ADD INDEX `user_id`(`user_id`); |
|
502 |
ALTER TABLE `zjhj_bd_balance_log` ADD INDEX `type`(`type`); |
|
503 |
|
|
504 |
ALTER TABLE `zjhj_bd_bargain_user_order` ADD INDEX `mall_id`(`mall_id`); |
|
505 |
ALTER TABLE `zjhj_bd_bargain_user_order` ADD INDEX `user_id`(`user_id`); |
|
506 |
ALTER TABLE `zjhj_bd_bargain_user_order` ADD INDEX `bargain_order_id`(`bargain_order_id`); |
|
507 |
|
|
508 |
ALTER TABLE `zjhj_bd_bonus_captain_log` ADD INDEX `mall_id`(`mall_id`); |
|
509 |
ALTER TABLE `zjhj_bd_bonus_captain_log` ADD INDEX `user_id`(`user_id`); |
|
510 |
|
|
511 |
ALTER TABLE `zjhj_bd_cart` ADD INDEX `mall_id`(`mall_id`); |
|
512 |
ALTER TABLE `zjhj_bd_cart` ADD INDEX `user_id`(`user_id`); |
|
513 |
|
|
514 |
ALTER TABLE `zjhj_bd_check_in_sign` ADD INDEX `mall_id`(`mall_id`); |
|
515 |
ALTER TABLE `zjhj_bd_check_in_sign` ADD INDEX `user_id`(`user_id`); |
|
516 |
|
|
517 |
ALTER TABLE `zjhj_bd_check_in_user_remind` ADD INDEX `mall_id`(`mall_id`); |
|
518 |
ALTER TABLE `zjhj_bd_check_in_user_remind` ADD INDEX `user_id`(`user_id`); |
|
519 |
ALTER TABLE `zjhj_bd_check_in_user_remind` ADD INDEX `is_remind`(`is_remind`); |
|
520 |
|
|
521 |
ALTER TABLE `zjhj_bd_core_queue_data` ADD INDEX `queue_id`(`queue_id`); |
|
522 |
ALTER TABLE `zjhj_bd_core_queue_data` ADD INDEX `token`(`token`); |
|
523 |
|
|
524 |
ALTER TABLE `zjhj_bd_coupon_mall_relation` ADD INDEX `mall_id`(`mall_id`); |
|
525 |
ALTER TABLE `zjhj_bd_coupon_mall_relation` ADD INDEX `user_coupon_id`(`user_coupon_id`); |
|
526 |
|
|
527 |
ALTER TABLE `zjhj_bd_goods_cats` ADD INDEX `mall_id`(`mall_id`); |
|
528 |
ALTER TABLE `zjhj_bd_goods_cats` ADD INDEX `mch_id`(`mch_id`); |
|
529 |
ALTER TABLE `zjhj_bd_goods_cats` ADD INDEX `parent_id`(`parent_id`); |
|
530 |
|
|
531 |
ALTER TABLE `zjhj_bd_goods_cat_relation` ADD INDEX `cat_id`(`cat_id`); |
|
532 |
|
|
533 |
ALTER TABLE `zjhj_bd_goods_member_price` ADD INDEX `goods_id`(`goods_id`); |
|
534 |
|
|
535 |
ALTER TABLE `zjhj_bd_integral_log` ADD INDEX `mall_id`(`mall_id`); |
|
536 |
ALTER TABLE `zjhj_bd_integral_log` ADD INDEX `user_id`(`user_id`); |
|
537 |
ALTER TABLE `zjhj_bd_integral_log` ADD INDEX `type`(`type`); |
|
538 |
|
|
539 |
ALTER TABLE `zjhj_bd_integral_mall_goods_attr` ADD INDEX `goods_id`(`goods_id`); |
|
540 |
ALTER TABLE `zjhj_bd_integral_mall_goods_attr` ADD INDEX `goods_attr_id`(`goods_attr_id`); |
|
541 |
|
|
542 |
ALTER TABLE `zjhj_bd_lottery_log` ADD INDEX `mall_id`(`mall_id`); |
|
543 |
|
|
544 |
ALTER TABLE `zjhj_bd_mall_goods` ADD INDEX `mall_id`(`mall_id`); |
|
545 |
|
|
546 |
ALTER TABLE `zjhj_bd_mall_setting` ADD INDEX `mall_id`(`mall_id`); |
|
547 |
ALTER TABLE `zjhj_bd_mall_setting` ADD INDEX `key`(`key`); |
|
548 |
|
|
549 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD INDEX `mall_id`(`mall_id`); |
|
550 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD INDEX `goods_id`(`goods_id`); |
|
551 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD INDEX `goods_warehouse_id`(`goods_warehouse_id`); |
|
552 |
|
|
553 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `mall_id`(`mall_id`); |
|
554 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `mch_id`(`mch_id`); |
|
555 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `group`(`group`); |
|
556 |
ALTER TABLE `zjhj_bd_option` ADD INDEX `name`(`name`); |
|
557 |
|
|
558 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `order_no`(`order_no`); |
|
559 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_pay`(`is_pay`); |
|
560 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_send`(`is_send`); |
|
561 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_sale`(`is_sale`); |
|
562 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_confirm`(`is_confirm`); |
|
563 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_delete`(`is_delete`); |
|
564 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_recycle`(`is_recycle`); |
|
565 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `token`(`token`); |
|
566 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `is_comment`(`is_comment`); |
|
567 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `status`(`status`); |
|
568 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `sale_status`(`sale_status`); |
|
569 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `sign`(`sign`); |
|
570 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `clerk_id`(`clerk_id`); |
|
571 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `store_id`(`store_id`); |
|
572 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `cancel_status`(`cancel_status`); |
|
573 |
|
|
574 |
ALTER TABLE `zjhj_bd_order_detail_express` ADD INDEX `mall_id`(`mall_id`); |
|
575 |
ALTER TABLE `zjhj_bd_order_detail_express` ADD INDEX `mch_id`(`mch_id`); |
|
576 |
ALTER TABLE `zjhj_bd_order_detail_express` ADD INDEX `order_id`(`order_id`); |
|
577 |
ALTER TABLE `zjhj_bd_order_detail_express` ADD INDEX `send_type`(`send_type`); |
|
578 |
|
|
579 |
ALTER TABLE `zjhj_bd_order_pay_result` ADD INDEX `order_id`(`order_id`); |
|
580 |
|
|
581 |
ALTER TABLE `zjhj_bd_payment_order` ADD INDEX `payment_order_union_id`(`payment_order_union_id`); |
|
582 |
ALTER TABLE `zjhj_bd_payment_order` ADD INDEX `order_no`(`order_no`); |
|
583 |
ALTER TABLE `zjhj_bd_payment_order` ADD INDEX `is_pay`(`is_pay`); |
|
584 |
ALTER TABLE `zjhj_bd_payment_order` ADD INDEX `pay_type`(`pay_type`); |
|
585 |
|
|
586 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD INDEX `mall_id`(`mall_id`); |
|
587 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD INDEX `user_id`(`user_id`); |
|
588 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD INDEX `order_no`(`order_no`); |
|
589 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD INDEX `is_pay`(`is_pay`); |
|
590 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD INDEX `pay_type`(`pay_type`); |
|
591 |
|
|
592 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `mall_id`(`mall_id`); |
|
593 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `pond_id`(`pond_id`); |
|
594 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `user_id`(`user_id`); |
|
595 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `status`(`status`); |
|
596 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `type`(`type`); |
|
597 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `goods_id`(`goods_id`); |
|
598 |
ALTER TABLE `zjhj_bd_pond_log` ADD INDEX `order_id`(`order_id`); |
|
599 |
|
|
600 |
ALTER TABLE `zjhj_bd_quick_share_goods` ADD INDEX `mall_id`(`mall_id`); |
|
601 |
ALTER TABLE `zjhj_bd_quick_share_goods` ADD INDEX `goods_id`(`goods_id`); |
|
602 |
ALTER TABLE `zjhj_bd_quick_share_goods` ADD INDEX `status`(`status`); |
|
603 |
ALTER TABLE `zjhj_bd_quick_share_goods` ADD INDEX `is_top`(`is_top`); |
|
604 |
|
|
605 |
ALTER TABLE `zjhj_bd_share` ADD INDEX `mall_id`(`mall_id`); |
|
606 |
ALTER TABLE `zjhj_bd_share` ADD INDEX `user_id`(`user_id`); |
|
607 |
|
|
608 |
ALTER TABLE `zjhj_bd_share_cash_log` ADD INDEX `mall_id`(`mall_id`); |
|
609 |
ALTER TABLE `zjhj_bd_share_cash_log` ADD INDEX `user_id`(`user_id`); |
|
610 |
ALTER TABLE `zjhj_bd_share_cash_log` ADD INDEX `type`(`type`); |
|
611 |
|
|
612 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `mall_id`(`mall_id`); |
|
613 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `order_id`(`order_id`); |
|
614 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `order_detail_id`(`order_detail_id`); |
|
615 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `user_id`(`user_id`); |
|
616 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `first_parent_id`(`first_parent_id`); |
|
617 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `second_parent_id`(`second_parent_id`); |
|
618 |
ALTER TABLE `zjhj_bd_share_order` ADD INDEX `third_parent_id`(`third_parent_id`); |
|
619 |
|
|
620 |
ALTER TABLE `zjhj_bd_share_setting` ADD INDEX `mall_id`(`mall_id`); |
|
621 |
ALTER TABLE `zjhj_bd_share_setting` ADD INDEX `key`(`key`); |
|
622 |
|
|
623 |
ALTER TABLE `zjhj_bd_shopping_buys` ADD INDEX `mall_id`(`mall_id`); |
|
624 |
ALTER TABLE `zjhj_bd_shopping_buys` ADD INDEX `order_id`(`order_id`); |
|
625 |
ALTER TABLE `zjhj_bd_shopping_buys` ADD INDEX `user_id`(`user_id`); |
|
626 |
|
|
627 |
ALTER TABLE `zjhj_bd_template_record` ADD INDEX `mall_id`(`mall_id`); |
|
628 |
ALTER TABLE `zjhj_bd_template_record` ADD INDEX `user_id`(`user_id`); |
|
629 |
ALTER TABLE `zjhj_bd_template_record` ADD INDEX `status`(`status`); |
|
630 |
|
|
631 |
ALTER TABLE `zjhj_bd_user` ADD INDEX `mall_id`(`mall_id`); |
|
632 |
ALTER TABLE `zjhj_bd_user` ADD INDEX `mch_id`(`mch_id`); |
|
633 |
ALTER TABLE `zjhj_bd_user` ADD INDEX `username`(`username`); |
|
634 |
ALTER TABLE `zjhj_bd_user` ADD INDEX `access_token`(`access_token`); |
|
635 |
|
|
636 |
ALTER TABLE `zjhj_bd_user_coupon_auto` ADD INDEX `user_coupon_id`(`user_coupon_id`); |
|
637 |
ALTER TABLE `zjhj_bd_user_coupon_auto` ADD INDEX `auto_coupon_id`(`auto_coupon_id`); |
|
638 |
|
|
639 |
ALTER TABLE `zjhj_bd_user_coupon_center` ADD INDEX `mall_id`(`mall_id`); |
|
640 |
ALTER TABLE `zjhj_bd_user_coupon_center` ADD INDEX `user_coupon_id`(`user_coupon_id`); |
|
641 |
ALTER TABLE `zjhj_bd_user_coupon_center` ADD INDEX `user_id`(`user_id`); |
|
642 |
|
|
643 |
ALTER TABLE `zjhj_bd_user_info` ADD INDEX `platform_user_id`(`platform_user_id`); |
|
644 |
ALTER TABLE `zjhj_bd_user_info` ADD INDEX `temp_parent_id`(`temp_parent_id`); |
|
645 |
EOF; |
|
646 |
sql_execute($sql); |
|
647 |
}, |
|
648 |
|
|
649 |
'4.2.14' => function () { |
|
650 |
}, |
|
651 |
|
|
652 |
'4.2.15' => function () { |
|
653 |
$sql = <<<EOF |
|
654 |
ALTER TABLE `zjhj_bd_lottery` |
|
655 |
MODIFY COLUMN `start_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '开始时间' AFTER `stock`, |
|
656 |
MODIFY COLUMN `end_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '结束时间' AFTER `start_at`; |
|
657 |
EOF; |
|
658 |
sql_execute($sql); |
|
659 |
}, |
|
660 |
|
|
661 |
'4.2.17' => function () { |
|
662 |
}, |
|
663 |
|
|
664 |
'4.2.18' => function () { |
|
665 |
}, |
|
666 |
|
|
667 |
'4.2.19' => function () { |
|
668 |
}, |
|
669 |
|
|
670 |
'4.2.20' => function () { |
|
671 |
$sql = <<<EOF |
|
672 |
alter table `zjhj_bd_order_detail_express` add `express_single_id` int(11) not null default 0 comment '电子面单ID'; |
|
673 |
|
|
674 |
ALTER TABLE `zjhj_bd_goods_cats` |
|
675 |
ADD COLUMN `advert_open_type` varchar(65) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '打开方式' AFTER `is_show`, |
|
676 |
ADD COLUMN `advert_params` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '导航参数' AFTER `advert_open_type`; |
|
677 |
EOF; |
|
678 |
sql_execute($sql); |
|
679 |
}, |
|
680 |
|
|
681 |
'4.2.21' => function () { |
|
682 |
$sql = <<<EOF |
|
683 |
ALTER TABLE `zjhj_bd_order_detail` ADD COLUMN `form_data` longtext NULL COMMENT '自定义表单提交的数据' AFTER `goods_no`; |
|
684 |
ALTER TABLE `zjhj_bd_order_detail` ADD COLUMN `form_id` int(11) NOT NULL DEFAULT 0 COMMENT '自定义表单的id' AFTER `form_data`; |
|
685 |
ALTER TABLE `zjhj_bd_coupon_auto_send` ADD COLUMN `type` tinyint(1) NOT NULL DEFAULT 0 COMMENT '领取人 0--所有人 1--指定用户', ADD COLUMN `user_list` longtext NULL COMMENT '指定用户id列表'; |
|
686 |
ALTER TABLE `zjhj_bd_share` ADD COLUMN `level` int(11) NOT NULL DEFAULT 0 COMMENT '分销商等级', ADD COLUMN `level_at` timestamp NULL DEFAULT '' COMMENT '成为分销商等级时间', ADD COLUMN `delete_first_show` tinyint(1) NOT NULL DEFAULT 0 COMMENT '删除后是否第一次展示'; |
|
687 |
CREATE TABLE `zjhj_bd_share_level` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `level` int(11) NOT NULL DEFAULT '1' COMMENT '分销等级1~100', `name` varchar(255) NOT NULL DEFAULT '' COMMENT '分销等级名称', `condition_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '升级条件:1--下线用户数|2--累计佣金|3--已提现佣金', `condition` decimal(11,2) NOT NULL DEFAULT '0.00' COMMENT '下线用户数(人)|累计佣金数(元)|已提现佣金数(元)', `price_type` tinyint(1) NOT NULL DEFAULT '1' COMMENT '分销佣金类型:1--百分比|2--固定金额', `first` decimal(11,2) NOT NULL DEFAULT '0.00' COMMENT '一级分销佣金数(元)', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否启用', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `second` decimal(11,2) NOT NULL DEFAULT '0.00' COMMENT '二级分销佣金数(元)', `third` decimal(11,2) NOT NULL DEFAULT '0.00' COMMENT '三级分销佣金数(元)', `is_auto_level` tinyint(1) NOT NULL DEFAULT '1' COMMENT '是否启用自动升级', `rule` varchar(255) NOT NULL DEFAULT '' COMMENT '等级说明', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
688 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `form_id` int NOT NULL DEFAULT 0 COMMENT '自定义表单id 0--表示默认表单 -1--表示不使用表单'; |
|
689 |
ALTER TABLE `zjhj_bd_goods_share` ADD COLUMN `level` int(11) NOT NULL DEFAULT 0 COMMENT '分销商等级'; |
|
690 |
ALTER TABLE `zjhj_bd_pintuan_goods_share` ADD COLUMN `level` int(11) NOT NULL DEFAULT 0 COMMENT '分销商等级'; |
|
691 |
CREATE TABLE `zjhj_bd_form` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `mch_id` int(11) NOT NULL DEFAULT '0', `name` varchar(255) NOT NULL DEFAULT '', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否启用', `data` longtext NOT NULL COMMENT '表单内容', `is_default` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否默认', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
692 |
ALTER TABLE `zjhj_bd_user_coupon` ADD COLUMN `discount_limit` decimal(10,2) NULL DEFAULT NULL COMMENT '折扣优惠上限'; |
|
693 |
ALTER TABLE `zjhj_bd_coupon` ADD COLUMN `discount_limit` decimal(10,2) NULL DEFAULT NULL COMMENT '折扣优惠上限'; |
|
694 |
ALTER TABLE `zjhj_bd_vip_card_setting` ADD COLUMN `share_level` text COMMENT '分销等级'; |
|
695 |
EOF; |
|
696 |
sql_execute($sql); |
|
697 |
}, |
|
698 |
|
|
699 |
'4.2.22' => function () { |
|
700 |
$sql = <<<EOF |
|
701 |
ALTER TABLE `zjhj_bd_goods_warehouse` MODIFY COLUMN `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '商品名称' AFTER `mall_id`; |
|
702 |
ALTER TABLE `zjhj_bd_share` ADD COLUMN `level` int(11) NOT NULL DEFAULT 0 COMMENT '分销商等级', ADD COLUMN `level_at` timestamp NULL DEFAULT '0000-00-00 00:00:00' COMMENT '成为分销商等级时间', ADD COLUMN `delete_first_show` tinyint(1) NOT NULL DEFAULT 0 COMMENT '删除后是否第一次展示'; |
|
703 |
EOF; |
|
704 |
sql_execute($sql); |
|
705 |
}, |
|
706 |
|
|
707 |
'4.2.23' => function () { |
|
708 |
$sql = <<<EOF |
|
709 |
ALTER TABLE `zjhj_bd_form` ADD COLUMN `value` longtext NOT NULL; |
|
710 |
EOF; |
|
711 |
sql_execute($sql); |
|
712 |
}, |
|
713 |
|
|
714 |
'4.2.24' => function () { |
|
715 |
$sql = <<<EOF |
|
716 |
ALTER TABLE `zjhj_bd_form` MODIFY COLUMN `data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '表单内容'; |
|
717 |
EOF; |
|
718 |
sql_execute($sql); |
|
719 |
}, |
|
720 |
|
|
721 |
'4.2.25' => function () { |
|
722 |
}, |
|
723 |
|
|
724 |
'4.2.27' => function () { |
|
725 |
$sql = <<<EOF |
|
726 |
ALTER TABLE `zjhj_bd_order_detail` MODIFY COLUMN `form_id` int(11) NULL DEFAULT 0 COMMENT '自定义表单的id' AFTER `form_data`; |
|
727 |
EOF; |
|
728 |
sql_execute($sql); |
|
729 |
}, |
|
730 |
|
|
731 |
'4.2.28' => function () { |
|
732 |
$sql = <<<EOF |
|
733 |
CREATE TABLE `zjhj_bd_wxapp_subscribe` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `tpl_name` varchar(65) NOT NULL DEFAULT '', `tpl_id` varchar(255) NOT NULL DEFAULT '', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='微信订阅消息'; |
|
734 |
EOF; |
|
735 |
sql_execute($sql); |
|
736 |
}, |
|
737 |
|
|
738 |
'4.2.29' => function () { |
|
739 |
}, |
|
740 |
|
|
741 |
'4.2.30' => function () { |
|
742 |
$sql = <<<EOF |
|
743 |
CREATE TABLE `zjhj_bd_core_template` ( `id` int(11) NOT NULL AUTO_INCREMENT, `template_id` int(11) NOT NULL DEFAULT '0' COMMENT '模板id', `name` varchar(255) NOT NULL DEFAULT '' COMMENT '模板名称', `author` varchar(255) NOT NULL DEFAULT '' COMMENT '作者', `price` decimal(10,0) NOT NULL DEFAULT '0' COMMENT '价格', `pics` longtext NOT NULL, `data` longtext NOT NULL COMMENT '数据', `order_no` varchar(255) NOT NULL DEFAULT '' COMMENT '订单号', `version` varchar(255) NOT NULL DEFAULT '' COMMENT '版本号', `type` varchar(255) NOT NULL DEFAULT '' COMMENT 'home--首页布局 diy--DIY模板', `detail` longtext NOT NULL, `is_delete` tinyint(1) NOT NULL, `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
744 |
CREATE TABLE `zjhj_bd_core_template_edit` ( `id` int(11) NOT NULL AUTO_INCREMENT, `template_id` int(11) NOT NULL DEFAULT '0' COMMENT '模板id', `name` varchar(255) NOT NULL DEFAULT '' COMMENT '修改后名称', `price` decimal(10,0) NOT NULL DEFAULT '0' COMMENT '修改后价格', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
745 |
ALTER TABLE `zjhj_bd_address` ADD INDEX `user_id`(`user_id`); |
|
746 |
ALTER TABLE `zjhj_bd_vip_card_setting` ADD INDEX `mall_id`(`mall_id`); |
|
747 |
ALTER TABLE `zjhj_bd_vip_card_appoint_goods` ADD INDEX `goods_id`(`goods_id`); |
|
748 |
ALTER TABLE `zjhj_bd_mall_members` ADD INDEX `mall_id`(`mall_id`); |
|
749 |
ALTER TABLE `zjhj_bd_mall_members` ADD INDEX `level`(`level`); |
|
750 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `mall_id`(`mall_id`); |
|
751 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `mch_id`(`mch_id`); |
|
752 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `status`(`status`); |
|
753 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `store_id`(`store_id`); |
|
754 |
EOF; |
|
755 |
sql_execute($sql); |
|
756 |
}, |
|
757 |
|
|
758 |
'4.2.31' => function () { |
|
759 |
$sql = <<<EOF |
|
760 |
CREATE TABLE `zjhj_bd_import_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL COMMENT '操作账户ID', `status` tinyint(4) NOT NULL COMMENT '导入状态|1.全部失败|2.部分失败|3.全部成功', `file_name` varchar(191) NOT NULL DEFAULT '' COMMENT '导入文件名', `goods_count` int(11) NOT NULL, `success_count` int(11) NOT NULL, `error_count` int(11) NOT NULL, `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
761 |
alter table `zjhj_bd_order_comments` add `is_top` tinyint(1) default 0 not null comment '是否置顶0.否|1.是'; |
|
762 |
EOF; |
|
763 |
sql_execute($sql); |
|
764 |
}, |
|
765 |
|
|
766 |
'4.2.32' => function () { |
|
767 |
}, |
|
768 |
|
|
769 |
'4.2.35' => function () { |
|
770 |
}, |
|
771 |
|
|
772 |
'4.2.36' => function () { |
|
773 |
$sql = <<<EOF |
|
774 |
ALTER TABLE `zjhj_bd_gift_log` ADD COLUMN `bless_music` VARCHAR(200) NULL COMMENT '祝福语音' AFTER `bless_word`; |
|
775 |
EOF; |
|
776 |
sql_execute($sql); |
|
777 |
}, |
|
778 |
|
|
779 |
'4.2.38' => function () { |
|
780 |
$sql = <<<EOF |
|
781 |
alter table zjhj_bd_goods change app_share_title app_share_title varchar(65) character set utf8mb4 not null default '' comment '自定义分享标题'; |
|
782 |
ALTER TABLE `zjhj_bd_advance_goods` CHARACTER SET = utf8mb4, COLLATE = utf8mb4_general_ci; |
|
783 |
ALTER TABLE `zjhj_bd_advance_goods_attr` CHARACTER SET = utf8mb4, COLLATE = utf8mb4_general_ci; |
|
784 |
CREATE TABLE `zjhj_bd_stock_bonus_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT 0, `bonus_type` tinyint(4) NOT NULL DEFAULT 0 COMMENT '1按周,2按月', `bonus_price` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '分红金额', `bonus_rate` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '当时的分红比例', `order_num` int(11) NOT NULL DEFAULT 0 COMMENT '分红订单数', `stock_num` int(11) NOT NULL DEFAULT 0 COMMENT '当时股东人数', `start_time` timestamp(0) NOT NULL COMMENT '分红时间段-开始时间', `end_time` timestamp(0) NOT NULL COMMENT '分红时间段-结束时间', `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
785 |
CREATE TABLE `zjhj_bd_stock_cash` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号', `price` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '提现金额', `service_charge` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '提现手续费(%)', `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额', `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '额外信息 例如微信账号、支付宝账号等', `status` int(11) NOT NULL DEFAULT 0 COMMENT '提现状态 0--申请 1--同意 2--已打款 3--驳回', `is_delete` int(11) NOT NULL DEFAULT 0, `created_at` datetime(0) NOT NULL, `updated_at` datetime(0) NOT NULL, `deleted_at` datetime(0) NOT NULL, `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '提现记录表' ROW_FORMAT = Dynamic; |
|
786 |
CREATE TABLE `zjhj_bd_stock_cash_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `type` int(11) NOT NULL DEFAULT 1 COMMENT '类型 1--收入 2--支出', `price` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '变动佣金', `desc` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `custom_desc` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `level_id` int(11) NULL DEFAULT 0 COMMENT '当时的股东等级', `level_name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL, `order_num` int(11) NULL DEFAULT 0, `bonus_rate` decimal(10, 2) NULL DEFAULT 0.00 COMMENT '当时的分红比例', `bonus_id` int(11) NULL DEFAULT 0 COMMENT '股东完成分红记录ID', `is_delete` int(11) NOT NULL DEFAULT 0, `created_at` datetime(0) NOT NULL, `updated_at` datetime(0) NOT NULL, `deleted_at` datetime(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '分红日志' ROW_FORMAT = Dynamic; |
|
787 |
CREATE TABLE `zjhj_bd_stock_level` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT 0, `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '等级名称', `bonus_rate` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '分红比例', `condition` int(11) NOT NULL DEFAULT 0 COMMENT '升级条件,0不自动升级', `is_default` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否默认等级,0否1是', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `deleted_at` timestamp(0) NOT NULL, `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '股东等级表' ROW_FORMAT = Dynamic; |
|
788 |
CREATE TABLE `zjhj_bd_stock_level_up` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT 0, `type` tinyint(2) NOT NULL DEFAULT 1 COMMENT '1下线总人数,2累计佣金总额,3已提现佣金总额,4分销订单总数,5分销订单总金额', `remark` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '股东等级升级条件' ROW_FORMAT = Dynamic; |
|
789 |
CREATE TABLE `zjhj_bd_stock_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT 0, `order_id` int(11) NOT NULL DEFAULT 0, `total_pay_price` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '订单实付金额', `is_bonus` tinyint(1) NOT NULL DEFAULT 0 COMMENT '1已分红,0未分红', `bonus_time` timestamp(0) NOT NULL COMMENT '分红时间', `bonus_id` int(11) NOT NULL DEFAULT 0 COMMENT '股东完成分红记录ID', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `deleted_at` timestamp(0) NOT NULL, `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '分红池' ROW_FORMAT = Dynamic; |
|
790 |
CREATE TABLE `zjhj_bd_stock_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `key` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `value` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `created_at` timestamp(0) NOT NULL ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '创建时间', `updated_at` timestamp(0) NOT NULL ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '更新时间', `is_delete` int(11) NOT NULL DEFAULT 0 COMMENT '是否删除 0--未删除 1--已删除', `deleted_at` timestamp(0) NOT NULL ON UPDATE CURRENT_TIMESTAMP(0) COMMENT '删除时间', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '股东分红设置' ROW_FORMAT = Dynamic; |
|
791 |
CREATE TABLE `zjhj_bd_stock_user` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT 0, `user_id` int(11) NOT NULL DEFAULT 0, `level_id` int(11) NOT NULL DEFAULT 0 COMMENT '对应等级表ID', `status` tinyint(1) NOT NULL DEFAULT 0 COMMENT '-2被拒或移除后再次申请没提交 -1移除 0审核中,1同意,2拒绝', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `deleted_at` timestamp(0) NOT NULL, `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, `applyed_at` timestamp(0) NOT NULL COMMENT '申请时间', `agreed_at` timestamp(0) NOT NULL COMMENT '审核时间', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '股东表' ROW_FORMAT = Dynamic; |
|
792 |
CREATE TABLE `zjhj_bd_stock_user_info` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL DEFAULT 0, `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '股东姓名', `phone` varchar(11) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '股东手机号', `all_bonus` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '累计分红', `total_bonus` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '当前分红', `out_bonus` decimal(10, 2) NOT NULL DEFAULT 0.00 COMMENT '已提现分红', `remark` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '备注', `reason` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '拒绝理由', `created_at` timestamp(0) NOT NULL, `updated_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '股东信息表' ROW_FORMAT = Dynamic; |
|
793 |
EOF; |
|
794 |
sql_execute($sql); |
|
795 |
}, |
|
796 |
|
|
797 |
'4.2.39' => function () { |
|
798 |
$sql = <<<EOF |
|
799 |
ALTER TABLE `zjhj_bd_bonus_setting` |
|
800 |
MODIFY COLUMN `updated_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '更新时间' AFTER `created_at`, |
|
801 |
MODIFY COLUMN `deleted_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '删除时间' AFTER `is_delete`; |
|
802 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index2`(`mall_id`, `is_delete`, `cancel_status`); |
|
803 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index3`(`mall_id`, `is_delete`, `cancel_status`, `is_pay`); |
|
804 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index4`(`mall_id`, `is_delete`, `cancel_status`, `pay_type`); |
|
805 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index5`(`mall_id`, `is_delete`, `cancel_status`, `is_pay`, `pay_type`); |
|
806 |
ALTER TABLE `zjhj_bd_order_detail` ADD INDEX `index1`(`goods_id`, `is_refund`, `order_id`); |
|
807 |
EOF; |
|
808 |
sql_execute($sql); |
|
809 |
}, |
|
810 |
|
|
811 |
'4.2.40' => function () { |
|
812 |
$sql = <<<EOF |
|
813 |
alter table zjhj_bd_store add `is_all_day` tinyint(1) not null default 0 comment '是否全天营业0.否|1.是'; |
|
814 |
EOF; |
|
815 |
sql_execute($sql); |
|
816 |
}, |
|
817 |
|
|
818 |
'4.2.42' => function () { |
|
819 |
$sql = <<<EOF |
|
820 |
ALTER TABLE `zjhj_bd_stock_bonus_log` MODIFY COLUMN `start_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间段-开始时间' AFTER `stock_num`, MODIFY COLUMN `end_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间段-结束时间' AFTER `start_time`; |
|
821 |
ALTER TABLE `zjhj_bd_stock_order` MODIFY COLUMN `bonus_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间' AFTER `is_bonus`; |
|
822 |
CREATE TABLE `zjhj_bd_order_send_template` ( `id` INT ( 11 ) UNSIGNED NOT NULL AUTO_INCREMENT, `mall_id` INT ( 11 ) NOT NULL, `mch_id` INT ( 11 ) NOT NULL DEFAULT '0', `name` VARCHAR ( 60 ) NOT NULL DEFAULT '' COMMENT '发货单名称', `cover_pic` VARCHAR ( 255 ) NOT NULL DEFAULT '' COMMENT '缩略图', `params` text NOT NULL COMMENT '模板参数', `is_default` TINYINT ( 1 ) NOT NULL DEFAULT '0' COMMENT '是否为默认模板0.否|1.是', `created_at` TIMESTAMP NOT NULL, `updated_at` TIMESTAMP NOT NULL, `deleted_at` TIMESTAMP NOT NULL, `is_delete` TINYINT ( 1 ) NOT NULL DEFAULT '0', PRIMARY KEY ( `id` ) ) ENGINE = INNODB DEFAULT CHARSET = utf8mb4; |
|
823 |
CREATE TABLE `zjhj_bd_order_send_template_address` ( `id` INT ( 11 ) UNSIGNED NOT NULL AUTO_INCREMENT, `mall_id` INT ( 11 ) NOT NULL, `mch_id` INT ( 11 ) NOT NULL, `name` VARCHAR ( 60 ) NOT NULL DEFAULT '' COMMENT '网点名称', `username` VARCHAR ( 60 ) NOT NULL DEFAULT '' COMMENT '联系人', `mobile` VARCHAR ( 60 ) NOT NULL DEFAULT '' COMMENT '联系电话', `code` VARCHAR ( 60 ) NOT NULL DEFAULT '' COMMENT '网点邮编', `address` VARCHAR ( 255 ) NOT NULL DEFAULT '' COMMENT '地址', `created_at` TIMESTAMP NOT NULL, `updated_at` TIMESTAMP NOT NULL, `deleted_at` TIMESTAMP NOT NULL, `is_delete` TINYINT ( 1 ) NOT NULL DEFAULT '0', PRIMARY KEY ( `id` ) ) ENGINE = INNODB DEFAULT CHARSET = utf8mb4; |
|
824 |
EOF; |
|
825 |
sql_execute($sql); |
|
826 |
}, |
|
827 |
|
|
828 |
'4.2.43' => function () { |
|
829 |
}, |
|
830 |
|
|
831 |
'4.2.45' => function () { |
|
832 |
}, |
|
833 |
|
|
834 |
'4.2.46' => function () { |
|
835 |
$sql = <<<EOF |
|
836 |
ALTER TABLE `zjhj_bd_gift_log` CHARSET=utf8mb4; |
|
837 |
ALTER TABLE `zjhj_bd_gift_log` MODIFY COLUMN `bless_word` varchar(200) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '祝福语' AFTER `open_type`; |
|
838 |
EOF; |
|
839 |
sql_execute($sql); |
|
840 |
}, |
|
841 |
|
|
842 |
'4.2.47' => function () { |
|
843 |
}, |
|
844 |
|
|
845 |
'4.2.48' => function () { |
|
846 |
$sql = <<<EOF |
|
847 |
ALTER TABLE `zjhj_bd_printer_setting` ADD COLUMN `big` int(11) NOT NULL DEFAULT 0 COMMENT '放大倍数' AFTER `deleted_at`, ADD COLUMN `show_type` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '打印参数 attr 规格 goods_no 货号 form_data 下单表单' AFTER `big`; |
|
848 |
EOF; |
|
849 |
sql_execute($sql); |
|
850 |
}, |
|
851 |
|
|
852 |
'4.2.50' => function () { |
|
853 |
$sql = <<<EOF |
|
854 |
alter table zjhj_bd_step_setting add `share_pic` varchar(255) not null default '' comment '分享图片'; |
|
855 |
alter table zjhj_bd_user_info add `remark_name` varchar(60) not null default '' comment '备注名'; |
|
856 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `sales` int(11) NOT NULL DEFAULT 0 COMMENT '商品实际销量'; |
|
857 |
ALTER TABLE `zjhj_bd_mail_setting` ADD COLUMN `show_type` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT 'attr 规格 goods_no 货号 form_data 下单表单' AFTER `deleted_at`; |
|
858 |
ALTER TABLE `zjhj_bd_step_ad` ADD COLUMN `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '流量主类型' AFTER `deleted_at`, ADD COLUMN `pic_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '广告封面' AFTER `type`, ADD COLUMN `video_url` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '广告视频' AFTER `pic_url`, ADD COLUMN `reward_data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '奖励数据' AFTER `video_url`; |
|
859 |
CREATE TABLE `zjhj_bd_step_ad_coupon` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `user_coupon_id` int(11) NOT NULL, `is_delete` tinyint(2) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
860 |
CREATE TABLE `zjhj_bd_diy_ad_coupon` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `user_coupon_id` int(11) NOT NULL, `is_delete` tinyint(2) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
861 |
CREATE TABLE `zjhj_bd_diy_ad_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `template_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `raffled_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
862 |
CREATE TABLE `zjhj_bd_step_ad_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `ad_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `raffled_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
863 |
CREATE TABLE `zjhj_bd_pick_activity` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `status` int(11) NOT NULL DEFAULT '0' COMMENT '状态 0下架 1上架', `is_delete` tinyint(4) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `title` varchar(255) NOT NULL DEFAULT '' COMMENT '活动标题', `start_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动开始时间', `end_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动结束时间', `rule_price` decimal(10,2) NOT NULL COMMENT '组合方案 元', `rule_num` int(11) NOT NULL COMMENT '组合方案 件', `is_area_limit` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否单独区域购买', `area_limit` longtext NOT NULL, PRIMARY KEY (`id`) USING BTREE, KEY `idx_1` (`mall_id`,`is_delete`,`created_at`), KEY `sort` (`start_at`,`end_at`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='N元任选活动'; |
|
864 |
CREATE TABLE `zjhj_bd_pick_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `status` tinyint(1) NOT NULL COMMENT '状态 0 关闭 1开启', `goods_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `pick_activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动id', `stock` int(11) NOT NULL COMMENT '总库存', `sort` int(11) NOT NULL DEFAULT '100' COMMENT '排序', PRIMARY KEY (`id`) USING BTREE, KEY `activity` (`pick_activity_id`) USING BTREE, KEY `goods_id` (`goods_id`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='N元任选商品'; |
|
865 |
CREATE TABLE `zjhj_bd_pick_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `key` varchar(255) NOT NULL, `value` text NOT NULL, `created_at` timestamp NOT NULL COMMENT '创建时间', `updated_at` timestamp NOT NULL COMMENT '更新时间', `is_delete` int(11) NOT NULL DEFAULT '0' COMMENT '是否删除 0--未删除 1--已删除', `deleted_at` timestamp NOT NULL COMMENT '删除时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='N元任选设置'; |
|
866 |
CREATE TABLE `zjhj_bd_pick_cart` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL COMMENT '商品', `attr_id` int(11) NOT NULL COMMENT '商品规格', `num` int(11) NOT NULL DEFAULT '1' COMMENT '商品数量', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `attr_info` text, `pick_activity_id` int(11) NOT NULL COMMENT '活动id', PRIMARY KEY (`id`), KEY `mall_id` (`mall_id`), KEY `user_id` (`user_id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
867 |
|
|
868 |
ALTER TABLE `zjhj_bd_user_identity` ADD INDEX `is_super_admin`(`is_super_admin`); |
|
869 |
ALTER TABLE `zjhj_bd_admin_info` ADD INDEX `user_id`(`user_id`); |
|
870 |
ALTER TABLE `zjhj_bd_admin_info` ADD INDEX `is_delete`(`is_delete`); |
|
871 |
ALTER TABLE `zjhj_bd_favorite` ADD INDEX `user_id`(`user_id`); |
|
872 |
ALTER TABLE `zjhj_bd_favorite` ADD INDEX `is_delete`(`is_delete`); |
|
873 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `status`(`status`); |
|
874 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `is_delete`(`is_delete`); |
|
875 |
ALTER TABLE `zjhj_bd_footprint_goods_log` ADD INDEX `user_id`(`user_id`); |
|
876 |
ALTER TABLE `zjhj_bd_footprint_goods_log` ADD INDEX `is_delete`(`is_delete`); |
|
877 |
ALTER TABLE `zjhj_bd_qr_code_parameter` ADD INDEX `mall_id`(`mall_id`); |
|
878 |
ALTER TABLE `zjhj_bd_qr_code_parameter` ADD INDEX `token`(`token`); |
|
879 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `mall_id`(`mall_id`); |
|
880 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `is_delete`(`is_delete`); |
|
881 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `type`(`type`); |
|
882 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `mch_id`(`mch_id`); |
|
883 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `is_recycle`(`is_recycle`); |
|
884 |
ALTER TABLE `zjhj_bd_attachment` ADD INDEX `attachment_group_id`(`attachment_group_id`); |
|
885 |
ALTER TABLE `zjhj_bd_diy_page` ADD INDEX `is_delete`(`is_delete`); |
|
886 |
ALTER TABLE `zjhj_bd_diy_page` ADD INDEX `mall_id`(`mall_id`); |
|
887 |
ALTER TABLE `zjhj_bd_diy_page` ADD INDEX `is_disable`(`is_disable`); |
|
888 |
ALTER TABLE `zjhj_bd_vip_card` ADD INDEX `mall_id`(`mall_id`); |
|
889 |
ALTER TABLE `zjhj_bd_vip_card` ADD INDEX `is_delete`(`is_delete`); |
|
890 |
ALTER TABLE `zjhj_bd_city_delivery_setting` ADD INDEX `key`(`key`); |
|
891 |
ALTER TABLE `zjhj_bd_city_delivery_setting` ADD INDEX `is_delete`(`is_delete`); |
|
892 |
ALTER TABLE `zjhj_bd_city_delivery_setting` ADD INDEX `mall_id`(`mall_id`); |
|
893 |
ALTER TABLE `zjhj_bd_wxapp_config` ADD INDEX `mall_id`(`mall_id`); |
|
894 |
ALTER TABLE `zjhj_bd_bargain_goods` ADD INDEX `mall_id`(`mall_id`); |
|
895 |
ALTER TABLE `zjhj_bd_bargain_goods` ADD INDEX `is_delete`(`is_delete`); |
|
896 |
ALTER TABLE `zjhj_bd_bargain_goods` ADD INDEX `end_time`(`end_time`); |
|
897 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `sort`(`sort`); |
|
898 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `created_at`(`created_at`); |
|
899 |
ALTER TABLE `zjhj_bd_goods_warehouse` ADD INDEX `mall_id`(`mall_id`); |
|
900 |
ALTER TABLE `zjhj_bd_goods_warehouse` ADD INDEX `is_delete`(`is_delete`); |
|
901 |
ALTER TABLE `zjhj_bd_goods` ADD INDEX `sales`(`sales`); |
|
902 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `mall_id`(`mall_id`); |
|
903 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `mch_id`(`mch_id`); |
|
904 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `user_id`(`user_id`); |
|
905 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `order_id`(`order_id`); |
|
906 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `order_detail_id`(`order_detail_id`); |
|
907 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `order_no`(`order_no`); |
|
908 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `type`(`type`); |
|
909 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `status`(`status`); |
|
910 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `is_send`(`is_send`); |
|
911 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `is_confirm`(`is_confirm`); |
|
912 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `is_refund`(`is_refund`); |
|
913 |
ALTER TABLE `zjhj_bd_order_refund` ADD INDEX `is_delete`(`is_delete`); |
|
914 |
EOF; |
|
915 |
sql_execute($sql); |
|
916 |
}, |
|
917 |
|
|
918 |
'4.2.53' => function () { |
|
919 |
$sql = <<<EOF |
|
920 |
ALTER TABLE `zjhj_bd_goods` MODIFY COLUMN `area_limit` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '区域限制' AFTER `is_area_limit`; |
|
921 |
EOF; |
|
922 |
sql_execute($sql); |
|
923 |
}, |
|
924 |
|
|
925 |
'4.2.54' => function () { |
|
926 |
$sql = <<<EOF |
|
927 |
ALTER TABLE `zjhj_bd_vip_card_user` MODIFY COLUMN `all_send` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '所有赠送信息' AFTER `image_name`; |
|
928 |
EOF; |
|
929 |
sql_execute($sql); |
|
930 |
}, |
|
931 |
|
|
932 |
'4.2.55' => function () { |
|
933 |
$sql = <<<EOF |
|
934 |
alter table `zjhj_bd_goods_cards` add `number` int(11) not null default 1 comment '卡券可核销总次数'; |
|
935 |
alter table `zjhj_bd_user_card` add `use_number` int(11) not null default 0 comment '卡券已核销次数'; |
|
936 |
alter table `zjhj_bd_user_card` add `number` int(11) not null default 1 comment '卡券可核销次数'; |
|
937 |
update `zjhj_bd_order` set pay_type = 1 where pay_type = 4 or pay_type = 5 or pay_type = 6; |
|
938 |
ALTER TABLE `zjhj_bd_mall_setting` MODIFY COLUMN `value` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `key`; |
|
939 |
CREATE TABLE `zjhj_bd_goods_card_clerk_log` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `user_card_id` int(11) NOT NULL COMMENT '用户卡券ID', `clerk_id` int(11) NOT NULL COMMENT '核销员ID', `store_id` int(11) NOT NULL COMMENT '核销门店ID', `use_number` int(11) NOT NULL COMMENT '核销次数', `surplus_number` int(11) NOT NULL COMMENT '剩余次数', `clerked_at` timestamp NOT NULL COMMENT '核销时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
940 |
EOF; |
|
941 |
sql_execute($sql); |
|
942 |
}, |
|
943 |
|
|
944 |
'4.2.56' => function () { |
|
945 |
}, |
|
946 |
|
|
947 |
'4.2.57' => function () { |
|
948 |
}, |
|
949 |
|
|
950 |
'4.2.58' => function () { |
|
951 |
$sql = <<<EOF |
|
952 |
alter table `zjhj_bd_import_goods` rename to `zjhj_bd_import_data`; |
|
953 |
alter table `zjhj_bd_import_data` change `goods_count` `count` int(11) not null comment '导入总数量'; |
|
954 |
alter table `zjhj_bd_import_data` add `type` tinyint(1) not null default 1 comment '1.商品导入|2.分类导入'; |
|
955 |
alter table `zjhj_bd_home_nav` add `sign` varchar(65) not null default '' comment '插件标识'; |
|
956 |
alter table `zjhj_bd_banner` add `sign` varchar(65) not null default '' comment '插件标识'; |
|
957 |
ALTER TABLE `zjhj_bd_order` MODIFY COLUMN `send_type` tinyint(1) NOT NULL DEFAULT 0 COMMENT '配送方式:0--快递配送 1--到店自提 2--同城配送 3--无配送' AFTER `is_recycle`; |
|
958 |
CREATE TABLE `zjhj_bd_goods_attr_template` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT 0, `attr_group_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '规格名', `attr_group_id` int(11) NOT NULL DEFAULT 0 COMMENT '规格组', `attr_list` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '规格值', `select_attr_list` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '后台 搜索用的', `is_delete` tinyint(1) NOT NULL DEFAULT 0 COMMENT '删除', `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
959 |
CREATE TABLE `zjhj_bd_composition` ( `id` int(11) NOT NULL AUTO_INCREMENT COMMENT ' ', `mall_id` int(11) NOT NULL, `name` varchar(255) NOT NULL DEFAULT '' COMMENT '套餐名', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '套餐价', `type` tinyint(255) NOT NULL DEFAULT '1' COMMENT '套餐类型 1--固定套餐 2--搭配套餐', `status` int(11) NOT NULL DEFAULT '0' COMMENT '是否上架 0--下架 1--上架', `sort` int(11) NOT NULL DEFAULT '100' COMMENT '排序', `is_delete` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `sort_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '排序的优惠金额', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='套餐表'; |
|
960 |
CREATE TABLE `zjhj_bd_composition_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `model_id` int(11) NOT NULL COMMENT '套餐id', `goods_id` int(11) NOT NULL COMMENT '商品id', `is_host` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否是主商品', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '优惠金额', `payment_people` int(11) NOT NULL DEFAULT '0' COMMENT '支付人数', `payment_num` int(11) NOT NULL DEFAULT '0' COMMENT '支付件数', `payment_amount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '支付金额', `created_at` timestamp NOT NULL, PRIMARY KEY (`id`), KEY `mall_id` (`mall_id`) USING BTREE, KEY `model_id` (`model_id`) USING BTREE, KEY `goods_id` (`goods_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
961 |
CREATE TABLE `zjhj_bd_composition_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `composition_id` int(11) NOT NULL DEFAULT '0' COMMENT '优惠金额', `price` decimal(10,2) NOT NULL, `is_delete` tinyint(1) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
962 |
EOF; |
|
963 |
sql_execute($sql); |
|
964 |
}, |
|
965 |
|
|
966 |
'4.2.59' => function () { |
|
967 |
}, |
|
968 |
|
|
969 |
'4.2.60' => function () { |
|
970 |
}, |
|
971 |
|
|
972 |
'4.2.61' => function () { |
|
973 |
$sql = <<<EOF |
|
974 |
ALTER TABLE `zjhj_bd_goods_member_price` ADD INDEX `is_delete`(`is_delete`); |
|
975 |
ALTER TABLE `zjhj_bd_form` ADD INDEX `mall_id`(`mall_id`); |
|
976 |
ALTER TABLE `zjhj_bd_form` ADD INDEX `mch_id`(`mch_id`); |
|
977 |
ALTER TABLE `zjhj_bd_form` ADD INDEX `is_default`(`is_default`); |
|
978 |
ALTER TABLE `zjhj_bd_form` ADD INDEX `status`(`status`); |
|
979 |
ALTER TABLE `zjhj_bd_form` ADD INDEX `is_delete`(`is_delete`); |
|
980 |
ALTER TABLE `zjhj_bd_wxapp_subscribe` ADD INDEX `mall_id`(`mall_id`); |
|
981 |
ALTER TABLE `zjhj_bd_mall_members` ADD INDEX `level`(`level`); |
|
982 |
ALTER TABLE `zjhj_bd_mall_members` ADD INDEX `mall_id`(`mall_id`); |
|
983 |
ALTER TABLE `zjhj_bd_mall_members` ADD INDEX `is_delete`(`is_delete`); |
|
984 |
ALTER TABLE `zjhj_bd_vip_card_discount` ADD INDEX `order_id`(`order_id`); |
|
985 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `mch_id`(`mch_id`); |
|
986 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `is_delete`(`is_delete`); |
|
987 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `mall_id`(`mall_id`); |
|
988 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `status`(`status`); |
|
989 |
ALTER TABLE `zjhj_bd_printer_setting` ADD INDEX `store_id`(`store_id`); |
|
990 |
ALTER TABLE `zjhj_bd_goods_attr` ADD INDEX `index1`(`is_delete`, `goods_id`); |
|
991 |
ALTER TABLE `zjhj_bd_order_comments` ADD INDEX `order_id`(`order_id`); |
|
992 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index2`(`mall_id`,`is_delete`,`user_id`,`is_confirm`,`is_sale`,`sale_status`,`cancel_status`,`is_recycle`); |
|
993 |
ALTER TABLE `zjhj_bd_order` ADD INDEX `index3`(`mall_id`,`is_delete`,`user_id`,`is_send`,`pay_type`,`is_pay`,`cancel_status`,`is_recycle`); |
|
994 |
ALTER TABLE `zjhj_bd_vip_card_appoint_goods` ADD INDEX `goods_id`(`goods_id`); |
|
995 |
ALTER TABLE `zjhj_bd_vip_card_setting` ADD INDEX `mall_id`(`mall_id`); |
|
996 |
ALTER TABLE `zjhj_bd_vip_card_setting` ADD INDEX `is_delete`(`is_delete`); |
|
997 |
EOF; |
|
998 |
sql_execute($sql); |
|
999 |
}, |
|
1000 |
|
|
1001 |
'4.2.62' => function () { |
|
1002 |
}, |
|
1003 |
|
|
1004 |
'4.2.63' => function () { |
|
1005 |
}, |
|
1006 |
|
|
1007 |
'4.2.64' => function () { |
|
1008 |
}, |
|
1009 |
|
|
1010 |
'4.2.65' => function () { |
|
1011 |
}, |
|
1012 |
|
|
1013 |
'4.2.68' => function () { |
|
1014 |
}, |
|
1015 |
|
|
1016 |
'4.2.69' => function () { |
|
1017 |
}, |
|
1018 |
|
|
1019 |
'4.2.70' => function () { |
|
1020 |
$sql = <<<EOF |
|
1021 |
ALTER TABLE `zjhj_bd_pintuan_goods` ADD `start_time` TIMESTAMP NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动开始日期'; |
|
1022 |
ALTER TABLE `zjhj_bd_pintuan_goods` ADD `is_auto_add_robot` TINYINT ( 1 ) NOT NULL DEFAULT '0' COMMENT '是否自动添加机器人0.否|1.是'; |
|
1023 |
ALTER TABLE `zjhj_bd_pintuan_goods` ADD `add_robot_time` INT ( 11 ) NOT NULL DEFAULT '0' COMMENT '机器人参与时间0.表示不添加'; |
|
1024 |
ALTER TABLE `zjhj_bd_pintuan_goods` ADD `pintuan_goods_id` INT ( 11 ) NOT NULL DEFAULT '0' COMMENT '是否为同一组'; |
|
1025 |
CREATE TABLE `zjhj_bd_miaosha_activitys` ( `id` INT ( 11 ) UNSIGNED NOT NULL AUTO_INCREMENT, `mall_id` INT ( 11 ) NOT NULL, `status` TINYINT ( 1 ) NOT NULL DEFAULT '0' COMMENT '秒杀活动状态0.关闭|1.开启', `open_date` date NOT NULL DEFAULT '0000-00-00' COMMENT '活动开始时间', `end_date` date NOT NULL DEFAULT '0000-00-00' COMMENT '活动结束时间', `created_at` TIMESTAMP NOT NULL, `updated_at` TIMESTAMP NOT NULL, `deleted_at` TIMESTAMP NOT NULL, `is_delete` TINYINT ( 1 ) NOT NULL DEFAULT '0', PRIMARY KEY ( `id` ) ) ENGINE = INNODB DEFAULT CHARSET = utf8mb4; |
|
1026 |
ALTER TABLE `zjhj_bd_miaosha_goods` ADD `activity_id` INT ( 11 ) NOT NULL DEFAULT '0' COMMENT '活动ID'; |
|
1027 |
ALTER TABLE `zjhj_bd_booking_goods` ADD `is_order_form` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '是否开启自定义表单0.否|1.是'; |
|
1028 |
ALTER TABLE `zjhj_bd_booking_goods` ADD `order_form_type` TINYINT ( 1 ) NOT NULL DEFAULT 1 COMMENT '1.选择表单|2.自定义表单'; |
|
1029 |
ALTER TABLE `zjhj_bd_bargain_goods` ADD COLUMN `stock_type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '减库存的方式 1--参与减库存 2--拍下减库存'; |
|
1030 |
ALTER TABLE `zjhj_bd_fxhb_activity` ADD COLUMN `is_home_model` tinyint(1) NOT NULL DEFAULT 0 COMMENT '首页弹窗开关' AFTER `name`; |
|
1031 |
ALTER TABLE `zjhj_bd_qr_code_parameter` ADD `use_number` INT ( 11 ) NOT NULL DEFAULT 0 COMMENT '使用次数'; |
|
1032 |
EOF; |
|
1033 |
sql_execute($sql); |
|
1034 |
}, |
|
1035 |
|
|
1036 |
'4.2.74' => function () { |
|
1037 |
$sql = <<<EOF |
|
1038 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD COLUMN `app_version` VARCHAR ( 32 ) NOT NULL DEFAULT '' COMMENT '小程序端版本'; |
|
1039 |
EOF; |
|
1040 |
sql_execute($sql); |
|
1041 |
}, |
|
1042 |
|
|
1043 |
'4.2.76' => function () { |
|
1044 |
$sql = <<<EOF |
|
1045 |
CREATE TABLE `zjhj_bd_order_vip_card_info` ( `id` int(11) NOT NULL AUTO_INCREMENT, `order_id` int(11) NOT NULL COMMENT '订单ID', `vip_card_detail_id` int(11) NOT NULL COMMENT '超级会员卡子卡ID', `order_total_price` decimal(10,2) NOT NULL COMMENT '超级会员卡优惠后订单的金额', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1046 |
ALTER TABLE `zjhj_bd_bargain_order` ADD COLUMN `preferential_price` decimal(10,2) NOT NULL DEFAULT 0 COMMENT '优惠金额'; |
|
1047 |
ALTER TABLE `zjhj_bd_address` MODIFY COLUMN `province_id` int(11) NOT NULL DEFAULT 0 AFTER `name`, MODIFY COLUMN `province` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '省份名称' AFTER `province_id`, MODIFY COLUMN `city_id` int(11) NOT NULL DEFAULT 0 AFTER `province`, MODIFY COLUMN `city` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '城市名称' AFTER `city_id`, MODIFY COLUMN `district_id` int(11) NOT NULL DEFAULT 0 AFTER `city`, MODIFY COLUMN `district` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '县区名称' AFTER `district_id`; |
|
1048 |
ALTER TABLE `zjhj_bd_address` ADD COLUMN `type` tinyint(1) NOT NULL DEFAULT 0 COMMENT '类型:0快递 1同城' AFTER `location`; |
|
1049 |
CREATE TABLE `zjhj_bd_assistant_data` ( `id` int(11) NOT NULL AUTO_INCREMENT, `type` tinyint(1) NOT NULL DEFAULT '0' COMMENT '类型 0--淘宝 1--淘宝app 2--天猫 3--天猫app 4--京东 5--拼多多', `itemId` varchar(255) NOT NULL DEFAULT '0' COMMENT '原始商品id', `json` longtext NOT NULL COMMENT '数据', `created_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='采集助手数据存储'; |
|
1050 |
CREATE TABLE `zjhj_bd_order_detail_vip_card_info` ( `id` int(11) NOT NULL AUTO_INCREMENT, `vip_card_order_id` int(11) NOT NULL, `order_detail_id` int(11) NOT NULL, `order_detail_total_price` decimal(10,2) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1051 |
EOF; |
|
1052 |
sql_execute($sql); |
|
1053 |
}, |
|
1054 |
|
|
1055 |
'4.2.81' => function () { |
|
1056 |
$sql = <<<EOF |
|
1057 |
ALTER TABLE `zjhj_bd_order` ADD `cancel_data` text COMMENT '订单申请退款数据'; |
|
1058 |
ALTER TABLE `zjhj_bd_order_refund` ADD `mobile` VARCHAR ( 255 ) NOT NULL DEFAULT '' COMMENT '联系方式'; |
|
1059 |
ALTER TABLE `zjhj_bd_order_refund` ADD `refund_data` text NOT NULL COMMENT '售后数据'; |
|
1060 |
ALTER TABLE `zjhj_bd_share_order` ADD COLUMN `price` DECIMAL ( 10, 2 ) NOT NULL DEFAULT 0 COMMENT '用于分销的金额', ADD COLUMN `first_share_type` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '一级分销的分销类型', ADD COLUMN `first_share_price` DECIMAL ( 10, 2 ) NOT NULL DEFAULT 0 COMMENT '一级佣金', ADD COLUMN `second_share_type` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '二级分销的分销类型', ADD COLUMN `second_share_price` DECIMAL ( 10, 2 ) NOT NULL DEFAULT 0 COMMENT '二级佣金', ADD COLUMN `third_share_type` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '三级分销的分销类型', ADD COLUMN `third_share_price` DECIMAL ( 10, 2 ) NOT NULL DEFAULT 0 COMMENT '三级佣金', ADD COLUMN `flag` TINYINT ( 1 ) NOT NULL DEFAULT 0 COMMENT '修改记录 0--售后优化之前的分销订单 1--售后优化之后的订单'; |
|
1061 |
EOF; |
|
1062 |
sql_execute($sql); |
|
1063 |
}, |
|
1064 |
|
|
1065 |
'4.2.83' => function () { |
|
1066 |
$sql = <<<EOF |
|
1067 |
ALTER TABLE `zjhj_bd_goods_warehouse` ADD COLUMN `type` varchar(255) NOT NULL DEFAULT 'goods' COMMENT '商品类型:goods--实体商品 ecard--电子卡密', ADD COLUMN `ecard_id` int NOT NULL DEFAULT 0 COMMENT '卡密id'; |
|
1068 |
ALTER TABLE `zjhj_bd_scratch_log` ADD COLUMN `token` varchar(255) NOT NULL DEFAULT '' COMMENT '订单表token'; |
|
1069 |
ALTER TABLE `zjhj_bd_pond_log` ADD COLUMN `token` varchar(255) NOT NULL DEFAULT '' COMMENT '订单表token'; |
|
1070 |
ALTER TABLE `zjhj_bd_lottery_log` ADD COLUMN `token` varchar(255) NOT NULL DEFAULT '' COMMENT '订单表token'; |
|
1071 |
CREATE TABLE `zjhj_bd_ecard` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(255) NOT NULL DEFAULT '' COMMENT '卡密名称', `content` longtext COMMENT '使用说明', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `list` longtext NOT NULL COMMENT '卡密字段', `sales` int(11) NOT NULL DEFAULT '0' COMMENT '已售', `stock` int(11) NOT NULL DEFAULT '0' COMMENT '库存', `is_unique` tinyint(1) NOT NULL DEFAULT '1' COMMENT '是否去重 0--否 1--是', `pre_stock` int(11) NOT NULL DEFAULT '0' COMMENT '预占用的库存', `total_stock` int(11) NOT NULL DEFAULT '0' COMMENT '总库存', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='电子卡密'; |
|
1072 |
CREATE TABLE `zjhj_bd_ecard_data` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `ecard_id` int(11) NOT NULL, `token` varchar(255) NOT NULL, `key` varchar(255) NOT NULL, `value` longtext NOT NULL, `is_delete` tinyint(1) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1073 |
CREATE TABLE `zjhj_bd_ecard_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `ecard_id` int(11) NOT NULL DEFAULT '0', `status` varchar(255) NOT NULL DEFAULT '' COMMENT '日志操作 add--添加 occupy--占用 sales--卖出 delete--删除', `sign` varchar(255) NOT NULL DEFAULT '' COMMENT '插件标示', `number` int(11) NOT NULL DEFAULT '0' COMMENT '数量', `created_at` timestamp NOT NULL, `goods_id` int(11) NOT NULL DEFAULT '0' COMMENT '商品id', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1074 |
CREATE TABLE `zjhj_bd_ecard_options` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `token` varchar(255) NOT NULL DEFAULT '' COMMENT '加密字符串', `ecard_id` int(11) NOT NULL DEFAULT '0' COMMENT '电子卡密id', `value` longtext NOT NULL COMMENT '卡密字段值', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否删除', `is_sales` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否出售', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_occupy` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否被占用 0--否 1--是', PRIMARY KEY (`id`), KEY `e_card_id` (`ecard_id`), KEY `token` (`token`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='电子卡密数据'; |
|
1075 |
CREATE TABLE `zjhj_bd_ecard_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `ecard_id` int(11) NOT NULL, `value` longtext NOT NULL, `order_id` int(11) NOT NULL, `order_detail_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL, `token` varchar(255) NOT NULL DEFAULT '' COMMENT '加密字符串', `ecard_options_id` int(11) NOT NULL, `user_id` int(11) NOT NULL DEFAULT '0' COMMENT '用户id', `order_token` varchar(255) NOT NULL DEFAULT '' COMMENT '订单token', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='卡密订单列表'; |
|
1076 |
ALTER TABLE `zjhj_bd_order_detail` ADD COLUMN `goods_type` VARCHAR ( 255 ) NOT NULL DEFAULT 'goods' COMMENT '商品类型'; |
|
1077 |
EOF; |
|
1078 |
sql_execute($sql); |
|
1079 |
}, |
|
1080 |
|
|
1081 |
'4.2.84' => function () { |
|
1082 |
$sql = <<<EOF |
|
1083 |
CREATE TABLE `zjhj_bd_ecard_options` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `token` varchar(255) NOT NULL DEFAULT '' COMMENT '加密字符串', `ecard_id` int(11) NOT NULL DEFAULT '0' COMMENT '电子卡密id', `value` longtext NOT NULL COMMENT '卡密字段值', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否删除', `is_sales` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否出售', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_occupy` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否被占用 0--否 1--是', PRIMARY KEY (`id`), KEY `e_card_id` (`ecard_id`), KEY `token` (`token`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='电子卡密数据'; |
|
1084 |
EOF; |
|
1085 |
sql_execute($sql); |
|
1086 |
}, |
|
1087 |
|
|
1088 |
'4.2.85' => function () { |
|
1089 |
$sql = <<<EOF |
|
1090 |
CREATE TABLE `zjhj_bd_ecard_options` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `token` varchar(70) NOT NULL DEFAULT '' COMMENT '加密字符串', `ecard_id` int(11) NOT NULL DEFAULT '0' COMMENT '电子卡密id', `value` longtext NOT NULL COMMENT '卡密字段值', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否删除', `is_sales` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否出售', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_occupy` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否被占用 0--否 1--是', PRIMARY KEY (`id`), KEY `e_card_id` (`ecard_id`), KEY `token` (`token`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='电子卡密数据'; |
|
1091 |
EOF; |
|
1092 |
sql_execute($sql); |
|
1093 |
}, |
|
1094 |
|
|
1095 |
'4.2.90' => function () { |
|
1096 |
$sql = <<<EOF |
|
1097 |
ALTER TABLE `zjhj_bd_diy_template` ADD COLUMN `type` VARCHAR ( 100 ) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT 'page:微页面' AFTER `deleted_at`; |
|
1098 |
CREATE TABLE `zjhj_bd_diy_coupon_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `template_id` int(11) NOT NULL, `user_coupon_id` int(11) NOT NULL, `is_delete` tinyint(2) NOT NULL DEFAULT 0 COMMENT '删除', `created_at` timestamp(0) NOT NULL, `deleted_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1099 |
ALTER TABLE `zjhj_bd_delivery` ADD COLUMN `goods_alias` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '商品' COMMENT '自定义商品别名' AFTER `deleted_at`, ADD COLUMN `is_goods_alias` tinyint(1) NOT NULL DEFAULT 0 COMMENT '自定义商品别名开关' AFTER `goods_alias`; |
|
1100 |
EOF; |
|
1101 |
sql_execute($sql); |
|
1102 |
}, |
|
1103 |
|
|
1104 |
'4.2.98' => function () { |
|
1105 |
$sql = <<<EOF |
|
1106 |
ALTER TABLE `zjhj_bd_mch_cash` ADD COLUMN `content` longtext NULL COMMENT '备注' AFTER `is_delete`; |
|
1107 |
CREATE TABLE `zjhj_bd_region_area` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(100) NOT NULL DEFAULT '' COMMENT '区域名称', `province_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '省代理分红比例', `city_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '市代理分红比例', `district_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '区/县分红比例', `province_condition` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '省代理条件', `city_condition` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '市代理条件', `district_condition` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '区/县代理条件', `become_type` tinyint(2) NOT NULL DEFAULT '0' COMMENT '1:下线总人数\r\n2:分销订单总数\r\n3:分销订单总金额\r\n4:累计佣金总额\r\n5:已提现佣金总额\r\n6:消费金额', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`), KEY `index_1` (`mall_id`,`is_delete`,`created_at`), KEY `created_at` (`created_at`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='区域区域表'; |
|
1108 |
CREATE TABLE `zjhj_bd_region_area_detail` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `area_id` int(11) NOT NULL COMMENT '区域id', `province_id` int(2) NOT NULL COMMENT '省id', `is_delete` tinyint(2) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), KEY `area_id` (`area_id`), KEY `index_1` (`mall_id`,`area_id`,`is_delete`), KEY `created_at` (`created_at`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='代理区域详情表'; |
|
1109 |
CREATE TABLE `zjhj_bd_region_bonus_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `bonus_type` tinyint(4) NOT NULL DEFAULT '0' COMMENT '1按周,2按月', `pre_bonus_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '预计分红金额', `bonus_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '分红金额', `bonus_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '当时的分红比例', `pre_order_num` int(11) NOT NULL DEFAULT '0' COMMENT '预计分红订单数', `order_num` int(11) NOT NULL DEFAULT '0' COMMENT '分红订单数', `region_num` int(11) NOT NULL DEFAULT '0' COMMENT '当时区域人数', `start_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间段-开始时间', `end_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间段-结束时间', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1110 |
CREATE TABLE `zjhj_bd_region_cash` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `order_no` varchar(255) NOT NULL DEFAULT '' COMMENT '订单号', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '提现金额', `service_charge` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '提现手续费(%)', `type` varchar(255) NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额', `extra` longtext NOT NULL COMMENT '额外信息 例如微信账号、支付宝账号等', `status` int(11) NOT NULL DEFAULT '0' COMMENT '提现状态 0--申请 1--同意 2--已打款 3--驳回', `is_delete` int(11) NOT NULL DEFAULT '0', `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL, `deleted_at` datetime NOT NULL, `content` longtext, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='提现记录表'; |
|
1111 |
CREATE TABLE `zjhj_bd_region_cash_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `type` int(11) NOT NULL DEFAULT '1' COMMENT '类型 1--收入 2--支出', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '变动佣金', `desc` longtext, `custom_desc` longtext, `level_id` int(11) NOT NULL DEFAULT '0' COMMENT '当时的区域等级', `level_name` varchar(100) NOT NULL DEFAULT '', `order_num` int(11) NOT NULL DEFAULT '0', `bonus_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '当时的分红比例', `bonus_id` int(11) NOT NULL DEFAULT '0' COMMENT '区域完成分红记录ID', `is_delete` int(11) NOT NULL DEFAULT '0', `created_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` datetime NOT NULL DEFAULT '0000-00-00 00:00:00', `province_id` int(11) NOT NULL DEFAULT '0', `city_id` int(11) NOT NULL DEFAULT '0', `district_id` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`), KEY `idx_1` (`mall_id`,`is_delete`,`province_id`,`level_id`,`type`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='分红日志'; |
|
1112 |
CREATE TABLE `zjhj_bd_region_level_up` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0:申请升级中 1:通过升级 2:拒绝升级', `level` tinyint(1) NOT NULL COMMENT '升级的等级', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), KEY `idx_1` (`mall_id`,`is_delete`,`user_id`,`created_at`), KEY `idx_2` (`user_id`), KEY `idx_3` (`created_at`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='代理升级申请表'; |
|
1113 |
CREATE TABLE `zjhj_bd_region_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `total_pay_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '订单实付金额', `is_bonus` tinyint(1) NOT NULL DEFAULT '0' COMMENT '1已分红,0未分红', `bonus_rate` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '分红比例', `bonus_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '分红时间', `bonus_id` int(11) NOT NULL DEFAULT '0' COMMENT '区域完成分红记录ID', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `province` varchar(20) NOT NULL COMMENT '省', `city` varchar(20) NOT NULL COMMENT '市', `district` varchar(20) NOT NULL COMMENT '区', `province_id` int(11) NOT NULL DEFAULT '0', `city_id` int(11) NOT NULL DEFAULT '0', `district_id` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='分红池'; |
|
1114 |
CREATE TABLE `zjhj_bd_region_relation` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL COMMENT '代理id', `district_id` int(11) NOT NULL COMMENT '代理的省市区id', `is_update` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否是升级中的关联地区0:否 1:是', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), KEY `mall_id` (`mall_id`,`district_id`,`is_update`,`is_delete`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='代理 --- 地区关联表'; |
|
1115 |
CREATE TABLE `zjhj_bd_region_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `key` varchar(255) NOT NULL, `value` text NOT NULL, `created_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间', `updated_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间', `is_delete` int(11) NOT NULL DEFAULT '0' COMMENT '是否删除 0--未删除 1--已删除', `deleted_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '删除时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='区域分红设置'; |
|
1116 |
CREATE TABLE `zjhj_bd_region_user` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `area_id` int(11) NOT NULL COMMENT '区域ID', `province_id` int(11) NOT NULL COMMENT '所属省', `level` tinyint(2) NOT NULL COMMENT '1:省代理 2:市代理 3:区代理', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '-2被拒或移除后再次申请没提交 -1移除 0审核中,1同意,2拒绝', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `applyed_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '申请时间', `agreed_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '审核时间', PRIMARY KEY (`id`), KEY `created_at` (`created_at`), KEY `idx_1` (`mall_id`,`is_delete`,`status`,`created_at`) USING BTREE, KEY `idx_2` (`mall_id`,`is_delete`,`user_id`,`status`,`created_at`), KEY `user_id` (`user_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='代理表'; |
|
1117 |
CREATE TABLE `zjhj_bd_region_user_info` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL, `name` varchar(100) NOT NULL DEFAULT '' COMMENT '区域姓名', `phone` varchar(11) NOT NULL DEFAULT '' COMMENT '区域手机号', `all_bonus` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '累计分红', `total_bonus` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '当前分红', `out_bonus` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '已提现分红', `remark` varchar(200) NOT NULL DEFAULT '' COMMENT '备注', `reason` text NOT NULL COMMENT '拒绝理由', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`), KEY `idx_1` (`user_id`,`created_at`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='代理信息表'; |
|
1118 |
ALTER TABLE `zjhj_bd_region_level_up` |
|
1119 |
ADD COLUMN `reason` varchar(512) NOT NULL DEFAULT '' COMMENT '理由' AFTER `level`; |
|
1120 |
ALTER TABLE `zjhj_bd_region_level_up` |
|
1121 |
ADD COLUMN `is_read` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0未读 1已读' AFTER `reason`; |
|
1122 |
ALTER TABLE `zjhj_bd_vip_card_order` |
|
1123 |
MODIFY COLUMN `all_send` varchar(4096) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `status`; |
|
1124 |
EOF; |
|
1125 |
sql_execute($sql); |
|
1126 |
}, |
|
1127 |
|
|
1128 |
'4.3.2' => function () { |
|
1129 |
$sql = <<<EOF |
|
1130 |
CREATE TABLE `zjhj_bd_live_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL, `audit_id` int(11) NOT NULL, PRIMARY KEY (`id`), KEY `index_name` (`goods_id`,`audit_id`,`mall_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1131 |
ALTER TABLE `zjhj_bd_core_plugin` MODIFY COLUMN `name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL AFTER `id`; |
|
1132 |
ALTER TABLE `zjhj_bd_core_plugin` ADD COLUMN `pic_url` text NULL AFTER `deleted_at`; |
|
1133 |
ALTER TABLE `zjhj_bd_core_plugin` ADD COLUMN `desc` longtext NULL AFTER `pic_url`; |
|
1134 |
CREATE TABLE `zjhj_bd_plugin_cat` ( `id` INT ( 11 ) NOT NULL AUTO_INCREMENT, `name` VARCHAR ( 24 ) COLLATE utf8mb4_general_ci NOT NULL, `display_name` VARCHAR ( 255 ) COLLATE utf8mb4_general_ci NOT NULL, `sort` INT ( 11 ) NOT NULL DEFAULT 100, `icon` text COLLATE utf8mb4_general_ci, `is_delete` TINYINT ( 1 ) NOT NULL DEFAULT 0, `add_time` datetime DEFAULT NULL, `update_time` datetime DEFAULT NULL, PRIMARY KEY ( `id` ), KEY `name` ( `name` ), KEY `sort` ( `sort` ), KEY `is_delete` ( `is_delete` ) ) ENGINE = INNODB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = DYNAMIC; |
|
1135 |
CREATE TABLE `zjhj_bd_plugin_cat_rel` ( `id` INT ( 11 ) NOT NULL AUTO_INCREMENT, `plugin_name` VARCHAR ( 32 ) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `plugin_cat_name` VARCHAR ( 24 ) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, PRIMARY KEY ( `id` ), KEY `plugin_name` ( `plugin_name` ), KEY `plugin_cat_name` ( `plugin_cat_name` ) ) ENGINE = INNODB DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = DYNAMIC; |
|
1136 |
ALTER TABLE `zjhj_bd_plugin_cat` ADD COLUMN `color` varchar(24) NOT NULL DEFAULT '' AFTER `display_name`; |
|
1137 |
ALTER TABLE `zjhj_bd_core_plugin` ADD COLUMN `sort` int(0) NOT NULL DEFAULT 100 AFTER `desc`; |
|
1138 |
EOF; |
|
1139 |
sql_execute($sql); |
|
1140 |
}, |
|
1141 |
|
|
1142 |
'4.3.6' => function () { |
|
1143 |
$sql = <<<EOF |
|
1144 |
CREATE TABLE `zjhj_bd_admin_notice` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL DEFAULT '0', `type` varchar(20) NOT NULL DEFAULT '' COMMENT 'update更新urgent紧急important重要', `content` text NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1145 |
CREATE TABLE `zjhj_bd_statistics_data_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `key` varchar(100) NOT NULL DEFAULT '', `value` int(11) NOT NULL DEFAULT '0', `time_stamp` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1146 |
CREATE TABLE `zjhj_bd_statistics_user_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `num` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `time_stamp` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1147 |
EOF; |
|
1148 |
sql_execute($sql); |
|
1149 |
}, |
|
1150 |
|
|
1151 |
'4.3.7' => function () { |
|
1152 |
$sql = <<<EOF |
|
1153 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (1, 'wxapp', '微信小程序', '1.0.33', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/d52a90d4eb06059d9fdb0641592400b3.png', '在微信小程序中经营你的店铺', 1); |
|
1154 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (2, 'diy', 'DIY装修', '1.0.105', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4903220b146520fd91533ed140d2542f.png', 'DIY店铺风格和元素,千人千面', 2); |
|
1155 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (3, 'advance', '商品预售', '1.0.57', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/888a3c5dbc7881c74e2ae4299c4e6e2c.png', '提前交付定金,尾款享受优惠', 1); |
|
1156 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (4, 'composition', '套餐组合', '1.0.15', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/753525bea4854dae63ce83f575fa3a10.png', '套餐组合', 2); |
|
1157 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (5, 'aliapp', '支付宝小程序', '1.0.147', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e1f631677b48470eeb0c50f811165472.png', '在支付宝小程序中经营你的店铺', 2); |
|
1158 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (6, 'app_admin', '手机端管理', '1.0.7', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e3e79ca9b97dba95ae79b9ac1bed16f9.png', '手机端操作管理店铺', 3); |
|
1159 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (7, 'assistant', '采集助手', '1.0.5', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/8064507d4b463ae2be31dd86ccc4bd8d.png', '采集助手', 1); |
|
1160 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (8, 'bargain', '砍价', '1.0.63', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/10da8fa3ab90d190fb6c8dcb1fa0ac24.png', '邀请好友砍价后低价购买', 5); |
|
1161 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (9, 'bdapp', '百度小程序', '1.0.147', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/c606e51d6c842f68b768c6780f6dbc87.png', '在百度小程序中经营你的店铺', 4); |
|
1162 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (10, 'bonus', '团队分红', '1.0.39', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/6831954dc342f2ba066621409fe1e60d.png', '队长获得队员订单分红', 2); |
|
1163 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (11, 'booking', '预约', '1.0.71', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/07c662e46ade264338df7544c5f5057f.png', '提前线下消费或服务', 4); |
|
1164 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (12, 'check_in', '签到插件', '1.0.26', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9f8feafc5d1619c3d897e56ba2fd4147.png', '促进店铺访问量和用户活跃度', 3); |
|
1165 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (13, 'clerk', '核销员', '1.0.13', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2743ec86b035db21eaa5e3019e33c714.png', '手机端扫码核销,查询订单', 4); |
|
1166 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (14, 'dianqilai', '客服系统', '1.0.7', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9a1ae4508528799d9ca5543a857b3237.png', '促进商家和买家之间的高效交流', 5); |
|
1167 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (15, 'ecard', '电子卡密', '1.0.7', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/ea1a03f8a27561ea18ec1312b102c3e3.png', '电子卡密', 10); |
|
1168 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (16, 'fxhb', '裂变拆“红包”', '1.0.33', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9a7e9bb462ece248a6da22d7a2a39b84.png', '裂变式邀请好友拆“红包”', 4); |
|
1169 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (17, 'gift', '社交送礼', '1.0.35', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e88d4dd935389049bdeda86856b59ed3.png', '购买礼品送给朋友', 6); |
|
1170 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (18, 'integral_mall', '积分商城', '1.0.61', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4677340a313d1d6a417492dd3b615540.png', '使用积分或积分+现金兑换商品', 1); |
|
1171 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (19, 'lottery', '幸运抽奖', '1.0.63', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0bde7f03396f64b1a6a602ffdc384fe8.png', '裂变玩法,抽取幸运客户赠送奖品', 5); |
|
1172 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (20, 'mch', '多商户', '1.0.76', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e518720e0d614439e51b49735fe1f842.png', '获取入驻商流量,自营+商户入驻', 6); |
|
1173 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (21, 'miaosha', '整点秒杀', '1.0.62', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7ec0386824388b8ce18040857058827d.png', '引导客户快速抢购', 7); |
|
1174 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (22, 'pick', 'N元任选', '1.0.28', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/a4f3d48897eb696fd936816f33a2da70.png', 'N元任选', 3); |
|
1175 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (23, 'pintuan', '拼团', '1.0.104', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/1ad43702df97bdea25452f00b3b49f5e.png', '引导客户邀请朋友一起拼团购买', 8); |
|
1176 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (24, 'pond', '九宫格', '1.0.44', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4b9e58ea9aa6f60e08b5aaef20426ac9.png', '抽积分、优惠券、实物等', 1); |
|
1177 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (25, 'quick_share', '一键发圈', '1.0.15', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7e2836a9861b31de1eb548f067bb2fde.png', '一键保存文案和图片,高效发朋友圈', 7); |
|
1178 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (26, 'scan_code_pay', '当面付', '1.0.34', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0680c8f2ef2632d373750bd8addcfe8b.png', '线下场景扫码当面支付', 6); |
|
1179 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (27, 'scratch', '刮刮卡', '1.0.42', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/28fd30646970fe742350d47c3494aee4.png', '刮开卡片参与抽奖', 8); |
|
1180 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (28, 'shopping', '好物圈', '1.0.9', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/994df3a6c8dc456d4a3a3614b4deaec4.png', '向微信好友推荐好商品', 9); |
|
1181 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (29, 'step', '步数宝', '1.0.69', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7e2e64e891d444d5c31824fee9f8fb88.png', '步数兑换商品', 9); |
|
1182 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (30, 'stock', '股东分红', '1.0.20', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/8174c99e859fd446abd47b877fd41a45.png', '股东分红', 10); |
|
1183 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (31, 'ttapp', '抖音/头条小程序', '1.0.147', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0192ac346351c5fbdc2ea1c953d097f2.png', '在抖音/头条小程序中经营你的店铺', 3); |
|
1184 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (32, 'vip_card', '超级会员卡', '1.0.51', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9c719748ee725092f09fdc5ee18538f2.png', '享受超级会员折扣和福利', 2); |
|
1185 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (33, 'region', '区域代理', '1.0.9', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/1a698f7c1b6c64b57f878d735734858b.png', '区域代理', 11); |
|
1186 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (34, 'flash_sale', '限时抢购', '1.0.12', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0c4882580c64ac1c5a239b653b2e429f.png', '限时抢购', 11); |
|
1187 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (35, 'community', '社区团购', '1.0.23', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/8fec059e37dbf85adb01bd1d7f904d1e.png', '团长群内推广,本地社区自提', 10); |
|
1188 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (36, 'exchange', '兑换中心', '1.0.14', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e7116ea1eee1ae77747cca91cc9f7fed.png', '提货卡、礼品卡、送礼神器', 10); |
|
1189 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (37, 'wholesale', '商品批发', '1.0.1', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/a646bebae632d967be78ee275e9921a5.png', '商品批发', 100); |
|
1190 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (38, 'wechat', '公众号商城', '1.0.1', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/75f92915101acd808800a72d022b0940.png', '公众号商城', 100); |
|
1191 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (39, 'mobile', 'H5商城', '1.0.1', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/68ac2d12965cb0bed7c2c5d357418826.png', 'H5商城', 100); |
|
1192 |
INSERT INTO `zjhj_bd_core_plugin` VALUES (40, 'teller', '收银台', '1.0.1', 0, '0000-00-00 00:00:00', '0000-00-00 00:00:00', '0000-00-00 00:00:00', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/775debae7be373dbb37d2c9d3ca269ad.png', '门店收银与线上商城完美结合', 100); |
|
1193 |
|
|
1194 |
INSERT INTO `zjhj_bd_plugin_cat` VALUES ('1', 'xb4z5hqs6388pd5c', '销售渠道', '#3399FF', '100', null, '0', null, null); |
|
1195 |
INSERT INTO `zjhj_bd_plugin_cat` VALUES ('2', 'nddsdjdaxzmmeqk4', '促销玩法', '#FAA322', '100', null, '0', null, null); |
|
1196 |
INSERT INTO `zjhj_bd_plugin_cat` VALUES ('3', 'xwmgpax7jkzjrxha', '获客工具', '#0DBCD7', '100', null, '0', null, null); |
|
1197 |
INSERT INTO `zjhj_bd_plugin_cat` VALUES ('4', '3wsern27hxspzytd', '客户维护', '#E84C52', '100', null, '0', null, null); |
|
1198 |
INSERT INTO `zjhj_bd_plugin_cat` VALUES ('5', 'kwfhnndnbakznksb', '常用工具', '#7181D9', '100', null, '0', null, null); |
|
1199 |
|
|
1200 |
|
|
1201 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (1, 'wxapp', 'xb4z5hqs6388pd5c'); |
|
1202 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (2, 'aliapp', 'xb4z5hqs6388pd5c'); |
|
1203 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (3, 'ttapp', 'xb4z5hqs6388pd5c'); |
|
1204 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (4, 'bdapp', 'xb4z5hqs6388pd5c'); |
|
1205 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (5, 'advance', 'nddsdjdaxzmmeqk4'); |
|
1206 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (6, 'composition', 'nddsdjdaxzmmeqk4'); |
|
1207 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (7, 'pick', 'nddsdjdaxzmmeqk4'); |
|
1208 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (8, 'booking', 'nddsdjdaxzmmeqk4'); |
|
1209 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (9, 'bargain', 'nddsdjdaxzmmeqk4'); |
|
1210 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (10, 'gift', 'nddsdjdaxzmmeqk4'); |
|
1211 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (11, 'miaosha', 'nddsdjdaxzmmeqk4'); |
|
1212 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (12, 'pintuan', 'nddsdjdaxzmmeqk4'); |
|
1213 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (13, 'shopping', 'nddsdjdaxzmmeqk4'); |
|
1214 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (14, 'ecard', 'nddsdjdaxzmmeqk4'); |
|
1215 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (15, 'flash_sale', 'nddsdjdaxzmmeqk4'); |
|
1216 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (16, 'pond', 'xwmgpax7jkzjrxha'); |
|
1217 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (17, 'bonus', 'xwmgpax7jkzjrxha'); |
|
1218 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (18, 'check_in', 'xwmgpax7jkzjrxha'); |
|
1219 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (19, 'fxhb', 'xwmgpax7jkzjrxha'); |
|
1220 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (20, 'lottery', 'xwmgpax7jkzjrxha'); |
|
1221 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (21, 'mch', 'xwmgpax7jkzjrxha'); |
|
1222 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (22, 'quick_share', 'xwmgpax7jkzjrxha'); |
|
1223 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (23, 'scratch', 'xwmgpax7jkzjrxha'); |
|
1224 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (24, 'step', 'xwmgpax7jkzjrxha'); |
|
1225 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (25, 'stock', 'xwmgpax7jkzjrxha'); |
|
1226 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (26, 'region', 'xwmgpax7jkzjrxha'); |
|
1227 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (27, 'integral_mall', '3wsern27hxspzytd'); |
|
1228 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (28, 'vip_card', '3wsern27hxspzytd'); |
|
1229 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (29, 'assistant', 'kwfhnndnbakznksb'); |
|
1230 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (30, 'diy', 'kwfhnndnbakznksb'); |
|
1231 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (31, 'app_admin', 'kwfhnndnbakznksb'); |
|
1232 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (32, 'clerk', 'kwfhnndnbakznksb'); |
|
1233 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (33, 'dianqilai', 'kwfhnndnbakznksb'); |
|
1234 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (34, 'scan_code_pay', 'kwfhnndnbakznksb'); |
|
1235 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (35, 'community', 'nddsdjdaxzmmeqk4'); |
|
1236 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (36, 'exchange', 'nddsdjdaxzmmeqk4'); |
|
1237 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (37, 'wholesale', 'nddsdjdaxzmmeqk4'); |
|
1238 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (38, 'wechat', 'xb4z5hqs6388pd5c'); |
|
1239 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (39, 'mobile', 'xb4z5hqs6388pd5c'); |
|
1240 |
INSERT INTO `zjhj_bd_plugin_cat_rel` VALUES (40, 'teller', 'kwfhnndnbakznksb'); |
|
1241 |
|
|
1242 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (1, '双十二', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/d66b72d485ceed26d358e8f142dec60f.png\"]', '双十二', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/6d79442a06563f9b356854994d794b9a.zip'); |
|
1243 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (2, '服饰1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/42d68cee10e3fa8af2c23ab81241e14e.png\"]', '服饰1', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/e7b0241ebaf1b6a62498d6b3368104d7.zip'); |
|
1244 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (3, '服饰2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7e96634708ed70371f9fbcd3dcba0bb4.png\"]', '服饰2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/ab1744dc43d2086eb9c783bef3103a81.zip'); |
|
1245 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (4, '服饰3', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2e86a1ad42ac8ea8b5f9c8e1131e2cc2.png\"]', '服饰3', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0f42e2f848b9f4f915e89bb143a07f08.zip'); |
|
1246 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (5, '生鲜1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/3d6b77eb7d512537c8e03e86c1e052f5.png\"]', '生鲜1', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/60cada7959c796057723077f5ece92b8.zip'); |
|
1247 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (6, '生鲜2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7b516ba8fce669badea52aa2452dc3db.png\"]', '生鲜2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2d55951b4a6f9edfb3119f1a6523d85d.zip'); |
|
1248 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (7, '美妆1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9d24aec77b45951b50343f3bc9708cd9.png\"]', '美妆1', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7926abf6c6100457633685f5bc59375a.zip'); |
|
1249 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (8, '美妆2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/dc9370e6666b5cb588d81c1b22c72151.png\"]', '美妆2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/35f29d446dd3b6329affd943e0e9f5c4.zip'); |
|
1250 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (9, '超市1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/3bddad82d6c63870596334e318777fa5.png\"]', '超市1', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/33bd4dfe5ad7a707042a74b7bd79d843.zip'); |
|
1251 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (10, '超市2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/81ecb3a4ec8e8248da0e7f7a027bafd2.png\"]', '超市2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/87646dd04503f59f316e23af515015e8.zip'); |
|
1252 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (11, '超市3', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/63f989c9f7b9663e6ab9de13c03056b6.png\"]', '超市3', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/476d9d5bcc2b4faba2693b4f6c990603.zip'); |
|
1253 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (12, '春节模板', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2be7b8bd21b5b89c1008bcbfbd6fc876.png\"]', '春节模板', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/29434d36932147c538e575e95918ec3b.zip'); |
|
1254 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (13, '元宵节模板', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/a5c397ade39f0e76c784d46078f0ea20.png\"]', '元宵节模板', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4057bee3a03bcbe14d1c7d5fb36a5afb.zip'); |
|
1255 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (14, '情人节模板', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/615112ec2dc3e3b0b8aaa9b0b93bd4f0.png\"]', '情人节模板', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/f275c5db1cbd432567b7eaab81cf1dd0.zip'); |
|
1256 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (15, '春节模板2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2022fc32d157bbdacae989174c75d583.png\"]', '春节模板2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/732a5469e1f2110de1b0433ba9223a14.zip'); |
|
1257 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (16, '元宵节模板2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/5f8c2f51b4a9160decb00bed2277952f.png\"]', '元宵节模板2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/46fcb342159ea926a4a5258503717895.zip'); |
|
1258 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (17, '情人节模板2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/a0dadedd1a511bfa59fa63497a8c974d.png\"]', '情人节模板2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/ee6f185747fc4079bc097331ffe26e94.zip'); |
|
1259 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (18, '妇女节', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/be4f913235be3ca1b7a4b4d34bb45216.png\"]', '妇女节', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/aa6b10949760ec20e2febfe8598d28e1.zip'); |
|
1260 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (19, '妇女节2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/df3307934c25cfbf1ae2c1046037d8bc.png\"]', '妇女节2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/3d31d280d6bb8e87fdf433369bc25126.zip'); |
|
1261 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (20, '51劳动节', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/fdce3d73af8165e0f5652187213950e3.png\"]', '51劳动节', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/976637b958d269cd483784e9c5c1c71e.zip'); |
|
1262 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (21, '51劳动节-2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/a65509e5cee18c6dda134cde50009892.png\"]', '51劳动节-2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/db17654eddbc57754dfb9542f57ffd6a.zip'); |
|
1263 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (22, '618年中盛典', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/3dec44461189a8c99b157e426ec98aa4.png\"]', '618年中盛典', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/c651005b5944a0b61871b82459edece4.zip'); |
|
1264 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (23, '618年中盛典-2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/35120f94cf467eb8874aa67afe0b12c4.png\"]', '618年中盛典-2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/fc0274194a2297cceee2d62bdb7ec248.zip'); |
|
1265 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (24, '端午节2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/995334b8ad426121aa8565297b51fcca.png\"]', '端午节2', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/0605dac1b23afa05e59ee253c5785ff2.zip'); |
|
1266 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (25, '端午节1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/da8a5f4aa964f4dd933b60f9643a7353.png\"]', '端午节1', 0.00, 'diy', '0.0.1', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/61173884b5b6f8bb604ad0bfe5998b22.zip'); |
|
1267 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (26, '七夕节', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/7c028875992161e54de2ca8ff3368d07.png\"]', '七夕节', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/d6b97eba29e23e34fc6540018a745a3f.zip'); |
|
1268 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (27, '国庆节1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/01a2c2b646e906a4030890f63e90b3e5.png\"]', '国庆节1', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/46b7d293c7e09914096ab0452405057b.zip'); |
|
1269 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (28, '国庆节2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/5d7e89956a98affd664148d8bea71551.png\"]', '国庆节2', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2c707440327f70b161354716a39a1323.zip'); |
|
1270 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (29, '中秋节1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4f03a7e64fd2d253f5c0377758a3339f.png\"]', '中秋节1', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/2236ba6e328a1697f3aad986e7aa87f9.zip'); |
|
1271 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (30, '中秋节2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/6a9368b86fda2ae8036eca737a63c889.png\"]', '中秋节2', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/6cbfc8b71f419e0744b717acfdf9154e.zip'); |
|
1272 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (31, '双十二1', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/d580c61a686ced24053ad0aec7457096.png\"]', '双十二1', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/b7855271cd534e42504dc850ff5ff216.zip'); |
|
1273 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (32, '双十二2', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/096eb7e2b1c7ace2e8d40580e230ab81.png\"]', '双十二2', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/eec38ebdb62248f1476dfb2595ab2883.zip'); |
|
1274 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (33, '圣诞节', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/9d5be7805c6895bcb76f91b309bf60c0.png\"]', '圣诞节', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/467383db158a2c65edbf1163197ff78b.zip'); |
|
1275 |
INSERT INTO `zjhj_bd_core_template_local` VALUES (34, '元旦节', '[\"http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/4d7d33a1854ecd602ef737d9f465f048.png\"]', '元旦节', 0.00, 'diy', '0.01', 'http://auth-zjhejiang-com.oss-cn-hangzhou.aliyuncs.com/uploads/versions/f04d03473489c20f894655e76d2a6b76.zip'); |
|
1276 |
|
|
1277 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (1, 'page', 0); |
|
1278 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (1, 'module', 0); |
|
1279 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (2, 'page', 0); |
|
1280 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (2, 'module', 0); |
|
1281 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (3, 'page', 0); |
|
1282 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (3, 'module', 0); |
|
1283 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (4, 'page', 0); |
|
1284 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (4, 'module', 0); |
|
1285 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (5, 'page', 0); |
|
1286 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (5, 'module', 0); |
|
1287 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (6, 'page', 0); |
|
1288 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (6, 'module', 0); |
|
1289 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (7, 'page', 0); |
|
1290 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (7, 'module', 0); |
|
1291 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (8, 'page', 0); |
|
1292 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (8, 'module', 0); |
|
1293 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (9, 'page', 0); |
|
1294 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (9, 'module', 0); |
|
1295 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (10, 'page', 0); |
|
1296 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (10, 'module', 0); |
|
1297 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (11, 'page', 0); |
|
1298 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (11, 'module', 0); |
|
1299 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (12, 'page', 0); |
|
1300 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (12, 'module', 0); |
|
1301 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (13, 'page', 0); |
|
1302 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (13, 'module', 0); |
|
1303 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (14, 'page', 0); |
|
1304 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (14, 'module', 0); |
|
1305 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (15, 'page', 0); |
|
1306 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (15, 'module', 0); |
|
1307 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (16, 'page', 0); |
|
1308 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (16, 'module', 0); |
|
1309 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (17, 'page', 0); |
|
1310 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (17, 'module', 0); |
|
1311 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (18, 'page', 0); |
|
1312 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (18, 'module', 0); |
|
1313 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (19, 'page', 0); |
|
1314 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (19, 'module', 0); |
|
1315 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (20, 'page', 0); |
|
1316 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (20, 'module', 0); |
|
1317 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (21, 'page', 0); |
|
1318 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (21, 'module', 0); |
|
1319 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (22, 'page', 0); |
|
1320 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (22, 'module', 0); |
|
1321 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (23, 'page', 0); |
|
1322 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (23, 'module', 0); |
|
1323 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (24, 'page', 0); |
|
1324 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (25, 'page', 0); |
|
1325 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (26, 'page', 0); |
|
1326 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (26, 'module', 0); |
|
1327 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (27, 'page', 0); |
|
1328 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (27, 'module', 0); |
|
1329 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (28, 'page', 0); |
|
1330 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (28, 'module', 0); |
|
1331 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (29, 'page', 0); |
|
1332 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (29, 'module', 0); |
|
1333 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (30, 'page', 0); |
|
1334 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (31, 'page', 0); |
|
1335 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (31, 'module', 0); |
|
1336 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (32, 'page', 0); |
|
1337 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (32, 'module', 0); |
|
1338 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (33, 'page', 0); |
|
1339 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (34, 'page', 0); |
|
1340 |
INSERT INTO `zjhj_bd_core_template_type` (`template_id`, `type`, `is_delete`) VALUES (34, 'module', 0); |
|
1341 |
|
|
1342 |
|
|
1343 |
EOF; |
|
1344 |
sql_execute($sql); |
|
1345 |
}, |
|
1346 |
'4.3.8' => function () { |
|
1347 |
$sql = <<<EOF |
|
1348 |
CREATE TABLE `zjhj_bd_flash_sale_activity` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `status` int(11) NOT NULL DEFAULT '0' COMMENT '状态 0下架 1上架', `is_delete` tinyint(4) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `title` varchar(255) NOT NULL DEFAULT '' COMMENT '活动标题', `start_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动开始时间', `end_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动结束时间', `notice` int(11) NOT NULL DEFAULT '0' COMMENT '活动预告', PRIMARY KEY (`id`), KEY `idx_1` (`mall_id`,`is_delete`,`created_at`) USING BTREE, KEY `sort` (`start_at`,`end_at`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='显示购买活动'; |
|
1349 |
CREATE TABLE `zjhj_bd_flash_sale_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `status` tinyint(1) NOT NULL COMMENT '状态 0 关闭 1开启', `goods_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动id', `sort` int(11) NOT NULL DEFAULT '100' COMMENT '排序', PRIMARY KEY (`id`), KEY `activity` (`activity_id`) USING BTREE, KEY `goods_id` (`goods_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='限时抢购商品表'; |
|
1350 |
CREATE TABLE `zjhj_bd_flash_sale_goods_attr` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `discount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '商品折扣', `cut` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '商品减钱', `goods_id` int(11) NOT NULL, `goods_attr_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='显示购买商品规格'; |
|
1351 |
CREATE TABLE `zjhj_bd_flash_sale_order_discount` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `order_id` int(11) NOT NULL COMMENT '订单id', `discount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '优惠金额', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1352 |
ALTER TABLE `zjhj_bd_store` MODIFY COLUMN `description` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '门店描述'; |
|
1353 |
ALTER TABLE `zjhj_bd_flash_sale_activity` ADD COLUMN `notice_hours` int(11) NOT NULL DEFAULT 0 COMMENT '提前N小时' AFTER `notice`; |
|
1354 |
ALTER TABLE `zjhj_bd_flash_sale_goods` ADD COLUMN `type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '1打折 2减钱 3促销价' AFTER `goods_id`; |
|
1355 |
ALTER TABLE `zjhj_bd_flash_sale_goods_attr` ADD COLUMN `type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '1打折 2减钱 3促销价' AFTER `cut`; |
|
1356 |
EOF; |
|
1357 |
sql_execute($sql); |
|
1358 |
}, |
|
1359 |
|
|
1360 |
'4.3.10' => function () { |
|
1361 |
$sql = <<<EOF |
|
1362 |
CREATE TABLE `zjhj_bd_core_template_type` ( `id` int(11) NOT NULL AUTO_INCREMENT, `template_id` int(11) NOT NULL, `type` varchar(255) NOT NULL DEFAULT '' COMMENT '模板适用地方', `is_delete` tinyint(1) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=49 DEFAULT CHARSET=utf8mb4 COMMENT='模板市场中模板适用的地方'; |
|
1363 |
alter table `zjhj_bd_pintuan_orders` add `expected_over_time` int(11) default 0 not null; |
|
1364 |
alter table `zjhj_bd_pintuan_orders` add index index_name(expected_over_time); |
|
1365 |
CREATE TABLE `zjhj_bd_wxapp_service` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `cid` int(11) NOT NULL COMMENT 'wxapp_config', `appid` varchar(128) NOT NULL COMMENT '服务商appid', `mchid` varchar(32) NOT NULL COMMENT '服务商mchid', `is_choise` tinyint(1) NOT NULL DEFAULT '0' COMMENT '1选中 0不选', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `key` varchar(32) NOT NULL COMMENT '服务商微信支付Api密钥', `cert_pem` varchar(2000) NOT NULL DEFAULT '', `key_pem` varchar(2000) NOT NULL DEFAULT '', PRIMARY KEY (`id`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
1366 |
ALTER TABLE `zjhj_bd_wxapp_config` MODIFY COLUMN `mchid` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `updated_at`, MODIFY COLUMN `key` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `mchid`; |
|
1367 |
ALTER TABLE `zjhj_bd_goods_service_relation` ADD INDEX `index1` (`goods_id`, `is_delete`) USING BTREE , ADD INDEX `index2` (`service_id`, `is_delete`) USING BTREE ; |
|
1368 |
ALTER TABLE `zjhj_bd_goods_service_relation` ADD INDEX `service_id`(`service_id`); |
|
1369 |
ALTER TABLE `zjhj_bd_goods_service_relation` ADD INDEX `goods_id`(`goods_id`); |
|
1370 |
ALTER TABLE `zjhj_bd_goods_service_relation` ADD INDEX `is_delete`(`is_delete`); |
|
1371 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX `mall_id`(`mall_id`); |
|
1372 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX `key`(`key`); |
|
1373 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX `value`(`value`); |
|
1374 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX `time_stamp`(`time_stamp`); |
|
1375 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX `created_at`(`created_at`); |
|
1376 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `mall_id`(`mall_id`); |
|
1377 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `user_id`(`user_id`); |
|
1378 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `num`(`num`); |
|
1379 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `created_at`(`created_at`); |
|
1380 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `is_delete`(`is_delete`); |
|
1381 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX `time_stamp`(`time_stamp`); |
|
1382 |
ALTER TABLE `zjhj_bd_statistics_data_log` ADD INDEX ( `mall_id` ), ADD INDEX ( `key` ); |
|
1383 |
ALTER TABLE `zjhj_bd_statistics_user_log` ADD INDEX ( `mall_id` ), ADD INDEX ( `user_id` ); |
|
1384 |
EOF; |
|
1385 |
sql_execute($sql); |
|
1386 |
}, |
|
1387 |
'4.3.14' => function () { |
|
1388 |
$sql = <<<EOF |
|
1389 |
CREATE TABLE `zjhj_bd_community_activity` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `status` int(11) NOT NULL DEFAULT '0' COMMENT '状态 0下架 1上架', `is_delete` tinyint(4) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `title` varchar(255) NOT NULL DEFAULT '' COMMENT '活动标题', `start_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动开始时间', `end_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '活动结束时间', `is_area_limit` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否单独区域购买', `area_limit` longtext NOT NULL, `full_price` varchar(200) NOT NULL DEFAULT '' COMMENT '满减方案json', `condition` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0关闭,1开启人数条件,2开启件数条件', `num` int(11) NOT NULL DEFAULT '0' COMMENT '条件数量', PRIMARY KEY (`id`) USING BTREE, KEY `idx_1` (`mall_id`,`is_delete`,`created_at`), KEY `sort` (`start_at`,`end_at`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='社区团购活动'; |
|
1390 |
CREATE TABLE `zjhj_bd_community_activity_locking` ( `id` int(11) NOT NULL AUTO_INCREMENT, `activity_id` int(11) NOT NULL DEFAULT '0', `middleman_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1391 |
CREATE TABLE `zjhj_bd_community_activity_robots` ( `id` int(11) NOT NULL AUTO_INCREMENT, `activity_id` int(11) NOT NULL DEFAULT '0', `middleman_id` int(11) NOT NULL DEFAULT '0', `robots_ids` varchar(100) NOT NULL DEFAULT '', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1392 |
CREATE TABLE `zjhj_bd_community_address` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL, `name` varchar(255) NOT NULL COMMENT '收货人', `province_id` int(11) NOT NULL, `province` varchar(255) NOT NULL COMMENT '省份名称', `city_id` int(11) NOT NULL, `city` varchar(255) NOT NULL COMMENT '城市名称', `district_id` int(11) NOT NULL, `district` varchar(255) NOT NULL COMMENT '县区名称', `mobile` varchar(255) NOT NULL COMMENT '联系电话', `detail` varchar(1000) NOT NULL COMMENT '详细地址', `is_default` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否默认', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `latitude` varchar(255) NOT NULL DEFAULT '' COMMENT '经度', `longitude` varchar(255) NOT NULL DEFAULT '' COMMENT '纬度', `location` varchar(255) NOT NULL DEFAULT '' COMMENT '位置', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='团长地址'; |
|
1393 |
CREATE TABLE `zjhj_bd_community_bonus_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动ID', `desc` varchar(200) NOT NULL DEFAULT '', `price` decimal(10,2) NOT NULL DEFAULT '0.00', `profit_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '利润', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1394 |
CREATE TABLE `zjhj_bd_community_cart` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `mch_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL DEFAULT '0', `activity_id` int(11) NOT NULL DEFAULT '0', `community_goods_id` int(11) NOT NULL DEFAULT '0', `goods_id` int(11) NOT NULL DEFAULT '0', `goods_attr_id` int(11) NOT NULL DEFAULT '0', `attr_info` longtext NOT NULL, `num` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='社区团购用户购物车'; |
|
1395 |
CREATE TABLE `zjhj_bd_community_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动id', `sort` int(11) NOT NULL DEFAULT '100' COMMENT '排序', PRIMARY KEY (`id`) USING BTREE, KEY `activity` (`activity_id`) USING BTREE, KEY `goods_id` (`goods_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='社区团购商品'; |
|
1396 |
CREATE TABLE `zjhj_bd_community_goods_attr` ( `id` int(11) NOT NULL AUTO_INCREMENT, `goods_id` int(11) NOT NULL DEFAULT '0', `attr_id` int(11) NOT NULL DEFAULT '0', `supply_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '供货价', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1397 |
CREATE TABLE `zjhj_bd_community_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL DEFAULT '0', `middleman_id` int(11) NOT NULL DEFAULT '0', `activity_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1398 |
CREATE TABLE `zjhj_bd_community_middleman` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `money` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '可提现利润', `total_money` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '累计利润', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0--申请中 1--通过 2--拒绝 -1--未支付', `apply_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '申请时间', `become_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '通过审核时间', `delete_first_show` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除后是否显示0--不显示 1--显示', `reason` varchar(255) NOT NULL DEFAULT '' COMMENT '审核结果原因', `content` varchar(255) NOT NULL DEFAULT '' COMMENT '备注', `name` varchar(255) NOT NULL DEFAULT '' COMMENT '收货人', `mobile` varchar(255) NOT NULL DEFAULT '' COMMENT '联系电话', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `pay_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '支付的金额', `token` varchar(255) NOT NULL DEFAULT '', `pay_type` tinyint(255) NOT NULL DEFAULT '0' COMMENT '支付方式', `pay_time` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '支付时间', `total_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '销售总额', `order_count` int(11) NOT NULL DEFAULT '0' COMMENT '订单总数', PRIMARY KEY (`id`), KEY `user_id` (`user_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='社区团购 团长信息'; |
|
1399 |
CREATE TABLE `zjhj_bd_community_middleman_activity` ( `id` int(11) NOT NULL AUTO_INCREMENT, `middleman_id` int(11) NOT NULL DEFAULT '0' COMMENT '团长user_id', `activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动id', `is_remind` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否提醒 0--未提醒 1--已提醒', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否删除', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1400 |
CREATE TABLE `zjhj_bd_community_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `activity_id` int(11) NOT NULL DEFAULT '0' COMMENT '活动ID', `user_id` int(11) NOT NULL DEFAULT '0' COMMENT '用户ID', `middleman_id` int(11) NOT NULL COMMENT '团长ID', `profit_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '总利润', `profit_data` text NOT NULL COMMENT '利润详情', `full_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '满多少', `discount_price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '优惠金额', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `activity_no` varchar(100) NOT NULL DEFAULT '' COMMENT '活动编号', `no` int(11) NOT NULL DEFAULT '0' COMMENT '编号', `num` int(11) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1401 |
CREATE TABLE `zjhj_bd_community_relations` ( `id` int(11) NOT NULL AUTO_INCREMENT, `user_id` int(11) NOT NULL DEFAULT '0', `middleman_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='社区团购 用户与团长关系'; |
|
1402 |
CREATE TABLE `zjhj_bd_community_switch` ( `id` int(11) NOT NULL AUTO_INCREMENT, `middleman_id` int(11) NOT NULL DEFAULT '0', `activity_id` int(11) NOT NULL DEFAULT '0', `goods_id` int(11) NOT NULL DEFAULT '0', `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='活动商品关闭表'; |
|
1403 |
CREATE TABLE `zjhj_bd_finance` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `order_no` varchar(255) NOT NULL DEFAULT '' COMMENT '订单号', `price` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '提现金额', `service_charge` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '提现手续费(%)', `type` varchar(255) NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额', `extra` longtext COMMENT '额外信息 例如微信账号、支付宝账号等', `status` int(11) NOT NULL DEFAULT '0' COMMENT '提现状态 0--申请 1--同意 2--已打款 3--驳回', `is_delete` int(11) NOT NULL DEFAULT '0', `created_at` datetime NOT NULL, `updated_at` datetime NOT NULL, `deleted_at` datetime NOT NULL, `content` longtext, `name` varchar(255) NOT NULL DEFAULT '' COMMENT '真实姓名', `model` varchar(255) NOT NULL DEFAULT '' COMMENT '提现插件(share,bonus,stock,region,mch)', `transfer_status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0.待转账 | 1.已转账 | 2.拒绝转账', `phone` varchar(255) NOT NULL DEFAULT '' COMMENT '手机号', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='提现记录汇总表'; |
|
1404 |
ALTER TABLE `zjhj_bd_order_detail` ADD INDEX (`created_at`); |
|
1405 |
EOF; |
|
1406 |
sql_execute($sql); |
|
1407 |
}, |
|
1408 |
'4.3.20' => function () { |
|
1409 |
$sql = <<<EOF |
|
1410 |
ALTER TABLE `zjhj_bd_region_cash` MODIFY COLUMN `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' AFTER `user_id`, MODIFY COLUMN `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额' AFTER `service_charge`, MODIFY COLUMN `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '额外信息 例如微信账号、支付宝账号等' AFTER `type`, MODIFY COLUMN `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `deleted_at`, DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci; |
|
1411 |
ALTER TABLE `zjhj_bd_finance` MODIFY COLUMN `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' AFTER `user_id`, MODIFY COLUMN `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额' AFTER `service_charge`, MODIFY COLUMN `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '额外信息 例如微信账号、支付宝账号等' AFTER `type`, MODIFY COLUMN `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `deleted_at`, MODIFY COLUMN `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '真实姓名' AFTER `content`, MODIFY COLUMN `model` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现插件(share,bonus,stock,region,mch)' AFTER `name`, MODIFY COLUMN `phone` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '手机号' AFTER `transfer_status`, DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci; |
|
1412 |
alter table `zjhj_bd_order_detail_express` add `city_mobile` varchar(255); |
|
1413 |
alter table `zjhj_bd_order_detail_express` add `city_info` longtext; |
|
1414 |
alter table `zjhj_bd_order_detail_express` add `city_name` varchar(255); |
|
1415 |
alter table `zjhj_bd_order_detail_express` add `shop_order_id` varchar(255); |
|
1416 |
alter table `zjhj_bd_order_detail_express` add `status` int(11) default 0 not null; |
|
1417 |
alter table `zjhj_bd_order_detail_express` add `express_type` varchar(255) default ''; |
|
1418 |
CREATE TABLE `zjhj_bd_city_service` (`id` int(11) NOT NULL AUTO_INCREMENT,`mall_id` int(11) NOT NULL,`platform` varchar(255) DEFAULT NULL COMMENT '所属平台',`name` varchar(255) NOT NULL COMMENT '配送名称',`distribution_corporation` int(11) NOT NULL COMMENT '配送公司 1.顺丰|2.闪送|3.美团配送|4.达达',`shop_no` varchar(255) DEFAULT NULL COMMENT '门店编号',`data` text,`created_at` timestamp NULL DEFAULT NULL,`is_delete` int(1) NOT NULL DEFAULT '0',`service_type` varchar(255) NOT NULL,PRIMARY KEY (`id`)) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1419 |
ALTER TABLE `zjhj_bd_pond_setting` ADD COLUMN `bg_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景图' AFTER `is_print`,ADD COLUMN `bg_color` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景颜色' AFTER `bg_pic`,ADD COLUMN `bg_color_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景颜色类型' AFTER `bg_color`,ADD COLUMN `bg_gradient_color` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景渐变颜色' AFTER `bg_color_type`; |
|
1420 |
ALTER TABLE `zjhj_bd_scratch_setting` ADD COLUMN `bg_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景图' AFTER `is_print`; |
|
1421 |
alter table `zjhj_bd_order_detail_express` add `city_service_id` int(11) default 0 not null; |
|
1422 |
ALTER TABLE `zjhj_bd_recharge` ADD COLUMN `send_member_id` int(11) NOT NULL DEFAULT 0 COMMENT '赠送的会员' AFTER `send_integral`; |
|
1423 |
ALTER TABLE `zjhj_bd_recharge_orders` ADD COLUMN `send_member_id` int(11) NOT NULL DEFAULT 0 COMMENT '赠送的会员' AFTER `send_integral`; |
|
1424 |
EOF; |
|
1425 |
sql_execute($sql); |
|
1426 |
}, |
|
1427 |
|
|
1428 |
'4.3.25' => function () { |
|
1429 |
$sql = <<<EOF |
|
1430 |
CREATE TABLE `zjhj_bd_goods_coupon_relation` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `goods_id` int(11) NOT NULL, `coupon_id` int(11) NOT NULL, `num` int(11) NOT NULL DEFAULT '1', `is_delete` int(11) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='商品赠送优惠券信息'; |
|
1431 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `give_balance` decimal(10,2) NOT NULL DEFAULT 0 COMMENT '赠送余额' AFTER `give_integral_type`, ADD COLUMN `give_balance_type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '赠送余额类型1.固定值 |2.百分比' AFTER `give_balance`; |
|
1432 |
CREATE TABLE `zjhj_bd_user_coupon_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL DEFAULT 0 COMMENT '商城ID' , `user_coupon_id` int(11) NOT NULL DEFAULT 0 COMMENT '优惠券ID' , `user_id` int(11) NOT NULL DEFAULT 0 COMMENT '用户ID' , `goods_id` int(11) NOT NULL COMMENT '商品ID' , `is_delete` int(11) NOT NULL DEFAULT 0 COMMENT '是否删除 0--不删除 1--删除' , `created_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '创建时间' , `updated_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间' , `deleted_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP COMMENT '删除时间' , PRIMARY KEY (`id`), INDEX `mall_id` (`mall_id`) USING BTREE , INDEX `user_coupon_id` (`user_coupon_id`) USING BTREE , INDEX `user_id` (`user_id`) USING BTREE ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='随商品赠送优惠券关联表' AUTO_INCREMENT=1 ROW_FORMAT=DYNAMIC; |
|
1433 |
ALTER TABLE `zjhj_bd_favorite` ADD COLUMN `mirror_price` decimal(10,2) NOT NULL DEFAULT 0 COMMENT '收藏时的售价' AFTER `goods_id`; |
|
1434 |
ALTER TABLE `zjhj_bd_balance_log` ADD COLUMN `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' AFTER `custom_desc`; |
|
1435 |
ALTER TABLE `zjhj_bd_integral_log` ADD COLUMN `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' AFTER `custom_desc`; |
|
1436 |
CREATE TABLE `zjhj_bd_city_preview_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `result_data` json DEFAULT NULL, `order_info` json DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, `order_detail_sign` varchar(255) DEFAULT NULL, `all_order_info` json DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=5 DEFAULT CHARSET=utf8mb4; |
|
1437 |
EOF; |
|
1438 |
sql_execute($sql); |
|
1439 |
}, |
|
1440 |
'4.3.29' => function () { |
|
1441 |
$sql = <<<EOF |
|
1442 |
DROP TABLE IF EXISTS `zjhj_bd_city_preview_order`; |
|
1443 |
CREATE TABLE `zjhj_bd_city_preview_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `result_data` text, `order_info` text, `created_at` timestamp NULL DEFAULT NULL, `order_detail_sign` varchar(255) DEFAULT NULL, `all_order_info` text, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1444 |
EOF; |
|
1445 |
sql_execute($sql); |
|
1446 |
}, |
|
1447 |
'4.3.30' => function () { |
|
1448 |
$sql = <<<EOF |
|
1449 |
ALTER TABLE `zjhj_bd_coupon` ADD COLUMN `can_receive_count` int(11) NOT NULL DEFAULT 1 COMMENT '可领取数量', ADD COLUMN `app_share_title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', ADD COLUMN `app_share_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT ''; |
|
1450 |
ALTER TABLE `zjhj_bd_user_card` ADD COLUMN `receive_id` int NOT NULL DEFAULT 0 COMMENT '转赠领取的用户id', ADD COLUMN `parent_card_id` int NOT NULL DEFAULT 0 COMMENT '转赠的用户卡券id'; |
|
1451 |
ALTER TABLE `zjhj_bd_goods_cards` ADD COLUMN `app_share_title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', ADD COLUMN `app_share_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT ''; |
|
1452 |
EOF; |
|
1453 |
sql_execute($sql); |
|
1454 |
}, |
|
1455 |
'4.3.34' => function () { |
|
1456 |
$sql = <<<EOF |
|
1457 |
ALTER TABLE `zjhj_bd_vip_card_order` ADD COLUMN `sign` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `deleted_at`; |
|
1458 |
CREATE TABLE `zjhj_bd_exchange_code` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `library_id` int(11) NOT NULL, `type` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0 后台 1礼品卡', `code` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NOT NULL, `status` tinyint(1) NOT NULL DEFAULT 1 COMMENT '状态开关 0禁用 1 启用 2 兑换 3结束', `validity_type` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `valid_end_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `valid_start_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `r_user_id` int(11) NOT NULL DEFAULT 0, `r_raffled_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `r_rewards` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL, `r_origin` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '兑换来源', `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '后台联系人', `mobile` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '后台手机号码', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1459 |
CREATE TABLE `zjhj_bd_exchange_code_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `is_success` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否兑换成功', `code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `origin` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT 'admin app', `remake` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '简单说明', `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1460 |
CREATE TABLE `zjhj_bd_exchange_coupon_relation` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `code_id` int(11) NOT NULL, `user_coupon_id` int(11) NOT NULL, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1461 |
CREATE TABLE `zjhj_bd_exchange_goods` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `library_id` int(11) NOT NULL DEFAULT 0, `goods_id` int(11) NOT NULL, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1462 |
CREATE TABLE `zjhj_bd_exchange_library` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '名称', `remark` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '说明', `expire_type` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 'all' COMMENT 'all 永久 fixed 固定 relatively相对', `expire_start_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '固定开始', `expire_end_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '固定开始', `expire_start_day` int(10) NOT NULL DEFAULT 0 COMMENT '相对开始', `expire_end_day` int(10) NOT NULL DEFAULT 0 COMMENT '相对结束', `mode` tinyint(1) NOT NULL DEFAULT 0 COMMENT '0 全部 1 份', `code_format` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 'english_num' COMMENT 'english_num, num', `rewards` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '奖励品', `rewards_s` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '奖励品类型 后台搜索使用', `is_recycle` tinyint(1) NOT NULL COMMENT '是否加入回收站', `recycle_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `updated_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', `deleted_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1463 |
CREATE TABLE `zjhj_bd_exchange_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `exchange_id` int(11) NOT NULL, `code_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1464 |
CREATE TABLE `zjhj_bd_exchange_record_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `token` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, `code_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1465 |
CREATE TABLE `zjhj_bd_exchange_reward_result` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT, `code_token` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `token` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '', `data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL, PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1466 |
ALTER TABLE `zjhj_bd_user_card` ADD COLUMN `remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT '' COMMENT '简单备注来源' AFTER `parent_card_id`; |
|
1467 |
ALTER TABLE `zjhj_bd_share_cash` MODIFY COLUMN `order_no` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '订单号' AFTER `user_id`, MODIFY COLUMN `type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提现方式 auto--自动打款 wechat--微信打款 alipay--支付宝打款 bank--银行转账 balance--打款到余额' AFTER `service_charge`, MODIFY COLUMN `extra` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '额外信息 例如微信账号、支付宝账号等' AFTER `type`, MODIFY COLUMN `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `deleted_at`, DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci; |
|
1468 |
CREATE TABLE `zjhj_bd_exchange_svip_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `order_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `code_id` int(11) NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB AUTO_INCREMENT = 1 CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1469 |
EOF; |
|
1470 |
sql_execute($sql); |
|
1471 |
}, |
|
1472 |
'4.3.40' => function () { |
|
1473 |
$sql = <<<EOF |
|
1474 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `shipping_id` int(11) NOT NULL DEFAULT 0 COMMENT '包邮模板ID' AFTER `forehead`; |
|
1475 |
ALTER TABLE `zjhj_bd_free_delivery_rules` ADD COLUMN `status` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否默认 0否 1是' AFTER `detail`; |
|
1476 |
ALTER TABLE `zjhj_bd_free_delivery_rules` ADD COLUMN `type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '1:订单满额包邮 2:订单满件包邮 3:单商品满额包邮 4:单商品满件包邮' AFTER `name`; |
|
1477 |
CREATE TABLE `zjhj_bd_full_reduce_activity` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `name` varchar(255) NOT NULL COMMENT '活动标题', `content` varchar(8192) NOT NULL DEFAULT '', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '状态 0下架 1上架', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `start_at` timestamp NOT NULL, `end_at` timestamp NOT NULL, `appoint_type` tinyint(1) NOT NULL COMMENT '1:全部商品\r\n2:全部自营商品\r\n3:指定商品参加\r\n4:指定商品不参加', `rule_type` tinyint(1) NOT NULL COMMENT '1:阶梯满减\r\n2:循环满减', `discount_rule` varchar(512) NOT NULL COMMENT '满减规则', `appoint_goods` text NOT NULL, `noappoint_goods` text NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1478 |
ALTER TABLE `zjhj_bd_order` ADD COLUMN `full_reduce_price` decimal(10,2) NOT NULL DEFAULT 0 COMMENT '满减活动优惠价格' AFTER `member_discount_price`; |
|
1479 |
ALTER TABLE `zjhj_bd_gift_send_order` ADD COLUMN `full_reduce_price` decimal(10,2) NOT NULL DEFAULT 0 COMMENT '满减活动优惠价格' AFTER `member_discount_price`; |
|
1480 |
ALTER TABLE `zjhj_bd_full_reduce_activity` MODIFY COLUMN `discount_rule` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '阶梯满减规则' AFTER `rule_type`, ADD COLUMN `loop_discount_rule` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '循环满减规则' AFTER `discount_rule`; |
|
1481 |
ALTER TABLE `zjhj_bd_printer_setting` ADD COLUMN `order_send_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `show_type`; |
|
1482 |
ALTER TABLE `zjhj_bd_delivery` ADD COLUMN `business_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 1 COMMENT '业务类型' AFTER `is_goods_alias`; |
|
1483 |
CREATE TABLE `zjhj_bd_goods_hot_search` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL COMMENT '商品id', `title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '热搜词', `type` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT 'goods 自动 hot-search 手动', `sort` smallint(2) NOT NULL DEFAULT 0 COMMENT '排序', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL, `deleted_at` timestamp(0) NOT NULL, PRIMARY KEY (`id`) USING BTREE, INDEX `mall_id`(`mall_id`, `type`, `is_delete`) USING BTREE, INDEX `goods_id`(`goods_id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1484 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `detail_count` int(11) NOT NULL DEFAULT 0 COMMENT '详情浏览量统计' AFTER `sales`; |
|
1485 |
ALTER TABLE `zjhj_bd_goods_cards` ADD COLUMN `is_allow_send` int(1) NOT NULL DEFAULT 0 COMMENT '是否允许转赠'; |
|
1486 |
EOF; |
|
1487 |
sql_execute($sql); |
|
1488 |
}, |
|
1489 |
'4.3.44' => function () { |
|
1490 |
$sql = <<<EOF |
|
1491 |
ALTER TABLE `zjhj_bd_user` ADD COLUMN `unionid` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `mobile`; |
|
1492 |
EOF; |
|
1493 |
sql_execute($sql); |
|
1494 |
}, |
|
1495 |
'4.3.45' => function () { |
|
1496 |
$sql = <<<EOF |
|
1497 |
ALTER TABLE `zjhj_bd_goods_services` ADD COLUMN `pic` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '商品服务标识' AFTER `name`; |
|
1498 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `guarantee_title` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '商品服务标题' AFTER `detail_count`, ADD COLUMN `guarantee_pic` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '商品服务标识' AFTER `guarantee_title`; |
|
1499 |
ALTER TABLE `zjhj_bd_vip_card_setting` ADD COLUMN `is_order_form` tinyint(1) NOT NULL DEFAULT 0 COMMENT '下单表单开关' AFTER `rules`, ADD COLUMN `order_form` text NULL AFTER `is_order_form`; |
|
1500 |
ALTER TABLE `zjhj_bd_goods_warehouse` ADD COLUMN `subtitle` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '副标题' AFTER `name`; |
|
1501 |
ALTER TABLE `zjhj_bd_share` ADD COLUMN `form` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '分销商自定义表单' AFTER `delete_first_show`; |
|
1502 |
ALTER TABLE `zjhj_bd_order_comments` ADD COLUMN `goods_info` longtext NULL COMMENT '商品信息' AFTER `is_top`; |
|
1503 |
ALTER TABLE `zjhj_bd_order_comments` ADD COLUMN `attr_id` int(11) NOT NULL DEFAULT 0 COMMENT '规格' AFTER `goods_info`; |
|
1504 |
ALTER TABLE `zjhj_bd_delivery` ADD COLUMN `kd100_business_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '快递100 业务类型' AFTER `is_goods`, ADD COLUMN `kd100_template` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '快递100 模板' AFTER `kd100_business_type`; |
|
1505 |
EOF; |
|
1506 |
sql_execute($sql); |
|
1507 |
}, |
|
1508 |
'4.3.52' => function () { |
|
1509 |
$sql = <<<EOF |
|
1510 |
CREATE TABLE `zjhj_bd_wholesale_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `goods_id` int(11) NOT NULL, `mall_id` int(11) NOT NULL, `type` tinyint(1) NOT NULL COMMENT '优惠方式,0折扣,1减钱\r\n', `wholesale_rules` varchar(2048) NOT NULL DEFAULT '' COMMENT '批发规则', `is_delete` tinyint(1) NOT NULL DEFAULT '0', `rise_num` int(11) NOT NULL DEFAULT '0' COMMENT '0不设置', `rules_status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '规则开关,0关闭,1开启', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='批发商品'; |
|
1511 |
CREATE TABLE `zjhj_bd_wholesale_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL DEFAULT '0', `order_id` int(11) NOT NULL DEFAULT '0', `discount` decimal(10,2) NOT NULL DEFAULT '0.00', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1512 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `param_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '参数名称' AFTER `guarantee_pic`, ADD COLUMN `param_content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '参数内容' AFTER `param_name`; |
|
1513 |
ALTER TABLE `zjhj_bd_coupon` ADD COLUMN `use_obtain` tinyint(1) NOT NULL DEFAULT 0 COMMENT '领取后赠送' AFTER `app_share_pic`; |
|
1514 |
ALTER TABLE `zjhj_bd_coupon_mall_relation` ADD COLUMN `order_id` int(11) NOT NULL COMMENT '订单id' AFTER `is_delete`, ADD COLUMN `type` varchar(20) NOT NULL COMMENT ' use优惠券自动发放' AFTER `order_id`; |
|
1515 |
alter table zjhj_bd_store add `extra_attributes` text not null; |
|
1516 |
EOF; |
|
1517 |
sql_execute($sql); |
|
1518 |
}, |
|
1519 |
'4.3.60' => function () { |
|
1520 |
$sql = <<<EOF |
|
1521 |
CREATE TABLE `zjhj_bd_wxapp_platform` ( `id` int(11) NOT NULL AUTO_INCREMENT, `appid` varchar(128) NOT NULL COMMENT '第三方平台应用appid', `appsecret` varchar(255) NOT NULL COMMENT '第三方平台应用appsecret', `token` varchar(255) NOT NULL COMMENT '第三方平台应用token(消息校验Token)', `encoding_aes_key` varchar(512) NOT NULL COMMENT '第三方平台应用Key(消息加解密Key)', `component_access_token` varchar(255) NOT NULL DEFAULT '', `token_expires` int(11) NOT NULL DEFAULT '0' COMMENT 'token过期时间', `type` tinyint(1) NOT NULL DEFAULT '2' COMMENT '授权类型\r\n1:公众号\r\n2:小程序\r\n3:公众号/小程序同时展现\r\n', `third_appid` varchar(128) NOT NULL COMMENT '第三方平台绑定的应用appid', `domain` longtext NOT NULL COMMENT '域名', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC; |
|
1522 |
CREATE TABLE `zjhj_bd_wxapp_wxminiprogram_audit` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'ID', `appid` varchar(45) NOT NULL DEFAULT '' COMMENT '小程序appid', `auditid` varchar(45) NOT NULL DEFAULT '' COMMENT '审核编号', `version` varchar(45) NOT NULL DEFAULT '', `template_id` int(11) NOT NULL COMMENT '模板id', `status` tinyint(1) unsigned NOT NULL DEFAULT '3' COMMENT '审核状态,其中0为审核成功,1为审核失败,2为审核中,3已提交审核, 4已发布', `reason` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT '' COMMENT '当status=1,审核被拒绝时,返回的拒绝原因', `created_at` timestamp NOT NULL COMMENT '提交审核时间', `release_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00', `is_delete` tinyint(4) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='微信小程序提交审核的小程序'; |
|
1523 |
CREATE TABLE `zjhj_bd_wxapp_wxminiprograms` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'ID', `mall_id` int(11) NOT NULL COMMENT '商城id', `nick_name` varchar(45) NOT NULL DEFAULT '' COMMENT '微信小程序名称', `token` varchar(45) NOT NULL DEFAULT '' COMMENT '平台生成的token值', `head_img` varchar(255) NOT NULL DEFAULT '' COMMENT '微信小程序头像', `verify_type_info` tinyint(1) NOT NULL DEFAULT '0' COMMENT '授权方认证类型,-1代表未认证,0代表微信认证', `is_show` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否显示,0显示,1隐藏', `user_name` varchar(45) NOT NULL DEFAULT '' COMMENT '原始ID', `qrcode_url` varchar(2048) NOT NULL DEFAULT '' COMMENT '二维码图片的URL', `business_info` varchar(2048) NOT NULL DEFAULT '' COMMENT 'json格式。用以了解以下功能的开通状况(0代表未开通,1代表已开通): open_store:是否开通微信门店功能 open_scan:是否开通微信扫商品功能 open_pay:是否开通微信支付功能 open_card:是否开通微信卡券功能 open_shake:是否开通微信摇一摇功能', `idc` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'idc', `principal_name` varchar(45) NOT NULL DEFAULT '' COMMENT '小程序的主体名称', `signature` varchar(255) NOT NULL DEFAULT '' COMMENT '帐号介绍', `miniprograminfo` varchar(255) NOT NULL DEFAULT '' COMMENT 'json格式。判断是否为小程序类型授权,包含network小程序已设置的各个服务器域名', `func_info` longtext COMMENT 'json格式。权限集列表,ID为17到19时分别代表: 17.帐号管理权限 18.开发管理权限 19.客服消息管理权限 请注意: 1)该字段的返回不会考虑小程序是否具备该权限集的权限(因为可能部分具备)。', `authorizer_appid` varchar(45) NOT NULL DEFAULT '' COMMENT '小程序appid', `authorizer_access_token` varchar(255) NOT NULL DEFAULT '' COMMENT '授权方接口调用凭据(在授权的公众号或小程序具备API权限时,才有此返回值),也简称为令牌', `authorizer_expires` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'refresh有效期', `authorizer_refresh_token` varchar(255) NOT NULL DEFAULT '' COMMENT '接口调用凭据刷新令牌', `created_at` timestamp NOT NULL COMMENT '授权时间', `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='微信小程序授权列表'; |
|
1524 |
ALTER TABLE `zjhj_bd_wxapp_config` MODIFY COLUMN `appid` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `mall_id`, MODIFY COLUMN `appsecret` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `appid`; |
|
1525 |
ALTER TABLE `zjhj_bd_wxapp_wxminiprograms` ADD COLUMN `domain` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '业务域名' AFTER `authorizer_refresh_token`; |
|
1526 |
EOF; |
|
1527 |
sql_execute($sql); |
|
1528 |
}, |
|
1529 |
'4.3.66' => function () { |
|
1530 |
$sql = <<<EOF |
|
1531 |
CREATE TABLE `zjhj_bd_wxapp_fast_create` ( `id` int(11) NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '企业名称' , `code` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '企业代码' , `code_type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '企业代码类型(1:统一社会信用代码, 2:组织机构代码,3:营业执照注册号)' , `legal_persona_wechat` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '法人微信' , `legal_persona_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '法人姓名' , `component_phone` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '第三方联系电话' , `md5` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '唯一标识' , `status` tinyint(4) NOT NULL DEFAULT '-2' , `appid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '创建小程序appid' , `auth_code` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '第三方授权码' , `updated_at` timestamp NOT NULL , `created_at` timestamp NOT NULL , `deleted_at` timestamp NOT NULL , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1 ROW_FORMAT=DYNAMIC ; |
|
1532 |
alter table zjhj_bd_live_goods modify column audit_id varchar(255) default null; |
|
1533 |
EOF; |
|
1534 |
sql_execute($sql); |
|
1535 |
}, |
|
1536 |
'4.3.68' => function () { |
|
1537 |
$sql = <<<EOF |
|
1538 |
CREATE TABLE `zjhj_bd_video_number_data` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT '0', `mch_id` int(11) DEFAULT '0', `type` varchar(255) DEFAULT NULL, `key` varchar(255) DEFAULT NULL, `value` varchar(255) DEFAULT NULL, `url` varchar(255) DEFAULT NULL, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` int(11) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=6 DEFAULT CHARSET=utf8mb4; |
|
1539 |
CREATE TABLE `zjhj_bd_video_number` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT '0', `mch_id` int(11) DEFAULT '0', `user_id` int(11) DEFAULT '0', `goods_id` int(11) DEFAULT '0', `media_id` varchar(255) DEFAULT NULL, `msg_id` varchar(255) DEFAULT NULL, `status` varchar(255) DEFAULT NULL, `extra_attributes` text, `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=26 DEFAULT CHARSET=utf8mb4; |
|
1540 |
EOF; |
|
1541 |
sql_execute($sql); |
|
1542 |
}, |
|
1543 |
'4.3.69' => function () { |
|
1544 |
$sql = <<<EOF |
|
1545 |
ALTER TABLE `zjhj_bd_order_express_single` MODIFY COLUMN `print_teplate` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `ebusiness_id`; |
|
1546 |
EOF; |
|
1547 |
sql_execute($sql); |
|
1548 |
}, |
|
1549 |
'4.3.70' => function () { |
|
1550 |
$sql = <<<EOF |
|
1551 |
ALTER TABLE `zjhj_bd_exchange_library` ADD COLUMN `is_limit` tinyint(1) NOT NULL DEFAULT 0 COMMENT '限制兑换' AFTER `deleted_at`, ADD COLUMN `limit_user_num` int(8) NOT NULL DEFAULT 0 COMMENT '每位用户每天限制兑换成功次数' AFTER `is_limit`, ADD COLUMN `limit_user_success_num` int(8) NOT NULL DEFAULT 0 COMMENT '永久兑换成功次数字' AFTER `limit_user_num`, ADD COLUMN `limit_user_type` varchar(8) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 'day' COMMENT '限制兑换类型 day all' AFTER `limit_user_success_num`; |
|
1552 |
ALTER TABLE `zjhj_bd_exchange_code_log` ADD COLUMN `library_id` int(11) NOT NULL COMMENT '库id'; |
|
1553 |
ALTER TABLE `zjhj_bd_delivery` ADD COLUMN `kd100_t_height` int(11) NOT NULL DEFAULT 150 COMMENT '打印纸高度' AFTER `kd100_template`,ADD COLUMN `kd100_t_width` int(11) NOT NULL DEFAULT 100 COMMENT '打印纸宽度' AFTER `kd100_t_height`; |
|
1554 |
EOF; |
|
1555 |
sql_execute($sql); |
|
1556 |
}, |
|
1557 |
'4.3.76' => function () { |
|
1558 |
$sql = <<<EOF |
|
1559 |
CREATE TABLE `zjhj_bd_pay_type` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '支付名称' , `type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '1:微信 2:支付宝' , `appid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `mchid` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `key` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `cert_pem` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `key_pem` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `is_service` tinyint(1) NOT NULL DEFAULT 0 COMMENT '是否为服务商支付 0否 1是' , `service_key` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `service_appid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '服务商appid' , `service_mchid` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '服务商mch_id' , `service_cert_pem` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `service_key_pem` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `is_auto_add` tinyint(4) NOT NULL DEFAULT 0 COMMENT '0否 1是' , `alipay_appid` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `app_private_key` varchar(2000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '支付宝应用私钥' , `alipay_public_key` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝平台公钥' , `appcert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL , `alipay_rootcert` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '支付宝根证书' , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , `updated_at` timestamp NOT NULL ON UPDATE CURRENT_TIMESTAMP , `created_at` timestamp NOT NULL , `deleted_at` timestamp NOT NULL , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1 ROW_FORMAT=DYNAMIC ; |
|
1560 |
CREATE TABLE `zjhj_bd_wechat_config` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `appid` varchar(255) NOT NULL DEFAULT '', `appsecret` varchar(255) NOT NULL DEFAULT '', `is_delete` tinyint(4) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `name` varchar(255) NOT NULL DEFAULT '', `logo` varchar(255) NOT NULL DEFAULT '', `qrcode` varchar(255) NOT NULL DEFAULT '', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1561 |
CREATE TABLE `zjhj_bd_wechat_template` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `tpl_name` varchar(65) NOT NULL DEFAULT '', `tpl_id` varchar(255) NOT NULL DEFAULT '', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1562 |
CREATE TABLE `zjhj_bd_wechat_wxmpprograms` ( `id` int(10) unsigned NOT NULL AUTO_INCREMENT COMMENT 'ID', `mall_id` int(11) NOT NULL COMMENT '商城id', `nick_name` varchar(45) DEFAULT '' COMMENT '公众号名称', `token` varchar(45) NOT NULL DEFAULT '' COMMENT '平台生成的token值', `head_img` varchar(255) NOT NULL DEFAULT '' COMMENT '公众号头像', `verify_type_info` tinyint(1) NOT NULL DEFAULT '0' COMMENT '授权方认证类型,-1代表未认证,0代表微信认证', `is_show` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否显示,0显示,1隐藏', `user_name` varchar(45) NOT NULL DEFAULT '' COMMENT '原始ID', `qrcode_url` varchar(2048) NOT NULL DEFAULT '' COMMENT '二维码图片的URL', `business_info` varchar(2048) NOT NULL DEFAULT '' COMMENT 'json格式。用以了解以下功能的开通状况(0代表未开通,1代表已开通): open_store:是否开通微信门店功能 open_scan:是否开通微信扫商品功能 open_pay:是否开通微信支付功能 open_card:是否开通微信卡券功能 open_shake:是否开通微信摇一摇功能', `idc` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'idc', `principal_name` varchar(45) NOT NULL DEFAULT '' COMMENT '公众号的主体名称', `signature` varchar(255) NOT NULL DEFAULT '' COMMENT '帐号介绍', `miniprograminfo` varchar(255) NOT NULL DEFAULT '' COMMENT 'json格式。判断是否为小程序类型授权,包含network小程序已设置的各个服务器域名', `func_info` longtext COMMENT 'json格式。权限集列表,ID为17到19时分别代表: 17.帐号管理权限 18.开发管理权限 19.客服消息管理权限 请注意: 1)该字段的返回不会考虑小程序是否具备该权限集的权限(因为可能部分具备)。', `authorizer_appid` varchar(45) NOT NULL DEFAULT '' COMMENT '公众号appid', `authorizer_access_token` varchar(255) NOT NULL DEFAULT '' COMMENT '授权方接口调用凭据(在授权的公众号或小程序具备API权限时,才有此返回值),也简称为令牌', `authorizer_expires` int(10) unsigned NOT NULL DEFAULT '0' COMMENT 'refresh有效期', `authorizer_refresh_token` varchar(255) NOT NULL DEFAULT '' COMMENT '接口调用凭据刷新令牌', `created_at` timestamp NOT NULL COMMENT '授权时间', `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, `is_delete` tinyint(1) NOT NULL DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=DYNAMIC COMMENT='公众号授权列表'; |
|
1563 |
CREATE TABLE `zjhj_bd_user_platform` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `platform` varchar(255) NOT NULL DEFAULT '' COMMENT '用户所属平台标识', `platform_id` varchar(255) NOT NULL DEFAULT '' COMMENT '用户所属平台的用户id', `password` varchar(255) NOT NULL DEFAULT '' COMMENT 'h5平台使用的密码', `unionid` varchar(255) NOT NULL DEFAULT '' COMMENT '微信平台使用的unionid', `subscribe` tinyint(1) NOT NULL DEFAULT '0' COMMENT '微信平台使用的是否关注', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4; |
|
1564 |
CREATE TABLE `zjhj_bd_user_center` ( `id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT , `mall_id` int(11) NOT NULL , `config` longblob NOT NULL , `is_delete` tinyint(1) NOT NULL DEFAULT 0 , `created_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `updated_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `deleted_at` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00' , `name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , `is_recycle` tinyint(1) NOT NULL DEFAULT 0 , `platform` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' , PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARACTER SET=utf8mb4 COLLATE=utf8mb4_general_ci AUTO_INCREMENT=1 ROW_FORMAT=DYNAMIC ; |
|
1565 |
ALTER TABLE `zjhj_bd_diy_page` ADD COLUMN `platform` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `deleted_at`; |
|
1566 |
ALTER TABLE `zjhj_bd_order` ADD COLUMN `platform` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT 'wxapp 微信小程序' AFTER `cancel_data`; |
|
1567 |
ALTER TABLE `zjhj_bd_payment_order_union` ADD COLUMN `platform` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' AFTER `app_version`; |
|
1568 |
EOF; |
|
1569 |
sql_execute($sql); |
|
1570 |
}, |
|
1571 |
'4.3.81' => function () { |
|
1572 |
$sql = <<<EOF |
|
1573 |
ALTER TABLE `zjhj_bd_wxapp_fast_create` MODIFY COLUMN `status` int(11) NOT NULL DEFAULT '-2' AFTER `md5`; |
|
1574 |
EOF; |
|
1575 |
sql_execute($sql); |
|
1576 |
}, |
|
1577 |
'4.3.82' => function () { |
|
1578 |
$sql = <<<EOF |
|
1579 |
ALTER TABLE `zjhj_bd_user_info` MODIFY COLUMN `total_balance` decimal(12, 2) NOT NULL COMMENT '总余额' AFTER `balance`; |
|
1580 |
EOF; |
|
1581 |
sql_execute($sql); |
|
1582 |
}, |
|
1583 |
'4.3.83' => function () { |
|
1584 |
$sql = <<<EOF |
|
1585 |
ALTER TABLE `zjhj_bd_user_info` MODIFY COLUMN `total_balance` decimal(12, 2) NOT NULL DEFAULT 0.00 COMMENT '总余额' AFTER `balance`; |
|
1586 |
EOF; |
|
1587 |
sql_execute($sql); |
|
1588 |
}, |
|
1589 |
'4.3.84' => function () { |
|
1590 |
$sql = <<<EOF |
|
1591 |
ALTER TABLE `zjhj_bd_lottery` ADD COLUMN `deplete_integral_num` int(11) NOT NULL DEFAULT 0 COMMENT '消耗积分' AFTER `buy_goods_id`; |
|
1592 |
CREATE TABLE `zjhj_bd_goods_params_template` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT 0, `name` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '模板名称', `content` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '参数内容', `select_data` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL COMMENT '搜索使用', `is_delete` tinyint(1) NOT NULL DEFAULT 0, `created_at` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) ON UPDATE CURRENT_TIMESTAMP(0), `deleted_at` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00', PRIMARY KEY (`id`) USING BTREE ) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic; |
|
1593 |
EOF; |
|
1594 |
sql_execute($sql); |
|
1595 |
}, |
|
1596 |
'4.3.87' => function () { |
|
1597 |
$sql = <<<EOF |
|
1598 |
ALTER TABLE `zjhj_bd_order_express_single` ADD COLUMN `order_detail_id` int(11) NOT NULL DEFAULT 0 AFTER `deleted_at`; |
|
1599 |
EOF; |
|
1600 |
sql_execute($sql); |
|
1601 |
}, |
|
1602 |
'4.3.89' => function () { |
|
1603 |
$sql = <<<EOF |
|
1604 |
ALTER TABLE `zjhj_bd_scan_code_pay_activities_groups_rules` ADD COLUMN `send_money_type` tinyint(1) NOT NULL DEFAULT 1 COMMENT '赠送余额类型1.固定2.百分比' AFTER `send_money`; |
|
1605 |
ALTER TABLE `zjhj_bd_lottery_setting` ADD COLUMN `bg_pic` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景图' AFTER `is_print`, ADD COLUMN `bg_color` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景颜色' AFTER `bg_pic`, ADD COLUMN `bg_color_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景颜色类型' AFTER `bg_color`, ADD COLUMN `bg_gradient_color` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '背景渐变颜色' AFTER `bg_color_type`; |
|
1606 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `limit_buy_status` smallint(1) NOT NULL DEFAULT 1 COMMENT '限购状态0--关闭 1--开启', ADD COLUMN `limit_buy_type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT 'day' COMMENT '限购类型 day--每天 week--每周 month--每月 all--永久', ADD COLUMN `limit_buy_value` int(11) NOT NULL DEFAULT -1 COMMENT '限购数量', ADD COLUMN `min_number` int(11) NOT NULL DEFAULT 1 COMMENT '起售数量', ADD COLUMN `is_setting_show_and_buy_auth` smallint(1) NOT NULL DEFAULT 0 COMMENT '是否单独设置浏览和购买权限', ADD COLUMN `show_goods_auth` varchar(255) NOT NULL DEFAULT '-1' COMMENT '会员等级浏览权限', ADD COLUMN `buy_goods_auth` varchar(255) NOT NULL DEFAULT '-1' COMMENT '会员等级购买权限'; |
|
1607 |
EOF; |
|
1608 |
sql_execute($sql); |
|
1609 |
}, |
|
1610 |
'4.4.1' => function () { |
|
1611 |
$sql = <<<EOF |
|
1612 |
ALTER TABLE `zjhj_bd_user_info` ADD COLUMN `pay_password` VARCHAR(255) NOT NULL DEFAULT '' COMMENT '支付密码'; |
|
1613 |
ALTER TABLE `zjhj_bd_order_detail` ADD COLUMN `erase_price` decimal(10, 2) NOT NULL DEFAULT 0 COMMENT '抹零价格' AFTER `member_discount_price`; |
|
1614 |
CREATE TABLE `zjhj_bd_teller_cashier` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL COMMENT '用户ID', `number` varchar(255) NOT NULL COMMENT '收银员编号', `store_id` int(11) NOT NULL DEFAULT '0' COMMENT '门店ID', `creator_id` int(11) NOT NULL COMMENT '创建者ID', `status` tinyint(1) DEFAULT '0' COMMENT '状态0.不启用|1.启用', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '提成总金额', `sale_money` decimal(10,2) DEFAULT '0.00' COMMENT '销售总金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`), KEY `index` (`mall_id`,`mch_id`,`user_id`,`store_id`,`creator_id`,`status`,`is_delete`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=43 DEFAULT CHARSET=utf8mb4; |
|
1615 |
CREATE TABLE `zjhj_bd_teller_orders` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `order_id` int(11) DEFAULT '0' COMMENT '订单ID', `re_order_id` int(11) DEFAULT '0' COMMENT '充值订单ID', `cashier_id` int(11) DEFAULT NULL COMMENT '收银员ID', `sales_id` int(11) DEFAULT '0' COMMENT '导购员ID', `order_type` varchar(255) DEFAULT NULL COMMENT '订单类型', `add_money` decimal(10,2) DEFAULT '0.00' COMMENT '订单加价', `change_price_type` varchar(255) DEFAULT NULL COMMENT '改价类型 加价|减价', `change_price` decimal(10,2) DEFAULT '0.00' COMMENT '订单改价金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `is_refund` tinyint(1) DEFAULT '0' COMMENT '是否有退款0.否|1.是', `refund_money` decimal(10,2) DEFAULT '0.00' COMMENT '退款总金额', `order_query` int(11) DEFAULT '0' COMMENT '付款码订单查询次数', `is_pay` int(11) DEFAULT '0' COMMENT '是否支付0.未付款|1.已付款', `pay_type` int(11) DEFAULT '0' COMMENT '支付方式', `work_log_id` int(11) DEFAULT '0' COMMENT '交班记录ID', `is_statistics` tinyint(1) DEFAULT '0' COMMENT '是否统计0.否|1.是', PRIMARY KEY (`id`), KEY `index` (`mall_id`,`mch_id`,`order_id`,`re_order_id`,`cashier_id`,`sales_id`,`order_type`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=694 DEFAULT CHARSET=utf8mb4; |
|
1616 |
CREATE TABLE `zjhj_bd_teller_printer_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `store_id` int(11) DEFAULT '0', `printer_id` int(11) NOT NULL COMMENT '打印机id', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0关闭 1启用', `type` text COMMENT '打印类型', `order_send_type` text COMMENT '发货方式', `show_type` longtext NOT NULL COMMENT 'attr 规格 goods_no 货号 form_data 下单表单', `big` int(11) NOT NULL DEFAULT '0' COMMENT '倍数', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`), KEY `mch_id` (`mch_id`), KEY `is_delete` (`is_delete`), KEY `mall_id` (`mall_id`), KEY `status` (`status`), KEY `store_id` (`store_id`) ) ENGINE=InnoDB AUTO_INCREMENT=71 DEFAULT CHARSET=utf8mb4; |
|
1617 |
CREATE TABLE `zjhj_bd_teller_push_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `user_type` varchar(65) DEFAULT NULL COMMENT '用户类型', `order_type` varchar(65) DEFAULT NULL COMMENT '订单类型', `teller_order_id` int(11) NOT NULL COMMENT '收银台订单ID', `order_id` int(11) NOT NULL DEFAULT '0' COMMENT '订单ID', `re_order_id` int(11) DEFAULT '0' COMMENT '充值订单ID', `push_type` varchar(65) DEFAULT NULL COMMENT '提成类型', `push_order_money` decimal(10,2) DEFAULT '0.00' COMMENT '按订单提成金额 ', `push_percent` decimal(10,2) DEFAULT '0.00' COMMENT '按百分比提成', `sales_id` int(11) DEFAULT '0' COMMENT '导购员ID', `cashier_id` int(11) DEFAULT '0' COMMENT '收银员ID', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '订单过售后最终提成金额', `status` varchar(255) DEFAULT NULL COMMENT '订单状态', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`), KEY `index` (`mall_id`,`mch_id`,`user_type`,`order_type`,`order_id`,`re_order_id`,`push_type`,`sales_id`,`cashier_id`,`status`) ) ENGINE=InnoDB AUTO_INCREMENT=768 DEFAULT CHARSET=utf8mb4; |
|
1618 |
CREATE TABLE `zjhj_bd_teller_sales` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `number` varchar(255) NOT NULL COMMENT '导购员编号', `name` varchar(255) NOT NULL COMMENT '姓名', `head_url` varchar(255) NOT NULL COMMENT '头像', `mobile` varchar(255) NOT NULL COMMENT '电话', `store_id` int(11) NOT NULL DEFAULT '0' COMMENT '门店ID', `creator_id` int(11) NOT NULL COMMENT '创建者ID', `status` tinyint(1) DEFAULT '0' COMMENT '状态0.不启用|1.启用', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '提成总金额', `sale_money` decimal(10,2) DEFAULT '0.00' COMMENT '销售总金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`), KEY `index` (`mall_id`,`mch_id`,`store_id`,`creator_id`,`status`,`is_delete`) ) ENGINE=InnoDB AUTO_INCREMENT=22 DEFAULT CHARSET=utf8mb4; |
|
1619 |
CREATE TABLE `zjhj_bd_teller_work_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `store_id` int(11) DEFAULT '0' COMMENT '门店ID', `start_time` timestamp NULL DEFAULT NULL COMMENT '上班时间', `end_time` timestamp NULL DEFAULT NULL COMMENT '交班时间', `cashier_id` int(11) DEFAULT NULL COMMENT '收银员ID', `status` varchar(255) DEFAULT NULL COMMENT '交班状态pending 上班中|finish 交班完成', `extra_attributes` text COMMENT '交班详细信息', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` int(11) DEFAULT '0', PRIMARY KEY (`id`), KEY `index` (`mall_id`,`mch_id`,`store_id`,`cashier_id`,`status`,`is_delete`) USING BTREE ) ENGINE=InnoDB AUTO_INCREMENT=77 DEFAULT CHARSET=utf8mb4; |
|
1620 |
ALTER TABLE `zjhj_bd_goods_attr` ADD COLUMN `bar_code` varchar(255) NOT NULL DEFAULT '' COMMENT '条形码' AFTER `pic_url`; |
|
1621 |
EOF; |
|
1622 |
sql_execute($sql); |
|
1623 |
}, |
|
1624 |
'4.4.2' => function () { |
|
1625 |
$sql = <<<EOF |
|
1626 |
CREATE TABLE `zjhj_bd_teller_cashier` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `user_id` int(11) NOT NULL COMMENT '用户ID', `number` varchar(255) NOT NULL COMMENT '收银员编号', `store_id` int(11) NOT NULL DEFAULT '0' COMMENT '门店ID', `creator_id` int(11) NOT NULL COMMENT '创建者ID', `status` tinyint(1) DEFAULT '0' COMMENT '状态0.不启用|1.启用', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '提成总金额', `sale_money` decimal(10,2) DEFAULT '0.00' COMMENT '销售总金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1627 |
CREATE TABLE `zjhj_bd_teller_orders` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `order_id` int(11) DEFAULT '0' COMMENT '订单ID', `re_order_id` int(11) DEFAULT '0' COMMENT '充值订单ID', `cashier_id` int(11) DEFAULT NULL COMMENT '收银员ID', `sales_id` int(11) DEFAULT '0' COMMENT '导购员ID', `order_type` varchar(255) DEFAULT NULL COMMENT '订单类型', `add_money` decimal(10,2) DEFAULT '0.00' COMMENT '订单加价', `change_price_type` varchar(255) DEFAULT NULL COMMENT '改价类型 加价|减价', `change_price` decimal(10,2) DEFAULT '0.00' COMMENT '订单改价金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `is_refund` tinyint(1) DEFAULT '0' COMMENT '是否有退款0.否|1.是', `refund_money` decimal(10,2) DEFAULT '0.00' COMMENT '退款总金额', `order_query` int(11) DEFAULT '0' COMMENT '付款码订单查询次数', `is_pay` int(11) DEFAULT '0' COMMENT '是否支付0.未付款|1.已付款', `pay_type` int(11) DEFAULT '0' COMMENT '支付方式', `work_log_id` int(11) DEFAULT '0' COMMENT '交班记录ID', `is_statistics` tinyint(1) DEFAULT '0' COMMENT '是否统计0.否|1.是', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1628 |
CREATE TABLE `zjhj_bd_teller_printer_setting` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `store_id` int(11) DEFAULT '0', `printer_id` int(11) NOT NULL COMMENT '打印机id', `status` tinyint(1) NOT NULL DEFAULT '0' COMMENT '0关闭 1启用', `type` text COMMENT '打印类型', `order_send_type` text COMMENT '发货方式', `show_type` longtext NOT NULL COMMENT 'attr 规格 goods_no 货号 form_data 下单表单', `big` int(11) NOT NULL DEFAULT '0' COMMENT '倍数', `is_delete` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1629 |
CREATE TABLE `zjhj_bd_teller_push_order` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `user_type` varchar(65) DEFAULT NULL COMMENT '用户类型', `order_type` varchar(65) DEFAULT NULL COMMENT '订单类型', `teller_order_id` int(11) NOT NULL COMMENT '收银台订单ID', `order_id` int(11) NOT NULL DEFAULT '0' COMMENT '订单ID', `re_order_id` int(11) DEFAULT '0' COMMENT '充值订单ID', `push_type` varchar(65) DEFAULT NULL COMMENT '提成类型', `push_order_money` decimal(10,2) DEFAULT '0.00' COMMENT '按订单提成金额 ', `push_percent` decimal(10,2) DEFAULT '0.00' COMMENT '按百分比提成', `sales_id` int(11) DEFAULT '0' COMMENT '导购员ID', `cashier_id` int(11) DEFAULT '0' COMMENT '收银员ID', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '订单过售后最终提成金额', `status` varchar(255) DEFAULT NULL COMMENT '订单状态', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1630 |
CREATE TABLE `zjhj_bd_teller_sales` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `mch_id` int(11) NOT NULL DEFAULT '0', `number` varchar(255) NOT NULL COMMENT '导购员编号', `name` varchar(255) NOT NULL COMMENT '姓名', `head_url` varchar(255) NOT NULL COMMENT '头像', `mobile` varchar(255) NOT NULL COMMENT '电话', `store_id` int(11) NOT NULL DEFAULT '0' COMMENT '门店ID', `creator_id` int(11) NOT NULL COMMENT '创建者ID', `status` tinyint(1) DEFAULT '0' COMMENT '状态0.不启用|1.启用', `push_money` decimal(10,2) DEFAULT '0.00' COMMENT '提成总金额', `sale_money` decimal(10,2) DEFAULT '0.00' COMMENT '销售总金额', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` tinyint(1) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1631 |
CREATE TABLE `zjhj_bd_teller_work_log` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT NULL, `mch_id` int(11) DEFAULT '0', `store_id` int(11) DEFAULT '0' COMMENT '门店ID', `start_time` timestamp NULL DEFAULT NULL COMMENT '上班时间', `end_time` timestamp NULL DEFAULT NULL COMMENT '交班时间', `cashier_id` int(11) DEFAULT NULL COMMENT '收银员ID', `status` varchar(255) DEFAULT NULL COMMENT '交班状态pending 上班中|finish 交班完成', `extra_attributes` text COMMENT '交班详细信息', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, `is_delete` int(11) DEFAULT '0', PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1632 |
EOF; |
|
1633 |
sql_execute($sql); |
|
1634 |
}, |
|
1635 |
'4.4.5' => function () { |
|
1636 |
$sql = <<<EOF |
|
1637 |
ALTER TABLE `zjhj_bd_store` ADD COLUMN `status` tinyint(1) NOT NULL DEFAULT 1 COMMENT '状态开关' AFTER `extra_attributes`; |
|
1638 |
ALTER TABLE `zjhj_bd_diy_page` ADD COLUMN `access_limit` longtext CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL AFTER `platform`; |
|
1639 |
ALTER TABLE `zjhj_bd_goods` ADD COLUMN `is_setting_send_type` smallint(1) NOT NULL DEFAULT 0 COMMENT '是否单独设置发货方式0--否 1--是', ADD COLUMN `send_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '发货方式', ADD COLUMN `is_time` smallint(1) NOT NULL DEFAULT 0 COMMENT '是否单独设置销售时间', ADD COLUMN `sell_begin_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '开售时间', ADD COLUMN `sell_end_time` timestamp(0) NOT NULL DEFAULT '0000-00-00 00:00:00' COMMENT '结束时间'; |
|
1640 |
CREATE TABLE `zjhj_bd_goods_remind` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) NOT NULL, `goods_id` int(11) NOT NULL, `user_id` int(11) NOT NULL, `is_remind` smallint(1) NOT NULL DEFAULT '0' COMMENT '是否提醒', `is_delete` smallint(1) NOT NULL DEFAULT '0', `created_at` timestamp NOT NULL, `updated_at` timestamp NOT NULL, `deleted_at` timestamp NOT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1641 |
CREATE TABLE `zjhj_bd_core_file` ( `id` int(11) NOT NULL AUTO_INCREMENT, `mall_id` int(11) DEFAULT '0', `mch_id` int(11) DEFAULT '0', `file_name` varchar(255) DEFAULT '' COMMENT '文件名称', `percent` decimal(11,2) DEFAULT '0.00' COMMENT '下载进度', `status` tinyint(1) DEFAULT '0' COMMENT '是否完成', `is_delete` tinyint(1) DEFAULT '0', `created_at` timestamp NULL DEFAULT NULL, `updated_at` timestamp NULL DEFAULT NULL, `deleted_at` timestamp NULL DEFAULT NULL, PRIMARY KEY (`id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4; |
|
1642 |
ALTER TABLE `zjhj_bd_goods_remind` ADD COLUMN `remind_at` timestamp NOT NULL COMMENT '提醒时间'; |
|
1643 |
EOF; |
|
1644 |
sql_execute($sql); |
|
1645 |
} |
|
1646 |
]; |