Files

84 lines
5.8 KiB
SQL

-- import to SQLite by running: sqlite3.exe db.sqlite3 -init sqlite.sql
PRAGMA journal_mode = MEMORY;
PRAGMA synchronous = OFF;
PRAGMA foreign_keys = OFF;
PRAGMA ignore_check_constraints = OFF;
PRAGMA auto_vacuum = NONE;
PRAGMA secure_delete = OFF;
BEGIN TRANSACTION;
create table `xh_article`
(
`id` bigint NOT NULL ,
`title` TEXT DEFAULT NULL ,
`author` TEXT DEFAULT NULL ,
`content` TEXT DEFAULT NULL ,
`status` INTEGER DEFAULT NULL ,
`order` int DEFAULT 0 ,
`create_by` bigint DEFAULT NULL,
`update_by` bigint DEFAULT NULL,
`publish_at` datetime NULL DEFAULT NULL ,
`created_at` datetime not null default current_timestamp ,
`updated_at` datetime not null ,
`deleted_at` datetime NULL DEFAULT NULL,
PRIMARY KEY (`id`)
);
create TABLE `xh_category`
(
`id` bigint not null ,
`title` TEXT default null ,
`slug` TEXT not null ,
`desc` TEXT null ,
`parent` bigint default 0 ,
`order` bigint default 0 ,
`status` INTEGER default NULL ,
`created_at` datetime not null default current_timestamp ,
`updated_at` datetime not null ,
PRIMARY KEY (`id`),
unique (`slug`)
);
insert into `xh_category` values (1, '网站首页', 'wzsy', '网站首页-分类', 0, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (2, '协会概况', 'xhgk', '协会概况-分类', 0, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (3, '协会简介', 'xhjj', '协会简介-分类', 2, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (4, '规章制度', 'gzzd', '规章制度-分类', 2, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (5, '协会领导', 'xhld', '协会领导-分类', 2, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (6, '发展历程', 'fzlc', '发展历程-分类', 2, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (7, '联系我们', 'lxwm', '联系我们-分类', 2, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (8, '重点资讯', 'zdzx', '重点资讯-分类', 0, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (9, '新闻资讯', 'xwzx', '新闻资讯-分类', 8, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (10, '通知公告', 'tzgg', '通知公告-分类', 8, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (11, '行业动态', 'hydt', '行业动态-分类', 8, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (12, '品牌活动', 'pphd', '品牌活动-分类', 8, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (13, '学习专栏', 'xxzl', '学习专栏-分类', 8, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (14, '分支机构', 'fzjg', '分支机构-分类', 0, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (15, '乡村振兴与共同富裕委员会', 'xczxygtfywyh', '乡村振兴与共同富裕委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (16, '文化艺术委员会', 'whyswyh', '文化艺术委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (17, '旅游委员会', 'lywyh', '旅游委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (18, '科技委员会', 'kjwyh', '科技委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (19, '海外联谊委员会', 'hwlywyh', '海外联谊委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (20, '中华民族城建委员会', 'zhmzcjwyh', '中华民族城建委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (21, '基金管理委员会', 'jjglwyh', '基金管理委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (22, '专家委员会', 'zjwyh', '专家委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (23, '中华传统医药委员会', 'zhctyywyh', '中华传统医药委员会-分类', 15, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (24, '主题活动', 'tthd', '主题活动-分类', 0, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (25, '会员代表大会', 'hydbdh', '会员代表大会-分类', 24, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (26, '理事会工作会议', 'lshgzhy', '理事会工作会议-分类', 24, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (27, '青少年交流专题', 'qsnjlzt', '青少年交流专题-分类', 24, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (28, '互嵌式发展专题', 'hqsfzzt', '互嵌式发展专题-分类', 24, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (29, '旅游振兴专题', 'lyzxzt', '旅游振兴专题-分类', 24, 0, 0, current_timestamp, current_timestamp);
insert into `xh_category` values (30, '会员天地', 'hytd', '会员天地-分类', 0, 0, 0, current_timestamp, current_timestamp);
COMMIT;
PRAGMA ignore_check_constraints = ON;
PRAGMA foreign_keys = ON;
PRAGMA journal_mode = WAL;
PRAGMA synchronous = NORMAL;