cloud-web-corejs 1.0.54-dev.321 → 1.0.54-dev.323

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cloud-web-corejs",
3
3
  "private": false,
4
- "version": "1.0.54-dev.321",
4
+ "version": "1.0.54-dev.323",
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
7
7
  "lint": "eslint --ext .js,.vue src",
@@ -88,7 +88,7 @@ export default {
88
88
  codes,
89
89
  customCondition:(exportTemplate)=>{
90
90
  let param = {
91
- formData: [this.formModel]
91
+ formData: this.formModel
92
92
  };
93
93
  if (this.field.options.printCustomCondition) {
94
94
  let param1 = this.handleCustomEvent(this.field.options.printCustomCondition,['exportTemplate'],[exportTemplate]);
@@ -50,8 +50,8 @@ service.interceptors.request.use(
50
50
  config.data = window.commonDataUtil.handleForm(config.data, config.filterConfig);
51
51
  }
52
52
  if (
53
- (config.headers['Content-Type'] == "application/x-www-form-urlencoded" ||
54
- config.headers['Content-Type'] == "application/x-www-form-urlencoded;charset=UTF-8") &&
53
+ (config.headers['Content-Type'] === "application/x-www-form-urlencoded" ||
54
+ config.headers['Content-Type'] === "application/x-www-form-urlencoded;charset=UTF-8") &&
55
55
  typeof (config.data) !== 'string' && config.data) {
56
56
  config.data = qs.stringify(config.data);
57
57
  } else if (settingConfig.base64Urls && settingConfig.base64Urls.includes(config.url)) {
@@ -100,7 +100,7 @@ function removeModel(config) {
100
100
 
101
101
  async function handleNickName(option) {
102
102
  let {vueTarget, res, callback, config} = option;
103
- if (res.type != "success" || !res.objx) {
103
+ if (res.type !== "success" || !res.objx) {
104
104
  callback && callback(res)
105
105
  return
106
106
  }
@@ -135,14 +135,14 @@ async function handleNickName(option) {
135
135
  success: res2 => {
136
136
  let arr = res2.objx || [];
137
137
  if (createBy) {
138
- let obj = arr.find(item => item.loginAccount == createBy);
138
+ let obj = arr.find(item => item.loginAccount === createBy);
139
139
  if (obj && obj.nickName) {
140
140
  res.objx._createNickName = obj.nickName;
141
141
  res.objx._createMobile = obj.mobile;
142
142
  }
143
143
  }
144
144
  if (modifyBy) {
145
- let obj = arr.find(item => item.loginAccount == modifyBy);
145
+ let obj = arr.find(item => item.loginAccount === modifyBy);
146
146
  if (obj && obj.nickName) {
147
147
  res.objx._modifyNickName = obj.nickName;
148
148
  res.objx._modifyMobile = obj.mobile;
@@ -163,16 +163,16 @@ function handleCreateInfo(config, res) {
163
163
  let _createBy = null;
164
164
  let _modifyBy = null;
165
165
  if (row._createNickName) {
166
- if (queryCreateInfo == "1") {
166
+ if (queryCreateInfo === "1") {
167
167
  _createBy = getCreateBy(row) + "(" + row._createNickName + ")";
168
- } else if (queryCreateInfo == "2") {
168
+ } else if (queryCreateInfo === "2") {
169
169
  _createBy = row._createNickName;
170
170
  }
171
171
  }
172
172
  if (row._modifyNickName) {
173
- if (queryCreateInfo == "1") {
173
+ if (queryCreateInfo === "1") {
174
174
  _modifyBy = getModifyBy(row) + "(" + row._modifyNickName + ")";
175
- } else if (queryCreateInfo == "2") {
175
+ } else if (queryCreateInfo === "2") {
176
176
  _modifyBy = row._modifyNickName;
177
177
  }
178
178
  }
@@ -180,7 +180,7 @@ function handleCreateInfo(config, res) {
180
180
  row._modifyBy = _modifyBy || getCreateBy(row) || null;
181
181
  }
182
182
  let data = res.objx;
183
- if (typeof res.objx == "object") {
183
+ if (typeof res.objx === "object") {
184
184
  if (Array.isArray(data)) {
185
185
  res.objx.forEach(item => {
186
186
  toDo(item);
@@ -222,7 +222,7 @@ function getModifyBy(row) {
222
222
 
223
223
  async function handleNickName2(option) {
224
224
  let {vueTarget, res, callback, config} = option;
225
- if (res.type != "success" || !res.objx) {
225
+ if (res.type !== "success" || !res.objx) {
226
226
  callback && callback(res)
227
227
  return
228
228
  }
@@ -263,14 +263,14 @@ async function handleNickName2(option) {
263
263
  let createBy = getCreateBy(item);
264
264
  let modifyBy = getModifyBy(item);
265
265
  if (createBy) {
266
- let obj = arr.find(item => item.loginAccount == createBy);
266
+ let obj = arr.find(item => item.loginAccount === createBy);
267
267
  if (obj && obj.nickName) {
268
268
  item._createNickName = obj.nickName;
269
269
  item._createMobile = obj.mobile;
270
270
  }
271
271
  }
272
272
  if (modifyBy) {
273
- let obj = arr.find(item => item.loginAccount == modifyBy);
273
+ let obj = arr.find(item => item.loginAccount === modifyBy);
274
274
  if (obj && obj.nickName) {
275
275
  item._modifyNickName = obj.nickName;
276
276
  item._modifyMobile = obj.mobile;
@@ -286,13 +286,13 @@ service.interceptors.response.use(
286
286
  async response => {
287
287
  const res = response.data;
288
288
  const config = response.config;
289
- if (config.resultType == "other") {
289
+ if (config.resultType === "other") {
290
290
  config.callback && config.callback(res, response);
291
291
  removeModel(config);
292
292
  return res;
293
293
  } else if (res.type) {
294
- if (res.type == "success") {
295
- if (settingConfig.queryCreateInfo !== false && config.queryCreateInfo && config.queryCreateInfo != "0") {
294
+ if (res.type === "success") {
295
+ if (settingConfig.queryCreateInfo !== false && config.queryCreateInfo && config.queryCreateInfo !== "0") {
296
296
  let vueTarget = config.vueTarget;
297
297
  await handleNickName({vueTarget, res, config});
298
298
  }
@@ -305,7 +305,7 @@ service.interceptors.response.use(
305
305
  removeModel(config);
306
306
  return res;
307
307
  } else {
308
- if (res.rmid == "999999999") {
308
+ if (res.rmid === "999999999") {
309
309
  removeModel(config);
310
310
  configUtil.logout();
311
311
  } else {
@@ -314,7 +314,7 @@ service.interceptors.response.use(
314
314
  if (config.modalStrictly !== true) {
315
315
  removeModel(config);
316
316
  }
317
- if (config.resultType != "special" && config.failMsg !== false) {
317
+ if (config.resultType !== "special" && config.failMsg !== false) {
318
318
  ErroreBox.msg(res);
319
319
  }
320
320
  }
@@ -329,7 +329,7 @@ service.interceptors.response.use(
329
329
  },
330
330
  error => {
331
331
  let config = error.config;
332
- if (error.response && error.response.data && error.response.data.rmid == "999999999") {
332
+ if (error.response && error.response.data && error.response.data.rmid === "999999999") {
333
333
  removeModel(config);
334
334
  configUtil.logout();
335
335
  } else {