ecinc-cloud-moabase 9.6.251 → 9.6.253
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/index.js +5 -1
- package/lib/ecmoabase.common.js +478 -1
- package/lib/ecmoabase.umd.js +478 -1
- package/lib/ecmoabase.umd.min.js +4 -4
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -12,6 +12,9 @@ import Submission from './src/wfInstance/mainform/components/Submission'
|
|
|
12
12
|
|
|
13
13
|
//wfInstance/viewContent
|
|
14
14
|
import viewContent from './src/wfInstance/viewContent'
|
|
15
|
+
|
|
16
|
+
import ZipViewer from './src/common/components/ZipViewer/index.vue'
|
|
17
|
+
|
|
15
18
|
// 以对象的结构保存组件,便于遍历
|
|
16
19
|
const components = {
|
|
17
20
|
BbzxFrameLoader,
|
|
@@ -47,7 +50,8 @@ const components = {
|
|
|
47
50
|
handovernote,
|
|
48
51
|
RelatedArticle,
|
|
49
52
|
SendFile,
|
|
50
|
-
Submission
|
|
53
|
+
Submission,
|
|
54
|
+
ZipViewer
|
|
51
55
|
}
|
|
52
56
|
// 定义 install 方法
|
|
53
57
|
const install = function (Vue) {
|
package/lib/ecmoabase.common.js
CHANGED
|
@@ -1360,6 +1360,27 @@ ___CSS_LOADER_EXPORT___.push([module.id, ".water[data-v-1343231e]{position:absol
|
|
|
1360
1360
|
/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
|
|
1361
1361
|
|
|
1362
1362
|
|
|
1363
|
+
/***/ }),
|
|
1364
|
+
|
|
1365
|
+
/***/ 1484:
|
|
1366
|
+
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|
|
1367
|
+
|
|
1368
|
+
"use strict";
|
|
1369
|
+
__webpack_require__.r(__webpack_exports__);
|
|
1370
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(1601);
|
|
1371
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0__);
|
|
1372
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(6314);
|
|
1373
|
+
/* harmony import */ var _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(_node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1__);
|
|
1374
|
+
// Imports
|
|
1375
|
+
|
|
1376
|
+
|
|
1377
|
+
var ___CSS_LOADER_EXPORT___ = _node_modules_css_loader_dist_runtime_api_js__WEBPACK_IMPORTED_MODULE_1___default()((_node_modules_css_loader_dist_runtime_noSourceMaps_js__WEBPACK_IMPORTED_MODULE_0___default()));
|
|
1378
|
+
// Module
|
|
1379
|
+
___CSS_LOADER_EXPORT___.push([module.id, ".breadcrumb[data-v-e919400c]{padding:10px 20px;-ms-flex-wrap:nowrap;flex-wrap:nowrap;font-size:12px;background-color:#fff;overflow-x:auto}.breadcrumb[data-v-e919400c],.crumb-item-container[data-v-e919400c]{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.crumb-item-container .crumb-item[data-v-e919400c]{width:-webkit-max-content;width:-moz-max-content;width:max-content}.crumb-item[data-v-e919400c]{color:#666;cursor:pointer;border-radius:22px;background-color:#f7f8fa;padding:7px 12px}.last-item[data-v-e919400c]{color:#53a8ff;cursor:default;pointer-events:none;background-color:#edf6ff}.separator[data-v-e919400c]{margin:0 8px;color:#a2a6ad}.file-list[data-v-e919400c]{background:#fff;height:calc(100vh - 96px);overflow-y:auto}.item[data-v-e919400c]{padding:12px 20px;cursor:pointer;-webkit-transition:background .2s;transition:background .2s;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between}.icon[data-v-e919400c]{margin-right:10px}.icon img[data-v-e919400c],.icon svg[data-v-e919400c]{width:30px;height:30px;position:relative;top:2px}.folder[data-v-e919400c]{font-weight:500;color:#333;-webkit-box-align:center;-ms-flex-align:center;align-items:center;width:100%}.folder[data-v-e919400c],.folder .file-name[data-v-e919400c]{display:-webkit-box;display:-ms-flexbox;display:flex}.folder .file-name[data-v-e919400c]{-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-flex:1;-ms-flex:1;flex:1;gap:4px;font-size:14px;--line-clamp:2}.folder .file-name .file-time[data-v-e919400c]{font-size:12px;color:#999}.folder .file-name>div[data-v-e919400c]:first-child{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;line-clamp:var(--line-clamp);-webkit-line-clamp:var(--line-clamp);-webkit-box-orient:vertical}.folder .file-name.is-folder[data-v-e919400c]{font-size:16px;--line-clamp:1}.folder .van-icon[data-v-e919400c]{color:#d8d8d8}.empty-tip[data-v-e919400c]{padding:20px;text-align:center;color:#999}", ""]);
|
|
1380
|
+
// Exports
|
|
1381
|
+
/* harmony default export */ __webpack_exports__["default"] = (___CSS_LOADER_EXPORT___);
|
|
1382
|
+
|
|
1383
|
+
|
|
1363
1384
|
/***/ }),
|
|
1364
1385
|
|
|
1365
1386
|
/***/ 6939:
|
|
@@ -26095,6 +26116,22 @@ var update = add("b6a4bb0e", content, true, {"sourceMap":false,"shadowMode":fals
|
|
|
26095
26116
|
|
|
26096
26117
|
/***/ }),
|
|
26097
26118
|
|
|
26119
|
+
/***/ 1174:
|
|
26120
|
+
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
26121
|
+
|
|
26122
|
+
// style-loader: Adds some css to the DOM by adding a <style> tag
|
|
26123
|
+
|
|
26124
|
+
// load the styles
|
|
26125
|
+
var content = __webpack_require__(1484);
|
|
26126
|
+
if(content.__esModule) content = content.default;
|
|
26127
|
+
if(typeof content === 'string') content = [[module.id, content, '']];
|
|
26128
|
+
if(content.locals) module.exports = content.locals;
|
|
26129
|
+
// add the styles to the DOM
|
|
26130
|
+
var add = (__webpack_require__(9548)/* ["default"] */ .A)
|
|
26131
|
+
var update = add("f5932efa", content, true, {"sourceMap":false,"shadowMode":false});
|
|
26132
|
+
|
|
26133
|
+
/***/ }),
|
|
26134
|
+
|
|
26098
26135
|
/***/ 3393:
|
|
26099
26136
|
/***/ (function(module, __unused_webpack_exports, __webpack_require__) {
|
|
26100
26137
|
|
|
@@ -143897,6 +143934,443 @@ var viewContent_component = normalizeComponent(
|
|
|
143897
143934
|
)
|
|
143898
143935
|
|
|
143899
143936
|
/* harmony default export */ var viewContent = (viewContent_component.exports);
|
|
143937
|
+
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/moabase/src/common/components/ZipViewer/index.vue?vue&type=template&id=5bd9dee7&scoped=true
|
|
143938
|
+
var ZipViewervue_type_template_id_5bd9dee7_scoped_true_render = function render() {
|
|
143939
|
+
var _vm = this,
|
|
143940
|
+
_c = _vm._self._c;
|
|
143941
|
+
return _c('PopupDialog', {
|
|
143942
|
+
attrs: {
|
|
143943
|
+
"showpop": _vm.isShow,
|
|
143944
|
+
"title": "压缩文件预览"
|
|
143945
|
+
},
|
|
143946
|
+
on: {
|
|
143947
|
+
"update:showpop": function updateShowpop($event) {
|
|
143948
|
+
_vm.isShow = $event;
|
|
143949
|
+
}
|
|
143950
|
+
}
|
|
143951
|
+
}, [_c('div', {
|
|
143952
|
+
directives: [{
|
|
143953
|
+
name: "loading",
|
|
143954
|
+
rawName: "v-loading",
|
|
143955
|
+
value: _vm.loading,
|
|
143956
|
+
expression: "loading"
|
|
143957
|
+
}]
|
|
143958
|
+
}, [!_vm.loading ? _c('FileTree', {
|
|
143959
|
+
attrs: {
|
|
143960
|
+
"treeData": _vm.treeData,
|
|
143961
|
+
"root-name": _vm.rootName
|
|
143962
|
+
},
|
|
143963
|
+
on: {
|
|
143964
|
+
"preview": _vm.preview
|
|
143965
|
+
}
|
|
143966
|
+
}) : _vm._e()], 1)]);
|
|
143967
|
+
};
|
|
143968
|
+
var ZipViewervue_type_template_id_5bd9dee7_scoped_true_staticRenderFns = [];
|
|
143969
|
+
|
|
143970
|
+
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??ruleSet[1].rules[3]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue?vue&type=template&id=e919400c&scoped=true
|
|
143971
|
+
var FileTreevue_type_template_id_e919400c_scoped_true_render = function render() {
|
|
143972
|
+
var _vm = this,
|
|
143973
|
+
_c = _vm._self._c;
|
|
143974
|
+
return _c('div', {
|
|
143975
|
+
staticClass: "file-tree-container"
|
|
143976
|
+
}, [_c('div', {
|
|
143977
|
+
staticClass: "breadcrumb"
|
|
143978
|
+
}, [_c('div', {
|
|
143979
|
+
staticClass: "crumb-item",
|
|
143980
|
+
class: {
|
|
143981
|
+
'last-item': _vm.pathStack.length == 0
|
|
143982
|
+
},
|
|
143983
|
+
on: {
|
|
143984
|
+
"click": function click($event) {
|
|
143985
|
+
$event.stopPropagation();
|
|
143986
|
+
return _vm.jumpTo(-1);
|
|
143987
|
+
}
|
|
143988
|
+
}
|
|
143989
|
+
}, [_vm._v(_vm._s(_vm.rootName))]), _vm._l(_vm.pathStack, function (folder, index) {
|
|
143990
|
+
return _c('div', {
|
|
143991
|
+
key: folder.id,
|
|
143992
|
+
staticClass: "crumb-item-container"
|
|
143993
|
+
}, [_c('van-icon', {
|
|
143994
|
+
staticClass: "separator",
|
|
143995
|
+
attrs: {
|
|
143996
|
+
"name": "arrow"
|
|
143997
|
+
}
|
|
143998
|
+
}), _c('div', {
|
|
143999
|
+
staticClass: "crumb-item",
|
|
144000
|
+
class: {
|
|
144001
|
+
'last-item': index == _vm.pathStack.length - 1
|
|
144002
|
+
},
|
|
144003
|
+
on: {
|
|
144004
|
+
"click": function click($event) {
|
|
144005
|
+
$event.stopPropagation();
|
|
144006
|
+
return _vm.jumpTo(index);
|
|
144007
|
+
}
|
|
144008
|
+
}
|
|
144009
|
+
}, [_vm._v(_vm._s(folder.fileName))])], 1);
|
|
144010
|
+
})], 2), _c('div', {
|
|
144011
|
+
staticClass: "file-list"
|
|
144012
|
+
}, [_vm.currentList.length === 0 ? _c('div', {
|
|
144013
|
+
staticClass: "empty-tip"
|
|
144014
|
+
}, [_vm._v("文件夹为空")]) : _vm._e(), _vm._l(_vm.currentList, function (item) {
|
|
144015
|
+
return _c('div', {
|
|
144016
|
+
key: item.id,
|
|
144017
|
+
staticClass: "item",
|
|
144018
|
+
on: {
|
|
144019
|
+
"click": function click($event) {
|
|
144020
|
+
return _vm.handleItemClick(item);
|
|
144021
|
+
}
|
|
144022
|
+
}
|
|
144023
|
+
}, [_c('div', {
|
|
144024
|
+
staticClass: "folder"
|
|
144025
|
+
}, [_c('div', {
|
|
144026
|
+
staticClass: "icon"
|
|
144027
|
+
}, [item.fileType == 1 ? _c('svg', {
|
|
144028
|
+
attrs: {
|
|
144029
|
+
"aria-hidden": "true",
|
|
144030
|
+
"fill": "#333"
|
|
144031
|
+
}
|
|
144032
|
+
}, [_c('use', {
|
|
144033
|
+
attrs: {
|
|
144034
|
+
"xlink:href": '#icon-folder'
|
|
144035
|
+
}
|
|
144036
|
+
})]) : _vm.iconUrl(item.fileName) ? _c('img', {
|
|
144037
|
+
attrs: {
|
|
144038
|
+
"src": _vm.iconUrl(item.fileName)
|
|
144039
|
+
}
|
|
144040
|
+
}) : _vm._e()]), _c('div', {
|
|
144041
|
+
staticClass: "file-name",
|
|
144042
|
+
class: {
|
|
144043
|
+
'is-folder': item.fileType == 1
|
|
144044
|
+
}
|
|
144045
|
+
}, [_c('div', [_vm._v(_vm._s(item.fileName))]), item.fileType == 1 ? _c('div', {
|
|
144046
|
+
staticClass: "file-time"
|
|
144047
|
+
}, [_vm._v(_vm._s(item.fileTime))]) : _vm._e()]), item.fileType == 1 ? _c('van-icon', {
|
|
144048
|
+
attrs: {
|
|
144049
|
+
"name": "arrow"
|
|
144050
|
+
}
|
|
144051
|
+
}) : _vm._e()], 1)]);
|
|
144052
|
+
})], 2)]);
|
|
144053
|
+
};
|
|
144054
|
+
var FileTreevue_type_template_id_e919400c_scoped_true_staticRenderFns = [];
|
|
144055
|
+
|
|
144056
|
+
// EXTERNAL MODULE: ./src/global/utils/index.js
|
|
144057
|
+
var utils = __webpack_require__(7458);
|
|
144058
|
+
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue?vue&type=script&lang=js
|
|
144059
|
+
|
|
144060
|
+
/* harmony default export */ var FileTreevue_type_script_lang_js = ({
|
|
144061
|
+
name: "FileTree",
|
|
144062
|
+
props: {
|
|
144063
|
+
treeData: {
|
|
144064
|
+
type: Array,
|
|
144065
|
+
default: function _default() {
|
|
144066
|
+
return [];
|
|
144067
|
+
}
|
|
144068
|
+
},
|
|
144069
|
+
rootName: {
|
|
144070
|
+
type: String,
|
|
144071
|
+
default: ''
|
|
144072
|
+
}
|
|
144073
|
+
},
|
|
144074
|
+
data: function data() {
|
|
144075
|
+
return {
|
|
144076
|
+
pathStack: [] // 存储路径对象数组
|
|
144077
|
+
};
|
|
144078
|
+
},
|
|
144079
|
+
computed: {
|
|
144080
|
+
// 动态计算当前显示内容
|
|
144081
|
+
currentList: function currentList() {
|
|
144082
|
+
if (this.pathStack.length === 0) return this.treeData;
|
|
144083
|
+
return this.pathStack[this.pathStack.length - 1].children || [];
|
|
144084
|
+
}
|
|
144085
|
+
},
|
|
144086
|
+
methods: {
|
|
144087
|
+
// 进入文件夹
|
|
144088
|
+
handleItemClick: function handleItemClick(item) {
|
|
144089
|
+
if (item.fileType == 1) {
|
|
144090
|
+
this.pathStack.push(item);
|
|
144091
|
+
} else {
|
|
144092
|
+
this.$emit('preview', item);
|
|
144093
|
+
}
|
|
144094
|
+
},
|
|
144095
|
+
jumpTo: function jumpTo(index) {
|
|
144096
|
+
this.pathStack = this.pathStack.slice(0, index + 1);
|
|
144097
|
+
},
|
|
144098
|
+
iconUrl: function iconUrl(fileName) {
|
|
144099
|
+
if (typeof utils.attachIconUrl == 'function') {
|
|
144100
|
+
return (0,utils.attachIconUrl)(fileName);
|
|
144101
|
+
}
|
|
144102
|
+
return null;
|
|
144103
|
+
}
|
|
144104
|
+
}
|
|
144105
|
+
});
|
|
144106
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue?vue&type=script&lang=js
|
|
144107
|
+
/* harmony default export */ var ZipViewer_FileTreevue_type_script_lang_js = (FileTreevue_type_script_lang_js);
|
|
144108
|
+
// EXTERNAL MODULE: ./node_modules/vue-style-loader/index.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/@vue/vue-loader-v15/lib/loaders/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[4]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue?vue&type=style&index=0&id=e919400c&prod&scoped=true&lang=scss
|
|
144109
|
+
var FileTreevue_type_style_index_0_id_e919400c_prod_scoped_true_lang_scss = __webpack_require__(1174);
|
|
144110
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue?vue&type=style&index=0&id=e919400c&prod&scoped=true&lang=scss
|
|
144111
|
+
|
|
144112
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/src/common/components/ZipViewer/FileTree.vue
|
|
144113
|
+
|
|
144114
|
+
|
|
144115
|
+
|
|
144116
|
+
;
|
|
144117
|
+
|
|
144118
|
+
|
|
144119
|
+
/* normalize component */
|
|
144120
|
+
|
|
144121
|
+
var FileTree_component = normalizeComponent(
|
|
144122
|
+
ZipViewer_FileTreevue_type_script_lang_js,
|
|
144123
|
+
FileTreevue_type_template_id_e919400c_scoped_true_render,
|
|
144124
|
+
FileTreevue_type_template_id_e919400c_scoped_true_staticRenderFns,
|
|
144125
|
+
false,
|
|
144126
|
+
null,
|
|
144127
|
+
"e919400c",
|
|
144128
|
+
null
|
|
144129
|
+
|
|
144130
|
+
)
|
|
144131
|
+
|
|
144132
|
+
/* harmony default export */ var FileTree = (FileTree_component.exports);
|
|
144133
|
+
;// CONCATENATED MODULE: ./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[0]!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./packages/ecmoa/moabase/src/common/components/ZipViewer/index.vue?vue&type=script&lang=js
|
|
144134
|
+
function ZipViewervue_type_script_lang_js_typeof(o) { "@babel/helpers - typeof"; return ZipViewervue_type_script_lang_js_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, ZipViewervue_type_script_lang_js_typeof(o); }
|
|
144135
|
+
function ZipViewervue_type_script_lang_js_ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
144136
|
+
function ZipViewervue_type_script_lang_js_objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ZipViewervue_type_script_lang_js_ownKeys(Object(t), !0).forEach(function (r) { ZipViewervue_type_script_lang_js_defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ZipViewervue_type_script_lang_js_ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
144137
|
+
function ZipViewervue_type_script_lang_js_defineProperty(e, r, t) { return (r = ZipViewervue_type_script_lang_js_toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
144138
|
+
function ZipViewervue_type_script_lang_js_toPropertyKey(t) { var i = ZipViewervue_type_script_lang_js_toPrimitive(t, "string"); return "symbol" == ZipViewervue_type_script_lang_js_typeof(i) ? i : i + ""; }
|
|
144139
|
+
function ZipViewervue_type_script_lang_js_toPrimitive(t, r) { if ("object" != ZipViewervue_type_script_lang_js_typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != ZipViewervue_type_script_lang_js_typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
144140
|
+
function ZipViewervue_type_script_lang_js_regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ ZipViewervue_type_script_lang_js_regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == ZipViewervue_type_script_lang_js_typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; 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; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; 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); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(ZipViewervue_type_script_lang_js_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { 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); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; 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; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
144141
|
+
function ZipViewervue_type_script_lang_js_asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
|
|
144142
|
+
function ZipViewervue_type_script_lang_js_asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { ZipViewervue_type_script_lang_js_asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { ZipViewervue_type_script_lang_js_asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
|
|
144143
|
+
|
|
144144
|
+
|
|
144145
|
+
/* harmony default export */ var ZipViewervue_type_script_lang_js = ({
|
|
144146
|
+
components: {
|
|
144147
|
+
FileTree: FileTree
|
|
144148
|
+
},
|
|
144149
|
+
props: {
|
|
144150
|
+
show: {
|
|
144151
|
+
type: Boolean,
|
|
144152
|
+
default: function _default() {
|
|
144153
|
+
return false;
|
|
144154
|
+
}
|
|
144155
|
+
},
|
|
144156
|
+
productCode: {
|
|
144157
|
+
type: String,
|
|
144158
|
+
default: function _default() {
|
|
144159
|
+
return '';
|
|
144160
|
+
}
|
|
144161
|
+
},
|
|
144162
|
+
// 直接传入attach就不用传attachId和attachName
|
|
144163
|
+
attach: {
|
|
144164
|
+
type: Object,
|
|
144165
|
+
default: null
|
|
144166
|
+
},
|
|
144167
|
+
// attachId,attachName的优先级高于attach
|
|
144168
|
+
attachId: {
|
|
144169
|
+
type: String,
|
|
144170
|
+
default: function _default() {
|
|
144171
|
+
return '';
|
|
144172
|
+
}
|
|
144173
|
+
},
|
|
144174
|
+
attachName: {
|
|
144175
|
+
type: String,
|
|
144176
|
+
default: function _default() {
|
|
144177
|
+
return '';
|
|
144178
|
+
}
|
|
144179
|
+
},
|
|
144180
|
+
onPreview: {
|
|
144181
|
+
type: Function,
|
|
144182
|
+
default: null
|
|
144183
|
+
},
|
|
144184
|
+
toPdf: {
|
|
144185
|
+
type: Boolean,
|
|
144186
|
+
default: true
|
|
144187
|
+
},
|
|
144188
|
+
canDownload: {
|
|
144189
|
+
type: Number,
|
|
144190
|
+
default: 1
|
|
144191
|
+
}
|
|
144192
|
+
},
|
|
144193
|
+
computed: {
|
|
144194
|
+
isShow: {
|
|
144195
|
+
get: function get() {
|
|
144196
|
+
return this.show;
|
|
144197
|
+
},
|
|
144198
|
+
set: function set(val) {
|
|
144199
|
+
this.$emit('update:show', val);
|
|
144200
|
+
}
|
|
144201
|
+
}
|
|
144202
|
+
},
|
|
144203
|
+
watch: {
|
|
144204
|
+
show: function show(val) {
|
|
144205
|
+
if (val) {
|
|
144206
|
+
this.init();
|
|
144207
|
+
}
|
|
144208
|
+
}
|
|
144209
|
+
},
|
|
144210
|
+
data: function data() {
|
|
144211
|
+
return {
|
|
144212
|
+
treeData: [],
|
|
144213
|
+
rootName: '根目录',
|
|
144214
|
+
loading: false
|
|
144215
|
+
};
|
|
144216
|
+
},
|
|
144217
|
+
methods: {
|
|
144218
|
+
init: function init() {
|
|
144219
|
+
var _this = this;
|
|
144220
|
+
return ZipViewervue_type_script_lang_js_asyncToGenerator( /*#__PURE__*/ZipViewervue_type_script_lang_js_regeneratorRuntime().mark(function _callee() {
|
|
144221
|
+
var _this$getArg, attachName, attachId, _yield$_this$$http, body, code, message;
|
|
144222
|
+
return ZipViewervue_type_script_lang_js_regeneratorRuntime().wrap(function _callee$(_context) {
|
|
144223
|
+
while (1) switch (_context.prev = _context.next) {
|
|
144224
|
+
case 0:
|
|
144225
|
+
// 调用接口请求fileUrl获取文件
|
|
144226
|
+
_this.loading = true;
|
|
144227
|
+
_this$getArg = _this.getArg(), attachName = _this$getArg.attachName, attachId = _this$getArg.attachId;
|
|
144228
|
+
_this.rootName = attachName || '根目录';
|
|
144229
|
+
_context.next = 5;
|
|
144230
|
+
return _this.$http({
|
|
144231
|
+
method: 'get',
|
|
144232
|
+
url: "".concat(_this.productCode, "/webForm/findZipFileFolder?fileId=").concat(attachId)
|
|
144233
|
+
});
|
|
144234
|
+
case 5:
|
|
144235
|
+
_yield$_this$$http = _context.sent;
|
|
144236
|
+
body = _yield$_this$$http.body;
|
|
144237
|
+
code = _yield$_this$$http.code;
|
|
144238
|
+
message = _yield$_this$$http.message;
|
|
144239
|
+
if (!(code != 'success')) {
|
|
144240
|
+
_context.next = 12;
|
|
144241
|
+
break;
|
|
144242
|
+
}
|
|
144243
|
+
_this.$message.error(message);
|
|
144244
|
+
return _context.abrupt("return");
|
|
144245
|
+
case 12:
|
|
144246
|
+
body.folders.forEach(function (item) {
|
|
144247
|
+
item.id = item.fileId;
|
|
144248
|
+
});
|
|
144249
|
+
_this.treeData = _this.arrayToTree(body.folders);
|
|
144250
|
+
_this.loading = false;
|
|
144251
|
+
case 15:
|
|
144252
|
+
case "end":
|
|
144253
|
+
return _context.stop();
|
|
144254
|
+
}
|
|
144255
|
+
}, _callee);
|
|
144256
|
+
}))();
|
|
144257
|
+
},
|
|
144258
|
+
arrayToTree: function arrayToTree(list) {
|
|
144259
|
+
var map = {};
|
|
144260
|
+
var tree = [];
|
|
144261
|
+
list.forEach(function (item) {
|
|
144262
|
+
map[item.id] = ZipViewervue_type_script_lang_js_objectSpread(ZipViewervue_type_script_lang_js_objectSpread({}, item), {}, {
|
|
144263
|
+
children: []
|
|
144264
|
+
});
|
|
144265
|
+
});
|
|
144266
|
+
list.forEach(function (item) {
|
|
144267
|
+
var node = map[item.id];
|
|
144268
|
+
if (item.parentId && map[item.parentId]) {
|
|
144269
|
+
map[item.parentId].children.push(node);
|
|
144270
|
+
} else {
|
|
144271
|
+
tree.push(node);
|
|
144272
|
+
}
|
|
144273
|
+
});
|
|
144274
|
+
return tree;
|
|
144275
|
+
},
|
|
144276
|
+
preview: function preview(file) {
|
|
144277
|
+
var _this2 = this;
|
|
144278
|
+
return ZipViewervue_type_script_lang_js_asyncToGenerator( /*#__PURE__*/ZipViewervue_type_script_lang_js_regeneratorRuntime().mark(function _callee2() {
|
|
144279
|
+
var fileName, extension, appUrl, _this2$getArg, attachId, downloadUrl, canToPdf, isImg, device, canPreview;
|
|
144280
|
+
return ZipViewervue_type_script_lang_js_regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
144281
|
+
while (1) switch (_context2.prev = _context2.next) {
|
|
144282
|
+
case 0:
|
|
144283
|
+
if (!_this2.onPreview) {
|
|
144284
|
+
_context2.next = 3;
|
|
144285
|
+
break;
|
|
144286
|
+
}
|
|
144287
|
+
_this2.onPreview(file);
|
|
144288
|
+
return _context2.abrupt("return");
|
|
144289
|
+
case 3:
|
|
144290
|
+
fileName = file.fileName;
|
|
144291
|
+
extension = fileName.split('.').pop();
|
|
144292
|
+
appUrl = location.href.split('#')[0].split('mindex.html')[0];
|
|
144293
|
+
_this2$getArg = _this2.getArg(), attachId = _this2$getArg.attachId;
|
|
144294
|
+
downloadUrl = "".concat(appUrl, "apigw/").concat(_this2.productCode, "/webForm/downloadZipInnerFile?fileId=").concat(attachId, "&fullPath=").concat(encodeURIComponent(file.fullId), "&fileName=&csrfToken=").concat(window.$auth.getCsrfToken());
|
|
144295
|
+
canToPdf = ['doc', 'docx', 'xls', 'xlsx', 'ppt', 'pptx', 'wps', 'ofd', 'tif', 'tiff'];
|
|
144296
|
+
isImg = ['jpg', 'png', 'gif', 'jpeg', 'bmp'];
|
|
144297
|
+
device = js_cookie_default().get('device');
|
|
144298
|
+
canPreview = _this2.canDownload;
|
|
144299
|
+
if (canToPdf.includes(extension) && _this2.toPdf && !['qywx', 'zwwx'].includes(device)) {
|
|
144300
|
+
downloadUrl += '&topdf=true';
|
|
144301
|
+
canPreview = 1;
|
|
144302
|
+
}
|
|
144303
|
+
if (isImg.includes(extension)) {
|
|
144304
|
+
downloadUrl += '&img=true';
|
|
144305
|
+
canPreview = 1;
|
|
144306
|
+
}
|
|
144307
|
+
if (!(extension !== 'pdf')) {
|
|
144308
|
+
_context2.next = 18;
|
|
144309
|
+
break;
|
|
144310
|
+
}
|
|
144311
|
+
if (canPreview) {
|
|
144312
|
+
_context2.next = 18;
|
|
144313
|
+
break;
|
|
144314
|
+
}
|
|
144315
|
+
//只能在线预览、不能下载到本地
|
|
144316
|
+
_this2.$toast.fail('文件格式“' + extension + '”不支持在线预览');
|
|
144317
|
+
return _context2.abrupt("return");
|
|
144318
|
+
case 18:
|
|
144319
|
+
downloadUrl += '&attachH5CanDownload=' + _this2.canDownload;
|
|
144320
|
+
_this2.$mappUtils.downLoadAndOpenFile(null, downloadUrl, fileName, null);
|
|
144321
|
+
case 20:
|
|
144322
|
+
case "end":
|
|
144323
|
+
return _context2.stop();
|
|
144324
|
+
}
|
|
144325
|
+
}, _callee2);
|
|
144326
|
+
}))();
|
|
144327
|
+
},
|
|
144328
|
+
getArg: function getArg() {
|
|
144329
|
+
var attachId = '',
|
|
144330
|
+
attachName = '';
|
|
144331
|
+
if (this.attach) {
|
|
144332
|
+
attachId = this.attach.id;
|
|
144333
|
+
if (typeof this.attach.fileName == 'string') {
|
|
144334
|
+
var name = this.attach.fileName.split('.');
|
|
144335
|
+
name.pop();
|
|
144336
|
+
attachName = name.join('.');
|
|
144337
|
+
}
|
|
144338
|
+
}
|
|
144339
|
+
if (this.attachId) {
|
|
144340
|
+
attachId = this.attachId;
|
|
144341
|
+
}
|
|
144342
|
+
if (this.attachName) {
|
|
144343
|
+
attachName = this.attachName;
|
|
144344
|
+
}
|
|
144345
|
+
return {
|
|
144346
|
+
attachName: attachName,
|
|
144347
|
+
attachId: attachId
|
|
144348
|
+
};
|
|
144349
|
+
}
|
|
144350
|
+
}
|
|
144351
|
+
});
|
|
144352
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/src/common/components/ZipViewer/index.vue?vue&type=script&lang=js
|
|
144353
|
+
/* harmony default export */ var components_ZipViewervue_type_script_lang_js = (ZipViewervue_type_script_lang_js);
|
|
144354
|
+
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/src/common/components/ZipViewer/index.vue
|
|
144355
|
+
|
|
144356
|
+
|
|
144357
|
+
|
|
144358
|
+
|
|
144359
|
+
|
|
144360
|
+
/* normalize component */
|
|
144361
|
+
;
|
|
144362
|
+
var ZipViewer_component = normalizeComponent(
|
|
144363
|
+
components_ZipViewervue_type_script_lang_js,
|
|
144364
|
+
ZipViewervue_type_template_id_5bd9dee7_scoped_true_render,
|
|
144365
|
+
ZipViewervue_type_template_id_5bd9dee7_scoped_true_staticRenderFns,
|
|
144366
|
+
false,
|
|
144367
|
+
null,
|
|
144368
|
+
"5bd9dee7",
|
|
144369
|
+
null
|
|
144370
|
+
|
|
144371
|
+
)
|
|
144372
|
+
|
|
144373
|
+
/* harmony default export */ var ZipViewer = (ZipViewer_component.exports);
|
|
143900
144374
|
;// CONCATENATED MODULE: ./packages/ecmoa/moabase/index.js
|
|
143901
144375
|
function moabase_typeof(o) { "@babel/helpers - typeof"; return moabase_typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, moabase_typeof(o); }
|
|
143902
144376
|
function moabase_ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
@@ -143943,6 +144417,8 @@ var BbzxIndex = exportor.BbzxIndex,
|
|
|
143943
144417
|
|
|
143944
144418
|
//wfInstance/viewContent
|
|
143945
144419
|
|
|
144420
|
+
|
|
144421
|
+
|
|
143946
144422
|
// 以对象的结构保存组件,便于遍历
|
|
143947
144423
|
var components = {
|
|
143948
144424
|
BbzxFrameLoader: BbzxFrameLoader,
|
|
@@ -143978,7 +144454,8 @@ var components = {
|
|
|
143978
144454
|
handovernote: handovernote,
|
|
143979
144455
|
RelatedArticle: RelatedArticle,
|
|
143980
144456
|
SendFile: SendFile,
|
|
143981
|
-
Submission: Submission
|
|
144457
|
+
Submission: Submission,
|
|
144458
|
+
ZipViewer: ZipViewer
|
|
143982
144459
|
};
|
|
143983
144460
|
// 定义 install 方法
|
|
143984
144461
|
var moabase_install = function install(Vue) {
|