添加 dic 组件,select 和 value text
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
/* eslint-disable */
|
||||
import mockjs from 'mockjs';
|
||||
import { resultBody } from './mock-comment';
|
||||
import adminMenu from './geographic/admin-menu.json';
|
||||
import adminMenuAll from './geographic/admin-menu-all.json';
|
||||
import adminUrls from './geographic/admin-urls';
|
||||
@@ -25,9 +27,28 @@ function getQueryRole(req, res) {
|
||||
return res.json(roleQuery);
|
||||
}
|
||||
|
||||
function getDictionaryKeys(req, res) {
|
||||
const values = mockjs.mock({
|
||||
'list|5': [{ 'value|+1': 0, text: '@city' }],
|
||||
});
|
||||
|
||||
return res.json(resultBody(values));
|
||||
}
|
||||
|
||||
function getDictionaryText(req, res) {
|
||||
const values = mockjs.mock({
|
||||
text: '@city',
|
||||
});
|
||||
|
||||
return res.json(resultBody(values));
|
||||
}
|
||||
|
||||
export default {
|
||||
'GET /admin-api/admins/resource/admin_menu_tree': getAdminMenuAll,
|
||||
'GET /admin-api/admins/resource/admin_url_list': getAdminUrls,
|
||||
'GET /admin-api/admins/resource/tree': getResourceTree,
|
||||
'GET /admin-api/admins/role/page': getQueryRole,
|
||||
'GET /admin-api/admins/admin/page': getQueryRole,
|
||||
'GET /admin-api/admins/dictionary/getList': getDictionaryKeys,
|
||||
'GET /admin-api/admins/dictionary/queryText': getDictionaryText,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user