kz-ui-base 1.0.3 → 1.0.5

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.
@@ -1,9 +1,9 @@
1
1
  import Vue from "vue";
2
2
  import dialog from "@components/base/dialog/Dialog";
3
- import router from "../../../../../main/src/router/index.js";
3
+ import router from "@/router/index.js";
4
4
  Vue.prototype.dialog = dialog;
5
5
  const open = (options) => {
6
- if (options.setting?.jumpUrl) {
6
+ if (options.setting&&options.setting.jumpUrl) {
7
7
  router.push({
8
8
  name: options.setting.jumpUrl
9
9
  .toLowerCase()
@@ -13,14 +13,14 @@ const open = (options) => {
13
13
  return;
14
14
  }
15
15
  if (typeof options.component === "string") {
16
- let component = options?.component;
16
+ let component = options&&options.component;
17
17
  options.component = (resolve) => {
18
18
  require([`@/${component}`], resolve);
19
19
  };
20
20
  }
21
- if (options?.setting?.showType == "menuTab") {
21
+ if (options&&options.setting&&options.setting.showType == "menuTab") {
22
22
  let url = new Date().getTime();
23
- if (options.setting?.entityId) {
23
+ if (options.setting&&options.setting.entityId) {
24
24
  url = options.setting.entityId;
25
25
  }
26
26
  router.addRoute("tabmenu", {
@@ -49,7 +49,7 @@ const open = (options) => {
49
49
  ) {
50
50
  Vue.prototype.openDialog(options.component)({
51
51
  ...options,
52
- ...options?.setting?.data,
52
+ ...options&&options.setting&&options.setting.data,
53
53
  });
54
54
  } else {
55
55
  Vue.prototype.dialog.open(options);
@@ -63,7 +63,7 @@ const open = (options) => {
63
63
  if (String(instance.dialogType) === "2") {
64
64
  Vue.prototype.openDialog(options.component)({
65
65
  ...options,
66
- ...options?.setting?.data,
66
+ ...options&&options.setting&&options.setting.data,
67
67
  });
68
68
  } else {
69
69
  Vue.prototype.dialog.open(options);
@@ -132,7 +132,7 @@ export default {
132
132
  name: "PrintDialog",
133
133
 
134
134
  components: {
135
- SearchTable: () => import("../../customForm/searchTable"),
135
+ SearchTable: () => import("@/components/customForm/searchTable"),
136
136
  },
137
137
  props: {
138
138
  //微服务模块名称
@@ -58,7 +58,7 @@ import {
58
58
  addEntity,
59
59
  updateEntity,
60
60
  listEntity,
61
- } from "../../../api/common/common";
61
+ } from "@/api/common/common";
62
62
  export default {
63
63
  name: "tableDialog",
64
64
  extends: EditDialog,
@@ -34,21 +34,8 @@
34
34
  </template>
35
35
 
36
36
  <script>
37
- import {
38
- listUser,
39
- getUser,
40
- delUser,
41
- addUser,
42
- updateUser,
43
- resetUserPwd,
44
- changeUserStatus,
45
- changeUserRole
46
- } from "@/api/system/user"
47
37
  import {getToken} from "@utils/auth"
48
- import {treeSelect} from "@/api/system/post"
49
- import Treeselect from "@riophae/vue-treeselect"
50
38
  import "@riophae/vue-treeselect/dist/vue-treeselect.css"
51
- import {optionSelect} from "@/api/system/role"
52
39
 
53
40
  export default {
54
41
  name: "UploadDialog",
@@ -1,8 +1,6 @@
1
1
  // import Vue from 'vue'
2
- import router from "~../../../src/router";
2
+ import router from "@/router";
3
3
  import Layout from "@/layout";
4
- // import path from 'path';
5
- import store from "@/store";
6
4
  // let tt=this.$store.state.tagsView.visitedViews
7
5
  // let vm = new Vue();
8
6
  // export default (url, setting) => {
@@ -1,4 +1,4 @@
1
- import store from '~../../../src/store'
1
+ import store from '@/store'
2
2
 
3
3
  function authPermission(permission) {
4
4
  const all_permission = "*:*:*";
@@ -1,5 +1,5 @@
1
- import store from '~../../../src/store'
2
- import router from '~../../../src/router';
1
+ import store from '@/store'
2
+ import router from '@/router';
3
3
 
4
4
  export default {
5
5
  // 刷新当前tab页签
@@ -1,6 +1,5 @@
1
1
  import Vue from 'vue'
2
2
  import {getUrl} from '../../api/common/common';
3
- import Big from "big.js";
4
3
 
5
4
  let that = new Vue()
6
5
 
@@ -1,12 +1,12 @@
1
- import Vue from '~../../vue'
1
+ import Vue from 'vue'
2
2
 
3
3
  let common={};
4
4
  if (window)
5
5
  window.common = common;
6
6
  /**
7
7
  *
8
- * ��common����������еĹ��÷���
9
- * common.dialog()�ǵ��õ���ķ���
8
+ * ��common����������еĹ��÷���
9
+ * common.dialog()�ǵ��õ���ķ���
10
10
  */
11
11
  common.dialog = function (option) {
12
12
  var m = document.createElement('div');
@@ -83,11 +83,11 @@ common.dialog = function (option) {
83
83
  this.show = false;
84
84
  return;
85
85
  }
86
- //�������type����type����close��cancelֱ�ӹرյ���
86
+ //�������type����type����close��cancelֱ�ӹرյ���
87
87
  if (!result.type || result.type == 'close' || result.type == 'cancel') {
88
88
  this.show = false;
89
89
  } else if (result.type == 'sure') {
90
- //���type����sure�����parent���ݹ����Ļص���
90
+ //���type����sure�����parent���ݹ����Ļص���
91
91
  this.show = false;
92
92
  if (option.callback) {
93
93
  option.callback(result.data);
@@ -1,4 +1,4 @@
1
- import Vue from '~../../vue'
1
+ import Vue from 'vue'
2
2
 
3
3
 
4
4
  //dialog.js
@@ -1,4 +1,4 @@
1
- import Vue from '~../../vue'
1
+ import Vue from 'vue'
2
2
 
3
3
  // v-dialogDrag: 弹窗拖拽
4
4
  Vue.directive('dialogDrag', {
@@ -1,5 +1,4 @@
1
- import defaultSettings from "../../settings";
2
-
1
+ import defaultSettings from "@/settings";
3
2
 
4
3
  /**
5
4
  * 通用js方法封装处理
@@ -5,7 +5,7 @@ const kezhiTool = {
5
5
  for (const key in obj) {
6
6
  if (
7
7
  key == item.property &&
8
- (item.displayType == "CheckBox" || item.setting?.multiple)
8
+ (item.displayType == "CheckBox" || (item.setting&&item.setting.multiple))
9
9
  ) {
10
10
  if (obj[key]) {
11
11
  obj[key] = _.join(obj[key], split);
@@ -21,7 +21,7 @@ const kezhiTool = {
21
21
  for (const key in obj) {
22
22
  if (
23
23
  key == item.property &&
24
- (item.displayType == "CheckBox" || item.setting?.multiple)
24
+ (item.displayType == "CheckBox" || (item.setting&&item.setting.multiple))
25
25
  ) {
26
26
  if (obj[key]) {
27
27
  obj[key] = _.split(obj[key], split);
@@ -1,4 +1,4 @@
1
- import store from '~../../../src/store'
1
+ import store from '@/store'
2
2
 
3
3
  /**
4
4
  * 字符权限校验
@@ -1,6 +1,6 @@
1
1
  import axios from "~../../axios";
2
- import { Notification, MessageBox, Message } from "~../../element-ui";
3
- import store from "~../../../src/store";
2
+ import { Notification, MessageBox, Message } from "element-ui";
3
+ import store from "@/store";
4
4
  import { getToken } from "./auth";
5
5
  import errorCode from "./errorCode";
6
6
  import { tansParams } from "./ruoyi";
@@ -106,10 +106,8 @@
106
106
 
107
107
  <script>
108
108
  import { accessToken } from "../api/login";
109
- import Cookies from "~../../js-cookie";
110
- import { encrypt, decrypt } from "../utils/jsencrypt";
111
109
  import store from "@/store";
112
- import { getToken, setToken, setExpiresIn, removeToken } from "@utils/auth";
110
+ import { getToken, setToken} from "@utils/auth";
113
111
  import { getWebConfig } from "../utils/utils";
114
112
  export default {
115
113
  name: "Login",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kz-ui-base",
3
- "version": "1.0.3",
3
+ "version": "1.0.5",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -1,46 +0,0 @@
1
- module.exports = {
2
- /** 侧边栏主题 深色主题theme-dark,浅色主题theme-light */
3
- sideTheme: 'theme-dark',
4
-
5
- /** 是否系统布局配置 */
6
- showSettings: false,
7
-
8
- /** 是否显示顶部导航 */
9
- topNav: false,
10
-
11
- /** 是否显示 tagsView */
12
- tagsView: true,
13
-
14
- /** 是否固定头部 */
15
- fixedHeader: true,
16
-
17
- /** 是否显示logo */
18
- sidebarLogo: true,
19
-
20
- /** 是否显示动态标题 */
21
- dynamicTitle: false,
22
-
23
- /** 库编号 */
24
- libraryId: 0,
25
-
26
- /** 站点编号 */
27
- siteId: 0,
28
-
29
- /** 系统编号 */
30
- systemId: 0,
31
-
32
- /** 初始页名称|图标 */
33
- homePageName: '首页',
34
- homePageIcon: 'xy_productCenter',
35
-
36
- /** 主登录页地址 | loginAddress='' 时则跳转至本地登录页 | 本参数目的为控制集中登录/分散登录 */
37
- baseSystemUrl: '',
38
-
39
- /**
40
- * @type {string | array} 'production' | ['production', 'development']
41
- * @description Need show err logs component.
42
- * The default is only used in the production env
43
- * If you want to also use it in dev, you can pass ['production', 'development']
44
- */
45
- errorLog: 'production'
46
- }