@egova/egova-api 1.3.7 → 1.3.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -150,6 +150,13 @@ var POLYFILL = isForced.POLYFILL = 'P';
150
150
  module.exports = isForced;
151
151
 
152
152
 
153
+ /***/ }),
154
+
155
+ /***/ "06a8":
156
+ /***/ (function(module, exports, __webpack_require__) {
157
+
158
+ // extracted by mini-css-extract-plugin
159
+
153
160
  /***/ }),
154
161
 
155
162
  /***/ "07ab":
@@ -189,6 +196,13 @@ module.exports = "<i-modal draggable sticky transfer reset-drag-position :mask-c
189
196
 
190
197
  /***/ }),
191
198
 
199
+ /***/ "0a2e":
200
+ /***/ (function(module, exports, __webpack_require__) {
201
+
202
+ // extracted by mini-css-extract-plugin
203
+
204
+ /***/ }),
205
+
192
206
  /***/ "0d9b":
193
207
  /***/ (function(module, exports, __webpack_require__) {
194
208
 
@@ -1096,11 +1110,12 @@ function readToken(key) {
1096
1110
  }
1097
1111
  function getToken() {
1098
1112
  var _a;
1099
- // 获取是否通过用户中心认证
1100
- var isUserCenter = enableUserCenterCookie();
1101
- // 获取token
1102
- var keys = isUserCenter ? SSO_KEY : COMMON_KEYS;
1103
- var token = (_a = keys.map(readToken).find(Boolean)) !== null && _a !== void 0 ? _a : '';
1113
+ // 1. 获取SSO_token
1114
+ var ssoToken = SSO_KEY.map(readToken).find(Boolean);
1115
+ // 2. 根据 SSO_KEY token 与 配置存在性决定是否用户中心
1116
+ var isUserCenter = enableUserCenterCookie() && !!ssoToken;
1117
+ // 3. 获取最终 token(优先使用 ssoToken 或回退 COMMON_KEYS)
1118
+ var token = isUserCenter ? ssoToken : (_a = COMMON_KEYS.map(readToken).find(Boolean)) !== null && _a !== void 0 ? _a : '';
1104
1119
  // 获取headers
1105
1120
  var headers = isUserCenter ? {
1106
1121
  "X-Authorization": "Bearer ".concat(token)
@@ -2191,6 +2206,9 @@ var tree_selector_TreeSelectorComponent = /** @class */function (_super) {
2191
2206
  return [];
2192
2207
  }
2193
2208
  })], TreeSelectorComponent.prototype, "treeData", void 0);
2209
+ __decorate([Object(flagwind_web_["config"])({
2210
+ default: "请输入"
2211
+ })], TreeSelectorComponent.prototype, "placeholder", void 0);
2194
2212
  __decorate([Object(flagwind_web_["config"])({
2195
2213
  default: "children"
2196
2214
  })], TreeSelectorComponent.prototype, "leafName", void 0);
@@ -6533,6 +6551,30 @@ var service_ApiService = /** @class */function (_super) {
6533
6551
  ApiService.prototype.onValidateImport = function (data) {
6534
6552
  return this._post("/unity/api/info/check-name", data);
6535
6553
  };
6554
+ ApiService.prototype.getEgovaApiTree = function () {
6555
+ return this._get("/unity/wizdom-api/tree");
6556
+ };
6557
+ ApiService.prototype.getProjectList = function (condition) {
6558
+ if (condition === void 0) {
6559
+ condition = {};
6560
+ }
6561
+ return this._post("/unity/api/project/list", condition);
6562
+ };
6563
+ ApiService.prototype.getApiRequestParams = function (apiId) {
6564
+ return this._get("/unity/api/request-param/apiId/".concat(apiId));
6565
+ };
6566
+ ApiService.prototype.getCategoryList = function () {
6567
+ return this._get("/unity/proxy/tree");
6568
+ };
6569
+ ApiService.prototype.getProxyNameList = function (apiId) {
6570
+ return this._get("/unity/proxy/getbyapi?apiId=".concat(apiId));
6571
+ };
6572
+ ApiService.prototype.save = function (config) {
6573
+ if (config.id) {
6574
+ return this._put("/unity/proxy", config);
6575
+ }
6576
+ return this._post("/unity/proxy", config);
6577
+ };
6536
6578
  __decorate([serviceHandler("query", {
6537
6579
  title: "获取接口树"
6538
6580
  })], ApiService.prototype, "getApiTree", null);
@@ -6653,6 +6695,26 @@ var service_ApiService = /** @class */function (_super) {
6653
6695
  title: "单接口详情导入",
6654
6696
  showErrorMsg: true
6655
6697
  })], ApiService.prototype, "onValidateImport", null);
6698
+ __decorate([serviceHandler("query", {
6699
+ title: "获取egova接口树"
6700
+ })], ApiService.prototype, "getEgovaApiTree", null);
6701
+ __decorate([serviceHandler("query", {
6702
+ title: "获取API项目列表"
6703
+ })], ApiService.prototype, "getProjectList", null);
6704
+ __decorate([serviceHandler("query", {
6705
+ title: "获取API参数列表"
6706
+ })], ApiService.prototype, "getApiRequestParams", null);
6707
+ __decorate([serviceHandler("query", {
6708
+ title: "查询分类树"
6709
+ })], ApiService.prototype, "getCategoryList", null);
6710
+ __decorate([serviceHandler("query", {
6711
+ title: "查询代理详情"
6712
+ })], ApiService.prototype, "getProxyNameList", null);
6713
+ __decorate([serviceHandler("save", {
6714
+ title: "保存接口配置",
6715
+ showTip: true,
6716
+ showErrorMsg: true
6717
+ })], ApiService.prototype, "save", null);
6656
6718
  return ApiService;
6657
6719
  }(common_service);
6658
6720
  /* harmony default export */ var project_detail_service = (service_ApiService);
@@ -9107,6 +9169,700 @@ var security_setting_v2_SecuritySettingV2 = /** @class */function (_super) {
9107
9169
  return SecuritySettingV2;
9108
9170
  }(flagwind_web_["Component"]);
9109
9171
  /* harmony default export */ var project_detail_security_setting_v2 = (security_setting_v2_SecuritySettingV2);
9172
+ // EXTERNAL MODULE: ./src/views/project-detail/interface-settings/tips-table-label/index.scss
9173
+ var tips_table_label = __webpack_require__("0a2e");
9174
+
9175
+ // CONCATENATED MODULE: ./src/views/project-detail/interface-settings/tips-table-label/index.ts
9176
+
9177
+
9178
+
9179
+ var tips_table_label_TipsTableLabel = /** @class */function (_super) {
9180
+ __extends(TipsTableLabel, _super);
9181
+ function TipsTableLabel() {
9182
+ var _this = _super !== null && _super.apply(this, arguments) || this;
9183
+ _this.columns = [{
9184
+ title: "次数",
9185
+ key: "header",
9186
+ width: "100"
9187
+ }, {
9188
+ title: "5",
9189
+ key: "five"
9190
+ }, {
9191
+ title: "6",
9192
+ key: "six"
9193
+ }, {
9194
+ title: "7",
9195
+ key: "seven"
9196
+ }, {
9197
+ title: "8",
9198
+ key: "eight"
9199
+ }, {
9200
+ title: "9",
9201
+ key: "nine"
9202
+ }, {
9203
+ title: "10",
9204
+ key: "ten"
9205
+ }];
9206
+ _this.data = [{
9207
+ header: "覆盖范围",
9208
+ five: "1h",
9209
+ six: "2h",
9210
+ seven: "4h",
9211
+ eight: "8h",
9212
+ nine: "16h",
9213
+ ten: "32h"
9214
+ }];
9215
+ return _this;
9216
+ }
9217
+ __decorate([Object(flagwind_web_["config"])({
9218
+ default: ""
9219
+ })], TipsTableLabel.prototype, "tips", void 0);
9220
+ __decorate([Object(flagwind_web_["config"])({
9221
+ default: ""
9222
+ })], TipsTableLabel.prototype, "labelTitle", void 0);
9223
+ __decorate([Object(flagwind_web_["config"])({
9224
+ default: 520
9225
+ })], TipsTableLabel.prototype, "width", void 0);
9226
+ __decorate([Object(flagwind_web_["config"])({
9227
+ type: Boolean,
9228
+ default: false
9229
+ })], TipsTableLabel.prototype, "labelColon", void 0);
9230
+ TipsTableLabel = __decorate([Object(flagwind_web_["component"])({
9231
+ template: __webpack_require__("dc41")
9232
+ })], TipsTableLabel);
9233
+ return TipsTableLabel;
9234
+ }(flagwind_web_["Component"]);
9235
+ /* harmony default export */ var interface_settings_tips_table_label = (tips_table_label_TipsTableLabel);
9236
+ // CONCATENATED MODULE: ./src/models/common/resource.ts
9237
+ /**
9238
+ * 资源目录资源model
9239
+ */
9240
+ var ShareType;
9241
+ (function (ShareType) {
9242
+ ShareType["Private"] = "0";
9243
+ ShareType["Public"] = "1";
9244
+ ShareType["Protected"] = "2";
9245
+ })(ShareType || (ShareType = {}));
9246
+ var ShareMode;
9247
+ (function (ShareMode) {
9248
+ ShareMode["PlateForm"] = "1";
9249
+ ShareMode["Email"] = "2";
9250
+ ShareMode["CopyDisk"] = "3";
9251
+ ShareMode["MediumExchange"] = "4";
9252
+ })(ShareMode || (ShareMode = {}));
9253
+ var ResourceType;
9254
+ (function (ResourceType) {
9255
+ ResourceType["ElectronicFile"] = "1";
9256
+ ResourceType["ElectronicExcel"] = "2";
9257
+ ResourceType["Database"] = "3";
9258
+ ResourceType["GraphicImage"] = "4";
9259
+ ResourceType["StreamingMedia"] = "5";
9260
+ })(ResourceType || (ResourceType = {}));
9261
+ var UpdatePeriod;
9262
+ (function (UpdatePeriod) {
9263
+ UpdatePeriod["Realtime"] = "1";
9264
+ UpdatePeriod["Daily"] = "2";
9265
+ UpdatePeriod["Weekly"] = "3";
9266
+ UpdatePeriod["Monthly"] = "4";
9267
+ UpdatePeriod["Quarterly"] = "5";
9268
+ UpdatePeriod["Annually"] = "6";
9269
+ UpdatePeriod["Irregular"] = "7";
9270
+ UpdatePeriod["Other"] = "8";
9271
+ })(UpdatePeriod || (UpdatePeriod = {}));
9272
+ var ResourceStatus;
9273
+ (function (ResourceStatus) {
9274
+ ResourceStatus["Unreleased"] = "0";
9275
+ ResourceStatus["Released"] = "1";
9276
+ })(ResourceStatus || (ResourceStatus = {}));
9277
+ var updatePeriodList = [{
9278
+ code: "Realtime",
9279
+ value: "1",
9280
+ name: "实时"
9281
+ }, {
9282
+ code: "Daily",
9283
+ value: "2",
9284
+ name: "每天"
9285
+ }, {
9286
+ code: "Weekly",
9287
+ value: "3",
9288
+ name: "每周"
9289
+ }, {
9290
+ code: "Monthly",
9291
+ value: "4",
9292
+ name: "每月"
9293
+ }, {
9294
+ code: "Quarterly",
9295
+ value: "5",
9296
+ name: "每季度"
9297
+ }, {
9298
+ code: "Annually",
9299
+ value: "6",
9300
+ name: "每年"
9301
+ }, {
9302
+ code: "Irregular",
9303
+ value: "7",
9304
+ name: "不定期更新"
9305
+ }, {
9306
+ code: "Other",
9307
+ value: "8",
9308
+ name: "其他"
9309
+ }];
9310
+ var checkFlag = [{
9311
+ value: 0,
9312
+ name: "不开启"
9313
+ }, {
9314
+ value: 1,
9315
+ name: "开启"
9316
+ }];
9317
+ var resource_authFlag = [{
9318
+ value: 0,
9319
+ name: "否"
9320
+ }, {
9321
+ value: 1,
9322
+ name: "是"
9323
+ }];
9324
+ var logLevelList = [{
9325
+ value: 0,
9326
+ name: "不记录"
9327
+ }, {
9328
+ value: 1,
9329
+ name: "记录全部"
9330
+ }, {
9331
+ value: 2,
9332
+ name: "记录失败"
9333
+ }];
9334
+ // EXTERNAL MODULE: ./src/views/project-detail/interface-settings/process-drawer/index.scss
9335
+ var process_drawer = __webpack_require__("06a8");
9336
+
9337
+ // CONCATENATED MODULE: ./src/views/project-detail/util.ts
9338
+ /**
9339
+ * 构建接口完整地址
9340
+ * @param code 接口编码
9341
+ * @returns
9342
+ */
9343
+ function formatUrl(code) {
9344
+ var prefix = prefixUrl();
9345
+ return "".concat(prefix, "/api/exchange/").concat(code);
9346
+ }
9347
+ function prefixUrl() {
9348
+ var baseUrl = window.commonSetting.baseUrl || "";
9349
+ var result = "";
9350
+ if (baseUrl && baseUrl.startsWith("https://") || baseUrl.startsWith("http://")) {
9351
+ result = "".concat(baseUrl);
9352
+ } else if (baseUrl && baseUrl.startsWith("/")) {
9353
+ result = "".concat(window.location.origin).concat(baseUrl);
9354
+ } else if (baseUrl) {
9355
+ result = "".concat(window.location.origin, "/").concat(baseUrl);
9356
+ } else {
9357
+ result = "".concat(window.location.origin);
9358
+ }
9359
+ return result;
9360
+ }
9361
+ // CONCATENATED MODULE: ./src/views/project-detail/interface-settings/process-drawer/index.ts
9362
+
9363
+
9364
+
9365
+
9366
+
9367
+
9368
+
9369
+
9370
+
9371
+ var process_drawer_InterfaceModal = /** @class */function (_super) {
9372
+ __extends(InterfaceModal, _super);
9373
+ function InterfaceModal() {
9374
+ var _this = _super !== null && _super.apply(this, arguments) || this;
9375
+ _this.egovaApiTree = [];
9376
+ _this.projectList = [];
9377
+ _this.model = {
9378
+ name: "",
9379
+ code: "",
9380
+ categoryId: "",
9381
+ retryTimes: "",
9382
+ description: "",
9383
+ enableRetry: "false",
9384
+ authFlag: 1,
9385
+ logSavingEnabled: 2
9386
+ };
9387
+ _this.apiModel = {};
9388
+ _this.apiTree = [];
9389
+ _this.apiColumns = [{
9390
+ title: "参数名称",
9391
+ key: "name",
9392
+ align: "left",
9393
+ ellipsis: true,
9394
+ tooltip: true
9395
+ }, {
9396
+ title: "参数值",
9397
+ key: "valueContent",
9398
+ align: "left",
9399
+ ellipsis: true,
9400
+ tooltip: true
9401
+ }];
9402
+ _this.apiParamList = [];
9403
+ _this.isRetryList = [{
9404
+ name: "是",
9405
+ value: "true"
9406
+ }, {
9407
+ name: "否",
9408
+ value: "false"
9409
+ }];
9410
+ _this.statusCodeList = [{
9411
+ name: "默认(502,504)",
9412
+ value: "1"
9413
+ }, {
9414
+ name: "自定义",
9415
+ value: "2"
9416
+ }];
9417
+ _this.statusCode = "1";
9418
+ _this.authFlag = resource_authFlag;
9419
+ _this.loginLevelFlag = logLevelList;
9420
+ _this.isResourceCodeEnabled = false;
9421
+ _this.rulesValidate = {};
9422
+ _this.isNameValid = false;
9423
+ _this.isCategoryIdValid = false;
9424
+ _this.isCodeValid = false;
9425
+ _this.isDesValid = false;
9426
+ _this.isRetryTimesValid = false;
9427
+ _this.isRetryCodeValid = false; // 新增状态码校验标志
9428
+ _this.isRetryTimesReadonly = false;
9429
+ _this.isDeatilPage = false;
9430
+ _this.readonly = false;
9431
+ _this.formTitle = "流程配置详情";
9432
+ _this.categoryList = [];
9433
+ _this.isAdding = false;
9434
+ _this.proxyName = "";
9435
+ _this.proxyList = [];
9436
+ return _this;
9437
+ }
9438
+ InterfaceModal.prototype.onStatusCodeChange = function (newVal) {
9439
+ var _this = this;
9440
+ if (newVal !== "2") {
9441
+ this.model.retryCode = "";
9442
+ // 清除校验状态
9443
+ this.isRetryCodeValid = true;
9444
+ this.$nextTick(function () {
9445
+ _this.$refs.configform && _this.$refs.configform.validateField("retryCode", function () {});
9446
+ });
9447
+ }
9448
+ // 只有在自定义状态码时才触发校验
9449
+ if (newVal === "2") {
9450
+ this.$nextTick(function () {
9451
+ _this.$refs.configform && _this.$refs.configform.validateField("retryCode");
9452
+ });
9453
+ }
9454
+ };
9455
+ InterfaceModal.prototype.changeInputStatus = function () {
9456
+ this.isResourceCodeEnabled = Boolean(this.model.authFlag);
9457
+ };
9458
+ Object.defineProperty(InterfaceModal.prototype, "url", {
9459
+ get: function () {
9460
+ return formatUrl(this.model.code || "");
9461
+ },
9462
+ enumerable: false,
9463
+ configurable: true
9464
+ });
9465
+ Object.defineProperty(InterfaceModal.prototype, "show", {
9466
+ get: function () {
9467
+ return this.value;
9468
+ },
9469
+ set: function (value) {
9470
+ this.$emit("input", value);
9471
+ },
9472
+ enumerable: false,
9473
+ configurable: true
9474
+ });
9475
+ InterfaceModal.prototype.onSave = function () {
9476
+ var _this = this;
9477
+ var _a;
9478
+ if (!this.model.logSavingEnabled || this.model.enableRetry === "false") {
9479
+ this.isRetryTimesValid = true;
9480
+ }
9481
+ (_a = this.$refs.configform) === null || _a === void 0 ? void 0 : _a.validate(function (isValid) {
9482
+ return __awaiter(_this, void 0, void 0, function () {
9483
+ var submitModel;
9484
+ return __generator(this, function (_a) {
9485
+ // 1. 表单校验(仅 model 字段有规则,apiModel 无规则不影响)
9486
+ if (!isValid) {
9487
+ return [2 /*return*/, this.$message.warning("请完善配置信息")];
9488
+ }
9489
+ submitModel = __assign(__assign({}, this.model), this.apiModel);
9490
+ this.$emit("on-save", submitModel);
9491
+ return [2 /*return*/];
9492
+ });
9493
+ });
9494
+ });
9495
+ };
9496
+ InterfaceModal.prototype.onCancel = function () {
9497
+ this.show = false;
9498
+ };
9499
+ InterfaceModal.prototype.mounted = function () {
9500
+ return __awaiter(this, void 0, void 0, function () {
9501
+ return __generator(this, function (_a) {
9502
+ this.getEgovaApiTree();
9503
+ this.getProjectList();
9504
+ this.getCategoryList();
9505
+ this.apiModel.projectId = this.info.projectId;
9506
+ this.apiModel.type = "API";
9507
+ // todo 根据typeId获取所有流程配置信息
9508
+ this.rulesValidate = {
9509
+ categoryId: [{
9510
+ validator: this.validateCategoryId,
9511
+ trigger: "blur,change"
9512
+ }],
9513
+ name: [{
9514
+ validator: this.validateName,
9515
+ required: false,
9516
+ trigger: "blur,change"
9517
+ }],
9518
+ code: [{
9519
+ validator: this.validateCode,
9520
+ required: false,
9521
+ trigger: "blur,change"
9522
+ }],
9523
+ description: [{
9524
+ validator: this.validateDescription,
9525
+ required: false,
9526
+ trigger: "blur,change"
9527
+ }],
9528
+ retryTimes: [{
9529
+ validator: this.validateRetryTimes,
9530
+ trigger: "blur,change"
9531
+ }],
9532
+ // 添加retryCode校验规则
9533
+ retryCode: [{
9534
+ validator: this.validateRetryCode,
9535
+ trigger: "blur,change"
9536
+ }]
9537
+ };
9538
+ return [2 /*return*/];
9539
+ });
9540
+ });
9541
+ };
9542
+ InterfaceModal.prototype.validateCategoryId = function (rule, value, callback) {
9543
+ if (!value) {
9544
+ this.isCategoryIdValid = false;
9545
+ callback(new Error("请选择所属分类"));
9546
+ } else {
9547
+ this.isCategoryIdValid = true;
9548
+ callback();
9549
+ }
9550
+ };
9551
+ InterfaceModal.prototype.validateName = function (rule, value, callback) {
9552
+ var val = String(value || "").trim();
9553
+ if (!val) {
9554
+ this.isNameValid = false;
9555
+ callback(new Error("请填写代理名称,不能为空"));
9556
+ } else if (val.length > 50) {
9557
+ this.isNameValid = false;
9558
+ callback(new Error("代理名称长度不能超过50"));
9559
+ } else {
9560
+ this.isNameValid = true;
9561
+ callback();
9562
+ }
9563
+ };
9564
+ InterfaceModal.prototype.validateCode = function (rule, value, callback) {
9565
+ var val = String(value || "").trim();
9566
+ if (!val) {
9567
+ this.isCodeValid = false;
9568
+ callback(new Error("请填写接口编码。不能为空"));
9569
+ } else if (val.length > 80) {
9570
+ this.isCodeValid = false;
9571
+ callback(new Error("接口编码长度不能超过80"));
9572
+ } else {
9573
+ this.isCodeValid = true;
9574
+ callback();
9575
+ }
9576
+ };
9577
+ InterfaceModal.prototype.validateDescription = function (rule, value, callback) {
9578
+ if (value && value.length > 150) {
9579
+ this.isDesValid = false;
9580
+ callback(new Error("描述长度不能超过150"));
9581
+ } else {
9582
+ this.isDesValid = true;
9583
+ callback();
9584
+ }
9585
+ };
9586
+ InterfaceModal.prototype.validateRetryTimes = function (rule, value, callback) {
9587
+ if (this.model.enableRetry === "false") {
9588
+ this.isRetryTimesValid = true;
9589
+ callback();
9590
+ return;
9591
+ }
9592
+ var regular = /(^[1-9]\d*$)/;
9593
+ if (!regular.test(value)) {
9594
+ this.isRetryTimesValid = false;
9595
+ callback(new Error("请输入正整数"));
9596
+ } else {
9597
+ this.isRetryTimesValid = true;
9598
+ callback();
9599
+ }
9600
+ };
9601
+ // 修改状态码校验方法
9602
+ InterfaceModal.prototype.validateRetryCode = function (rule, value, callback) {
9603
+ if (this.statusCode === "2") {
9604
+ if (!value || value.trim() === "") {
9605
+ this.isRetryCodeValid = false;
9606
+ callback(new Error("请输入状态码"));
9607
+ } else {
9608
+ // 校验状态码格式(支持多个以逗号分隔的数字)
9609
+ var codes = value.split(",").map(function (code) {
9610
+ return code.trim();
9611
+ });
9612
+ var isValid = codes.every(function (code) {
9613
+ return /^\d+$/.test(code);
9614
+ });
9615
+ if (!isValid) {
9616
+ this.isRetryCodeValid = false;
9617
+ callback(new Error("格式不正确,为数字或英文逗号分隔的数字"));
9618
+ } else {
9619
+ this.isRetryCodeValid = true;
9620
+ callback();
9621
+ }
9622
+ }
9623
+ } else {
9624
+ this.isRetryCodeValid = true;
9625
+ callback();
9626
+ }
9627
+ };
9628
+ InterfaceModal.prototype.onLogSavingEnabledChange = function (value) {
9629
+ this.model.logSavingEnabled = value;
9630
+ };
9631
+ InterfaceModal.prototype.getCategoryList = function () {
9632
+ return __awaiter(this, void 0, void 0, function () {
9633
+ var res, templateData;
9634
+ return __generator(this, function (_a) {
9635
+ switch (_a.label) {
9636
+ case 0:
9637
+ return [4 /*yield*/, this.service.getCategoryList()];
9638
+ case 1:
9639
+ res = _a.sent();
9640
+ if (res && !res.hasError) {
9641
+ templateData = (res === null || res === void 0 ? void 0 : res.result) || [];
9642
+ if (templateData.length > 0) {
9643
+ templateData.forEach(function (item) {
9644
+ if (!item.parentId) {
9645
+ item.parentId = "virtual_root_directory";
9646
+ }
9647
+ });
9648
+ this.categoryList = [__assign(__assign({}, templateData[0]), {
9649
+ id: "virtual_root_directory",
9650
+ children: templateData,
9651
+ name: "全部",
9652
+ expand: true,
9653
+ parentId: null,
9654
+ parentName: null
9655
+ })];
9656
+ } else {
9657
+ this.categoryList = [{
9658
+ id: "virtual_root_directory",
9659
+ children: templateData,
9660
+ name: "全部",
9661
+ expand: true,
9662
+ parentId: null,
9663
+ parentName: null
9664
+ }];
9665
+ }
9666
+ }
9667
+ return [2 /*return*/];
9668
+ }
9669
+ });
9670
+ });
9671
+ };
9672
+ InterfaceModal.prototype.getEgovaApiTree = function () {
9673
+ return __awaiter(this, void 0, void 0, function () {
9674
+ var result;
9675
+ return __generator(this, function (_a) {
9676
+ switch (_a.label) {
9677
+ case 0:
9678
+ return [4 /*yield*/, this.service.getEgovaApiTree()];
9679
+ case 1:
9680
+ result = _a.sent();
9681
+ this.egovaApiTree = (result === null || result === void 0 ? void 0 : result.result) || [];
9682
+ return [2 /*return*/];
9683
+ }
9684
+ });
9685
+ });
9686
+ };
9687
+ InterfaceModal.prototype.getProjectList = function () {
9688
+ return __awaiter(this, void 0, void 0, function () {
9689
+ var result;
9690
+ return __generator(this, function (_a) {
9691
+ switch (_a.label) {
9692
+ case 0:
9693
+ return [4 /*yield*/, this.service.getProjectList()];
9694
+ case 1:
9695
+ result = _a.sent();
9696
+ this.projectList = (result === null || result === void 0 ? void 0 : result.result) || [];
9697
+ return [2 /*return*/];
9698
+ }
9699
+ });
9700
+ });
9701
+ };
9702
+ InterfaceModal.prototype.freshApiTree = function () {
9703
+ var _a, _b;
9704
+ return __awaiter(this, void 0, void 0, function () {
9705
+ var result, listResult;
9706
+ return __generator(this, function (_c) {
9707
+ switch (_c.label) {
9708
+ case 0:
9709
+ if (!this.proxyName) {
9710
+ try {
9711
+ (_b = (_a = this.$refs.configform) === null || _a === void 0 ? void 0 : _a.resetFields) === null || _b === void 0 ? void 0 : _b.call(_a);
9712
+ } catch (error) {
9713
+ console.warn('resetFields 执行失败:', error);
9714
+ }
9715
+ this.resetForm();
9716
+ }
9717
+ ;
9718
+ if (!this.show) {
9719
+ this.readonly = false;
9720
+ this.isAdding = false;
9721
+ this.formTitle = "流程配置详情";
9722
+ this.proxyName = "";
9723
+ return [2 /*return*/];
9724
+ }
9725
+ if (!this.apiModel.projectId || !this.show) return [2 /*return*/];
9726
+ this.apiTree = this.projectTree || [];
9727
+ this.apiModel.typeId = this.info.id;
9728
+ this.onApiTreeSelect(this.info);
9729
+ return [4 /*yield*/, this.service.getApiRequestParams(this.apiModel.typeId)];
9730
+ case 1:
9731
+ result = _c.sent();
9732
+ this.apiParamList = (result === null || result === void 0 ? void 0 : result.result.filter(function (item) {
9733
+ return !item.disabled;
9734
+ })) || [];
9735
+ return [4 /*yield*/, this.service.getProxyNameList(this.info.id)];
9736
+ case 2:
9737
+ listResult = _c.sent();
9738
+ this.proxyList = (listResult === null || listResult === void 0 ? void 0 : listResult.result) || [];
9739
+ return [2 /*return*/];
9740
+ }
9741
+ });
9742
+ });
9743
+ };
9744
+ InterfaceModal.prototype.enableRetryChange = function (newval, oldVal) {
9745
+ var _a, _b;
9746
+ if (newval === "false") {
9747
+ (_a = this.$refs.configform) === null || _a === void 0 ? void 0 : _a.validateField("retryTimes");
9748
+ this.isRetryTimesReadonly = true;
9749
+ this.model.retryTimes = undefined;
9750
+ } else if (newval === "null") {
9751
+ this.model.enableRetry = "false";
9752
+ this.model.retryTimes = undefined;
9753
+ (_b = this.$refs.configform) === null || _b === void 0 ? void 0 : _b.validateField("retryTimes");
9754
+ this.isRetryTimesReadonly = true;
9755
+ } else {
9756
+ this.isRetryTimesReadonly = false;
9757
+ }
9758
+ };
9759
+ InterfaceModal.prototype.resetFields = function () {
9760
+ var _a, _b;
9761
+ if (!this.proxyName && !this.isAdding) return;
9762
+ // 重置表单校验状态
9763
+ try {
9764
+ (_b = (_a = this.$refs.configform) === null || _a === void 0 ? void 0 : _a.resetFields) === null || _b === void 0 ? void 0 : _b.call(_a);
9765
+ } catch (error) {
9766
+ //
9767
+ }
9768
+ this.isAdding && this.resetForm();
9769
+ };
9770
+ InterfaceModal.prototype.onApiTreeSelect = function (data) {
9771
+ var _a;
9772
+ this.apiModel.path = ((_a = data === null || data === void 0 ? void 0 : data.path) !== null && _a !== void 0 ? _a : data === null || data === void 0 ? void 0 : data.url) || "";
9773
+ };
9774
+ InterfaceModal.prototype.selectProxyName = function (node) {
9775
+ this.formTitle = "流程配置详情";
9776
+ var selectedProxy = this.proxyList.filter(function (item) {
9777
+ return item.id === node.id;
9778
+ })[0];
9779
+ this.model = __assign({}, selectedProxy);
9780
+ this.statusCode = this.model.retryCode ? "2" : "1";
9781
+ if (this.model.enableRetry === true) {
9782
+ this.model.enableRetry = "true";
9783
+ } else if (this.model.enableRetry === false) {
9784
+ this.model.enableRetry = "false";
9785
+ }
9786
+ this.isAdding = false;
9787
+ };
9788
+ InterfaceModal.prototype.selectCategory = function (node) {
9789
+ // 将所选的类型id付给当前类型的父id,实现修改分组
9790
+ this.model.categoryId = node.id;
9791
+ };
9792
+ InterfaceModal.prototype.onCopy = function (content) {
9793
+ var oInput = document.createElement("textarea");
9794
+ try {
9795
+ oInput.value = content;
9796
+ document.body.appendChild(oInput);
9797
+ oInput.select();
9798
+ document.execCommand("Copy");
9799
+ this.$message.success("复制成功");
9800
+ } catch (_a) {
9801
+ //
9802
+ } finally {
9803
+ oInput.remove();
9804
+ }
9805
+ };
9806
+ InterfaceModal.prototype.resetForm = function () {
9807
+ this.model = {
9808
+ name: "",
9809
+ code: "",
9810
+ categoryId: "",
9811
+ description: "",
9812
+ retryTimes: "",
9813
+ enableRetry: "false",
9814
+ authFlag: 1,
9815
+ logSavingEnabled: 2
9816
+ };
9817
+ };
9818
+ InterfaceModal.prototype.onAdd = function () {
9819
+ this.isAdding = true;
9820
+ this.statusCode = "1";
9821
+ this.proxyName = "";
9822
+ this.formTitle = "新增流程配置";
9823
+ };
9824
+ __decorate([Object(flagwind_web_["config"])({
9825
+ type: Boolean,
9826
+ default: false
9827
+ })], InterfaceModal.prototype, "value", void 0);
9828
+ __decorate([Object(flagwind_web_["autowired"])(project_detail_service)], InterfaceModal.prototype, "service", void 0);
9829
+ __decorate([Object(flagwind_web_["config"])({
9830
+ type: Boolean,
9831
+ default: false
9832
+ })], InterfaceModal.prototype, "loading", void 0);
9833
+ __decorate([Object(flagwind_web_["config"])({
9834
+ type: Object,
9835
+ default: {}
9836
+ })], InterfaceModal.prototype, "info", void 0);
9837
+ __decorate([Object(flagwind_web_["config"])({
9838
+ type: Array,
9839
+ default: []
9840
+ })], InterfaceModal.prototype, "projectTree", void 0);
9841
+ __decorate([Object(flagwind_web_["watch"])("statusCode", {
9842
+ immediate: true
9843
+ })], InterfaceModal.prototype, "onStatusCodeChange", null);
9844
+ __decorate([Object(flagwind_web_["watch"])("model.authFlag", {
9845
+ immediate: true
9846
+ })], InterfaceModal.prototype, "changeInputStatus", null);
9847
+ __decorate([Object(flagwind_web_["watch"])("show")], InterfaceModal.prototype, "freshApiTree", null);
9848
+ __decorate([Object(flagwind_web_["watch"])("model.enableRetry", {
9849
+ immediate: true
9850
+ })], InterfaceModal.prototype, "enableRetryChange", null);
9851
+ __decorate([Object(flagwind_web_["watch"])("proxyName", {
9852
+ immediate: true
9853
+ }), Object(flagwind_web_["watch"])("isAdding", {
9854
+ immediate: true
9855
+ })], InterfaceModal.prototype, "resetFields", null);
9856
+ InterfaceModal = __decorate([Object(flagwind_web_["component"])({
9857
+ template: __webpack_require__("40aa"),
9858
+ components: {
9859
+ "u-tree-selector": project_combine_tree_selector,
9860
+ "tips-table-label": interface_settings_tips_table_label
9861
+ }
9862
+ })], InterfaceModal);
9863
+ return InterfaceModal;
9864
+ }(flagwind_web_["Component"]);
9865
+ /* harmony default export */ var interface_settings_process_drawer = (process_drawer_InterfaceModal);
9110
9866
  // CONCATENATED MODULE: ./src/views/project-detail/interface-settings/index.ts
9111
9867
 
9112
9868
 
@@ -9128,6 +9884,7 @@ var security_setting_v2_SecuritySettingV2 = /** @class */function (_super) {
9128
9884
 
9129
9885
 
9130
9886
 
9887
+
9131
9888
  var interface_settings_InterfaceSettings = /** @class */function (_super) {
9132
9889
  __extends(InterfaceSettings, _super);
9133
9890
  function InterfaceSettings() {
@@ -9147,6 +9904,7 @@ var interface_settings_InterfaceSettings = /** @class */function (_super) {
9147
9904
  };
9148
9905
  _this.showImportModal = false; // 导入校验名称弹窗
9149
9906
  _this.importObj = {}; // 解析的导入文件数据
9907
+ _this.showDrawer = false;
9150
9908
  _this.typeList = [{
9151
9909
  value: "GET",
9152
9910
  text: "GET"
@@ -9283,6 +10041,22 @@ var interface_settings_InterfaceSettings = /** @class */function (_super) {
9283
10041
  });
9284
10042
  });
9285
10043
  };
10044
+ InterfaceSettings.prototype.onProcessSave = function (submitModel) {
10045
+ return __awaiter(this, void 0, void 0, function () {
10046
+ return __generator(this, function (_a) {
10047
+ switch (_a.label) {
10048
+ case 0:
10049
+ this.loading = true;
10050
+ return [4 /*yield*/, this.service.save(submitModel)];
10051
+ case 1:
10052
+ _a.sent();
10053
+ this.loading = false;
10054
+ this.showDrawer = false;
10055
+ return [2 /*return*/];
10056
+ }
10057
+ });
10058
+ });
10059
+ };
9286
10060
  InterfaceSettings.prototype.onSave = function () {
9287
10061
  return __awaiter(this, void 0, void 0, function () {
9288
10062
  var tmpInterfaceModel;
@@ -9524,6 +10298,9 @@ var interface_settings_InterfaceSettings = /** @class */function (_super) {
9524
10298
  InterfaceSettings.prototype.onScriptMax = function (data) {
9525
10299
  this.scriptView = data;
9526
10300
  };
10301
+ InterfaceSettings.prototype.onProcess = function () {
10302
+ this.showDrawer = true;
10303
+ };
9527
10304
  __decorate([autowired(project_detail_service)], InterfaceSettings.prototype, "service", void 0);
9528
10305
  __decorate([Object(flagwind_web_["config"])({
9529
10306
  default: function () {
@@ -9536,6 +10313,9 @@ var interface_settings_InterfaceSettings = /** @class */function (_super) {
9536
10313
  __decorate([Object(flagwind_web_["config"])({
9537
10314
  default: ""
9538
10315
  })], InterfaceSettings.prototype, "projectId", void 0);
10316
+ __decorate([Object(flagwind_web_["config"])({
10317
+ default: {}
10318
+ })], InterfaceSettings.prototype, "projectTree", void 0);
9539
10319
  __decorate([Object(flagwind_web_["watch"])("interfaceModel", {
9540
10320
  immediate: true
9541
10321
  })], InterfaceSettings.prototype, "interfaceModelChange", null);
@@ -9550,8 +10330,9 @@ var interface_settings_InterfaceSettings = /** @class */function (_super) {
9550
10330
  "pre-execution": project_detail_pre_execution_setting,
9551
10331
  "after-execution-transfer": project_detail_after_execution_transfer,
9552
10332
  "after-execution-script": after_execution_script,
9553
- "v2security": project_detail_security_setting_v2,
9554
- "u-environment-modal": project_detail_environment_variable_modal
10333
+ v2security: project_detail_security_setting_v2,
10334
+ "u-environment-modal": project_detail_environment_variable_modal,
10335
+ "u-process-drawer": interface_settings_process_drawer
9555
10336
  }
9556
10337
  })], InterfaceSettings);
9557
10338
  return InterfaceSettings;
@@ -10370,6 +11151,7 @@ var tree_ProjectTree = /** @class */function (_super) {
10370
11151
  result = _a.sent();
10371
11152
  this.data = (result === null || result === void 0 ? void 0 : result.result) || [];
10372
11153
  data = this.data.$clone();
11154
+ this.$emit("tree-data", data);
10373
11155
  TreeDataUtil.handlerTreeData2(data, "name");
10374
11156
  this.groupTree = data;
10375
11157
  data = this.data.$clone();
@@ -10547,6 +11329,7 @@ var project_detail_ProjectDetail = /** @class */function (_super) {
10547
11329
  spaceBetween: 0
10548
11330
  };
10549
11331
  _this.current = {};
11332
+ _this.projectTree = [];
10550
11333
  return _this;
10551
11334
  }
10552
11335
  ProjectDetail.prototype.onClickSlide = function (index) {
@@ -10827,6 +11610,9 @@ var project_detail_ProjectDetail = /** @class */function (_super) {
10827
11610
  ProjectDetail.prototype.onEnvironmentRefresh = function () {
10828
11611
  this.$refs["interface-settings"] && this.$refs["interface-settings"].getEnvironmentParamList();
10829
11612
  };
11613
+ ProjectDetail.prototype.getTreeData = function (data) {
11614
+ this.projectTree = data;
11615
+ };
10830
11616
  __decorate([autowired(project_detail_service)], ProjectDetail.prototype, "service", void 0);
10831
11617
  ProjectDetail = __decorate([Object(flagwind_web_["component"])({
10832
11618
  name: "ApiProjectDetail",
@@ -11096,6 +11882,13 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__3fb3__;
11096
11882
 
11097
11883
  /***/ }),
11098
11884
 
11885
+ /***/ "40aa":
11886
+ /***/ (function(module, exports) {
11887
+
11888
+ module.exports = "<!DOCTYPE html>\r\n<i-drawer\r\n width=\"700\"\r\n draggable\r\n sticky\r\n reset-drag-position\r\n v-model=\"show\"\r\n class=\"interface-modal diy-modal\"\r\n transfer\r\n title=\"已关联流程配置\"\r\n :mask-closable=\"false\"\r\n @on-cancel=\"onCancel\"\r\n>\r\n <div class=\"header\">\r\n <u-tree-selector\r\n :treeData=\"proxyList\"\r\n leaf-name=\"apis\"\r\n v-model=\"proxyName\"\r\n @on-select=\"selectProxyName\"\r\n :canChooseFolder=\"true\"\r\n placeholder=\"请选择代理名称\"\r\n ></u-tree-selector>\r\n <i-button class=\"diy-btn-primary\" type=\"primary\" @click=\"onAdd\">新增配置</i-button>\r\n </div>\r\n\r\n <template v-if=\"proxyName || isAdding \"> \r\n <i-form ref=\"configform\" label-position=\"left\" :label-width=\"125\" label-colon :rules=\"rulesValidate\"\r\n :model=\"model\">\r\n <div class=\"form-title\">{{formTitle}}</div>\r\n <i-form-item v-if=\"isAdding\" label=\"所属分类\" prop=\"categoryId\" class=\"proxy-category-validate\" required>\r\n <u-tree-selector :treeData=\"categoryList\" :canChooseFolder=\"true\" v-model=\"model.categoryId\"\r\n @on-select=\"selectCategory\" placeholder=\"请选择所属分类\"></u-tree-selector>\r\n </i-form-item>\r\n <i-form-item label=\"代理名称\" prop=\"name\" class=\"proxy-name-validate\" required>\r\n <i-input class=\"diy-input\" v-model=\"model.name\" placeholder=\"请输入代理名称\"></i-input>\r\n </i-form-item>\r\n <i-form-item class=\"proxy-name-validate\" prop=\"code\" label=\"接口编码\" required>\r\n <i-input class=\"diy-input\" v-model=\"model.code\" placeholder=\"请输入接口编码\"></i-input>\r\n </i-form-item>\r\n <i-form-item class=\"un-required-item copy-item\" label=\"接口地址\">\r\n <i-input class=\"diy-input\" disabled :value=\"url\"></i-input>\r\n <div class=\"set-btn\" @click=\"onCopy(url)\">复制</div>\r\n </i-form-item>\r\n <i-form-item label=\"描述\" prop=\"description\" class=\"proxy-description-validate un-required-item\">\r\n <i-input type=\"textarea\" v-model=\"model.description\" placeholder=\"请输入描述\" :rows=\"2\"></i-input>\r\n </i-form-item>\r\n <i-row class=\"retry-wrap\" style=\"padding-top: 8px\">\r\n <i-col span=\"11\">\r\n <i-form-item class=\"un-required-item copy-item\">\r\n <template #label>\r\n <i-poptip slot=\"label\" trigger=\"hover\"\r\n content=\"日志表会记录请求头、请求参数和响应体,如果内容较多时建议关闭,请求次数频繁比较占数据库资源。选项【失败】仅记录调用失败的日志\" word-wrap\r\n transfer>\r\n <icon style=\"cursor: help; font-size: 0.16rem\" type=\"ios-information-circle-outline\" />\r\n </i-poptip>\r\n <span>记录日志:</span>\r\n </template>\r\n\r\n <i-select class=\"diy-select\" v-model=\"model.logSavingEnabled\"\r\n @on-change=\"onLogSavingEnabledChange\">\r\n <i-option v-for=\"item in loginLevelFlag\" :value=\"item.value\" :key=\"item.value\">{{ item.name\r\n }}</i-option>\r\n </i-select>\r\n </i-form-item>\r\n </i-col>\r\n </i-row>\r\n <template v-if=\"model.logSavingEnabled\">\r\n <i-row class=\"retry-wrap\">\r\n <i-col span=\"11\">\r\n <i-form-item label=\"开启重推\" required>\r\n <i-select class=\"diy-select\" v-model=\"model.enableRetry\">\r\n <i-option v-for=\"(item,index) in isRetryList\" :value=\"item.value\" :key=\"index\">{{\r\n item.name }}</i-option>\r\n </i-select>\r\n </i-form-item>\r\n </i-col>\r\n <i-col span=\"11\">\r\n <i-form-item class=\"un-required-item\" label=\"重推次数\" prop=\"retryTimes\">\r\n <tips-table-label class=\"data-type-tips\" slot=\"label\" label-colon\r\n labelTitle=\"重推次数\"></tips-table-label>\r\n <i-input class=\"diy-input\" type=\"number\"\r\n :disabled=\"isRetryTimesReadonly\" v-model=\"model.retryTimes\"\r\n placeholder=\"请输入重推次数\"></i-input>\r\n </i-form-item>\r\n </i-col>\r\n </i-row>\r\n <i-row v-if=\"model.enableRetry === 'true' \">\r\n <i-col span=\"11\">\r\n <i-form-item class=\"un-required-item status-code\">\r\n <template #label>\r\n <i-poptip slot=\"label\" trigger=\"hover\" content=\"当接口状态码和配置项相同时,才触发重推;多个自定义状态码以英文逗号分隔\"\r\n word-wrap transfer>\r\n <icon style=\"cursor: help; font-size: 0.16rem\"\r\n type=\"ios-information-circle-outline\" />\r\n </i-poptip>\r\n <span>重推接口状态码:</span>\r\n </template>\r\n <i-form-item>\r\n <i-select v-model=\"statusCode\" class=\"diy-select code-select\"\r\n @on-change=\"onStatusCodeChange\">\r\n <i-option v-for=\"item in statusCodeList\" :value=\"item.value\" :key=\"item.value\">{{\r\n item.name }}</i-option>\r\n </i-select>\r\n </i-form-item>\r\n <i-form-item prop=\"retryCode\">\r\n <i-input v-if=\"statusCode === '2'\" class=\"diy-input\" v-model=\"model.retryCode\"\r\n placeholder=\"请输入状态码\"></i-input>\r\n </i-form-item>\r\n </i-form-item>\r\n </i-col>\r\n </i-row>\r\n </template>\r\n\r\n <i-row class=\"retry-wrap\">\r\n <i-col span=\"11\">\r\n <i-form-item label=\"需要认证\" class=\"un-required-item copy-item\">\r\n <i-select class=\"diy-select\" style=\"margin-top: 6px\" v-model=\"model.authFlag\">\r\n <i-option v-for=\"item in authFlag\" :value=\"item.value\" :key=\"item.value\">{{ item.name\r\n }}</i-option>\r\n </i-select>\r\n </i-form-item>\r\n </i-col>\r\n <i-col span=\"11\">\r\n <i-form-item class=\"un-required-item copy-item\">\r\n <template #label>\r\n <i-poptip slot=\"label\" trigger=\"hover\" content=\"使用用户中心token访问该接口时,将校验登陆是否拥有该资源代码的权限\"\r\n word-wrap transfer>\r\n <icon style=\"cursor: help; font-size: 0.16rem\" type=\"ios-information-circle-outline\" />\r\n </i-poptip>\r\n <span>用户中心资源代码:</span>\r\n </template>\r\n <i-input class=\"diy-input\" style=\"margin-top: 6px\" v-model=\"model.resourceCode\"\r\n :disabled=\"!isResourceCodeEnabled\" placeholder=\"请输入用户中心资源代码\"></i-input>\r\n </i-form-item>\r\n </i-col>\r\n </i-row>\r\n <template>\r\n <i-row class=\"retry-wrap\">\r\n <i-col span=\"11\">\r\n <i-form-item label=\"代理类型\">\r\n <i-input class=\"diy-input\" value=\"外部接口\" disabled></i-input>\r\n </i-form-item>\r\n </i-col>\r\n <i-col span=\"11\">\r\n <i-form-item label=\"API项目\">\r\n <i-select disabled class=\"diy-select\" v-model=\"apiModel.projectId\">\r\n <i-option v-for=\"(item,index) in projectList\" :value=\"item.id\" :key=\"item.id\">{{ item.name }}</i-option>\r\n </i-select>\r\n </i-form-item>\r\n </i-col>\r\n </i-row>\r\n <i-form-item label=\"API接口\">\r\n <u-tree-selector readonly :treeData=\"apiTree\" leaf-name=\"apis\" v-model=\"apiModel.typeId\" placeholder=\"请选择API接口\" @on-select=\"onApiTreeSelect\"></u-tree-selector>\r\n </i-form-item>\r\n <i-form-item label=\"接口路径\">\r\n <i-input class=\"diy-input\" :readonly=\"true\" v-model=\"apiModel.path\" :rows=\"4\"></i-input>\r\n </i-form-item>\r\n <i-table class=\"diy-table\" height=\"200\" :columns=\"apiColumns\" :data=\"apiParamList\"> </i-table>\r\n </template>\r\n </i-form>\r\n </template>\r\n <div v-else class=\"no-data\">暂无数据</div>\r\n <div class=\"footer\">\r\n <i-button class=\"diy-btn-primary\" type=\"primary\" :loading=\"loading\" @click.stop=\"onSave\">保存</i-button>\r\n <i-button class=\"diy-btn-default\" @click.stop=\"onCancel\">取消</i-button>\r\n </div>\r\n</i-drawer>"
11889
+
11890
+ /***/ }),
11891
+
11099
11892
  /***/ "42a3":
11100
11893
  /***/ (function(module, exports, __webpack_require__) {
11101
11894
 
@@ -13804,7 +14597,7 @@ module.exports = "<article class=\"catalog-params\">\r\n <i-table height=\"20
13804
14597
  /***/ "a1f0":
13805
14598
  /***/ (function(module, exports) {
13806
14599
 
13807
- module.exports = "<i-poptip\r\n transfer\r\n class=\"u-tree-selector\"\r\n transfer-class-name=\"u-tree-selector\"\r\n trigger=\"click\"\r\n content=\"content\"\r\n placement=\"bottom\"\r\n :disabled=\"readonly\"\r\n v-model=\"visible\"\r\n>\r\n <i-input\r\n class=\"diy-input\"\r\n :value=\"inputValue\"\r\n @on-change=\"onInputChange\"\r\n readonly\r\n />\r\n <i-icon\r\n v-if=\"inputValue && !readonly\"\r\n class=\"icon-clear-value\"\r\n type=\"ios-close-circle\"\r\n @click.stop=\"onClear\"\r\n />\r\n <i-tree\r\n slot=\"content\"\r\n :data=\"tree\"\r\n :render=\"renderContent\"\r\n @on-select-change=\"onSelectChange\"\r\n ></i-tree>\r\n</i-poptip>\r\n"
14600
+ module.exports = "<i-poptip\r\n transfer\r\n class=\"u-tree-selector\"\r\n transfer-class-name=\"u-tree-selector\"\r\n trigger=\"click\"\r\n content=\"content\"\r\n placement=\"bottom\"\r\n :disabled=\"readonly\"\r\n v-model=\"visible\"\r\n>\r\n <i-input\r\n class=\"diy-input\"\r\n :value=\"inputValue\"\r\n @on-change=\"onInputChange\"\r\n :placeholder=\"placeholder\"\r\n readonly\r\n />\r\n <i-icon\r\n v-if=\"inputValue && !readonly\"\r\n class=\"icon-clear-value\"\r\n type=\"ios-close-circle\"\r\n @click.stop=\"onClear\"\r\n />\r\n <i-tree\r\n slot=\"content\"\r\n :data=\"tree\"\r\n :render=\"renderContent\"\r\n @on-select-change=\"onSelectChange\"\r\n ></i-tree>\r\n</i-poptip>\r\n"
13808
14601
 
13809
14602
  /***/ }),
13810
14603
 
@@ -14495,7 +15288,7 @@ module.exports = function (obj) {
14495
15288
  /***/ "d63e":
14496
15289
  /***/ (function(module, exports) {
14497
15290
 
14498
- module.exports = "<article class=\"project-detail\">\r\n <header>\r\n <div class=\"environment\">\r\n <i class=\"iconfont icon-zhankai\" @click=\"onBack\"></i>\r\n <p>{{projectName}}</p>\r\n <!-- <span>环境变量:</span> -->\r\n <!-- <i-select class=\"diy-select\"></i-select> -->\r\n </div>\r\n <div class=\"btns\">\r\n <!-- <i-button type=\"primary\" ghost class=\"diy-btn-primary\" @click=\"onOpenGlobalModal\"> <i class=\"api-icon icon-setting\"></i>全局参数设置</i-button> -->\r\n <!-- <i-button type=\"success\" ghost class=\"diy-btn-success\" @click=\"onOpenCurrentModal\"><i class=\"api-icon icon-view\"></i>查看当前变量</i-button> -->\r\n <i-button v-if=\"projectId && projectName\" type=\"primary\" class=\"diy-btn-primary security-btn\" ghost @click=\"onSecurity\"><i class=\"iconfont icon-xinzengzhibiao\"></i>授权认证</i-button>\r\n <i-button v-if=\"projectId && projectName\" type=\"primary\" class=\"diy-btn-primary\" ghost @click=\"onOpenEnvModal\"><i class=\"iconfont icon-bianliang\"></i>环境变量</i-button>\r\n <i-button v-show=\"active.id\" type=\"primary\" class=\"diy-btn-primary\" ghost @click=\"onToggleLayout\"><i class=\"api-icon icon-switch\"></i>切换布局</i-button>\r\n </div>\r\n </header>\r\n <!-- <main> -->\r\n <i-split v-model=\"split\" min=\"200px\" max=\"900px\">\r\n <u-tree slot=\"left\" @on-check-interface=\"onCheckInterface\" @on-edit-interface-success=\"onEditInterfaceSuccess\" :project-id=\"projectId\" @on-success=\"onBatchSuccess\" @on-delete-interface=\"onDeleteInterface\" @on-reset=\"onReset\"></u-tree>\r\n <section slot=\"right\" class=\"interface-box\">\r\n <header class=\"interface-bar\">\r\n <swiper class=\"swiper\" :options=\"swiperOption\" @click-slide=\"onClickSlide\" @ready=\"onSwiperReadied\">\r\n <swiper-slide class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\"\r\n ><span>{{item.name}}</span> <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon\r\n ></swiper-slide>\r\n </swiper>\r\n <!-- <div class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\">\r\n <span>{{item.name}}</span>\r\n <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon>\r\n </div> -->\r\n </header>\r\n <u-settings ref=\"interface-settings\" :interface-model.sync=\"active\" :project-id=\"projectId\" v-if=\"active.id\" :lengthwise=\"lengthwise\"></u-settings>\r\n </section>\r\n </i-split>\r\n <i-spin fix v-show=\"loading\">\r\n <i class=\"spin-icon-load ivu-icon\"></i>\r\n </i-spin>\r\n <!-- </main> -->\r\n <u-global-modal :visiable.sync=\"showGlobalModal\">\r\n <footer slot=\"footer\">\r\n <i-button @click=\"showGlobalModal = false\">取消</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary\">确定</i-button>\r\n </footer>\r\n </u-global-modal>\r\n <u-current-modal :visiable.sync=\"showCurrentModal\"> </u-current-modal>\r\n <u-security-modal v-model=\"showSecurity\" :projectID=\"projectId\"></u-security-modal>\r\n <u-environment-modal :visiable.sync=\"showEnvironmentModal\" :projectId=\"projectId\" @on-refresh=\"onEnvironmentRefresh\"></u-environment-modal>\r\n</article>\r\n"
15291
+ module.exports = "<article class=\"project-detail\">\r\n <header>\r\n <div class=\"environment\">\r\n <i class=\"iconfont icon-zhankai\" @click=\"onBack\"></i>\r\n <p>{{projectName}}</p>\r\n <!-- <span>环境变量:</span> -->\r\n <!-- <i-select class=\"diy-select\"></i-select> -->\r\n </div>\r\n <div class=\"btns\">\r\n <!-- <i-button type=\"primary\" ghost class=\"diy-btn-primary\" @click=\"onOpenGlobalModal\"> <i class=\"api-icon icon-setting\"></i>全局参数设置</i-button> -->\r\n <!-- <i-button type=\"success\" ghost class=\"diy-btn-success\" @click=\"onOpenCurrentModal\"><i class=\"api-icon icon-view\"></i>查看当前变量</i-button> -->\r\n <i-button v-if=\"projectId && projectName\" type=\"primary\" class=\"diy-btn-primary security-btn\" ghost @click=\"onSecurity\"><i class=\"iconfont icon-xinzengzhibiao\"></i>授权认证</i-button>\r\n <i-button v-if=\"projectId && projectName\" type=\"primary\" class=\"diy-btn-primary\" ghost @click=\"onOpenEnvModal\"><i class=\"iconfont icon-bianliang\"></i>环境变量</i-button>\r\n <i-button v-show=\"active.id\" type=\"primary\" class=\"diy-btn-primary\" ghost @click=\"onToggleLayout\"><i class=\"api-icon icon-switch\"></i>切换布局</i-button>\r\n </div>\r\n </header>\r\n <!-- <main> -->\r\n <i-split v-model=\"split\" min=\"200px\" max=\"900px\">\r\n <u-tree slot=\"left\" @on-check-interface=\"onCheckInterface\" @on-edit-interface-success=\"onEditInterfaceSuccess\" :project-id=\"projectId\" @on-success=\"onBatchSuccess\" @on-delete-interface=\"onDeleteInterface\" @on-reset=\"onReset\" @tree-data=\"getTreeData\"></u-tree>\r\n <section slot=\"right\" class=\"interface-box\">\r\n <header class=\"interface-bar\">\r\n <swiper class=\"swiper\" :options=\"swiperOption\" @click-slide=\"onClickSlide\" @ready=\"onSwiperReadied\">\r\n <swiper-slide class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\"\r\n ><span>{{item.name}}</span> <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon\r\n ></swiper-slide>\r\n </swiper>\r\n <!-- <div class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\">\r\n <span>{{item.name}}</span>\r\n <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon>\r\n </div> -->\r\n </header>\r\n <u-settings ref=\"interface-settings\" :interface-model.sync=\"active\" :project-id=\"projectId\" v-if=\"active.id\" :lengthwise=\"lengthwise\" :projectTree=\"projectTree\"></u-settings>\r\n </section>\r\n </i-split>\r\n <i-spin fix v-show=\"loading\">\r\n <i class=\"spin-icon-load ivu-icon\"></i>\r\n </i-spin>\r\n <!-- </main> -->\r\n <u-global-modal :visiable.sync=\"showGlobalModal\">\r\n <footer slot=\"footer\">\r\n <i-button @click=\"showGlobalModal = false\">取消</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary\">确定</i-button>\r\n </footer>\r\n </u-global-modal>\r\n <u-current-modal :visiable.sync=\"showCurrentModal\"> </u-current-modal>\r\n <u-security-modal v-model=\"showSecurity\" :projectID=\"projectId\"></u-security-modal>\r\n <u-environment-modal :visiable.sync=\"showEnvironmentModal\" :projectId=\"projectId\" @on-refresh=\"onEnvironmentRefresh\"></u-environment-modal>\r\n</article>\r\n"
14499
15292
 
14500
15293
  /***/ }),
14501
15294
 
@@ -14561,6 +15354,13 @@ module.exports = "<div class=\"interface-tree-node\">\r\n <span v-if=\"isLeaf
14561
15354
 
14562
15355
  /***/ }),
14563
15356
 
15357
+ /***/ "dc41":
15358
+ /***/ (function(module, exports) {
15359
+
15360
+ module.exports = "<span>\r\n <i-poptip trigger=\"hover\" :content=\"tips\" word-wrap :width=\"width\" transfer>\r\n <icon\r\n style=\"cursor: help;font-size: 0.16rem;\"\r\n type=\"ios-information-circle-outline\"\r\n />\r\n <div class=\"tips-tabel-label\" slot=\"content\">\r\n <div class=\"tips-tabel-label-text\">\r\n <span>重推次数设定规则:</span>\r\n <span>min(当前时间 - 日志创建时间) >= 2 ^ 重推次数</span>\r\n <span>小于10次时间隔设定为:</span>\r\n <span>第 1 次需间隔 2 ^ 1 = 2 分钟</span>\r\n <span>第 2 次需间隔 2 ^ 2 = 4 分钟</span>\r\n <span>第 3 次需间隔 2 ^ 3 = 8 分钟</span>\r\n <span>第 4 次需间隔 2 ^ 4 = 16 分钟</span>\r\n <span>第 5 次需间隔 2 ^ 5 = 32 分钟</span>\r\n <span>第 6 次需间隔 2 ^ 6 = 64 分钟 1 小时</span>\r\n <span>第 7 次需间隔 2 ^ 7 = 128 分钟 2 小时</span>\r\n <span>第 8 次需间隔 2 ^ 8 = 256 分钟 4.2 小时</span>\r\n <span>第 9 次需间隔 2 ^ 9 = 512 分钟 8.5 小时</span>\r\n <span>第 10 次需间隔 2 ^ 10 = 1024 分钟 17 小时</span>\r\n <span>重推次数大于10次,从第11次开始,每次间隔24h</span>\r\n <span>设定重推次数覆盖范围:</span>\r\n </div>\r\n <i-table class=\"diy-table\" :data=\"data\" :columns=\"columns\"></i-table>\r\n </div>\r\n </i-poptip>\r\n <span>{{labelTitle}}<span v-if=\"labelColon\">:</span></span>\r\n</span>\r\n"
15361
+
15362
+ /***/ }),
15363
+
14564
15364
  /***/ "dd76":
14565
15365
  /***/ (function(module, exports, __webpack_require__) {
14566
15366
 
@@ -15414,7 +16214,7 @@ module.exports = function (bitmap, value) {
15414
16214
  /***/ "f40e":
15415
16215
  /***/ (function(module, exports) {
15416
16216
 
15417
- module.exports = "<article class=\"interface-settings\" :class=\"{'script-max': scriptView}\">\r\n <header v-show=\"!scriptView\">\r\n<!-- <i-input class=\"diy-input\" v-model=\"interfaceModel.info.url\">-->\r\n<!-- <i-select transfer slot=\"prepend\" class=\"diy-select\" v-model=\"interfaceModel.info.method\">-->\r\n<!-- <i-option v-for=\"item in typeList\" :key=\"item.value\" :value=\"item.value\">{{item.text}}</i-option>-->\r\n<!-- </i-select>-->\r\n<!-- </i-input>-->\r\n <i-select class=\"diy-select method-select\" v-model=\"interfaceModel.info.method\">\r\n <i-option v-for=\"item in typeList\" :key=\"item.value\" :value=\"item.value\">{{item.text}}</i-option>\r\n </i-select>\r\n <i-select ref=\"addEnvParamSelect\" class=\"diy-select env-select\" v-model=\"interfaceModel.info.envId\" placeholder=\"请选择环境变量\" clearable>\r\n <i-option v-for=\"item in paramList\" :key=\"item.id\" :value=\"item.id\">{{item.name + \":\" + item.value}}</i-option>\r\n <i-option class=\"add-security-item\" value=\"''\">\r\n <div class=\"add-security-item-content\" @click.stop=\"onAddEnvParam\">\r\n <i class=\"api-icon icon-add\"></i>\r\n <span>新增环境变量</span>\r\n </div>\r\n </i-option>\r\n </i-select>\r\n <i-input class=\"diy-input url-input\" v-model=\"interfaceModel.info.url\"></i-input>\r\n\r\n <i-button type=\"primary\" class=\"diy-btn-primary submit-btn\" @click=\"onRun\">发送</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary\" @click=\"onSave\" ghost>保存</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary his-btn\" @click=\"onVersion\" ghost>查看历史版本</i-button>\r\n <i class=\"export iconfont icon-xiazai\" title=\"导出\" type=\"md-download\" @click=\"onExport\"></i>\r\n <i-upload action=\"\" :before-upload=\"onImport\" :show-upload-list=\"false\">\r\n <i class=\"import iconfont icon-shangchuan\" title=\"导入\" type=\"md-cloud-upload\"></i>\r\n </i-upload>\r\n </header>\r\n <main :class=\"{'transverse': !lengthwise}\">\r\n <section class=\"request\">\r\n <div v-show=\"!scriptView\" class=\"request-bar\">\r\n <div\r\n class=\"tag\"\r\n :class=\"{'active': currentRequestSettingType.name.indexOf(item.name) === 0}\"\r\n v-for=\"(item,index) in requertSettingTypeList\"\r\n :key=\"item.name\"\r\n @click=\"onClickRequertSettingTpye(item)\"\r\n >\r\n <span>{{item.title}}</span>\r\n </div>\r\n </div>\r\n <div class=\"request-content\">\r\n <component\r\n :is=\"currentRequestSettingType.name\"\r\n :lengthwise=\"lengthwise\"\r\n :interface-model=\"interfaceModel\"\r\n :response=\"response\"\r\n :key=\"interfaceModel.info.id + currentRequestSettingType.name\"\r\n :projectID=\"projectId\"\r\n :currentSecurityID=\"currentId\"\r\n :errorLine=\"!originId || originId === interfaceModel.info.id ? errorLine : []\"\r\n :formData=\"formData\"\r\n @on-current-id=\"onCurrentId\"\r\n @on-script-run=\"onScriptRun\"\r\n @on-script-save=\"onSave\"\r\n @on-script-max=\"onScriptMax\"\r\n ></component>\r\n </div>\r\n </section>\r\n <response :key=\"interfaceModel.info.id + 'response'\" :lengthwise=\"lengthwise\" :response=\"response\"></response>\r\n </main>\r\n <i-spin fix v-show=\"loading\">\r\n <i class=\"spin-icon-load ivu-icon\"></i>\r\n </i-spin>\r\n <u-environment-modal :visiable.sync=\"showEnvironmentModal\" :projectId=\"projectId\" @on-refresh=\"getEnvironmentParamList\" :isAdd=\"true\"></u-environment-modal>\r\n <i-modal class=\"diy-modal edit-import-name\" v-model=\"showImportModal\" :mask-closable=\"false\">\r\n <p slot=\"header\">编辑名称</p>\r\n <i-form ref=\"import\" :model=\"apiForm\" :rules=\"rules\">\r\n <i-form-item label=\"环境变量:\" prop=\"envName\">\r\n <i-input v-model=\"apiForm.envName\"></i-input>\r\n </i-form-item>\r\n\r\n <i-form-item label=\"授权:\" prop=\"authName\">\r\n <i-input v-model=\"apiForm.authName\"></i-input>\r\n </i-form-item>\r\n </i-form>\r\n <div class=\"handle-btn\" slot=\"footer\">\r\n <i-button class=\"diy-btn-primary\" type=\"primary\" @click.stop=\"saveImportData(importObj)\">确定</i-button>\r\n <i-button class=\"diy-btn-text\" @click.stop=\"cancleModify\">取消</i-button>\r\n </div>\r\n </i-modal>\r\n</article>\r\n"
16217
+ module.exports = "<article class=\"interface-settings\" :class=\"{'script-max': scriptView}\">\r\n <header v-show=\"!scriptView\">\r\n <!-- <i-input class=\"diy-input\" v-model=\"interfaceModel.info.url\">-->\r\n <!-- <i-select transfer slot=\"prepend\" class=\"diy-select\" v-model=\"interfaceModel.info.method\">-->\r\n <!-- <i-option v-for=\"item in typeList\" :key=\"item.value\" :value=\"item.value\">{{item.text}}</i-option>-->\r\n <!-- </i-select>-->\r\n <!-- </i-input>-->\r\n <i-select class=\"diy-select method-select\" v-model=\"interfaceModel.info.method\">\r\n <i-option v-for=\"item in typeList\" :key=\"item.value\" :value=\"item.value\">{{item.text}}</i-option>\r\n </i-select>\r\n <i-select ref=\"addEnvParamSelect\" class=\"diy-select env-select\" v-model=\"interfaceModel.info.envId\" placeholder=\"请选择环境变量\" clearable>\r\n <i-option v-for=\"item in paramList\" :key=\"item.id\" :value=\"item.id\">{{item.name + \":\" + item.value}}</i-option>\r\n <i-option class=\"add-security-item\" value=\"''\">\r\n <div class=\"add-security-item-content\" @click.stop=\"onAddEnvParam\">\r\n <i class=\"api-icon icon-add\"></i>\r\n <span>新增环境变量</span>\r\n </div>\r\n </i-option>\r\n </i-select>\r\n <i-input class=\"diy-input url-input\" v-model=\"interfaceModel.info.url\"></i-input>\r\n\r\n <i-button type=\"primary\" class=\"diy-btn-primary submit-btn\" @click=\"onRun\">发送</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary\" @click=\"onSave\" ghost>保存</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary process-btn\" @click=\"onProcess\" ghost>流程配置</i-button>\r\n <i-button type=\"primary\" class=\"diy-btn-primary his-btn\" @click=\"onVersion\" ghost>查看历史版本</i-button>\r\n <i class=\"export iconfont icon-xiazai\" title=\"导出\" type=\"md-download\" @click=\"onExport\"></i>\r\n <i-upload action=\"\" :before-upload=\"onImport\" :show-upload-list=\"false\">\r\n <i class=\"import iconfont icon-shangchuan\" title=\"导入\" type=\"md-cloud-upload\"></i>\r\n </i-upload>\r\n </header>\r\n <main :class=\"{'transverse': !lengthwise}\">\r\n <section class=\"request\">\r\n <div v-show=\"!scriptView\" class=\"request-bar\">\r\n <div\r\n class=\"tag\"\r\n :class=\"{'active': currentRequestSettingType.name.indexOf(item.name) === 0}\"\r\n v-for=\"(item,index) in requertSettingTypeList\"\r\n :key=\"item.name\"\r\n @click=\"onClickRequertSettingTpye(item)\"\r\n >\r\n <span>{{item.title}}</span>\r\n </div>\r\n </div>\r\n <div class=\"request-content\">\r\n <component\r\n :is=\"currentRequestSettingType.name\"\r\n :lengthwise=\"lengthwise\"\r\n :interface-model=\"interfaceModel\"\r\n :response=\"response\"\r\n :key=\"interfaceModel.info.id + currentRequestSettingType.name\"\r\n :projectID=\"projectId\"\r\n :currentSecurityID=\"currentId\"\r\n :errorLine=\"!originId || originId === interfaceModel.info.id ? errorLine : []\"\r\n :formData=\"formData\"\r\n @on-current-id=\"onCurrentId\"\r\n @on-script-run=\"onScriptRun\"\r\n @on-script-save=\"onSave\"\r\n @on-script-max=\"onScriptMax\"\r\n ></component>\r\n </div>\r\n </section>\r\n <response :key=\"interfaceModel.info.id + 'response'\" :lengthwise=\"lengthwise\" :response=\"response\"></response>\r\n </main>\r\n <i-spin fix v-show=\"loading\">\r\n <i class=\"spin-icon-load ivu-icon\"></i>\r\n </i-spin>\r\n <u-environment-modal :visiable.sync=\"showEnvironmentModal\" :projectId=\"projectId\" @on-refresh=\"getEnvironmentParamList\" :isAdd=\"true\"></u-environment-modal>\r\n <i-modal class=\"diy-modal edit-import-name\" v-model=\"showImportModal\" :mask-closable=\"false\">\r\n <p slot=\"header\">编辑名称</p>\r\n <i-form ref=\"import\" :model=\"apiForm\" :rules=\"rules\">\r\n <i-form-item label=\"环境变量:\" prop=\"envName\">\r\n <i-input v-model=\"apiForm.envName\"></i-input>\r\n </i-form-item>\r\n\r\n <i-form-item label=\"授权:\" prop=\"authName\">\r\n <i-input v-model=\"apiForm.authName\"></i-input>\r\n </i-form-item>\r\n </i-form>\r\n <div class=\"handle-btn\" slot=\"footer\">\r\n <i-button class=\"diy-btn-primary\" type=\"primary\" @click.stop=\"saveImportData(importObj)\">确定</i-button>\r\n <i-button class=\"diy-btn-text\" @click.stop=\"cancleModify\">取消</i-button>\r\n </div>\r\n </i-modal>\r\n <u-process-drawer v-model=\"showDrawer\" :projectTree=\"projectTree\" :info=\"interfaceModel.info\" @on-save=\"onProcessSave\"></u-process-drawer>\r\n</article>\r\n"
15418
16218
 
15419
16219
  /***/ }),
15420
16220