diff --git a/src/api/index.js b/src/api/index.js index b151e1ce5f1e0e250b9f69101064233161a0b542..c55eae1e8b92436d0fc84044bcbb898a4489f3e7 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -35,5 +35,5 @@ export const getStaticDataApi = async (data) => { }; export function getStaticDataByTwoParamsApi(paramModule, paramCode) { - return getStaticDataApi({ paramModule, paramCode }); + return () => getStaticDataApi({ paramModule, paramCode }); } diff --git a/src/components/MySelect/url_select.vue b/src/components/MySelect/url_select.vue index 35b180a27e37054a51f0fab01ed3dcbbc9e0605d..32fc5df7ab7724aa9acb2ba9b244abd0dc5f2c62 100644 --- a/src/components/MySelect/url_select.vue +++ b/src/components/MySelect/url_select.vue @@ -2,7 +2,7 @@
- +
@@ -21,7 +21,7 @@
- + {{ newBtn.text || '新增' }} @@ -104,6 +104,7 @@ export default { type: Object, default: () => ({}), }, + noMargin: Boolean, }, data() { @@ -164,6 +165,13 @@ export default { }, }; }, + tableCardStyle() { + return this.noMargin + ? { + paddingTop: 0, + } + : {}; + }, }, methods: { diff --git a/src/local/index.js b/src/local/index.js new file mode 100644 index 0000000000000000000000000000000000000000..2fd0f73bf1f0b1d80f70e74f9d848cdd277fad87 --- /dev/null +++ b/src/local/index.js @@ -0,0 +1,16 @@ +import selectLang from './select'; + +const zh_CN = {}; +const en_US = {}; + +function formatLang(langObject) { + for (const key in langObject) { + const element = langObject[key]; + zh_CN[key] = element[0]; + en_US[key] = element[1]; + } +} + +formatLang(selectLang); + +export { en_US, zh_CN }; diff --git a/src/local/select.js b/src/local/select.js new file mode 100644 index 0000000000000000000000000000000000000000..dfc7e71974123f3b7a90efc6d295b9e5c36ed35e --- /dev/null +++ b/src/local/select.js @@ -0,0 +1,4 @@ +// 0 中文, 1 英文 +export default { + 'select.placeholder': ['请选择', 'Please Select'], +}; diff --git a/src/main.js b/src/main.js index 012ef2ca30db8b94a3e2d2fac4a06ca40bd0e5eb..259ec2099b779db2c56d2eb79362d18fcec3ebb4 100644 --- a/src/main.js +++ b/src/main.js @@ -12,6 +12,7 @@ import { loadGuards, setAppOptions } from './utils/routerUtil'; import guards from './router/guards'; import { loadResponseInterceptor } from './utils/requestUtil'; import langUtils from '@/utils/langUtils'; +import { en_US, zh_CN } from '@/local'; import 'tailwindcss/tailwind.css'; import 'animate.css/source/animate.css'; @@ -43,6 +44,7 @@ const i18n = new VueI18n({ locale: localeLang, fallbackLocale: langUtils.fallbackLocale, silentFallbackWarn: true, + messages: { zh_CN, en_US }, }); //装载antd控件 @@ -67,5 +69,5 @@ new Vue({ router, store, i18n, - render: h => h(App), + render: (h) => h(App), }).$mount('#app'); diff --git a/src/pages/ranger/report/trend/index.vue b/src/pages/ranger/report/trend/index.vue new file mode 100644 index 0000000000000000000000000000000000000000..d85a57fc07ceaf9b4e403a91f9b53a0ad319af76 --- /dev/null +++ b/src/pages/ranger/report/trend/index.vue @@ -0,0 +1,65 @@ + + + + + diff --git a/src/pages/ranger/task_managment/center/detail.vue b/src/pages/ranger/task_managment/center/detail.vue index f8c2482cab1e701792b1ed3e6a99938e99e9e203..f66f7279a52aa31dcc69a737da352f12cf4aa92c 100644 --- a/src/pages/ranger/task_managment/center/detail.vue +++ b/src/pages/ranger/task_managment/center/detail.vue @@ -142,7 +142,7 @@ export default { title: '备注 & 附件', options: { fixed: 'right', - width: 150, + width: 100, }, data: [ { @@ -166,7 +166,6 @@ export default { }, methods: { viewDetail(row) { - console.log(row); this.$refs.table.show({ row, title: '备注 & 附件' }); }, }, diff --git a/src/router/config.js b/src/router/config.js index b21d25ea07a1e490fa662e54c27368bc8142aa0a..ec8fd77dc4ed90100e9d4749ab7c213dd0ad9efd 100644 --- a/src/router/config.js +++ b/src/router/config.js @@ -81,13 +81,11 @@ const hasAuthorityRoutes = [ component: () => import('@/pages/ranger/basic/unit'), }, { - path: 'major', name: '专业配置', component: () => import('@/pages/ranger/basic/major'), }, { - path: 'item', name: '项目配置', component: () => import('@/pages/ranger/basic/item'), @@ -121,6 +119,11 @@ const hasAuthorityRoutes = [ name: '报表中心', component: RouterView, children: [ + { + path: 'trend-analysis', + name: '趋势对比', + component: () => import('@/pages/ranger/report/trend/index.vue'), + }, { path: 'week', name: '巡检周报',