1 Star 0 Fork 324

Lajox / tp6

forked from 若水印象 / tp6 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
update.sql 18.04 KB
一键复制 编辑 原始数据 按行查看 历史
Lajox 提交于 2021-07-29 07:31 . 更新sql
ALTER TABLE `tp_auth_group`
ADD COLUMN `sort` mediumint(8) NULL DEFAULT 0 COMMENT '排序' AFTER `rules`;
-- ------------ update on 2020.05.26 增加伪静态规则管理功能 ------------------
INSERT INTO `tp_module` (`id`, `module_name`, `table_name`, `model_name`, `table_comment`, `table_type`, `pk`, `list_fields`, `remark`, `sort`, `create_time`, `update_time`, `is_sort`, `is_status`, `top_button`, `right_button`, `is_single`, `show_all`, `add_param`) VALUES ('26', '伪静态规则', 'rewrite', 'Rewrite', '伪静态规则', '2', 'id', '*', '伪静态规则', '50', '1590429376', '1590429376', '1', '1', 'add,edit,del,export', 'edit,delete', '0', '1', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('356', '26', 'id', '编号', '', '0', '0', '0', 'hidden', '0', '', '', '', '0', '0', '1', '0', '0', '', '1', '1', '自增ID', 'array (\'default\' => \'0\',\'extra_attr\' => \'\',\'extra_class\' => \'\',\'step\' => \'1\',\'fieldtype\' => \'int\',\'group\' => \'\')', '0');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('357', '26', 'create_time', '添加时间', '', '0', '0', '11', 'datetime', '0', '', '', '', '0', '0', '1', '0', '0', '=', '1', '45', '添加时间', 'array (\'default\' => \'0\', \'format\' => \'Y-m-d H:i:s\', \'extra_attr\' => \'\', \'extra_class\' => \'\', \'placeholder\' => \'\', \'fieldtype\' => \'int\',)', '0');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('358', '26', 'update_time', '更新时间', '', '0', '0', '11', 'datetime', '0', '', '', '', '0', '0', '0', '0', '0', '=', '1', '45', '更新时间', 'array (\n \'default\' => \'0\',\n \'format\' => \'Y-m-d H:i:s\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'int\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('359', '26', 'sort', '排序', '', '1', '0', '8', 'number', '0', '', '', '', '1', '1', '1', '0', '1', '=', '1', '49', '', 'array (\'default\' => \'50\', \'extra_attr\' => \'\', \'extra_class\' => \'\', \'step\' => \'1\', \'fieldtype\' => \'int\',)', '0');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('360', '26', 'status', '状态', '', '1', '0', '1', 'radio', '1', '', '', '1', '1', '1', '1', '1', '0', '=', '1', '48', '', 'array (\'default\' => \'1\', \'extra_attr\' => \'\', \'extra_class\' => \'\', \'fieldtype\' => \'tinyint\',)', '0');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('361', '26', 'title', '规则名称', '', '1', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', 'like', '1', '2', '规则名称', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('362', '26', 'describe', '规则描述', '', '0', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', 'like', '1', '3', '规则描述', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '0');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('363', '26', 'origin_url', '原地址', '', '0', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '0', 'like', '1', '4', '原地址', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('364', '26', 'rule', '路由规则', '自动从URL获取参数规则为 <参数名>,例如:&lt;id&gt;将自动获取id参数', '1', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', 'like', '1', '5', '路由规则', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('365', '26', 'test_param', '测试参数', '若路由规则里含有<参数名>,则需填写测试参数,例如:id=1', '0', '0', '0', 'text', '0', '', '', '', '1', '1', '0', '0', '0', 'like', '1', '6', '测试参数', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('366', '26', 'route_g', '模块名', '', '1', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', '=', '1', '7', '模块名', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('367', '26', 'route_c', '控制器名', '', '1', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', '=', '1', '8', '控制器名', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('368', '26', 'route_a', '方法名', '', '1', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', '=', '1', '9', '方法名', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_field` (`id`, `module_id`, `field`, `name`, `tips`, `required`, `minlength`, `maxlength`, `type`, `data_source`, `relation_model`, `relation_field`, `dict_code`, `is_add`, `is_edit`, `is_list`, `is_search`, `is_sort`, `search_type`, `status`, `sort`, `remark`, `setup`, `group_id`) VALUES ('369', '26', 'route_param', '固定参数', '例如: cate_id=5&id=1', '0', '0', '0', 'text', '0', '', '', '', '1', '1', '1', '1', '1', 'like', '1', '10', '固定参数', 'array (\n \'default\' => \'\',\n \'extra_attr\' => \'\',\n \'extra_class\' => \'\',\n \'placeholder\' => \'\',\n \'fieldtype\' => \'varchar\',\n \'group\' => \'\',\n)', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('283', '0', 'Rewrite/index', '伪静态规则', '1', '1', '', '50', '1', 'fa fa-eye-slash', '1590429388', '1590429676', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('284', '283', 'Rewrite/add', '操作-添加', '1', '0', '', '1', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('285', '283', 'Rewrite/addPost', '操作-添加保存', '1', '0', '', '2', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('286', '283', 'Rewrite/edit', '操作-修改', '1', '0', '', '3', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('287', '283', 'Rewrite/editPost', '操作-修改保存', '1', '0', '', '4', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('288', '283', 'Rewrite/del', '操作-删除', '1', '0', '', '5', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('289', '283', 'Rewrite/selectDel', '操作-批量删除', '1', '0', '', '6', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('290', '283', 'Rewrite/export', '操作-导出', '1', '0', '', '7', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('291', '283', 'Rewrite/sort', '操作-排序', '1', '0', '', '8', '1', '', '1590429388', '1590429388', '');
INSERT INTO `tp_auth_rule` (`id`, `pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('292', '283', 'Rewrite/state', '操作-状态', '1', '0', '', '9', '1', '', '1590429388', '1590429388', '');
-- ----------------------------
-- Table structure for tp_rewrite
-- ----------------------------
DROP TABLE IF EXISTS `tp_rewrite`;
CREATE TABLE `tp_rewrite` (
`id` int(8) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`create_time` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '添加时间',
`update_time` int(11) unsigned NOT NULL DEFAULT '0' COMMENT '更新时间',
`sort` mediumint(8) DEFAULT '50' COMMENT '排序',
`status` tinyint(1) DEFAULT NULL COMMENT '状态',
`title` varchar(255) NOT NULL DEFAULT '' COMMENT '规则名称',
`describe` varchar(255) NOT NULL DEFAULT '' COMMENT '规则描述',
`origin_url` varchar(255) NOT NULL DEFAULT '' COMMENT '原地址',
`rule` varchar(255) NOT NULL DEFAULT '' COMMENT '路由规则',
`test_param` varchar(255) NOT NULL DEFAULT '' COMMENT '测试参数',
`route_g` varchar(255) NOT NULL DEFAULT '' COMMENT '模块名',
`route_c` varchar(255) NOT NULL DEFAULT '' COMMENT '控制器名',
`route_a` varchar(255) NOT NULL DEFAULT '' COMMENT '方法名',
`route_param` varchar(255) NOT NULL DEFAULT '' COMMENT '固定参数',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='伪静态规则';
-- ----------------------------
-- Records of tp_rewrite
-- ----------------------------
INSERT INTO `tp_rewrite` VALUES ('1', '1590431830', '1590434982', '50', '1', '关于我们', '', '/index/about.html', 'aboutus', '', 'index', 'about', 'index', '');
INSERT INTO `tp_rewrite` VALUES ('2', '1590441666', '1590472880', '100', '1', '公司新闻-列表', '', '/index/Article/index.html?cate=5', 'news', '', 'index', 'article', 'index', 'cate=5');
INSERT INTO `tp_rewrite` VALUES ('3', '1590465978', '1590472870', '101', '1', '公司新闻-详情页(多个页面)', '', '/index/Article/info.html?cate=5&id=1', 'news/<id>', 'id=1', 'index', 'article', 'info', 'cate=5');
-- ------------ update on 2020.06.10 ------------------
INSERT INTO `tp_config` (`name`, `value`, `inc_type`, `desc`) VALUES ('app_id', '', 'xcx', NULL);
INSERT INTO `tp_config` (`name`, `value`, `inc_type`, `desc`) VALUES ('app_secret', '', 'xcx', NULL);
INSERT INTO `tp_config` (`name`, `value`, `inc_type`, `desc`) VALUES ('wxpay_mchid', '', 'xcx', NULL);
INSERT INTO `tp_config` (`name`, `value`, `inc_type`, `desc`) VALUES ('wxpay_apikey', '', 'xcx', NULL);
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('157', 'Config/xcx', '小程序配置', '1', '1', '', '18', '1', 'fa fa-wechat', '1591892827', '1591893098', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('291', 'Config/xcxPost', '操作-修改保存', '1', '0', '', '1', '1', '', '1591892900', '1591892912', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('147', 'Field/changeModule', '操作-加载分组', '1', '0', '', '10', '1', '', '1591331334', '1591331343', '');
-- ------------ update on 2020.06.12 ------------------
-- ----------------------------
-- Table structure for tp_api_log
-- ----------------------------
DROP TABLE IF EXISTS `tp_api_log`;
CREATE TABLE `tp_api_log` (
`id` int(11) unsigned NOT NULL AUTO_INCREMENT COMMENT '主键ID',
`url` text NOT NULL COMMENT '接口地址',
`app_route` varchar(100) NOT NULL DEFAULT '' COMMENT 'app路由定位',
`request_param` text NOT NULL COMMENT '请求参数',
`request_method` varchar(20) NOT NULL DEFAULT '' COMMENT '请求方法',
`request_content_type` varchar(40) DEFAULT '' COMMENT '请求类型',
`request_ip` varchar(50) DEFAULT '' COMMENT 'IP地址',
`http_user_agent` text COMMENT 'User-Agent',
`response_text` text COMMENT '响应结果',
`response_content_type` varchar(40) DEFAULT '' COMMENT '响应类型',
`response_code` varchar(8) DEFAULT '' COMMENT 'HTTP状态码',
`is_success` tinyint(4) NOT NULL DEFAULT '0' COMMENT '是否成功',
`uid` int(11) DEFAULT '0' COMMENT '用户ID',
`create_time` int(11) NOT NULL DEFAULT '0' COMMENT '创建时间',
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 ROW_FORMAT=COMPACT COMMENT='API调用日志';
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('0', 'ApiLog/index', 'API日志', '1', '1', '', '50', '1', 'fa fa-history', '1591893964', '1591893964', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/detail', '操作-详情', '1', '0', '', '1', '1', '', '1591894102', '1591894315', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/edit', '操作-修改', '1', '0', '', '2', '1', '', '1591894132', '1591894320', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/editPost', '操作-修改保存', '1', '0', '', '3', '1', '', '1591894178', '1591894324', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/del', '操作-删除', '1', '0', '', '4', '1', '', '1591894213', '1591894327', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/selectDel', '操作-批量删除', '1', '0', '', '5', '1', '', '1591894243', '1591894331', '');
INSERT INTO `tp_auth_rule` (`pid`, `name`, `title`, `type`, `status`, `condition`, `sort`, `auth_open`, `icon`, `create_time`, `update_time`, `param`) VALUES ('296', 'ApiLog/deleteAgo', '操作-删除一个月前日志', '1', '0', '', '6', '1', '', '1591894301', '1591894336', '');
PHP
1
https://gitee.com/lajox/tp6.git
git@gitee.com:lajox/tp6.git
lajox
tp6
tp6
master

搜索帮助