Files
yunzhupass-database/MySQL/09_cm_init.sql
朱进 768abcfc12 feat(database): 添加项目结构与合同模板相关表及字典数据
- 新增 base_project_structure_t 表,存储项目结构信息
- 新增 cm_contract_template 和 template_component 表,支持合同模板管理
- 添加合同管理相关字典类型和数据,包含合同分类等
- 添加基础配置字典类型及项目阶段、预算阶段、成本维度等字典数据
- 调整字符集和索引提升数据库性能和数据完整性保障
2026-05-15 09:34:43 +08:00

18 lines
3.5 KiB
SQL
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

----------------------------- 一级字典分类 -----------------------------
-- ----------------------------
-- 字典类型合同管理cm和字典数据
-- ----------------------------
INSERT INTO `base_dictionary_type` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_is_tree`, `f_type`, `f_description`, `f_enabled_mark`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('cm', '-1', '合同管理', 'cm', 0, 0, NULL, 1, 0, '2026-02-27 11:58:17', 'admin', NULL, NULL, NULL, NULL, NULL, '0');
----------------------------- 二级字典分类 -----------------------------
-- ----------------------------
-- 字典类型合同分类contractCategory和字典数据
-- ----------------------------
INSERT INTO `base_dictionary_type` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_is_tree`, `f_type`, `f_description`, `f_enabled_mark`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('contractCategory', 'cm', '合同分类', 'contractCategory', 0, 0, '合同分类', 1, 0, '2026-03-23 15:50:49', 'admin', '2026-04-24 10:01:11', 'admin', NULL, NULL, NULL, '0');
INSERT INTO `base_dictionary_data` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_simple_spelling`, `f_is_default`, `f_description`, `f_enabled_mark`, `f_dictionary_type_id`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('contractCategory_RJFW', 'contractCategory', '软件服务合同', '1001', 'RJFW', NULL, NULL, 1, 'contractCategory', 0, '2026-03-23 15:51:15', 'admin', NULL, NULL, NULL, NULL, NULL, '0');
INSERT INTO `base_dictionary_data` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_simple_spelling`, `f_is_default`, `f_description`, `f_enabled_mark`, `f_dictionary_type_id`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('contractCategory_JSZC', 'contractCategory', '技术支持合同', '1002', 'JSZC', NULL, NULL, 1, 'contractCategory', 1, '2026-03-23 15:51:32', 'admin', NULL, NULL, NULL, NULL, NULL, '0');
INSERT INTO `base_dictionary_data` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_simple_spelling`, `f_is_default`, `f_description`, `f_enabled_mark`, `f_dictionary_type_id`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('contractCategory_YWPX', 'contractCategory', '业务培训合同', '1003', 'YWPX', NULL, NULL, 1, 'contractCategory', 3, '2026-03-23 15:51:48', 'admin', NULL, NULL, NULL, NULL, NULL, '0');
INSERT INTO `base_dictionary_data` (`f_id`, `f_parent_id`, `f_full_name`, `f_en_code`, `f_simple_spelling`, `f_is_default`, `f_description`, `f_enabled_mark`, `f_dictionary_type_id`, `f_sort_code`, `f_creator_time`, `f_creator_user_id`, `f_last_modify_time`, `f_last_modify_user_id`, `f_delete_time`, `f_delete_user_id`, `f_delete_mark`, `f_tenant_id`) VALUES ('contractCategory_JZGC', 'contractCategory', '建筑工程合同', '1005', 'JZGC', NULL, NULL, 1, 'contractCategory', 4, '2026-03-23 15:52:08', 'admin', NULL, NULL, NULL, NULL, NULL, '0');