178 lines
15 KiB
SQL
178 lines
15 KiB
SQL
-- =========================================================================
|
|
-- 学生信息管理模块字典数据SQL脚本(修正版)
|
|
-- 创建日期:2025-01-14
|
|
-- 功能说明:为学生信息管理模块添加字典数据
|
|
-- 注意事项:使用INSERT IGNORE避免重复插入已存在的字典类型
|
|
-- =========================================================================
|
|
|
|
-- ===========================================
|
|
-- 1. 学籍状态字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3001, '000000', '学籍状态', 'xg_student_status', 1, NOW(), '学生学籍状态列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30011, '000000', 1, '在校', '1', 'xg_student_status', '', 'primary', 'Y', 1, NOW(), '正常在校'),
|
|
(30012, '000000', 2, '休学', '2', 'xg_student_status', '', 'warning', 'N', 1, NOW(), '休学状态'),
|
|
(30013, '000000', 3, '退学', '3', 'xg_student_status', '', 'danger', 'N', 1, NOW(), '退学状态'),
|
|
(30014, '000000', 4, '毕业', '4', 'xg_student_status', '', 'success', 'N', 1, NOW(), '已毕业'),
|
|
(30015, '000000', 5, '肄业', '5', 'xg_student_status', '', 'info', 'N', 1, NOW(), '肄业状态'),
|
|
(30016, '000000', 6, '转学', '6', 'xg_student_status', '', 'warning', 'N', 1, NOW(), '转学状态');
|
|
|
|
-- ===========================================
|
|
-- 2. 信息状态字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3002, '000000', '信息状态', 'xg_info_status', 1, NOW(), '学生信息状态列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30021, '000000', 1, '草稿', '1', 'xg_info_status', '', 'info', 'Y', 1, NOW(), '信息录入中'),
|
|
(30022, '000000', 2, '待审核', '2', 'xg_info_status', '', 'warning', 'N', 1, NOW(), '待审核状态'),
|
|
(30023, '000000', 3, '审核通过', '3', 'xg_info_status', '', 'success', 'N', 1, NOW(), '审核通过'),
|
|
(30024, '000000', 4, '审核拒绝', '4', 'xg_info_status', '', 'danger', 'N', 1, NOW(), '审核拒绝'),
|
|
(30025, '000000', 5, '需修改', '5', 'xg_info_status', '', 'warning', 'N', 1, NOW(), '需要修改');
|
|
|
|
-- ===========================================
|
|
-- 3. 政治面貌字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3003, '000000', '政治面貌', 'xg_political_status', 1, NOW(), '政治面貌列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30031, '000000', 1, '中共党员', 'CCP_MEMBER', 'xg_political_status', '', 'danger', 'N', 1, NOW(), '中国共产党党员'),
|
|
(30032, '000000', 2, '中共预备党员', 'CCP_PROBATIONARY', 'xg_political_status', '', 'warning', 'N', 1, NOW(), '中国共产党预备党员'),
|
|
(30033, '000000', 3, '共青团员', 'LEAGUE_MEMBER', 'xg_political_status', '', 'primary', 'Y', 1, NOW(), '中国共产主义青年团团员'),
|
|
(30034, '000000', 4, '民革党员', 'MING_GE', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国国民党革命委员会'),
|
|
(30035, '000000', 5, '民盟盟员', 'MING_MENG', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国民主同盟'),
|
|
(30036, '000000', 6, '民建会员', 'MING_JIAN', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国民主建国会'),
|
|
(30037, '000000', 7, '民进会员', 'MING_JIN', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国民主促进会'),
|
|
(30038, '000000', 8, '农工党党员', 'NONG_GONG', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国农工民主党'),
|
|
(30039, '000000', 9, '致公党党员', 'ZHI_GONG', 'xg_political_status', '', 'info', 'N', 1, NOW(), '中国致公党'),
|
|
(30040, '000000', 10, '九三学社社员', 'JIU_SAN', 'xg_political_status', '', 'info', 'N', 1, NOW(), '九三学社'),
|
|
(30041, '000000', 11, '台盟盟员', 'TAI_MENG', 'xg_political_status', '', 'info', 'N', 1, NOW(), '台湾民主自治同盟'),
|
|
(30042, '000000', 12, '无党派人士', 'NO_PARTY', 'xg_political_status', '', 'info', 'N', 1, NOW(), '无党派人士'),
|
|
(30043, '000000', 13, '群众', 'MASSES', 'xg_political_status', '', 'success', 'N', 1, NOW(), '群众');
|
|
|
|
-- ===========================================
|
|
-- 4. 民族字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3004, '000000', '民族', 'xg_nation', 1, NOW(), '中华民族56个民族列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30041, '000000', 1, '汉族', '01', 'xg_nation', '', 'primary', 'Y', 1, NOW(), '汉族'),
|
|
(30042, '000000', 2, '蒙古族', '02', 'xg_nation', '', '', 'N', 1, NOW(), '蒙古族'),
|
|
(30043, '000000', 3, '回族', '03', 'xg_nation', '', '', 'N', 1, NOW(), '回族'),
|
|
(30044, '000000', 4, '藏族', '04', 'xg_nation', '', '', 'N', 1, NOW(), '藏族'),
|
|
(30045, '000000', 5, '维吾尔族', '05', 'xg_nation', '', '', 'N', 1, NOW(), '维吾尔族'),
|
|
(30046, '000000', 6, '苗族', '06', 'xg_nation', '', '', 'N', 1, NOW(), '苗族'),
|
|
(30047, '000000', 7, '彝族', '07', 'xg_nation', '', '', 'N', 1, NOW(), '彝族'),
|
|
(30048, '000000', 8, '壮族', '08', 'xg_nation', '', '', 'N', 1, NOW(), '壮族'),
|
|
(30049, '000000', 9, '布依族', '09', 'xg_nation', '', '', 'N', 1, NOW(), '布依族'),
|
|
(30050, '000000', 10, '朝鲜族', '10', 'xg_nation', '', '', 'N', 1, NOW(), '朝鲜族'),
|
|
(30051, '000000', 11, '满族', '11', 'xg_nation', '', '', 'N', 1, NOW(), '满族'),
|
|
(30052, '000000', 12, '侗族', '12', 'xg_nation', '', '', 'N', 1, NOW(), '侗族'),
|
|
(30053, '000000', 13, '瑶族', '13', 'xg_nation', '', '', 'N', 1, NOW(), '瑶族'),
|
|
(30054, '000000', 14, '白族', '14', 'xg_nation', '', '', 'N', 1, NOW(), '白族'),
|
|
(30055, '000000', 15, '土家族', '15', 'xg_nation', '', '', 'N', 1, NOW(), '土家族'),
|
|
(30056, '000000', 16, '哈尼族', '16', 'xg_nation', '', '', 'N', 1, NOW(), '哈尼族'),
|
|
(30057, '000000', 17, '哈萨克族', '17', 'xg_nation', '', '', 'N', 1, NOW(), '哈萨克族'),
|
|
(30058, '000000', 18, '傣族', '18', 'xg_nation', '', '', 'N', 1, NOW(), '傣族'),
|
|
(30059, '000000', 19, '黎族', '19', 'xg_nation', '', '', 'N', 1, NOW(), '黎族'),
|
|
(30060, '000000', 20, '傈僳族', '20', 'xg_nation', '', '', 'N', 1, NOW(), '傈僳族'),
|
|
(30061, '000000', 21, '佤族', '21', 'xg_nation', '', '', 'N', 1, NOW(), '佤族'),
|
|
(30062, '000000', 22, '畲族', '22', 'xg_nation', '', '', 'N', 1, NOW(), '畲族'),
|
|
(30063, '000000', 23, '高山族', '23', 'xg_nation', '', '', 'N', 1, NOW(), '高山族'),
|
|
(30064, '000000', 24, '拉祜族', '24', 'xg_nation', '', '', 'N', 1, NOW(), '拉祜族'),
|
|
(30065, '000000', 25, '水族', '25', 'xg_nation', '', '', 'N', 1, NOW(), '水族');
|
|
|
|
-- ===========================================
|
|
-- 5. 血型字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3005, '000000', '血型', 'xg_blood_type', 1, NOW(), '血型分类列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30051, '000000', 1, 'A型', 'A', 'xg_blood_type', '', 'primary', 'N', 1, NOW(), 'A型血'),
|
|
(30052, '000000', 2, 'B型', 'B', 'xg_blood_type', '', 'success', 'N', 1, NOW(), 'B型血'),
|
|
(30053, '000000', 3, 'AB型', 'AB', 'xg_blood_type', '', 'warning', 'N', 1, NOW(), 'AB型血'),
|
|
(30054, '000000', 4, 'O型', 'O', 'xg_blood_type', '', 'danger', 'N', 1, NOW(), 'O型血'),
|
|
(30055, '000000', 5, '未知', 'UNKNOWN', 'xg_blood_type', '', 'info', 'Y', 1, NOW(), '未知血型');
|
|
|
|
-- ===========================================
|
|
-- 6. 培养方式字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3006, '000000', '培养方式', 'xg_training_mode', 1, NOW(), '学生培养方式列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30061, '000000', 1, '统招', 'UNIFIED', 'xg_training_mode', '', 'primary', 'Y', 1, NOW(), '统一招生'),
|
|
(30062, '000000', 2, '自费', 'SELF_FUNDED', 'xg_training_mode', '', 'warning', 'N', 1, NOW(), '自费生'),
|
|
(30063, '000000', 3, '委培', 'COMMISSIONED', 'xg_training_mode', '', 'info', 'N', 1, NOW(), '委托培养'),
|
|
(30064, '000000', 4, '定向', 'DIRECTED', 'xg_training_mode', '', 'success', 'N', 1, NOW(), '定向培养'),
|
|
(30065, '000000', 5, '专升本', 'ASSOCIATE_TO_BACHELOR', 'xg_training_mode', '', 'warning', 'N', 1, NOW(), '专科升本科'),
|
|
(30066, '000000', 6, '研究生', 'GRADUATE', 'xg_training_mode', '', 'danger', 'N', 1, NOW(), '研究生');
|
|
|
|
-- ===========================================
|
|
-- 7. 班级职务字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3007, '000000', '班级职务', 'xg_class_position', 1, NOW(), '班级干部职务列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30071, '000000', 1, '班长', 'MONITOR', 'xg_class_position', '', 'danger', 'N', 1, NOW(), '班长'),
|
|
(30072, '000000', 2, '副班长', 'VICE_MONITOR', 'xg_class_position', '', 'warning', 'N', 1, NOW(), '副班长'),
|
|
(30073, '000000', 3, '学习委员', 'STUDY_COMMISSIONER', 'xg_class_position', '', 'primary', 'N', 1, NOW(), '学习委员'),
|
|
(30074, '000000', 4, '生活委员', 'LIFE_COMMISSIONER', 'xg_class_position', '', 'success', 'N', 1, NOW(), '生活委员'),
|
|
(30075, '000000', 5, '体育委员', 'SPORTS_COMMISSIONER', 'xg_class_position', '', 'info', 'N', 1, NOW(), '体育委员'),
|
|
(30076, '000000', 6, '文艺委员', 'CULTURE_COMMISSIONER', 'xg_class_position', '', 'warning', 'N', 1, NOW(), '文艺委员'),
|
|
(30077, '000000', 7, '宣传委员', 'PUBLICITY_COMMISSIONER', 'xg_class_position', '', 'primary', 'N', 1, NOW(), '宣传委员'),
|
|
(30078, '000000', 8, '组织委员', 'ORGANIZATION_COMMISSIONER', 'xg_class_position', '', 'danger', 'N', 1, NOW(), '组织委员'),
|
|
(30079, '000000', 9, '心理委员', 'PSYCHOLOGY_COMMISSIONER', 'xg_class_position', '', 'info', 'N', 1, NOW(), '心理委员'),
|
|
(30080, '000000', 10, '安全委员', 'SAFETY_COMMISSIONER', 'xg_class_position', '', 'warning', 'N', 1, NOW(), '安全委员'),
|
|
(30081, '000000', 11, '普通学生', 'STUDENT', 'xg_class_position', '', '', 'Y', 1, NOW(), '普通学生');
|
|
|
|
-- ===========================================
|
|
-- 8. 批次状态字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3008, '000000', '批次状态', 'xg_batch_status', 1, NOW(), '信息采集批次状态列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30081, '000000', 1, '未开始', '1', 'xg_batch_status', '', 'info', 'N', 1, NOW(), '批次未开始'),
|
|
(30082, '000000', 2, '进行中', '2', 'xg_batch_status', '', 'warning', 'Y', 1, NOW(), '批次进行中'),
|
|
(30083, '000000', 3, '已结束', '3', 'xg_batch_status', '', 'success', 'N', 1, NOW(), '批次已结束'),
|
|
(30084, '000000', 4, '已暂停', '4', 'xg_batch_status', '', 'danger', 'N', 1, NOW(), '批次已暂停'),
|
|
(30085, '000000', 5, '已取消', '5', 'xg_batch_status', '', 'info', 'N', 1, NOW(), '批次已取消');
|
|
|
|
-- ===========================================
|
|
-- 9. 审核结果字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3009, '000000', '审核结果', 'xg_audit_result', 1, NOW(), '审核结果列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30091, '000000', 1, '待审核', 'PENDING', 'xg_audit_result', '', 'info', 'Y', 1, NOW(), '等待审核'),
|
|
(30092, '000000', 2, '审核通过', 'APPROVED', 'xg_audit_result', '', 'success', 'N', 1, NOW(), '审核通过'),
|
|
(30093, '000000', 3, '审核拒绝', 'REJECTED', 'xg_audit_result', '', 'danger', 'N', 1, NOW(), '审核拒绝'),
|
|
(30094, '000000', 4, '需要修改', 'NEED_MODIFY', 'xg_audit_result', '', 'warning', 'N', 1, NOW(), '需要修改'),
|
|
(30095, '000000', 5, '退回重填', 'RETURN_REFILL', 'xg_audit_result', '', 'warning', 'N', 1, NOW(), '退回重新填写');
|
|
|
|
-- ===========================================
|
|
-- 10. 家庭经济状况字典(新增)
|
|
-- ===========================================
|
|
INSERT IGNORE INTO `sys_dict_type` (`dict_id`, `tenant_id`, `dict_name`, `dict_type`, `create_by`, `create_time`, `remark`) VALUES
|
|
(3010, '000000', '家庭经济状况', 'xg_family_economic', 1, NOW(), '家庭经济状况列表');
|
|
|
|
INSERT IGNORE INTO `sys_dict_data` (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_by`, `create_time`, `remark`) VALUES
|
|
(30101, '000000', 1, '富裕', 'WEALTHY', 'xg_family_economic', '', 'success', 'N', 1, NOW(), '家庭富裕'),
|
|
(30102, '000000', 2, '一般', 'AVERAGE', 'xg_family_economic', '', 'primary', 'Y', 1, NOW(), '家庭经济一般'),
|
|
(30103, '000000', 3, '困难', 'DIFFICULT', 'xg_family_economic', '', 'warning', 'N', 1, NOW(), '家庭经济困难'),
|
|
(30104, '000000', 4, '特别困难', 'VERY_DIFFICULT', 'xg_family_economic', '', 'danger', 'N', 1, NOW(), '家庭经济特别困难');
|
|
|
|
-- ===========================================
|
|
-- 脚本执行完成提示
|
|
-- ===========================================
|
|
SELECT 'XG学生信息管理模块字典数据创建完成!' as message;
|
|
SELECT '共创建10个字典类型,包含约80个字典数据项' as summary;
|
|
SELECT '所有字典都使用INSERT IGNORE避免重复插入' as features; |