sql.txt 63 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150
  1. 
  2. CREATE TABLE `oscshop_lionfish_comshop_member_integral_flow` (
  3. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  4. `member_id` int(10) NOT NULL COMMENT '会员id',
  5. `in_out` enum('in','out') NOT NULL COMMENT '增加积分,还是减少积分',
  6. `type` enum('goodsbuy','refundorder','system_add','system_del','orderbuy') NOT NULL COMMENT '积分获赠/减少 类型',
  7. `order_id` int(10) DEFAULT NULL COMMENT '订单id',
  8. `order_goods_id` int(10) DEFAULT NULL COMMENT '订单商品id',
  9. `score` float(10,2) DEFAULT '0.00' COMMENT '积分数量',
  10. `after_operate_score` float(10,2) DEFAULT '0.00' COMMENT '操作后的积分',
  11. `state` tinyint(1) DEFAULT '0' COMMENT '0 还未赠送,1处理成功,',
  12. `remark` varchar(255) DEFAULT NULL COMMENT '说明',
  13. `addtime` int(10) NOT NULL COMMENT '添加时间',
  14. PRIMARY KEY (`id`)
  15. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='积分流水记录表';
  16. ALTER TABLE `oscshop_lionfish_community_head` ADD `agent_id` INT(10) NULL DEFAULT '0' COMMENT '推荐人id' AFTER `member_id`, ADD INDEX (`agent_id`);
  17. CREATE TABLE `oscshop_lionfish_community_head_invite_recod` (
  18. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  19. `head_id` INT(10) NOT NULL COMMENT '团长id' ,
  20. `agent_member_id` INT(10) NOT NULL COMMENT '推荐人id' ,
  21. `money` FLOAT(10,2) NOT NULL COMMENT '奖励金额' ,
  22. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  23. PRIMARY KEY (`id`), INDEX (`head_id`), INDEX (`agent_member_id`)
  24. ) ENGINE = InnoDB COMMENT = '狮子鱼团长推荐团长记录表';
  25. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `type` ENUM('orderbuy','commiss','tuijian') NOT NULL DEFAULT 'orderbuy' COMMENT 'orderbuy 团员订单购买 ,commiss 下级的会员订单购买,tuijian 推荐团长的佣金' AFTER `head_id`;
  26. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `child_head_id` INT(10) NULL DEFAULT '0' COMMENT '下级团长id' AFTER `head_id`;
  27. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `level` INT(10) NULL DEFAULT '0' COMMENT '第几层分佣' AFTER `type`;
  28. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_community_head_level` (
  29. `id` int(10) NOT NULL COMMENT '自增id',
  30. `levelname` varchar(255) NOT NULL COMMENT '等级名称',
  31. `commission1` float(10,2) DEFAULT '0.00' COMMENT '1级分销比例',
  32. `commission2` float(10,2) DEFAULT '0.00' COMMENT '2级分销比例',
  33. `commission3` float(10,2) DEFAULT '0.00' COMMENT '3级分销比例'
  34. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼商城团长等级表';
  35. ALTER TABLE `oscshop_lionfish_comshop_community_head_level`
  36. ADD PRIMARY KEY (`id`);
  37. ALTER TABLE `oscshop_lionfish_comshop_community_head_level`
  38. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id';
  39. ALTER TABLE `oscshop_lionfish_community_head` ADD `level_id` INT(10) NULL DEFAULT '0' COMMENT '团长等级id' AFTER `agent_id`;
  40. ALTER TABLE `oscshop_lionfish_comshop_community_head_level` CHANGE `commission1` `commission` FLOAT(10,2) NULL DEFAULT '0.00' COMMENT '分销比例';
  41. ALTER TABLE `oscshop_lionfish_comshop_community_head_level` DROP `commission2`, DROP `commission3`;
  42. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_modify_head_commission` TINYINT(1) NULL DEFAULT '0' COMMENT '是否开启独立配置团长等级分佣' AFTER `community_head_commission`, ADD `community_head_commission_modify` TEXT NULL COMMENT '自定义团长等级分佣配置信息' AFTER `is_modify_head_commission`;
  43. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `bili` FLOAT(10,2) NULL DEFAULT '0' COMMENT '分销分佣比例' AFTER `type`;
  44. ALTER TABLE `oscshop_lionfish_comshop_member` CHANGE `score` `score` FLOAT(10,2) NULL DEFAULT '0' COMMENT '积分';
  45. V2.6.0
  46. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow` ADD `operate_end_yuer` FLOAT(10,2) NULL DEFAULT '0' COMMENT '当前操作结束后余额' AFTER `money`;
  47. V2.0
  48. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `login_name` VARCHAR(50) NULL COMMENT '供应商登录名称' AFTER `apptime`, ADD `login_password` VARCHAR(100) NULL COMMENT '供应商登录密码' AFTER `login_name`, ADD `login_slat` VARCHAR(50) NULL COMMENT '密码盐值' AFTER `login_password`;
  49. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `fullreduction_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '满减金额' AFTER `oldprice`, ADD `voucher_credit` FLOAT(10,2) NULL DEFAULT '0' COMMENT '优惠券优惠金额' AFTER `fullreduction_money`;
  50. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `fenbi_li` FLOAT(10,2) NULL DEFAULT '0' COMMENT '订单中金额占比' AFTER `voucher_credit`;
  51. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `type` TINYINT(1) NULL DEFAULT '0' COMMENT '0 平台自营,1入驻' AFTER `state`;
  52. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `commiss_bili` INT(10) NULL DEFAULT '0' COMMENT '供应商提成。百分比' AFTER `type`;
  53. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_supply_commiss_order` (
  54. `id` int(10) NOT NULL COMMENT '自增ID',
  55. `supply_id` int(10) NOT NULL COMMENT '供应商id',
  56. `order_id` int(10) NOT NULL COMMENT '订单ID',
  57. `order_goods_id` int(10) DEFAULT '0' COMMENT '商品订单id',
  58. `state` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否结算:0,待计算。1,已结算。2,订单取消',
  59. `money` float(10,2) NOT NULL DEFAULT '0.00' COMMENT '分佣金额',
  60. `addtime` int(10) NOT NULL COMMENT '添加时间'
  61. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  62. ALTER TABLE `oscshop_lionfish_supply_commiss_order`
  63. ADD PRIMARY KEY (`id`),
  64. ADD KEY `supply_id` (`supply_id`);
  65. ALTER TABLE `oscshop_lionfish_supply_commiss_order`
  66. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增ID';
  67. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_supply_commiss` (
  68. `id` int(10) NOT NULL COMMENT '自增ID',
  69. `supply_id` int(10) NOT NULL COMMENT '供应商ID',
  70. `money` float(10,2) DEFAULT '0.00' COMMENT '可提现金额',
  71. `dongmoney` float(10,2) DEFAULT '0.00' COMMENT '提现中金额',
  72. `getmoney` float(10,2) DEFAULT '0.00' COMMENT '已提现金额'
  73. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  74. ALTER TABLE `oscshop_lionfish_supply_commiss`
  75. ADD PRIMARY KEY (`id`),
  76. ADD KEY `supply_id` (`supply_id`);
  77. ALTER TABLE `oscshop_lionfish_supply_commiss`
  78. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增ID';
  79. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_supply_tixian_order` (
  80. `id` int(10) NOT NULL COMMENT '自增id',
  81. `supply_id` int(10) NOT NULL COMMENT '团长id',
  82. `money` float(10,2) NOT NULL COMMENT '提现金额',
  83. `service_charge` float(10,2) DEFAULT '0.00' COMMENT '手续费',
  84. `state` tinyint(1) NOT NULL COMMENT '提现状态,0申请中,1提现成功,2体现失败',
  85. `shentime` int(10) NOT NULL COMMENT '审核时间',
  86. `is_send_fail` tinyint(1) DEFAULT '0' COMMENT '是否发送是否,1是,0否',
  87. `fail_msg` varchar(255) DEFAULT NULL COMMENT '发送失败原因',
  88. `addtime` int(10) NOT NULL COMMENT '提交时间'
  89. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='分销佣金提现表';
  90. ALTER TABLE `oscshop_lionfish_supply_tixian_order`
  91. ADD PRIMARY KEY (`id`),
  92. ADD KEY `supply_id` (`supply_id`);
  93. ALTER TABLE `oscshop_lionfish_supply_tixian_order`
  94. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id';
  95. ALTER TABLE `oscshop_lionfish_supply_commiss_order` ADD `total_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '总金额' AFTER `order_goods_id`, ADD `comunity_blili` FLOAT(10,2) NULL DEFAULT '0' COMMENT '服务费比例' AFTER `total_money`;
  96. ALTER TABLE `oscshop_lionfish_supply_commiss_order` ADD `head_commiss_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '团长分佣金额' AFTER `state`;
  97. ALTER TABLE `oscshop_lionfish_supply_tixian_order` ADD `bankname` VARCHAR(200) NULL COMMENT '转账类型。微信,支付宝,银行' AFTER `fail_msg`, ADD `bankaccount` VARCHAR(200) NULL COMMENT '账户' AFTER `bankname`, ADD `bankusername` VARCHAR(200) NULL COMMENT '持卡人姓名' AFTER `bankaccount`;
  98. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_member_charge_flow` (
  99. `id` int(10) NOT NULL COMMENT '自增id',
  100. `formid` varchar(255) DEFAULT NULL COMMENT '充值时候的prepayid',
  101. `member_id` int(10) NOT NULL COMMENT '会员id',
  102. `trans_id` varchar(100) DEFAULT NULL COMMENT '交易号',
  103. `money` decimal(10,2) NOT NULL COMMENT '充值金额',
  104. `state` tinyint(1) NOT NULL COMMENT '0,未支付,1已支付,3余额付款,4退款到余额,5后台充值,6 裂变红包,7 会员升级,8后台扣款',
  105. `charge_time` int(10) NOT NULL COMMENT '充值时间',
  106. `remark` varchar(255) DEFAULT NULL COMMENT '充值描述',
  107. `add_time` int(10) NOT NULL COMMENT '添加时间'
  108. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='狮子鱼商城会员充值记录表';
  109. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow`
  110. ADD PRIMARY KEY (`id`),
  111. ADD KEY `member_id` (`member_id`);
  112. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow`
  113. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id';
  114. CREATE TABLE `oscshop_lionfish_comshop_community_pickup_member` (
  115. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  116. `community_id` INT(10) NOT NULL COMMENT '社区id' ,
  117. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  118. `state` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '状态,0未审核,1审核通过' ,
  119. `remark` VARCHAR(255) NULL COMMENT '备注' ,
  120. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  121. PRIMARY KEY (`id`), INDEX (`member_id`), INDEX (`community_id`)
  122. ) ENGINE = InnoDB COMMENT = '核销人员表';
  123. CREATE TABLE `oscshop_lionfish_comshop_community_pickup_member_record` (
  124. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  125. `order_id` INT(10) NOT NULL COMMENT '订单id' ,
  126. `community_id` INT(10) NOT NULL COMMENT '社区id' ,
  127. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  128. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  129. PRIMARY KEY (`id`), INDEX (`order_id`)
  130. ) ENGINE = InnoDB COMMENT = '核销员核销记录';
  131. ALTER TABLE `oscshop_lionfish_comshop_member` ADD `pickup_id` INT(10) NULL DEFAULT '0' COMMENT '自提关联id' AFTER `last_login_ip`;
  132. ALTER TABLE `oscshop_lionfish_comshop_community_pickup_member_record` ADD `order_sn` VARCHAR(100) NULL COMMENT '订单编号' AFTER `order_id`;
  133. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `last_refund_order_status_id` INT(10) NULL DEFAULT '0' COMMENT '申请退款时,该订单的上一订单状态' AFTER `order_status_id`;
  134. V1.8.1
  135. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_member_shopinfo` (
  136. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  137. `member_id` int(10) NOT NULL COMMENT '会员id',
  138. `shop_name` varchar(255) NOT NULL COMMENT '店铺名称',
  139. `shop_mobile` varchar(50) NOT NULL COMMENT '店铺手机号',
  140. `imgGroup` text COMMENT '营业执照',
  141. `otherImgGroup` text COMMENT '其他证件',
  142. `state` tinyint(1) NOT NULL COMMENT '状态',
  143. `addtime` int(10) NOT NULL COMMENT '申请时间',
  144. PRIMARY KEY (`id`),
  145. KEY `member_id` (`member_id`)
  146. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='狮子鱼商城用户店铺申请表' AUTO_INCREMENT=1 ;
  147. V1.8.0
  148. ALTER TABLE `oscshop_lionfish_community_head` ADD `rest` TINYINT(1) NULL DEFAULT '0' COMMENT '团长休息' AFTER `enable`;
  149. ALTER TABLE `oscshop_lionfish_comshop_address` ADD `lon_lat` VARCHAR(30) NULL DEFAULT '' COMMENT '地址经纬度' AFTER `address_name`;
  150. ALTER TABLE `oscshop_lionfish_comshop_address` ADD `lou_meng_hao` VARCHAR(100) NULL DEFAULT '' COMMENT '门牌号-楼号' AFTER `lon_lat`;
  151. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_jiauser` (
  152. `id` bigint(20) unsigned NOT NULL,
  153. `username` varchar(32) DEFAULT NULL,
  154. `avatar` varchar(255) DEFAULT NULL,
  155. `mobile` varchar(16) DEFAULT NULL
  156. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  157. ALTER TABLE `oscshop_lionfish_comshop_jiauser`
  158. ADD PRIMARY KEY (`id`);
  159. ALTER TABLE `oscshop_lionfish_comshop_jiauser`
  160. MODIFY `id` bigint(20) unsigned NOT NULL AUTO_INCREMENT;
  161. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_member_level` (
  162. `id` int(10) NOT NULL COMMENT '自增id',
  163. `level` int(11) NOT NULL COMMENT '等级',
  164. `levelname` varchar(100) NOT NULL COMMENT '等级名称',
  165. `level_money` decimal(10,2) DEFAULT '0.00' COMMENT '会员升级金额',
  166. `discount` decimal(10,2) NOT NULL DEFAULT '0.00' COMMENT '折扣',
  167. `logo` varchar(255) DEFAULT NULL COMMENT '会员等级logo'
  168. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='会员等级表';
  169. ALTER TABLE `oscshop_lionfish_comshop_member_level`
  170. ADD PRIMARY KEY (`id`);
  171. ALTER TABLE `oscshop_lionfish_comshop_member_level`
  172. MODIFY `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id';
  173. V1.6.0
  174. ALTER TABLE `oscshop_lionfish_comshop_goods_tags` ADD `type` TINYINT(1) NULL DEFAULT '0' COMMENT '类型:0文字 1图片' AFTER `tagname`;
  175. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `print_sub_title` VARCHAR(200) NULL COMMENT '商品打印简短标题' AFTER `share_title`;
  176. V1.5.0
  177. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_perm_role` (
  178. `id` int(11) NOT NULL AUTO_INCREMENT,
  179. `rolename` varchar(255) DEFAULT '',
  180. `status` tinyint(3) DEFAULT '0',
  181. `perms` text,
  182. `deleted` tinyint(3) DEFAULT '0',
  183. `perms2` text,
  184. PRIMARY KEY (`id`),
  185. KEY `idx_status` (`status`),
  186. KEY `idx_deleted` (`deleted`)
  187. ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=5 ;
  188. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_perm_user` (
  189. `id` int(11) NOT NULL AUTO_INCREMENT,
  190. `uniacid` int(11) DEFAULT '0',
  191. `uid` int(11) DEFAULT '0',
  192. `username` varchar(255) DEFAULT '',
  193. `password` varchar(255) DEFAULT '',
  194. `roleid` int(11) DEFAULT '0',
  195. `status` int(11) DEFAULT '0',
  196. `perms` text,
  197. `deleted` tinyint(3) DEFAULT '0',
  198. `realname` varchar(255) DEFAULT '',
  199. `mobile` varchar(255) DEFAULT '',
  200. `perms2` text,
  201. `openid` varchar(50) DEFAULT NULL,
  202. `openid_wa` varchar(50) DEFAULT NULL,
  203. `member_nick` varchar(50) DEFAULT NULL,
  204. PRIMARY KEY (`id`),
  205. KEY `idx_uniacid` (`uniacid`),
  206. KEY `idx_uid` (`uid`),
  207. KEY `idx_roleid` (`roleid`),
  208. KEY `idx_status` (`status`),
  209. KEY `idx_deleted` (`deleted`)
  210. ) ENGINE=MyISAM DEFAULT CHARSET=utf8 AUTO_INCREMENT=2 ;
  211. ALTER TABLE `oscshop_seller` ADD `roleid` INT( 11 ) NULL COMMENT '角色id',
  212. ADD `perms` TEXT NULL COMMENT '权限',
  213. ADD `deleted` TINYINT( 1 ) NULL DEFAULT '0' COMMENT '是否禁用';
  214. ALTER TABLE `oscshop_seller` DROP `we_hexiao_qrcode`;
  215. ALTER TABLE `oscshop_seller`
  216. DROP `s_logo`,
  217. DROP `s_banner`,
  218. DROP `certification`,
  219. DROP `s_descript`,
  220. DROP `s_qrcode`,
  221. DROP `s_telephone`,
  222. DROP `s_qq`,
  223. DROP `s_weixin`,
  224. DROP `s_alipay`,
  225. DROP `s_cardrealname`,
  226. DROP `s_cardname`,
  227. DROP `s_cardnumber`,
  228. DROP `s_email`,
  229. DROP `s_is_super`,
  230. DROP `roleid`;
  231. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_take_fullreduction` TINYINT(1) NULL DEFAULT '1' COMMENT '是否参加满减' AFTER `goods_share_image`;
  232. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `fullreduction_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '满减金额' AFTER `voucher_credit`;
  233. ALTER TABLE `oscshop_lionfish_community_head_tixian_order` ADD `is_send_fail` TINYINT(1) NULL DEFAULT '0' COMMENT '是否发送是否,1是,0否' AFTER `shentime`, ADD `fail_msg` VARCHAR(255) NULL COMMENT '发送失败原因' AFTER `is_send_fail`;
  234. 优惠券3张表,待导入
  235. V1.4.1
  236. ALTER TABLE `oscshop_lionfish_comshop_order` CHANGE `delivery` `delivery` ENUM('express','pickup','tuanz_send') CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT 'express' COMMENT '配送类型';
  237. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `tuan_send_address` VARCHAR(255) NULL COMMENT '团长配送,送货详细地址' AFTER `shipping_address`;
  238. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `add_shipping_fare` FLOAT(10,2) NULL DEFAULT '0' COMMENT '团长配送费' AFTER `money`;
  239. ALTER TABLE `oscshop_lionfish_comshop_notify_order` CHANGE `state` `state` INT(10) NOT NULL COMMENT '状态,0未发送,1已发送';
  240. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_navigat` (
  241. `id` int(11) NOT NULL COMMENT '自增id',
  242. `advname` varchar(200) NOT NULL COMMENT '名称',
  243. `thumb` varchar(255) NOT NULL COMMENT '图片地址',
  244. `link` varchar(255) NOT NULL COMMENT '链接地址',
  245. `appid` varchar(255) NOT NULL COMMENT '外部小程序appid',
  246. `type` tinyint(1) NOT NULL COMMENT '0外链 1小程序内链 2外部小程序',
  247. `displayorder` int(10) NOT NULL COMMENT '排序,越大排序越前面',
  248. `enabled` tinyint(1) NOT NULL COMMENT '是否生效,1生效,0不生效',
  249. `addtime` int(10) NOT NULL COMMENT '添加广告时间'
  250. ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8 COMMENT='导航图标';
  251. ALTER TABLE `oscshop_lionfish_comshop_navigat`
  252. ADD PRIMARY KEY (`id`);
  253. ALTER TABLE `oscshop_lionfish_comshop_navigat`
  254. MODIFY `id` int(11) NOT NULL AUTO_INCREMENT COMMENT '自增id',AUTO_INCREMENT=1;
  255. ALTER TABLE `oscshop_lionfish_community_head` ADD `wechat` VARCHAR(100) NULL DEFAULT NULL COMMENT '微信号' AFTER `head_mobile`;
  256. ALTER TABLE `oscshop_lionfish_comshop_adv` ADD `appid` VARCHAR(255) NULL DEFAULT NULL COMMENT '外部小程序appid' AFTER `link`, ADD `linktype` TINYINT(1) NOT NULL DEFAULT '1' COMMENT '0外链 1小程序内 2外部小程序' AFTER `appid`;
  257. ALTER TABLE `oscshop_lionfish_comshop_navigat` CHANGE `advname` `navname` VARCHAR(200) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '名称';
  258. //快递整个表等待导出:
  259. V1.2.2
  260. ALTER TABLE `oscshop_lionfish_community_head` ADD `enable` TINYINT(1) NULL DEFAULT '1' COMMENT '禁用状态 0:禁用 1:启用' AFTER `state`;
  261. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `member_id` INT(10) NULL DEFAULT '0' COMMENT '关联会员id' AFTER `name`;
  262. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_delivery_flag` TINYINT(1) NULL DEFAULT '0' COMMENT '是否已经打包' AFTER `is_zhuli`;
  263. ALTER TABLE`oscshop_lionfish_comshop_good_common` ADD `big_img` VARCHAR(255) NULL DEFAULT NULL COMMENT '首页列表大图' AFTER `content`;
  264. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `goods_share_image` VARCHAR(255) NULL COMMENT '商品分享图' AFTER `big_img`;
  265. V1.3.3
  266. CREATE TABLE `oscshop_lionfish_comshop_deliveryclerk` (
  267. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  268. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  269. `line_id` int(10) NOT NULL COMMENT '线路id',
  270. `name` varchar(100) NOT NULL COMMENT '配送员名称',
  271. `logo` varchar(255) DEFAULT NULL COMMENT '头像',
  272. `mobile` varchar(50) NOT NULL COMMENT '配送员手机号',
  273. `addtime` int(10) NOT NULL COMMENT '添加时间',
  274. PRIMARY KEY (`id`),
  275. KEY `uniacid` (`uniacid`,`line_id`)
  276. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购配送员表';
  277. CREATE TABLE `oscshop_lionfish_comshop_deliveryline` (
  278. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  279. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  280. `name` varchar(255) NOT NULL COMMENT '线路名称',
  281. `clerk_id` int(10) NOT NULL COMMENT '配送员id',
  282. `addtime` int(10) NOT NULL COMMENT '添加时间',
  283. PRIMARY KEY (`id`),
  284. KEY `uniacid` (`uniacid`,`clerk_id`)
  285. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购配送线路';
  286. CREATE TABLE `oscshop_lionfish_comshop_deliveryline_headrelative` (
  287. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  288. `line_id` int(10) NOT NULL COMMENT '线路id',
  289. `head_id` int(11) NOT NULL COMMENT '团长id',
  290. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  291. `addtime` int(11) NOT NULL COMMENT '添加时间',
  292. PRIMARY KEY (`id`),
  293. KEY `uniacid` (`uniacid`,`line_id`),
  294. KEY `head_id` (`head_id`)
  295. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购线路团长关联表';
  296. CREATE TABLE `oscshop_lionfish_comshop_deliverylist` (
  297. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  298. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  299. `list_sn` varchar(50) NOT NULL COMMENT '编号',
  300. `head_id` int(10) DEFAULT NULL COMMENT '团长id',
  301. `head_name` varchar(100) NOT NULL COMMENT '团长名称',
  302. `head_mobile` varchar(20) DEFAULT NULL COMMENT '团长手机',
  303. `head_address` varchar(255) NOT NULL COMMENT '团长地址',
  304. `line_id` int(10) NOT NULL COMMENT '线路id',
  305. `line_name` varchar(200) DEFAULT NULL COMMENT '线路名称',
  306. `clerk_id` int(10) DEFAULT NULL COMMENT '配送员id',
  307. `clerk_name` varchar(100) DEFAULT NULL COMMENT '配送员名称',
  308. `clerk_mobile` varchar(50) DEFAULT NULL COMMENT '配送员手机号',
  309. `state` tinyint(1) NOT NULL COMMENT '配送状态:0未配送,1配送中,2已配送',
  310. `goods_count` int(10) NOT NULL COMMENT '商品数量',
  311. `express_time` int(10) NOT NULL COMMENT '配送时间',
  312. `head_get_time` int(10) DEFAULT NULL COMMENT '清单配送到时间',
  313. `create_time` int(10) NOT NULL COMMENT '创建清单时间',
  314. `addtime` int(11) NOT NULL COMMENT '添加时间',
  315. PRIMARY KEY (`id`),
  316. KEY `uniacid` (`uniacid`,`line_id`),
  317. KEY `clerk_id` (`clerk_id`),
  318. KEY `head_id` (`head_id`)
  319. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购清单表';
  320. CREATE TABLE `oscshop_lionfish_comshop_deliverylist_goods` (
  321. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  322. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  323. `list_id` int(10) NOT NULL COMMENT '清单id',
  324. `goods_id` int(10) NOT NULL COMMENT '商品id',
  325. `goods_name` varchar(255) NOT NULL COMMENT '商品标题',
  326. `rela_goodsoption_valueid` varchar(100) NOT NULL COMMENT '商品规格',
  327. `sku_str` varchar(255) DEFAULT NULL COMMENT '标签名称',
  328. `goods_image` varchar(255) NOT NULL COMMENT '商品图片',
  329. `addtime` int(10) NOT NULL COMMENT '添加时间',
  330. `goods_count` int(10) NOT NULL COMMENT '商品数量',
  331. PRIMARY KEY (`id`),
  332. KEY `uniacid` (`uniacid`),
  333. KEY `list_id` (`list_id`),
  334. KEY `goods_id` (`goods_id`)
  335. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购';
  336. CREATE TABLE `oscshop_lionfish_comshop_deliverylist_order` (
  337. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  338. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  339. `list_id` int(10) NOT NULL COMMENT '清单id',
  340. `order_id` int(11) NOT NULL COMMENT '订单id',
  341. `addtime` int(11) NOT NULL COMMENT '添加时间',
  342. PRIMARY KEY (`id`),
  343. KEY `uniacid` (`uniacid`,`list_id`),
  344. KEY `order_id` (`order_id`)
  345. ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COMMENT='狮子鱼社区团购清单订单关联表';
  346. ALTER TABLE `oscshop_lionfish_comshop_goods` ADD `istop` TINYINT(1) NULL DEFAULT '0' COMMENT '置顶 0否 1是' AFTER `addtime`, ADD `settoptime` INT(10) NULL DEFAULT '0' COMMENT '置顶时间' AFTER `istop`;
  347. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `product` VARCHAR(1000) NULL DEFAULT NULL COMMENT '产品说明' AFTER `logo`;
  348. CREATE TABLE `oscshop_lionfish_comshop_notify_order` (
  349. `id` int(10) NOT NULL AUTO_INCREMENT,
  350. `username` varchar(255) NOT NULL COMMENT '会员名称',
  351. `member_id` int(10) DEFAULT '0',
  352. `avatar` varchar(255) NOT NULL COMMENT '头像',
  353. `order_time` int(10) NOT NULL COMMENT '购买时间',
  354. `order_id` int(10) DEFAULT '0' COMMENT '订单id',
  355. `state` tinyint(1) NOT NULL COMMENT '状态,0未发送,1已发送',
  356. `add_time` int(10) NOT NULL COMMENT '添加时间',
  357. `order_url` varchar(100) NOT NULL COMMENT '订单id',
  358. PRIMARY KEY (`id`),
  359. KEY `member_id` (`member_id`)
  360. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='最新订单消息通知';
  361. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow` ADD `operate_end_yuer` FLOAT(10,2) NULL DEFAULT '0' COMMENT '当前操作结束后余额' AFTER `money`;
  362. V4.0.0.0
  363. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_new_buy` TINYINT( 1 ) NULL DEFAULT '0' COMMENT '是否新人购买,0否,1 是';
  364. V4.3.0
  365. ALTER TABLE `oscshop_lionfish_community_head_commiss_order` ADD `fen_type` TINYINT(1) NULL DEFAULT '0' COMMENT '0,按照比例计算的,1按照实际金额计算的' AFTER `type`;
  366. CREATE TABLE `oscshop_lionfish_community_head_group`
  367. (
  368. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  369. `groupname` VARCHAR(255) NOT NULL COMMENT '分组名称' ,
  370. PRIMARY KEY (`id`)
  371. ) ENGINE = InnoDB COMMENT = '狮子鱼商城团长分组表';
  372. ALTER TABLE `oscshop_lionfish_community_head` ADD `groupid` INT(10) NULL DEFAULT '0' COMMENT '分组id' AFTER `head_mobile`;
  373. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_print_suc` TINYINT(1) NULL DEFAULT '1' COMMENT '是否打印成功。' AFTER `is_delivery_flag`;
  374. V4.9.0
  375. ALTER TABLE `oscshop_lionfish_comshop_member` ADD `is_writecommiss_form` TINYINT(1) NULL DEFAULT '0' COMMENT '是否收集过表单' AFTER `full_user_name`, ADD `commiss_formcontent` TEXT NULL COMMENT '表单收集的内容' AFTER `is_writecommiss_form`;
  376. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `video` VARCHAR(255) NULL COMMENT '商品视频' AFTER `big_img`;
  377. ALTER TABLE `oscshop_lionfish_comshop_member` ADD `commiss_qrcode` VARCHAR(255) NULL COMMENT '分销商二维码' AFTER `hexiao_qrcod`;
  378. V5.0.0
  379. ALTER TABLE `oscshop_lionfish_comshop_member` ADD `is_share_tj` TINYINT(1) NULL DEFAULT '0' COMMENT '是否分销条件中,分享成为' AFTER `is_writecommiss_form`;
  380. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_commission` TINYINT(1) NULL DEFAULT '0' COMMENT '是否分销订单' AFTER `is_zhuli`;
  381. ALTER TABLE `oscshop_lionfish_comshop_member_commiss_order` ADD `type` TINYINT(1) NULL DEFAULT '1' COMMENT '1按照比例。2按照固定金额' AFTER `level`, ADD `bili` FLOAT(10,2) NULL DEFAULT '0' COMMENT '比例,如果是固定金额,那么这里就是固定金额' AFTER `type`;
  382. ALTER TABLE `oscshop_lionfish_supply_commiss_order` ADD `member_commiss_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '会员分销金额' AFTER `head_commiss_money`;
  383. ALTER TABLE `oscshop_lionfish_community_head` ADD `is_modify_shipping_method` TINYINT(1) NULL DEFAULT '0' COMMENT '0跟随系统,1,开启,2关闭' AFTER `apptime`, ADD `is_modify_shipping_fare` TINYINT(1) NULL DEFAULT '0' COMMENT '是否开启自定义运费' AFTER `is_modify_shipping_method`, ADD `shipping_fare` FLOAT(10,2) NULL DEFAULT '0' COMMENT '配送费' AFTER `is_modify_shipping_fare`;
  384. ALTER TABLE `oscshop_lionfish_comshop_coupon` ADD `limit_goods_list` TEXT NULL COMMENT '限制的商品id' AFTER `is_limit_goods_buy`;
  385. ALTER TABLE `oscshop_lionfish_comshop_coupon` ADD `goodscates` INT(10) NULL DEFAULT '0' COMMENT '限制商品分类使用' AFTER `limit_goods_list`;
  386. ALTER TABLE `oscshop_lionfish_comshop_coupon_list` ADD `limit_goods_list` TEXT NULL COMMENT '限制的商品id' AFTER `is_limit_goods_buy`;
  387. ALTER TABLE `oscshop_lionfish_comshop_coupon_list` ADD `goodscates` INT(10) NULL DEFAULT '0' COMMENT '限制商品分类使用' AFTER `limit_goods_list`;
  388. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_free_shipping_fare` TINYINT(1) NULL DEFAULT '0' COMMENT '满金额减运费' AFTER `shipping_fare`, ADD `fare_shipping_free` FLOAT(10,2) NULL DEFAULT '0' COMMENT '满x减免运费' AFTER `is_free_shipping_fare`;
  389. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `fare_shipping_free` FLOAT(10,2) NULL DEFAULT '0' COMMENT '满x金额减运费' AFTER `shipping_fare`;
  390. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `man_e_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '满多少' AFTER `fare_shipping_free`;
  391. V5.1.0
  392. ALTER TABLE `oscshop_lionfish_comshop_member_commiss` ADD `type` TINYINT(1) NULL DEFAULT '0' COMMENT '1余额,2 weixin,3alipay,4bank ' AFTER `dongmoney`;
  393. ALTER TABLE `oscshop_lionfish_comshop_member_tixian_order` ADD `type` TINYINT(1) NULL DEFAULT '0' COMMENT '1余额,2微信 3支付宝 4 银行卡' AFTER `shentime`, ADD `bankname` VARCHAR(255) NULL COMMENT '银行卡名称' AFTER `type`, ADD `bankaccount` VARCHAR(255) NULL COMMENT '卡号' AFTER `bankname`, ADD `bankusername` VARCHAR(255) NULL COMMENT '持卡人姓名' AFTER `bankaccount`;
  394. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_spike_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '是否限时秒杀,0不是,1是' AFTER `is_new_buy`;
  395. V5.2.0
  396. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `is_refund_state` TINYINT(1) NULL DEFAULT '0' COMMENT '是否退款,0未退款,1已退款' AFTER `rela_goodsoption_valueid`;
  397. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `order_goods_id` INT(10) NULL DEFAULT '0' COMMENT '退款子订单编号' AFTER `order_id`;
  398. ALTER TABLE `oscshop_lionfish_comshop_order_history` ADD `order_goods_id` INT(10) NULL DEFAULT '0' COMMENT '商品订单id' AFTER `order_id`;
  399. ALTER TABLE `oscshop_lionfish_comshop_order_history` ADD INDEX( `order_id`, `order_goods_id`);
  400. ALTER TABLE `oscshop_lionfish_comshop_order_refund_history` ADD `order_goods_id` INT(10) NULL DEFAULT '0' COMMENT '订单商品id' AFTER `order_id`;
  401. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow` ADD `order_goods_id` INT(10) NULL DEFAULT '0' COMMENT '订单商品id' AFTER `trans_id`;
  402. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_modify_sendscore` TINYINT(1) NULL DEFAULT '0' COMMENT '是否自定义赠送积分' AFTER `is_spike_buy`, ADD `send_socre` INT(10) NULL DEFAULT '0' COMMENT '买一个商品赠送积分多少' AFTER `is_modify_sendscore`;
  403. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `score_for_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '积分抵扣金额' AFTER `payment_code`;
  404. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `score_for_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '积分抵扣金额' AFTER `voucher_credit`;
  405. V5.4.0 V5.5.0
  406. CREATE TABLE IF NOT EXISTS `oscshop_lionfish_comshop_member_group` (
  407. `id` int(11) NOT NULL AUTO_INCREMENT,
  408. `groupname` varchar(255) DEFAULT '',
  409. PRIMARY KEY (`id`)
  410. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  411. ALTER TABLE `oscshop_lionfish_comshop_member_tixian_order` ADD `service_charge` FLOAT(10,2) NULL DEFAULT '0' COMMENT '提现手续费比例' AFTER `money`;
  412. ALTER TABLE `oscshop_lionfish_comshop_member_tixian_order` ADD `service_charge_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '提现后实际到账金额' AFTER `service_charge`;
  413. ALTER TABLE `oscshop_lionfish_community_head_tixian_order` ADD `type` TINYINT(1) NULL DEFAULT '0' COMMENT '0 原系统参数,1 余额,2微信,3支付宝,4 银行卡' AFTER `fail_msg`, ADD `bankname` VARCHAR(100) NULL COMMENT '银行卡名称' AFTER `type`, ADD `bankaccount` VARCHAR(100) NULL COMMENT '卡号' AFTER `bankname`, ADD `bankusername` VARCHAR(100) NULL COMMENT '持卡人姓名' AFTER `bankaccount`;
  414. V5.7.0
  415. ALTER TABLE `oscshop_lionfish_community_head_commiss` ADD `share_avatar` VARCHAR(200) NULL DEFAULT NULL COMMENT '团长群分享头像' AFTER `bankusername`, ADD `share_wxcode` VARCHAR(200) NULL DEFAULT NULL COMMENT '团长群分享二维码' AFTER `share_avatar`, ADD `share_title` VARCHAR(200) NULL DEFAULT NULL COMMENT '团长群分享标题' AFTER `share_wxcode`, ADD `share_desc` VARCHAR(255) NULL DEFAULT NULL COMMENT '团长群分享描述' AFTER `share_title`;
  416. V5.8.0
  417. CREATE TABLE `oscshop_lionfish_comshop_chargetype`
  418. (
  419. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  420. `money` FLOAT(10,2) NOT NULL COMMENT '充值金额' ,
  421. `send_money` FLOAT(10,2) NOT NULL DEFAULT '0' COMMENT '赠送金额' ,
  422. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  423. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  424. PRIMARY KEY (`id`), INDEX (`uniacid`)
  425. ) ENGINE = InnoDB COMMENT = '会员充值选项表';
  426. ALTER TABLE `oscshop_lionfish_comshop_member_charge_flow` ADD `give_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '赠送金额' AFTER `money`;
  427. V6.0.0
  428. ALTER TABLE `oscshop_lionfish_comshop_coupon` ADD `is_index_alert` TINYINT(1) NULL DEFAULT '0' COMMENT '是否首页弹窗,0否,1是' AFTER `is_index_show`;
  429. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_mb_level_buy` TINYINT(1) NULL DEFAULT '1' COMMENT '是否支持会员折扣购买' AFTER `is_spike_buy`;
  430. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `store_id` INT(10) NULL DEFAULT '0' COMMENT '供应商id' AFTER `order_id`;
  431. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `complaint_name` VARCHAR(255) NULL COMMENT '联系人姓名' AFTER `ref_mobile`;
  432. ALTER TABLE `oscshop_lionfish_comshop_order_refund_history` ADD `ref_id` INT(10) NULL COMMENT '退款记录id' AFTER `type`, ADD INDEX (`ref_id`);
  433. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `type` tinyint(1) NULL DEFAULT 0 COMMENT '0单图 1图+商品' AFTER `enabled`;
  434. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `special_title` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '活动页面主题标题' AFTER `type`;
  435. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `special_cover` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '活动页面主题图片' AFTER `special_title`;
  436. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `displayorder` int(10) NULL DEFAULT 0 COMMENT '排序' AFTER `special_cover`;
  437. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `begin_time` int(10) NOT NULL COMMENT '活动开始时间' AFTER `displayorder`;
  438. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `end_time` int(10) NOT NULL COMMENT '活动结束时间' AFTER `begin_time`;
  439. ALTER TABLE `oscshop_lionfish_comshop_special` ADD COLUMN `addtime` int(10) NOT NULL COMMENT '添加时间' AFTER `end_time`;
  440. ALTER TABLE `oscshop_lionfish_comshop_special` DROP COLUMN `description`;
  441. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `remarkrefund` VARCHAR(255) NULL COMMENT '管理员备注' AFTER `state`;
  442. CREATE TABLE `oscshop_lionfish_comshop_order_refund_disable` (
  443. `id` INT(10) NOT NULL COMMENT '自增id' ,
  444. `ref_id` INT(10) NOT NULL COMMENT '退款的id' ,
  445. `order_id` INT(10) NOT NULL COMMENT '订单id' ,
  446. `order_goods_id` INT(10) NOT NULL COMMENT '子订单id' ,
  447. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  448. PRIMARY KEY (`id`), INDEX (`ref_id`)
  449. ) ENGINE = InnoDB COMMENT = '禁止申请退款的订单';
  450. ALTER TABLE `oscshop_lionfish_comshop_order_refund_disable` ADD INDEX( `order_id`, `order_goods_id`);
  451. ALTER TABLE `oscshop_lionfish_comshop_order_refund_disable` CHANGE `id` `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id';
  452. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `modify_time` INT(10) NULL DEFAULT '0' COMMENT '退款订单管理员修改时间' AFTER `remarkrefund`;
  453. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `storename` VARCHAR(255) NOT NULL COMMENT '店铺名称' AFTER `logo`, ADD `banner` VARCHAR(255) NULL DEFAULT NULL COMMENT '店铺顶部图' AFTER `storename`;
  454. V6.1.0
  455. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_only_express` TINYINT(1) NULL DEFAULT '0' COMMENT '是否仅快递' AFTER `send_socre`;
  456. V6.3.0
  457. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `is_statements_state` TINYINT(1) NULL DEFAULT '1' COMMENT '是否结算' AFTER `is_refund_state`;
  458. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `statements_end_time` INT(10) NULL DEFAULT '0' COMMENT '结算时间' AFTER `is_statements_state`;
  459. ALTER TABLE `oscshop_lionfish_comshop_special` ADD `is_index` TINYINT(1) NOT NULL DEFAULT '1' COMMENT '首页显示' AFTER `end_time`;
  460. ALTER TABLE `oscshop_lionfish_comshop_special` ADD `show_type` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '0小图,1大图' AFTER `is_index`;
  461. ALTER TABLE `oscshop_lionfish_supply_tixian_order` ADD `supply_apply_type` TINYINT(1) NULL DEFAULT '0' COMMENT '供应商提现类型:0原来默认,1 微信 2 支付宝 3银行卡' AFTER `money`;
  462. V6.6.0
  463. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `relative_goods_list` TEXT NULL COMMENT '关联的商品id' AFTER `is_only_express`;
  464. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `head_id` INT(10) NULL DEFAULT '0' COMMENT '团长id' AFTER `order_goods_id`, ADD INDEX (`head_id`);
  465. V6.7.0
  466. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_show_arrive` TINYINT(1) NOT NULL DEFAULT '1' COMMENT '商品预达简介' AFTER `relative_goods_list`, ADD `diy_arrive_switch` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '预达简介开关' AFTER `is_show_arrive`, ADD `diy_arrive_details` VARCHAR(200) NULL DEFAULT NULL COMMENT '预达简介内容' AFTER `diy_arrive_switch`;
  467. V6.8.0 V6.9.0
  468. ALTER TABLE `oscshop_lionfish_comshop_special` ADD `bg_color` VARCHAR(20) NOT NULL DEFAULT '#F6F6F6' COMMENT '背景颜色' AFTER `show_type`;
  469. ALTER TABLE `oscshop_lionfish_comshop_community_head_level` ADD `auto_upgrade` TINYINT(1) NULL DEFAULT '0' COMMENT '自动升级: 0 否,1 是' AFTER `commission`, ADD `condition_type` TINYINT(1) NULL COMMENT '0 . 累计社区用户完成订单总金额, 1 .累计社区用户数量' AFTER `auto_upgrade`, ADD `condition_one` FLOAT(10,2) NULL DEFAULT '0' COMMENT '累计社区用户完成订单总金额' AFTER `condition_type`, ADD `condition_two` INT(10) NULL DEFAULT '0' COMMENT '累计社区用户数量' AFTER `condition_one`;
  470. V7.1.0
  471. ALTER TABLE `oscshop_lionfish_comshop_adv` CHANGE `type` `type` ENUM('slider','nav','pintuan') CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '广告类型,slider幻灯,nav导航小图';
  472. ALTER TABLE `oscshop_lionfish_comshop_goods_tags` ADD `tag_type` ENUM('normal','pintuan') NULL DEFAULT 'normal' COMMENT '商品标签类型' AFTER `type`;
  473. ALTER TABLE `oscshop_lionfish_comshop_spec` ADD `spec_type` ENUM('normal','pintuan') NULL DEFAULT 'normal' COMMENT '商品规格类型,普通,拼团' AFTER `value`;
  474. ALTER TABLE `oscshop_lionfish_comshop_goods_category` ADD `cate_type` ENUM('normal','pintuan') NULL DEFAULT 'normal' COMMENT '普通商品分类:normal,拼团商品。pintuan' AFTER `sort_order`;
  475. V7.2.0
  476. ALTER TABLE `oscshop_lionfish_comshop_order_comment` ADD `gd_type` ENUM('normal','pintuan') NULL DEFAULT 'normal' COMMENT 'normal普通商品。pintuan 拼团商品' AFTER `type`;
  477. ALTER TABLE `oscshop_lionfish_comshop_goods_category` ADD `banner` VARCHAR(255) NULL DEFAULT NULL COMMENT '顶部主题图' AFTER `logo`;
  478. V7.3.0
  479. ALTER TABLE `oscshop_lionfish_comshop_goods_category` ADD `is_show_topic` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '是否显示3*3布局' AFTER `is_show`;
  480. V7.4.0
  481. CREATE TABLE `oscshop_lionfish_comshop_pin` (
  482. `pin_id` int(11) NOT NULL AUTO_INCREMENT COMMENT '拼团id,自增',
  483. `order_id` int(11) NOT NULL DEFAULT '0' COMMENT '订单id',
  484. `user_id` int(11) NOT NULL DEFAULT '0' COMMENT '会员id',
  485. `need_count` int(11) NOT NULL DEFAULT '0' COMMENT '拼团人数',
  486. `state` tinyint(1) NOT NULL DEFAULT '0' COMMENT '拼团状态,0拼团中,1拼团成功,2拼团失败并退款',
  487. `lottery_state` tinyint(1) NOT NULL DEFAULT '0' COMMENT '抽奖状态,0抽奖中,1可退款,2已退款送券。',
  488. `is_lottery` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否抽奖拼团,0正常订单,1抽奖订单',
  489. `begin_time` int(11) NOT NULL COMMENT '拼团开始时间',
  490. `end_time` int(11) NOT NULL COMMENT '拼团结束时间',
  491. `add_time` int(11) NOT NULL COMMENT ' 添加时间',
  492. `success_time` int(10) DEFAULT NULL COMMENT '拼团成功时间',
  493. `is_jiqi` tinyint(1) DEFAULT '0' COMMENT '是否机器人成团',
  494. `qrcode` varchar(255) DEFAULT NULL COMMENT '二维码',
  495. PRIMARY KEY (`pin_id`),
  496. KEY `user_id` (`user_id`) USING BTREE,
  497. KEY `order_id` (`order_id`) USING BTREE
  498. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  499. CREATE TABLE `oscshop_lionfish_comshop_pin_order` (
  500. `id` int(11) NOT NULL AUTO_INCREMENT,
  501. `pin_id` int(11) NOT NULL COMMENT '拼团id',
  502. `order_id` int(11) NOT NULL COMMENT '订单id',
  503. `add_time` int(11) NOT NULL,
  504. PRIMARY KEY (`id`),
  505. KEY `pin_id` (`pin_id`) USING BTREE,
  506. KEY `order_id` (`order_id`) USING BTREE
  507. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  508. V7.5.0
  509. ALTER TABLE `oscshop_lionfish_comshop_goods` ADD `costprice` FLOAT(10,2) NULL DEFAULT '0' COMMENT '成本价' AFTER `price`;
  510. V7.6.0
  511. ALTER TABLE `oscshop_lionfish_comshop_order` CHANGE `type` `type` ENUM('pintuan','normal','lottery','virtual','bargain','integral','community','ignore') CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT 'normal';
  512. ALTER TABLE `oscshop_lionfish_comshop_coupon` ADD `is_new_man` TINYINT(1) NULL DEFAULT '0' COMMENT '是否新人券,0非,1新人' AFTER `is_index_alert`;
  513. ALTER TABLE `oscshop_lionfish_comshop_good_pin` ADD `is_commiss_tuan` TINYINT(1) NULL DEFAULT '0' COMMENT '是否佣金团,0否,1是' AFTER `end_time`, ADD `is_zero_open` TINYINT(1) NULL DEFAULT '0' COMMENT '是否0元开团:0否,1是' AFTER `is_commiss_tuan`, ADD `is_newman` TINYINT(1) NULL DEFAULT '0' COMMENT '是否仅新人参加:0否,1是' AFTER `is_zero_open`, ADD `commiss_type` TINYINT(1) NULL DEFAULT '0' COMMENT '0百分比,1固定金额' AFTER `is_newman`;
  514. ALTER TABLE `oscshop_lionfish_comshop_good_pin` ADD `commiss_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '具体佣金比例或佣金' AFTER `commiss_type`;
  515. CREATE TABLE `oscshop_lionfish_comshop_pintuan_commiss` (
  516. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增ID',
  517. `uniacid` int(10) NOT NULL COMMENT '公众号id',
  518. `member_id` int(10) NOT NULL COMMENT '会员ID',
  519. `money` float(10,2) DEFAULT '0.00' COMMENT '可提现金额',
  520. `dongmoney` float(10,2) DEFAULT '0.00' COMMENT '提现中金额',
  521. `getmoney` float(10,2) DEFAULT '0.00' COMMENT '已提现金额',
  522. PRIMARY KEY (`id`),
  523. KEY `member_id` (`member_id`) USING BTREE,
  524. KEY `uniacid` (`uniacid`)
  525. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  526. CREATE TABLE `oscshop_lionfish_comshop_pintuan_commiss_order` (
  527. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增ID',
  528. `uniacid` int(11) NOT NULL COMMENT '公众号id',
  529. `member_id` int(10) NOT NULL COMMENT '会员ID',
  530. `order_id` int(10) NOT NULL COMMENT '订单ID',
  531. `order_goods_id` int(10) DEFAULT '0' COMMENT '商品订单id',
  532. `type` tinyint(1) DEFAULT '1' COMMENT '1按照比例。2按照固定金额',
  533. `bili` float(10,2) DEFAULT '0.00' COMMENT '比例,如果是固定金额,那么这里就是固定金额',
  534. `store_id` int(10) NOT NULL COMMENT '店铺ID',
  535. `state` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否结算:0,待计算。1,已结算。2,订单取消\r\n3、已打款',
  536. `money` float(10,2) NOT NULL DEFAULT '0.00' COMMENT '分佣金额',
  537. `addtime` int(10) NOT NULL COMMENT '添加时间',
  538. PRIMARY KEY (`id`),
  539. KEY `member_id` (`member_id`) USING BTREE,
  540. KEY `uniacid` (`uniacid`)
  541. ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
  542. CREATE TABLE `oscshop_lionfish_comshop_pintuan_tixian_order` (
  543. `id` int(10) NOT NULL AUTO_INCREMENT COMMENT '自增id',
  544. `uniacid` int(10) NOT NULL,
  545. `member_id` int(10) NOT NULL COMMENT '会员id',
  546. `money` float(10,2) NOT NULL COMMENT '提现金额',
  547. `service_charge` float(10,2) DEFAULT '0.00' COMMENT '提现手续费比例',
  548. `service_charge_money` float(10,2) DEFAULT '0.00' COMMENT '提现后实际到账金额',
  549. `state` tinyint(1) NOT NULL COMMENT '提现状态,0申请中,1提现成功,2体现失败',
  550. `shentime` int(10) NOT NULL COMMENT '审核时间',
  551. `type` tinyint(1) DEFAULT '0' COMMENT '1余额,2微信 3支付宝 4 银行卡',
  552. `bankname` varchar(255) DEFAULT NULL COMMENT '银行卡名称',
  553. `bankaccount` varchar(255) DEFAULT NULL COMMENT '卡号',
  554. `bankusername` varchar(255) DEFAULT NULL COMMENT '持卡人姓名',
  555. `addtime` int(10) NOT NULL COMMENT '提交时间',
  556. PRIMARY KEY (`id`),
  557. KEY `uniacid` (`uniacid`),
  558. KEY `member_id` (`member_id`) USING BTREE
  559. ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='分销佣金提现表';
  560. ALTER TABLE `oscshop_lionfish_comshop_pin` ADD `is_commiss_tuan` TINYINT(1) NULL DEFAULT '0' COMMENT '是否佣金团' AFTER `state`, ADD `is_newman_takein` TINYINT(1) NULL DEFAULT '0' COMMENT '是否仅新人参加' AFTER `is_commiss_tuan`;
  561. ALTER TABLE `oscshop_lionfish_comshop_pintuan_commiss_order` ADD `statement_time` INT(10) NULL DEFAULT '0' COMMENT '结算时间' AFTER `money`;
  562. V7.7.0
  563. CREATE TABLE `oscshop_lionfish_comshop_member_card` (
  564. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  565. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  566. `cardname` VARCHAR(255) NOT NULL COMMENT '会员卡名称' ,
  567. `orignprice` FLOAT(10,2) NOT NULL COMMENT '原价' ,
  568. `price` FLOAT(10,2) NOT NULL COMMENT '实际购买价格' ,
  569. `expire_day` FLOAT(10,2) NOT NULL COMMENT '有效期天数,支持小数点' ,
  570. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  571. PRIMARY KEY (`id`), INDEX (`uniacid`)
  572. ) ENGINE = InnoDB COMMENT = '付费会员卡表';
  573. CREATE TABLE `oscshop_lionfish_comshop_member_card_order` (
  574. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  575. `order_sn` VARCHAR(50) NOT NULL COMMENT '订单编号' ,
  576. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  577. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  578. `pay_type` ENUM('weixin','yuer') NOT NULL COMMENT '支付类型,微信,余额' ,
  579. `state` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '支付状态:0未支付,1已支付' ,
  580. `car_id` INT(10) NOT NULL COMMENT '购买的 会员卡id' ,
  581. `expire_day` FLOAT(10,2) NOT NULL COMMENT '有效期天数,支持小数点' ,
  582. `price` FLOAT(10,2) NOT NULL COMMENT '购买价格' ,
  583. `order_type` TINYINT(1) NULL DEFAULT '1' COMMENT '购买类型:1首次购买,2有效期内续期,3过期后续费' ,
  584. `begin_time` INT(10) NULL DEFAULT '0' COMMENT '有效期开始时间' ,
  585. `end_time` INT(10) NOT NULL DEFAULT '0' COMMENT '有效期截止时间点' ,
  586. `pay_time` INT(10) NULL DEFAULT '0' COMMENT '支付的时间点' ,
  587. `addtime` INT(10) NOT NULL COMMENT '下单的时间' ,
  588. PRIMARY KEY (`id`), INDEX (`order_sn`), INDEX (`uniacid`), INDEX (`member_id`), INDEX (`car_id`)
  589. ) ENGINE = InnoDB COMMENT = '付费会员卡 购买订单表';
  590. CREATE TABLE `oscshop_lionfish_comshop_member_card_equity` (
  591. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  592. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  593. `equity_name` VARCHAR(255) NOT NULL COMMENT '权益名称' ,
  594. `image` VARCHAR(255) NOT NULL COMMENT '权益图标' ,
  595. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  596. PRIMARY KEY (`id`), INDEX (`uniacid`)
  597. ) ENGINE = InnoDB COMMENT = '会员卡权益';
  598. ALTER TABLE `oscshop_lionfish_comshop_member` ADD `card_id` INT(10) NULL DEFAULT '0' COMMENT '会员卡id' AFTER `commiss_formcontent`, ADD `card_begin_time` INT(10) NULL DEFAULT '0' COMMENT '会员卡开始时间' AFTER `card_id`, ADD `card_end_time` INT(10) NULL DEFAULT '0' COMMENT '会员卡结束时间' AFTER `card_begin_time`;
  599. ALTER TABLE `oscshop_lionfish_comshop_goods` ADD `card_price` FLOAT(10,2) NULL DEFAULT '0' COMMENT '会员卡商品购买价格' AFTER `costprice`;
  600. ALTER TABLE `oscshop_lionfish_comshop_goods_option_item_value` ADD `card_price` FLOAT(10,2) NULL DEFAULT '0' COMMENT '会员卡购买价格' AFTER `pinprice`;
  601. ALTER TABLE `oscshop_lionfish_comshop_member_card_order` ADD `formid` VARCHAR(255) NULL COMMENT '支付formid' AFTER `car_id`;
  602. ALTER TABLE `oscshop_lionfish_comshop_member_card_order` ADD `trans_id` VARCHAR(255) NULL COMMENT '微信交易单号' AFTER `car_id`;
  603. V7.8.0
  604. ALTER TABLE `oscshop_lionfish_comshop_goods` ADD `is_take_vipcard` TINYINT(1) NULL DEFAULT '0' COMMENT '是否参加会员卡,1参加,0不参加' AFTER `card_price`;
  605. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `is_vipcard_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '0非vip价格购买,1是' AFTER `total`, ADD `old_total` FLOAT(10,2) NULL DEFAULT '0' COMMENT '原始总价' AFTER `is_vipcard_buy`;
  606. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_vipcard_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '是否会员卡购买,0 否,1是' AFTER `supply_id`;
  607. V8.0.0
  608. CREATE TABLE `oscshop_lionfish_comshop_cube` (
  609. `id` INT(11) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  610. `name` VARCHAR(255) NOT NULL COMMENT '名称' ,
  611. `thumb` TEXT NOT NULL COMMENT '图片' ,
  612. `link` VARCHAR(255) NOT NULL COMMENT '链接地址' ,
  613. `appid` VARCHAR(255) NULL DEFAULT NULL COMMENT '外部小程序appid' ,
  614. `type` TINYINT(2) NOT NULL DEFAULT '0' COMMENT '类型' ,
  615. `displayorder` INT(10) NOT NULL COMMENT '排序,越大排序越前面' ,
  616. `enabled` TINYINT(1) NOT NULL COMMENT '是否生效,1生效,0不生效' ,
  617. `linktype` TINYINT(1) NOT NULL COMMENT '0外链 1小程序内 2外部小程序' ,
  618. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  619. PRIMARY KEY (`id`)
  620. ) ENGINE = InnoDB CHARACTER SET utf8 COLLATE utf8_general_ci COMMENT = '魔方图片';
  621. V8.1.0
  622. ALTER TABLE `oscshop_lionfish_comshop_cube` CHANGE `link` `num` TINYINT(1) NOT NULL COMMENT '图片个数';
  623. ALTER TABLE `oscshop_lionfish_comshop_order_all` ADD `out_trade_no` VARCHAR(100) NULL DEFAULT '' COMMENT '提交给微信的订单号' AFTER `transaction_id`;
  624. V8.3.0
  625. CREATE TABLE `oscshop_lionfish_comshop_signinreward_record` (
  626. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  627. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  628. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  629. `continuity_day` INT(10) NOT NULL COMMENT '连续签到几天' ,
  630. `reward_socre` INT(10) NOT NULL COMMENT '赠送积分数量' ,
  631. `signin_time` INT(10) NOT NULL COMMENT '签到时间' ,
  632. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  633. PRIMARY KEY (`id`), INDEX (`uniacid`, `member_id`)
  634. ) ENGINE = InnoDB COMMENT = '狮子鱼商城签到奖励记录表';
  635. ALTER TABLE `oscshop_lionfish_comshop_member_integral_flow` CHANGE `type` `type` ENUM('goodsbuy','refundorder','system_add','system_del','orderbuy','signin_send') CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '积分获赠/减少 类型';
  636. V8.4.0
  637. ALTER TABLE `oscshop_lionfish_comshop_adv` CHANGE `type` `type` ENUM('slider','nav','pintuan','recipe') CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '广告类型,slider幻灯,nav导航小图';
  638. ALTER TABLE `oscshop_lionfish_comshop_goods_category` CHANGE `cate_type` `cate_type` ENUM('normal','pintuan','recipe') CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT 'normal' COMMENT '普通商品分类:normal,拼团商品。pintuan';
  639. CREATE TABLE `oscshop_lionfish_comshop_recipe`
  640. (
  641. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  642. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  643. `recipe_name` VARCHAR(255) NOT NULL COMMENT '菜谱名称' ,
  644. `sub_name` VARCHAR(255) NULL COMMENT '菜谱描述' ,
  645. `images` VARCHAR(255) NULL COMMENT '菜谱图片' ,
  646. `video` VARCHAR(255) NULL COMMENT '菜谱视频' ,
  647. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  648. `cate_id` INT(10) NOT NULL COMMENT '分类id' ,
  649. `make_time` VARCHAR(100) NULL COMMENT '制作时间' ,
  650. `diff_type` TINYINT(1) NOT NULL COMMENT '难易程度,1简单,2容易,3困难' ,
  651. `state` TINYINT(1) NULL COMMENT '0禁用,1启用' ,
  652. `content` TEXT NOT NULL COMMENT '菜谱内容' ,
  653. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  654. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`cate_id`)
  655. ) ENGINE = InnoDB COMMENT = '狮子鱼商城菜谱表';
  656. CREATE TABLE `oscshop_lionfish_comshop_recipe_ingredients`
  657. (
  658. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  659. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  660. `recipe_id` INT(10) NOT NULL COMMENT '菜谱id' ,
  661. `goods_id` INT(10) NOT NULL COMMENT '商品id' ,
  662. `title` VARCHAR(255) NOT NULL COMMENT '食材标题' ,
  663. `addtime` INT(10) NOT NULL COMMENT '添加时间' , PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`recipe_id`)
  664. ) ENGINE = InnoDB COMMENT = '狮子鱼商城食材表';
  665. V8.5.0
  666. ALTER TABLE `oscshop_lionfish_comshop_recipe` ADD `fav_count` INT(10) NULL DEFAULT '0' COMMENT '喜欢数' AFTER `state`;
  667. CREATE TABLE `oscshop_lionfish_comshop_recipe_fav`
  668. (
  669. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  670. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  671. `recipe_id` INT(10) NOT NULL COMMENT '菜谱id' ,
  672. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  673. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  674. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`recipe_id`), INDEX (`member_id`)
  675. ) ENGINE = InnoDB COMMENT = '狮子鱼商城菜谱喜欢表';
  676. V8.6.0
  677. ALTER TABLE `oscshop_lionfish_comshop_recipe_ingredients` CHANGE `goods_id` `goods_id` VARCHAR(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '商品id,字符串多个逗号隔开 .';
  678. V8.7.0
  679. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `is_level_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '是否会员等级购买,1是,0 不是' AFTER `is_vipcard_buy`;
  680. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `is_level_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '是否会员等级购买,1是,0 不是' AFTER `is_vipcard_buy`;
  681. V8.8.0
  682. ALTER TABLE `oscshop_lionfish_comshop_goods` ADD `is_seckill` TINYINT(1) NULL DEFAULT '0' COMMENT '是否秒杀商品,1是,0否' AFTER `is_index_show`;
  683. V8.9.0
  684. ALTER TABLE `oscshop_lionfish_comshop_goods` CHANGE `type` `type` ENUM('normal','pin','lottery','oldman','newman','commiss','ladder','flash','spike','integral') CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT 'normal' COMMENT '商品类型';
  685. ALTER TABLE `oscshop_lionfish_comshop_member_integral_flow` CHANGE `type` `type` ENUM('goodsbuy','refundorder','system_add','system_del','orderbuy','signin_send','integral_exchange') CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '积分获赠/减少 类型';
  686. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD INDEX ( `goods_id` , `rela_goodsoption_valueid` ) ;
  687. V9.2.0
  688. CREATE TABLE `oscshop_lionfish_comshop_solitaire` (
  689. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  690. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  691. `head_id` INT(10) NOT NULL COMMENT '团长id' ,
  692. `solitaire_name` VARCHAR(255) NOT NULL COMMENT '接龙名称' ,
  693. `images_list` TEXT NULL COMMENT '图片列表' ,
  694. `addtype` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '0平台添加,1团长添加' ,
  695. `state` TINYINT(1) NOT NULL DEFAULT '0' COMMENT '0未审核,1已审核' ,
  696. `begin_time` INT(10) NOT NULL COMMENT '开始时间' ,
  697. `end_time` INT(10) NOT NULL COMMENT '结束时间' ,
  698. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  699. `content` TEXT NULL COMMENT '内容' ,
  700. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`head_id`)
  701. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群接龙活动表';
  702. CREATE TABLE `oscshop_lionfish_comshop_solitaire_goods` (
  703. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  704. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  705. `soli_id` INT(10) NOT NULL COMMENT '群接龙id' ,
  706. `goods_id` INT(10) NOT NULL COMMENT '商品id' ,
  707. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  708. PRIMARY KEY (`id`), INDEX (`uniacid`, `soli_id`),
  709. INDEX (`goods_id`)
  710. ) ENGINE = InnoDB COMMENT = '狮子鱼商城接龙活动商品表';
  711. CREATE TABLE `oscshop_lionfish_comshop_templatemsg`
  712. (
  713. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  714. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  715. `template_data` TEXT NOT NULL COMMENT '发送数据' ,
  716. `url` VARCHAR(255) NULL COMMENT '点击url' ,
  717. `open_id` VARCHAR(255) NOT NULL COMMENT 'openid' ,
  718. `template_id` VARCHAR(255) NOT NULL COMMENT '模板id' ,
  719. `type` TINYINT(1) NOT NULL COMMENT '0 非群发,1 发送给所有人' ,
  720. `state` TINYINT(1) NOT NULL COMMENT '0未发送状态,1已发送' ,
  721. `total_count` INT(10) NULL COMMENT '一共多少条' ,
  722. `send_total_count` INT(10) NULL DEFAULT '0' COMMENT '已经发送了多少条' ,
  723. `addtime` INT NOT NULL ,
  724. PRIMARY KEY (`id`)
  725. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群发模板消息';
  726. V9.3.0
  727. ALTER TABLE `oscshop_lionfish_comshop_solitaire` ADD `appstate` TINYINT(1) NULL DEFAULT '1' COMMENT '是否审核,1审核,0未审核' AFTER `state`;
  728. CREATE TABLE `oscshop_lionfish_comshop_solitaire_order` (
  729. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  730. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  731. `soli_id` INT(10) NOT NULL COMMENT '群接龙id' ,
  732. `order_id` INT(10) NOT NULL COMMENT '订单id' ,
  733. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  734. PRIMARY KEY (`id`),
  735. INDEX (`uniacid`, `soli_id`)
  736. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群接龙订单表';
  737. CREATE TABLE `oscshop_lionfish_comshop_solitaire_invite` (
  738. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  739. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  740. `soli_id` INT(10) NOT NULL COMMENT '群接龙id' ,
  741. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  742. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  743. PRIMARY KEY (`id`),
  744. INDEX (`uniacid`),
  745. INDEX (`soli_id`, `member_id`)
  746. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群接龙访问记录表';
  747. ALTER TABLE `oscshop_lionfish_community_head` ADD `is_default` TINYINT(1) NULL DEFAULT '0' COMMENT '0非默认,1 默认,只有开启单团长模式下可用' AFTER `rest`;
  748. V9.4.0
  749. CREATE TABLE `oscshop_lionfish_comshop_solitaire_post` (
  750. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  751. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  752. `soli_id` INT(10) NOT NULL COMMENT '群接龙id' ,
  753. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  754. `pid` INT(10) NOT NULL DEFAULT '0' COMMENT '回复id,默认0' ,
  755. `fav_count` INT(10) NOT NULL COMMENT '点赞数' ,
  756. `content` TEXT NOT NULL COMMENT '评论内容' ,
  757. `addtime` INT(10) NOT NULL COMMENT '评论时间' ,
  758. PRIMARY KEY (`id`), INDEX (`uniacid`, `soli_id`), INDEX (`pid`)
  759. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群接龙评论表';
  760. CREATE TABLE `oscshop_lionfish_comshop_solitaire_post_fav` (
  761. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  762. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  763. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  764. `soli_id` INT(10) NOT NULL COMMENT '群接龙id' ,
  765. `post_id` INT(10) NOT NULL COMMENT '评论id' ,
  766. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  767. PRIMARY KEY (`id`), INDEX (`member_id`, `post_id`)
  768. ) ENGINE = InnoDB COMMENT = '狮子鱼商城群接龙点赞表';
  769. V9.5.0
  770. ALTER TABLE `oscshop_lionfish_comshop_solitaire` ADD `qrcode_image` VARCHAR(255) NULL COMMENT '接龙二维码' AFTER `content`;
  771. ALTER TABLE `oscshop_lionfish_comshop_order` ADD `soli_id` INT(10) NULL COMMENT '接龙id' AFTER `is_zhuli`;
  772. ALTER TABLE `oscshop_lionfish_comshop_order` ADD INDEX(`soli_id`);
  773. ALTER TABLE `oscshop_lionfish_comshop_special` CHANGE `goodsids` `goodsids` TEXT CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '商品id';
  774. V9.6.0
  775. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_limit_levelunbuy` TINYINT(1) NULL DEFAULT '0' COMMENT '默认等级不能买' AFTER `is_new_buy`;
  776. ALTER TABLE `oscshop_lionfish_comshop_solitaire` ADD `end` TINYINT(1) NULL DEFAULT '0' COMMENT '手动结束' AFTER `content`;
  777. V9.9.0
  778. ALTER TABLE `oscshop_lionfish_comshop_good_common` ADD `is_limit_vipmember_buy` TINYINT(1) NULL DEFAULT '0' COMMENT '非VIP 不能购买' AFTER `is_limit_levelunbuy`;
  779. CREATE TABLE `oscshop_lionfish_comshop_subscribe` (
  780. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  781. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  782. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  783. `template_id` VARCHAR(255) NOT NULL COMMENT '模板' ,
  784. `type` ENUM('pay_order','send_order','hexiao_success','apply_community','open_tuan','take_tuan','pin_tuansuccess','apply_tixian') NOT NULL COMMENT '消息类型' ,
  785. `addtime` INT(10) NOT NULL COMMENT '订阅时间' ,
  786. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`member_id`)
  787. ) ENGINE = InnoDB COMMENT = '狮子鱼商城用户订阅消息';
  788. ALTER TABLE `oscshop_lionfish_comshop_subscribe` ADD INDEX( `member_id`, `type`);
  789. V10.0.0
  790. ALTER TABLE `oscshop_lionfish_comshop_member_level` ADD `is_auto_grade` TINYINT(1) NULL DEFAULT '0' COMMENT '是否自动升级,0 否,1是' AFTER `level_money`;
  791. ALTER TABLE `oscshop_lionfish_comshop_goods_category` ADD `is_type_show` TINYINT(1) NULL DEFAULT '0' COMMENT '分类显示' AFTER `is_show_topic`;
  792. V11.0.0
  793. CREATE TABLE `oscshop_lionfish_comshop_order_goods_refund`
  794. (
  795. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  796. `order_goods_id` INT(10) NOT NULL COMMENT '商品订单id' ,
  797. `order_id` INT(10) NOT NULL COMMENT '订单id' ,
  798. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  799. `quantity` INT(10) NOT NULL COMMENT '退款数量' ,
  800. `money` FLOAT(10,2) NOT NULL COMMENT '退款金额' ,
  801. `order_status_id` INT(10) NOT NULL COMMENT '退款时,订单状态' ,
  802. `is_back_quantity` TINYINT(1) NULL COMMENT '是否退商品库存' ,
  803. `back_score_for_money` FLOAT(10,2) NOT NULL COMMENT '退还积分兑换商品的积分' ,
  804. `back_send_score` FLOAT(10,2) NOT NULL COMMENT '退还赠送积分' ,
  805. `back_head_orderbuycommiss` FLOAT(10,2) NOT NULL COMMENT '退还团长佣金' ,
  806. `back_head_commiss_1` FLOAT(10,2) NOT NULL COMMENT '退1级团长佣金' ,
  807. `back_head_commiss_2` FLOAT(10,2) NOT NULL COMMENT '退2级团长佣金' ,
  808. `back_head_commiss_3` FLOAT(10,2) NOT NULL COMMENT '退3级团长佣金' ,
  809. `back_member_commiss_1` FLOAT(10,2) NOT NULL COMMENT '退会员1级佣金' ,
  810. `back_member_commiss_2` FLOAT(10,2) NOT NULL COMMENT '退会员2级佣金' ,
  811. `back_member_commiss_3` FLOAT(10,2) NOT NULL COMMENT '退会员3级佣金' ,
  812. `addtime` INT(10) NOT NULL COMMENT '操作时间' ,
  813. PRIMARY KEY (`id`), INDEX (`order_goods_id`), INDEX (`order_id`), INDEX (`uniacid`)
  814. ) ENGINE = InnoDB COMMENT = '狮子鱼商城订单商品退款记录表';
  815. ALTER TABLE `oscshop_lionfish_comshop_order_goods_refund` ADD `back_head_supplycommiss` FLOAT(10,2) NULL DEFAULT '0' COMMENT '退还供应商佣金' AFTER `back_head_orderbuycommiss`;
  816. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `has_refund_money` FLOAT(10,2) NULL DEFAULT '0' COMMENT '已经退款金额' AFTER `total`;
  817. V11.1.0
  818. ALTER TABLE `oscshop_lionfish_comshop_order_goods` ADD `has_refund_quantity` INT(10) NULL DEFAULT '0' COMMENT '已经退款数量' AFTER `has_refund_money`;
  819. V11.3.0
  820. ALTER TABLE `oscshop_lionfish_comshop_order_goods_refund` ADD `real_refund_quantity` INT(10) NULL DEFAULT '0' COMMENT '实际退款的数量' AFTER `uniacid`;
  821. ALTER TABLE `oscshop_lionfish_comshop_order_refund` ADD `real_refund_quantity` INT(10) NULL DEFAULT '0' COMMENT '退款几个商品' AFTER `order_goods_id`;
  822. V11.4.0
  823. ALTER TABLE `oscshop_lionfish_comshop_supply` ADD `qualifications` TEXT NULL COMMENT '工商资质' AFTER `login_slat`;
  824. V11.6.0
  825. CREATE TABLE `oscshop_lionfish_comshop_salesroom`
  826. (
  827. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  828. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  829. `supply_id` INT(10) NULL COMMENT '商户id' ,
  830. `room_name` VARCHAR(255) NOT NULL COMMENT '门店名称' ,
  831. `room_logo` VARCHAR(255) NOT NULL COMMENT '门店logo' ,
  832. `province_id` INT(10) NOT NULL COMMENT '省' ,
  833. `city_id` INT(10) NOT NULL COMMENT '市' ,
  834. `country_id` INT(10) NOT NULL COMMENT '区' ,
  835. `area_id` INT(10) NOT NULL COMMENT '镇' ,
  836. `address` VARCHAR(255) NOT NULL COMMENT '详细地址' ,
  837. `lon` FLOAT(10.6) NOT NULL COMMENT '经度' ,
  838. `lat` FLOAT(10.6) NOT NULL COMMENT '纬度' ,
  839. `state` TINYINT(1) NOT NULL COMMENT '状态,0禁用,1启用' ,
  840. `mobile` VARCHAR(25) NOT NULL COMMENT '手机' ,
  841. `business_hours` VARCHAR(100) NOT NULL COMMENT '营业时间' ,
  842. `contacts` VARCHAR(50) NOT NULL COMMENT '联系人' ,
  843. `store_introduction` TEXT NOT NULL COMMENT '门店介绍' ,
  844. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  845. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`supply_id`)
  846. ) ENGINE = InnoDB COMMENT = '核销门店';
  847. CREATE TABLE `oscshop_lionfish_comshop_salesroom_member`
  848. (
  849. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  850. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  851. `username` VARCHAR(255) NOT NULL COMMENT '用户名' ,
  852. `mobile` VARCHAR(25) NOT NULL COMMENT '手机号' ,
  853. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  854. `state` TINYINT(1) NOT NULL COMMENT '状态,0禁用,1启用' ,
  855. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  856. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`member_id`)
  857. ) ENGINE = InnoDB COMMENT = '门店核销人员表';
  858. CREATE TABLE `oscshop_lionfish_comshop_salesroom_relative_member`
  859. (
  860. `id` INT(10) NOT NULL AUTO_INCREMENT COMMENT '自增id' ,
  861. `uniacid` INT(10) NOT NULL COMMENT '公众号id' ,
  862. `salesroom_id` INT(10) NOT NULL COMMENT '门店id' ,
  863. `member_id` INT(10) NOT NULL COMMENT '会员id' ,
  864. `addtime` INT(10) NOT NULL COMMENT '添加时间' ,
  865. PRIMARY KEY (`id`), INDEX (`uniacid`), INDEX (`salesroom_id`), INDEX (`member_id`)
  866. ) ENGINE = InnoDB COMMENT = '门店核销人员跟门店关联表';