💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
~~~[sql] CREATE TABLE `xi_template_goods` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `cate_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分类ID', `brands_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '品牌ID', `name` varchar(64) NOT NULL DEFAULT '' COMMENT '名称', `weight` float(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '重量(kg)', `volume` float(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '体积(m³)', `thumb` varchar(255) NOT NULL DEFAULT 'http://oss.dgyouduo.com/static/img/no-image.png' COMMENT '缩略图', `banner` varchar(512) NOT NULL DEFAULT 'a:1:{i:0;s:53:"http://oss.dgyouduo.com/static/img/no-image-16x10.png";}' COMMENT '横幅(轮播图)', `summary` varchar(128) NOT NULL DEFAULT '' COMMENT '摘要', `content` text NOT NULL COMMENT '内容', `price` decimal(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '普通价格', `market_price` decimal(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '市场价格', `inventory` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '库存', `view_count` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '浏览数', `sale_count` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '销售数', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_free_shipping` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否包邮', `is_hot` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否推荐', `is_new` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否新品', `is_real` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '是否实体商品', `is_sale` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否上架', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', `saled_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '上架时间', PRIMARY KEY (`id`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_brands` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `cate_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分类ID', `name` varchar(16) NOT NULL DEFAULT '' COMMENT '名称', `description` varchar(128) NOT NULL DEFAULT '' COMMENT '描述', `logo` varchar(255) NOT NULL DEFAULT 'http://oss.dgyouduo.com/static/img/no-image.png' COMMENT '商标', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`cate_id`,`is_trash`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品品牌'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_category` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `parent_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '父ID', `parent_id_path` varchar(32) NOT NULL DEFAULT '' COMMENT '父ID路径', `level` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '级别', `name` varchar(32) NOT NULL DEFAULT '' COMMENT '名称', `thumb` varchar(255) NOT NULL DEFAULT 'http://oss.dgyouduo.com/static/img/no-image.png' COMMENT '缩略图', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_show` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否显示在列表', `is_hot` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '是否显示在推荐', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`parent_id`,`is_trash`) ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品分类'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_parameter` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `cate_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分类ID', `name` varchar(32) NOT NULL DEFAULT '' COMMENT '名称', `type` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '属性值类型(录入方式),1=>单行文本,2=>多行文本,3=>单选,4=>多选', `default_values` varchar(255) NOT NULL DEFAULT '' COMMENT '可选属性值(数组序列化)', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`cate_id`,`is_trash`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品参数'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_parameter_value` ( `param_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '参数ID', `goods_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '商品ID', `value` varchar(128) NOT NULL DEFAULT '' COMMENT '参数值', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', UNIQUE KEY `param_id` (`param_id`,`goods_id`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品参数值'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_sku` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `cate_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '分类ID', `name` varchar(32) NOT NULL DEFAULT '' COMMENT '名称', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`cate_id`,`is_trash`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品库存量单位'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_sku_item` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `sku_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '库存量项目ID', `name` varchar(16) NOT NULL DEFAULT '' COMMENT '名称', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `name` (`name`,`sku_id`,`is_trash`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品库存量项目'; ~~~ ~~~[sql] CREATE TABLE `xi_template_goods_sku_value` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `goods_id` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '商品ID', `sku_key` varchar(32) NOT NULL DEFAULT '' COMMENT '存放SKU库存量项目ID进行拼接', `thumb` varchar(255) NOT NULL DEFAULT 'http://oss.dgyouduo.com/static/img/no-image.png' COMMENT '缩略图', `price` decimal(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '普通价格', `market_price` decimal(10,2) unsigned NOT NULL DEFAULT '0.00' COMMENT '市场价格', `inventory` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '库存', `sort` tinyint(3) unsigned NOT NULL DEFAULT '0' COMMENT '排序', `is_trash` tinyint(1) unsigned NOT NULL DEFAULT '0' COMMENT '删除,0=>否,1=>是', `status` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT '状态,0=>禁用,1=>启用', `created_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '创建时间', `updated_at` int(11) unsigned NOT NULL DEFAULT '1451577600' COMMENT '更新时间', PRIMARY KEY (`id`), UNIQUE KEY `sku_key` (`sku_key`,`goods_id`,`is_trash`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 ROW_FORMAT=COMPACT COMMENT='模板商品库存量值'; ~~~