kz-ui-base 1.0.118 → 1.0.120
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.
|
@@ -53,7 +53,8 @@ export default {
|
|
|
53
53
|
}
|
|
54
54
|
|
|
55
55
|
function initSystemCache() {
|
|
56
|
-
|
|
56
|
+
if (!localStorage.getItem("dict")){
|
|
57
|
+
getUrl("/system/dict/data/getAll").then(
|
|
57
58
|
(response) => {
|
|
58
59
|
var data = response.data;
|
|
59
60
|
Vue.prototype.$cache.local.setJSON("dict", data);
|
|
@@ -62,9 +63,12 @@ export default {
|
|
|
62
63
|
console.log(error);
|
|
63
64
|
}
|
|
64
65
|
);
|
|
66
|
+
}
|
|
67
|
+
|
|
65
68
|
|
|
66
69
|
// user cache
|
|
67
|
-
|
|
70
|
+
if (!localStorage.getItem("user"))(
|
|
71
|
+
getUrl("/system/user/getAll").then(
|
|
68
72
|
(response) => {
|
|
69
73
|
console.log(response);
|
|
70
74
|
var data = response.data;
|
|
@@ -73,8 +77,10 @@ export default {
|
|
|
73
77
|
(error) => {
|
|
74
78
|
console.log(error);
|
|
75
79
|
}
|
|
76
|
-
)
|
|
77
|
-
|
|
80
|
+
)
|
|
81
|
+
)
|
|
82
|
+
if (!localStorage.getItem("dept")){
|
|
83
|
+
// dept cache
|
|
78
84
|
getUrl("/system/dept/getAll").then(
|
|
79
85
|
(response) => {
|
|
80
86
|
var data = response.data;
|
|
@@ -84,7 +90,9 @@ export default {
|
|
|
84
90
|
console.log(error);
|
|
85
91
|
}
|
|
86
92
|
);
|
|
87
|
-
|
|
93
|
+
}
|
|
94
|
+
if (!localStorage.getItem("configUrl")){
|
|
95
|
+
getUrl("/system/config/list?pageNum=1&pageSize=9999").then(
|
|
88
96
|
(response) => {
|
|
89
97
|
var data = response.data;
|
|
90
98
|
let list = [];
|
|
@@ -97,6 +105,8 @@ export default {
|
|
|
97
105
|
console.log(error);
|
|
98
106
|
}
|
|
99
107
|
);
|
|
108
|
+
}
|
|
109
|
+
|
|
100
110
|
}
|
|
101
111
|
},
|
|
102
112
|
};
|
|
@@ -135,6 +135,10 @@ export default {
|
|
|
135
135
|
default: function() {
|
|
136
136
|
return []
|
|
137
137
|
}
|
|
138
|
+
},
|
|
139
|
+
defaultTemplateId: {
|
|
140
|
+
type: String,
|
|
141
|
+
default: null
|
|
138
142
|
}
|
|
139
143
|
},
|
|
140
144
|
data() {
|
|
@@ -144,7 +148,7 @@ export default {
|
|
|
144
148
|
listData: [],
|
|
145
149
|
listQueryParams: {
|
|
146
150
|
pageNum: 1,
|
|
147
|
-
pageSize:
|
|
151
|
+
pageSize: 10,
|
|
148
152
|
total: 0,
|
|
149
153
|
templateType: this.templateType,
|
|
150
154
|
templateName: ''
|
|
@@ -204,6 +208,12 @@ export default {
|
|
|
204
208
|
}).then((response) => {
|
|
205
209
|
this.listData = response.rows
|
|
206
210
|
this.listQueryParams.total = Number(response.total)
|
|
211
|
+
if(this.defaultTemplateId){
|
|
212
|
+
this.$nextTick(() => {
|
|
213
|
+
this.tableSelection = this.listData.filter(item => item.id === this.defaultTemplateId)
|
|
214
|
+
this.$refs.multipleTable.toggleRowSelection(this.listData.filter(item => item.id === this.defaultTemplateId)[0])
|
|
215
|
+
})
|
|
216
|
+
}
|
|
207
217
|
this.loading = false
|
|
208
218
|
})
|
|
209
219
|
},
|