常量
12114常量总览
_constant结构
CREATE TABLE `_constant` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`constantKey` varchar(255) DEFAULT NULL,
`constantType` varchar(255) DEFAULT NULL COMMENT '常量类型; object, array',
`desc` varchar(255) DEFAULT NULL COMMENT '描述',
`constantValue` text COMMENT '常量内容; object, array',
`operation` varchar(255) DEFAULT 'insert' COMMENT '操作; insert, update, jhInsert, jhUpdate, jhDelete jhRestore',
`operationByUserId` varchar(255) DEFAULT NULL COMMENT '操作者userId',
`operationByUser` varchar(255) DEFAULT NULL COMMENT '操作者用户名',
`operationAt` varchar(255) DEFAULT NULL COMMENT '操作时间; E.g: 2021-05-28T10:24:54+08:00 ',
PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB AUTO_INCREMENT = 67 DEFAULT CHARSET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '常量表;'
_constant 表数据
constantKey:bookCover
constantType:array
[
{
"text": "图标1 语文",
"value": "/bookCover/1684392567970_906812_图标语文.png"
},
{
"text": "图标2 数学",
"value": "/bookCover/1684392581983_621071_图标数学.png"
}
]
null
constantKey:userStatus
constantType:array
[
{
"value": "active",
"text": "正常"
},
{
"value": "banned",
"text": "禁用"
}
]
null
constantKey:userType
constantType:array
[
{
"value": "common",
"text": "普通用户"
},
{
"value": "xiaochengxu",
"text": "小程序机器人"
}
]
null
constantKey:gender
constantType:array
[
{
"value": "male",
"text": "男"
},
{
"value": "female",
"text": "女"
}
]
null
constantKey:version
constantType:object
{
"testUserIdList": "",
"version": "4.3.11",
"title": "4.3.7 版本发布",
"note": "新版本介绍\n 1. 聊天输入优化",
"apkVersion": "5.0.20",
"apkLink": "https://duoxing.openjianghu.org/duoxing/upload/10002/1647840662817_956853_D多星MD-4.7.10.apk",
"apkNote": "",
"desktopVersion": "4.3.2",
"desktopLink": "http://192.168.110.215:8082/duoxing/upload/duoxing-1.0.1.dmg.zip",
"desktopNote": "测试桌面客户端升级"
}
null
constantKey:emotion
constantType:array
[
{
"dir": "face01",
"cover": "face-lbl",
"ext": "png",
"cols": 5,
"total": 86
},
{
"dir": "face02",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face03",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face04",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face05",
"cover": "face-lbl",
"ext": "gif",
"cols": 1,
"total": 7
},
{
"dir": "face06",
"cover": "face-lbl",
"ext": "gif",
"cols": 3,
"total": 24
},
{
"dir": "face07",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face08",
"cover": "face-lbl",
"ext": "gif",
"cols": 3,
"total": 23
},
{
"dir": "face09",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face10",
"cover": "face-lbl",
"ext": "gif",
"cols": 3,
"total": 20
},
{
"dir": "face11",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 13
},
{
"dir": "face12",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
},
{
"dir": "face13",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 15
},
{
"dir": "face14",
"cover": "face-lbl",
"ext": "gif",
"cols": 2,
"total": 16
}
]
null
constantKey:appLinkActionConfig
constantType:array
[
{
"regex": ".openjianghu.org/*",
"action": "internal"
},
{
"regex": "http://192.168./*",
"action": "internal"
}
]
年级列表
constantKey:level
constantType:array
[
{
"value": "01",
"text": "一年级"
},
{
"value": "02",
"text": "二年级"
},
{
"value": "03",
"text": "三年级"
},
{
"value": "04",
"text": "四年级"
},
{
"value": "05",
"text": "五年级"
},
{
"value": "06",
"text": "六年级"
},
{
"value": "07",
"text": "七年级"
},
{
"value": "08",
"text": "八年级"
},
{
"value": "09",
"text": "九年级"
},
{
"value": "10",
"text": "高一"
},
{
"value": "11",
"text": "高二"
},
{
"value": "12",
"text": "高三"
}
]
_constant语句
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (1, 'bookCover', 'array', '', '[{"text":"图标1 语文","value": "/bookCover/1684392567970_906812_图标语文.png"},
{"text":"图标2 数学","value": "/bookCover/1684392581983_621071_图标数学.png"}]', 'update', 'admin01', 'admin01', '2022-03-12T17:19:50+08:00');
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (59, 'userStatus', 'array', NULL, '[{"value": "active", "text": "正常"}, {"value": "banned", "text": "禁用"}]', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (60, 'userType', 'array', NULL, '[{"value": "common", "text": "普通用户"},{"value": "xiaochengxu", "text": "小程序机器人"}]', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (61, 'gender', 'array', NULL, '[{"value": "male", "text": "男"}, {"value": "female", "text": "女"}]', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (62, 'version', 'object', NULL, '{"testUserIdList": "","version": "4.3.11", "title": "4.3.7 版本发布", "note": "新版本介绍\n 1. 聊天输入优化", "apkVersion": "5.0.20", "apkLink": "https://duoxing.openjianghu.org/duoxing/upload/10002/1647840662817_956853_D多星MD-4.7.10.apk", "apkNote": "", "desktopVersion": "4.3.2", "desktopLink": "http://192.168.110.215:8082/duoxing/upload/duoxing-1.0.1.dmg.zip", "desktopNote": "测试桌面客户端升级" }', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (64, 'emotion', 'array', NULL, '[
{
"dir":"face01",
"cover":"face-lbl",
"ext":"png",
"cols":5,
"total":86
},
{
"dir":"face02",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face03",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face04",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face05",
"cover":"face-lbl",
"ext":"gif",
"cols":1,
"total":7
},
{
"dir":"face06",
"cover":"face-lbl",
"ext":"gif",
"cols":3,
"total":24
},
{
"dir":"face07",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face08",
"cover":"face-lbl",
"ext":"gif",
"cols":3,
"total":23
},
{
"dir":"face09",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face10",
"cover":"face-lbl",
"ext":"gif",
"cols":3,
"total":20
},
{
"dir":"face11",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":13
},
{
"dir":"face12",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
},
{
"dir":"face13",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":15
},
{
"dir":"face14",
"cover":"face-lbl",
"ext":"gif",
"cols":2,
"total":16
}
]
', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (65, 'appLinkActionConfig', 'array', NULL, '[{"regex":".openjianghu.org\/*", "action": "internal"}, {"regex":"http:\/\/192.168.\/*", "action": "internal"}]', 'insert', NULL, NULL, NULL);
INSERT INTO _constant (id, constantKey, constantType, desc, constantValue, operation, operationByUserId, operationByUser, operationAt) VALUES (66, 'level', 'array', '年级列表', '[{"value":"01","text":"一年级"},{"value": "02","text": "二年级"},{"value":"03","text":"三年级"},{"value": "04","text": "四年级"},{"value": "05","text": "五年级"},{"value": "06","text": "六年级"},{"value": "07","text": "七年级"},{"value": "08","text": "八年级"},{"value": "09","text": "九年级"},{"value": "10","text": "高一"},{"value": "11","text": "高二"},{"value": "12","text": "高三"}]', 'insert', NULL, NULL, NULL);