imatrix-ui 2.9.21-boe01-rc2 → 2.9.21-boe01-rc4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.cjs +45 -0
- package/lib/index.js +39 -0
- package/lib/src/README.md +46 -0
- package/lib/src/api/sso-service.js +118 -0
- package/lib/src/api/tab.js +30 -0
- package/lib/src/api/user-service.js +11 -0
- package/lib/src/assets/401/401.gif +0 -0
- package/lib/src/assets/404/404-cloud.png +0 -0
- package/lib/src/assets/404/404.png +0 -0
- package/lib/src/assets/cloud.png +0 -0
- package/lib/src/assets/nonemessage.png +0 -0
- package/lib/src/directives/permission/index.js +13 -0
- package/lib/src/directives/permission/permission.js +18 -0
- package/lib/src/i18n/i18n.js +19 -0
- package/lib/src/i18n/langs/cn.js +264 -0
- package/lib/src/i18n/langs/en.js +261 -0
- package/lib/src/permission.js +103 -0
- package/lib/src/router/index.js +120 -0
- package/lib/src/store/getters.js +15 -0
- package/lib/src/store/index.js +21 -0
- package/lib/src/store/modules/app.js +55 -0
- package/lib/src/store/modules/permission.js +124 -0
- package/lib/src/store/modules/tab-content.js +38 -0
- package/lib/src/store/modules/user.js +233 -0
- package/lib/src/styles/display-layout.scss +34 -0
- package/lib/src/styles/element-ui.scss +29 -0
- package/lib/src/styles/index.scss +157 -0
- package/lib/src/styles/mixin.scss +27 -0
- package/lib/src/styles/theme/black/font-style.scss +70 -0
- package/lib/src/styles/theme/black/index.scss +306 -0
- package/lib/src/styles/theme/black/sidebar.scss +189 -0
- package/lib/src/styles/theme/blue/font-style.scss +46 -0
- package/lib/src/styles/theme/blue/index.scss +172 -0
- package/lib/src/styles/theme/blue/sidebar.scss +171 -0
- package/lib/src/styles/theme/blue2/font-style.scss +70 -0
- package/lib/src/styles/theme/blue2/index.scss +188 -0
- package/lib/src/styles/theme/blue2/sidebar.scss +201 -0
- package/lib/src/styles/theme/dark-blue/button.scss +9 -0
- package/lib/src/styles/theme/dark-blue/card.scss +62 -0
- package/lib/src/styles/theme/dark-blue/checkbox.scss +10 -0
- package/lib/src/styles/theme/dark-blue/dark-blue-var.scss +8 -0
- package/lib/src/styles/theme/dark-blue/dialog.scss +21 -0
- package/lib/src/styles/theme/dark-blue/element-variables.scss +7 -0
- package/lib/src/styles/theme/dark-blue/font.scss +70 -0
- package/lib/src/styles/theme/dark-blue/form.scss +54 -0
- package/lib/src/styles/theme/dark-blue/index.scss +272 -0
- package/lib/src/styles/theme/dark-blue/input.scss +18 -0
- package/lib/src/styles/theme/dark-blue/message.scss +8 -0
- package/lib/src/styles/theme/dark-blue/pagination.scss +14 -0
- package/lib/src/styles/theme/dark-blue/radio.scss +13 -0
- package/lib/src/styles/theme/dark-blue/scrollbar-style.scss +37 -0
- package/lib/src/styles/theme/dark-blue/sidebar.scss +266 -0
- package/lib/src/styles/theme/dark-blue/tab.scss +86 -0
- package/lib/src/styles/theme/dark-blue/table.scss +60 -0
- package/lib/src/styles/theme/dark-blue/tree.scss +56 -0
- package/lib/src/styles/theme/dark-blue/var.scss +1028 -0
- package/lib/src/styles/theme/gray/card-style.scss +54 -0
- package/lib/src/styles/theme/gray/font-style.scss +70 -0
- package/lib/src/styles/theme/gray/index.scss +172 -0
- package/lib/src/styles/theme/gray/input-style.scss +19 -0
- package/lib/src/styles/theme/gray/scrollbar-style.scss +37 -0
- package/lib/src/styles/theme/gray/sidebar.scss +231 -0
- package/lib/src/styles/theme/gray/tab-style.scss +81 -0
- package/lib/src/styles/transition.scss +47 -0
- package/lib/src/utils/auth-api.js +161 -0
- package/lib/src/utils/auth.js +61 -0
- package/lib/src/utils/calculator/calculator-factory-wf.js +456 -0
- package/lib/src/utils/calculator/calculator-factory.js +125 -0
- package/lib/src/utils/calculator/calculator-util.js +144 -0
- package/lib/src/utils/common-util.js +266 -0
- package/lib/src/utils/eventBus.js +2 -0
- package/lib/src/utils/iconUtils.js +23 -0
- package/lib/src/utils/index.js +100 -0
- package/lib/src/utils/jump-page-utils.js +540 -0
- package/lib/src/utils/local-storage.js +31 -0
- package/lib/src/utils/menu.js +19 -0
- package/lib/src/utils/permission.js +30 -0
- package/lib/src/utils/permissionAuth.js +84 -0
- package/lib/src/utils/preview-util.js +33 -0
- package/lib/src/utils/range-selector.js +185 -0
- package/lib/src/utils/request.js +299 -0
- package/lib/src/utils/restful-interface-utils.js +47 -0
- package/lib/src/utils/util.js +571 -0
- package/lib/src/utils/validate.js +33 -0
- package/lib/src/utils/watermark.js +95 -0
- package/lib/src/utils/workflow-util.js +78 -0
- package/lib/src/views/404.vue +239 -0
- package/lib/src/views/dsc-component/Sidebar/Item.vue +65 -0
- package/lib/src/views/dsc-component/Sidebar/Link.vue +40 -0
- package/lib/src/views/dsc-component/Sidebar/SidebarItem.vue +168 -0
- package/lib/src/views/dsc-component/Sidebar/index.vue +184 -0
- package/lib/src/views/dsc-component/tabs/tab-content.vue +159 -0
- package/lib/src/views/error-page/401.vue +107 -0
- package/lib/src/views/error-page/404.vue +239 -0
- package/lib/src/views/layout/EmptyLayout.vue +7 -0
- package/lib/src/views/layout/Layout.vue +77 -0
- package/lib/src/views/layout/NewLayout.vue +18 -0
- package/lib/src/views/layout/components/AppMain.vue +38 -0
- package/lib/src/views/layout/components/Breadcrumb/index.vue +139 -0
- package/lib/src/views/layout/components/Menubar/Item.vue +62 -0
- package/lib/src/views/layout/components/Menubar/Link.vue +40 -0
- package/lib/src/views/layout/components/Menubar/SidebarItem.vue +144 -0
- package/lib/src/views/layout/components/Menubar/index.vue +180 -0
- package/lib/src/views/layout/components/Sidebar/Item.vue +50 -0
- package/lib/src/views/layout/components/Sidebar/Link.vue +39 -0
- package/lib/src/views/layout/components/Sidebar/SidebarItem.vue +107 -0
- package/lib/src/views/layout/components/Sidebar/index.vue +117 -0
- package/lib/src/views/layout/components/iframe-page.vue +31 -0
- package/lib/src/views/layout/components/index.js +4 -0
- package/lib/src/views/layout/components/tabs/tab-content.vue +162 -0
- package/lib/src/views/layout/mixin/ResizeHandler.js +41 -0
- package/lib/src/views/layout/tab-content-iframe-index.vue +31 -0
- package/lib/src/views/layout/tab-content-index.vue +84 -0
- package/lib/src/views/login/authredirect.vue +10 -0
- package/lib/src/views/login/index.vue +258 -0
- package/lib/src/views/login/update-password.vue +195 -0
- package/lib/src/views/redirect/index.vue +12 -0
- package/lib/src/views/wf-history/tache-subprocess-history.vue +45 -0
- package/package.json +7 -4
- package/src/api/sso-service.js +118 -0
- package/src/api/tab.js +30 -0
- package/src/api/user-service.js +11 -0
- package/src/assets/401/401.gif +0 -0
- package/src/assets/404/404-cloud.png +0 -0
- package/src/assets/404/404.png +0 -0
- package/src/assets/cloud.png +0 -0
- package/src/assets/nonemessage.png +0 -0
- package/src/directives/permission/index.js +13 -0
- package/src/directives/permission/permission.js +18 -0
- package/src/i18n/i18n.js +19 -0
- package/src/i18n/langs/cn.js +264 -0
- package/src/i18n/langs/en.js +261 -0
- package/src/permission.js +103 -0
- package/src/plugins.js +25 -0
- package/src/router/index.js +120 -0
- package/src/store/getters.js +15 -0
- package/src/store/index.js +21 -0
- package/src/store/modules/app.js +55 -0
- package/src/store/modules/permission.js +124 -0
- package/src/store/modules/tab-content.js +38 -0
- package/src/store/modules/user.js +233 -0
- package/src/styles/display-layout.scss +34 -0
- package/src/styles/element-ui.scss +29 -0
- package/src/styles/index.scss +157 -0
- package/src/styles/mixin.scss +27 -0
- package/src/styles/theme/black/font-style.scss +70 -0
- package/src/styles/theme/black/index.scss +306 -0
- package/src/styles/theme/black/sidebar.scss +189 -0
- package/src/styles/theme/blue/font-style.scss +46 -0
- package/src/styles/theme/blue/index.scss +172 -0
- package/src/styles/theme/blue/sidebar.scss +171 -0
- package/src/styles/theme/blue2/font-style.scss +70 -0
- package/src/styles/theme/blue2/index.scss +188 -0
- package/src/styles/theme/blue2/sidebar.scss +201 -0
- package/src/styles/theme/dark-blue/button.scss +9 -0
- package/src/styles/theme/dark-blue/card.scss +62 -0
- package/src/styles/theme/dark-blue/checkbox.scss +10 -0
- package/src/styles/theme/dark-blue/dark-blue-var.scss +8 -0
- package/src/styles/theme/dark-blue/dialog.scss +21 -0
- package/src/styles/theme/dark-blue/element-variables.scss +7 -0
- package/src/styles/theme/dark-blue/font.scss +70 -0
- package/src/styles/theme/dark-blue/form.scss +54 -0
- package/src/styles/theme/dark-blue/index.scss +272 -0
- package/src/styles/theme/dark-blue/input.scss +18 -0
- package/src/styles/theme/dark-blue/message.scss +8 -0
- package/src/styles/theme/dark-blue/pagination.scss +14 -0
- package/src/styles/theme/dark-blue/radio.scss +13 -0
- package/src/styles/theme/dark-blue/scrollbar-style.scss +37 -0
- package/src/styles/theme/dark-blue/sidebar.scss +266 -0
- package/src/styles/theme/dark-blue/tab.scss +86 -0
- package/src/styles/theme/dark-blue/table.scss +60 -0
- package/src/styles/theme/dark-blue/tree.scss +56 -0
- package/src/styles/theme/dark-blue/var.scss +1028 -0
- package/src/styles/theme/gray/card-style.scss +54 -0
- package/src/styles/theme/gray/font-style.scss +70 -0
- package/src/styles/theme/gray/index.scss +172 -0
- package/src/styles/theme/gray/input-style.scss +19 -0
- package/src/styles/theme/gray/scrollbar-style.scss +37 -0
- package/src/styles/theme/gray/sidebar.scss +231 -0
- package/src/styles/theme/gray/tab-style.scss +81 -0
- package/src/styles/transition.scss +47 -0
- package/src/utils/auth-api.js +161 -0
- package/src/utils/auth.js +61 -0
- package/src/utils/calculator/calculator-factory-wf.js +456 -0
- package/src/utils/calculator/calculator-factory.js +125 -0
- package/src/utils/calculator/calculator-util.js +144 -0
- package/src/utils/common-util.js +266 -0
- package/src/utils/eventBus.js +2 -0
- package/src/utils/iconUtils.js +23 -0
- package/src/utils/index.js +100 -0
- package/src/utils/jump-page-utils.js +540 -0
- package/src/utils/local-storage.js +31 -0
- package/src/utils/menu.js +19 -0
- package/src/utils/permission.js +30 -0
- package/src/utils/permissionAuth.js +84 -0
- package/src/utils/preview-util.js +33 -0
- package/src/utils/range-selector.js +185 -0
- package/src/utils/request.js +299 -0
- package/src/utils/restful-interface-utils.js +47 -0
- package/src/utils/util.js +571 -0
- package/src/utils/validate.js +33 -0
- package/src/utils/watermark.js +95 -0
- package/src/utils/workflow-util.js +78 -0
- package/src/views/404.vue +239 -0
- package/src/views/dsc-component/Sidebar/Item.vue +65 -0
- package/src/views/dsc-component/Sidebar/Link.vue +40 -0
- package/src/views/dsc-component/Sidebar/SidebarItem.vue +168 -0
- package/src/views/dsc-component/Sidebar/index.vue +184 -0
- package/src/views/dsc-component/tabs/tab-content.vue +159 -0
- package/src/views/error-page/401.vue +107 -0
- package/src/views/error-page/404.vue +239 -0
- package/src/views/layout/EmptyLayout.vue +7 -0
- package/src/views/layout/Layout.vue +77 -0
- package/src/views/layout/NewLayout.vue +18 -0
- package/src/views/layout/components/AppMain.vue +38 -0
- package/src/views/layout/components/Breadcrumb/index.vue +139 -0
- package/src/views/layout/components/Menubar/Item.vue +62 -0
- package/src/views/layout/components/Menubar/Link.vue +40 -0
- package/src/views/layout/components/Menubar/SidebarItem.vue +144 -0
- package/src/views/layout/components/Menubar/index.vue +180 -0
- package/src/views/layout/components/Sidebar/Item.vue +50 -0
- package/src/views/layout/components/Sidebar/Link.vue +39 -0
- package/src/views/layout/components/Sidebar/SidebarItem.vue +107 -0
- package/src/views/layout/components/Sidebar/index.vue +117 -0
- package/src/views/layout/components/iframe-page.vue +31 -0
- package/src/views/layout/components/index.js +4 -0
- package/src/views/layout/components/tabs/tab-content.vue +162 -0
- package/src/views/layout/mixin/ResizeHandler.js +41 -0
- package/src/views/layout/tab-content-iframe-index.vue +31 -0
- package/src/views/layout/tab-content-index.vue +84 -0
- package/src/views/login/authredirect.vue +10 -0
- package/src/views/login/index.vue +258 -0
- package/src/views/login/update-password.vue +195 -0
- package/src/views/redirect/index.vue +12 -0
- package/src/views/wf-history/tache-subprocess-history.vue +45 -0
package/lib/index.cjs
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
// iMatrix-UI 组件库入口文件 (CommonJS)
|
|
2
|
+
// 优先推荐直接使用组件文件路径引入,避免加载大包
|
|
3
|
+
|
|
4
|
+
// 全量引入对象(延迟加载)
|
|
5
|
+
const FullLibrary = {
|
|
6
|
+
install(Vue, opts = {}) {
|
|
7
|
+
// 只有在真正使用 Vue.use() 时才加载全量包
|
|
8
|
+
try {
|
|
9
|
+
const SuperUI = require('./super-ui.umd.min.js')
|
|
10
|
+
if (SuperUI && SuperUI.default && SuperUI.default.install) {
|
|
11
|
+
SuperUI.default.install(Vue, opts)
|
|
12
|
+
} else if (SuperUI && SuperUI.install) {
|
|
13
|
+
SuperUI.install(Vue, opts)
|
|
14
|
+
} else {
|
|
15
|
+
console.warn('iMatrix-UI: 无法找到安装方法,请检查super-ui.umd.min.js文件')
|
|
16
|
+
}
|
|
17
|
+
} catch (error) {
|
|
18
|
+
console.error('iMatrix-UI: 加载全量包失败', error.message)
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
// 尝试导出按需引入的组件
|
|
24
|
+
try {
|
|
25
|
+
const components = require('./components.js')
|
|
26
|
+
if (components) {
|
|
27
|
+
Object.assign(module.exports, components)
|
|
28
|
+
}
|
|
29
|
+
} catch (e) {
|
|
30
|
+
// components.js 可能是ES模块格式,提供备用方案
|
|
31
|
+
console.warn('iMatrix-UI: 无法加载components.js,请直接使用组件路径引入')
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
// 默认导出
|
|
35
|
+
module.exports = FullLibrary
|
|
36
|
+
module.exports.default = FullLibrary
|
|
37
|
+
|
|
38
|
+
// 添加版本信息
|
|
39
|
+
try {
|
|
40
|
+
const pkg = require('../package.json')
|
|
41
|
+
module.exports.version = pkg.version
|
|
42
|
+
} catch (e) {
|
|
43
|
+
// 忽略版本信息获取失败
|
|
44
|
+
}
|
|
45
|
+
module.exports.description = '推荐使用: require("imatrix-ui/lib/组件名/组件名.umd.min.js") 来按需引入组件'
|
package/lib/index.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
// iMatrix-UI 组件库入口文件 (ES Module)
|
|
2
|
+
// 按需引入优先,全量引入按需加载
|
|
3
|
+
|
|
4
|
+
// 导出所有组件供按需引入
|
|
5
|
+
export * from './components.js'
|
|
6
|
+
|
|
7
|
+
// 全量引入对象(延迟加载)
|
|
8
|
+
const FullLibrary = {
|
|
9
|
+
install(Vue, opts = {}) {
|
|
10
|
+
// 只有在真正使用 Vue.use() 时才动态加载全量包
|
|
11
|
+
const loadFullLibrary = async () => {
|
|
12
|
+
try {
|
|
13
|
+
const SuperUI = await import('./super-ui.umd.min.js')
|
|
14
|
+
if (SuperUI && SuperUI.default && SuperUI.default.install) {
|
|
15
|
+
SuperUI.default.install(Vue, opts)
|
|
16
|
+
} else if (SuperUI && SuperUI.install) {
|
|
17
|
+
SuperUI.install(Vue, opts)
|
|
18
|
+
}
|
|
19
|
+
} catch (error) {
|
|
20
|
+
// 降级到同步加载
|
|
21
|
+
try {
|
|
22
|
+
const SuperUI = require('./super-ui.umd.min.js')
|
|
23
|
+
if (SuperUI && SuperUI.default && SuperUI.default.install) {
|
|
24
|
+
SuperUI.default.install(Vue, opts)
|
|
25
|
+
} else if (SuperUI && SuperUI.install) {
|
|
26
|
+
SuperUI.install(Vue, opts)
|
|
27
|
+
}
|
|
28
|
+
} catch (syncError) {
|
|
29
|
+
console.error('iMatrix-UI: 无法加载全量包', syncError)
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
loadFullLibrary()
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// 默认导出全量安装器
|
|
39
|
+
export default FullLibrary
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# iMatrix-UI src 目录
|
|
2
|
+
|
|
3
|
+
这个目录包含了 iMatrix-UI 的源码文件,支持直接引入使用。
|
|
4
|
+
|
|
5
|
+
## 🎨 样式文件
|
|
6
|
+
|
|
7
|
+
```scss
|
|
8
|
+
// 引入完整样式
|
|
9
|
+
import 'imatrix-ui/src/styles/index.scss'
|
|
10
|
+
|
|
11
|
+
// 引入特定样式
|
|
12
|
+
import 'imatrix-ui/src/styles/mixin.scss'
|
|
13
|
+
import 'imatrix-ui/src/styles/element-ui.scss'
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## 🔧 工具函数
|
|
17
|
+
|
|
18
|
+
```javascript
|
|
19
|
+
// 引入工具函数
|
|
20
|
+
import { parseTime, formatTime } from 'imatrix-ui/src/utils/index.js'
|
|
21
|
+
import { openPage } from 'imatrix-ui/src/utils/jump-page-utils.js'
|
|
22
|
+
|
|
23
|
+
// 引入通用工具
|
|
24
|
+
import * as commonUtil from 'imatrix-ui/src/utils/common-util.js'
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## 📁 目录结构
|
|
28
|
+
|
|
29
|
+
- `styles/` - 样式文件(SCSS)
|
|
30
|
+
- `utils/` - 工具函数
|
|
31
|
+
- `directives/` - Vue指令
|
|
32
|
+
- `api/` - API相关
|
|
33
|
+
- `i18n/` - 国际化文件
|
|
34
|
+
- `assets/` - 静态资源
|
|
35
|
+
|
|
36
|
+
## 💡 使用建议
|
|
37
|
+
|
|
38
|
+
1. **样式引入**:推荐在项目入口处引入样式文件
|
|
39
|
+
2. **工具函数**:按需引入需要的工具函数
|
|
40
|
+
3. **主题定制**:可以引入特定主题的样式文件
|
|
41
|
+
|
|
42
|
+
## ⚠️ 注意事项
|
|
43
|
+
|
|
44
|
+
- 直接引用src文件需要确保您的构建工具支持相应的文件类型
|
|
45
|
+
- SCSS文件需要在您的项目中配置SASS/SCSS编译器
|
|
46
|
+
- 某些工具函数可能依赖特定的第三方库
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import request from '../utils/request'
|
|
2
|
+
import Vue from 'vue'
|
|
3
|
+
function login(username, password, language) {
|
|
4
|
+
const usernamePasswordToken = {
|
|
5
|
+
username,
|
|
6
|
+
password
|
|
7
|
+
}
|
|
8
|
+
if (language) {
|
|
9
|
+
usernamePasswordToken.language = language
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
return request.post(Vue.prototype.baseAPI + '/sso/login', usernamePasswordToken)
|
|
13
|
+
}
|
|
14
|
+
function loginWithValidateCode(username, password, language, validateCode, imageCodeKey) {
|
|
15
|
+
const usernamePasswordToken = {
|
|
16
|
+
username,
|
|
17
|
+
password
|
|
18
|
+
}
|
|
19
|
+
if (language) {
|
|
20
|
+
usernamePasswordToken.language = language
|
|
21
|
+
}
|
|
22
|
+
if (validateCode) {
|
|
23
|
+
usernamePasswordToken.validateCode = validateCode
|
|
24
|
+
}
|
|
25
|
+
if (imageCodeKey) {
|
|
26
|
+
usernamePasswordToken.imageCodeKey = imageCodeKey
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
return request.post(Vue.prototype.baseAPI + '/sso/login-with-validate-code', usernamePasswordToken)
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
function getCurrentUser() {
|
|
33
|
+
return request.get(
|
|
34
|
+
Vue.prototype.baseAPI + '/sso/current-user?_t=' + new Date().getTime()
|
|
35
|
+
)
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
function logout() {
|
|
39
|
+
return request.get(Vue.prototype.baseAPI + '/sso/logout?_t=' + new Date().getTime())
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
function getCurrentUserPermissionsBySystem(loginName, systemCode) {
|
|
43
|
+
if (!systemCode) {
|
|
44
|
+
if (Vue.prototype.customSystem) {
|
|
45
|
+
systemCode = Vue.prototype.customSystem
|
|
46
|
+
} else {
|
|
47
|
+
systemCode = Vue.prototype.systemCode
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
return request.get(Vue.prototype.baseAPI + '/sso/current-users/permissions/with-system?loginName=' + encodeURI(loginName) + '&systemCode=' + systemCode + '&_t=' + new Date().getTime())
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
function isPasswordExpired(username, password) {
|
|
54
|
+
const usernamePasswordToken = {
|
|
55
|
+
username,
|
|
56
|
+
password
|
|
57
|
+
}
|
|
58
|
+
return request.post(Vue.prototype.baseAPI + '/sso/is-password-expired', usernamePasswordToken)
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/** 更新密码 */
|
|
62
|
+
function updatePassword(data) {
|
|
63
|
+
return request.put(Vue.prototype.baseAPI + '/acs/users/password', data)
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
function getUserLanguage() {
|
|
67
|
+
return request.get(Vue.prototype.baseAPI + '/acs/user-languages')
|
|
68
|
+
}
|
|
69
|
+
function forgetPasswordSendMail(username, email) {
|
|
70
|
+
const userInfo = {
|
|
71
|
+
username,
|
|
72
|
+
email
|
|
73
|
+
}
|
|
74
|
+
return request.post(Vue.prototype.baseAPI + '/sso/forget-passwords/send-mails', userInfo)
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
function isResetPasswordJwtOverdue(jwt) {
|
|
78
|
+
const userInfo = {
|
|
79
|
+
jwt
|
|
80
|
+
}
|
|
81
|
+
return request.post(Vue.prototype.baseAPI + '/sso/forget-passwords/jwt-overdue', userInfo)
|
|
82
|
+
}
|
|
83
|
+
function resetPassword(username, password) {
|
|
84
|
+
const userInfo = {
|
|
85
|
+
username,
|
|
86
|
+
password
|
|
87
|
+
}
|
|
88
|
+
return request.post(Vue.prototype.baseAPI + '/sso/forget-passwords/reset', userInfo)
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
function isLoginTimeOut() {
|
|
92
|
+
return request.get(Vue.prototype.baseAPI + '/sso/current-users/is-login-time-out')
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
function getUserPermissionMenusBySystemCode(systemCode) {
|
|
96
|
+
if (!systemCode) {
|
|
97
|
+
systemCode = Vue.prototype.currentSystem
|
|
98
|
+
}
|
|
99
|
+
if (!systemCode) {
|
|
100
|
+
systemCode = Vue.prototype.systemCode
|
|
101
|
+
}
|
|
102
|
+
return request.get(Vue.prototype.baseAPI + '/component/permission-menus/systems/' + systemCode)
|
|
103
|
+
}
|
|
104
|
+
export default {
|
|
105
|
+
login,
|
|
106
|
+
getCurrentUser,
|
|
107
|
+
logout,
|
|
108
|
+
isPasswordExpired,
|
|
109
|
+
updatePassword,
|
|
110
|
+
getCurrentUserPermissionsBySystem,
|
|
111
|
+
getUserLanguage,
|
|
112
|
+
forgetPasswordSendMail,
|
|
113
|
+
isResetPasswordJwtOverdue,
|
|
114
|
+
resetPassword,
|
|
115
|
+
isLoginTimeOut,
|
|
116
|
+
getUserPermissionMenusBySystemCode,
|
|
117
|
+
loginWithValidateCode
|
|
118
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
const tabJs = {
|
|
2
|
+
addTabs(query, openTab, path, fullpath) {
|
|
3
|
+
let flag = false
|
|
4
|
+
let menuCode
|
|
5
|
+
let menuName
|
|
6
|
+
if (query) {
|
|
7
|
+
menuCode = query._menuCode
|
|
8
|
+
menuName = query._menuName
|
|
9
|
+
}
|
|
10
|
+
if (openTab && menuCode) {
|
|
11
|
+
for (let i = 0; i < openTab.length; i++) {
|
|
12
|
+
const item = openTab[i]
|
|
13
|
+
console.log('item.name', item.name)
|
|
14
|
+
|
|
15
|
+
if (menuCode && item.code === menuCode) {
|
|
16
|
+
console.log('to.path--menuCode1=', menuCode)
|
|
17
|
+
this.$store.commit('set_active_index', menuCode)
|
|
18
|
+
flag = true
|
|
19
|
+
break
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
if (!flag && menuCode) {
|
|
24
|
+
console.log('to.path--menuCode2=', menuCode)
|
|
25
|
+
this.$store.commit('add_tabs', { code: menuCode, name: menuName, routePath: path, routeQuery: query, fullpath: fullpath })
|
|
26
|
+
this.$store.commit('set_active_index', menuCode)
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
export default tabJs
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import permission from './permission'
|
|
2
|
+
|
|
3
|
+
const install = function(Vue) {
|
|
4
|
+
Vue.directive('permission', permission)
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
if (window.Vue) {
|
|
8
|
+
window['permission'] = permission
|
|
9
|
+
Vue.use(install); // eslint-disable-line
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
permission.install = install
|
|
13
|
+
export default permission
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import checkPermission from '../../utils/permission'
|
|
2
|
+
export default {
|
|
3
|
+
inserted(el, binding, vnode) {
|
|
4
|
+
const { value } = binding
|
|
5
|
+
// const currentUserPermissions = store.getters && store.getters.currentUserPermissions
|
|
6
|
+
|
|
7
|
+
if (value) {
|
|
8
|
+
// console.log('-----v-permission---init----')
|
|
9
|
+
// 页面组件预览时不需要权限控制,系统中使用页面组件时需要使用权限控制,所以当是预览是资源编码传'true'
|
|
10
|
+
// 工作流按钮组件中也使用了资源编码为'true'的情况
|
|
11
|
+
if (value !== 'true' && !checkPermission(value)) {
|
|
12
|
+
el.parentNode && el.parentNode.removeChild(el)
|
|
13
|
+
}
|
|
14
|
+
} else {
|
|
15
|
+
throw new Error(`need permission1! Like v-permission="acs.department.save"`)
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import Vue from 'vue'
|
|
2
|
+
import locale from 'element-ui/lib/locale'
|
|
3
|
+
import VueI18n from 'vue-i18n'
|
|
4
|
+
import en from './langs/en'
|
|
5
|
+
import cn from './langs/cn'
|
|
6
|
+
Vue.use(VueI18n)
|
|
7
|
+
|
|
8
|
+
const messages = {
|
|
9
|
+
en: en,
|
|
10
|
+
cn: cn
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
const i18n = new VueI18n({
|
|
14
|
+
locale: 'cn', // 设置默认语言
|
|
15
|
+
messages
|
|
16
|
+
})
|
|
17
|
+
locale.i18n((key, value) => i18n.t(key, value)) // 为了实现element插件的多语言切换
|
|
18
|
+
|
|
19
|
+
export default i18n
|
|
@@ -0,0 +1,264 @@
|
|
|
1
|
+
import zhLocale from 'element-ui/lib/locale/lang/zh-CN'
|
|
2
|
+
const cn = {
|
|
3
|
+
imatrixUIPublicModel: {
|
|
4
|
+
sure: '确定',
|
|
5
|
+
cancel: '取消',
|
|
6
|
+
allDepartments: '所有部门',
|
|
7
|
+
allUsers: '所有用户',
|
|
8
|
+
reset: '重置',
|
|
9
|
+
to: '至',
|
|
10
|
+
edit: '操作',
|
|
11
|
+
clear: '清空',
|
|
12
|
+
download: '下载',
|
|
13
|
+
delete: '删除',
|
|
14
|
+
preview: '预览',
|
|
15
|
+
add: '增加',
|
|
16
|
+
graphView: '图形视图',
|
|
17
|
+
listView: '列表视图',
|
|
18
|
+
fieldName: '字段名(*)',
|
|
19
|
+
operator: '操作符',
|
|
20
|
+
value: '值(*)',
|
|
21
|
+
andOr: '并且/或者',
|
|
22
|
+
whenTheVariableIsEmpty: '变量为空时',
|
|
23
|
+
perhaps: '或者',
|
|
24
|
+
also: '并且',
|
|
25
|
+
greaterThan: '大于',
|
|
26
|
+
lessThan: '小于',
|
|
27
|
+
beEqualTo: '等于',
|
|
28
|
+
notGreaterThan: '不大于',
|
|
29
|
+
notLessThan: '不小于',
|
|
30
|
+
notEqualTo: '不等于',
|
|
31
|
+
contain: '包含',
|
|
32
|
+
notIncluded: '不包含',
|
|
33
|
+
laterThan: '晚于',
|
|
34
|
+
earlierThan: '早于',
|
|
35
|
+
noLaterThan: '不晚于',
|
|
36
|
+
noEarlierThan: '不早于',
|
|
37
|
+
ignore11: '忽略(1=1)',
|
|
38
|
+
nonConformity: '不符合(1<>1)',
|
|
39
|
+
switchToNormalQuery: '切换为普通查询',
|
|
40
|
+
switchToAdvancedQuery: '切换为高级查询',
|
|
41
|
+
isNull: '等于Null',
|
|
42
|
+
isNotNull: '不等于Null',
|
|
43
|
+
previewImage: '预览图片',
|
|
44
|
+
fullScreen: '全屏'
|
|
45
|
+
},
|
|
46
|
+
imatrixUIMessage: {
|
|
47
|
+
whetherToConfirmDeletion: '是否确认删除',
|
|
48
|
+
tips: '提示',
|
|
49
|
+
pleaseEnterContent: '请输入内容',
|
|
50
|
+
internalServerError: '请求失败',
|
|
51
|
+
pleaseSelectDepartment: '请选择部门',
|
|
52
|
+
pleaseSelectPersonnel: '请选择人员',
|
|
53
|
+
pleaseRemoveallpersonnelBeforeSelectingSpecificPersonnel: '请先移除所有人员,再选择具体人员',
|
|
54
|
+
queryResultIsEmpty: '查询结果为空',
|
|
55
|
+
pleaseSelectATeam: '请选择工作组',
|
|
56
|
+
pleaseEnterTeamName: '请输入工作组名称',
|
|
57
|
+
validationFailed: '验证失败',
|
|
58
|
+
selectionDate: '选择日期',
|
|
59
|
+
selectTime: '选择时间',
|
|
60
|
+
pleaseEnterATimePoint: '请输入时间点',
|
|
61
|
+
pleaseSelect: '请选择',
|
|
62
|
+
startDate: '开始日期',
|
|
63
|
+
endDate: '结束日期',
|
|
64
|
+
noExportColumnsConfigured: '没有配置导出列',
|
|
65
|
+
organizationTreeNoResultNotRemove: '未选择任何信息,无需移除',
|
|
66
|
+
exceedFileSize: '超过文件大小限制{fileSize}M',
|
|
67
|
+
upload: '上传',
|
|
68
|
+
invalideDoubleValue: '{num} 不是合法的小数',
|
|
69
|
+
noJumpPage: '未配置跳转页面',
|
|
70
|
+
saveSuccessfully: '保存成功',
|
|
71
|
+
pleaseInputSearchCondition: '请输入查询条件',
|
|
72
|
+
fileUpload: '文件上传',
|
|
73
|
+
selectYear: '选择年份',
|
|
74
|
+
selectMounth: '选择月份',
|
|
75
|
+
search: '查询',
|
|
76
|
+
forbiddenException: '您没有权限访问该资源',
|
|
77
|
+
theButtonIsNotBoundToAResource: '该按钮未绑定资源,请先绑定资源',
|
|
78
|
+
asyncExport: '正在异步导出,请等待消息通知!',
|
|
79
|
+
NoContent: '暂无内容'
|
|
80
|
+
},
|
|
81
|
+
// 列表组件
|
|
82
|
+
superGrid: {
|
|
83
|
+
columnConfig: '字段配置',
|
|
84
|
+
pleaseSaveOrCancelEditingLine: '请先保存或撤销编辑第 {row} 行数据',
|
|
85
|
+
pleaseSaveLine: '请先保存第 {row} 行数据',
|
|
86
|
+
noNeedToSaveRow: '无需保存第 {row} 行数据',
|
|
87
|
+
pleaseSetURLToSaveRowInformation: '请设置“保存行信息的url”',
|
|
88
|
+
lineSavedSuccessfully: '第 {row} 行保存成功',
|
|
89
|
+
theReturnValueOfTheBeforesaveCallbackMethodIsFalse: 'beforeSave回调方法返回值为false',
|
|
90
|
+
lineNoNeedToUndoEdit: '第 {row} 行无需撤销编辑',
|
|
91
|
+
lineCancelledSuccessfully: '第 {row} 行撤销成功',
|
|
92
|
+
label: '字段名',
|
|
93
|
+
isShow: '是否显示',
|
|
94
|
+
isExportable: '是否导出',
|
|
95
|
+
recordLine: '第 {row} 行记录',
|
|
96
|
+
pageRecordLine: '第 {pageNum} 页第 {row} 行记录',
|
|
97
|
+
fileName: '文件名称',
|
|
98
|
+
deleteSuccessful: '删除成功',
|
|
99
|
+
index: '序号',
|
|
100
|
+
searchConditionName: '查询条件名称',
|
|
101
|
+
pleaseInputSearchConditionName: '请输入查询条件名称',
|
|
102
|
+
saveCondition: '保存条件',
|
|
103
|
+
saveConditionTitle: '保存查询条件',
|
|
104
|
+
displayOrder: '显示顺序',
|
|
105
|
+
width: '列宽',
|
|
106
|
+
default: '默认',
|
|
107
|
+
custom: '自定义',
|
|
108
|
+
show: '显示',
|
|
109
|
+
hidden: '隐藏',
|
|
110
|
+
export: '导出',
|
|
111
|
+
unExport: '不导出',
|
|
112
|
+
whetherToConfirmReset: '是否确认重置?',
|
|
113
|
+
resetSuccessful: '重置成功',
|
|
114
|
+
dragColumnOrderMessage: '支持拖动改变列顺序',
|
|
115
|
+
selectAll: '全选',
|
|
116
|
+
viewImage: '查看图片',
|
|
117
|
+
previewTitleWhenNotImg: '非图片格式,使用其它方式预览',
|
|
118
|
+
refresh: '刷新',
|
|
119
|
+
open: '展开',
|
|
120
|
+
fold: '收起'
|
|
121
|
+
},
|
|
122
|
+
// 部门树组件
|
|
123
|
+
departmentTree: {
|
|
124
|
+
|
|
125
|
+
},
|
|
126
|
+
// 嵌入部门树组件
|
|
127
|
+
departmentTreeInline: {
|
|
128
|
+
pleaseEnterDepartmentName: '请输入部门名称',
|
|
129
|
+
name: '部门名称',
|
|
130
|
+
code: '部门编码',
|
|
131
|
+
removeDepartment: '移除部门',
|
|
132
|
+
selectedDept: '已选部门',
|
|
133
|
+
namePath: '名称路径'
|
|
134
|
+
},
|
|
135
|
+
// 用户树
|
|
136
|
+
departmentUserTree: {
|
|
137
|
+
pleaseEnterUserInformation: '请输入用户信息',
|
|
138
|
+
selectedPeople: '已选人员',
|
|
139
|
+
searchFieldUserName: '姓名',
|
|
140
|
+
searchFieldLoginName: '登录名',
|
|
141
|
+
searchFieldEmail: '邮箱',
|
|
142
|
+
searchFieldTelephone: '手机号',
|
|
143
|
+
searchFieldJobNumber: '工号',
|
|
144
|
+
searchFieldHonorificName: '尊称'
|
|
145
|
+
},
|
|
146
|
+
// 嵌入用户树
|
|
147
|
+
departmentUserTreeInline: {
|
|
148
|
+
name: '姓名',
|
|
149
|
+
department: '所属部门',
|
|
150
|
+
branch: '所属分支',
|
|
151
|
+
removeUser: '移除用户',
|
|
152
|
+
email: '邮箱',
|
|
153
|
+
loginName: '登录名',
|
|
154
|
+
superiorDeptNameFullPath: '组织全路径',
|
|
155
|
+
groupName: '名称',
|
|
156
|
+
groupForm: '群组表单',
|
|
157
|
+
groupList: '群组维护',
|
|
158
|
+
group: '群组',
|
|
159
|
+
orgTree: '组织树',
|
|
160
|
+
groupNameNotEmpty: '群组名称必填'
|
|
161
|
+
},
|
|
162
|
+
// 工作组树
|
|
163
|
+
workgroupTree: {
|
|
164
|
+
allTeamMembers: '所有工作组人员',
|
|
165
|
+
name: '工作组名称',
|
|
166
|
+
code: '工作组编码',
|
|
167
|
+
removeWorkgroup: '移除工作组'
|
|
168
|
+
},
|
|
169
|
+
// 流程按钮组件。save、submit等属性名不能随便改,和后台的ButtonType枚举名保持一致
|
|
170
|
+
workflowButton: {
|
|
171
|
+
save: '暂存',
|
|
172
|
+
submit: '提交',
|
|
173
|
+
approve: '同意',
|
|
174
|
+
refuse: '不同意',
|
|
175
|
+
agreement: '赞成',
|
|
176
|
+
oppose: '反对',
|
|
177
|
+
kiken: '弃权',
|
|
178
|
+
get_back_button: '取回',
|
|
179
|
+
copy: '抄送',
|
|
180
|
+
draw: '领取',
|
|
181
|
+
abandon_draw: '放弃领取',
|
|
182
|
+
add_sign: '加签',
|
|
183
|
+
remove_sign: '减签',
|
|
184
|
+
signoff: '签收',
|
|
185
|
+
assign: '交办',
|
|
186
|
+
assign_task: '转办',
|
|
187
|
+
readed: '已阅',
|
|
188
|
+
export_report: '导出报告',
|
|
189
|
+
draw_dept_task: '部门领取',
|
|
190
|
+
abandon_draw_dept_task: '放弃部门领取'
|
|
191
|
+
},
|
|
192
|
+
// 流转历史文本组件
|
|
193
|
+
workflowHistoryList: {
|
|
194
|
+
specailText: '特',
|
|
195
|
+
index: '序号',
|
|
196
|
+
taskName: '环节名称',
|
|
197
|
+
operation: '流转操作',
|
|
198
|
+
opinion: '办理意见',
|
|
199
|
+
processStart: '流程开始',
|
|
200
|
+
processEnd: '流程结束',
|
|
201
|
+
process_start: '[{1}]流程开始',
|
|
202
|
+
prcoess_end: '[{1}]流程结束',
|
|
203
|
+
force_end_process: '{1}强制结束了该流程,[{2}]的任务被取消',
|
|
204
|
+
history_jump: '流程{3}到[{1}],[{2}]的任务被取消',
|
|
205
|
+
history_back: '{1}退回任务,流程退回到[{2}]',
|
|
206
|
+
history_removesign: '{1}给[{2}]减签',
|
|
207
|
+
history_changetransactor_and_delegate: '{1}把办理人[{2}]更改成[{3})],{4}把任务委托给了[{5}]',
|
|
208
|
+
history_changetransactor: '{1}把办理人[{2}]更改成[{3}]',
|
|
209
|
+
history_addsign: '{1}给[{2}]加签',
|
|
210
|
+
history_addtransactor: '{1}增加办理人[{2}]',
|
|
211
|
+
history_removetransactor: '{1}减少办理人[{2}]',
|
|
212
|
+
history_delegate_and_assign: '{1}把任务指派给了[{2}],[{3}]把任务委托给了[{4}]',
|
|
213
|
+
history_assign: '{1}把任务指派给了[{2}]',
|
|
214
|
+
transfer: '{1}移交给[{2}]',
|
|
215
|
+
history_complete_transfer: '{1}执行了[{2}]操作,取消了其它接收人[{3}]的任务',
|
|
216
|
+
history_delegate_receive: '{1}收回委托给[{2}]的任务',
|
|
217
|
+
history_delegate: '{1}已把任务[{2}]委托给[{3}]',
|
|
218
|
+
history_quit_transfer: '{1}离职,已把任务[{2}]移交给了[{3}]',
|
|
219
|
+
history_change_job_transfer: '{1}换岗,已把任务[{2}]移交给了[{3}]',
|
|
220
|
+
commonButtonOperation: '{1}执行了[{2}]操作',
|
|
221
|
+
history_draw_task: '{1}领取了任务,取消了候选人[{2}]的任务',
|
|
222
|
+
history_abandon_draw: '{1}放弃领取该任务,还原了候选人[{2}]的任务',
|
|
223
|
+
create_copy_task: '{1}把任务抄送给了[{2}]',
|
|
224
|
+
toDoText: '待处理',
|
|
225
|
+
operator: '操作人',
|
|
226
|
+
operatorDept: '操作人部门',
|
|
227
|
+
operationTime: '操作时间',
|
|
228
|
+
history_draw_dept_task: '{1}领取了部门[{2}]的任务',
|
|
229
|
+
history_abandon_draw_dept_task: '{1}放弃领取部门[{2}]的任务',
|
|
230
|
+
loginName: '登录名'
|
|
231
|
+
},
|
|
232
|
+
gateway: {
|
|
233
|
+
timeout: '接口调用超时',
|
|
234
|
+
callFailed: '接口调用失败'
|
|
235
|
+
},
|
|
236
|
+
// 九宫格列表组件
|
|
237
|
+
superNineGrid: {
|
|
238
|
+
add: '新建'
|
|
239
|
+
},
|
|
240
|
+
fsUpload: {
|
|
241
|
+
upload: '上传',
|
|
242
|
+
download: '下载',
|
|
243
|
+
delete: '删除',
|
|
244
|
+
preview: '预览',
|
|
245
|
+
name: '名称',
|
|
246
|
+
picture: '图片',
|
|
247
|
+
operating: '操作',
|
|
248
|
+
uploadSucceeded: '上传成功',
|
|
249
|
+
theNumberOfUploadsExceedsTheLimitTheLimitIs: '上传数量超过限制,限制数量为'
|
|
250
|
+
},
|
|
251
|
+
messageVideo: {
|
|
252
|
+
attemptingToIdentify: '正在尝试识别....',
|
|
253
|
+
callingRearCamera: '正在调用后置摄像头...',
|
|
254
|
+
identificationFailed: '识别失败'
|
|
255
|
+
},
|
|
256
|
+
IntervalSelection: {
|
|
257
|
+
year: '年',
|
|
258
|
+
quarter: '季度',
|
|
259
|
+
auxiliary: '第',
|
|
260
|
+
week: '周'
|
|
261
|
+
},
|
|
262
|
+
...zhLocale
|
|
263
|
+
}
|
|
264
|
+
export default cn
|