@freelog/tools-lib 0.1.162 → 0.1.165

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.
@@ -12,50 +12,42 @@ var i18next = _interopDefault(require('i18next'));
12
12
  var Cookies = _interopDefault(require('js-cookie'));
13
13
  var htmlReactParser = _interopDefault(require('html-react-parser'));
14
14
 
15
+ // import {report} from '@freelog/resource-policy-lang/dist';
15
16
  // import {ContractEntity} from '@freelog/resource-policy-lang/dist/tools/ContractTool';
16
17
  // const {compile} = require('@freelog/resource-policy-lang');
17
-
18
18
  /**
19
19
  * 将对应的字节数,转换为易读单位数量
20
20
  * @param bytes
21
21
  * @return {string}
22
22
  */
23
-
24
23
  function humanizeSize(bytes) {
25
24
  // console.log('dddhumanizeSizesdfsd');
26
25
  if (bytes <= 0) {
27
26
  return '0 B';
28
27
  }
29
-
30
28
  var unitArr = ['B', 'KB', 'MB', 'GB', 'TB', 'PB', 'EB', 'ZB', 'YB'];
31
29
  var index = Math.floor(Math.log(bytes) / Math.log(1024));
32
30
  var size = Math.round(bytes / Math.pow(1024, index) * 100) / 100; //保留的小数位数
33
-
34
31
  return size + ' ' + unitArr[index];
35
32
  }
36
33
  /**
37
34
  * 格式化日期时间
38
35
  */
39
-
40
36
  function formatDateTime(date, showTime) {
41
37
  if (showTime === void 0) {
42
38
  showTime = false;
43
39
  }
44
-
45
40
  return moment(date).format('YYYY/MM/DD' + (showTime ? ' HH:mm' : ''));
46
41
  }
47
42
  /**
48
43
  * 根据传入的子域名拼合成完整的适合的url
49
44
  * @param domain 要组合的三级域名
50
45
  */
51
-
52
46
  function completeUrlByDomain(domain) {
53
47
  var origin = "https://" + domain + ".testfreelog.com";
54
-
55
48
  if (window.location.origin.includes('.freelog.com')) {
56
49
  origin = "https://" + domain + ".freelog.com";
57
50
  }
58
-
59
51
  return origin;
60
52
  }
61
53
  /**
@@ -104,12 +96,10 @@ function completeUrlByDomain(domain) {
104
96
  // };
105
97
  // }
106
98
  // }
107
-
108
99
  /**
109
100
  * 将资源类型关键字数组,转换成标准展示文字
110
101
  * @param arr 关键字数组
111
102
  */
112
-
113
103
  function resourceTypeKeyArrToResourceType(arr) {
114
104
  return arr.join(' / ');
115
105
  }
@@ -123,46 +113,46 @@ var Format = {
123
113
  };
124
114
 
125
115
  // 展品名称
126
- var EXHIBIT_NAME = /*#__PURE__*/new RegExp(/^(?!.*(\\|\/|:|\*|\?|"|<|>|\||\s|@|\$|#)).{1,60}$/); // 资源名称
127
-
128
- var RESOURCE_NAME = /*#__PURE__*/new RegExp(/^(?!.*(\\|\/|:|\*|\?|"|<|>|\||\s|@|\$|#)).{1,60}$/); // 资源类型
129
-
130
- var RESOURCE_TYPE = /*#__PURE__*/new RegExp("^[\u4E00-\u9FEFa-zA-Z0-9\\-&.,]{1,40}$"); // 自定义属性键
116
+ var EXHIBIT_NAME = /*#__PURE__*/new RegExp(/^(?!.*(\\|\/|:|\*|\?|"|<|>|\||\s|@|\$|#)).{1,60}$/);
117
+ // 资源名称
118
+ var RESOURCE_NAME = /*#__PURE__*/new RegExp(/^(?!.*(\\|\/|:|\*|\?|"|<|>|\||\s|@|\$|#)).{1,60}$/);
119
+ // 资源类型
120
+ var RESOURCE_TYPE = /*#__PURE__*/new RegExp("^[\u4E00-\u9FEFa-zA-Z0-9\\-&.,]{1,40}$");
121
+ // 自定义属性键
131
122
  // export const CUSTOM_KEY: RegExp = new RegExp(/^[a-zA-Z_]([a-zA-Z0-9_]{1,19})?$/);
132
-
133
- var CUSTOM_KEY = /*#__PURE__*/new RegExp('^[a-zA-Z]([a-zA-Z0-9_]{1,29})?$'); // 节点名称
134
-
135
- var NODE_NAME = /*#__PURE__*/new RegExp(/^[\u4E00-\u9FA5|a-zA-Z0-9]{2,24}$/); // 节点地址
123
+ var CUSTOM_KEY = /*#__PURE__*/new RegExp('^[a-zA-Z]([a-zA-Z0-9_]{1,29})?$');
124
+ // 节点名称
125
+ var NODE_NAME = /*#__PURE__*/new RegExp(/^[\u4E00-\u9FA5|a-zA-Z0-9]{2,24}$/);
126
+ // 节点地址
136
127
  // export const NODE_DOMAIN: RegExp = new RegExp(/^(?!-)[a-z0-9-]{4,24}(?<!-)$/);
137
-
138
- var NODE_DOMAIN = /*#__PURE__*/new RegExp(/^[a-z0-9][a-z0-9-]{2,22}[a-z0-9]$/); // 支付密码
139
-
140
- var PAY_PASSWORD = /*#__PURE__*/new RegExp(/^\d{6}$/); // 手机号码
141
-
142
- var MOBILE_PHONE_NUMBER = /*#__PURE__*/new RegExp(/^1[345789]\d{9}$/); // export const TELEPHONE_NUMBER = /^((13[0-9])|(14[5-9])|(15([0-3]|[5-9]))|(16[6-7])|(17[1-8])|(18[0-9])|(19[1|3])|(19[5|6])|(19[8|9]))\d{8}$/
128
+ var NODE_DOMAIN = /*#__PURE__*/new RegExp(/^[a-z0-9][a-z0-9-]{2,22}[a-z0-9]$/);
129
+ // 支付密码
130
+ var PAY_PASSWORD = /*#__PURE__*/new RegExp(/^\d{6}$/);
131
+ // 手机号码
132
+ var MOBILE_PHONE_NUMBER = /*#__PURE__*/new RegExp(/^1[345789]\d{9}$/);
133
+ // export const TELEPHONE_NUMBER = /^((13[0-9])|(14[5-9])|(15([0-3]|[5-9]))|(16[6-7])|(17[1-8])|(18[0-9])|(19[1|3])|(19[5|6])|(19[8|9]))\d{8}$/
143
134
  // 邮箱地址
144
-
145
- var EMAIL_ADDRESS = /*#__PURE__*/new RegExp(/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/); // 用户名
135
+ var EMAIL_ADDRESS = /*#__PURE__*/new RegExp(/^\w+([-+.]\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*$/);
136
+ // 用户名
146
137
  // export const USERNAME: RegExp = new RegExp(/^(?!-)[A-Za-z0-9-]{1,30}(?<!-)$/);
147
-
148
- var USERNAME = /*#__PURE__*/new RegExp(/^([A-Za-z0-9][A-Za-z0-9-]{0,28})?[A-Za-z0-9]$/); // 用户密码
138
+ var USERNAME = /*#__PURE__*/new RegExp(/^([A-Za-z0-9][A-Za-z0-9-]{0,28})?[A-Za-z0-9]$/);
139
+ // 用户密码
149
140
  // export const PASSWORD = /^(?=.*[a-zA-Z])(?=.*[0-9]).{6,24}$/;
150
-
151
- var PASSWORD = /*#__PURE__*/new RegExp(/^(?=.*[0-9])(?=.*[a-zA-Z])(.{6,24})$/); // 自然数
152
-
153
- var NATURAL_NUMBER = /*#__PURE__*/new RegExp(/^[0-9]*$/); // 正整数
154
-
155
- var POSITIVE_INTEGER = /*#__PURE__*/new RegExp(/^[1-9]\d*$/); // 最多两位小数的正数
141
+ var PASSWORD = /*#__PURE__*/new RegExp(/^(?=.*[0-9])(?=.*[a-zA-Z])(.{6,24})$/);
142
+ // 自然数
143
+ var NATURAL_NUMBER = /*#__PURE__*/new RegExp(/^[0-9]*$/);
144
+ // 正整数
145
+ var POSITIVE_INTEGER = /*#__PURE__*/new RegExp(/^[1-9]\d*$/);
146
+ // 最多两位小数的正数
156
147
  // export const MAX_2_DECIMAL_POSITIVE_NUMBER = new RegExp(/^\d+(.\d{1,2})?$/);
157
-
158
- var MAX_2_DECIMAL_POSITIVE_NUMBER = /*#__PURE__*/new RegExp(/^\d+(\.\d{0,2})?$/); // 对象的Bucket名称
159
-
160
- var BUCKET_NAME = /*#__PURE__*/new RegExp(/^([a-z0-9][a-z0-9-]{0,61})?[a-z0-9]$/); // JS变量名称
161
-
162
- var JS_VARIABLE_NAME = /*#__PURE__*/new RegExp(/^[A-Za-z$_][\w$_]*$/); // 日期
163
-
164
- var DATE = /*#__PURE__*/new RegExp(/(([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29)$/); // 日期时间
165
-
148
+ var MAX_2_DECIMAL_POSITIVE_NUMBER = /*#__PURE__*/new RegExp(/^\d+(\.\d{0,2})?$/);
149
+ // 对象的Bucket名称
150
+ var BUCKET_NAME = /*#__PURE__*/new RegExp(/^([a-z0-9][a-z0-9-]{0,61})?[a-z0-9]$/);
151
+ // JS变量名称
152
+ var JS_VARIABLE_NAME = /*#__PURE__*/new RegExp(/^[A-Za-z$_][\w$_]*$/);
153
+ // 日期
154
+ var DATE = /*#__PURE__*/new RegExp(/(([0-9]{3}[1-9]|[0-9]{2}[1-9][0-9]{1}|[0-9]{1}[1-9][0-9]{2}|[1-9][0-9]{3})-(((0[13578]|1[02])-(0[1-9]|[12][0-9]|3[01]))|((0[469]|11)-(0[1-9]|[12][0-9]|30))|(02-(0[1-9]|[1][0-9]|2[0-8]))))|((([0-9]{2})(0[48]|[2468][048]|[13579][26])|((0[48]|[2468][048]|[3579][26])00))-02-29)$/);
155
+ // 日期时间
166
156
  var DATE_TIME = /*#__PURE__*/new RegExp(/^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}$/);
167
157
 
168
158
  var Regexp = {
@@ -187,441 +177,367 @@ var Regexp = {
187
177
  DATE_TIME: DATE_TIME
188
178
  };
189
179
 
180
+ function asyncGeneratorStep(n, t, e, r, o, a, c) {
181
+ try {
182
+ var i = n[a](c),
183
+ u = i.value;
184
+ } catch (n) {
185
+ return void e(n);
186
+ }
187
+ i.done ? t(u) : Promise.resolve(u).then(r, o);
188
+ }
189
+ function _asyncToGenerator(n) {
190
+ return function () {
191
+ var t = this,
192
+ e = arguments;
193
+ return new Promise(function (r, o) {
194
+ var a = n.apply(t, e);
195
+ function _next(n) {
196
+ asyncGeneratorStep(a, r, o, _next, _throw, "next", n);
197
+ }
198
+ function _throw(n) {
199
+ asyncGeneratorStep(a, r, o, _next, _throw, "throw", n);
200
+ }
201
+ _next(void 0);
202
+ });
203
+ };
204
+ }
205
+ function _extends() {
206
+ return _extends = Object.assign ? Object.assign.bind() : function (n) {
207
+ for (var e = 1; e < arguments.length; e++) {
208
+ var t = arguments[e];
209
+ for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
210
+ }
211
+ return n;
212
+ }, _extends.apply(null, arguments);
213
+ }
214
+ function _objectDestructuringEmpty(t) {
215
+ if (null == t) throw new TypeError("Cannot destructure " + t);
216
+ }
217
+ function _objectWithoutPropertiesLoose(r, e) {
218
+ if (null == r) return {};
219
+ var t = {};
220
+ for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
221
+ if (e.includes(n)) continue;
222
+ t[n] = r[n];
223
+ }
224
+ return t;
225
+ }
190
226
  function _regeneratorRuntime() {
191
- /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
192
-
193
227
  _regeneratorRuntime = function () {
194
- return exports;
228
+ return e;
195
229
  };
196
-
197
- var exports = {},
198
- Op = Object.prototype,
199
- hasOwn = Op.hasOwnProperty,
200
- $Symbol = "function" == typeof Symbol ? Symbol : {},
201
- iteratorSymbol = $Symbol.iterator || "@@iterator",
202
- asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator",
203
- toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
204
-
205
- function define(obj, key, value) {
206
- return Object.defineProperty(obj, key, {
207
- value: value,
230
+ var t,
231
+ e = {},
232
+ r = Object.prototype,
233
+ n = r.hasOwnProperty,
234
+ o = Object.defineProperty || function (t, e, r) {
235
+ t[e] = r.value;
236
+ },
237
+ i = "function" == typeof Symbol ? Symbol : {},
238
+ a = i.iterator || "@@iterator",
239
+ c = i.asyncIterator || "@@asyncIterator",
240
+ u = i.toStringTag || "@@toStringTag";
241
+ function define(t, e, r) {
242
+ return Object.defineProperty(t, e, {
243
+ value: r,
208
244
  enumerable: !0,
209
245
  configurable: !0,
210
246
  writable: !0
211
- }), obj[key];
247
+ }), t[e];
212
248
  }
213
-
214
249
  try {
215
250
  define({}, "");
216
- } catch (err) {
217
- define = function (obj, key, value) {
218
- return obj[key] = value;
251
+ } catch (t) {
252
+ define = function (t, e, r) {
253
+ return t[e] = r;
219
254
  };
220
255
  }
221
-
222
- function wrap(innerFn, outerFn, self, tryLocsList) {
223
- var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator,
224
- generator = Object.create(protoGenerator.prototype),
225
- context = new Context(tryLocsList || []);
226
- return generator._invoke = function (innerFn, self, context) {
227
- var state = "suspendedStart";
228
- return function (method, arg) {
229
- if ("executing" === state) throw new Error("Generator is already running");
230
-
231
- if ("completed" === state) {
232
- if ("throw" === method) throw arg;
233
- return doneResult();
234
- }
235
-
236
- for (context.method = method, context.arg = arg;;) {
237
- var delegate = context.delegate;
238
-
239
- if (delegate) {
240
- var delegateResult = maybeInvokeDelegate(delegate, context);
241
-
242
- if (delegateResult) {
243
- if (delegateResult === ContinueSentinel) continue;
244
- return delegateResult;
245
- }
246
- }
247
-
248
- if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
249
- if ("suspendedStart" === state) throw state = "completed", context.arg;
250
- context.dispatchException(context.arg);
251
- } else "return" === context.method && context.abrupt("return", context.arg);
252
- state = "executing";
253
- var record = tryCatch(innerFn, self, context);
254
-
255
- if ("normal" === record.type) {
256
- if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
257
- return {
258
- value: record.arg,
259
- done: context.done
260
- };
261
- }
262
-
263
- "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
264
- }
265
- };
266
- }(innerFn, self, context), generator;
256
+ function wrap(t, e, r, n) {
257
+ var i = e && e.prototype instanceof Generator ? e : Generator,
258
+ a = Object.create(i.prototype),
259
+ c = new Context(n || []);
260
+ return o(a, "_invoke", {
261
+ value: makeInvokeMethod(t, r, c)
262
+ }), a;
267
263
  }
268
-
269
- function tryCatch(fn, obj, arg) {
264
+ function tryCatch(t, e, r) {
270
265
  try {
271
266
  return {
272
267
  type: "normal",
273
- arg: fn.call(obj, arg)
268
+ arg: t.call(e, r)
274
269
  };
275
- } catch (err) {
270
+ } catch (t) {
276
271
  return {
277
272
  type: "throw",
278
- arg: err
273
+ arg: t
279
274
  };
280
275
  }
281
276
  }
282
-
283
- exports.wrap = wrap;
284
- var ContinueSentinel = {};
285
-
277
+ e.wrap = wrap;
278
+ var h = "suspendedStart",
279
+ l = "suspendedYield",
280
+ f = "executing",
281
+ s = "completed",
282
+ y = {};
286
283
  function Generator() {}
287
-
288
284
  function GeneratorFunction() {}
289
-
290
285
  function GeneratorFunctionPrototype() {}
291
-
292
- var IteratorPrototype = {};
293
- define(IteratorPrototype, iteratorSymbol, function () {
286
+ var p = {};
287
+ define(p, a, function () {
294
288
  return this;
295
289
  });
296
- var getProto = Object.getPrototypeOf,
297
- NativeIteratorPrototype = getProto && getProto(getProto(values([])));
298
- NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype);
299
- var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
300
-
301
- function defineIteratorMethods(prototype) {
302
- ["next", "throw", "return"].forEach(function (method) {
303
- define(prototype, method, function (arg) {
304
- return this._invoke(method, arg);
290
+ var d = Object.getPrototypeOf,
291
+ v = d && d(d(values([])));
292
+ v && v !== r && n.call(v, a) && (p = v);
293
+ var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
294
+ function defineIteratorMethods(t) {
295
+ ["next", "throw", "return"].forEach(function (e) {
296
+ define(t, e, function (t) {
297
+ return this._invoke(e, t);
305
298
  });
306
299
  });
307
300
  }
308
-
309
- function AsyncIterator(generator, PromiseImpl) {
310
- function invoke(method, arg, resolve, reject) {
311
- var record = tryCatch(generator[method], generator, arg);
312
-
313
- if ("throw" !== record.type) {
314
- var result = record.arg,
315
- value = result.value;
316
- return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) {
317
- invoke("next", value, resolve, reject);
318
- }, function (err) {
319
- invoke("throw", err, resolve, reject);
320
- }) : PromiseImpl.resolve(value).then(function (unwrapped) {
321
- result.value = unwrapped, resolve(result);
322
- }, function (error) {
323
- return invoke("throw", error, resolve, reject);
301
+ function AsyncIterator(t, e) {
302
+ function invoke(r, o, i, a) {
303
+ var c = tryCatch(t[r], t, o);
304
+ if ("throw" !== c.type) {
305
+ var u = c.arg,
306
+ h = u.value;
307
+ return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
308
+ invoke("next", t, i, a);
309
+ }, function (t) {
310
+ invoke("throw", t, i, a);
311
+ }) : e.resolve(h).then(function (t) {
312
+ u.value = t, i(u);
313
+ }, function (t) {
314
+ return invoke("throw", t, i, a);
324
315
  });
325
316
  }
326
-
327
- reject(record.arg);
317
+ a(c.arg);
328
318
  }
329
-
330
- var previousPromise;
331
-
332
- this._invoke = function (method, arg) {
333
- function callInvokeWithMethodAndArg() {
334
- return new PromiseImpl(function (resolve, reject) {
335
- invoke(method, arg, resolve, reject);
336
- });
319
+ var r;
320
+ o(this, "_invoke", {
321
+ value: function (t, n) {
322
+ function callInvokeWithMethodAndArg() {
323
+ return new e(function (e, r) {
324
+ invoke(t, n, e, r);
325
+ });
326
+ }
327
+ return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
337
328
  }
338
-
339
- return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
340
- };
329
+ });
341
330
  }
342
-
343
- function maybeInvokeDelegate(delegate, context) {
344
- var method = delegate.iterator[context.method];
345
-
346
- if (undefined === method) {
347
- if (context.delegate = null, "throw" === context.method) {
348
- if (delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method)) return ContinueSentinel;
349
- context.method = "throw", context.arg = new TypeError("The iterator does not provide a 'throw' method");
331
+ function makeInvokeMethod(e, r, n) {
332
+ var o = h;
333
+ return function (i, a) {
334
+ if (o === f) throw Error("Generator is already running");
335
+ if (o === s) {
336
+ if ("throw" === i) throw a;
337
+ return {
338
+ value: t,
339
+ done: !0
340
+ };
350
341
  }
351
-
352
- return ContinueSentinel;
353
- }
354
-
355
- var record = tryCatch(method, delegate.iterator, context.arg);
356
- if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
357
- var info = record.arg;
358
- return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel);
342
+ for (n.method = i, n.arg = a;;) {
343
+ var c = n.delegate;
344
+ if (c) {
345
+ var u = maybeInvokeDelegate(c, n);
346
+ if (u) {
347
+ if (u === y) continue;
348
+ return u;
349
+ }
350
+ }
351
+ if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
352
+ if (o === h) throw o = s, n.arg;
353
+ n.dispatchException(n.arg);
354
+ } else "return" === n.method && n.abrupt("return", n.arg);
355
+ o = f;
356
+ var p = tryCatch(e, r, n);
357
+ if ("normal" === p.type) {
358
+ if (o = n.done ? s : l, p.arg === y) continue;
359
+ return {
360
+ value: p.arg,
361
+ done: n.done
362
+ };
363
+ }
364
+ "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
365
+ }
366
+ };
359
367
  }
360
-
361
- function pushTryEntry(locs) {
362
- var entry = {
363
- tryLoc: locs[0]
368
+ function maybeInvokeDelegate(e, r) {
369
+ var n = r.method,
370
+ o = e.iterator[n];
371
+ if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
372
+ var i = tryCatch(o, e.iterator, r.arg);
373
+ if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
374
+ var a = i.arg;
375
+ return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
376
+ }
377
+ function pushTryEntry(t) {
378
+ var e = {
379
+ tryLoc: t[0]
364
380
  };
365
- 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry);
381
+ 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
366
382
  }
367
-
368
- function resetTryEntry(entry) {
369
- var record = entry.completion || {};
370
- record.type = "normal", delete record.arg, entry.completion = record;
383
+ function resetTryEntry(t) {
384
+ var e = t.completion || {};
385
+ e.type = "normal", delete e.arg, t.completion = e;
371
386
  }
372
-
373
- function Context(tryLocsList) {
387
+ function Context(t) {
374
388
  this.tryEntries = [{
375
389
  tryLoc: "root"
376
- }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
390
+ }], t.forEach(pushTryEntry, this), this.reset(!0);
377
391
  }
378
-
379
- function values(iterable) {
380
- if (iterable) {
381
- var iteratorMethod = iterable[iteratorSymbol];
382
- if (iteratorMethod) return iteratorMethod.call(iterable);
383
- if ("function" == typeof iterable.next) return iterable;
384
-
385
- if (!isNaN(iterable.length)) {
386
- var i = -1,
387
- next = function next() {
388
- for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next;
389
-
390
- return next.value = undefined, next.done = !0, next;
391
- };
392
-
393
- return next.next = next;
392
+ function values(e) {
393
+ if (e || "" === e) {
394
+ var r = e[a];
395
+ if (r) return r.call(e);
396
+ if ("function" == typeof e.next) return e;
397
+ if (!isNaN(e.length)) {
398
+ var o = -1,
399
+ i = function next() {
400
+ for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
401
+ return next.value = t, next.done = !0, next;
402
+ };
403
+ return i.next = i;
394
404
  }
395
405
  }
396
-
397
- return {
398
- next: doneResult
399
- };
406
+ throw new TypeError(typeof e + " is not iterable");
400
407
  }
401
-
402
- function doneResult() {
408
+ return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
409
+ value: GeneratorFunctionPrototype,
410
+ configurable: !0
411
+ }), o(GeneratorFunctionPrototype, "constructor", {
412
+ value: GeneratorFunction,
413
+ configurable: !0
414
+ }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
415
+ var e = "function" == typeof t && t.constructor;
416
+ return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
417
+ }, e.mark = function (t) {
418
+ return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
419
+ }, e.awrap = function (t) {
403
420
  return {
404
- value: undefined,
405
- done: !0
421
+ __await: t
406
422
  };
407
- }
408
-
409
- return GeneratorFunction.prototype = GeneratorFunctionPrototype, define(Gp, "constructor", GeneratorFunctionPrototype), define(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
410
- var ctor = "function" == typeof genFun && genFun.constructor;
411
- return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
412
- }, exports.mark = function (genFun) {
413
- return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
414
- }, exports.awrap = function (arg) {
415
- return {
416
- __await: arg
417
- };
418
- }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
423
+ }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
419
424
  return this;
420
- }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) {
421
- void 0 === PromiseImpl && (PromiseImpl = Promise);
422
- var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl);
423
- return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) {
424
- return result.done ? result.value : iter.next();
425
+ }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
426
+ void 0 === i && (i = Promise);
427
+ var a = new AsyncIterator(wrap(t, r, n, o), i);
428
+ return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
429
+ return t.done ? t.value : a.next();
425
430
  });
426
- }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
431
+ }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
427
432
  return this;
428
- }), define(Gp, "toString", function () {
433
+ }), define(g, "toString", function () {
429
434
  return "[object Generator]";
430
- }), exports.keys = function (object) {
431
- var keys = [];
432
-
433
- for (var key in object) keys.push(key);
434
-
435
- return keys.reverse(), function next() {
436
- for (; keys.length;) {
437
- var key = keys.pop();
438
- if (key in object) return next.value = key, next.done = !1, next;
435
+ }), e.keys = function (t) {
436
+ var e = Object(t),
437
+ r = [];
438
+ for (var n in e) r.push(n);
439
+ return r.reverse(), function next() {
440
+ for (; r.length;) {
441
+ var t = r.pop();
442
+ if (t in e) return next.value = t, next.done = !1, next;
439
443
  }
440
-
441
444
  return next.done = !0, next;
442
445
  };
443
- }, exports.values = values, Context.prototype = {
446
+ }, e.values = values, Context.prototype = {
444
447
  constructor: Context,
445
- reset: function (skipTempReset) {
446
- if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined);
448
+ reset: function (e) {
449
+ if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
447
450
  },
448
451
  stop: function () {
449
452
  this.done = !0;
450
- var rootRecord = this.tryEntries[0].completion;
451
- if ("throw" === rootRecord.type) throw rootRecord.arg;
453
+ var t = this.tryEntries[0].completion;
454
+ if ("throw" === t.type) throw t.arg;
452
455
  return this.rval;
453
456
  },
454
- dispatchException: function (exception) {
455
- if (this.done) throw exception;
456
- var context = this;
457
-
458
- function handle(loc, caught) {
459
- return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught;
457
+ dispatchException: function (e) {
458
+ if (this.done) throw e;
459
+ var r = this;
460
+ function handle(n, o) {
461
+ return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
460
462
  }
461
-
462
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
463
- var entry = this.tryEntries[i],
464
- record = entry.completion;
465
- if ("root" === entry.tryLoc) return handle("end");
466
-
467
- if (entry.tryLoc <= this.prev) {
468
- var hasCatch = hasOwn.call(entry, "catchLoc"),
469
- hasFinally = hasOwn.call(entry, "finallyLoc");
470
-
471
- if (hasCatch && hasFinally) {
472
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
473
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
474
- } else if (hasCatch) {
475
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
463
+ for (var o = this.tryEntries.length - 1; o >= 0; --o) {
464
+ var i = this.tryEntries[o],
465
+ a = i.completion;
466
+ if ("root" === i.tryLoc) return handle("end");
467
+ if (i.tryLoc <= this.prev) {
468
+ var c = n.call(i, "catchLoc"),
469
+ u = n.call(i, "finallyLoc");
470
+ if (c && u) {
471
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
472
+ if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
473
+ } else if (c) {
474
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
476
475
  } else {
477
- if (!hasFinally) throw new Error("try statement without catch or finally");
478
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
476
+ if (!u) throw Error("try statement without catch or finally");
477
+ if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
479
478
  }
480
479
  }
481
480
  }
482
481
  },
483
- abrupt: function (type, arg) {
484
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
485
- var entry = this.tryEntries[i];
486
-
487
- if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) {
488
- var finallyEntry = entry;
482
+ abrupt: function (t, e) {
483
+ for (var r = this.tryEntries.length - 1; r >= 0; --r) {
484
+ var o = this.tryEntries[r];
485
+ if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
486
+ var i = o;
489
487
  break;
490
488
  }
491
489
  }
492
-
493
- finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null);
494
- var record = finallyEntry ? finallyEntry.completion : {};
495
- return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record);
490
+ i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
491
+ var a = i ? i.completion : {};
492
+ return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
496
493
  },
497
- complete: function (record, afterLoc) {
498
- if ("throw" === record.type) throw record.arg;
499
- return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel;
494
+ complete: function (t, e) {
495
+ if ("throw" === t.type) throw t.arg;
496
+ return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
500
497
  },
501
- finish: function (finallyLoc) {
502
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
503
- var entry = this.tryEntries[i];
504
- if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel;
498
+ finish: function (t) {
499
+ for (var e = this.tryEntries.length - 1; e >= 0; --e) {
500
+ var r = this.tryEntries[e];
501
+ if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
505
502
  }
506
503
  },
507
- catch: function (tryLoc) {
508
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
509
- var entry = this.tryEntries[i];
510
-
511
- if (entry.tryLoc === tryLoc) {
512
- var record = entry.completion;
513
-
514
- if ("throw" === record.type) {
515
- var thrown = record.arg;
516
- resetTryEntry(entry);
504
+ catch: function (t) {
505
+ for (var e = this.tryEntries.length - 1; e >= 0; --e) {
506
+ var r = this.tryEntries[e];
507
+ if (r.tryLoc === t) {
508
+ var n = r.completion;
509
+ if ("throw" === n.type) {
510
+ var o = n.arg;
511
+ resetTryEntry(r);
517
512
  }
518
-
519
- return thrown;
513
+ return o;
520
514
  }
521
515
  }
522
-
523
- throw new Error("illegal catch attempt");
516
+ throw Error("illegal catch attempt");
524
517
  },
525
- delegateYield: function (iterable, resultName, nextLoc) {
518
+ delegateYield: function (e, r, n) {
526
519
  return this.delegate = {
527
- iterator: values(iterable),
528
- resultName: resultName,
529
- nextLoc: nextLoc
530
- }, "next" === this.method && (this.arg = undefined), ContinueSentinel;
520
+ iterator: values(e),
521
+ resultName: r,
522
+ nextLoc: n
523
+ }, "next" === this.method && (this.arg = t), y;
531
524
  }
532
- }, exports;
533
- }
534
-
535
- function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
536
- try {
537
- var info = gen[key](arg);
538
- var value = info.value;
539
- } catch (error) {
540
- reject(error);
541
- return;
542
- }
543
-
544
- if (info.done) {
545
- resolve(value);
546
- } else {
547
- Promise.resolve(value).then(_next, _throw);
548
- }
549
- }
550
-
551
- function _asyncToGenerator(fn) {
552
- return function () {
553
- var self = this,
554
- args = arguments;
555
- return new Promise(function (resolve, reject) {
556
- var gen = fn.apply(self, args);
557
-
558
- function _next(value) {
559
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
560
- }
561
-
562
- function _throw(err) {
563
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
564
- }
565
-
566
- _next(undefined);
567
- });
568
- };
569
- }
570
-
571
- function _extends() {
572
- _extends = Object.assign ? Object.assign.bind() : function (target) {
573
- for (var i = 1; i < arguments.length; i++) {
574
- var source = arguments[i];
575
-
576
- for (var key in source) {
577
- if (Object.prototype.hasOwnProperty.call(source, key)) {
578
- target[key] = source[key];
579
- }
580
- }
581
- }
582
-
583
- return target;
584
- };
585
- return _extends.apply(this, arguments);
586
- }
587
-
588
- function _objectDestructuringEmpty(obj) {
589
- if (obj == null) throw new TypeError("Cannot destructure undefined");
590
- }
591
-
592
- function _objectWithoutPropertiesLoose(source, excluded) {
593
- if (source == null) return {};
594
- var target = {};
595
- var sourceKeys = Object.keys(source);
596
- var key, i;
597
-
598
- for (i = 0; i < sourceKeys.length; i++) {
599
- key = sourceKeys[i];
600
- if (excluded.indexOf(key) >= 0) continue;
601
- target[key] = source[key];
602
- }
603
-
604
- return target;
525
+ }, e;
605
526
  }
606
527
 
607
528
  var _excluded = ["resourceID"],
608
- _excluded2 = ["nodeID", "showPage"],
609
- _excluded3 = ["nodeID", "showPage"],
610
- _excluded4 = ["goTo"],
611
- _excluded5 = ["goTo"],
612
- _excluded6 = ["goTo", "returnUrl"];
529
+ _excluded2 = ["nodeID", "showPage"],
530
+ _excluded3 = ["exhibitID"],
531
+ _excluded4 = ["nodeID", "showPage"],
532
+ _excluded5 = ["goTo"],
533
+ _excluded6 = ["goTo"],
534
+ _excluded7 = ["goTo", "returnUrl"];
613
535
  function home(_temp) {
614
- var _ref = _temp === void 0 ? {} : _temp;
615
-
616
- _objectDestructuringEmpty(_ref);
617
-
536
+ _objectDestructuringEmpty(_temp === void 0 ? {} : _temp);
618
537
  return "/home";
619
538
  }
620
539
  function activities(_temp2) {
621
- var _ref2 = _temp2 === void 0 ? {} : _temp2;
622
-
623
- _objectDestructuringEmpty(_ref2);
624
-
540
+ _objectDestructuringEmpty(_temp2 === void 0 ? {} : _temp2);
625
541
  return "/activities";
626
542
  }
627
543
  function activity(_ref3) {
@@ -629,308 +545,299 @@ function activity(_ref3) {
629
545
  return "/activity/" + activityID;
630
546
  }
631
547
  function dashboard(_temp3) {
632
- var _ref4 = _temp3 === void 0 ? {} : _temp3;
633
-
634
- _objectDestructuringEmpty(_ref4);
635
-
548
+ _objectDestructuringEmpty(_temp3 === void 0 ? {} : _temp3);
636
549
  return "/dashboard";
637
550
  }
638
551
  function market(_temp4) {
639
552
  var _ref5 = _temp4 === void 0 ? {} : _temp4,
640
- params = _extends({}, _ref5);
641
-
553
+ params = _extends({}, (_objectDestructuringEmpty(_ref5), _ref5));
642
554
  return "/market" + handleQuery(params);
643
555
  }
644
556
  function exampleNodes(_temp5) {
645
- var _ref6 = _temp5 === void 0 ? {} : _temp5;
646
-
647
- _objectDestructuringEmpty(_ref6);
648
-
557
+ _objectDestructuringEmpty(_temp5 === void 0 ? {} : _temp5);
649
558
  return "/examples";
650
559
  }
651
560
  function resourceDetails(_ref7) {
652
561
  var resourceID = _ref7.resourceID,
653
- params = _objectWithoutPropertiesLoose(_ref7, _excluded);
654
-
562
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded);
655
563
  return "/resource/details/" + resourceID + handleQuery(params);
656
564
  }
565
+ function collectionDetails(_ref8) {
566
+ var collectionID = _ref8.collectionID;
567
+ return "/resource/collectionDetails/" + collectionID;
568
+ }
657
569
  function resourceCreatorEntry(_temp6) {
658
- var _ref8 = _temp6 === void 0 ? {} : _temp6;
659
-
660
- _objectDestructuringEmpty(_ref8);
661
-
570
+ _objectDestructuringEmpty(_temp6 === void 0 ? {} : _temp6);
662
571
  return "/resource/creatorEntry";
663
572
  }
664
573
  function resourceCreator(_temp7) {
665
- var _ref9 = _temp7 === void 0 ? {} : _temp7;
666
-
667
- _objectDestructuringEmpty(_ref9);
668
-
574
+ _objectDestructuringEmpty(_temp7 === void 0 ? {} : _temp7);
669
575
  return "/resource/creator";
670
576
  }
671
577
  function resourceCreatorBatch(_temp8) {
672
- var _ref10 = _temp8 === void 0 ? {} : _temp8;
673
-
674
- _objectDestructuringEmpty(_ref10);
675
-
578
+ _objectDestructuringEmpty(_temp8 === void 0 ? {} : _temp8);
676
579
  return "/resource/creatorBatch";
677
580
  }
678
- function myResources(_temp9) {
679
- var _ref11 = _temp9 === void 0 ? {} : _temp9;
680
-
681
- _objectDestructuringEmpty(_ref11);
682
-
581
+ function collectionCreator(_temp9) {
582
+ _objectDestructuringEmpty(_temp9 === void 0 ? {} : _temp9);
583
+ return "/resource/collectionCreator";
584
+ }
585
+ function myResources(_temp10) {
586
+ _objectDestructuringEmpty(_temp10 === void 0 ? {} : _temp10);
683
587
  return "/resource/list";
684
588
  }
685
- function myCollects(_temp10) {
686
- var _ref12 = _temp10 === void 0 ? {} : _temp10;
687
-
688
- _objectDestructuringEmpty(_ref12);
689
-
589
+ function myCollections(_temp11) {
590
+ _objectDestructuringEmpty(_temp11 === void 0 ? {} : _temp11);
591
+ return "/resource/collection";
592
+ }
593
+ function myCollects(_temp12) {
594
+ _objectDestructuringEmpty(_temp12 === void 0 ? {} : _temp12);
690
595
  return "/resource/collect";
691
596
  }
692
- function resourceInfo(_ref13) {
693
- var resourceID = _ref13.resourceID;
597
+ function resourceVersionInfo(_ref16) {
598
+ var resourceID = _ref16.resourceID,
599
+ _ref16$version = _ref16.version,
600
+ version = _ref16$version === void 0 ? '' : _ref16$version;
601
+ return "/resource/sidebar/versionInfo/" + resourceID + handleQuery({
602
+ version: version
603
+ });
604
+ }
605
+ function resourceInfo(_ref17) {
606
+ var resourceID = _ref17.resourceID;
694
607
  return "/resource/sidebar/info/" + resourceID;
695
608
  }
696
- function resourcePolicy(_ref14) {
697
- var resourceID = _ref14.resourceID;
609
+ function resourcePolicy(_ref18) {
610
+ var resourceID = _ref18.resourceID;
698
611
  return "/resource/sidebar/policy/" + resourceID;
699
612
  }
700
- function resourceContract(_ref15) {
701
- var resourceID = _ref15.resourceID;
613
+ function resourceContract(_ref19) {
614
+ var resourceID = _ref19.resourceID;
702
615
  return "/resource/sidebar/contract/" + resourceID;
703
616
  }
704
- function resourceDependency(_ref16) {
705
- var resourceID = _ref16.resourceID;
617
+ function resourceDependency(_ref20) {
618
+ var resourceID = _ref20.resourceID;
706
619
  return "/resource/sidebar/dependency/" + resourceID;
707
620
  }
708
- function resourceVersionCreator(_ref17) {
709
- var resourceID = _ref17.resourceID;
621
+ function resourceVersionCreator(_ref21) {
622
+ var resourceID = _ref21.resourceID;
710
623
  return "/resource/versionCreator/" + resourceID;
711
624
  }
712
- function resourceVersionInfo(_ref18) {
713
- var resourceID = _ref18.resourceID,
714
- _ref18$version = _ref18.version,
715
- version = _ref18$version === void 0 ? '' : _ref18$version;
716
- return "/resource/sidebar/versionInfo/" + resourceID + handleQuery({
717
- version: version
718
- });
625
+ function collectionVersionInfo(_ref22) {
626
+ var collectionID = _ref22.collectionID;
627
+ return "/resource/collectionSidebar/versionInfo/" + collectionID;
719
628
  }
720
- function nodeCreator(_temp11) {
721
- var _ref19 = _temp11 === void 0 ? {} : _temp11;
722
-
723
- _objectDestructuringEmpty(_ref19);
724
-
629
+ function collectionInfo(_ref23) {
630
+ var collectionID = _ref23.collectionID;
631
+ return "/resource/collectionSidebar/info/" + collectionID;
632
+ }
633
+ function collectionPolicy(_ref24) {
634
+ var collectionID = _ref24.collectionID;
635
+ return "/resource/collectionSidebar/policy/" + collectionID;
636
+ }
637
+ function collectionContract(_ref25) {
638
+ var collectionID = _ref25.collectionID;
639
+ return "/resource/collectionSidebar/contract/" + collectionID;
640
+ }
641
+ function collectionDependency(_ref26) {
642
+ var collectionID = _ref26.collectionID;
643
+ return "/resource/collectionSidebar/dependency/" + collectionID;
644
+ }
645
+ function nodeCreator(_temp13) {
646
+ _objectDestructuringEmpty(_temp13 === void 0 ? {} : _temp13);
725
647
  return "/node/creator";
726
648
  }
727
- function nodeManagement(_ref20) {
728
- var nodeID = _ref20.nodeID,
729
- _ref20$showPage = _ref20.showPage,
730
- showPage = _ref20$showPage === void 0 ? 'exhibit' : _ref20$showPage,
731
- params = _objectWithoutPropertiesLoose(_ref20, _excluded2);
732
-
649
+ function nodeManagement(_ref28) {
650
+ var nodeID = _ref28.nodeID,
651
+ _ref28$showPage = _ref28.showPage,
652
+ showPage = _ref28$showPage === void 0 ? 'exhibit' : _ref28$showPage,
653
+ params = _objectWithoutPropertiesLoose(_ref28, _excluded2);
733
654
  return "/node/formal/" + nodeID + handleQuery(_extends({
734
655
  showPage: showPage
735
656
  }, params));
736
657
  }
737
- function exhibitManagement(_ref21) {
738
- var exhibitID = _ref21.exhibitID,
739
- openAuthDrawer = _ref21.openAuthDrawer;
740
- return "/node/exhibit/formal/" + exhibitID + handleQuery({
658
+ function exhibitManagement(_ref29) {
659
+ var exhibitID = _ref29.exhibitID,
660
+ params = _objectWithoutPropertiesLoose(_ref29, _excluded3);
661
+ return "/node/exhibit/formal/" + exhibitID + handleQuery(_extends({}, params));
662
+ }
663
+ function collectionExhibitManagement(_ref30) {
664
+ var exhibitID = _ref30.exhibitID,
665
+ openAuthDrawer = _ref30.openAuthDrawer;
666
+ return "/node/collectionExhibit/formal/" + exhibitID + handleQuery({
741
667
  openAuthDrawer: openAuthDrawer
742
668
  });
743
669
  }
744
- function informNodeManagement(_ref22) {
745
- var nodeID = _ref22.nodeID,
746
- _ref22$showPage = _ref22.showPage,
747
- showPage = _ref22$showPage === void 0 ? 'exhibit' : _ref22$showPage,
748
- params = _objectWithoutPropertiesLoose(_ref22, _excluded3);
749
-
670
+ function informNodeManagement(_ref31) {
671
+ var nodeID = _ref31.nodeID,
672
+ _ref31$showPage = _ref31.showPage,
673
+ showPage = _ref31$showPage === void 0 ? 'exhibit' : _ref31$showPage,
674
+ params = _objectWithoutPropertiesLoose(_ref31, _excluded4);
750
675
  return "/node/informal/" + nodeID + handleQuery(_extends({
751
676
  showPage: showPage
752
677
  }, params));
753
678
  }
754
- function informExhibitManagement(_ref23) {
755
- var exhibitID = _ref23.exhibitID;
679
+ function informExhibitManagement(_ref32) {
680
+ var exhibitID = _ref32.exhibitID;
756
681
  return "/node/exhibit/informal/" + exhibitID;
757
682
  }
758
- function storageSpace(_temp12) {
759
- var _ref24 = _temp12 === void 0 ? {} : _temp12,
760
- params = _extends({}, _ref24);
761
-
683
+ function storageSpace(_temp14) {
684
+ var _ref33 = _temp14 === void 0 ? {} : _temp14,
685
+ params = _extends({}, (_objectDestructuringEmpty(_ref33), _ref33));
762
686
  return "/storage" + handleQuery(params);
763
687
  }
764
- function objectDetails(_ref25) {
765
- var params = _extends({}, _ref25);
766
-
688
+ function objectDetails(_ref34) {
689
+ var params = _extends({}, (_objectDestructuringEmpty(_ref34), _ref34));
767
690
  return "/storage" + handleQuery(params);
768
691
  }
769
- function resourceCreateSuccess(_ref26) {
770
- var resourceID = _ref26.resourceID;
692
+ function collectionCreateSuccess(_ref35) {
693
+ var collectionID = _ref35.collectionID;
694
+ return "/result/collection/create/success/" + collectionID;
695
+ }
696
+ function resourceCreateSuccess(_ref36) {
697
+ var resourceID = _ref36.resourceID;
771
698
  return "/result/resource/create/success/" + resourceID;
772
699
  }
773
- function resourceVersionCreateSuccess(_ref27) {
774
- var resourceID = _ref27.resourceID,
775
- version = _ref27.version;
700
+ function resourceVersionCreateSuccess(_ref37) {
701
+ var resourceID = _ref37.resourceID,
702
+ version = _ref37.version;
776
703
  return "/result/resource/version/create/success/" + resourceID + "/" + version;
777
704
  }
778
- function resourceVersionCreateRelease(_ref28) {
779
- var resourceID = _ref28.resourceID,
780
- version = _ref28.version;
705
+ function resourceVersionCreateRelease(_ref38) {
706
+ var resourceID = _ref38.resourceID,
707
+ version = _ref38.version;
781
708
  return "/result/resource/version/create/release/" + resourceID + "/" + version;
782
709
  }
783
- function nodeCreateSuccess(_ref29) {
784
- var nodeID = _ref29.nodeID;
710
+ function nodeCreateSuccess(_ref39) {
711
+ var nodeID = _ref39.nodeID;
785
712
  return "/result/node/create/success/" + nodeID;
786
713
  }
787
- function invitation(_temp13) {
788
- var _ref30 = _temp13 === void 0 ? {} : _temp13,
789
- goTo = _ref30.goTo,
790
- params = _objectWithoutPropertiesLoose(_ref30, _excluded4);
791
-
714
+ function invitation(_temp15) {
715
+ var _ref40 = _temp15 === void 0 ? {} : _temp15,
716
+ goTo = _ref40.goTo,
717
+ params = _objectWithoutPropertiesLoose(_ref40, _excluded5);
792
718
  // console.log(params.goTo, 'goTo9iowjefklsdj;flksdjflk')
793
719
  return "/invitation" + handleQuery(_extends({}, params, {
794
720
  returnUrl: goTo ? encodeURIComponent(goTo) : undefined
795
721
  }));
796
722
  }
797
- function exception403(_temp14) {
798
- var _ref31 = _temp14 === void 0 ? {} : _temp14,
799
- params = _extends({}, _ref31);
800
-
723
+ function exception403(_temp16) {
724
+ var _ref41 = _temp16 === void 0 ? {} : _temp16,
725
+ params = _extends({}, (_objectDestructuringEmpty(_ref41), _ref41));
801
726
  var fromUrl = params.from || '';
802
-
803
727
  if (!fromUrl) {
804
728
  var _window$location = window.location,
805
- href = _window$location.href,
806
- origin = _window$location.origin;
729
+ href = _window$location.href,
730
+ origin = _window$location.origin;
807
731
  fromUrl = href.replace(origin, '');
808
732
  }
809
-
810
733
  return "/exception/403" + handleQuery({
811
734
  from: fromUrl
812
735
  });
813
736
  }
814
- function nodeFreeze(_ref32) {
815
- var nodeID = _ref32.nodeID;
737
+ function exceptionUnableToAccess(_temp17) {
738
+ var _ref42 = _temp17 === void 0 ? {} : _temp17,
739
+ params = _extends({}, (_objectDestructuringEmpty(_ref42), _ref42));
740
+ var fromUrl = params.from || '';
741
+ if (!fromUrl) {
742
+ var _window$location2 = window.location,
743
+ href = _window$location2.href,
744
+ origin = _window$location2.origin;
745
+ fromUrl = href.replace(origin, '');
746
+ }
747
+ return "/exception/unableToAccess" + handleQuery({
748
+ from: fromUrl
749
+ });
750
+ }
751
+ function nodeFreeze(_ref43) {
752
+ var nodeID = _ref43.nodeID;
816
753
  return "/result/node/freeze/" + nodeID;
817
754
  }
818
- function resourceFreeze(_ref33) {
819
- var resourceID = _ref33.resourceID;
755
+ function resourceFreeze(_ref44) {
756
+ var resourceID = _ref44.resourceID;
820
757
  return "/result/resource/freeze/" + resourceID;
821
758
  }
822
- function globalSearch(_ref34) {
823
- var search = _ref34.search;
759
+ function globalSearch(_ref45) {
760
+ var search = _ref45.search;
824
761
  return "/search" + handleQuery({
825
762
  search: search
826
763
  });
827
764
  }
828
- function login(_temp15) {
829
- var _ref35 = _temp15 === void 0 ? {} : _temp15,
830
- goTo = _ref35.goTo;
831
-
765
+ function login(_temp18) {
766
+ var _ref46 = _temp18 === void 0 ? {} : _temp18,
767
+ goTo = _ref46.goTo;
832
768
  return "/login" + handleQuery({
833
769
  goTo: goTo ? encodeURIComponent(goTo) : undefined
834
770
  });
835
771
  }
836
- function logon(_temp16) {
837
- var _ref36 = _temp16 === void 0 ? {} : _temp16,
838
- goTo = _ref36.goTo,
839
- params = _objectWithoutPropertiesLoose(_ref36, _excluded5);
840
-
772
+ function logon(_temp19) {
773
+ var _ref47 = _temp19 === void 0 ? {} : _temp19,
774
+ goTo = _ref47.goTo,
775
+ params = _objectWithoutPropertiesLoose(_ref47, _excluded6);
841
776
  return "/logon" + handleQuery(_extends({
842
777
  goTo: goTo ? encodeURIComponent(goTo) : undefined
843
778
  }, params));
844
779
  }
845
- function bind(_temp17) {
846
- var _ref37 = _temp17 === void 0 ? {} : _temp17,
847
- goTo = _ref37.goTo,
848
- returnUrl = _ref37.returnUrl,
849
- params = _objectWithoutPropertiesLoose(_ref37, _excluded6);
850
-
780
+ function bind(_temp20) {
781
+ var _ref48 = _temp20 === void 0 ? {} : _temp20,
782
+ goTo = _ref48.goTo,
783
+ returnUrl = _ref48.returnUrl,
784
+ params = _objectWithoutPropertiesLoose(_ref48, _excluded7);
851
785
  return "/bind" + handleQuery(_extends({
852
786
  goTo: goTo ? encodeURIComponent(goTo) : undefined,
853
787
  returnUrl: returnUrl ? encodeURIComponent(returnUrl) : undefined
854
788
  }, params));
855
789
  }
856
- function retrieveUserPassword(_temp18) {
857
- var _ref38 = _temp18 === void 0 ? {} : _temp18,
858
- goTo = _ref38.goTo;
859
-
790
+ function retrieveUserPassword(_temp21) {
791
+ var _ref49 = _temp21 === void 0 ? {} : _temp21,
792
+ goTo = _ref49.goTo;
860
793
  return "/retrieve" + handleQuery({
861
794
  goTo: goTo ? encodeURIComponent(goTo) : undefined
862
795
  });
863
796
  }
864
- function retrievePayPassword(_temp19) {
865
- var _ref39 = _temp19 === void 0 ? {} : _temp19;
866
-
867
- _objectDestructuringEmpty(_ref39);
868
-
797
+ function retrievePayPassword(_temp22) {
798
+ _objectDestructuringEmpty(_temp22 === void 0 ? {} : _temp22);
869
799
  return "/retrievePayPassword";
870
800
  }
871
- function userFreeze(_temp20) {
872
- var _ref40 = _temp20 === void 0 ? {} : _temp20;
873
-
874
- _objectDestructuringEmpty(_ref40);
875
-
801
+ function userFreeze(_temp23) {
802
+ _objectDestructuringEmpty(_temp23 === void 0 ? {} : _temp23);
876
803
  return "/freeze";
877
804
  }
878
- function wallet(_temp21) {
879
- var _ref41 = _temp21 === void 0 ? {} : _temp21;
880
-
881
- _objectDestructuringEmpty(_ref41);
882
-
805
+ function wallet(_temp24) {
806
+ _objectDestructuringEmpty(_temp24 === void 0 ? {} : _temp24);
883
807
  return "/logged/wallet";
884
808
  }
885
- function reward(_temp22) {
886
- var _ref42 = _temp22 === void 0 ? {} : _temp22;
887
-
888
- _objectDestructuringEmpty(_ref42);
889
-
809
+ function reward(_temp25) {
810
+ _objectDestructuringEmpty(_temp25 === void 0 ? {} : _temp25);
890
811
  return "/logged/reward";
891
812
  }
892
- function contract(_temp23) {
893
- var _ref43 = _temp23 === void 0 ? {} : _temp23,
894
- params = _extends({}, _ref43);
895
-
813
+ function contract(_temp26) {
814
+ var _ref54 = _temp26 === void 0 ? {} : _temp26,
815
+ params = _extends({}, (_objectDestructuringEmpty(_ref54), _ref54));
896
816
  return "/logged/contract" + handleQuery(_extends({}, params));
897
817
  }
898
- function setting(_temp24) {
899
- var _ref44 = _temp24 === void 0 ? {} : _temp24;
900
-
901
- _objectDestructuringEmpty(_ref44);
902
-
818
+ function setting(_temp27) {
819
+ _objectDestructuringEmpty(_temp27 === void 0 ? {} : _temp27);
903
820
  return "/logged/setting";
904
821
  }
905
- function binding(_temp25) {
906
- var _ref45 = _temp25 === void 0 ? {} : _temp25;
907
-
908
- _objectDestructuringEmpty(_ref45);
909
-
822
+ function binding(_temp28) {
823
+ _objectDestructuringEmpty(_temp28 === void 0 ? {} : _temp28);
910
824
  return "/logged/binding";
911
825
  }
912
- function resultBindingSuccess(_temp26) {
913
- var _ref46 = _temp26 === void 0 ? {} : _temp26;
914
-
915
- _objectDestructuringEmpty(_ref46);
916
-
826
+ function resultBindingSuccess(_temp29) {
827
+ _objectDestructuringEmpty(_temp29 === void 0 ? {} : _temp29);
917
828
  return "/result/binding";
918
829
  }
919
830
  /************** user End ******************************************************/
920
-
921
831
  function handleQuery(query) {
922
832
  var obj = {};
923
-
924
833
  for (var _i = 0, _Object$entries = Object.entries(query); _i < _Object$entries.length; _i++) {
925
834
  var _Object$entries$_i = _Object$entries[_i],
926
- key = _Object$entries$_i[0],
927
- value = _Object$entries$_i[1];
928
-
835
+ key = _Object$entries$_i[0],
836
+ value = _Object$entries$_i[1];
929
837
  if (key && value) {
930
838
  obj[key] = value;
931
839
  }
932
840
  }
933
-
934
841
  var result = querystring.stringify(obj);
935
842
  return result ? '?' + result : '';
936
843
  }
@@ -944,30 +851,41 @@ var LinkTo = {
944
851
  market: market,
945
852
  exampleNodes: exampleNodes,
946
853
  resourceDetails: resourceDetails,
854
+ collectionDetails: collectionDetails,
947
855
  resourceCreatorEntry: resourceCreatorEntry,
948
856
  resourceCreator: resourceCreator,
949
857
  resourceCreatorBatch: resourceCreatorBatch,
858
+ collectionCreator: collectionCreator,
950
859
  myResources: myResources,
860
+ myCollections: myCollections,
951
861
  myCollects: myCollects,
862
+ resourceVersionInfo: resourceVersionInfo,
952
863
  resourceInfo: resourceInfo,
953
864
  resourcePolicy: resourcePolicy,
954
865
  resourceContract: resourceContract,
955
866
  resourceDependency: resourceDependency,
956
867
  resourceVersionCreator: resourceVersionCreator,
957
- resourceVersionInfo: resourceVersionInfo,
868
+ collectionVersionInfo: collectionVersionInfo,
869
+ collectionInfo: collectionInfo,
870
+ collectionPolicy: collectionPolicy,
871
+ collectionContract: collectionContract,
872
+ collectionDependency: collectionDependency,
958
873
  nodeCreator: nodeCreator,
959
874
  nodeManagement: nodeManagement,
960
875
  exhibitManagement: exhibitManagement,
876
+ collectionExhibitManagement: collectionExhibitManagement,
961
877
  informNodeManagement: informNodeManagement,
962
878
  informExhibitManagement: informExhibitManagement,
963
879
  storageSpace: storageSpace,
964
880
  objectDetails: objectDetails,
881
+ collectionCreateSuccess: collectionCreateSuccess,
965
882
  resourceCreateSuccess: resourceCreateSuccess,
966
883
  resourceVersionCreateSuccess: resourceVersionCreateSuccess,
967
884
  resourceVersionCreateRelease: resourceVersionCreateRelease,
968
885
  nodeCreateSuccess: nodeCreateSuccess,
969
886
  invitation: invitation,
970
887
  exception403: exception403,
888
+ exceptionUnableToAccess: exceptionUnableToAccess,
971
889
  nodeFreeze: nodeFreeze,
972
890
  resourceFreeze: resourceFreeze,
973
891
  globalSearch: globalSearch,
@@ -987,38 +905,34 @@ var LinkTo = {
987
905
 
988
906
  // export const apiHost = `${window.location.protocol}//qi.${(window.location.host.match(/(?<=\.).*/) || [''])[0]}`;
989
907
  // 预设资源类型
990
- var resourceTypes = ['json', 'widget', 'image', 'audio', 'markdown', 'theme', 'reveal_slide', 'license', 'video', 'catalog']; // 全局列表加载条目数
991
-
992
- var pageSize = 100; // Moment 日期时间格式
993
-
908
+ var resourceTypes = ['json', 'widget', 'image', 'audio', 'markdown', 'theme', 'reveal_slide', 'license', 'video', 'catalog'];
909
+ // 全局列表加载条目数
910
+ var pageSize = 100;
911
+ // Moment 日期时间格式
994
912
  var momentDateFormat = 'YYYY-MM-DD';
995
- var momentDateTimeFormat = 'YYYY-MM-DD HH:mm'; // 签约方用户的身份类型定义
996
-
913
+ var momentDateTimeFormat = 'YYYY-MM-DD HH:mm';
914
+ // 签约方用户的身份类型定义
997
915
  var EnumContractPartyIdentityType;
998
-
999
916
  (function (EnumContractPartyIdentityType) {
1000
917
  EnumContractPartyIdentityType[EnumContractPartyIdentityType["resource"] = 1] = "resource";
1001
918
  EnumContractPartyIdentityType[EnumContractPartyIdentityType["node"] = 2] = "node";
1002
919
  EnumContractPartyIdentityType[EnumContractPartyIdentityType["consumer"] = 3] = "consumer";
1003
- })(EnumContractPartyIdentityType || (EnumContractPartyIdentityType = {})); // 标的物类型定义
1004
-
1005
-
920
+ })(EnumContractPartyIdentityType || (EnumContractPartyIdentityType = {}));
921
+ // 标的物类型定义
1006
922
  var EnumSubjectType;
1007
-
1008
923
  (function (EnumSubjectType) {
1009
924
  EnumSubjectType[EnumSubjectType["resource"] = 1] = "resource";
1010
925
  EnumSubjectType[EnumSubjectType["exhibit"] = 2] = "exhibit";
1011
926
  EnumSubjectType[EnumSubjectType["user"] = 3] = "user";
1012
- })(EnumSubjectType || (EnumSubjectType = {})); // 合约状态定义
1013
-
1014
-
927
+ })(EnumSubjectType || (EnumSubjectType = {}));
928
+ // 合约状态定义
1015
929
  var EnumContractStatus;
1016
-
1017
930
  (function (EnumContractStatus) {
1018
931
  EnumContractStatus[EnumContractStatus["pending"] = 0] = "pending";
1019
932
  EnumContractStatus[EnumContractStatus["authorized"] = 1] = "authorized";
1020
933
  EnumContractStatus[EnumContractStatus["stopped"] = 2] = "stopped";
1021
- })(EnumContractStatus || (EnumContractStatus = {})); // 合约授权状态定义
934
+ })(EnumContractStatus || (EnumContractStatus = {}));
935
+ // 合约授权状态定义
1022
936
  // export enum ContractAuthStatus {
1023
937
  //
1024
938
  // }
@@ -1049,11 +963,10 @@ function details(params) {
1049
963
  method: 'GET',
1050
964
  url: "/v2/nodes/" + params.nodeId
1051
965
  });
1052
- } // return FUtil.Axios.get(`/v2/nodes/detail`, {
966
+ }
967
+ // return FUtil.Axios.get(`/v2/nodes/detail`, {
1053
968
  // params,
1054
969
  // });
1055
-
1056
-
1057
970
  return FUtil.Request({
1058
971
  method: 'GET',
1059
972
  url: "/v2/nodes/detail",
@@ -1081,6 +994,13 @@ function setNodeInfo(params) {
1081
994
  data: params
1082
995
  });
1083
996
  }
997
+ function deleteNode(_ref) {
998
+ var nodeId = _ref.nodeId;
999
+ return FUtil.Request({
1000
+ method: 'DELETE',
1001
+ url: "/v2/nodes/" + nodeId
1002
+ });
1003
+ }
1084
1004
 
1085
1005
  var Node = {
1086
1006
  __proto__: null,
@@ -1088,19 +1008,21 @@ var Node = {
1088
1008
  details: details,
1089
1009
  nodes: nodes,
1090
1010
  searchForClient: searchForClient,
1091
- setNodeInfo: setNodeInfo
1011
+ setNodeInfo: setNodeInfo,
1012
+ deleteNode: deleteNode
1092
1013
  };
1093
1014
 
1094
1015
  var _excluded$1 = ["presentableId"],
1095
- _excluded2$1 = ["presentableId"],
1096
- _excluded3$1 = ["presentableId"],
1097
- _excluded4$1 = ["presentableId"],
1098
- _excluded5$1 = ["presentableId"],
1099
- _excluded6$1 = ["presentableId"],
1100
- _excluded7 = ["presentableId"],
1101
- _excluded8 = ["presentableId"],
1102
- _excluded9 = ["nodeId"],
1103
- _excluded10 = ["nodeId"];
1016
+ _excluded2$1 = ["presentableId"],
1017
+ _excluded3$1 = ["presentableId"],
1018
+ _excluded4$1 = ["presentableId"],
1019
+ _excluded5$1 = ["presentableId"],
1020
+ _excluded6$1 = ["presentableId"],
1021
+ _excluded7$1 = ["presentableId"],
1022
+ _excluded8 = ["presentableId"],
1023
+ _excluded9 = ["nodeId"],
1024
+ _excluded10 = ["nodeId"],
1025
+ _excluded11 = ["presentableId"];
1104
1026
  function createPresentable(params) {
1105
1027
  return FUtil.Request({
1106
1028
  method: 'POST',
@@ -1110,8 +1032,7 @@ function createPresentable(params) {
1110
1032
  }
1111
1033
  function updatePresentable(_ref) {
1112
1034
  var presentableId = _ref.presentableId,
1113
- params = _objectWithoutPropertiesLoose(_ref, _excluded$1);
1114
-
1035
+ params = _objectWithoutPropertiesLoose(_ref, _excluded$1);
1115
1036
  return FUtil.Request({
1116
1037
  method: 'PUT',
1117
1038
  url: "/v2/presentables/" + presentableId,
@@ -1120,8 +1041,7 @@ function updatePresentable(_ref) {
1120
1041
  }
1121
1042
  function presentablesOnlineStatus(_ref2) {
1122
1043
  var presentableId = _ref2.presentableId,
1123
- params = _objectWithoutPropertiesLoose(_ref2, _excluded2$1);
1124
-
1044
+ params = _objectWithoutPropertiesLoose(_ref2, _excluded2$1);
1125
1045
  return FUtil.Request({
1126
1046
  method: 'PUT',
1127
1047
  url: "/v2/presentables/" + presentableId + "/onlineStatus",
@@ -1136,10 +1056,8 @@ function presentableDetails(params) {
1136
1056
  params: params
1137
1057
  });
1138
1058
  }
1139
-
1140
1059
  var presentableId = params.presentableId,
1141
- p = _objectWithoutPropertiesLoose(params, _excluded3$1);
1142
-
1060
+ p = _objectWithoutPropertiesLoose(params, _excluded3$1);
1143
1061
  return FUtil.Request({
1144
1062
  method: 'GET',
1145
1063
  url: "/v2/presentables/" + presentableId,
@@ -1162,8 +1080,7 @@ function presentableList(params) {
1162
1080
  }
1163
1081
  function dependencyTree(_ref3) {
1164
1082
  var presentableId = _ref3.presentableId,
1165
- params = _objectWithoutPropertiesLoose(_ref3, _excluded4$1);
1166
-
1083
+ params = _objectWithoutPropertiesLoose(_ref3, _excluded4$1);
1167
1084
  return FUtil.Request({
1168
1085
  method: 'GET',
1169
1086
  url: "/v2/presentables/" + presentableId + "/dependencyTree",
@@ -1172,8 +1089,7 @@ function dependencyTree(_ref3) {
1172
1089
  }
1173
1090
  function relationTree(_ref4) {
1174
1091
  var presentableId = _ref4.presentableId,
1175
- params = _objectWithoutPropertiesLoose(_ref4, _excluded5$1);
1176
-
1092
+ params = _objectWithoutPropertiesLoose(_ref4, _excluded5$1);
1177
1093
  return FUtil.Request({
1178
1094
  method: 'GET',
1179
1095
  url: "/v2/presentables/" + presentableId + "/relationTree",
@@ -1182,8 +1098,7 @@ function relationTree(_ref4) {
1182
1098
  }
1183
1099
  function authTree(_ref5) {
1184
1100
  var presentableId = _ref5.presentableId,
1185
- params = _objectWithoutPropertiesLoose(_ref5, _excluded6$1);
1186
-
1101
+ params = _objectWithoutPropertiesLoose(_ref5, _excluded6$1);
1187
1102
  return FUtil.Request({
1188
1103
  method: 'GET',
1189
1104
  url: "/v2/presentables/" + presentableId + "/authTree",
@@ -1192,8 +1107,7 @@ function authTree(_ref5) {
1192
1107
  }
1193
1108
  function presentablesVersion(_ref6) {
1194
1109
  var presentableId = _ref6.presentableId,
1195
- params = _objectWithoutPropertiesLoose(_ref6, _excluded7);
1196
-
1110
+ params = _objectWithoutPropertiesLoose(_ref6, _excluded7$1);
1197
1111
  return FUtil.Request({
1198
1112
  method: 'PUT',
1199
1113
  url: "/v2/presentables/" + presentableId + "/version",
@@ -1202,8 +1116,7 @@ function presentablesVersion(_ref6) {
1202
1116
  }
1203
1117
  function updateRewriteProperty(_ref7) {
1204
1118
  var presentableId = _ref7.presentableId,
1205
- params = _objectWithoutPropertiesLoose(_ref7, _excluded8);
1206
-
1119
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded8);
1207
1120
  return FUtil.Request({
1208
1121
  method: 'PUT',
1209
1122
  url: "/v2/presentables/" + presentableId + "/rewriteProperty",
@@ -1212,8 +1125,7 @@ function updateRewriteProperty(_ref7) {
1212
1125
  }
1213
1126
  function batchAuth(_ref8) {
1214
1127
  var nodeId = _ref8.nodeId,
1215
- params = _objectWithoutPropertiesLoose(_ref8, _excluded9);
1216
-
1128
+ params = _objectWithoutPropertiesLoose(_ref8, _excluded9);
1217
1129
  return FUtil.Request({
1218
1130
  method: 'GET',
1219
1131
  url: "/v2/auths/presentables/nodes/" + nodeId + "/batchAuth/result",
@@ -1222,8 +1134,7 @@ function batchAuth(_ref8) {
1222
1134
  }
1223
1135
  function contractAppliedPresentable(_ref9) {
1224
1136
  var nodeId = _ref9.nodeId,
1225
- params = _objectWithoutPropertiesLoose(_ref9, _excluded10);
1226
-
1137
+ params = _objectWithoutPropertiesLoose(_ref9, _excluded10);
1227
1138
  return FUtil.Request({
1228
1139
  method: 'GET',
1229
1140
  url: "/v2/presentables/" + nodeId + "/contractAppliedPresentable",
@@ -1238,8 +1149,7 @@ function batchCreatePresentable(params) {
1238
1149
  });
1239
1150
  }
1240
1151
  function batchUpdatePresentable(_ref10) {
1241
- var params = _extends({}, _ref10);
1242
-
1152
+ var params = _extends({}, (_objectDestructuringEmpty(_ref10), _ref10));
1243
1153
  return FUtil.Request({
1244
1154
  method: 'PUT',
1245
1155
  url: "/v2/presentables/updatePresentableBatch",
@@ -1247,14 +1157,22 @@ function batchUpdatePresentable(_ref10) {
1247
1157
  });
1248
1158
  }
1249
1159
  function batchUpdatePresentableStatus(_ref11) {
1250
- var params = _extends({}, _ref11);
1251
-
1160
+ var params = _extends({}, (_objectDestructuringEmpty(_ref11), _ref11));
1252
1161
  return FUtil.Request({
1253
1162
  method: 'PUT',
1254
1163
  url: "/v2/presentables/updatePresentableOnlineStatusBatch",
1255
1164
  data: params
1256
1165
  });
1257
1166
  }
1167
+ function ignorePresentableVersionUpdateTip(_ref12) {
1168
+ var presentableId = _ref12.presentableId,
1169
+ params = _objectWithoutPropertiesLoose(_ref12, _excluded11);
1170
+ return FUtil.Request({
1171
+ method: 'POST',
1172
+ url: "/v2/presentables/" + presentableId + "/ignorePresentableVersionUpdateTip",
1173
+ data: params
1174
+ });
1175
+ }
1258
1176
 
1259
1177
  var Exhibit = {
1260
1178
  __proto__: null,
@@ -1273,14 +1191,15 @@ var Exhibit = {
1273
1191
  contractAppliedPresentable: contractAppliedPresentable,
1274
1192
  batchCreatePresentable: batchCreatePresentable,
1275
1193
  batchUpdatePresentable: batchUpdatePresentable,
1276
- batchUpdatePresentableStatus: batchUpdatePresentableStatus
1194
+ batchUpdatePresentableStatus: batchUpdatePresentableStatus,
1195
+ ignorePresentableVersionUpdateTip: ignorePresentableVersionUpdateTip
1277
1196
  };
1278
1197
 
1279
1198
  var _excluded$2 = ["bucketName"],
1280
- _excluded2$2 = ["bucketName"],
1281
- _excluded3$2 = ["objectIdOrName"],
1282
- _excluded4$2 = ["sha1"],
1283
- _excluded5$2 = ["objectIdOrName"];
1199
+ _excluded2$2 = ["bucketName"],
1200
+ _excluded3$2 = ["objectIdOrName"],
1201
+ _excluded4$2 = ["sha1"],
1202
+ _excluded5$2 = ["objectIdOrName"];
1284
1203
  function createBucket(params) {
1285
1204
  return FUtil.Request({
1286
1205
  method: 'POST',
@@ -1299,7 +1218,6 @@ function spaceStatistics(params) {
1299
1218
  if (params === void 0) {
1300
1219
  params = {};
1301
1220
  }
1302
-
1303
1221
  return FUtil.Request({
1304
1222
  method: 'GET',
1305
1223
  url: "/v2/storages/buckets/spaceStatistics",
@@ -1321,8 +1239,7 @@ function bucketDetails(_ref) {
1321
1239
  }
1322
1240
  function objectList(_ref2) {
1323
1241
  var bucketName = _ref2.bucketName,
1324
- params = _objectWithoutPropertiesLoose(_ref2, _excluded$2);
1325
-
1242
+ params = _objectWithoutPropertiesLoose(_ref2, _excluded$2);
1326
1243
  return FUtil.Request({
1327
1244
  method: 'GET',
1328
1245
  url: "/v2/storages/buckets/" + bucketName + "/objects",
@@ -1338,8 +1255,7 @@ function userNodeDataList(params) {
1338
1255
  }
1339
1256
  function createObject(_ref3) {
1340
1257
  var bucketName = _ref3.bucketName,
1341
- params = _objectWithoutPropertiesLoose(_ref3, _excluded2$2);
1342
-
1258
+ params = _objectWithoutPropertiesLoose(_ref3, _excluded2$2);
1343
1259
  return FUtil.Request({
1344
1260
  method: 'POST',
1345
1261
  url: "/v2/storages/buckets/" + bucketName + "/objects",
@@ -1354,7 +1270,6 @@ function objectDetails$1(params) {
1354
1270
  params: params
1355
1271
  });
1356
1272
  }
1357
-
1358
1273
  return FUtil.Request({
1359
1274
  method: 'GET',
1360
1275
  url: "/v2/storages/buckets/" + params.bucketName + "/objects/" + params.objectId,
@@ -1389,19 +1304,15 @@ function uploadFile(params, config, returnCancel) {
1389
1304
  if (returnCancel === void 0) {
1390
1305
  returnCancel = false;
1391
1306
  }
1392
-
1393
1307
  var formData = new FormData();
1394
-
1395
1308
  for (var _i = 0, _Object$entries = Object.entries(params); _i < _Object$entries.length; _i++) {
1396
1309
  var _Object$entries$_i = _Object$entries[_i],
1397
- key = _Object$entries$_i[0],
1398
- value = _Object$entries$_i[1];
1399
-
1310
+ key = _Object$entries$_i[0],
1311
+ value = _Object$entries$_i[1];
1400
1312
  if (value) {
1401
1313
  formData.append(key, value);
1402
1314
  }
1403
1315
  }
1404
-
1405
1316
  if (!returnCancel) {
1406
1317
  // return FUtil.Axios.post('/v2/storages/files/upload', formData, config);
1407
1318
  return FUtil.Request(_extends({
@@ -1410,13 +1321,12 @@ function uploadFile(params, config, returnCancel) {
1410
1321
  data: formData
1411
1322
  }, config));
1412
1323
  }
1413
-
1414
- var cancel = null; // const promise = FUtil.Axios.post('/v2/storages/files/upload', formData, {
1324
+ var cancel = null;
1325
+ // const promise = FUtil.Axios.post('/v2/storages/files/upload', formData, {
1415
1326
  // cancelToken: new FUtil.Axios.CancelToken((c) => {
1416
1327
  // cancel = c;
1417
1328
  // }),
1418
1329
  // });
1419
-
1420
1330
  var promise = FUtil.Request(_extends({
1421
1331
  method: 'POST',
1422
1332
  url: "/v2/storages/files/upload",
@@ -1429,17 +1339,14 @@ function uploadFile(params, config, returnCancel) {
1429
1339
  }
1430
1340
  function uploadImage(params, config) {
1431
1341
  var formData = new FormData();
1432
-
1433
1342
  for (var _i2 = 0, _Object$entries2 = Object.entries(params); _i2 < _Object$entries2.length; _i2++) {
1434
1343
  var _Object$entries2$_i = _Object$entries2[_i2],
1435
- key = _Object$entries2$_i[0],
1436
- value = _Object$entries2$_i[1];
1437
-
1344
+ key = _Object$entries2$_i[0],
1345
+ value = _Object$entries2$_i[1];
1438
1346
  if (value) {
1439
1347
  formData.append(key, value);
1440
1348
  }
1441
1349
  }
1442
-
1443
1350
  return FUtil.Request(_extends({
1444
1351
  method: 'POST',
1445
1352
  url: "/v2/storages/files/uploadImage",
@@ -1462,8 +1369,7 @@ function generateCoverImage(params) {
1462
1369
  }
1463
1370
  function updateObject(_ref5) {
1464
1371
  var objectIdOrName = _ref5.objectIdOrName,
1465
- params = _objectWithoutPropertiesLoose(_ref5, _excluded3$2);
1466
-
1372
+ params = _objectWithoutPropertiesLoose(_ref5, _excluded3$2);
1467
1373
  return FUtil.Request({
1468
1374
  method: 'PUT',
1469
1375
  url: "/v2/storages/objects/" + objectIdOrName,
@@ -1471,8 +1377,7 @@ function updateObject(_ref5) {
1471
1377
  });
1472
1378
  }
1473
1379
  function batchUpdateObject(_ref6) {
1474
- var params = _extends({}, _ref6);
1475
-
1380
+ var params = _extends({}, (_objectDestructuringEmpty(_ref6), _ref6));
1476
1381
  return FUtil.Request({
1477
1382
  method: 'PUT',
1478
1383
  url: "/v2/storages/objects/updateBatch",
@@ -1488,8 +1393,7 @@ function batchObjectList(params) {
1488
1393
  }
1489
1394
  function fileProperty(_ref7) {
1490
1395
  var sha1 = _ref7.sha1,
1491
- params = _objectWithoutPropertiesLoose(_ref7, _excluded4$2);
1492
-
1396
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded4$2);
1493
1397
  return FUtil.Request({
1494
1398
  method: 'GET',
1495
1399
  url: "/v2/storages/files/" + sha1 + "/property",
@@ -1498,8 +1402,7 @@ function fileProperty(_ref7) {
1498
1402
  }
1499
1403
  function cycleDependencyCheck(_ref8) {
1500
1404
  var objectIdOrName = _ref8.objectIdOrName,
1501
- params = _objectWithoutPropertiesLoose(_ref8, _excluded5$2);
1502
-
1405
+ params = _objectWithoutPropertiesLoose(_ref8, _excluded5$2);
1503
1406
  return FUtil.Request({
1504
1407
  method: 'POST',
1505
1408
  url: "/v2/storages/objects/" + objectIdOrName + "/cycleDependencyCheck",
@@ -1507,8 +1410,7 @@ function cycleDependencyCheck(_ref8) {
1507
1410
  });
1508
1411
  }
1509
1412
  function clearUserNodeData(_ref9) {
1510
- var params = _extends({}, _ref9);
1511
-
1413
+ var params = _extends({}, (_objectDestructuringEmpty(_ref9), _ref9));
1512
1414
  return FUtil.Request({
1513
1415
  method: 'DELETE',
1514
1416
  url: "/v2/storages/buckets/.UserNodeData/objects/clear",
@@ -1516,14 +1418,21 @@ function clearUserNodeData(_ref9) {
1516
1418
  });
1517
1419
  }
1518
1420
  function filesListInfo(_ref10) {
1519
- var params = _extends({}, _ref10);
1520
-
1421
+ var params = _extends({}, (_objectDestructuringEmpty(_ref10), _ref10));
1521
1422
  return FUtil.Request({
1522
1423
  method: 'GET',
1523
1424
  url: "/v2/storages/files/list/info",
1524
1425
  params: params
1525
1426
  });
1526
1427
  }
1428
+ function filesInfo(_ref11) {
1429
+ var params = _extends({}, (_objectDestructuringEmpty(_ref11), _ref11));
1430
+ return FUtil.Request({
1431
+ method: 'GET',
1432
+ url: "/v2/storages/files/info",
1433
+ params: params
1434
+ });
1435
+ }
1527
1436
 
1528
1437
  var Storage = {
1529
1438
  __proto__: null,
@@ -1550,7 +1459,8 @@ var Storage = {
1550
1459
  fileProperty: fileProperty,
1551
1460
  cycleDependencyCheck: cycleDependencyCheck,
1552
1461
  clearUserNodeData: clearUserNodeData,
1553
- filesListInfo: filesListInfo
1462
+ filesListInfo: filesListInfo,
1463
+ filesInfo: filesInfo
1554
1464
  };
1555
1465
 
1556
1466
  function collectResource(params) {
@@ -1605,17 +1515,31 @@ var Collection = {
1605
1515
  };
1606
1516
 
1607
1517
  var _excluded$3 = ["resourceIdOrName"],
1608
- _excluded2$3 = ["resourceId"],
1609
- _excluded3$3 = ["resourceId"],
1610
- _excluded4$3 = ["resourceId"],
1611
- _excluded5$3 = ["resourceId", "version"],
1612
- _excluded6$2 = ["fileSha1"],
1613
- _excluded7$1 = ["fileSha1"],
1614
- _excluded8$1 = ["resourceId"],
1615
- _excluded9$1 = ["resourceId"],
1616
- _excluded10$1 = ["resourceId"],
1617
- _excluded11 = ["resourceId"],
1618
- _excluded12 = ["resourceId"];
1518
+ _excluded2$3 = ["resourceId"],
1519
+ _excluded3$3 = ["resourceId"],
1520
+ _excluded4$3 = ["resourceId"],
1521
+ _excluded5$3 = ["resourceId", "version"],
1522
+ _excluded6$2 = ["fileSha1"],
1523
+ _excluded7$2 = ["fileSha1"],
1524
+ _excluded8$1 = ["resourceId"],
1525
+ _excluded9$1 = ["resourceId"],
1526
+ _excluded10$1 = ["resourceId"],
1527
+ _excluded11$1 = ["resourceId"],
1528
+ _excluded12 = ["resourceId"],
1529
+ _excluded13 = ["resourceId"],
1530
+ _excluded14 = ["resourceId"],
1531
+ _excluded15 = ["resourceId"],
1532
+ _excluded16 = ["resourceId"],
1533
+ _excluded17 = ["resourceId"],
1534
+ _excluded18 = ["resourceId"],
1535
+ _excluded19 = ["resourceId"],
1536
+ _excluded20 = ["resourceId"],
1537
+ _excluded21 = ["resourceId"],
1538
+ _excluded22 = ["resourceId"],
1539
+ _excluded23 = ["resourceId"],
1540
+ _excluded24 = ["resourceId", "itemId"],
1541
+ _excluded25 = ["resourceId"],
1542
+ _excluded26 = ["resourceId"];
1619
1543
  function create$1(params) {
1620
1544
  return FUtil.Request({
1621
1545
  method: 'POST',
@@ -1643,10 +1567,10 @@ function batchUpdate(params) {
1643
1567
  url: "/v2/resources/updateBatch",
1644
1568
  data: params
1645
1569
  });
1646
- } // interface ListReturnType extends CommonReturn {
1570
+ }
1571
+ // interface ListReturnType extends CommonReturn {
1647
1572
  // data: IResourceInfo[];
1648
1573
  // }
1649
-
1650
1574
  function list(params) {
1651
1575
  return FUtil.Request({
1652
1576
  method: 'GET',
@@ -1656,8 +1580,7 @@ function list(params) {
1656
1580
  }
1657
1581
  function info(_ref) {
1658
1582
  var resourceIdOrName = _ref.resourceIdOrName,
1659
- params = _objectWithoutPropertiesLoose(_ref, _excluded$3);
1660
-
1583
+ params = _objectWithoutPropertiesLoose(_ref, _excluded$3);
1661
1584
  return FUtil.Request({
1662
1585
  method: 'GET',
1663
1586
  url: "/v2/resources/" + encodeURIComponent(resourceIdOrName),
@@ -1673,8 +1596,7 @@ function batchInfo(params) {
1673
1596
  }
1674
1597
  function dependencyTree$1(_ref2) {
1675
1598
  var resourceId = _ref2.resourceId,
1676
- params = _objectWithoutPropertiesLoose(_ref2, _excluded2$3);
1677
-
1599
+ params = _objectWithoutPropertiesLoose(_ref2, _excluded2$3);
1678
1600
  return FUtil.Request({
1679
1601
  method: 'GET',
1680
1602
  url: "/v2/resources/" + resourceId + "/dependencyTree",
@@ -1683,8 +1605,7 @@ function dependencyTree$1(_ref2) {
1683
1605
  }
1684
1606
  function authTree$1(_ref3) {
1685
1607
  var resourceId = _ref3.resourceId,
1686
- params = _objectWithoutPropertiesLoose(_ref3, _excluded3$3);
1687
-
1608
+ params = _objectWithoutPropertiesLoose(_ref3, _excluded3$3);
1688
1609
  return FUtil.Request({
1689
1610
  method: 'GET',
1690
1611
  url: "/v2/resources/" + resourceId + "/authTree",
@@ -1693,8 +1614,7 @@ function authTree$1(_ref3) {
1693
1614
  }
1694
1615
  function createVersion(_ref4) {
1695
1616
  var resourceId = _ref4.resourceId,
1696
- params = _objectWithoutPropertiesLoose(_ref4, _excluded4$3);
1697
-
1617
+ params = _objectWithoutPropertiesLoose(_ref4, _excluded4$3);
1698
1618
  // return FUtil.Axios.post(`/v2/resources/${resourceId}/versions`, params);
1699
1619
  return FUtil.Request({
1700
1620
  method: 'POST',
@@ -1704,9 +1624,8 @@ function createVersion(_ref4) {
1704
1624
  }
1705
1625
  function resourceVersionInfo1(_ref5) {
1706
1626
  var resourceId = _ref5.resourceId,
1707
- version = _ref5.version,
1708
- params = _objectWithoutPropertiesLoose(_ref5, _excluded5$3);
1709
-
1627
+ version = _ref5.version,
1628
+ params = _objectWithoutPropertiesLoose(_ref5, _excluded5$3);
1710
1629
  return FUtil.Request({
1711
1630
  method: 'GET',
1712
1631
  url: "/v2/resources/" + resourceId + "/versions/" + version,
@@ -1721,8 +1640,7 @@ function resourceVersionInfo2(params) {
1721
1640
  });
1722
1641
  }
1723
1642
  function getVersionList(_ref6) {
1724
- var params = _extends({}, _ref6);
1725
-
1643
+ var params = _extends({}, (_objectDestructuringEmpty(_ref6), _ref6));
1726
1644
  return FUtil.Request({
1727
1645
  method: 'GET',
1728
1646
  url: "/v2/resources/versions/list",
@@ -1731,8 +1649,7 @@ function getVersionList(_ref6) {
1731
1649
  }
1732
1650
  function getResourceVersionBySha1(_ref7) {
1733
1651
  var fileSha1 = _ref7.fileSha1,
1734
- params = _objectWithoutPropertiesLoose(_ref7, _excluded6$2);
1735
-
1652
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded6$2);
1736
1653
  return FUtil.Request({
1737
1654
  method: 'GET',
1738
1655
  url: "/v2/resources/files/" + fileSha1 + "/versions",
@@ -1741,8 +1658,7 @@ function getResourceVersionBySha1(_ref7) {
1741
1658
  }
1742
1659
  function getResourceBySha1(_ref8) {
1743
1660
  var fileSha1 = _ref8.fileSha1,
1744
- params = _objectWithoutPropertiesLoose(_ref8, _excluded7$1);
1745
-
1661
+ params = _objectWithoutPropertiesLoose(_ref8, _excluded7$2);
1746
1662
  // return FUtil.Axios.get(`/v2/resources/files/${fileSha1}`, {
1747
1663
  // params,
1748
1664
  // });
@@ -1795,14 +1711,14 @@ function resourceIsUsedByOther(params) {
1795
1711
  });
1796
1712
  }
1797
1713
  function resourcesDownload(params) {
1798
- return window.location.href = FUtil.Format.completeUrlByDomain('api') + ("/v2/resources/" + params.resourceId + "/versions/" + params.version + "/download"); // return request.get(`/v2/resources/${params.resourceId}/versions/${params.$version}/download`, {
1714
+ return window.location.href = FUtil.Format.completeUrlByDomain('api') + ("/v2/resources/" + params.resourceId + "/versions/" + params.version + "/download");
1715
+ // return request.get(`/v2/resources/${params.resourceId}/versions/${params.$version}/download`, {
1799
1716
  // responseType: 'arraybuffer',
1800
1717
  // });
1801
1718
  }
1802
1719
  function batchGetCoverageVersions(_ref10) {
1803
1720
  var resourceId = _ref10.resourceId,
1804
- params = _objectWithoutPropertiesLoose(_ref10, _excluded8$1);
1805
-
1721
+ params = _objectWithoutPropertiesLoose(_ref10, _excluded8$1);
1806
1722
  // return FUtil.Axios.get(`/v2/resources/${resourceId}/contracts/coverageVersions`, {
1807
1723
  // params,
1808
1724
  // });
@@ -1821,8 +1737,7 @@ function resolveResources(params) {
1821
1737
  }
1822
1738
  function batchSetContracts(_ref11) {
1823
1739
  var resourceId = _ref11.resourceId,
1824
- params = _objectWithoutPropertiesLoose(_ref11, _excluded9$1);
1825
-
1740
+ params = _objectWithoutPropertiesLoose(_ref11, _excluded9$1);
1826
1741
  // return FUtil.Axios.put(`/v2/resources/${resourceId}/versions/batchSetContracts`, params);
1827
1742
  return FUtil.Request({
1828
1743
  method: 'PUT',
@@ -1832,8 +1747,7 @@ function batchSetContracts(_ref11) {
1832
1747
  }
1833
1748
  function cycleDependencyCheck$1(_ref12) {
1834
1749
  var resourceId = _ref12.resourceId,
1835
- params = _objectWithoutPropertiesLoose(_ref12, _excluded10$1);
1836
-
1750
+ params = _objectWithoutPropertiesLoose(_ref12, _excluded10$1);
1837
1751
  // return FUtil.Axios.post(`/v2/resources/${resourceId}/versions/cycleDependencyCheck`, params);
1838
1752
  return FUtil.Request({
1839
1753
  method: 'POST',
@@ -1843,8 +1757,7 @@ function cycleDependencyCheck$1(_ref12) {
1843
1757
  }
1844
1758
  function relationTree$1(_ref13) {
1845
1759
  var resourceId = _ref13.resourceId,
1846
- params = _objectWithoutPropertiesLoose(_ref13, _excluded11);
1847
-
1760
+ params = _objectWithoutPropertiesLoose(_ref13, _excluded11$1);
1848
1761
  // return FUtil.Axios.get(`/v2/resources/${resourceId}/relationTree`, {
1849
1762
  // params,
1850
1763
  // });
@@ -1856,8 +1769,7 @@ function relationTree$1(_ref13) {
1856
1769
  }
1857
1770
  function relationTreeAuth(_ref14) {
1858
1771
  var resourceId = _ref14.resourceId,
1859
- params = _objectWithoutPropertiesLoose(_ref14, _excluded12);
1860
-
1772
+ params = _objectWithoutPropertiesLoose(_ref14, _excluded12);
1861
1773
  return FUtil.Request({
1862
1774
  method: 'GET',
1863
1775
  url: "/v2/auths/resources/" + resourceId + "/relationTreeAuth",
@@ -1865,8 +1777,7 @@ function relationTreeAuth(_ref14) {
1865
1777
  });
1866
1778
  }
1867
1779
  function resourcesCount(_ref15) {
1868
- var params = _extends({}, _ref15);
1869
-
1780
+ var params = _extends({}, (_objectDestructuringEmpty(_ref15), _ref15));
1870
1781
  return FUtil.Request({
1871
1782
  method: 'GET',
1872
1783
  url: "/v2/resources/count",
@@ -1874,8 +1785,7 @@ function resourcesCount(_ref15) {
1874
1785
  });
1875
1786
  }
1876
1787
  function batchAuth$1(_ref16) {
1877
- var params = _extends({}, _ref16);
1878
-
1788
+ var params = _extends({}, (_objectDestructuringEmpty(_ref16), _ref16));
1879
1789
  return FUtil.Request({
1880
1790
  method: 'GET',
1881
1791
  url: "/v2/auths/resources/batchAuth/results",
@@ -1883,8 +1793,7 @@ function batchAuth$1(_ref16) {
1883
1793
  });
1884
1794
  }
1885
1795
  function resourcesRecommend(_ref17) {
1886
- var params = _extends({}, _ref17);
1887
-
1796
+ var params = _extends({}, (_objectDestructuringEmpty(_ref17), _ref17));
1888
1797
  return FUtil.Request({
1889
1798
  method: 'GET',
1890
1799
  url: "/v2/resources/recommend",
@@ -1892,8 +1801,7 @@ function resourcesRecommend(_ref17) {
1892
1801
  });
1893
1802
  }
1894
1803
  function availableTags(_ref18) {
1895
- var params = _extends({}, _ref18);
1896
-
1804
+ var params = _extends({}, (_objectDestructuringEmpty(_ref18), _ref18));
1897
1805
  return FUtil.Request({
1898
1806
  method: 'GET',
1899
1807
  url: "/v2/resources/tags/availableTags",
@@ -1902,8 +1810,7 @@ function availableTags(_ref18) {
1902
1810
  }
1903
1811
  function resourceTypes$1(_temp) {
1904
1812
  var _ref19 = _temp === void 0 ? {} : _temp,
1905
- params = _extends({}, _ref19);
1906
-
1813
+ params = _extends({}, (_objectDestructuringEmpty(_ref19), _ref19));
1907
1814
  return FUtil.Request({
1908
1815
  method: 'GET',
1909
1816
  url: "/v2/resources/types/listSimpleByGroup",
@@ -1911,8 +1818,7 @@ function resourceTypes$1(_temp) {
1911
1818
  });
1912
1819
  }
1913
1820
  function ListSimpleByParentCode(_ref20) {
1914
- var params = _extends({}, _ref20);
1915
-
1821
+ var params = _extends({}, (_objectDestructuringEmpty(_ref20), _ref20));
1916
1822
  return FUtil.Request({
1917
1823
  method: 'GET',
1918
1824
  url: "/v2/resources/types/listSimpleByParentCode",
@@ -1920,8 +1826,7 @@ function ListSimpleByParentCode(_ref20) {
1920
1826
  });
1921
1827
  }
1922
1828
  function getResourceTypeInfoByCode(_ref21) {
1923
- var params = _extends({}, _ref21);
1924
-
1829
+ var params = _extends({}, (_objectDestructuringEmpty(_ref21), _ref21));
1925
1830
  return FUtil.Request({
1926
1831
  method: 'GET',
1927
1832
  url: "/v2/resources/types/getInfoByCode",
@@ -1929,8 +1834,7 @@ function getResourceTypeInfoByCode(_ref21) {
1929
1834
  });
1930
1835
  }
1931
1836
  function getResourceAttrListSimple(_ref22) {
1932
- var params = _extends({}, _ref22);
1933
-
1837
+ var params = _extends({}, (_objectDestructuringEmpty(_ref22), _ref22));
1934
1838
  return FUtil.Request({
1935
1839
  method: 'GET',
1936
1840
  url: "/v2/resources/attrs/listSimple",
@@ -1939,8 +1843,7 @@ function getResourceAttrListSimple(_ref22) {
1939
1843
  }
1940
1844
  function listSimple4Recently(_temp2) {
1941
1845
  var _ref23 = _temp2 === void 0 ? {} : _temp2,
1942
- params = _extends({}, _ref23);
1943
-
1846
+ params = _extends({}, (_objectDestructuringEmpty(_ref23), _ref23));
1944
1847
  return FUtil.Request({
1945
1848
  method: 'GET',
1946
1849
  url: "/v2/resources/types/listSimple4Recently",
@@ -1948,8 +1851,7 @@ function listSimple4Recently(_temp2) {
1948
1851
  });
1949
1852
  }
1950
1853
  function getAttrsInfoByKey(_ref24) {
1951
- var params = _extends({}, _ref24);
1952
-
1854
+ var params = _extends({}, (_objectDestructuringEmpty(_ref24), _ref24));
1953
1855
  return FUtil.Request({
1954
1856
  method: 'GET',
1955
1857
  url: "/v2/resources/attrs/getInfoByKey",
@@ -1966,6 +1868,201 @@ function generateResourceNames(_ref25) {
1966
1868
  }
1967
1869
  });
1968
1870
  }
1871
+ function updateCollection(_ref26) {
1872
+ var resourceId = _ref26.resourceId,
1873
+ params = _objectWithoutPropertiesLoose(_ref26, _excluded13);
1874
+ return FUtil.Request({
1875
+ method: 'PUT',
1876
+ url: "/v2/resources/catalogue/" + resourceId,
1877
+ data: params
1878
+ });
1879
+ }
1880
+ function deleteCollectionUnitResource(_ref27) {
1881
+ var resourceId = _ref27.resourceId,
1882
+ removeCollectionItemIds = _ref27.removeCollectionItemIds;
1883
+ return FUtil.Request({
1884
+ method: 'DELETE',
1885
+ url: "/v2/resources/catalogue/" + resourceId + "?removeCollectionItemIds=" + removeCollectionItemIds.join(',')
1886
+ });
1887
+ }
1888
+ function getCollectionItems(_ref28) {
1889
+ var resourceId = _ref28.resourceId,
1890
+ params = _objectWithoutPropertiesLoose(_ref28, _excluded14);
1891
+ return FUtil.Request({
1892
+ method: 'GET',
1893
+ url: "/v2/resources/catalogue/" + resourceId + "/items",
1894
+ params: params
1895
+ });
1896
+ }
1897
+ function getCollectionItems_Draft(_ref29) {
1898
+ var resourceId = _ref29.resourceId,
1899
+ params = _objectWithoutPropertiesLoose(_ref29, _excluded15);
1900
+ return FUtil.Request({
1901
+ method: 'GET',
1902
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items",
1903
+ params: params
1904
+ });
1905
+ }
1906
+ function setCollectionItemSort(_ref30) {
1907
+ var resourceId = _ref30.resourceId,
1908
+ params = _objectWithoutPropertiesLoose(_ref30, _excluded16);
1909
+ return FUtil.Request({
1910
+ method: 'PUT',
1911
+ url: "/v2/resources/catalogue/" + resourceId + "/manualSort",
1912
+ data: params
1913
+ });
1914
+ }
1915
+ function reorderCollectionItemsSort(_ref31) {
1916
+ var resourceId = _ref31.resourceId,
1917
+ params = _objectWithoutPropertiesLoose(_ref31, _excluded17);
1918
+ return FUtil.Request({
1919
+ method: 'PUT',
1920
+ url: "/v2/resources/catalogue/" + resourceId + "/reorder",
1921
+ data: params
1922
+ });
1923
+ }
1924
+ function checkExistCollectionItems(_ref32) {
1925
+ var resourceId = _ref32.resourceId,
1926
+ params = _objectWithoutPropertiesLoose(_ref32, _excluded18);
1927
+ return FUtil.Request({
1928
+ method: 'GET',
1929
+ url: "/v2/resources/catalogue/" + resourceId + "/items/checkExists",
1930
+ params: params
1931
+ });
1932
+ }
1933
+ function getCollectionItemsAuth(_ref33) {
1934
+ var resourceId = _ref33.resourceId,
1935
+ params = _objectWithoutPropertiesLoose(_ref33, _excluded19);
1936
+ return FUtil.Request({
1937
+ method: 'GET',
1938
+ url: "/v2/auths/resources/" + resourceId + "/items/batchAuth",
1939
+ params: params
1940
+ });
1941
+ }
1942
+ function batchResourceItems(_ref34) {
1943
+ var params = _extends({}, (_objectDestructuringEmpty(_ref34), _ref34));
1944
+ return FUtil.Request({
1945
+ method: 'GET',
1946
+ url: "/v2/resources/catalogue/items/batch/list",
1947
+ params: params
1948
+ });
1949
+ }
1950
+ function batchResourceItems_Draft(_ref35) {
1951
+ var params = _extends({}, (_objectDestructuringEmpty(_ref35), _ref35));
1952
+ return FUtil.Request({
1953
+ method: 'GET',
1954
+ url: "/v2/resources/catalogues/drafts/items/batch/list",
1955
+ params: params
1956
+ });
1957
+ }
1958
+ function getCollectionUpdateLogs(_ref36) {
1959
+ var resourceId = _ref36.resourceId,
1960
+ params = _objectWithoutPropertiesLoose(_ref36, _excluded20);
1961
+ return FUtil.Request({
1962
+ method: 'GET',
1963
+ url: "/v2/resources/catalogue/" + resourceId + "/updateLogs",
1964
+ params: params
1965
+ });
1966
+ }
1967
+ function getCollectionCollectRules(_ref37) {
1968
+ var resourceId = _ref37.resourceId;
1969
+ return FUtil.Request({
1970
+ method: 'GET',
1971
+ url: "/v2/resources/catalogue/" + resourceId + "/items/collectRules"
1972
+ });
1973
+ }
1974
+ function setCollectRules(_ref38) {
1975
+ var resourceId = _ref38.resourceId,
1976
+ params = _objectWithoutPropertiesLoose(_ref38, _excluded21);
1977
+ return FUtil.Request({
1978
+ method: 'POST',
1979
+ url: "/v2/resources/catalogue/" + resourceId + "/items/collectRules",
1980
+ data: params
1981
+ });
1982
+ }
1983
+ function setItemsTitle(_ref39) {
1984
+ var resourceId = _ref39.resourceId,
1985
+ data = _ref39.data;
1986
+ return FUtil.Request({
1987
+ method: 'PUT',
1988
+ url: "/v2/resources/catalogue/" + resourceId + "/items",
1989
+ data: data
1990
+ });
1991
+ }
1992
+ function deleteCollectionItems_Draft(_ref40) {
1993
+ var resourceId = _ref40.resourceId,
1994
+ removeCollectionItemIds = _ref40.removeCollectionItemIds;
1995
+ return FUtil.Request({
1996
+ method: 'DELETE',
1997
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items?removeCollectionItemIds=" + removeCollectionItemIds.join(',')
1998
+ });
1999
+ }
2000
+ function setCollectionItemsSortID_Draft(_ref41) {
2001
+ var resourceId = _ref41.resourceId,
2002
+ data = _ref41.data;
2003
+ return FUtil.Request({
2004
+ method: 'PUT',
2005
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/manualSort",
2006
+ data: data
2007
+ });
2008
+ }
2009
+ function reorderCollectionItems_Draft(_ref42) {
2010
+ var resourceId = _ref42.resourceId,
2011
+ params = _objectWithoutPropertiesLoose(_ref42, _excluded22);
2012
+ return FUtil.Request({
2013
+ method: 'PUT',
2014
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/reorder",
2015
+ data: params
2016
+ });
2017
+ }
2018
+ function resourceIsExistInItems_Draft(_ref43) {
2019
+ var resourceId = _ref43.resourceId,
2020
+ params = _objectWithoutPropertiesLoose(_ref43, _excluded23);
2021
+ return FUtil.Request({
2022
+ method: 'GET',
2023
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items/checkExists",
2024
+ params: params
2025
+ });
2026
+ }
2027
+ function updateCollectionItemsInfo_Draft(_ref44) {
2028
+ var resourceId = _ref44.resourceId,
2029
+ data = _ref44.data;
2030
+ return FUtil.Request({
2031
+ method: 'PUT',
2032
+ // url: `/v2/resources/catalogue/${resourceId}/items`,
2033
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items",
2034
+ data: data
2035
+ });
2036
+ }
2037
+ function updateCollectionItemAuthorization_Draft(_ref45) {
2038
+ var resourceId = _ref45.resourceId,
2039
+ itemId = _ref45.itemId,
2040
+ params = _objectWithoutPropertiesLoose(_ref45, _excluded24);
2041
+ return FUtil.Request({
2042
+ method: 'PUT',
2043
+ // url: `/v2/resources/catalogues/${resourceId}/items/${itemId}`,
2044
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items/" + itemId,
2045
+ data: params
2046
+ });
2047
+ }
2048
+ function addResourceItems_Draft(_ref46) {
2049
+ var resourceId = _ref46.resourceId,
2050
+ params = _objectWithoutPropertiesLoose(_ref46, _excluded25);
2051
+ return FUtil.Request({
2052
+ method: 'POST',
2053
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items",
2054
+ data: params
2055
+ });
2056
+ }
2057
+ function getCollectionItemsAuth_Draft(_ref47) {
2058
+ var resourceId = _ref47.resourceId,
2059
+ params = _objectWithoutPropertiesLoose(_ref47, _excluded26);
2060
+ return FUtil.Request({
2061
+ method: 'GET',
2062
+ url: "/v2/resources/catalogues/drafts/" + resourceId + "/items/batchAuth",
2063
+ params: params
2064
+ });
2065
+ }
1969
2066
 
1970
2067
  var Resource = {
1971
2068
  __proto__: null,
@@ -2006,13 +2103,34 @@ var Resource = {
2006
2103
  getResourceAttrListSimple: getResourceAttrListSimple,
2007
2104
  listSimple4Recently: listSimple4Recently,
2008
2105
  getAttrsInfoByKey: getAttrsInfoByKey,
2009
- generateResourceNames: generateResourceNames
2106
+ generateResourceNames: generateResourceNames,
2107
+ updateCollection: updateCollection,
2108
+ deleteCollectionUnitResource: deleteCollectionUnitResource,
2109
+ getCollectionItems: getCollectionItems,
2110
+ getCollectionItems_Draft: getCollectionItems_Draft,
2111
+ setCollectionItemSort: setCollectionItemSort,
2112
+ reorderCollectionItemsSort: reorderCollectionItemsSort,
2113
+ checkExistCollectionItems: checkExistCollectionItems,
2114
+ getCollectionItemsAuth: getCollectionItemsAuth,
2115
+ batchResourceItems: batchResourceItems,
2116
+ batchResourceItems_Draft: batchResourceItems_Draft,
2117
+ getCollectionUpdateLogs: getCollectionUpdateLogs,
2118
+ getCollectionCollectRules: getCollectionCollectRules,
2119
+ setCollectRules: setCollectRules,
2120
+ setItemsTitle: setItemsTitle,
2121
+ deleteCollectionItems_Draft: deleteCollectionItems_Draft,
2122
+ setCollectionItemsSortID_Draft: setCollectionItemsSortID_Draft,
2123
+ reorderCollectionItems_Draft: reorderCollectionItems_Draft,
2124
+ resourceIsExistInItems_Draft: resourceIsExistInItems_Draft,
2125
+ updateCollectionItemsInfo_Draft: updateCollectionItemsInfo_Draft,
2126
+ updateCollectionItemAuthorization_Draft: updateCollectionItemAuthorization_Draft,
2127
+ addResourceItems_Draft: addResourceItems_Draft,
2128
+ getCollectionItemsAuth_Draft: getCollectionItemsAuth_Draft
2010
2129
  };
2011
2130
 
2012
2131
  var _excluded$4 = ["loginName"];
2013
2132
  function login$1(_ref) {
2014
- var params = _extends({}, _ref);
2015
-
2133
+ var params = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
2016
2134
  // return FUtil.Axios.post(`/v2/passport/login`, params);
2017
2135
  return FUtil.Request({
2018
2136
  method: 'POST',
@@ -2024,8 +2142,7 @@ function login$1(_ref) {
2024
2142
  }
2025
2143
  function logout(_temp) {
2026
2144
  var _ref2 = _temp === void 0 ? {} : _temp,
2027
- params = _extends({}, _ref2);
2028
-
2145
+ params = _extends({}, (_objectDestructuringEmpty(_ref2), _ref2));
2029
2146
  return FUtil.Request({
2030
2147
  method: 'GET',
2031
2148
  url: '/v2/passport/logout',
@@ -2049,10 +2166,7 @@ function batchUserList(params) {
2049
2166
  });
2050
2167
  }
2051
2168
  function currentUserInfo(_temp2) {
2052
- var _ref3 = _temp2 === void 0 ? {} : _temp2;
2053
-
2054
- _objectDestructuringEmpty(_ref3);
2055
-
2169
+ _objectDestructuringEmpty(_temp2 === void 0 ? {} : _temp2);
2056
2170
  // return FUtil.Axios.get(`/v1/userinfos/current`);
2057
2171
  return FUtil.Request({
2058
2172
  method: 'GET',
@@ -2075,8 +2189,7 @@ function logon$1(params) {
2075
2189
  }
2076
2190
  function resetPassword(_ref4) {
2077
2191
  var loginName = _ref4.loginName,
2078
- params = _objectWithoutPropertiesLoose(_ref4, _excluded$4);
2079
-
2192
+ params = _objectWithoutPropertiesLoose(_ref4, _excluded$4);
2080
2193
  return FUtil.Request({
2081
2194
  method: 'PUT',
2082
2195
  url: "/v2/users/" + loginName + "/resetPassword",
@@ -2092,17 +2205,14 @@ function updatePassword(params) {
2092
2205
  }
2093
2206
  function uploadHeadImg(params, config) {
2094
2207
  var formData = new FormData();
2095
-
2096
2208
  for (var _i = 0, _Object$entries = Object.entries(params); _i < _Object$entries.length; _i++) {
2097
2209
  var _Object$entries$_i = _Object$entries[_i],
2098
- key = _Object$entries$_i[0],
2099
- value = _Object$entries$_i[1];
2100
-
2210
+ key = _Object$entries$_i[0],
2211
+ value = _Object$entries$_i[1];
2101
2212
  if (value) {
2102
2213
  formData.append(key, value);
2103
2214
  }
2104
2215
  }
2105
-
2106
2216
  return FUtil.Request(_extends({
2107
2217
  method: 'POST',
2108
2218
  url: "/v2/users/current/uploadHeadImg",
@@ -2127,7 +2237,6 @@ function areasProvinces(params) {
2127
2237
  if (params === void 0) {
2128
2238
  params = {};
2129
2239
  }
2130
-
2131
2240
  return FUtil.Request({
2132
2241
  method: 'GET',
2133
2242
  url: "/v2/areas/provinces",
@@ -2161,7 +2270,6 @@ function thirdPartyList(params) {
2161
2270
  if (params === void 0) {
2162
2271
  params = {};
2163
2272
  }
2164
-
2165
2273
  return FUtil.Request({
2166
2274
  method: 'GET',
2167
2275
  url: "/v2/thirdParty/list",
@@ -2174,15 +2282,15 @@ function thirdPartyIsBind(params) {
2174
2282
  url: "/v2/thirdParty/isBind",
2175
2283
  params: params
2176
2284
  });
2177
- } // 签到
2178
-
2285
+ }
2286
+ // 签到
2179
2287
  function signForCoins() {
2180
2288
  return FUtil.Request({
2181
2289
  method: 'GET',
2182
2290
  url: "/v2/activities/facade/sign"
2183
2291
  });
2184
- } // 查询签到信息
2185
-
2292
+ }
2293
+ // 查询签到信息
2186
2294
  function getSignInfo() {
2187
2295
  return FUtil.Request({
2188
2296
  method: 'GET',
@@ -2215,20 +2323,19 @@ var User = {
2215
2323
  };
2216
2324
 
2217
2325
  var _excluded$5 = ["nodeId"],
2218
- _excluded2$4 = ["nodeId"],
2219
- _excluded3$4 = ["nodeId"],
2220
- _excluded4$4 = ["nodeId"],
2221
- _excluded5$4 = ["nodeId"],
2222
- _excluded6$3 = ["testResourceId"],
2223
- _excluded7$2 = ["testResourceId"],
2224
- _excluded8$2 = ["nodeId"],
2225
- _excluded9$2 = ["nodeId"],
2226
- _excluded10$2 = ["nodeId"],
2227
- _excluded11$1 = ["nodeId"];
2326
+ _excluded2$4 = ["nodeId"],
2327
+ _excluded3$4 = ["nodeId"],
2328
+ _excluded4$4 = ["nodeId"],
2329
+ _excluded5$4 = ["nodeId"],
2330
+ _excluded6$3 = ["testResourceId"],
2331
+ _excluded7$3 = ["testResourceId"],
2332
+ _excluded8$2 = ["nodeId"],
2333
+ _excluded9$2 = ["nodeId"],
2334
+ _excluded10$2 = ["nodeId"],
2335
+ _excluded11$2 = ["nodeId"];
2228
2336
  function testResources(_ref) {
2229
2337
  var nodeId = _ref.nodeId,
2230
- params = _objectWithoutPropertiesLoose(_ref, _excluded$5);
2231
-
2338
+ params = _objectWithoutPropertiesLoose(_ref, _excluded$5);
2232
2339
  return FUtil.Request({
2233
2340
  method: 'GET',
2234
2341
  url: "/v2/testNodes/" + nodeId + "/testResources",
@@ -2237,8 +2344,7 @@ function testResources(_ref) {
2237
2344
  }
2238
2345
  function createRules(_ref2) {
2239
2346
  var nodeId = _ref2.nodeId,
2240
- params = _objectWithoutPropertiesLoose(_ref2, _excluded2$4);
2241
-
2347
+ params = _objectWithoutPropertiesLoose(_ref2, _excluded2$4);
2242
2348
  return FUtil.Request({
2243
2349
  method: 'POST',
2244
2350
  url: "/v2/testNodes/" + nodeId + "/rules",
@@ -2247,8 +2353,7 @@ function createRules(_ref2) {
2247
2353
  }
2248
2354
  function batchTestResources(_ref3) {
2249
2355
  var nodeId = _ref3.nodeId,
2250
- params = _objectWithoutPropertiesLoose(_ref3, _excluded3$4);
2251
-
2356
+ params = _objectWithoutPropertiesLoose(_ref3, _excluded3$4);
2252
2357
  return FUtil.Request({
2253
2358
  method: 'GET',
2254
2359
  url: "/v2/testNodes/" + nodeId + "/testResources/list",
@@ -2257,8 +2362,7 @@ function batchTestResources(_ref3) {
2257
2362
  }
2258
2363
  function dependencyTree$2(_ref4) {
2259
2364
  var nodeId = _ref4.nodeId,
2260
- params = _objectWithoutPropertiesLoose(_ref4, _excluded4$4);
2261
-
2365
+ params = _objectWithoutPropertiesLoose(_ref4, _excluded4$4);
2262
2366
  return FUtil.Request({
2263
2367
  method: 'GET',
2264
2368
  url: "/v2/testNodes/" + nodeId + "/testResources/dependencyTree/search",
@@ -2267,8 +2371,7 @@ function dependencyTree$2(_ref4) {
2267
2371
  }
2268
2372
  function putRules(_ref5) {
2269
2373
  var nodeId = _ref5.nodeId,
2270
- params = _objectWithoutPropertiesLoose(_ref5, _excluded5$4);
2271
-
2374
+ params = _objectWithoutPropertiesLoose(_ref5, _excluded5$4);
2272
2375
  return FUtil.Request({
2273
2376
  method: 'PUT',
2274
2377
  url: "/v2/testNodes/" + nodeId + "/rules",
@@ -2284,8 +2387,7 @@ function testNodeRules(_ref6) {
2284
2387
  }
2285
2388
  function updateTestResourceContracts(_ref7) {
2286
2389
  var testResourceId = _ref7.testResourceId,
2287
- params = _objectWithoutPropertiesLoose(_ref7, _excluded6$3);
2288
-
2390
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded6$3);
2289
2391
  // return FUtil.Axios.put(`/v2/testNodes/testResources/${testResourceId}`, params);
2290
2392
  return FUtil.Request({
2291
2393
  method: 'PUT',
@@ -2295,8 +2397,7 @@ function updateTestResourceContracts(_ref7) {
2295
2397
  }
2296
2398
  function dependencyTreeFilter(_ref8) {
2297
2399
  var testResourceId = _ref8.testResourceId,
2298
- params = _objectWithoutPropertiesLoose(_ref8, _excluded7$2);
2299
-
2400
+ params = _objectWithoutPropertiesLoose(_ref8, _excluded7$3);
2300
2401
  // return FUtil.Axios.get(`/v2/testNodes/testResources/${testResourceId}/dependencyTree/filter`, {
2301
2402
  // params
2302
2403
  // });
@@ -2331,8 +2432,7 @@ function testResourceDetails(_ref11) {
2331
2432
  }
2332
2433
  function searchTestResourcesByDependency(_ref12) {
2333
2434
  var nodeId = _ref12.nodeId,
2334
- params = _objectWithoutPropertiesLoose(_ref12, _excluded8$2);
2335
-
2435
+ params = _objectWithoutPropertiesLoose(_ref12, _excluded8$2);
2336
2436
  // return FUtil.Axios.get(`/v2/testNodes/${nodeId}/testResources/searchByDependency`, {
2337
2437
  // params,
2338
2438
  // });
@@ -2344,8 +2444,7 @@ function searchTestResourcesByDependency(_ref12) {
2344
2444
  }
2345
2445
  function rulesRematch(_ref13) {
2346
2446
  var nodeId = _ref13.nodeId,
2347
- params = _objectWithoutPropertiesLoose(_ref13, _excluded9$2);
2348
-
2447
+ params = _objectWithoutPropertiesLoose(_ref13, _excluded9$2);
2349
2448
  return FUtil.Request({
2350
2449
  method: 'POST',
2351
2450
  url: "/v2/testNodes/" + nodeId + "/rules/rematch",
@@ -2354,8 +2453,7 @@ function rulesRematch(_ref13) {
2354
2453
  }
2355
2454
  function rulesPreExecution(_ref14) {
2356
2455
  var nodeId = _ref14.nodeId,
2357
- params = _objectWithoutPropertiesLoose(_ref14, _excluded10$2);
2358
-
2456
+ params = _objectWithoutPropertiesLoose(_ref14, _excluded10$2);
2359
2457
  return FUtil.Request({
2360
2458
  method: 'POST',
2361
2459
  url: "/v2/testNodes/" + nodeId + "/rules/preExecution",
@@ -2364,8 +2462,7 @@ function rulesPreExecution(_ref14) {
2364
2462
  }
2365
2463
  function batchGetAuths(_ref15) {
2366
2464
  var nodeId = _ref15.nodeId,
2367
- params = _objectWithoutPropertiesLoose(_ref15, _excluded11$1);
2368
-
2465
+ params = _objectWithoutPropertiesLoose(_ref15, _excluded11$2);
2369
2466
  return FUtil.Request({
2370
2467
  method: 'GET',
2371
2468
  url: "/v2/auths/exhibits/" + nodeId + "/test/batchAuth/results",
@@ -2393,10 +2490,9 @@ var InformalNode = {
2393
2490
  };
2394
2491
 
2395
2492
  var _excluded$6 = ["contractId"],
2396
- _excluded2$5 = ["contractId"];
2493
+ _excluded2$5 = ["contractId"];
2397
2494
  function createContract(_ref) {
2398
- var params = _extends({}, _ref);
2399
-
2495
+ var params = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
2400
2496
  return FUtil.Request({
2401
2497
  method: 'POST',
2402
2498
  url: "/v2/contracts",
@@ -2404,8 +2500,7 @@ function createContract(_ref) {
2404
2500
  });
2405
2501
  }
2406
2502
  function batchCreateContracts(_ref2) {
2407
- var params = _extends({}, _ref2);
2408
-
2503
+ var params = _extends({}, (_objectDestructuringEmpty(_ref2), _ref2));
2409
2504
  return FUtil.Request({
2410
2505
  method: 'POST',
2411
2506
  url: "/v2/contracts/batchSign",
@@ -2414,8 +2509,7 @@ function batchCreateContracts(_ref2) {
2414
2509
  }
2415
2510
  function contractDetails(_ref3) {
2416
2511
  var contractId = _ref3.contractId,
2417
- params = _objectWithoutPropertiesLoose(_ref3, _excluded$6);
2418
-
2512
+ params = _objectWithoutPropertiesLoose(_ref3, _excluded$6);
2419
2513
  return FUtil.Request({
2420
2514
  method: 'GET',
2421
2515
  url: "/v2/contracts/" + contractId,
@@ -2445,8 +2539,7 @@ function batchContracts(params) {
2445
2539
  }
2446
2540
  function transitionRecords(_ref4) {
2447
2541
  var contractId = _ref4.contractId,
2448
- params = _objectWithoutPropertiesLoose(_ref4, _excluded2$5);
2449
-
2542
+ params = _objectWithoutPropertiesLoose(_ref4, _excluded2$5);
2450
2543
  return FUtil.Request({
2451
2544
  method: 'GET',
2452
2545
  url: "/v2/contracts/" + contractId + "/transitionRecords",
@@ -2474,11 +2567,10 @@ var Contract = {
2474
2567
  };
2475
2568
 
2476
2569
  var _excluded$7 = ["accountId"],
2477
- _excluded2$6 = ["userId"];
2570
+ _excluded2$6 = ["userId"];
2478
2571
  function details$1(_ref) {
2479
2572
  var accountId = _ref.accountId,
2480
- params = _objectWithoutPropertiesLoose(_ref, _excluded$7);
2481
-
2573
+ params = _objectWithoutPropertiesLoose(_ref, _excluded$7);
2482
2574
  return FUtil.Request({
2483
2575
  method: 'GET',
2484
2576
  url: "/v2/transactions/details/" + accountId,
@@ -2487,8 +2579,7 @@ function details$1(_ref) {
2487
2579
  }
2488
2580
  function individualAccounts(_ref2) {
2489
2581
  var userId = _ref2.userId,
2490
- params = _objectWithoutPropertiesLoose(_ref2, _excluded2$6);
2491
-
2582
+ params = _objectWithoutPropertiesLoose(_ref2, _excluded2$6);
2492
2583
  return FUtil.Request({
2493
2584
  method: 'GET',
2494
2585
  url: "/v2/accounts/individualAccounts/" + userId,
@@ -2503,8 +2594,7 @@ function transactionDetails(_ref3) {
2503
2594
  });
2504
2595
  }
2505
2596
  function activateIndividualAccounts(_ref4) {
2506
- var params = _extends({}, _ref4);
2507
-
2597
+ var params = _extends({}, (_objectDestructuringEmpty(_ref4), _ref4));
2508
2598
  return FUtil.Request({
2509
2599
  method: 'PUT',
2510
2600
  url: "/v2/accounts/individualAccounts/activate",
@@ -2512,8 +2602,7 @@ function activateIndividualAccounts(_ref4) {
2512
2602
  });
2513
2603
  }
2514
2604
  function changePassword(_ref5) {
2515
- var params = _extends({}, _ref5);
2516
-
2605
+ var params = _extends({}, (_objectDestructuringEmpty(_ref5), _ref5));
2517
2606
  return FUtil.Request({
2518
2607
  method: 'PUT',
2519
2608
  url: "/v2/accounts/individualAccounts",
@@ -2521,8 +2610,7 @@ function changePassword(_ref5) {
2521
2610
  });
2522
2611
  }
2523
2612
  function resetPassword$1(_ref6) {
2524
- var params = _extends({}, _ref6);
2525
-
2613
+ var params = _extends({}, (_objectDestructuringEmpty(_ref6), _ref6));
2526
2614
  return FUtil.Request({
2527
2615
  method: 'PUT',
2528
2616
  url: "/v2/accounts/individualAccounts/resetPassword",
@@ -2530,8 +2618,7 @@ function resetPassword$1(_ref6) {
2530
2618
  });
2531
2619
  }
2532
2620
  function verifyTransactionPassword(_ref7) {
2533
- var params = _extends({}, _ref7);
2534
-
2621
+ var params = _extends({}, (_objectDestructuringEmpty(_ref7), _ref7));
2535
2622
  return FUtil.Request({
2536
2623
  method: 'GET',
2537
2624
  url: "/v2/accounts/individualAccounts/verifyTransactionPassword",
@@ -2574,8 +2661,7 @@ var Captcha = {
2574
2661
  var _excluded$8 = ["contractId"];
2575
2662
  function transaction(_ref) {
2576
2663
  var contractId = _ref.contractId,
2577
- params = _objectWithoutPropertiesLoose(_ref, _excluded$8);
2578
-
2664
+ params = _objectWithoutPropertiesLoose(_ref, _excluded$8);
2579
2665
  return FUtil.Request({
2580
2666
  method: 'POST',
2581
2667
  url: "/v2/contracts/" + contractId + "/events/payment",
@@ -2634,7 +2720,6 @@ function getBaseTaskInfo(params) {
2634
2720
  if (params === void 0) {
2635
2721
  params = {};
2636
2722
  }
2637
-
2638
2723
  return FUtil.Request({
2639
2724
  method: 'GET',
2640
2725
  url: "/v2/activities/facade/getBaseTaskInfo",
@@ -2645,7 +2730,6 @@ function getResourceTaskInfo(params) {
2645
2730
  if (params === void 0) {
2646
2731
  params = {};
2647
2732
  }
2648
-
2649
2733
  return FUtil.Request({
2650
2734
  method: 'GET',
2651
2735
  url: "/v2/activities/facade/getResourceTaskInfo",
@@ -2656,7 +2740,6 @@ function getNodeTaskInfo(params) {
2656
2740
  if (params === void 0) {
2657
2741
  params = {};
2658
2742
  }
2659
-
2660
2743
  return FUtil.Request({
2661
2744
  method: 'GET',
2662
2745
  url: "/v2/activities/facade/getNodeTaskInfo",
@@ -2702,7 +2785,6 @@ function getWechatOfficialAccountInfo(params) {
2702
2785
  if (params === void 0) {
2703
2786
  params = {};
2704
2787
  }
2705
-
2706
2788
  return FUtil.Request({
2707
2789
  method: 'GET',
2708
2790
  url: "/v2/extensions/wechat/getRelationship4Client",
@@ -2713,7 +2795,6 @@ function lotteryList(params) {
2713
2795
  if (params === void 0) {
2714
2796
  params = {};
2715
2797
  }
2716
-
2717
2798
  return FUtil.Request({
2718
2799
  method: 'GET',
2719
2800
  url: "/v2/activities/lottery/resource/list",
@@ -2745,7 +2826,6 @@ function listRewardRecordInfos(params) {
2745
2826
  if (params === void 0) {
2746
2827
  params = {};
2747
2828
  }
2748
-
2749
2829
  return FUtil.Request({
2750
2830
  method: 'POST',
2751
2831
  url: "/v2/activities/facade/listRewardRecordInfos",
@@ -2811,15 +2891,13 @@ function codeDetails1(_ref) {
2811
2891
  }
2812
2892
  function codeDetails2(_ref2) {
2813
2893
  _objectDestructuringEmpty(_ref2);
2814
-
2815
2894
  return FUtil.Request({
2816
2895
  method: 'GET',
2817
2896
  url: "/v2/testQualifications/beta/codes/userActivateCode"
2818
2897
  });
2819
2898
  }
2820
2899
  function betaCodesActivate(_ref3) {
2821
- var params = _extends({}, _ref3);
2822
-
2900
+ var params = _extends({}, (_objectDestructuringEmpty(_ref3), _ref3));
2823
2901
  return FUtil.Request({
2824
2902
  method: 'POST',
2825
2903
  url: "/v2/testQualifications/beta/codes/activate",
@@ -2827,8 +2905,7 @@ function betaCodesActivate(_ref3) {
2827
2905
  });
2828
2906
  }
2829
2907
  function usedRecords(_ref4) {
2830
- var params = _extends({}, _ref4);
2831
-
2908
+ var params = _extends({}, (_objectDestructuringEmpty(_ref4), _ref4));
2832
2909
  return FUtil.Request({
2833
2910
  method: 'GET',
2834
2911
  url: "/v2/testQualifications/beta/codes/usedRecords",
@@ -2836,8 +2913,7 @@ function usedRecords(_ref4) {
2836
2913
  });
2837
2914
  }
2838
2915
  function betaApply(_ref5) {
2839
- var params = _extends({}, _ref5);
2840
-
2916
+ var params = _extends({}, (_objectDestructuringEmpty(_ref5), _ref5));
2841
2917
  return FUtil.Request({
2842
2918
  method: 'POST',
2843
2919
  url: "/v2/testQualifications/beta/apply",
@@ -2846,8 +2922,7 @@ function betaApply(_ref5) {
2846
2922
  }
2847
2923
  function getBetaApply1(_temp) {
2848
2924
  var _ref6 = _temp === void 0 ? {} : _temp,
2849
- params = _extends({}, _ref6);
2850
-
2925
+ params = _extends({}, (_objectDestructuringEmpty(_ref6), _ref6));
2851
2926
  return FUtil.Request({
2852
2927
  method: 'GET',
2853
2928
  url: "/v2/testQualifications/beta/apply/current",
@@ -2856,8 +2931,7 @@ function getBetaApply1(_temp) {
2856
2931
  }
2857
2932
  function getBetaApply2(_ref7) {
2858
2933
  var recordId = _ref7.recordId,
2859
- params = _objectWithoutPropertiesLoose(_ref7, _excluded$9);
2860
-
2934
+ params = _objectWithoutPropertiesLoose(_ref7, _excluded$9);
2861
2935
  return FUtil.Request({
2862
2936
  method: 'GET',
2863
2937
  url: "/v2/testQualifications/beta/apply/" + recordId,
@@ -2865,8 +2939,7 @@ function getBetaApply2(_ref7) {
2865
2939
  });
2866
2940
  }
2867
2941
  function invitees(_ref8) {
2868
- var params = _extends({}, _ref8);
2869
-
2942
+ var params = _extends({}, (_objectDestructuringEmpty(_ref8), _ref8));
2870
2943
  return FUtil.Request({
2871
2944
  method: 'GET',
2872
2945
  url: "/v2/testQualifications/beta/codes/invitees",
@@ -2906,7 +2979,8 @@ function configsList(params) {
2906
2979
  url: "/v2/i18n/configs/list",
2907
2980
  data: params
2908
2981
  });
2909
- } // oss保存的翻译
2982
+ }
2983
+ // oss保存的翻译
2910
2984
  // interface ConfigsListParamsType {
2911
2985
  // key: string;
2912
2986
  // content: string;
@@ -2947,7 +3021,6 @@ function policyTemplates(params) {
2947
3021
  if (params === void 0) {
2948
3022
  params = {};
2949
3023
  }
2950
-
2951
3024
  return FUtil.Request({
2952
3025
  method: 'GET',
2953
3026
  url: "/v2/translate/translate-config/list4Client",
@@ -2982,7 +3055,6 @@ var Policy = {
2982
3055
  };
2983
3056
 
2984
3057
  // import * as CryptoJS from 'crypto-js';
2985
-
2986
3058
  /**
2987
3059
  * 根据 File 获取 SHA1 Hash 字符串
2988
3060
  * @param file
@@ -2992,46 +3064,38 @@ function getSHA1Hash(file) {
2992
3064
  return new Promise(function (resolve) {
2993
3065
  var reader = new FileReader();
2994
3066
  reader.readAsArrayBuffer(file);
2995
- reader.onload = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
3067
+ reader.onload = /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
2996
3068
  var sha1;
2997
3069
  return _regeneratorRuntime().wrap(function _callee$(_context) {
2998
- while (1) {
2999
- switch (_context.prev = _context.next) {
3000
- case 0:
3001
- if (reader.result) {
3002
- _context.next = 3;
3003
- break;
3004
- }
3005
-
3006
- resolve('');
3007
- return _context.abrupt("return", '');
3008
-
3009
- case 3:
3010
- if (!(typeof reader.result === 'string')) {
3011
- _context.next = 6;
3012
- break;
3013
- }
3014
-
3015
- resolve('');
3016
- return _context.abrupt("return", '');
3017
-
3018
- case 6:
3019
- _context.next = 8;
3020
- return self.crypto.subtle.digest('SHA-1', reader.result).then(function (a) {
3021
- return Array.from(new Uint8Array(a)).map(function (a) {
3022
- return a.toString(16).padStart(2, '0');
3023
- }).join('');
3024
- });
3025
-
3026
- case 8:
3027
- sha1 = _context.sent;
3028
- resolve(sha1);
3029
- return _context.abrupt("return", '');
3030
-
3031
- case 11:
3032
- case "end":
3033
- return _context.stop();
3034
- }
3070
+ while (1) switch (_context.prev = _context.next) {
3071
+ case 0:
3072
+ if (reader.result) {
3073
+ _context.next = 3;
3074
+ break;
3075
+ }
3076
+ resolve('');
3077
+ return _context.abrupt("return", '');
3078
+ case 3:
3079
+ if (!(typeof reader.result === 'string')) {
3080
+ _context.next = 6;
3081
+ break;
3082
+ }
3083
+ resolve('');
3084
+ return _context.abrupt("return", '');
3085
+ case 6:
3086
+ _context.next = 8;
3087
+ return self.crypto.subtle.digest('SHA-1', reader.result).then(function (a) {
3088
+ return Array.from(new Uint8Array(a)).map(function (a) {
3089
+ return a.toString(16).padStart(2, '0');
3090
+ }).join('');
3091
+ });
3092
+ case 8:
3093
+ sha1 = _context.sent;
3094
+ resolve(sha1);
3095
+ return _context.abrupt("return", '');
3096
+ case 11:
3097
+ case "end":
3098
+ return _context.stop();
3035
3099
  }
3036
3100
  }, _callee);
3037
3101
  }));
@@ -3040,70 +3104,56 @@ function getSHA1Hash(file) {
3040
3104
  /**
3041
3105
  * 生成随机码
3042
3106
  */
3043
-
3044
3107
  function generateRandomCode(strLen) {
3045
3108
  if (strLen === void 0) {
3046
3109
  strLen = 5;
3047
3110
  }
3048
-
3049
3111
  var allStr = 'ABCDEFGHIJKLMNPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz1234567890';
3050
3112
  var newStrArr = [];
3051
-
3052
3113
  for (var i = 0; i < strLen; i++) {
3053
3114
  newStrArr.push(allStr[Math.floor(Math.random() * 61)]);
3054
3115
  }
3055
-
3056
3116
  return newStrArr.join('');
3057
3117
  }
3058
3118
  /**
3059
3119
  * 通过读取 cookies 获取用户 ID
3060
3120
  */
3061
-
3062
3121
  function getUserIDByCookies() {
3063
3122
  var uid = document.cookie.split('; ').find(function (co) {
3064
3123
  return co.startsWith('uid=');
3065
3124
  });
3066
-
3067
3125
  if (!uid) {
3068
3126
  return -1;
3069
3127
  }
3070
-
3071
3128
  return Number(uid.replace('uid=', ''));
3072
3129
  }
3073
3130
  function transformServerAPIContractState(_ref2) {
3074
3131
  var status = _ref2.status,
3075
- authStatus = _ref2.authStatus;
3076
-
3132
+ authStatus = _ref2.authStatus;
3077
3133
  if (status === 0) {
3078
3134
  if (authStatus === 1 || authStatus === 3) {
3079
3135
  return 'active';
3080
3136
  }
3081
-
3082
3137
  if (authStatus === 2) {
3083
3138
  return 'testActive';
3084
3139
  }
3085
-
3086
3140
  if (authStatus === 128) {
3087
3141
  return 'inactive';
3088
3142
  }
3089
3143
  }
3090
-
3091
3144
  if (status === 1) {
3092
3145
  return 'terminal';
3093
3146
  }
3094
-
3095
3147
  return 'exception';
3096
3148
  }
3097
3149
  /**
3098
3150
  * 暂时休眠
3099
3151
  * @param ms 休眠时常(毫秒)
3100
3152
  */
3101
-
3102
3153
  function promiseSleep(ms) {
3103
3154
  if (ms === void 0) {
3104
3155
  ms = 300;
3105
3156
  }
3106
-
3107
3157
  return new Promise(function (resolve) {
3108
3158
  setTimeout(function () {
3109
3159
  resolve();
@@ -3114,12 +3164,10 @@ function promiseSleep(ms) {
3114
3164
  * 获取用户头像URL
3115
3165
  * @param userID
3116
3166
  */
3117
-
3118
3167
  function getAvatarUrl(userID) {
3119
3168
  if (userID === void 0) {
3120
3169
  userID = 0;
3121
3170
  }
3122
-
3123
3171
  // return `${completeUrlByDomain('image')}/avatar/${userID || getUserIDByCookies()}?t=${Date.now()}`;
3124
3172
  return "https://image.freelog.com/avatar/" + (userID || getUserIDByCookies()) + "?t=" + Date.now();
3125
3173
  }
@@ -3137,123 +3185,101 @@ var Tool = {
3137
3185
  function getFilesSha1Info(_x, _x2) {
3138
3186
  return _getFilesSha1Info.apply(this, arguments);
3139
3187
  }
3140
-
3141
3188
  function _getFilesSha1Info() {
3142
- _getFilesSha1Info = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, cdPartially) {
3189
+ _getFilesSha1Info = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(_ref, cdPartially) {
3143
3190
  var sha1, resourceTypeCode, delay, needHandleSha1, allData, _yield$Storage$filesL, ret, errCode, data, msg, finishedInfo;
3144
-
3145
3191
  return _regeneratorRuntime().wrap(function _callee$(_context) {
3146
- while (1) {
3147
- switch (_context.prev = _context.next) {
3148
- case 0:
3149
- sha1 = _ref.sha1, resourceTypeCode = _ref.resourceTypeCode;
3150
-
3151
- if (cdPartially === void 0) {
3152
- cdPartially = function cdPartially() {
3153
- return undefined;
3154
- };
3155
- }
3156
-
3157
- if (!(sha1.length === 0)) {
3158
- _context.next = 4;
3159
- break;
3160
- }
3161
-
3162
- return _context.abrupt("return", {
3163
- error: '',
3164
- result: []
3165
- });
3166
-
3167
- case 4:
3168
- delay = 500;
3169
- needHandleSha1 = [].concat(sha1);
3170
- allData = [];
3171
-
3172
- case 7:
3173
-
3174
- _context.next = 10;
3175
- return filesListInfo({
3176
- sha1: needHandleSha1.join(','),
3177
- resourceTypeCode: resourceTypeCode
3178
- });
3179
-
3180
- case 10:
3181
- _yield$Storage$filesL = _context.sent;
3182
- ret = _yield$Storage$filesL.ret;
3183
- errCode = _yield$Storage$filesL.errCode;
3184
- data = _yield$Storage$filesL.data;
3185
- msg = _yield$Storage$filesL.msg;
3186
-
3187
- if (!(ret !== 0 || errCode !== 0)) {
3188
- _context.next = 18;
3189
- break;
3190
- }
3191
-
3192
- console.log({
3193
- ret: ret,
3194
- errCode: errCode,
3195
- data: data,
3196
- msg: msg
3197
- }, '09iowksdjaklfjs;oalijflskdjflsdkjflkj');
3198
- return _context.abrupt("return", {
3199
- error: msg,
3200
- result: allData
3201
- });
3202
-
3203
- case 18:
3204
- needHandleSha1 = data.filter(function (d) {
3205
- return d.metaAnalyzeStatus === 0 || d.metaAnalyzeStatus === 1;
3206
- }).map(function (d) {
3207
- return d.sha1;
3208
- });
3209
- finishedInfo = data.filter(function (d) {
3210
- return d.metaAnalyzeStatus !== 0 && d.metaAnalyzeStatus !== 1;
3211
- }).map(function (d) {
3212
- var state = 'fail';
3213
-
3214
- if (!d.metaAnalyzeStatus) {
3215
- state = 'nonentity';
3216
- } else if (d.metaAnalyzeStatus === 2) {
3217
- state = 'success';
3218
- } else if (d.metaAnalyzeStatus === 3) {
3219
- state = 'fail';
3220
- } // console.log(d, '90wieojiksdjf;lkasdjf;lksdjflksjdflkjsdlfkjsdlkj');
3221
-
3222
-
3223
- return {
3224
- sha1: d.sha1,
3225
- state: state,
3226
- info: d
3227
- };
3228
- });
3229
- cdPartially && cdPartially(finishedInfo);
3230
- allData = [].concat(allData, finishedInfo);
3231
-
3232
- if (!(needHandleSha1.length === 0)) {
3233
- _context.next = 24;
3234
- break;
3192
+ while (1) switch (_context.prev = _context.next) {
3193
+ case 0:
3194
+ sha1 = _ref.sha1, resourceTypeCode = _ref.resourceTypeCode;
3195
+ if (cdPartially === void 0) {
3196
+ cdPartially = function cdPartially() {
3197
+ return undefined;
3198
+ };
3199
+ }
3200
+ if (!(sha1.length === 0)) {
3201
+ _context.next = 4;
3202
+ break;
3203
+ }
3204
+ return _context.abrupt("return", {
3205
+ error: '',
3206
+ result: []
3207
+ });
3208
+ case 4:
3209
+ delay = 500;
3210
+ needHandleSha1 = [].concat(sha1);
3211
+ allData = [];
3212
+ case 7:
3213
+ _context.next = 10;
3214
+ return filesListInfo({
3215
+ sha1: needHandleSha1.join(','),
3216
+ resourceTypeCode: resourceTypeCode
3217
+ });
3218
+ case 10:
3219
+ _yield$Storage$filesL = _context.sent;
3220
+ ret = _yield$Storage$filesL.ret;
3221
+ errCode = _yield$Storage$filesL.errCode;
3222
+ data = _yield$Storage$filesL.data;
3223
+ msg = _yield$Storage$filesL.msg;
3224
+ if (!(ret !== 0 || errCode !== 0)) {
3225
+ _context.next = 18;
3226
+ break;
3227
+ }
3228
+ console.log({
3229
+ ret: ret,
3230
+ errCode: errCode,
3231
+ data: data,
3232
+ msg: msg
3233
+ }, '09iowksdjaklfjs;oalijflskdjflsdkjflkj');
3234
+ return _context.abrupt("return", {
3235
+ error: msg,
3236
+ result: allData
3237
+ });
3238
+ case 18:
3239
+ needHandleSha1 = data.filter(function (d) {
3240
+ return d.metaAnalyzeStatus === 0 || d.metaAnalyzeStatus === 1;
3241
+ }).map(function (d) {
3242
+ return d.sha1;
3243
+ });
3244
+ finishedInfo = data.filter(function (d) {
3245
+ return d.metaAnalyzeStatus !== 0 && d.metaAnalyzeStatus !== 1;
3246
+ }).map(function (d) {
3247
+ var state = 'fail';
3248
+ if (!d.metaAnalyzeStatus) {
3249
+ state = 'nonentity';
3250
+ } else if (d.metaAnalyzeStatus === 2) {
3251
+ state = 'success';
3252
+ } else if (d.metaAnalyzeStatus === 3) {
3253
+ state = 'fail';
3235
3254
  }
3236
-
3237
- return _context.abrupt("break", 28);
3238
-
3239
- case 24:
3240
- _context.next = 26;
3241
- return promiseSleep(delay);
3242
-
3243
- case 26:
3244
- _context.next = 7;
3255
+ // console.log(d, '90wieojiksdjf;lkasdjf;lksdjflksjdflkjsdlfkjsdlkj');
3256
+ return {
3257
+ sha1: d.sha1,
3258
+ state: state,
3259
+ info: d
3260
+ };
3261
+ });
3262
+ cdPartially && cdPartially(finishedInfo);
3263
+ allData = [].concat(allData, finishedInfo);
3264
+ if (!(needHandleSha1.length === 0)) {
3265
+ _context.next = 24;
3245
3266
  break;
3246
-
3247
- case 28:
3248
- return _context.abrupt("return", {
3249
- error: '',
3250
- result: allData
3251
- });
3252
-
3253
- case 29:
3254
- case "end":
3255
- return _context.stop();
3256
- }
3267
+ }
3268
+ return _context.abrupt("break", 28);
3269
+ case 24:
3270
+ _context.next = 26;
3271
+ return promiseSleep(delay);
3272
+ case 26:
3273
+ _context.next = 7;
3274
+ break;
3275
+ case 28:
3276
+ return _context.abrupt("return", {
3277
+ error: '',
3278
+ result: allData
3279
+ });
3280
+ case 29:
3281
+ case "end":
3282
+ return _context.stop();
3257
3283
  }
3258
3284
  }, _callee);
3259
3285
  }));
@@ -3267,8 +3293,7 @@ var recombination = {
3267
3293
 
3268
3294
  function operationCategories(_temp) {
3269
3295
  var _ref = _temp === void 0 ? {} : _temp,
3270
- params = _extends({}, _ref);
3271
-
3296
+ params = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
3272
3297
  return FUtil.Request({
3273
3298
  method: 'GET',
3274
3299
  url: "/v2/resources/operation-categories/listSimpleByGroup",
@@ -3276,8 +3301,7 @@ function operationCategories(_temp) {
3276
3301
  });
3277
3302
  }
3278
3303
  function recordRank(_ref2) {
3279
- var params = _extends({}, _ref2);
3280
-
3304
+ var params = _extends({}, (_objectDestructuringEmpty(_ref2), _ref2));
3281
3305
  return FUtil.Request({
3282
3306
  method: 'POST',
3283
3307
  url: "/v2/activities/coin/record/rank",
@@ -3285,8 +3309,7 @@ function recordRank(_ref2) {
3285
3309
  });
3286
3310
  }
3287
3311
  function rankInfo(_ref3) {
3288
- var params = _extends({}, _ref3);
3289
-
3312
+ var params = _extends({}, (_objectDestructuringEmpty(_ref3), _ref3));
3290
3313
  return FUtil.Request({
3291
3314
  method: 'POST',
3292
3315
  url: "/v2/activities/coin/record/rankInfo",
@@ -3301,6 +3324,29 @@ var Operation = {
3301
3324
  rankInfo: rankInfo
3302
3325
  };
3303
3326
 
3327
+ function getInfoByCode(_ref) {
3328
+ var params = _extends({}, (_objectDestructuringEmpty(_ref), _ref));
3329
+ return FUtil.Request({
3330
+ method: 'GET',
3331
+ url: "/v2/resources/types/getInfoByCode",
3332
+ params: params
3333
+ });
3334
+ }
3335
+ function getInfoByCodeOrName(_ref2) {
3336
+ var params = _extends({}, (_objectDestructuringEmpty(_ref2), _ref2));
3337
+ return FUtil.Request({
3338
+ method: 'GET',
3339
+ url: "/v2/resources/types/getInfoByCodeOrName",
3340
+ params: params
3341
+ });
3342
+ }
3343
+
3344
+ var ResourceType = {
3345
+ __proto__: null,
3346
+ getInfoByCode: getInfoByCode,
3347
+ getInfoByCodeOrName: getInfoByCodeOrName
3348
+ };
3349
+
3304
3350
  var FServiceAPI = {
3305
3351
  Node: Node,
3306
3352
  Exhibit: Exhibit,
@@ -3319,9 +3365,11 @@ var FServiceAPI = {
3319
3365
  I18n: I18n,
3320
3366
  Policy: Policy,
3321
3367
  recombination: recombination,
3322
- Operation: Operation
3368
+ Operation: Operation,
3369
+ ResourceType: ResourceType
3323
3370
  };
3324
3371
 
3372
+ // import from '../service-API';
3325
3373
  var codeMessage = {
3326
3374
  200: '服务器成功返回请求的数据。',
3327
3375
  201: '新建或修改数据成功。',
@@ -3338,8 +3386,8 @@ var codeMessage = {
3338
3386
  502: '网关错误。',
3339
3387
  503: '服务不可用,服务器暂时过载或维护。',
3340
3388
  504: '网关超时。'
3341
- }; // export let apiHost: string = '';
3342
-
3389
+ };
3390
+ // export let apiHost: string = '';
3343
3391
  if (window.location.hostname.includes('.com')) {
3344
3392
  // apiHost = `${window.location.protocol}//qi.${(window.location.host.match(/(?<=\.).*/) || [''])[0]}`;
3345
3393
  // apiHost = window.location.origin.replace('console', 'qi');
@@ -3369,8 +3417,6 @@ if (window.location.hostname.includes('.com')) {
3369
3417
  // };
3370
3418
  //
3371
3419
  // // Add a request interceptor
3372
-
3373
-
3374
3420
  axios.interceptors.request.use(function (config) {
3375
3421
  // Do something before request is sent
3376
3422
  // NProgress.start();
@@ -3383,10 +3429,8 @@ axios.interceptors.request.use(function (config) {
3383
3429
  /**
3384
3430
  * 配置request请求时的默认参数
3385
3431
  */
3386
-
3387
3432
  axios.interceptors.response.use(function (response) {
3388
3433
  var _headers$contentDisp;
3389
-
3390
3434
  // Do something with response data
3391
3435
  // console.log(response, 'response!!!!!!');
3392
3436
  // NProgress.done();
@@ -3394,18 +3438,17 @@ axios.interceptors.response.use(function (response) {
3394
3438
  var error = {
3395
3439
  description: codeMessage[response.status],
3396
3440
  message: response.status
3397
- }; // notification.error(error);
3398
-
3441
+ };
3442
+ // notification.error(error);
3399
3443
  throw new Error(JSON.stringify(error));
3400
3444
  }
3401
-
3402
3445
  var data = response.data,
3403
- headers = response.headers;
3404
-
3446
+ headers = response.headers;
3405
3447
  if ((_headers$contentDisp = headers['content-disposition']) != null && _headers$contentDisp.includes('attachment;')) {
3406
3448
  // downloadFile(response);
3407
3449
  return;
3408
- } // console.log(data, 'data2390jasdflkf');
3450
+ }
3451
+ // console.log(data, 'data2390jasdflkf');
3409
3452
  // if ((data.errcode === undefined
3410
3453
  // ? (data.errCode !== 0 && data.errCode !== 2)
3411
3454
  // : (data.errcode !== 0 && data.errcode !== 2))
@@ -3416,8 +3459,6 @@ axios.interceptors.response.use(function (response) {
3416
3459
  // // });
3417
3460
  // throw new Error(JSON.stringify(data));
3418
3461
  // }
3419
-
3420
-
3421
3462
  return data;
3422
3463
  }, function (error) {
3423
3464
  // Do something with response error
@@ -3427,51 +3468,40 @@ axios.interceptors.response.use(function (response) {
3427
3468
  function request(_x, _x2) {
3428
3469
  return _request.apply(this, arguments);
3429
3470
  }
3430
-
3431
3471
  function _request() {
3432
- _request = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(config, _temp) {
3472
+ _request = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(config, _temp) {
3433
3473
  var _ref, _ref$noRedirect, noRedirect, _ref$noErrorAlert, noErrorAlert, result;
3434
-
3435
3474
  return _regeneratorRuntime().wrap(function _callee$(_context) {
3436
- while (1) {
3437
- switch (_context.prev = _context.next) {
3438
- case 0:
3439
- _ref = _temp === void 0 ? {} : _temp, _ref$noRedirect = _ref.noRedirect, noRedirect = _ref$noRedirect === void 0 ? false : _ref$noRedirect, _ref$noErrorAlert = _ref.noErrorAlert, noErrorAlert = _ref$noErrorAlert === void 0 ? false : _ref$noErrorAlert;
3440
- _context.next = 3;
3441
- return axios.request(config);
3442
-
3443
- case 3:
3444
- result = _context.sent;
3445
-
3446
- if (!(result.errCode === 30 && !noRedirect)) {
3447
- _context.next = 10;
3448
- break;
3449
- }
3450
-
3451
- _context.next = 7;
3452
- return FServiceAPI.User.logout();
3453
-
3454
- case 7:
3455
- window.location.replace("" + completeUrlByDomain('user') + login({
3475
+ while (1) switch (_context.prev = _context.next) {
3476
+ case 0:
3477
+ _ref = _temp === void 0 ? {} : _temp, _ref$noRedirect = _ref.noRedirect, noRedirect = _ref$noRedirect === void 0 ? false : _ref$noRedirect, _ref$noErrorAlert = _ref.noErrorAlert, noErrorAlert = _ref$noErrorAlert === void 0 ? false : _ref$noErrorAlert;
3478
+ _context.next = 3;
3479
+ return axios.request(config);
3480
+ case 3:
3481
+ result = _context.sent;
3482
+ if (!(result.errCode === 30 && !noRedirect)) {
3483
+ _context.next = 10;
3484
+ break;
3485
+ }
3486
+ _context.next = 7;
3487
+ return FServiceAPI.User.logout();
3488
+ case 7:
3489
+ window.location.replace("" + completeUrlByDomain('user') + login({
3490
+ goTo: window.location.href
3491
+ }));
3492
+ _context.next = 11;
3493
+ break;
3494
+ case 10:
3495
+ if (result.ret === 4 && result.errCode === 10 && !noRedirect) {
3496
+ window.location.replace("" + completeUrlByDomain('user') + userFreeze({
3456
3497
  goTo: window.location.href
3457
3498
  }));
3458
- _context.next = 11;
3459
- break;
3460
-
3461
- case 10:
3462
- if (result.ret === 4 && result.errCode === 10 && !noRedirect) {
3463
- window.location.replace("" + completeUrlByDomain('user') + userFreeze({
3464
- goTo: window.location.href
3465
- }));
3466
- }
3467
-
3468
- case 11:
3469
- return _context.abrupt("return", result);
3470
-
3471
- case 12:
3472
- case "end":
3473
- return _context.stop();
3474
- }
3499
+ }
3500
+ case 11:
3501
+ return _context.abrupt("return", result);
3502
+ case 12:
3503
+ case "end":
3504
+ return _context.stop();
3475
3505
  }
3476
3506
  }, _callee);
3477
3507
  }));
@@ -3480,20 +3510,16 @@ function _request() {
3480
3510
 
3481
3511
  function useGetState(initVal) {
3482
3512
  var _React$useState = React.useState(initVal),
3483
- state = _React$useState[0],
3484
- setState = _React$useState[1];
3485
-
3513
+ state = _React$useState[0],
3514
+ setState = _React$useState[1];
3486
3515
  var ref = React.useRef(initVal);
3487
-
3488
3516
  function setStateCopy(newVal) {
3489
3517
  ref.current = newVal;
3490
3518
  setState(newVal);
3491
3519
  }
3492
-
3493
3520
  function getState() {
3494
3521
  return ref.current;
3495
3522
  }
3496
-
3497
3523
  return [state, setStateCopy, getState];
3498
3524
  }
3499
3525
 
@@ -3502,6 +3528,7 @@ var Hook = {
3502
3528
  useGetState: useGetState
3503
3529
  };
3504
3530
 
3531
+ // import I18n from '../i18n';
3505
3532
  var FUtil = {
3506
3533
  Format: Format,
3507
3534
  Regexp: Regexp,
@@ -3524,12 +3551,11 @@ var allLanguage = [{
3524
3551
  value: 'zh_CN',
3525
3552
  label: '简体中文'
3526
3553
  }];
3527
-
3528
3554
  var I18nNext = /*#__PURE__*/function () {
3529
3555
  function I18nNext() {
3530
3556
  this._loadingData = 'NotStart';
3531
- this._taskQueue = []; // private _currentLanguage: LanguageKeyType = window.localStorage.getItem(localStorage_i18nextLng_key) as null || 'zh_CN';
3532
-
3557
+ this._taskQueue = [];
3558
+ // private _currentLanguage: LanguageKeyType = window.localStorage.getItem(localStorage_i18nextLng_key) as null || 'zh_CN';
3533
3559
  this._currentLanguage = Cookies.get(localStorage_i18nextLng_key) || 'zh_CN';
3534
3560
  this.ready();
3535
3561
  this.ready = this.ready.bind(this);
@@ -3538,100 +3564,77 @@ var I18nNext = /*#__PURE__*/function () {
3538
3564
  this.getAllLanguage = this.getAllLanguage.bind(this);
3539
3565
  this.getCurrentLanguage = this.getCurrentLanguage.bind(this);
3540
3566
  }
3541
-
3542
3567
  var _proto = I18nNext.prototype;
3543
-
3544
3568
  _proto.ready = /*#__PURE__*/function () {
3545
- var _ready = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
3569
+ var _ready = /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
3546
3570
  var _this = this;
3547
-
3548
3571
  var exc, handleTasks, promise;
3549
3572
  return _regeneratorRuntime().wrap(function _callee2$(_context2) {
3550
- while (1) {
3551
- switch (_context2.prev = _context2.next) {
3552
- case 0:
3553
- exc = function exc() {
3554
- while (_this._taskQueue.length > 0) {
3555
- var task = _this._taskQueue.shift();
3556
-
3557
- task && task();
3558
- }
3559
- };
3560
-
3561
- handleTasks = /*#__PURE__*/function () {
3562
- var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
3563
- return _regeneratorRuntime().wrap(function _callee$(_context) {
3564
- while (1) {
3565
- switch (_context.prev = _context.next) {
3566
- case 0:
3567
- if (!(_this._loadingData === 'End')) {
3568
- _context.next = 3;
3569
- break;
3570
- }
3571
-
3572
- exc();
3573
- return _context.abrupt("return");
3574
-
3575
- case 3:
3576
- if (!(_this._loadingData === 'Start')) {
3577
- _context.next = 5;
3578
- break;
3579
- }
3580
-
3581
- return _context.abrupt("return");
3582
-
3583
- case 5:
3584
- // NO_START
3585
- _this._loadingData = 'Start';
3586
- _context.next = 8;
3587
- return _this._handleData();
3588
-
3589
- case 8:
3590
- // console.log('######');
3591
- exc();
3592
-
3593
- case 9:
3594
- case "end":
3595
- return _context.stop();
3573
+ while (1) switch (_context2.prev = _context2.next) {
3574
+ case 0:
3575
+ exc = function exc() {
3576
+ while (_this._taskQueue.length > 0) {
3577
+ var task = _this._taskQueue.shift();
3578
+ task && task();
3579
+ }
3580
+ };
3581
+ handleTasks = /*#__PURE__*/function () {
3582
+ var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
3583
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
3584
+ while (1) switch (_context.prev = _context.next) {
3585
+ case 0:
3586
+ if (!(_this._loadingData === 'End')) {
3587
+ _context.next = 3;
3588
+ break;
3596
3589
  }
3597
- }
3598
- }, _callee);
3599
- }));
3600
-
3601
- return function handleTasks() {
3602
- return _ref.apply(this, arguments);
3603
- };
3604
- }();
3605
-
3606
- promise = new Promise(function (resolve) {
3607
- _this._taskQueue.push(resolve);
3608
- });
3609
- handleTasks();
3610
- return _context2.abrupt("return", promise);
3611
-
3612
- case 5:
3613
- case "end":
3614
- return _context2.stop();
3615
- }
3590
+ exc();
3591
+ return _context.abrupt("return");
3592
+ case 3:
3593
+ if (!(_this._loadingData === 'Start')) {
3594
+ _context.next = 5;
3595
+ break;
3596
+ }
3597
+ return _context.abrupt("return");
3598
+ case 5:
3599
+ // NO_START
3600
+ _this._loadingData = 'Start';
3601
+ _context.next = 8;
3602
+ return _this._handleData();
3603
+ case 8:
3604
+ // console.log('######');
3605
+ exc();
3606
+ case 9:
3607
+ case "end":
3608
+ return _context.stop();
3609
+ }
3610
+ }, _callee);
3611
+ }));
3612
+ return function handleTasks() {
3613
+ return _ref.apply(this, arguments);
3614
+ };
3615
+ }();
3616
+ promise = new Promise(function (resolve) {
3617
+ _this._taskQueue.push(resolve);
3618
+ });
3619
+ handleTasks();
3620
+ return _context2.abrupt("return", promise);
3621
+ case 5:
3622
+ case "end":
3623
+ return _context2.stop();
3616
3624
  }
3617
3625
  }, _callee2);
3618
3626
  }));
3619
-
3620
3627
  function ready() {
3621
3628
  return _ready.apply(this, arguments);
3622
3629
  }
3623
-
3624
3630
  return ready;
3625
3631
  }();
3626
-
3627
3632
  _proto.t = function t(key, options) {
3628
3633
  return i18next.t(key.trim(), options);
3629
3634
  };
3630
-
3631
3635
  _proto.tJSXElement = function tJSXElement(key, options) {
3632
3636
  return htmlReactParser(i18next.t(key.trim(), options));
3633
3637
  };
3634
-
3635
3638
  _proto.changeLanguage = function changeLanguage(lng) {
3636
3639
  // return i18next.changeLanguage(lng);
3637
3640
  // window.localStorage.setItem(localStorage_i18nextLng_key, lng)
@@ -3640,135 +3643,108 @@ var I18nNext = /*#__PURE__*/function () {
3640
3643
  domain: FUtil.Format.completeUrlByDomain('').replace(/http(s)?:\/\//, '')
3641
3644
  });
3642
3645
  };
3643
-
3644
3646
  _proto.getAllLanguage = function getAllLanguage() {
3645
3647
  return allLanguage;
3646
3648
  };
3647
-
3648
3649
  _proto.getCurrentLanguage = function getCurrentLanguage() {
3649
3650
  return this._currentLanguage;
3650
3651
  };
3651
-
3652
3652
  _proto._handleData = /*#__PURE__*/function () {
3653
- var _handleData2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
3653
+ var _handleData2 = /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3() {
3654
3654
  var lng, resource, i18nextResources;
3655
3655
  return _regeneratorRuntime().wrap(function _callee3$(_context3) {
3656
- while (1) {
3657
- switch (_context3.prev = _context3.next) {
3658
- case 0:
3659
- lng = this._currentLanguage;
3660
- resource = window.localStorage.getItem(localStorage_i18nextResources_key); // const resource: string | undefined = Cookies.get(decodeURIComponent(localStorage_i18nextResources_key));
3661
-
3662
- i18nextResources = resource ? JSON.parse(resource) : null;
3663
-
3664
- if (i18nextResources) {
3665
- _context3.next = 9;
3666
- break;
3667
- }
3668
-
3669
- _context3.next = 6;
3670
- return this._fetchData();
3671
-
3672
- case 6:
3673
- i18nextResources = _context3.sent;
3674
- _context3.next = 10;
3656
+ while (1) switch (_context3.prev = _context3.next) {
3657
+ case 0:
3658
+ lng = this._currentLanguage;
3659
+ resource = window.localStorage.getItem(localStorage_i18nextResources_key); // const resource: string | undefined = Cookies.get(decodeURIComponent(localStorage_i18nextResources_key));
3660
+ i18nextResources = resource ? JSON.parse(resource) : null;
3661
+ if (i18nextResources) {
3662
+ _context3.next = 9;
3675
3663
  break;
3676
-
3677
- case 9:
3678
- this._fetchData();
3679
-
3680
- case 10:
3681
- _context3.next = 12;
3682
- return i18next.init({
3683
- // the translations
3684
- // (tip move them in a JSON file and import them,
3685
- // or even better, manage them via a UI: https://react.i18next.com/guides/multiple-translation-files#manage-your-translations-with-a-management-gui)
3686
- resources: i18nextResources,
3687
- lng: lng,
3688
- fallbackLng: 'zh_CN',
3689
- interpolation: {
3690
- escapeValue: false,
3691
- prefix: '{',
3692
- suffix: '}'
3693
- }
3694
- });
3695
-
3696
- case 12:
3697
- this._loadingData = 'End';
3698
-
3699
- case 13:
3700
- case "end":
3701
- return _context3.stop();
3702
- }
3664
+ }
3665
+ _context3.next = 6;
3666
+ return this._fetchData();
3667
+ case 6:
3668
+ i18nextResources = _context3.sent;
3669
+ _context3.next = 10;
3670
+ break;
3671
+ case 9:
3672
+ this._fetchData();
3673
+ case 10:
3674
+ _context3.next = 12;
3675
+ return i18next.init({
3676
+ // the translations
3677
+ // (tip move them in a JSON file and import them,
3678
+ // or even better, manage them via a UI: https://react.i18next.com/guides/multiple-translation-files#manage-your-translations-with-a-management-gui)
3679
+ resources: i18nextResources,
3680
+ lng: lng,
3681
+ fallbackLng: 'zh_CN',
3682
+ interpolation: {
3683
+ escapeValue: false,
3684
+ prefix: '{',
3685
+ suffix: '}'
3686
+ }
3687
+ });
3688
+ case 12:
3689
+ this._loadingData = 'End';
3690
+ case 13:
3691
+ case "end":
3692
+ return _context3.stop();
3703
3693
  }
3704
3694
  }, _callee3, this);
3705
3695
  }));
3706
-
3707
3696
  function _handleData() {
3708
3697
  return _handleData2.apply(this, arguments);
3709
3698
  }
3710
-
3711
3699
  return _handleData;
3712
3700
  }();
3713
-
3714
3701
  _proto._fetchData = /*#__PURE__*/function () {
3715
- var _fetchData2 = /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
3702
+ var _fetchData2 = /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4() {
3716
3703
  var url, res, en_US, zh_CN, _i, _Object$entries, _Object$entries$_i, key, value, result;
3717
-
3718
3704
  return _regeneratorRuntime().wrap(function _callee4$(_context4) {
3719
- while (1) {
3720
- switch (_context4.prev = _context4.next) {
3721
- case 0:
3722
- url = window.location.origin.includes('.freelog.com') ? ossJsonUrl : ossJsonUrl_Test;
3723
- _context4.next = 3;
3724
- return axios.get(url + '?timestamp=' + Date.now(), {
3725
- withCredentials: false
3726
- });
3727
-
3728
- case 3:
3729
- res = _context4.sent;
3730
- // console.log(res, 'data09oiw3qjelsfkdfjlsdkfjl');
3731
- en_US = {};
3732
- zh_CN = {};
3733
-
3734
- for (_i = 0, _Object$entries = Object.entries(res); _i < _Object$entries.length; _i++) {
3735
- _Object$entries$_i = _Object$entries[_i], key = _Object$entries$_i[0], value = _Object$entries$_i[1];
3736
- // console.log(key, value, 'key, value90iowsldfjlsdkj');
3737
- en_US[key] = value['en_US'];
3738
- zh_CN[key] = value['zh_CN'];
3705
+ while (1) switch (_context4.prev = _context4.next) {
3706
+ case 0:
3707
+ url = window.location.origin.includes('.freelog.com') ? ossJsonUrl : ossJsonUrl_Test;
3708
+ _context4.next = 3;
3709
+ return axios.get(url + '?timestamp=' + Date.now(), {
3710
+ withCredentials: false
3711
+ });
3712
+ case 3:
3713
+ res = _context4.sent;
3714
+ // console.log(res, 'data09oiw3qjelsfkdfjlsdkfjl');
3715
+ en_US = {};
3716
+ zh_CN = {};
3717
+ for (_i = 0, _Object$entries = Object.entries(res); _i < _Object$entries.length; _i++) {
3718
+ _Object$entries$_i = _Object$entries[_i], key = _Object$entries$_i[0], value = _Object$entries$_i[1];
3719
+ // console.log(key, value, 'key, value90iowsldfjlsdkj');
3720
+ en_US[key] = value['en_US'];
3721
+ zh_CN[key] = value['zh_CN'];
3722
+ }
3723
+ result = {
3724
+ en_US: {
3725
+ translation: en_US
3726
+ },
3727
+ zh_CN: {
3728
+ translation: zh_CN
3739
3729
  }
3740
-
3741
- result = {
3742
- en_US: {
3743
- translation: en_US
3744
- },
3745
- zh_CN: {
3746
- translation: zh_CN
3747
- }
3748
- }; // console.log(result, 'result093sdolkfjlsdkjl');
3749
-
3750
- window.localStorage.setItem(localStorage_i18nextResources_key, JSON.stringify(result)); // Cookies.set(localStorage_i18nextResources_key, encodeURIComponent(JSON.stringify(result)), {
3751
- // expires: 36525,
3752
- // domain: FUtil.Format.completeUrlByDomain('').replace(/http(s)?:\/\//, ''),
3753
- // });
3754
-
3755
- return _context4.abrupt("return", result);
3756
-
3757
- case 10:
3758
- case "end":
3759
- return _context4.stop();
3760
- }
3730
+ }; // console.log(result, 'result093sdolkfjlsdkjl');
3731
+ window.localStorage.setItem(localStorage_i18nextResources_key, JSON.stringify(result));
3732
+ // Cookies.set(localStorage_i18nextResources_key, encodeURIComponent(JSON.stringify(result)), {
3733
+ // expires: 36525,
3734
+ // domain: FUtil.Format.completeUrlByDomain('').replace(/http(s)?:\/\//, ''),
3735
+ // });
3736
+ return _context4.abrupt("return", result);
3737
+ case 10:
3738
+ case "end":
3739
+ return _context4.stop();
3761
3740
  }
3762
3741
  }, _callee4);
3763
3742
  }));
3764
-
3765
3743
  function _fetchData() {
3766
3744
  return _fetchData2.apply(this, arguments);
3767
3745
  }
3768
-
3769
3746
  return _fetchData;
3770
3747
  }();
3771
-
3772
3748
  return I18nNext;
3773
3749
  }();
3774
3750