常量

12135

常量总览

_constant结构

  1. CREATE TABLE `_constant` (
  2. `id` int(11) NOT NULL AUTO_INCREMENT,
  3. `constantKey` varchar(255) DEFAULT NULL,
  4. `constantType` varchar(255) DEFAULT NULL COMMENT '常量类型; object, array',
  5. `desc` varchar(255) DEFAULT NULL COMMENT '描述',
  6. `constantValue` text COMMENT '常量内容; object, array',
  7. `operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
  8. `operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
  9. `operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
  10. `operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
  11. PRIMARY KEY (`id`) USING BTREE
  12. ) ENGINE = InnoDB AUTO_INCREMENT = 5 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC COMMENT = '常量表; 软删除未启用;'

_constant 表数据

通知类型

constantKey constantType
noticeType array
  1. [
  2. {
  3. "text": "公告",
  4. "value": "公告"
  5. },
  6. {
  7. "text": "任务",
  8. "value": "任务"
  9. },
  10. {
  11. "text": "审批",
  12. "value": "审批"
  13. },
  14. {
  15. "text": "日志",
  16. "value": "日志"
  17. }
  18. ]

任务优先级

constantKey constantType
taskLevel array
  1. [
  2. {
  3. "text": "无",
  4. "value": "无",
  5. "color": "grey"
  6. },
  7. {
  8. "text": "低",
  9. "value": "低",
  10. "color": "green"
  11. },
  12. {
  13. "text": "中",
  14. "value": "中",
  15. "color": "orange"
  16. },
  17. {
  18. "text": "高",
  19. "value": "高",
  20. "color": "red"
  21. }
  22. ]

任务状态

constantKey constantType
taskStatus array
  1. [
  2. {
  3. "text": "未开始",
  4. "value": "未开始",
  5. "color": "blue"
  6. },
  7. {
  8. "text": "进行中",
  9. "value": "进行中",
  10. "color": "orange"
  11. },
  12. {
  13. "text": "已完成",
  14. "value": "已完成",
  15. "color": "grey"
  16. }
  17. ]

任务模板分组

constantKey constantType
taskTemplateGroup array
  1. [
  2. {
  3. "text": "行政",
  4. "value": "行政"
  5. },
  6. {
  7. "text": "人事",
  8. "value": "人事"
  9. },
  10. {
  11. "text": "其他",
  12. "value": "其他"
  13. }
  14. ]

_constant语句

  1. INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (1, 'noticeType', 'array', '通知类型', '[
  2. {
  3. "text": "公告",
  4. "value": "公告"
  5. },
  6. {
  7. "text": "任务",
  8. "value": "任务"
  9. },
  10. {
  11. "text": "审批",
  12. "value": "审批"
  13. },
  14. {
  15. "text": "日志",
  16. "value": "日志"
  17. }
  18. ]', 'update', NULL, NULL, '2023-03-07T15:17:37+08:00');
  19. INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (2, 'taskLevel', 'array', '任务优先级', '[
  20. {
  21. "text": "无",
  22. "value": "无",
  23. "color": "grey"
  24. },
  25. {
  26. "text": "低",
  27. "value": "低",
  28. "color": "green"
  29. },
  30. {
  31. "text": "中",
  32. "value": "中",
  33. "color": "orange"
  34. },
  35. {
  36. "text": "高",
  37. "value": "高",
  38. "color": "red"
  39. }
  40. ]', 'update', NULL, NULL, '2023-03-07T15:17:37+08:00');
  41. INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (3, 'taskStatus', 'array', '任务状态', '[
  42. {
  43. "text": "未开始",
  44. "value": "未开始",
  45. "color": "blue"
  46. },
  47. {
  48. "text": "进行中",
  49. "value": "进行中",
  50. "color": "orange"
  51. },
  52. {
  53. "text": "已完成",
  54. "value": "已完成",
  55. "color": "grey"
  56. }
  57. ]', 'update', NULL, NULL, '2023-03-07T15:17:37+08:00');
  58. INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (4, 'taskTemplateGroup', 'array', '任务模板分组', '[
  59. {
  60. "text": "行政",
  61. "value": "行政"
  62. },
  63. {
  64. "text": "人事",
  65. "value": "人事"
  66. },
  67. {
  68. "text": "其他",
  69. "value": "其他"
  70. }
  71. ]', 'update', NULL, NULL, '2023-03-07T15:17:37+08:00');