| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211 |
- -- =====================================================
- -- 勤工俭学管理系统完整字典数据脚本
- -- 项目: 校园管理系统 - 勤工俭学模块
- -- 版本: v1.0
- -- 创建时间: 2025-01-03
- -- 说明: 基于实际字典表结构的完整字典数据
- -- =====================================================
- -- 设置字符集
- SET NAMES utf8mb4;
- -- =====================================================
- -- 1. 岗位状态字典数据
- -- =====================================================
- -- 1.1 草稿
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001001, '000000', 1, '草稿', 'DRAFT', 'work_study_position_status', '', 'info', 'N', 103, 1, NOW(), '岗位创建但未发布');
- -- 1.2 已发布
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001002, '000000', 2, '已发布', 'PUBLISHED', 'work_study_position_status', '', 'primary', 'N', 103, 1, NOW(), '岗位已发布但未开始招录');
- -- 1.3 招录中
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001003, '000000', 3, '招录中', 'RECRUITING', 'work_study_position_status', '', 'success', 'Y', 103, 1, NOW(), '岗位正在招录学生');
- -- 1.4 已满员
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001004, '000000', 4, '已满员', 'FULL', 'work_study_position_status', '', 'warning', 'N', 103, 1, NOW(), '岗位申请人数已满');
- -- 1.5 已过期
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001005, '000000', 5, '已过期', 'EXPIRED', 'work_study_position_status', '', 'danger', 'N', 103, 1, NOW(), '岗位已过有效期');
- -- 1.6 已暂停
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001006, '000000', 6, '已暂停', 'SUSPENDED', 'work_study_position_status', '', 'info', 'N', 103, 1, NOW(), '岗位暂时停止招录');
- -- 1.7 已取消
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736001007, '000000', 7, '已取消', 'CANCELLED', 'work_study_position_status', '', 'danger', 'N', 103, 1, NOW(), '岗位被取消');
- -- =====================================================
- -- 2. 申请状态字典数据
- -- =====================================================
- -- 2.1 草稿
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002001, '000000', 1, '草稿', 'DRAFT', 'work_study_application_status', '', 'info', 'N', 103, 1, NOW(), '申请暂存未提交');
- -- 2.2 已提交
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002002, '000000', 2, '已提交', 'SUBMITTED', 'work_study_application_status', '', 'primary', 'Y', 103, 1, NOW(), '申请已提交,等待学院审核');
- -- 2.3 学院审核中
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002003, '000000', 3, '学院审核中', 'COLLEGE_REVIEWING', 'work_study_application_status', '', 'primary', 'N', 103, 1, NOW(), '二级学院正在审核');
- -- 2.4 学院审核通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002004, '000000', 4, '学院审核通过', 'COLLEGE_PASSED', 'work_study_application_status', '', 'success', 'N', 103, 1, NOW(), '学院审核通过,待学生处审核');
- -- 2.5 学院审核不通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002005, '000000', 5, '学院审核不通过', 'COLLEGE_REJECTED', 'work_study_application_status', '', 'danger', 'N', 103, 1, NOW(), '学院审核未通过');
- -- 2.6 学生处审核中
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002006, '000000', 6, '学生处审核中', 'FINAL_REVIEWING', 'work_study_application_status', '', 'warning', 'N', 103, 1, NOW(), '学生处正在终审');
- -- 2.7 审核通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002007, '000000', 7, '审核通过', 'APPROVED', 'work_study_application_status', '', 'success', 'N', 103, 1, NOW(), '最终审核通过');
- -- 2.8 审核不通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002008, '000000', 8, '审核不通过', 'REJECTED', 'work_study_application_status', '', 'danger', 'N', 103, 1, NOW(), '最终审核未通过');
- -- 2.9 已撤回
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736002009, '000000', 9, '已撤回', 'WITHDRAWN', 'work_study_application_status', '', 'info', 'N', 103, 1, NOW(), '学生主动撤回申请');
- -- =====================================================
- -- 3. 审核状态字典数据
- -- =====================================================
- -- 3.1 待审核
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736003001, '000000', 1, '待审核', 'PENDING', 'work_study_review_status', '', 'warning', 'Y', 103, 1, NOW(), '等待审核');
- -- 3.2 审核通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736003002, '000000', 2, '审核通过', 'PASSED', 'work_study_review_status', '', 'success', 'N', 103, 1, NOW(), '审核通过');
- -- 3.3 审核不通过
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736003003, '000000', 3, '审核不通过', 'REJECTED', 'work_study_review_status', '', 'danger', 'N', 103, 1, NOW(), '审核不通过');
- -- =====================================================
- -- 4. 岗位发布范围字典数据
- -- =====================================================
- -- 4.1 本学院
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736004001, '000000', 1, '本学院', 'COLLEGE', 'work_study_position_scope', '', 'primary', 'Y', 103, 1, NOW(), '仅本学院学生可见和申请');
- -- 4.2 全校
- INSERT INTO `sys_dict_data`
- (`dict_code`, `tenant_id`, `dict_sort`, `dict_label`, `dict_value`, `dict_type`, `css_class`, `list_class`, `is_default`, `create_dept`, `create_by`, `create_time`, `remark`)
- VALUES
- (1736004002, '000000', 2, '全校', 'UNIVERSITY', 'work_study_position_scope', '', 'success', 'N', 103, 1, NOW(), '所有学生可见和申请');
- -- =====================================================
- -- 5. 查询验证字典数据
- -- =====================================================
- -- 5.1 查询岗位状态字典
- SELECT
- dict_label as '标签',
- dict_value as '值',
- dict_type as '字典类型',
- list_class as '样式',
- remark as '说明'
- FROM sys_dict_data
- WHERE dict_type = 'work_study_position_status'
- ORDER BY dict_sort;
- -- 5.2 查询申请状态字典
- SELECT
- dict_label as '标签',
- dict_value as '值',
- dict_type as '字典类型',
- list_class as '样式',
- remark as '说明'
- FROM sys_dict_data
- WHERE dict_type = 'work_study_application_status'
- ORDER BY dict_sort;
- -- 5.3 查询审核状态字典
- SELECT
- dict_label as '标签',
- dict_value as '值',
- dict_type as '字典类型',
- list_class as '样式',
- remark as '说明'
- FROM sys_dict_data
- WHERE dict_type = 'work_study_review_status'
- ORDER BY dict_sort;
- -- 5.4 查询发布范围字典
- SELECT
- dict_label as '标签',
- dict_value as '值',
- dict_type as '字典类型',
- list_class as '样式',
- remark as '说明'
- FROM sys_dict_data
- WHERE dict_type = 'work_study_position_scope'
- ORDER BY dict_sort;
- -- =====================================================
- -- 6. 脚本执行完成提示
- -- =====================================================
- SELECT 'JCBT勤工俭学模块完整字典数据插入完成!' AS '执行结果';
- SELECT
- (SELECT COUNT(*) FROM sys_dict_data WHERE dict_type LIKE 'work_study%') AS '字典数据总数',
- (SELECT COUNT(*) FROM sys_dict_data WHERE dict_type = 'work_study_position_status') AS '岗位状态数量',
- (SELECT COUNT(*) FROM sys_dict_data WHERE dict_type = 'work_study_application_status') AS '申请状态数量',
- (SELECT COUNT(*) FROM sys_dict_data WHERE dict_type = 'work_study_review_status') AS '审核状态数量',
- (SELECT COUNT(*) FROM sys_dict_data WHERE dict_type = 'work_study_position_scope') AS '发布范围数量';
|