@egova/egova-api 1.0.50 → 1.0.54
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.common.js +287 -36
- package/dist/index.css +1 -1
- package/dist/index.umd.js +292 -41
- package/dist/index.umd.min.js +2 -2
- package/dist/types/src/settings/index.d.ts +5 -0
- package/dist/types/src/views/project-detail/index.d.ts +2 -1
- package/dist/types/src/views/project-detail/interface-settings/index.d.ts +1 -0
- package/dist/types/src/views/project-detail/service.d.ts +1 -0
- package/dist/types/src/views/project-list/card/index.d.ts +1 -0
- package/dist/types/src/views/project-list/index.d.ts +8 -0
- package/dist/types/src/views/project-list/service.d.ts +1 -0
- package/package.json +2 -2
package/dist/index.common.js
CHANGED
|
@@ -45429,6 +45429,13 @@ module.exports = "<div class=\"confirm\">\n <div @click.stop=\"onOpenConfirm\
|
|
|
45429
45429
|
|
|
45430
45430
|
/***/ }),
|
|
45431
45431
|
|
|
45432
|
+
/***/ "be65":
|
|
45433
|
+
/***/ (function(module, exports) {
|
|
45434
|
+
|
|
45435
|
+
module.exports = require("js-cookie");
|
|
45436
|
+
|
|
45437
|
+
/***/ }),
|
|
45438
|
+
|
|
45432
45439
|
/***/ "bff7":
|
|
45433
45440
|
/***/ (function(module, exports, __webpack_require__) {
|
|
45434
45441
|
|
|
@@ -45738,7 +45745,7 @@ module.exports = require("axios");
|
|
|
45738
45745
|
/***/ "cfb3":
|
|
45739
45746
|
/***/ (function(module, exports) {
|
|
45740
45747
|
|
|
45741
|
-
module.exports = "<article class=\"project-list\">\n <header>\n <i-input\n class=\"diy-input\"\n v-model=\"condition.name\"\n search\n @on-search=\"onQuery\"\n placeholder=\"输入关键字检索\"\n ></i-input>\n </header>\n <main>\n <header class=\"tool-bar\">\n <span>项目列表</span>\n <div class=\"right-tool\">\n <div class=\"action-btn\" @click=\"onComment\">\n <i\n class=\"api-icon icon-star\"\n @click=\"onCheckType('list')\"\n ></i>\n <div>查看项目动态</div>\n </div>\n <i\n class=\"api-icon icon-list\"\n :class=\"{'active': type === 'list'}\"\n title=\"列表展示\"\n @click=\"onCheckType('list')\"\n ></i>\n <i\n class=\"api-icon icon-card\"\n :class=\"{'active': type === 'card'}\"\n title=\"卡片展示\"\n @click=\"onCheckType('card')\"\n ></i>\n </div>\n </header>\n <main>\n <section class=\"projects\" v-if=\"type==='card'\">\n <div class=\"project-card\" @click=\"onAdd\">\n <div class=\"add-card\">\n <i-icon type=\"md-add\" />\n <p>新建项目</p>\n </div>\n </div>\n <u-card\n v-for=\"item in dataList\"\n :data=\"item\"\n :key=\"item.id\"\n @on-delete=\"onDelete\"\n @on-detail=\"onDetail\"\n @on-edit=\"onEdit\"\n ></u-card>\n </section>\n <section class=\"projects\" v-else>\n <i-table class=\"diy-table\" :columns=\"columns\" :data=\"dataList\">\n <template slot-scope=\"{ row,index }\" slot=\"action\">\n <span @click=\"onDetail(row)\" class=\"action-btn detail\"\n ><i class=\"api-icon icon-detail\" title=\"详情\"></i\n ></span>\n <span @click=\"onEdit(row)\" class=\"action-btn detail\"\n ><i class=\"api-icon icon-edit\" title=\"修改\"></i\n ></span>\n <u-confirm\n title=\"删除项目\"\n @on-ok=\"onDelete(row)\"\n message=\"项目内所有接口将被一并删除, 是否确认执行?\"\n >\n <span class=\"action-btn delete\"\n ><i\n class=\"api-icon icon-delete\"\n title=\"删除\"\n ></i\n ></span>\n </u-confirm>\n </template>\n </i-table>\n </section>\n </main>\n </main>\n <u-add-modal :visiable.sync=\"showAddModal\" :data=\"current\">\n <footer slot=\"footer\">\n <i-button @click=\"showAddModal = false\">取消</i-button>\n <i-button type=\"primary\" class=\"diy-btn-primary \" @click=\"onSave\"\n >确定</i-button\n >\n </footer>\n </u-add-modal>\n <i-spin fix v-show=\"loading\">\n <i class=\"spin-icon-load ivu-icon\"></i>\n </i-spin>\n</article>\n"
|
|
45748
|
+
module.exports = "<article class=\"project-list\">\n <header>\n <i-input\n class=\"diy-input\"\n v-model=\"condition.name\"\n search\n @on-search=\"onQuery\"\n placeholder=\"输入关键字检索\"\n ></i-input>\n </header>\n <main>\n <header class=\"tool-bar\">\n <span>项目列表</span>\n <div class=\"right-tool\">\n <div class=\"action-btn\">\n <i-upload\n class=\"action-item\"\n :action=\"uploadAction\"\n accept=\".json\"\n :headers=\"headers\"\n :show-upload-list=\"false\"\n :format=\"['json']\"\n :on-success=\"onSuccess\"\n :before-upload=\"onBeforeUpload\"\n :on-format-error=\"onFormatError\"\n >\n <i class=\"api-icon icon-import\"></i>\n <div>导入项目</div>\n </i-upload>\n </div>\n <div class=\"action-btn\" @click=\"onComment\">\n <i\n class=\"api-icon icon-star\"\n @click=\"onCheckType('list')\"\n ></i>\n <div>查看项目动态</div>\n </div>\n <i\n class=\"api-icon icon-list\"\n :class=\"{'active': type === 'list'}\"\n title=\"列表展示\"\n @click=\"onCheckType('list')\"\n ></i>\n <i\n class=\"api-icon icon-card\"\n :class=\"{'active': type === 'card'}\"\n title=\"卡片展示\"\n @click=\"onCheckType('card')\"\n ></i>\n </div>\n </header>\n <main>\n <section class=\"projects\" v-if=\"type==='card'\">\n <div class=\"project-card\" @click=\"onAdd\">\n <div class=\"add-card\">\n <i-icon type=\"md-add\" />\n <p>新建项目</p>\n </div>\n </div>\n <u-card\n v-for=\"item in dataList\"\n :data=\"item\"\n :key=\"item.id\"\n @on-delete=\"onDelete\"\n @on-detail=\"onDetail\"\n @on-edit=\"onEdit\"\n @on-export=\"onExport\"\n ></u-card>\n </section>\n <section class=\"projects\" v-else>\n <i-table class=\"diy-table\" :columns=\"columns\" :data=\"dataList\">\n <template slot-scope=\"{ row,index }\" slot=\"action\">\n <span @click=\"onDetail(row)\" class=\"action-btn detail\"\n ><i class=\"api-icon icon-detail\" title=\"详情\"></i\n ></span>\n <span @click=\"onEdit(row)\" class=\"action-btn detail\"\n ><i class=\"api-icon icon-edit\" title=\"修改\"></i\n ></span>\n <u-confirm\n title=\"删除项目\"\n @on-ok=\"onDelete(row)\"\n message=\"项目内所有接口将被一并删除, 是否确认执行?\"\n >\n <span class=\"action-btn delete\"\n ><i\n class=\"api-icon icon-delete\"\n title=\"删除\"\n ></i\n ></span>\n </u-confirm>\n </template>\n </i-table>\n </section>\n </main>\n </main>\n <u-add-modal :visiable.sync=\"showAddModal\" :data=\"current\">\n <footer slot=\"footer\">\n <i-button @click=\"showAddModal = false\">取消</i-button>\n <i-button type=\"primary\" class=\"diy-btn-primary \" @click=\"onSave\"\n >确定</i-button\n >\n </footer>\n </u-add-modal>\n <i-spin fix v-show=\"loading\">\n <i class=\"spin-icon-load ivu-icon\"></i>\n </i-spin>\n</article>\n"
|
|
45742
45749
|
|
|
45743
45750
|
/***/ }),
|
|
45744
45751
|
|
|
@@ -45898,7 +45905,7 @@ module.exports = /ipad|iphone|ipod/i.test(userAgent) && global.Pebble !== undefi
|
|
|
45898
45905
|
/***/ "d63e":
|
|
45899
45906
|
/***/ (function(module, exports) {
|
|
45900
45907
|
|
|
45901
|
-
module.exports = "<article class=\"project-detail\">\n <header>\n <div class=\"environment\">\n <p>{{projectName}}</p>\n <!-- <span>环境变量:</span> -->\n <!-- <i-select class=\"diy-select\"></i-select> -->\n </div>\n <div class=\"btns\">\n <!-- <i-button
|
|
45908
|
+
module.exports = "<article class=\"project-detail\">\n <header>\n <div class=\"environment\">\n <p>{{projectName}}</p>\n <!-- <span>环境变量:</span> -->\n <!-- <i-select class=\"diy-select\"></i-select> -->\n </div>\n <div class=\"btns\">\n <!-- <i-button type=\"primary\" ghost class=\"diy-btn-primary\" @click=\"onOpenGlobalModal\"> <i class=\"api-icon icon-setting\"></i>全局参数设置</i-button>\n <i-button type=\"success\" ghost class=\"diy-btn-success\" @click=\"onOpenCurrentModal\"><i class=\"api-icon icon-view\"></i>查看当前变量</i-button> -->\n <i-button type=\"primary\" class=\"diy-btn-primary button-back\" ghost icon=\"md-return-left\" @click=\"onBack\">返回列表</i-button>\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>\n </div>\n </header>\n <!-- <main> -->\n <i-split v-model=\"split\" min=\"200px\" max=\"900px\">\n <u-tree slot=\"left\" @on-check-interface=\"onCheckInterface\" :project-id=\"projectId\"></u-tree>\n <section slot=\"right\" class=\"interface-box\">\n <header class=\"interface-bar\">\n <swiper class=\"swiper\" :options=\"swiperOption\" @click-slide=\"onClickSlide\" @ready=\"onSwiperReadied\">\n <swiper-slide class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\"\n ><span>{{item.name}}</span> <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon\n ></swiper-slide>\n </swiper>\n <!-- <div class=\"tag\" @click=\"onClickTag(item)\" :class=\"{'active': item.id === active.id}\" v-for=\"(item,index) in openInterfaceList\" :key=\"item.id\">\n <span>{{item.name}}</span>\n <i-icon type=\"md-close\" @click.stop=\"onClose(index)\"></i-icon>\n </div> -->\n </header>\n <u-settings :interface-model.sync=\"active\" :project-id=\"projectId\" v-if=\"active.id\" :lengthwise=\"lengthwise\"></u-settings>\n </section>\n </i-split>\n <i-spin fix v-show=\"loading\">\n <i class=\"spin-icon-load ivu-icon\"></i>\n </i-spin>\n <!-- </main> -->\n <u-global-modal :visiable.sync=\"showGlobalModal\">\n <footer slot=\"footer\">\n <i-button @click=\"showGlobalModal = false\">取消</i-button>\n <i-button type=\"primary\" class=\"diy-btn-primary\">确定</i-button>\n </footer>\n </u-global-modal>\n <u-current-modal :visiable.sync=\"showCurrentModal\"> </u-current-modal>\n</article>\n"
|
|
45902
45909
|
|
|
45903
45910
|
/***/ }),
|
|
45904
45911
|
|
|
@@ -47068,7 +47075,7 @@ if ($stringify) {
|
|
|
47068
47075
|
/***/ "ef27":
|
|
47069
47076
|
/***/ (function(module, exports) {
|
|
47070
47077
|
|
|
47071
|
-
module.exports = "<article class=\"project-card\" @click=\"onDetail\">\n <header>{{data.name}}</header>\n <main></main>\n <footer>\n <div @click.stop=\"onEdit\">修改</div>\n <u-confirm\n class=\"delete\"\n title=\"删除项目\"\n message=\"项目内所有接口将被一并删除, 是否确认执行?\"\n @on-ok=\"onDelete\"\n >\n <span>删除</span>\n </u-confirm>\n </footer>\n</article>\n"
|
|
47078
|
+
module.exports = "<article class=\"project-card\" @click=\"onDetail\">\n <header>{{data.name}}</header>\n <i-dropdown transfer transfer-class-name=\"api-project-oprate\" class=\"project-card-i-dropdown\" @on-click=\"onClick\">\n <i-icon type=\"ios-more\" />\n <i-dropdown-menu slot=\"list\">\n <i-dropdown-item :name=\"'export'\">\n <i\n class=\"api-icon icon-export project-card-i-dropdown-item-icon\"\n title=\"导出此项目\"\n @click.stop=\"onExport\"\n ></i>\n 导出此项目\n </i-dropdown-item>\n </i-dropdown-menu>\n </i-dropdown>\n <main></main>\n <footer>\n <div @click.stop=\"onEdit\">修改</div>\n <u-confirm\n class=\"delete\"\n title=\"删除项目\"\n message=\"项目内所有接口将被一并删除, 是否确认执行?\"\n @on-ok=\"onDelete\"\n >\n <span>删除</span>\n </u-confirm>\n </footer>\n</article>\n"
|
|
47072
47079
|
|
|
47073
47080
|
/***/ }),
|
|
47074
47081
|
|
|
@@ -47208,7 +47215,7 @@ module.exports = uncurryThis([].slice);
|
|
|
47208
47215
|
/***/ "f40e":
|
|
47209
47216
|
/***/ (function(module, exports) {
|
|
47210
47217
|
|
|
47211
|
-
module.exports = "<article class=\"interface-settings\">\n <header>\n <i-input class=\"diy-input\" v-model=\"interfaceModel.info.url\">\n <i-select
|
|
47218
|
+
module.exports = "<article class=\"interface-settings\">\n <header>\n <i-input class=\"diy-input\" v-model=\"interfaceModel.info.url\">\n <i-select transfer slot=\"prepend\" class=\"diy-select\" v-model=\"interfaceModel.info.method\">\n <i-option v-for=\"item in typeList\" :key=\"item.value\" :value=\"item.value\">{{item.text}}</i-option>\n </i-select>\n </i-input>\n <i-button type=\"primary\" class=\"diy-btn-primary\" @click=\"onRun\">发送</i-button>\n <i-button type=\"primary\" class=\"diy-btn-primary\" @click=\"onSave\" ghost>保存</i-button>\n <i-button type=\"primary\" class=\"diy-btn-primary\" @click=\"onVersion\" ghost>查看历史版本</i-button>\n <i-icon class=\"export\" title=\"导出\" type=\"md-download\" @click=\"onExport\" />\n <i-upload action=\"\" :before-upload=\"onImport\" :show-upload-list=\"false\">\n <i-icon class=\"import\" title=\"导入\" type=\"md-cloud-upload\" />\n </i-upload>\n </header>\n <main :class=\"{'transverse': !lengthwise}\">\n <section class=\"request\">\n <div class=\"request-bar\">\n <div class=\"tag\" :class=\"{'active': currentRequestSettingType.name.indexOf(item.name) === 0}\" v-for=\"(item,index) in requertSettingTypeList\" :key=\"item.name\">\n <i-dropdown class=\"diy-dropdown\" stop-propagation v-if=\"item.children\" @on-click=\"onClickRequertSettingSubTpye(item,$event)\">\n <span>{{item.title}}<i class=\"api-icon icon-select\"></i></span>\n <i-dropdown-menu slot=\"list\">\n <i-dropdown-item v-for=\"subItem in item.children\" :key=\"subItem.name\" :name=\"subItem.name\">{{subItem.title}}</i-dropdown-item>\n </i-dropdown-menu>\n </i-dropdown>\n <span v-else @click=\"onClickRequertSettingTpye(item)\">{{item.title}}</span>\n </div>\n </div>\n <div class=\"request-content\">\n <component\n :is=\"currentRequestSettingType.name\"\n :lengthwise=\"lengthwise\"\n :interface-model=\"interfaceModel\"\n :response=\"response\"\n :key=\"interfaceModel.info.id + currentRequestSettingType.name\"\n ></component>\n </div>\n </section>\n <response :key=\"interfaceModel.info.id + 'response'\" :lengthwise=\"lengthwise\" :response=\"response\"></response>\n </main>\n <i-spin fix v-show=\"loading\">\n <i class=\"spin-icon-load ivu-icon\"></i>\n </i-spin>\n</article>\n"
|
|
47212
47219
|
|
|
47213
47220
|
/***/ }),
|
|
47214
47221
|
|
|
@@ -48236,6 +48243,11 @@ function (_super) {
|
|
|
48236
48243
|
this.$emit("on-edit", this.data);
|
|
48237
48244
|
};
|
|
48238
48245
|
|
|
48246
|
+
ProjectCard.prototype.onClick = function (name) {
|
|
48247
|
+
console.warn("onClick name===", name);
|
|
48248
|
+
this.$emit("on-" + name, this.data);
|
|
48249
|
+
};
|
|
48250
|
+
|
|
48239
48251
|
card_decorate([Object(flagwind_web_["config"])({
|
|
48240
48252
|
default: function _default() {
|
|
48241
48253
|
return new Object();
|
|
@@ -48255,6 +48267,12 @@ function (_super) {
|
|
|
48255
48267
|
// EXTERNAL MODULE: ./src/views/project-list/index.scss
|
|
48256
48268
|
var project_list = __webpack_require__("17fe");
|
|
48257
48269
|
|
|
48270
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url.js
|
|
48271
|
+
var web_url = __webpack_require__("2b3d");
|
|
48272
|
+
|
|
48273
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.js
|
|
48274
|
+
var web_url_search_params = __webpack_require__("9861");
|
|
48275
|
+
|
|
48258
48276
|
// CONCATENATED MODULE: ./src/decorators/service-handler.ts
|
|
48259
48277
|
|
|
48260
48278
|
|
|
@@ -48704,6 +48722,10 @@ function (_super) {
|
|
|
48704
48722
|
|
|
48705
48723
|
|
|
48706
48724
|
|
|
48725
|
+
// EXTERNAL MODULE: external "axios"
|
|
48726
|
+
var external_axios_ = __webpack_require__("cebe");
|
|
48727
|
+
var external_axios_default = /*#__PURE__*/__webpack_require__.n(external_axios_);
|
|
48728
|
+
|
|
48707
48729
|
// CONCATENATED MODULE: ./src/views/project-list/service.ts
|
|
48708
48730
|
|
|
48709
48731
|
|
|
@@ -48711,6 +48733,11 @@ function (_super) {
|
|
|
48711
48733
|
|
|
48712
48734
|
|
|
48713
48735
|
|
|
48736
|
+
|
|
48737
|
+
|
|
48738
|
+
|
|
48739
|
+
|
|
48740
|
+
|
|
48714
48741
|
var service_extends = undefined && undefined.__extends || function () {
|
|
48715
48742
|
var _extendStatics = function extendStatics(d, b) {
|
|
48716
48743
|
_extendStatics = Object.setPrototypeOf || {
|
|
@@ -48756,6 +48783,7 @@ var service_metadata = undefined && undefined.__metadata || function (k, v) {
|
|
|
48756
48783
|
|
|
48757
48784
|
|
|
48758
48785
|
|
|
48786
|
+
|
|
48759
48787
|
var service_ProjectService =
|
|
48760
48788
|
/** @class */
|
|
48761
48789
|
function (_super) {
|
|
@@ -48785,6 +48813,31 @@ function (_super) {
|
|
|
48785
48813
|
return this._delete("/unity/api/project/".concat(id));
|
|
48786
48814
|
};
|
|
48787
48815
|
|
|
48816
|
+
ProjectService.prototype.exportProject = function (data) {
|
|
48817
|
+
return external_axios_default.a.post(this.url("/unity/api/info/export"), data, {
|
|
48818
|
+
headers: {
|
|
48819
|
+
"X-Requested-With": "XMLHttpRequest",
|
|
48820
|
+
"Content-Type": "application/json; charset=UTF-8",
|
|
48821
|
+
"Access-Control-Allow-Origin": "*"
|
|
48822
|
+
},
|
|
48823
|
+
responseType: "arraybuffer"
|
|
48824
|
+
}).then(function (res) {
|
|
48825
|
+
var blob = new Blob([res.data], {
|
|
48826
|
+
type: "application/json"
|
|
48827
|
+
});
|
|
48828
|
+
var objectUrl = URL.createObjectURL(blob);
|
|
48829
|
+
var dom = document.createElement("a");
|
|
48830
|
+
dom.href = objectUrl;
|
|
48831
|
+
dom.download = decodeURI("data-model.json");
|
|
48832
|
+
dom.style.display = "none";
|
|
48833
|
+
document.body.appendChild(dom);
|
|
48834
|
+
dom.target = "_blank";
|
|
48835
|
+
dom.click();
|
|
48836
|
+
dom.parentNode.removeChild(dom);
|
|
48837
|
+
window.URL.revokeObjectURL(objectUrl);
|
|
48838
|
+
});
|
|
48839
|
+
};
|
|
48840
|
+
|
|
48788
48841
|
service_decorate([serviceHandler("query", {
|
|
48789
48842
|
title: "获取所有项目"
|
|
48790
48843
|
}), service_metadata("design:type", Function), service_metadata("design:paramtypes", [Object]), service_metadata("design:returntype", void 0)], ProjectService.prototype, "getProjectList", null);
|
|
@@ -48805,6 +48858,41 @@ function (_super) {
|
|
|
48805
48858
|
}(common_service);
|
|
48806
48859
|
|
|
48807
48860
|
/* harmony default export */ var project_list_service = (service_ProjectService);
|
|
48861
|
+
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.assign.js
|
|
48862
|
+
var es_object_assign = __webpack_require__("cca6");
|
|
48863
|
+
|
|
48864
|
+
// CONCATENATED MODULE: ./src/settings/index.ts
|
|
48865
|
+
|
|
48866
|
+
|
|
48867
|
+
var __assign = undefined && undefined.__assign || function () {
|
|
48868
|
+
__assign = Object.assign || function (t) {
|
|
48869
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
48870
|
+
s = arguments[i];
|
|
48871
|
+
|
|
48872
|
+
for (var p in s) {
|
|
48873
|
+
if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
48874
|
+
}
|
|
48875
|
+
}
|
|
48876
|
+
|
|
48877
|
+
return t;
|
|
48878
|
+
};
|
|
48879
|
+
|
|
48880
|
+
return __assign.apply(this, arguments);
|
|
48881
|
+
};
|
|
48882
|
+
|
|
48883
|
+
var global = window;
|
|
48884
|
+
/**
|
|
48885
|
+
* 公共配置
|
|
48886
|
+
*/
|
|
48887
|
+
|
|
48888
|
+
var commonSetting = __assign({
|
|
48889
|
+
// 后端地址
|
|
48890
|
+
baseUrl: ""
|
|
48891
|
+
}, global.commonSetting);
|
|
48892
|
+
// EXTERNAL MODULE: external "js-cookie"
|
|
48893
|
+
var external_js_cookie_ = __webpack_require__("be65");
|
|
48894
|
+
var external_js_cookie_default = /*#__PURE__*/__webpack_require__.n(external_js_cookie_);
|
|
48895
|
+
|
|
48808
48896
|
// CONCATENATED MODULE: ./src/views/project-list/index.ts
|
|
48809
48897
|
|
|
48810
48898
|
|
|
@@ -49013,6 +49101,8 @@ var project_list_generator = undefined && undefined.__generator || function (thi
|
|
|
49013
49101
|
|
|
49014
49102
|
|
|
49015
49103
|
|
|
49104
|
+
|
|
49105
|
+
|
|
49016
49106
|
var project_list_ProjectList =
|
|
49017
49107
|
/** @class */
|
|
49018
49108
|
function (_super) {
|
|
@@ -49050,6 +49140,14 @@ function (_super) {
|
|
|
49050
49140
|
return _this;
|
|
49051
49141
|
}
|
|
49052
49142
|
|
|
49143
|
+
Object.defineProperty(ProjectList.prototype, "uploadAction", {
|
|
49144
|
+
get: function get() {
|
|
49145
|
+
return commonSetting.baseUrl + "/unity/api/info/import";
|
|
49146
|
+
},
|
|
49147
|
+
enumerable: false,
|
|
49148
|
+
configurable: true
|
|
49149
|
+
});
|
|
49150
|
+
|
|
49053
49151
|
ProjectList.prototype.onCheckType = function (type) {
|
|
49054
49152
|
this.type = type;
|
|
49055
49153
|
};
|
|
@@ -49101,6 +49199,34 @@ function (_super) {
|
|
|
49101
49199
|
this.showAddModal = true;
|
|
49102
49200
|
};
|
|
49103
49201
|
|
|
49202
|
+
ProjectList.prototype.onExport = function (data) {
|
|
49203
|
+
return project_list_awaiter(this, void 0, void 0, function () {
|
|
49204
|
+
var queryModel;
|
|
49205
|
+
return project_list_generator(this, function (_a) {
|
|
49206
|
+
switch (_a.label) {
|
|
49207
|
+
case 0:
|
|
49208
|
+
console.warn("onExport data==", data);
|
|
49209
|
+
queryModel = Object.create(null);
|
|
49210
|
+
queryModel = {
|
|
49211
|
+
projectId: data.id
|
|
49212
|
+
};
|
|
49213
|
+
this.loading = true;
|
|
49214
|
+
return [4
|
|
49215
|
+
/*yield*/
|
|
49216
|
+
, this.service.exportProject(queryModel)];
|
|
49217
|
+
|
|
49218
|
+
case 1:
|
|
49219
|
+
_a.sent();
|
|
49220
|
+
|
|
49221
|
+
this.loading = false;
|
|
49222
|
+
return [2
|
|
49223
|
+
/*return*/
|
|
49224
|
+
];
|
|
49225
|
+
}
|
|
49226
|
+
});
|
|
49227
|
+
});
|
|
49228
|
+
};
|
|
49229
|
+
|
|
49104
49230
|
ProjectList.prototype.onComment = function () {
|
|
49105
49231
|
this.$router.push({
|
|
49106
49232
|
name: "project-comment"
|
|
@@ -49160,6 +49286,53 @@ function (_super) {
|
|
|
49160
49286
|
});
|
|
49161
49287
|
};
|
|
49162
49288
|
|
|
49289
|
+
Object.defineProperty(ProjectList.prototype, "headers", {
|
|
49290
|
+
get: function get() {
|
|
49291
|
+
var token = external_js_cookie_default.a.get("access_token");
|
|
49292
|
+
return {
|
|
49293
|
+
Authorization: "Bearer " + token
|
|
49294
|
+
};
|
|
49295
|
+
},
|
|
49296
|
+
enumerable: false,
|
|
49297
|
+
configurable: true
|
|
49298
|
+
});
|
|
49299
|
+
|
|
49300
|
+
ProjectList.prototype.onSuccess = function (res, file) {
|
|
49301
|
+
if (res && !res.hasError) {
|
|
49302
|
+
this.$Message.success("导入成功");
|
|
49303
|
+
this.onQuery();
|
|
49304
|
+
this.loading = false;
|
|
49305
|
+
return;
|
|
49306
|
+
}
|
|
49307
|
+
|
|
49308
|
+
this.loading = false;
|
|
49309
|
+
this.$Message.error(res.message || "导入出错,请稍后再试");
|
|
49310
|
+
}; // 文件检查
|
|
49311
|
+
|
|
49312
|
+
|
|
49313
|
+
ProjectList.prototype.onBeforeUpload = function (file) {
|
|
49314
|
+
this.loading = true;
|
|
49315
|
+
|
|
49316
|
+
if (file.name.indexOf(" ") !== -1) {
|
|
49317
|
+
this.$Message.warning("文件名不能包含空格");
|
|
49318
|
+
this.loading = false;
|
|
49319
|
+
return false;
|
|
49320
|
+
}
|
|
49321
|
+
|
|
49322
|
+
if (file.name.indexOf("%") !== -1) {
|
|
49323
|
+
this.$Message.warning("文件名不能包含符号%");
|
|
49324
|
+
this.loading = false;
|
|
49325
|
+
return false;
|
|
49326
|
+
}
|
|
49327
|
+
|
|
49328
|
+
return true; // 返回false则停止上传,可以使用回调函数,手动上传
|
|
49329
|
+
};
|
|
49330
|
+
|
|
49331
|
+
ProjectList.prototype.onFormatError = function (file) {
|
|
49332
|
+
this.loading = false;
|
|
49333
|
+
this.$Message.warning("\u6587\u4EF6".concat(file.name, "\u683C\u5F0F\u9519\u8BEF"));
|
|
49334
|
+
};
|
|
49335
|
+
|
|
49163
49336
|
var _a;
|
|
49164
49337
|
|
|
49165
49338
|
project_list_decorate([autowired(project_list_service), project_list_metadata("design:type", typeof (_a = typeof project_list_service !== "undefined" && project_list_service) === "function" ? _a : Object)], ProjectList.prototype, "service", void 0);
|
|
@@ -49443,6 +49616,10 @@ function (_super) {
|
|
|
49443
49616
|
return this._get("/api-help/postScript.json");
|
|
49444
49617
|
};
|
|
49445
49618
|
|
|
49619
|
+
ApiService.prototype.projectInfo = function (id) {
|
|
49620
|
+
return this._get("/unity/api/project/".concat(id));
|
|
49621
|
+
};
|
|
49622
|
+
|
|
49446
49623
|
var _a, _b;
|
|
49447
49624
|
|
|
49448
49625
|
project_detail_service_decorate([serviceHandler("query", {
|
|
@@ -49493,6 +49670,10 @@ function (_super) {
|
|
|
49493
49670
|
title: "后置脚本"
|
|
49494
49671
|
}), project_detail_service_metadata("design:type", Function), project_detail_service_metadata("design:paramtypes", []), project_detail_service_metadata("design:returntype", void 0)], ApiService.prototype, "postScript", null);
|
|
49495
49672
|
|
|
49673
|
+
project_detail_service_decorate([serviceHandler("query", {
|
|
49674
|
+
title: "项目详情"
|
|
49675
|
+
}), project_detail_service_metadata("design:type", Function), project_detail_service_metadata("design:paramtypes", [String]), project_detail_service_metadata("design:returntype", void 0)], ApiService.prototype, "projectInfo", null);
|
|
49676
|
+
|
|
49496
49677
|
return ApiService;
|
|
49497
49678
|
}(common_service);
|
|
49498
49679
|
|
|
@@ -50190,9 +50371,6 @@ function (_super) {
|
|
|
50190
50371
|
}(flagwind_web_["View"]);
|
|
50191
50372
|
|
|
50192
50373
|
/* harmony default export */ var views_project_comment = (project_comment_ProjectComment);
|
|
50193
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.object.assign.js
|
|
50194
|
-
var es_object_assign = __webpack_require__("cca6");
|
|
50195
|
-
|
|
50196
50374
|
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.string.split.js
|
|
50197
50375
|
var es_string_split = __webpack_require__("1276");
|
|
50198
50376
|
|
|
@@ -50436,12 +50614,6 @@ var es_array_filter = __webpack_require__("4de4");
|
|
|
50436
50614
|
// EXTERNAL MODULE: ./node_modules/core-js/modules/es.json.stringify.js
|
|
50437
50615
|
var es_json_stringify = __webpack_require__("e9c4");
|
|
50438
50616
|
|
|
50439
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url.js
|
|
50440
|
-
var web_url = __webpack_require__("2b3d");
|
|
50441
|
-
|
|
50442
|
-
// EXTERNAL MODULE: ./node_modules/core-js/modules/web.url-search-params.js
|
|
50443
|
-
var web_url_search_params = __webpack_require__("9861");
|
|
50444
|
-
|
|
50445
50617
|
// EXTERNAL MODULE: ./src/components/code-editor/index.scss
|
|
50446
50618
|
var code_editor = __webpack_require__("a6c3");
|
|
50447
50619
|
|
|
@@ -52874,8 +53046,8 @@ var interface_settings_extends = undefined && undefined.__extends || function ()
|
|
|
52874
53046
|
};
|
|
52875
53047
|
}();
|
|
52876
53048
|
|
|
52877
|
-
var
|
|
52878
|
-
|
|
53049
|
+
var interface_settings_assign = undefined && undefined.__assign || function () {
|
|
53050
|
+
interface_settings_assign = Object.assign || function (t) {
|
|
52879
53051
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
52880
53052
|
s = arguments[i];
|
|
52881
53053
|
|
|
@@ -52887,7 +53059,7 @@ var __assign = undefined && undefined.__assign || function () {
|
|
|
52887
53059
|
return t;
|
|
52888
53060
|
};
|
|
52889
53061
|
|
|
52890
|
-
return
|
|
53062
|
+
return interface_settings_assign.apply(this, arguments);
|
|
52891
53063
|
};
|
|
52892
53064
|
|
|
52893
53065
|
var interface_settings_decorate = undefined && undefined.__decorate || function (decorators, target, key, desc) {
|
|
@@ -53147,7 +53319,7 @@ function (_super) {
|
|
|
53147
53319
|
|
|
53148
53320
|
return [4
|
|
53149
53321
|
/*yield*/
|
|
53150
|
-
, this.service.run(this.interfaceModel.info.id,
|
|
53322
|
+
, this.service.run(this.interfaceModel.info.id, interface_settings_assign(interface_settings_assign({}, this.interfaceModel), {
|
|
53151
53323
|
formParams: formParams,
|
|
53152
53324
|
requestHeaders: requestHeaders
|
|
53153
53325
|
}))];
|
|
@@ -53256,6 +53428,22 @@ function (_super) {
|
|
|
53256
53428
|
link.click();
|
|
53257
53429
|
};
|
|
53258
53430
|
|
|
53431
|
+
InterfaceSettings.prototype.onVersion = function () {
|
|
53432
|
+
var id = (this.interfaceModel.info || {}).id;
|
|
53433
|
+
|
|
53434
|
+
if (!id) {
|
|
53435
|
+
this.$message.info("尚未保存,无历史版本");
|
|
53436
|
+
return;
|
|
53437
|
+
}
|
|
53438
|
+
|
|
53439
|
+
this.$router.push({
|
|
53440
|
+
name: "project-version",
|
|
53441
|
+
query: {
|
|
53442
|
+
id: id
|
|
53443
|
+
}
|
|
53444
|
+
});
|
|
53445
|
+
};
|
|
53446
|
+
|
|
53259
53447
|
var _a, _b;
|
|
53260
53448
|
|
|
53261
53449
|
interface_settings_decorate([autowired(project_detail_service), interface_settings_metadata("design:type", typeof (_a = typeof project_detail_service !== "undefined" && project_detail_service) === "function" ? _a : Object)], InterfaceSettings.prototype, "service", void 0);
|
|
@@ -54370,40 +54558,106 @@ function (_super) {
|
|
|
54370
54558
|
this.swiper = swiper;
|
|
54371
54559
|
};
|
|
54372
54560
|
|
|
54373
|
-
ProjectDetail.prototype.
|
|
54561
|
+
ProjectDetail.prototype.getProjectInfo = function () {
|
|
54562
|
+
var _a, _b;
|
|
54563
|
+
|
|
54374
54564
|
return project_detail_awaiter(this, void 0, void 0, function () {
|
|
54375
|
-
var
|
|
54565
|
+
var res;
|
|
54566
|
+
return project_detail_generator(this, function (_c) {
|
|
54567
|
+
switch (_c.label) {
|
|
54568
|
+
case 0:
|
|
54569
|
+
this.projectId = (_a = this.$route.params) === null || _a === void 0 ? void 0 : _a.id;
|
|
54570
|
+
if (!this.projectId) return [3
|
|
54571
|
+
/*break*/
|
|
54572
|
+
, 2];
|
|
54573
|
+
return [4
|
|
54574
|
+
/*yield*/
|
|
54575
|
+
, this.service.projectInfo(this.projectId)];
|
|
54576
|
+
|
|
54577
|
+
case 1:
|
|
54578
|
+
res = _c.sent();
|
|
54579
|
+
this.projectName = ((_b = res === null || res === void 0 ? void 0 : res.result) === null || _b === void 0 ? void 0 : _b.name) || "";
|
|
54580
|
+
_c.label = 2;
|
|
54581
|
+
|
|
54582
|
+
case 2:
|
|
54583
|
+
return [2
|
|
54584
|
+
/*return*/
|
|
54585
|
+
];
|
|
54586
|
+
}
|
|
54587
|
+
});
|
|
54588
|
+
});
|
|
54589
|
+
};
|
|
54590
|
+
|
|
54591
|
+
ProjectDetail.prototype.onCheckInterface = function (data, isResume) {
|
|
54592
|
+
return project_detail_awaiter(this, void 0, void 0, function () {
|
|
54593
|
+
var resumeData, text, set, result, res, index;
|
|
54376
54594
|
|
|
54377
54595
|
var _this = this;
|
|
54378
54596
|
|
|
54379
54597
|
return project_detail_generator(this, function (_a) {
|
|
54380
54598
|
switch (_a.label) {
|
|
54381
54599
|
case 0:
|
|
54600
|
+
resumeData = {};
|
|
54601
|
+
|
|
54602
|
+
if (isResume) {
|
|
54603
|
+
try {
|
|
54604
|
+
text = window.sessionStorage.getItem("api_project_".concat(data.id));
|
|
54605
|
+
|
|
54606
|
+
if (text) {
|
|
54607
|
+
resumeData = JSON.parse(text);
|
|
54608
|
+
}
|
|
54609
|
+
} catch (_b) {//
|
|
54610
|
+
}
|
|
54611
|
+
|
|
54612
|
+
resumeData = project_detail_assign(project_detail_assign({}, resumeData), {
|
|
54613
|
+
name: data.name,
|
|
54614
|
+
id: data.id
|
|
54615
|
+
});
|
|
54616
|
+
}
|
|
54617
|
+
|
|
54382
54618
|
set = new Set(this.openInterfaceList.map(function (i) {
|
|
54383
54619
|
return i.id;
|
|
54384
54620
|
}));
|
|
54385
54621
|
if (!!set.has(data.id)) return [3
|
|
54386
54622
|
/*break*/
|
|
54387
|
-
,
|
|
54623
|
+
, 4];
|
|
54388
54624
|
this.loading = true;
|
|
54625
|
+
result = void 0;
|
|
54626
|
+
if (!isResume) return [3
|
|
54627
|
+
/*break*/
|
|
54628
|
+
, 1];
|
|
54629
|
+
result = resumeData;
|
|
54630
|
+
return [3
|
|
54631
|
+
/*break*/
|
|
54632
|
+
, 3];
|
|
54633
|
+
|
|
54634
|
+
case 1:
|
|
54389
54635
|
return [4
|
|
54390
54636
|
/*yield*/
|
|
54391
54637
|
, this.service.apiInfo(data.id)];
|
|
54392
54638
|
|
|
54393
|
-
case
|
|
54394
|
-
|
|
54395
|
-
|
|
54396
|
-
obj = project_detail_assign(project_detail_assign({}, result.result), {
|
|
54639
|
+
case 2:
|
|
54640
|
+
res = _a.sent();
|
|
54641
|
+
result = project_detail_assign(project_detail_assign({}, res.result || {}), {
|
|
54397
54642
|
name: data.name,
|
|
54398
54643
|
id: data.id
|
|
54399
54644
|
});
|
|
54400
|
-
|
|
54401
|
-
_a.label = 2;
|
|
54645
|
+
_a.label = 3;
|
|
54402
54646
|
|
|
54403
|
-
case
|
|
54647
|
+
case 3:
|
|
54648
|
+
this.openInterfaceList.push(result);
|
|
54649
|
+
this.loading = false;
|
|
54650
|
+
_a.label = 4;
|
|
54651
|
+
|
|
54652
|
+
case 4:
|
|
54404
54653
|
index = this.openInterfaceList.findIndex(function (i) {
|
|
54405
54654
|
return i.id === data.id;
|
|
54406
54655
|
});
|
|
54656
|
+
|
|
54657
|
+
if (isResume) {
|
|
54658
|
+
this.openInterfaceList[index] = resumeData;
|
|
54659
|
+
}
|
|
54660
|
+
|
|
54407
54661
|
this.active = this.openInterfaceList[index];
|
|
54408
54662
|
this.$nextTick(function () {
|
|
54409
54663
|
_this.swiper.slideTo(index, 1000, false);
|
|
@@ -54448,20 +54702,17 @@ function (_super) {
|
|
|
54448
54702
|
|
|
54449
54703
|
|
|
54450
54704
|
ProjectDetail.prototype.mounted = function () {
|
|
54451
|
-
|
|
54452
|
-
|
|
54453
|
-
|
|
54454
|
-
|
|
54455
|
-
|
|
54456
|
-
apiName = _b.apiName,
|
|
54457
|
-
name = _b.name;
|
|
54458
|
-
this.projectName = name;
|
|
54705
|
+
this.getProjectInfo();
|
|
54706
|
+
var _a = this.$route.query,
|
|
54707
|
+
apiId = _a.apiId,
|
|
54708
|
+
apiName = _a.apiName,
|
|
54709
|
+
resume = _a.resume;
|
|
54459
54710
|
|
|
54460
54711
|
if (apiId) {
|
|
54461
54712
|
this.onCheckInterface({
|
|
54462
54713
|
id: apiId,
|
|
54463
54714
|
name: apiName
|
|
54464
|
-
});
|
|
54715
|
+
}, resume === "true");
|
|
54465
54716
|
}
|
|
54466
54717
|
};
|
|
54467
54718
|
|