jtui3.0 1.1.29 → 1.1.30
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/lib/jtui3.0.common.js +555 -1260
- package/lib/jtui3.0.css +1 -1
- package/lib/jtui3.0.umd.js +555 -1260
- package/lib/jtui3.0.umd.min.js +18 -18
- package/package.json +1 -1
package/lib/jtui3.0.common.js
CHANGED
|
@@ -94489,7 +94489,7 @@ var full_screen_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */(0,
|
|
|
94489
94489
|
}); // src/components/full-screen.vue
|
|
94490
94490
|
|
|
94491
94491
|
|
|
94492
|
-
var full_screen_default = full_screen_vue_vue_type_script_setup_true_lang_default; // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/goblet-full.vue?vue&type=script&setup=true&lang.ts
|
|
94492
|
+
var full_screen_default = (/* unused pure expression or super */ null && (full_screen_vue_vue_type_script_setup_true_lang_default)); // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/goblet-full.vue?vue&type=script&setup=true&lang.ts
|
|
94493
94493
|
|
|
94494
94494
|
|
|
94495
94495
|
|
|
@@ -96768,7 +96768,7 @@ var refresh_left_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */(0
|
|
|
96768
96768
|
}); // src/components/refresh-left.vue
|
|
96769
96769
|
|
|
96770
96770
|
|
|
96771
|
-
var refresh_left_default = refresh_left_vue_vue_type_script_setup_true_lang_default; // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/refresh-right.vue?vue&type=script&setup=true&lang.ts
|
|
96771
|
+
var refresh_left_default = (/* unused pure expression or super */ null && (refresh_left_vue_vue_type_script_setup_true_lang_default)); // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/refresh-right.vue?vue&type=script&setup=true&lang.ts
|
|
96772
96772
|
|
|
96773
96773
|
|
|
96774
96774
|
|
|
@@ -96790,7 +96790,7 @@ var refresh_right_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */(
|
|
|
96790
96790
|
}); // src/components/refresh-right.vue
|
|
96791
96791
|
|
|
96792
96792
|
|
|
96793
|
-
var refresh_right_default = refresh_right_vue_vue_type_script_setup_true_lang_default; // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/refresh.vue?vue&type=script&setup=true&lang.ts
|
|
96793
|
+
var refresh_right_default = (/* unused pure expression or super */ null && (refresh_right_vue_vue_type_script_setup_true_lang_default)); // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/refresh.vue?vue&type=script&setup=true&lang.ts
|
|
96794
96794
|
|
|
96795
96795
|
|
|
96796
96796
|
|
|
@@ -96925,7 +96925,7 @@ var scale_to_original_vue_vue_type_script_setup_true_lang_default = /* @__PURE__
|
|
|
96925
96925
|
}); // src/components/scale-to-original.vue
|
|
96926
96926
|
|
|
96927
96927
|
|
|
96928
|
-
var scale_to_original_default = scale_to_original_vue_vue_type_script_setup_true_lang_default; // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/school.vue?vue&type=script&setup=true&lang.ts
|
|
96928
|
+
var scale_to_original_default = (/* unused pure expression or super */ null && (scale_to_original_vue_vue_type_script_setup_true_lang_default)); // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/school.vue?vue&type=script&setup=true&lang.ts
|
|
96929
96929
|
|
|
96930
96930
|
|
|
96931
96931
|
|
|
@@ -98554,7 +98554,7 @@ var zoom_in_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */(0,exte
|
|
|
98554
98554
|
}); // src/components/zoom-in.vue
|
|
98555
98555
|
|
|
98556
98556
|
|
|
98557
|
-
var zoom_in_default = zoom_in_vue_vue_type_script_setup_true_lang_default; // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/zoom-out.vue?vue&type=script&setup=true&lang.ts
|
|
98557
|
+
var zoom_in_default = (/* unused pure expression or super */ null && (zoom_in_vue_vue_type_script_setup_true_lang_default)); // unplugin-vue:/home/runner/work/element-plus-icons/element-plus-icons/packages/vue/src/components/zoom-out.vue?vue&type=script&setup=true&lang.ts
|
|
98558
98558
|
|
|
98559
98559
|
|
|
98560
98560
|
|
|
@@ -98576,7 +98576,7 @@ var zoom_out_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */(0,ext
|
|
|
98576
98576
|
}); // src/components/zoom-out.vue
|
|
98577
98577
|
|
|
98578
98578
|
|
|
98579
|
-
var zoom_out_default = zoom_out_vue_vue_type_script_setup_true_lang_default;
|
|
98579
|
+
var zoom_out_default = (/* unused pure expression or super */ null && (zoom_out_vue_vue_type_script_setup_true_lang_default));
|
|
98580
98580
|
|
|
98581
98581
|
;// CONCATENATED MODULE: ./node_modules/element-plus/es/hooks/use-same-target/index.mjs
|
|
98582
98582
|
|
|
@@ -149149,7 +149149,7 @@ function draggable(element, options) {
|
|
|
149149
149149
|
|
|
149150
149150
|
|
|
149151
149151
|
const isInContainer = (el, container) => {
|
|
149152
|
-
if (!
|
|
149152
|
+
if (!isClient || !el || !container) return false;
|
|
149153
149153
|
const elRect = el.getBoundingClientRect();
|
|
149154
149154
|
let containerRect;
|
|
149155
149155
|
|
|
@@ -277646,838 +277646,502 @@ const logViewvue_type_script_setup_true_lang_js_hoisted_6 = {
|
|
|
277646
277646
|
const logView_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(logViewvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-6a7a17cb"]])
|
|
277647
277647
|
|
|
277648
277648
|
/* harmony default export */ var logView = (logView_exports_);
|
|
277649
|
-
|
|
277649
|
+
// EXTERNAL MODULE: ./node_modules/@vue-office/docx/lib/index.js
|
|
277650
|
+
var lib = __webpack_require__(23549);
|
|
277651
|
+
var lib_default = /*#__PURE__*/__webpack_require__.n(lib);
|
|
277652
|
+
// EXTERNAL MODULE: ./node_modules/@vue-office/pdf/lib/index.js
|
|
277653
|
+
var pdf_lib = __webpack_require__(73200);
|
|
277654
|
+
var pdf_lib_default = /*#__PURE__*/__webpack_require__.n(pdf_lib);
|
|
277655
|
+
// EXTERNAL MODULE: ./node_modules/@vue-office/excel/lib/index.js
|
|
277656
|
+
var excel_lib = __webpack_require__(94581);
|
|
277657
|
+
var excel_lib_default = /*#__PURE__*/__webpack_require__.n(excel_lib);
|
|
277658
|
+
;// CONCATENATED MODULE: ./packages/utils/utils.js
|
|
277650
277659
|
|
|
277651
277660
|
|
|
277652
277661
|
|
|
277662
|
+
//获取本地存储
|
|
277653
277663
|
|
|
277654
|
-
|
|
277655
|
-
|
|
277656
|
-
|
|
277657
|
-
|
|
277658
|
-
|
|
277659
|
-
|
|
277660
|
-
|
|
277661
|
-
|
|
277662
|
-
|
|
277663
|
-
|
|
277664
|
-
default: 0
|
|
277665
|
-
},
|
|
277666
|
-
infinite: {
|
|
277667
|
-
type: Boolean,
|
|
277668
|
-
default: true
|
|
277669
|
-
},
|
|
277670
|
-
hideOnClickModal: Boolean,
|
|
277671
|
-
teleported: Boolean,
|
|
277672
|
-
closeOnPressEscape: {
|
|
277673
|
-
type: Boolean,
|
|
277674
|
-
default: true
|
|
277675
|
-
},
|
|
277676
|
-
zoomRate: {
|
|
277677
|
-
type: Number,
|
|
277678
|
-
default: 1.2
|
|
277679
|
-
},
|
|
277680
|
-
minScale: {
|
|
277681
|
-
type: Number,
|
|
277682
|
-
default: 0.2
|
|
277683
|
-
},
|
|
277684
|
-
maxScale: {
|
|
277685
|
-
type: Number,
|
|
277686
|
-
default: 7
|
|
277687
|
-
},
|
|
277688
|
-
crossorigin: {
|
|
277689
|
-
type: definePropType(String)
|
|
277664
|
+
function getStorage(type, key) {
|
|
277665
|
+
if (type == 'local') {
|
|
277666
|
+
return localStorage.getItem(key);
|
|
277667
|
+
} else if (type == 'session') {
|
|
277668
|
+
return sessionStorage.getItem(key);
|
|
277669
|
+
}
|
|
277670
|
+
}
|
|
277671
|
+
function parseJson(data) {
|
|
277672
|
+
if (!data) {
|
|
277673
|
+
return {};
|
|
277690
277674
|
}
|
|
277691
|
-
});
|
|
277692
|
-
const imageViewerEmits = {
|
|
277693
|
-
close: () => true,
|
|
277694
|
-
switch: index => types_isNumber(index),
|
|
277695
|
-
rotate: deg => types_isNumber(deg)
|
|
277696
|
-
};
|
|
277697
|
-
|
|
277698
|
-
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/image-viewer/src/image-viewer2.mjs
|
|
277699
|
-
|
|
277700
|
-
|
|
277701
|
-
|
|
277702
|
-
|
|
277703
|
-
|
|
277704
|
-
|
|
277705
|
-
|
|
277706
277675
|
|
|
277676
|
+
if (typeof data !== 'string') {
|
|
277677
|
+
return data;
|
|
277678
|
+
}
|
|
277707
277679
|
|
|
277680
|
+
let obj = {};
|
|
277708
277681
|
|
|
277682
|
+
try {
|
|
277683
|
+
obj = JSON.parse(data);
|
|
277684
|
+
obj = obj ? obj : {};
|
|
277685
|
+
} catch (e) {}
|
|
277709
277686
|
|
|
277687
|
+
return obj;
|
|
277688
|
+
}
|
|
277689
|
+
function getUrl2(key) {
|
|
277690
|
+
let _key = key;
|
|
277691
|
+
let path = "";
|
|
277710
277692
|
|
|
277693
|
+
if (/\//.test(key)) {
|
|
277694
|
+
let strs = key.split("/");
|
|
277695
|
+
key = strs[0];
|
|
277696
|
+
path = strs[1];
|
|
277697
|
+
}
|
|
277711
277698
|
|
|
277699
|
+
let obj = parseJson(localStorage.getItem("activeMenu"));
|
|
277700
|
+
let params = obj.params;
|
|
277712
277701
|
|
|
277702
|
+
if (!params || !params[key]) {
|
|
277703
|
+
return _key;
|
|
277704
|
+
}
|
|
277713
277705
|
|
|
277706
|
+
return params[key] + path;
|
|
277707
|
+
}
|
|
277708
|
+
const getUrl = () => {
|
|
277709
|
+
try {
|
|
277710
|
+
const root = JSON.parse(getStorage('local', 'activeMenu'));
|
|
277711
|
+
return root.params || {};
|
|
277712
|
+
} catch (_) {
|
|
277713
|
+
return {};
|
|
277714
|
+
}
|
|
277715
|
+
}; //字符串转boolean
|
|
277714
277716
|
|
|
277717
|
+
function stringToBoolean(v) {
|
|
277718
|
+
v = v == 'false' ? 0 : v;
|
|
277719
|
+
v = v == 'true' ? 1 : v;
|
|
277720
|
+
return Boolean(v);
|
|
277721
|
+
} //得到JSON对象
|
|
277715
277722
|
|
|
277716
|
-
|
|
277717
|
-
|
|
277718
|
-
}
|
|
277723
|
+
function getJson(val) {
|
|
277724
|
+
return typeof val === 'string' ? JSON.parse(val) : val;
|
|
277725
|
+
} //生成uuid
|
|
277719
277726
|
|
|
277720
|
-
|
|
277721
|
-
|
|
277722
|
-
|
|
277727
|
+
function uuid() {
|
|
277728
|
+
var s = [];
|
|
277729
|
+
var hexDigits = "0123456789abcdef";
|
|
277723
277730
|
|
|
277724
|
-
|
|
277725
|
-
|
|
277726
|
-
|
|
277727
|
-
}) {
|
|
277728
|
-
var _a;
|
|
277731
|
+
for (var i = 0; i < 32; i++) {
|
|
277732
|
+
s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
|
|
277733
|
+
}
|
|
277729
277734
|
|
|
277730
|
-
|
|
277731
|
-
const modes = {
|
|
277732
|
-
CONTAIN: {
|
|
277733
|
-
name: "contain",
|
|
277734
|
-
icon: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.markRaw)(full_screen_default)
|
|
277735
|
-
},
|
|
277736
|
-
ORIGINAL: {
|
|
277737
|
-
name: "original",
|
|
277738
|
-
icon: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.markRaw)(scale_to_original_default)
|
|
277739
|
-
}
|
|
277740
|
-
};
|
|
277741
|
-
const {
|
|
277742
|
-
t
|
|
277743
|
-
} = useLocale();
|
|
277744
|
-
const ns = use_namespace_useNamespace("image-viewer");
|
|
277745
|
-
const {
|
|
277746
|
-
nextZIndex
|
|
277747
|
-
} = useZIndex();
|
|
277748
|
-
const wrapper = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
277749
|
-
const imgRefs = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)([]);
|
|
277750
|
-
const scopeEventListener = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.effectScope)();
|
|
277751
|
-
const loading = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(true);
|
|
277752
|
-
const activeIndex = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(props.initialIndex);
|
|
277753
|
-
const mode = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.shallowRef)(modes.CONTAIN);
|
|
277754
|
-
const transform = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)({
|
|
277755
|
-
scale: 1,
|
|
277756
|
-
deg: 0,
|
|
277757
|
-
offsetX: 0,
|
|
277758
|
-
offsetY: 0,
|
|
277759
|
-
enableTransition: false
|
|
277760
|
-
});
|
|
277761
|
-
const zIndex = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)((_a = props.zIndex) != null ? _a : nextZIndex());
|
|
277762
|
-
const isSingle = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
277763
|
-
const {
|
|
277764
|
-
urlList
|
|
277765
|
-
} = props;
|
|
277766
|
-
return urlList.length <= 1;
|
|
277767
|
-
});
|
|
277768
|
-
const isFirst = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
277769
|
-
return activeIndex.value === 0;
|
|
277770
|
-
});
|
|
277771
|
-
const isLast = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
277772
|
-
return activeIndex.value === props.urlList.length - 1;
|
|
277773
|
-
});
|
|
277774
|
-
const currentImg = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
277775
|
-
return props.urlList[activeIndex.value];
|
|
277776
|
-
});
|
|
277777
|
-
const arrowPrevKls = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => [ns.e("btn"), ns.e("prev"), ns.is("disabled", !props.infinite && isFirst.value)]);
|
|
277778
|
-
const arrowNextKls = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => [ns.e("btn"), ns.e("next"), ns.is("disabled", !props.infinite && isLast.value)]);
|
|
277779
|
-
const imgStyle = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
277780
|
-
const {
|
|
277781
|
-
scale,
|
|
277782
|
-
deg,
|
|
277783
|
-
offsetX,
|
|
277784
|
-
offsetY,
|
|
277785
|
-
enableTransition
|
|
277786
|
-
} = transform.value;
|
|
277787
|
-
let translateX = offsetX / scale;
|
|
277788
|
-
let translateY = offsetY / scale;
|
|
277789
|
-
const radian = deg * Math.PI / 180;
|
|
277790
|
-
const cosRadian = Math.cos(radian);
|
|
277791
|
-
const sinRadian = Math.sin(radian);
|
|
277792
|
-
translateX = translateX * cosRadian + translateY * sinRadian;
|
|
277793
|
-
translateY = translateY * cosRadian - offsetX / scale * sinRadian;
|
|
277794
|
-
const style = {
|
|
277795
|
-
transform: `scale(${scale}) rotate(${deg}deg) translate(${translateX}px, ${translateY}px)`,
|
|
277796
|
-
transition: enableTransition ? "transform .3s" : ""
|
|
277797
|
-
};
|
|
277735
|
+
s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010
|
|
277798
277736
|
|
|
277799
|
-
|
|
277800
|
-
style.maxWidth = style.maxHeight = "100%";
|
|
277801
|
-
}
|
|
277737
|
+
s[19] = hexDigits.substr(s[19] & 0x3 | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01
|
|
277802
277738
|
|
|
277803
|
-
|
|
277804
|
-
|
|
277739
|
+
var uuid = s.join("");
|
|
277740
|
+
return uuid;
|
|
277741
|
+
} //设置本地存储
|
|
277805
277742
|
|
|
277806
|
-
|
|
277807
|
-
|
|
277808
|
-
|
|
277743
|
+
function setStorage(type, key, value) {
|
|
277744
|
+
if (type == 'local') {
|
|
277745
|
+
if (value == null) {
|
|
277746
|
+
return localStorage.getItem(key) && localStorage.removeItem(key);
|
|
277747
|
+
} else {
|
|
277748
|
+
return localStorage.setItem(key, value);
|
|
277809
277749
|
}
|
|
277810
|
-
|
|
277811
|
-
|
|
277812
|
-
|
|
277813
|
-
|
|
277814
|
-
|
|
277815
|
-
props.closeOnPressEscape && hide();
|
|
277816
|
-
break;
|
|
277817
|
-
|
|
277818
|
-
case aria_EVENT_CODE.space:
|
|
277819
|
-
toggleMode();
|
|
277820
|
-
break;
|
|
277821
|
-
|
|
277822
|
-
case aria_EVENT_CODE.left:
|
|
277823
|
-
prev();
|
|
277824
|
-
break;
|
|
277825
|
-
|
|
277826
|
-
case aria_EVENT_CODE.up:
|
|
277827
|
-
handleActions("zoomIn");
|
|
277828
|
-
break;
|
|
277829
|
-
|
|
277830
|
-
case aria_EVENT_CODE.right:
|
|
277831
|
-
next();
|
|
277832
|
-
break;
|
|
277833
|
-
|
|
277834
|
-
case aria_EVENT_CODE.down:
|
|
277835
|
-
handleActions("zoomOut");
|
|
277836
|
-
break;
|
|
277837
|
-
}
|
|
277838
|
-
});
|
|
277839
|
-
const mousewheelHandler = lodash_es_throttle(e => {
|
|
277840
|
-
const delta = e.deltaY || e.deltaX;
|
|
277841
|
-
handleActions(delta < 0 ? "zoomIn" : "zoomOut", {
|
|
277842
|
-
zoomRate: props.zoomRate,
|
|
277843
|
-
enableTransition: false
|
|
277844
|
-
});
|
|
277845
|
-
});
|
|
277846
|
-
scopeEventListener.run(() => {
|
|
277847
|
-
useEventListener(document, "keydown", keydownHandler);
|
|
277848
|
-
useEventListener(document, "wheel", mousewheelHandler);
|
|
277849
|
-
});
|
|
277750
|
+
} else if (type == 'session') {
|
|
277751
|
+
if (value == null) {
|
|
277752
|
+
return sessionStorage.getItem(key) && sessionStorage.removeItem(key);
|
|
277753
|
+
} else {
|
|
277754
|
+
return sessionStorage.setItem(key, value);
|
|
277850
277755
|
}
|
|
277756
|
+
}
|
|
277757
|
+
} //获取文件名后缀
|
|
277851
277758
|
|
|
277852
|
-
|
|
277853
|
-
|
|
277854
|
-
|
|
277759
|
+
function extname(filename) {
|
|
277760
|
+
if (!filename || typeof filename != 'string') {
|
|
277761
|
+
return false;
|
|
277762
|
+
}
|
|
277855
277763
|
|
|
277856
|
-
|
|
277857
|
-
|
|
277858
|
-
|
|
277764
|
+
let a = filename.split('').reverse().join('');
|
|
277765
|
+
let b = a.substring(0, a.search(/\./)).split('').reverse().join('');
|
|
277766
|
+
return b;
|
|
277767
|
+
}
|
|
277768
|
+
function getLoading(target, msg) {
|
|
277769
|
+
let param = {
|
|
277770
|
+
fullscreen: false,
|
|
277771
|
+
target: target ? target : '',
|
|
277772
|
+
background: 'rgba(0, 0, 0, 0.65)'
|
|
277773
|
+
};
|
|
277859
277774
|
|
|
277860
|
-
|
|
277861
|
-
|
|
277862
|
-
|
|
277863
|
-
}
|
|
277775
|
+
if (msg) {
|
|
277776
|
+
param.text = msg;
|
|
277777
|
+
}
|
|
277864
277778
|
|
|
277865
|
-
|
|
277866
|
-
|
|
277867
|
-
transform.value.enableTransition = false;
|
|
277868
|
-
const {
|
|
277869
|
-
offsetX,
|
|
277870
|
-
offsetY
|
|
277871
|
-
} = transform.value;
|
|
277872
|
-
const startX = e.pageX;
|
|
277873
|
-
const startY = e.pageY;
|
|
277874
|
-
const dragHandler = lodash_es_throttle(ev => {
|
|
277875
|
-
transform.value = { ...transform.value,
|
|
277876
|
-
offsetX: offsetX + ev.pageX - startX,
|
|
277877
|
-
offsetY: offsetY + ev.pageY - startY
|
|
277878
|
-
};
|
|
277879
|
-
});
|
|
277880
|
-
const removeMousemove = useEventListener(document, "mousemove", dragHandler);
|
|
277881
|
-
useEventListener(document, "mouseup", () => {
|
|
277882
|
-
removeMousemove();
|
|
277883
|
-
});
|
|
277884
|
-
e.preventDefault();
|
|
277885
|
-
}
|
|
277779
|
+
return ElLoading.service(param);
|
|
277780
|
+
} //下载文件(不支持不同源的图片文件)
|
|
277886
277781
|
|
|
277887
|
-
|
|
277888
|
-
|
|
277889
|
-
|
|
277890
|
-
|
|
277891
|
-
|
|
277892
|
-
|
|
277893
|
-
|
|
277894
|
-
|
|
277895
|
-
|
|
277782
|
+
function download(src, name) {
|
|
277783
|
+
let tempa = document.createElement('a');
|
|
277784
|
+
tempa.href = src;
|
|
277785
|
+
tempa.download = name;
|
|
277786
|
+
document.body.append(tempa);
|
|
277787
|
+
tempa.click();
|
|
277788
|
+
tempa.remove();
|
|
277789
|
+
}
|
|
277790
|
+
const downloadFile = async (url, axios) => {
|
|
277791
|
+
const {
|
|
277792
|
+
data
|
|
277793
|
+
} = await axios({
|
|
277794
|
+
url,
|
|
277795
|
+
method: 'get',
|
|
277796
|
+
responseType: 'blob'
|
|
277797
|
+
});
|
|
277798
|
+
let name = getFileName(url);
|
|
277799
|
+
(0,FileSaver_min.saveAs)(data, name);
|
|
277800
|
+
};
|
|
277896
277801
|
|
|
277897
|
-
|
|
277898
|
-
|
|
277899
|
-
|
|
277900
|
-
|
|
277901
|
-
const currentMode = mode.value.name;
|
|
277902
|
-
const index = modeValues.findIndex(i => i.name === currentMode);
|
|
277903
|
-
const nextIndex = (index + 1) % modeNames.length;
|
|
277904
|
-
mode.value = modes[modeNames[nextIndex]];
|
|
277905
|
-
reset();
|
|
277906
|
-
}
|
|
277802
|
+
function getFileName(url) {
|
|
277803
|
+
const urlAry = url.split('/');
|
|
277804
|
+
return urlAry[urlAry.length - 1];
|
|
277805
|
+
}
|
|
277907
277806
|
|
|
277908
|
-
|
|
277909
|
-
|
|
277910
|
-
|
|
277911
|
-
|
|
277807
|
+
const fileLinkToStreamDownload = (url, fileName, type) => {
|
|
277808
|
+
// let reg = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+).)+([A-Za-z0-9-~\/])+$/;
|
|
277809
|
+
// if (!reg.test(url)) {
|
|
277810
|
+
// throw new Error("传入参数不合法,不是标准的文件链接");
|
|
277811
|
+
// } else {
|
|
277812
|
+
// let xhr = new XMLHttpRequest();
|
|
277813
|
+
// xhr.open('get', url, true);
|
|
277814
|
+
// xhr.setRequestHeader('Content-Type', `application/${type}`);
|
|
277815
|
+
// xhr.responseType = "blob";
|
|
277816
|
+
// xhr.onload = function () {
|
|
277817
|
+
// if (this.status == 200) {
|
|
277818
|
+
// //接受二进制文件流
|
|
277819
|
+
// console.log(this)
|
|
277820
|
+
// var blob = this.response;
|
|
277821
|
+
// const blobUrl = window.URL.createObjectURL(blob);
|
|
277822
|
+
// // 这里的文件名根据实际情况从响应头或者url里获取
|
|
277823
|
+
// const a = document.createElement('a');
|
|
277824
|
+
// a.href = blobUrl;
|
|
277825
|
+
// a.download = fileName;
|
|
277826
|
+
// a.click();
|
|
277827
|
+
// window.URL.revokeObjectURL(blobUrl);
|
|
277828
|
+
// }
|
|
277829
|
+
// }
|
|
277830
|
+
// xhr.send();
|
|
277831
|
+
// }
|
|
277832
|
+
let xhr = new XMLHttpRequest();
|
|
277833
|
+
xhr.open('get', url, true);
|
|
277912
277834
|
|
|
277913
|
-
|
|
277914
|
-
|
|
277915
|
-
|
|
277916
|
-
}
|
|
277835
|
+
if (type) {
|
|
277836
|
+
xhr.setRequestHeader('Content-Type', `application/${type}`);
|
|
277837
|
+
}
|
|
277917
277838
|
|
|
277918
|
-
|
|
277919
|
-
if (isLast.value && !props.infinite) return;
|
|
277920
|
-
setActiveItem(activeIndex.value + 1);
|
|
277921
|
-
}
|
|
277839
|
+
xhr.responseType = "blob";
|
|
277922
277840
|
|
|
277923
|
-
|
|
277924
|
-
|
|
277925
|
-
|
|
277926
|
-
|
|
277927
|
-
|
|
277928
|
-
|
|
277929
|
-
const {
|
|
277930
|
-
zoomRate,
|
|
277931
|
-
rotateDeg,
|
|
277932
|
-
enableTransition
|
|
277933
|
-
} = {
|
|
277934
|
-
zoomRate: props.zoomRate,
|
|
277935
|
-
rotateDeg: 90,
|
|
277936
|
-
enableTransition: true,
|
|
277937
|
-
...options
|
|
277938
|
-
};
|
|
277841
|
+
xhr.onload = function () {
|
|
277842
|
+
if (this.status == 200) {
|
|
277843
|
+
//接受二进制文件流
|
|
277844
|
+
console.log(this);
|
|
277845
|
+
var blob = this.response;
|
|
277846
|
+
const blobUrl = window.URL.createObjectURL(blob); // 这里的文件名根据实际情况从响应头或者url里获取
|
|
277939
277847
|
|
|
277940
|
-
|
|
277941
|
-
|
|
277942
|
-
|
|
277943
|
-
|
|
277944
|
-
|
|
277848
|
+
const a = document.createElement('a');
|
|
277849
|
+
a.href = blobUrl;
|
|
277850
|
+
a.download = fileName;
|
|
277851
|
+
a.click();
|
|
277852
|
+
window.URL.revokeObjectURL(blobUrl);
|
|
277853
|
+
}
|
|
277854
|
+
};
|
|
277945
277855
|
|
|
277946
|
-
|
|
277856
|
+
xhr.send();
|
|
277857
|
+
}; // 函数防抖
|
|
277947
277858
|
|
|
277948
|
-
|
|
277949
|
-
|
|
277950
|
-
|
|
277951
|
-
|
|
277859
|
+
function utils_debounce(fn, delay) {
|
|
277860
|
+
var timer = null;
|
|
277861
|
+
delay = delay || 200;
|
|
277862
|
+
return function () {
|
|
277863
|
+
var args = arguments;
|
|
277864
|
+
var that = this;
|
|
277865
|
+
clearTimeout(timer);
|
|
277866
|
+
timer = setTimeout(function () {
|
|
277867
|
+
fn.apply(that, args);
|
|
277868
|
+
}, delay);
|
|
277869
|
+
};
|
|
277870
|
+
}
|
|
277871
|
+
/****
|
|
277872
|
+
* 四舍六入 保留n为有效数字
|
|
277873
|
+
*/
|
|
277952
277874
|
|
|
277953
|
-
|
|
277875
|
+
function keepSignificantFigures(number, digit) {
|
|
277876
|
+
number = number.toString();
|
|
277877
|
+
let tempArr = [...number];
|
|
277878
|
+
let res = null;
|
|
277954
277879
|
|
|
277955
|
-
|
|
277956
|
-
|
|
277957
|
-
|
|
277958
|
-
|
|
277880
|
+
if (tempArr.length <= digit) {
|
|
277881
|
+
res = (number - 0).toPrecision(digit);
|
|
277882
|
+
} else {
|
|
277883
|
+
let index = digit + 1;
|
|
277884
|
+
let tarindex = digit;
|
|
277885
|
+
let subindex = digit;
|
|
277886
|
+
let tempStr = number.substring(0, index);
|
|
277887
|
+
let tarnum1 = null;
|
|
277888
|
+
let tarnum2 = null;
|
|
277959
277889
|
|
|
277960
|
-
|
|
277961
|
-
|
|
277962
|
-
|
|
277963
|
-
|
|
277890
|
+
if (tempStr.indexOf('.') != -1) {
|
|
277891
|
+
//有小数点
|
|
277892
|
+
//判断最后一位是否是小数
|
|
277893
|
+
if (tempStr[tempStr.length - 1] == '.') {
|
|
277894
|
+
tarnum1 = tempArr[index + 1];
|
|
277895
|
+
subindex = index + 1;
|
|
277896
|
+
tarnum2 = tempArr[index - 2];
|
|
277897
|
+
tarindex = index - 2; //判断倒数第二位位是否是小数
|
|
277898
|
+
} else if (tempStr[tempStr.length - 2] == '.') {
|
|
277899
|
+
tarnum1 = tempArr[index];
|
|
277900
|
+
subindex = index;
|
|
277901
|
+
tarnum2 = tempArr[index - 1];
|
|
277902
|
+
tarindex = index - 1;
|
|
277903
|
+
} else {
|
|
277904
|
+
tarnum1 = tempArr[index];
|
|
277905
|
+
subindex = index;
|
|
277906
|
+
tarnum2 = tempArr[index - 1];
|
|
277907
|
+
tarindex = index - 1;
|
|
277964
277908
|
}
|
|
277965
|
-
|
|
277966
|
-
|
|
277909
|
+
} else {
|
|
277910
|
+
//无小数
|
|
277911
|
+
tarnum1 = tempArr[index];
|
|
277912
|
+
subindex = index;
|
|
277913
|
+
tarnum2 = tempArr[index - 1];
|
|
277914
|
+
tarindex = index - 1;
|
|
277967
277915
|
}
|
|
277968
277916
|
|
|
277969
|
-
(0
|
|
277970
|
-
|
|
277971
|
-
|
|
277972
|
-
|
|
277973
|
-
|
|
277974
|
-
|
|
277975
|
-
}
|
|
277976
|
-
});
|
|
277977
|
-
});
|
|
277978
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.watch)(activeIndex, val => {
|
|
277979
|
-
reset();
|
|
277980
|
-
emit("switch", val);
|
|
277981
|
-
});
|
|
277982
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
277983
|
-
var _a2, _b;
|
|
277917
|
+
if (tarnum2 % 2 == 0) {
|
|
277918
|
+
//是否为偶数
|
|
277919
|
+
if (tarnum1 > 6) {
|
|
277920
|
+
tempArr[tarindex] = tarnum2 - 0 + 1;
|
|
277921
|
+
}
|
|
277922
|
+
}
|
|
277984
277923
|
|
|
277985
|
-
|
|
277986
|
-
(_b = (_a2 = wrapper.value) == null ? void 0 : _a2.focus) == null ? void 0 : _b.call(_a2);
|
|
277987
|
-
});
|
|
277988
|
-
expose({
|
|
277989
|
-
setActiveItem
|
|
277990
|
-
});
|
|
277991
|
-
return (_ctx, _cache) => {
|
|
277992
|
-
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createBlock)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElTeleport), {
|
|
277993
|
-
to: "body",
|
|
277994
|
-
disabled: !_ctx.teleported
|
|
277995
|
-
}, {
|
|
277996
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(external_commonjs_vue_commonjs2_vue_root_Vue_.Transition, {
|
|
277997
|
-
name: "viewer-fade",
|
|
277998
|
-
appear: ""
|
|
277999
|
-
}, {
|
|
278000
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278001
|
-
ref_key: "wrapper",
|
|
278002
|
-
ref: wrapper,
|
|
278003
|
-
tabindex: -1,
|
|
278004
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("wrapper")),
|
|
278005
|
-
style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)({
|
|
278006
|
-
zIndex: zIndex.value
|
|
278007
|
-
})
|
|
278008
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278009
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("mask")),
|
|
278010
|
-
onClick: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withModifiers)($event => _ctx.hideOnClickModal && hide(), ["self"])
|
|
278011
|
-
}, null, 10, ["onClick"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(" CLOSE "), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278012
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)([(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("btn"), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("close")]),
|
|
278013
|
-
onClick: hide
|
|
278014
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), null, {
|
|
278015
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(close_default))]),
|
|
278016
|
-
_: 1
|
|
278017
|
-
})], 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(" ARROW "), !(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isSingle) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, {
|
|
278018
|
-
key: 0
|
|
278019
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278020
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(arrowPrevKls)),
|
|
278021
|
-
onClick: prev
|
|
278022
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), null, {
|
|
278023
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(arrow_left_default))]),
|
|
278024
|
-
_: 1
|
|
278025
|
-
})], 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278026
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(arrowNextKls)),
|
|
278027
|
-
onClick: next
|
|
278028
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), null, {
|
|
278029
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(arrow_right_default))]),
|
|
278030
|
-
_: 1
|
|
278031
|
-
})], 2)], 64)) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(" ACTIONS "), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278032
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)([(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("btn"), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("actions")])
|
|
278033
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278034
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("actions__inner"))
|
|
278035
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), {
|
|
278036
|
-
onClick: $event => handleActions("zoomOut")
|
|
278037
|
-
}, {
|
|
278038
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(zoom_out_default))]),
|
|
278039
|
-
_: 1
|
|
278040
|
-
}, 8, ["onClick"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), {
|
|
278041
|
-
onClick: $event => handleActions("zoomIn")
|
|
278042
|
-
}, {
|
|
278043
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(zoom_in_default))]),
|
|
278044
|
-
_: 1
|
|
278045
|
-
}, 8, ["onClick"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("i", {
|
|
278046
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("actions__divider"))
|
|
278047
|
-
}, null, 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), {
|
|
278048
|
-
onClick: toggleMode
|
|
278049
|
-
}, {
|
|
278050
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createBlock)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.resolveDynamicComponent)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(mode).icon)))]),
|
|
278051
|
-
_: 1
|
|
278052
|
-
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("i", {
|
|
278053
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("actions__divider"))
|
|
278054
|
-
}, null, 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), {
|
|
278055
|
-
onClick: $event => handleActions("anticlockwise")
|
|
278056
|
-
}, {
|
|
278057
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(refresh_left_default))]),
|
|
278058
|
-
_: 1
|
|
278059
|
-
}, 8, ["onClick"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElIcon), {
|
|
278060
|
-
onClick: $event => handleActions("clockwise")
|
|
278061
|
-
}, {
|
|
278062
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(refresh_right_default))]),
|
|
278063
|
-
_: 1
|
|
278064
|
-
}, 8, ["onClick"])], 2)], 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)(" CANVAS "), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278065
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("canvas"))
|
|
278066
|
-
}, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)(_ctx.urlList, (url, i) => {
|
|
278067
|
-
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withDirectives)(((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("img", {
|
|
278068
|
-
ref_for: true,
|
|
278069
|
-
ref: el => imgRefs.value[i] = el,
|
|
278070
|
-
key: url,
|
|
278071
|
-
src: url,
|
|
278072
|
-
style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(imgStyle)),
|
|
278073
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("img")),
|
|
278074
|
-
crossorigin: _ctx.crossorigin,
|
|
278075
|
-
onLoad: handleImgLoad,
|
|
278076
|
-
onError: handleImgError,
|
|
278077
|
-
onMousedown: handleMouseDown
|
|
278078
|
-
}, null, 46, ["src", "crossorigin"])), [[external_commonjs_vue_commonjs2_vue_root_Vue_.vShow, i === activeIndex.value]]);
|
|
278079
|
-
}), 128))], 2), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderSlot)(_ctx.$slots, "default")], 6)]),
|
|
278080
|
-
_: 3
|
|
278081
|
-
})]),
|
|
278082
|
-
_: 3
|
|
278083
|
-
}, 8, ["disabled"]);
|
|
278084
|
-
};
|
|
277924
|
+
res = tempArr.join("").substring(0, subindex);
|
|
278085
277925
|
}
|
|
278086
277926
|
|
|
278087
|
-
|
|
278088
|
-
|
|
278089
|
-
var ImageViewer = /* @__PURE__ */_export_sfc(image_viewer2_sfc_main, [["__file", "image-viewer.vue"]]);
|
|
278090
|
-
|
|
278091
|
-
|
|
278092
|
-
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/image-viewer/index.mjs
|
|
278093
|
-
|
|
278094
|
-
|
|
278095
|
-
|
|
278096
|
-
|
|
278097
|
-
const ElImageViewer = withInstall(ImageViewer);
|
|
278098
|
-
|
|
278099
|
-
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/image/src/image.mjs
|
|
278100
|
-
|
|
278101
|
-
|
|
278102
|
-
|
|
277927
|
+
return res;
|
|
277928
|
+
} //字符串转number
|
|
278103
277929
|
|
|
278104
|
-
|
|
278105
|
-
|
|
278106
|
-
|
|
278107
|
-
|
|
278108
|
-
|
|
278109
|
-
},
|
|
278110
|
-
fit: {
|
|
278111
|
-
type: String,
|
|
278112
|
-
values: ["", "contain", "cover", "fill", "none", "scale-down"],
|
|
278113
|
-
default: ""
|
|
278114
|
-
},
|
|
278115
|
-
loading: {
|
|
278116
|
-
type: String,
|
|
278117
|
-
values: ["eager", "lazy"]
|
|
278118
|
-
},
|
|
278119
|
-
lazy: Boolean,
|
|
278120
|
-
scrollContainer: {
|
|
278121
|
-
type: definePropType([String, Object])
|
|
278122
|
-
},
|
|
278123
|
-
previewSrcList: {
|
|
278124
|
-
type: definePropType(Array),
|
|
278125
|
-
default: () => mutable([])
|
|
278126
|
-
},
|
|
278127
|
-
previewTeleported: Boolean,
|
|
278128
|
-
zIndex: {
|
|
278129
|
-
type: Number
|
|
278130
|
-
},
|
|
278131
|
-
initialIndex: {
|
|
278132
|
-
type: Number,
|
|
278133
|
-
default: 0
|
|
278134
|
-
},
|
|
278135
|
-
infinite: {
|
|
278136
|
-
type: Boolean,
|
|
278137
|
-
default: true
|
|
278138
|
-
},
|
|
278139
|
-
closeOnPressEscape: {
|
|
278140
|
-
type: Boolean,
|
|
278141
|
-
default: true
|
|
278142
|
-
},
|
|
278143
|
-
zoomRate: {
|
|
278144
|
-
type: Number,
|
|
278145
|
-
default: 1.2
|
|
278146
|
-
},
|
|
278147
|
-
minScale: {
|
|
278148
|
-
type: Number,
|
|
278149
|
-
default: 0.2
|
|
278150
|
-
},
|
|
278151
|
-
maxScale: {
|
|
278152
|
-
type: Number,
|
|
278153
|
-
default: 7
|
|
278154
|
-
},
|
|
278155
|
-
crossorigin: {
|
|
278156
|
-
type: definePropType(String)
|
|
277930
|
+
function isInput(val) {
|
|
277931
|
+
if (val == undefined || val == null || val == "") {
|
|
277932
|
+
return 0;
|
|
277933
|
+
} else {
|
|
277934
|
+
return Number(val);
|
|
278157
277935
|
}
|
|
278158
|
-
}
|
|
278159
|
-
const imageEmits = {
|
|
278160
|
-
load: evt => evt instanceof Event,
|
|
278161
|
-
error: evt => evt instanceof Event,
|
|
278162
|
-
switch: val => types_isNumber(val),
|
|
278163
|
-
close: () => true,
|
|
278164
|
-
show: () => true
|
|
278165
|
-
};
|
|
278166
|
-
|
|
278167
|
-
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/image/src/image2.mjs
|
|
278168
|
-
|
|
278169
|
-
|
|
278170
|
-
|
|
278171
|
-
|
|
278172
|
-
|
|
278173
|
-
|
|
278174
|
-
|
|
278175
|
-
|
|
278176
|
-
|
|
278177
|
-
|
|
278178
|
-
|
|
278179
|
-
|
|
278180
|
-
|
|
278181
|
-
|
|
278182
|
-
|
|
278183
|
-
|
|
278184
|
-
|
|
278185
|
-
const image2_default_ = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({
|
|
278186
|
-
name: "ElImage",
|
|
278187
|
-
inheritAttrs: false
|
|
278188
|
-
});
|
|
278189
|
-
|
|
278190
|
-
const image2_sfc_main = /* @__PURE__ */(0,external_commonjs_vue_commonjs2_vue_root_Vue_.defineComponent)({ ...image2_default_,
|
|
278191
|
-
props: imageProps,
|
|
278192
|
-
emits: imageEmits,
|
|
278193
|
-
|
|
278194
|
-
setup(__props, {
|
|
278195
|
-
emit
|
|
278196
|
-
}) {
|
|
278197
|
-
const props = __props;
|
|
278198
|
-
let prevOverflow = "";
|
|
278199
|
-
const {
|
|
278200
|
-
t
|
|
278201
|
-
} = useLocale();
|
|
278202
|
-
const ns = use_namespace_useNamespace("image");
|
|
278203
|
-
const rawAttrs = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.useAttrs)();
|
|
278204
|
-
const containerAttrs = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278205
|
-
return lodash_es_fromPairs(Object.entries(rawAttrs).filter(([key]) => /^(data-|on[A-Z])/i.test(key) || ["id", "style"].includes(key)));
|
|
278206
|
-
});
|
|
278207
|
-
const imgAttrs = useAttrs({
|
|
278208
|
-
excludeListeners: true,
|
|
278209
|
-
excludeKeys: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278210
|
-
return Object.keys(containerAttrs.value);
|
|
278211
|
-
})
|
|
278212
|
-
});
|
|
278213
|
-
const imageSrc = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
278214
|
-
const hasLoadError = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(false);
|
|
278215
|
-
const isLoading = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(true);
|
|
278216
|
-
const showViewer = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(false);
|
|
278217
|
-
const container = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
278218
|
-
|
|
278219
|
-
const _scrollContainer = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
278220
|
-
|
|
278221
|
-
const supportLoading = shared_isClient && "loading" in HTMLImageElement.prototype;
|
|
278222
|
-
let stopScrollListener;
|
|
278223
|
-
let stopWheelListener;
|
|
278224
|
-
const imageKls = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => [ns.e("inner"), preview.value && ns.e("preview"), isLoading.value && ns.is("loading")]);
|
|
278225
|
-
const imageStyle = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278226
|
-
const {
|
|
278227
|
-
fit
|
|
278228
|
-
} = props;
|
|
278229
|
-
|
|
278230
|
-
if (shared_isClient && fit) {
|
|
278231
|
-
return {
|
|
278232
|
-
objectFit: fit
|
|
278233
|
-
};
|
|
278234
|
-
}
|
|
278235
|
-
|
|
278236
|
-
return {};
|
|
278237
|
-
});
|
|
278238
|
-
const preview = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278239
|
-
const {
|
|
278240
|
-
previewSrcList
|
|
278241
|
-
} = props;
|
|
278242
|
-
return Array.isArray(previewSrcList) && previewSrcList.length > 0;
|
|
278243
|
-
});
|
|
278244
|
-
const imageIndex = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278245
|
-
const {
|
|
278246
|
-
previewSrcList,
|
|
278247
|
-
initialIndex
|
|
278248
|
-
} = props;
|
|
278249
|
-
let previewIndex = initialIndex;
|
|
278250
|
-
|
|
278251
|
-
if (initialIndex > previewSrcList.length - 1) {
|
|
278252
|
-
previewIndex = 0;
|
|
278253
|
-
}
|
|
278254
|
-
|
|
278255
|
-
return previewIndex;
|
|
278256
|
-
});
|
|
278257
|
-
const isManual = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.computed)(() => {
|
|
278258
|
-
if (props.loading === "eager") return false;
|
|
278259
|
-
return !supportLoading && props.loading === "lazy" || props.lazy;
|
|
278260
|
-
});
|
|
278261
|
-
|
|
278262
|
-
const loadImage = () => {
|
|
278263
|
-
if (!shared_isClient) return;
|
|
278264
|
-
isLoading.value = true;
|
|
278265
|
-
hasLoadError.value = false;
|
|
278266
|
-
imageSrc.value = props.src;
|
|
278267
|
-
};
|
|
277936
|
+
} // 格式化为float
|
|
278268
277937
|
|
|
278269
|
-
|
|
278270
|
-
|
|
278271
|
-
hasLoadError.value = false;
|
|
278272
|
-
emit("load", event);
|
|
278273
|
-
}
|
|
277938
|
+
function fomatFloat(num, n) {
|
|
277939
|
+
var f = parseFloat(num);
|
|
278274
277940
|
|
|
278275
|
-
|
|
278276
|
-
|
|
278277
|
-
|
|
278278
|
-
emit("error", event);
|
|
278279
|
-
}
|
|
277941
|
+
if (isNaN(f)) {
|
|
277942
|
+
return false;
|
|
277943
|
+
}
|
|
278280
277944
|
|
|
278281
|
-
|
|
278282
|
-
if (isInContainer(container.value, _scrollContainer.value)) {
|
|
278283
|
-
loadImage();
|
|
278284
|
-
removeLazyLoadListener();
|
|
278285
|
-
}
|
|
278286
|
-
}
|
|
277945
|
+
f = Math.round(num * Math.pow(10, n)) / Math.pow(10, n); // n 幂
|
|
278287
277946
|
|
|
278288
|
-
|
|
277947
|
+
var s = f.toString();
|
|
277948
|
+
var rs = s.indexOf('.'); //判定如果是整数,增加小数点再补0
|
|
278289
277949
|
|
|
278290
|
-
|
|
278291
|
-
|
|
277950
|
+
if (rs < 0 && n > 0) {
|
|
277951
|
+
rs = s.length;
|
|
277952
|
+
s += '.';
|
|
277953
|
+
}
|
|
278292
277954
|
|
|
278293
|
-
|
|
278294
|
-
|
|
278295
|
-
|
|
278296
|
-
scrollContainer
|
|
278297
|
-
} = props;
|
|
277955
|
+
while (s.length <= rs + n) {
|
|
277956
|
+
s += '0';
|
|
277957
|
+
}
|
|
278298
277958
|
|
|
278299
|
-
|
|
278300
|
-
|
|
278301
|
-
} else if (shared_esm_bundler_isString(scrollContainer) && scrollContainer !== "") {
|
|
278302
|
-
_scrollContainer.value = (_a = document.querySelector(scrollContainer)) != null ? _a : void 0;
|
|
278303
|
-
} else if (container.value) {
|
|
278304
|
-
_scrollContainer.value = getScrollContainer(container.value);
|
|
278305
|
-
}
|
|
277959
|
+
return s;
|
|
277960
|
+
} // 检查对象或纯数组中属性值是否有为空的情况
|
|
278306
277961
|
|
|
278307
|
-
|
|
278308
|
-
|
|
278309
|
-
setTimeout(() => handleLazyLoad(), 100);
|
|
278310
|
-
}
|
|
278311
|
-
}
|
|
277962
|
+
function isRepeatObj(item) {
|
|
277963
|
+
console.log(item, 'kkkk');
|
|
278312
277964
|
|
|
278313
|
-
|
|
278314
|
-
|
|
278315
|
-
|
|
278316
|
-
_scrollContainer.value = void 0;
|
|
277965
|
+
for (let index in item) {
|
|
277966
|
+
if (item[index] === '') {
|
|
277967
|
+
return false;
|
|
278317
277968
|
}
|
|
277969
|
+
}
|
|
278318
277970
|
|
|
278319
|
-
|
|
278320
|
-
|
|
277971
|
+
return true;
|
|
277972
|
+
} // 检查对象数组中属性值是否有为空的情况
|
|
278321
277973
|
|
|
278322
|
-
|
|
278323
|
-
|
|
278324
|
-
|
|
278325
|
-
|
|
278326
|
-
e.preventDefault();
|
|
277974
|
+
function isRepeatArr(item) {
|
|
277975
|
+
for (let index of item) {
|
|
277976
|
+
for (let ind in index) {
|
|
277977
|
+
if (index[ind] === '') {
|
|
278327
277978
|
return false;
|
|
278328
277979
|
}
|
|
278329
277980
|
}
|
|
277981
|
+
}
|
|
278330
277982
|
|
|
278331
|
-
|
|
278332
|
-
|
|
278333
|
-
stopWheelListener = useEventListener("wheel", wheelHandler, {
|
|
278334
|
-
passive: false
|
|
278335
|
-
});
|
|
278336
|
-
prevOverflow = document.body.style.overflow;
|
|
278337
|
-
document.body.style.overflow = "hidden";
|
|
278338
|
-
showViewer.value = true;
|
|
278339
|
-
emit("show");
|
|
278340
|
-
}
|
|
278341
|
-
|
|
278342
|
-
function closeViewer() {
|
|
278343
|
-
stopWheelListener == null ? void 0 : stopWheelListener();
|
|
278344
|
-
document.body.style.overflow = prevOverflow;
|
|
278345
|
-
showViewer.value = false;
|
|
278346
|
-
emit("close");
|
|
278347
|
-
}
|
|
277983
|
+
return true;
|
|
277984
|
+
} // 深拷贝
|
|
278348
277985
|
|
|
278349
|
-
|
|
278350
|
-
|
|
278351
|
-
}
|
|
277986
|
+
function deepCopy(obj1) {
|
|
277987
|
+
var obj2 = Array.isArray(obj1) ? [] : {};
|
|
278352
277988
|
|
|
278353
|
-
|
|
278354
|
-
|
|
278355
|
-
|
|
278356
|
-
|
|
278357
|
-
|
|
278358
|
-
|
|
278359
|
-
|
|
278360
|
-
|
|
278361
|
-
|
|
278362
|
-
|
|
278363
|
-
(0,external_commonjs_vue_commonjs2_vue_root_Vue_.onMounted)(() => {
|
|
278364
|
-
if (isManual.value) {
|
|
278365
|
-
addLazyLoadListener();
|
|
278366
|
-
} else {
|
|
278367
|
-
loadImage();
|
|
277989
|
+
if (obj1 && typeof obj1 === "object") {
|
|
277990
|
+
for (let i in obj1) {
|
|
277991
|
+
if (obj1.i) {
|
|
277992
|
+
// 如果子属性为引用数据类型,递归复制
|
|
277993
|
+
if (obj1[i] && typeof obj1[i] === "object") {
|
|
277994
|
+
obj2[i] = deepCopy(obj1[i]);
|
|
277995
|
+
} else {
|
|
277996
|
+
// 如果是基本数据类型,只是简单的复制
|
|
277997
|
+
obj2[i] = obj1[i];
|
|
277998
|
+
}
|
|
278368
277999
|
}
|
|
278369
|
-
}
|
|
278370
|
-
return (_ctx, _cache) => {
|
|
278371
|
-
return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", (0,external_commonjs_vue_commonjs2_vue_root_Vue_.mergeProps)({
|
|
278372
|
-
ref_key: "container",
|
|
278373
|
-
ref: container
|
|
278374
|
-
}, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(containerAttrs), {
|
|
278375
|
-
class: [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).b(), _ctx.$attrs.class]
|
|
278376
|
-
}), [hasLoadError.value ? (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderSlot)(_ctx.$slots, "error", {
|
|
278377
|
-
key: 0
|
|
278378
|
-
}, () => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278379
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("error"))
|
|
278380
|
-
}, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.toDisplayString)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(t)("el.image.error")), 3)]) : ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, {
|
|
278381
|
-
key: 1
|
|
278382
|
-
}, [imageSrc.value !== void 0 ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("img", (0,external_commonjs_vue_commonjs2_vue_root_Vue_.mergeProps)({
|
|
278383
|
-
key: 0
|
|
278384
|
-
}, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(imgAttrs), {
|
|
278385
|
-
src: imageSrc.value,
|
|
278386
|
-
loading: _ctx.loading,
|
|
278387
|
-
style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(imageStyle),
|
|
278388
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(imageKls),
|
|
278389
|
-
crossorigin: _ctx.crossorigin,
|
|
278390
|
-
onClick: clickHandler,
|
|
278391
|
-
onLoad: handleLoad,
|
|
278392
|
-
onError: handleError
|
|
278393
|
-
}), null, 16, ["src", "loading", "crossorigin"])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true), isLoading.value ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
|
|
278394
|
-
key: 1,
|
|
278395
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("wrapper"))
|
|
278396
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderSlot)(_ctx.$slots, "placeholder", {}, () => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278397
|
-
class: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeClass)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ns).e("placeholder"))
|
|
278398
|
-
}, null, 2)])], 2)) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true)], 64)), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(preview) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, {
|
|
278399
|
-
key: 2
|
|
278400
|
-
}, [showViewer.value ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createBlock)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(ElImageViewer), {
|
|
278401
|
-
key: 0,
|
|
278402
|
-
"z-index": _ctx.zIndex,
|
|
278403
|
-
"initial-index": (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(imageIndex),
|
|
278404
|
-
infinite: _ctx.infinite,
|
|
278405
|
-
"zoom-rate": _ctx.zoomRate,
|
|
278406
|
-
"min-scale": _ctx.minScale,
|
|
278407
|
-
"max-scale": _ctx.maxScale,
|
|
278408
|
-
"url-list": _ctx.previewSrcList,
|
|
278409
|
-
crossorigin: _ctx.crossorigin,
|
|
278410
|
-
"hide-on-click-modal": _ctx.hideOnClickModal,
|
|
278411
|
-
teleported: _ctx.previewTeleported,
|
|
278412
|
-
"close-on-press-escape": _ctx.closeOnPressEscape,
|
|
278413
|
-
onClose: closeViewer,
|
|
278414
|
-
onSwitch: switchViewer
|
|
278415
|
-
}, {
|
|
278416
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [_ctx.$slots.viewer ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
|
|
278417
|
-
key: 0
|
|
278418
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderSlot)(_ctx.$slots, "viewer")])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true)]),
|
|
278419
|
-
_: 3
|
|
278420
|
-
}, 8, ["z-index", "initial-index", "infinite", "zoom-rate", "min-scale", "max-scale", "url-list", "crossorigin", "hide-on-click-modal", "teleported", "close-on-press-escape"])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true)], 64)) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("v-if", true)], 16);
|
|
278421
|
-
};
|
|
278000
|
+
}
|
|
278422
278001
|
}
|
|
278423
278002
|
|
|
278424
|
-
|
|
278003
|
+
return obj2;
|
|
278004
|
+
}
|
|
278005
|
+
/**
|
|
278006
|
+
* 得到有效数字
|
|
278007
|
+
*/
|
|
278425
278008
|
|
|
278426
|
-
|
|
278009
|
+
function getEffeNum(num, digit) {
|
|
278010
|
+
if (!isNumber(num)) {
|
|
278011
|
+
return num;
|
|
278012
|
+
}
|
|
278427
278013
|
|
|
278014
|
+
let _num = num;
|
|
278428
278015
|
|
|
278429
|
-
|
|
278016
|
+
if (Math.abs(_num) >= Math.pow(10, digit) / 10) {
|
|
278017
|
+
let _numlen = parseInt(_num).toString().replaceAll(/^-/g, "").length;
|
|
278430
278018
|
|
|
278019
|
+
let _len = Math.pow(10, _numlen - digit);
|
|
278431
278020
|
|
|
278021
|
+
_num = parseInt(parseFloat(_num / _len / 10).toFixed(1) * _len * 10).toString();
|
|
278022
|
+
} else if (-1 <= _num && _num <= 1) {
|
|
278023
|
+
_num = parseFloat(_num).toFixed(digit);
|
|
278432
278024
|
|
|
278025
|
+
if (_num == 1 || _num == -1) {
|
|
278026
|
+
_num = parseFloat(_num).toPrecision(digit);
|
|
278027
|
+
}
|
|
278028
|
+
} else {
|
|
278029
|
+
_num = parseFloat(_num).toPrecision(digit);
|
|
278030
|
+
}
|
|
278433
278031
|
|
|
278434
|
-
|
|
278032
|
+
return _num;
|
|
278033
|
+
}
|
|
278034
|
+
function getMaxMin(datas, key) {
|
|
278035
|
+
let min = 999999999999;
|
|
278036
|
+
let max = -999999999999;
|
|
278037
|
+
datas.forEach(item => {
|
|
278038
|
+
let data = key ? item[key] : item;
|
|
278435
278039
|
|
|
278436
|
-
|
|
278437
|
-
|
|
278040
|
+
if (data == null || data == undefined) {
|
|
278041
|
+
return;
|
|
278042
|
+
}
|
|
278438
278043
|
|
|
278439
|
-
|
|
278440
|
-
|
|
278044
|
+
let num = Number(data);
|
|
278045
|
+
min = min > num ? num : min;
|
|
278046
|
+
max = max < num ? num : max;
|
|
278047
|
+
});
|
|
278048
|
+
return {
|
|
278049
|
+
max: max,
|
|
278050
|
+
min: min
|
|
278051
|
+
};
|
|
278052
|
+
}
|
|
278053
|
+
function convertMaxMin(data) {
|
|
278054
|
+
let ymin = data.min ? Number(data.min) : 0;
|
|
278055
|
+
let ymax = data.max ? Number(data.max) : 0;
|
|
278056
|
+
let min = Math.floor(ymin * 100 - 1);
|
|
278057
|
+
let gw = min % 10;
|
|
278441
278058
|
|
|
278442
|
-
|
|
278059
|
+
if (gw > 5) {
|
|
278060
|
+
min = min - gw - 10;
|
|
278061
|
+
} else {
|
|
278062
|
+
min = min - gw - 5;
|
|
278063
|
+
}
|
|
278443
278064
|
|
|
278065
|
+
ymin = (min / 100).toFixed(2);
|
|
278066
|
+
let max = Math.floor(ymax * 100 + 1);
|
|
278067
|
+
gw = max % 10;
|
|
278444
278068
|
|
|
278445
|
-
|
|
278069
|
+
if (gw > 5) {
|
|
278070
|
+
max = max - gw + 10;
|
|
278071
|
+
} else {
|
|
278072
|
+
max = max - gw + 5;
|
|
278073
|
+
}
|
|
278446
278074
|
|
|
278075
|
+
ymax = (max / 100).toFixed(2);
|
|
278076
|
+
return {
|
|
278077
|
+
max: ymax,
|
|
278078
|
+
min: ymin
|
|
278079
|
+
};
|
|
278080
|
+
}
|
|
278081
|
+
function getDate(tm) {
|
|
278082
|
+
if (tm instanceof Date) {
|
|
278083
|
+
return tm;
|
|
278084
|
+
}
|
|
278447
278085
|
|
|
278086
|
+
return new Date(tm.replace(/-/g, '/'));
|
|
278087
|
+
}
|
|
278088
|
+
function utils_formatDate(date, format) {
|
|
278089
|
+
let year = date.getFullYear();
|
|
278090
|
+
let month = (date.getMonth() + 1 < 10 ? '0' : '') + (date.getMonth() + 1);
|
|
278091
|
+
let day = (date.getDate() < 10 ? '0' : '') + date.getDate();
|
|
278092
|
+
let hour = (date.getHours() < 10 ? '0' : '') + date.getHours();
|
|
278093
|
+
let mi = (date.getMinutes() < 10 ? '0' : '') + date.getMinutes();
|
|
278094
|
+
let second = (date.getSeconds() < 10 ? '0' : '') + date.getSeconds();
|
|
278095
|
+
let formatFields = {
|
|
278096
|
+
yyyy: '{{year}}',
|
|
278097
|
+
MM: '{{month}}',
|
|
278098
|
+
dd: '{{day}}',
|
|
278099
|
+
HH: '{{hour}}',
|
|
278100
|
+
mm: '{{mi}}',
|
|
278101
|
+
ss: '{{second}}'
|
|
278102
|
+
};
|
|
278448
278103
|
|
|
278449
|
-
|
|
278104
|
+
for (let field of Object.keys(formatFields)) {
|
|
278105
|
+
format = format.replaceAll(field, formatFields[field]);
|
|
278106
|
+
}
|
|
278450
278107
|
|
|
278451
|
-
|
|
278452
|
-
|
|
278453
|
-
|
|
278454
|
-
|
|
278455
|
-
|
|
278456
|
-
|
|
278457
|
-
|
|
278458
|
-
|
|
278459
|
-
|
|
278108
|
+
return replace(format, {
|
|
278109
|
+
year: year,
|
|
278110
|
+
month: month,
|
|
278111
|
+
day: day,
|
|
278112
|
+
hour: hour,
|
|
278113
|
+
mi: mi,
|
|
278114
|
+
second: second
|
|
278115
|
+
});
|
|
278116
|
+
}
|
|
278460
278117
|
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/FileView.vue?vue&type=script&setup=true&lang=js
|
|
278461
278118
|
/* unplugin-vue-components disabled */
|
|
278462
278119
|
|
|
278463
278120
|
|
|
278464
278121
|
|
|
278465
278122
|
|
|
278466
|
-
|
|
278467
|
-
|
|
278468
|
-
const FileViewvue_type_script_setup_true_lang_js_withScopeId = n => (_pushScopeId("data-v-ab80c6ac"), n = n(), _popScopeId(), n);
|
|
278123
|
+
const FileViewvue_type_script_setup_true_lang_js_withScopeId = n => (_pushScopeId("data-v-9bec2f9c"), n = n(), _popScopeId(), n);
|
|
278469
278124
|
|
|
278470
278125
|
const FileViewvue_type_script_setup_true_lang_js_hoisted_1 = {
|
|
278471
278126
|
style: {
|
|
278472
|
-
"margin-bottom": "10px"
|
|
278127
|
+
"margin-bottom": "10px",
|
|
278128
|
+
"display": "flex",
|
|
278129
|
+
"align-items": "center"
|
|
278473
278130
|
}
|
|
278474
278131
|
};
|
|
278475
278132
|
const FileViewvue_type_script_setup_true_lang_js_hoisted_2 = {
|
|
278133
|
+
key: 0,
|
|
278134
|
+
class: "img-handler"
|
|
278135
|
+
};
|
|
278136
|
+
const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = {
|
|
278476
278137
|
style: {
|
|
278477
|
-
"height": "calc(100% - 60px)"
|
|
278138
|
+
"height": "calc(100% - 60px)",
|
|
278139
|
+
"overflow": "auto"
|
|
278478
278140
|
}
|
|
278479
278141
|
};
|
|
278480
|
-
const
|
|
278142
|
+
const FileViewvue_type_script_setup_true_lang_js_hoisted_4 = ["src"];
|
|
278143
|
+
const FileViewvue_type_script_setup_true_lang_js_hoisted_5 = ["src"];
|
|
278144
|
+
|
|
278481
278145
|
|
|
278482
278146
|
|
|
278483
278147
|
|
|
@@ -278495,17 +278159,22 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278495
278159
|
},
|
|
278496
278160
|
rowParams: {
|
|
278497
278161
|
type: Object
|
|
278162
|
+
},
|
|
278163
|
+
axios: {
|
|
278164
|
+
type: Function
|
|
278498
278165
|
}
|
|
278499
278166
|
},
|
|
278500
278167
|
|
|
278501
278168
|
setup(__props) {
|
|
278502
278169
|
const props = __props;
|
|
278503
|
-
const imgRef = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)();
|
|
278504
278170
|
|
|
278505
278171
|
let Base64 = (__webpack_require__(37702).Base64);
|
|
278506
278172
|
|
|
278507
278173
|
const fileLoading = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)(false);
|
|
278508
278174
|
const rowParams = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.reactive)(props.rowParams);
|
|
278175
|
+
const imgStyle = (0,external_commonjs_vue_commonjs2_vue_root_Vue_.ref)({
|
|
278176
|
+
transform: 'scale(1) rotate(0deg)'
|
|
278177
|
+
});
|
|
278509
278178
|
const {
|
|
278510
278179
|
width,
|
|
278511
278180
|
height
|
|
@@ -278557,12 +278226,10 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278557
278226
|
|
|
278558
278227
|
if (isPicture.value) {
|
|
278559
278228
|
picList.value.push(fileUrl.value);
|
|
278560
|
-
console.log(fileUrl.value, "fileUrl");
|
|
278561
278229
|
return "";
|
|
278562
278230
|
}
|
|
278563
278231
|
|
|
278564
278232
|
fileUrl.value = window.location.origin + fileUrl.value;
|
|
278565
|
-
console.log(fileUrl.value, "fileUrl");
|
|
278566
278233
|
return window.location.origin + "/fileview/onlinePreview?url=" + encodeURIComponent(Base64.encode(fileUrl.value));
|
|
278567
278234
|
}
|
|
278568
278235
|
|
|
@@ -278571,7 +278238,7 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278571
278238
|
// 判断文件类型
|
|
278572
278239
|
const fileType = filePath.substring(filePath.lastIndexOf(".") + 1);
|
|
278573
278240
|
isPicture.value = fileType === "jpg" || fileType === "png" || fileType === "jpeg";
|
|
278574
|
-
isDocx.value = fileType === "docx";
|
|
278241
|
+
isDocx.value = fileType === "docx" || fileType === 'doc';
|
|
278575
278242
|
isPdf.value = fileType === "pdf";
|
|
278576
278243
|
isExcel.value = fileType === "xlsx";
|
|
278577
278244
|
}
|
|
@@ -278621,18 +278288,91 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278621
278288
|
changeFile();
|
|
278622
278289
|
};
|
|
278623
278290
|
|
|
278624
|
-
|
|
278625
|
-
|
|
278291
|
+
function extractScaleNumber(str, tag) {
|
|
278292
|
+
// 匹配 scale(数字) 的模式,支持小数和负数
|
|
278293
|
+
let match;
|
|
278626
278294
|
|
|
278627
|
-
|
|
278295
|
+
if (tag == 1) {
|
|
278296
|
+
match = str.match(/scale\(([-+]?[0-9]*\.?[0-9]+)\)/);
|
|
278297
|
+
} else {
|
|
278298
|
+
match = str.match(/rotate\(([-+]?[0-9]*\.?[0-9]+deg)\)/);
|
|
278299
|
+
}
|
|
278628
278300
|
|
|
278629
|
-
|
|
278301
|
+
if (match && match[1]) {
|
|
278302
|
+
return parseFloat(match[1]);
|
|
278303
|
+
}
|
|
278630
278304
|
|
|
278631
|
-
|
|
278305
|
+
return null; // 如果没有匹配到则返回null
|
|
278306
|
+
}
|
|
278632
278307
|
|
|
278633
|
-
|
|
278308
|
+
function imgHandler(tag) {
|
|
278309
|
+
if (tag == 3) {
|
|
278310
|
+
let ind = fileList.value.length;
|
|
278311
|
+
fileList.value.forEach((item, index) => {
|
|
278312
|
+
if (item.value == selectFile.value) {
|
|
278313
|
+
ind = index;
|
|
278314
|
+
return;
|
|
278315
|
+
}
|
|
278316
|
+
});
|
|
278317
|
+
console.log(ind);
|
|
278318
|
+
downloadFile(`${window.location.origin}/jtrequest/download?uri=${fileList.value[ind].value}`, props.axios);
|
|
278319
|
+
return;
|
|
278320
|
+
}
|
|
278634
278321
|
|
|
278635
|
-
const
|
|
278322
|
+
const scale = extractScaleNumber(imgStyle.value['transform'], 1);
|
|
278323
|
+
const rotate = extractScaleNumber(imgStyle.value['transform'], 2);
|
|
278324
|
+
|
|
278325
|
+
switch (tag) {
|
|
278326
|
+
case 1:
|
|
278327
|
+
{
|
|
278328
|
+
if (scale >= 2) {
|
|
278329
|
+
imgStyle.value['transform'] = `scale(2) rotate(${rotate}deg)`;
|
|
278330
|
+
} else {
|
|
278331
|
+
imgStyle.value['transform'] = `scale(${scale + 0.1}) rotate(${rotate}deg)`;
|
|
278332
|
+
}
|
|
278333
|
+
|
|
278334
|
+
break;
|
|
278335
|
+
}
|
|
278336
|
+
|
|
278337
|
+
case 2:
|
|
278338
|
+
{
|
|
278339
|
+
if (scale <= 0.2) {
|
|
278340
|
+
imgStyle.value['transform'] = `scale(0.2) rotate(${rotate}deg)`;
|
|
278341
|
+
} else {
|
|
278342
|
+
imgStyle.value['transform'] = `scale(${scale - 0.1}) rotate(${rotate}deg)`;
|
|
278343
|
+
}
|
|
278344
|
+
|
|
278345
|
+
break;
|
|
278346
|
+
}
|
|
278347
|
+
|
|
278348
|
+
case 4:
|
|
278349
|
+
{
|
|
278350
|
+
if (rotate == 0) {
|
|
278351
|
+
imgStyle.value['transform'] = `scale(${scale}) rotate(270deg)`;
|
|
278352
|
+
} else {
|
|
278353
|
+
imgStyle.value['transform'] = `scale(${scale}) rotate(${rotate - 90}deg)`;
|
|
278354
|
+
}
|
|
278355
|
+
|
|
278356
|
+
break;
|
|
278357
|
+
}
|
|
278358
|
+
|
|
278359
|
+
case 5:
|
|
278360
|
+
{
|
|
278361
|
+
if (rotate == 360) {
|
|
278362
|
+
imgStyle.value['transform'] = `scale(${scale}) rotate(90deg)`;
|
|
278363
|
+
} else {
|
|
278364
|
+
imgStyle.value['transform'] = `scale(${scale}) rotate(${rotate + 90}deg)`;
|
|
278365
|
+
}
|
|
278366
|
+
|
|
278367
|
+
break;
|
|
278368
|
+
}
|
|
278369
|
+
}
|
|
278370
|
+
}
|
|
278371
|
+
|
|
278372
|
+
return (_ctx, _cache) => {
|
|
278373
|
+
const _component_el_option = ElOption;
|
|
278374
|
+
|
|
278375
|
+
const _component_el_select = ElSelect;
|
|
278636
278376
|
|
|
278637
278377
|
const _directive_loading = vLoading;
|
|
278638
278378
|
|
|
@@ -278642,23 +278382,19 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278642
278382
|
width: `${(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(width) - 100}px`,
|
|
278643
278383
|
height: `${(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(height)}px`
|
|
278644
278384
|
})
|
|
278645
|
-
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", FileViewvue_type_script_setup_true_lang_js_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.
|
|
278646
|
-
|
|
278647
|
-
|
|
278648
|
-
|
|
278649
|
-
|
|
278650
|
-
|
|
278651
|
-
}
|
|
278652
|
-
}, {
|
|
278653
|
-
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(_component_ArrowLeft)]),
|
|
278654
|
-
_: 1
|
|
278655
|
-
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(_component_el_select, {
|
|
278385
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", FileViewvue_type_script_setup_true_lang_js_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278386
|
+
class: "arrow-box"
|
|
278387
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278388
|
+
class: "jtIcon icondirection-left",
|
|
278389
|
+
onClick: afterFile
|
|
278390
|
+
})]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(_component_el_select, {
|
|
278656
278391
|
modelValue: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(selectFile),
|
|
278657
278392
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (0,external_commonjs_vue_commonjs2_vue_root_Vue_.isRef)(selectFile) ? selectFile.value = $event : selectFile = $event),
|
|
278658
278393
|
placeholder: "暂无文件",
|
|
278659
278394
|
onChange: changeFile,
|
|
278660
278395
|
style: {
|
|
278661
|
-
"width": "300px"
|
|
278396
|
+
"width": "300px",
|
|
278397
|
+
"margin": "0 20px"
|
|
278662
278398
|
}
|
|
278663
278399
|
}, {
|
|
278664
278400
|
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(fileList), item => {
|
|
@@ -278668,28 +278404,38 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278668
278404
|
}, null, 8, ["label", "value"]);
|
|
278669
278405
|
}), 256))]),
|
|
278670
278406
|
_: 1
|
|
278671
|
-
}, 8, ["modelValue"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.
|
|
278672
|
-
|
|
278673
|
-
|
|
278674
|
-
|
|
278675
|
-
|
|
278676
|
-
|
|
278677
|
-
|
|
278678
|
-
|
|
278679
|
-
|
|
278680
|
-
|
|
278681
|
-
|
|
278407
|
+
}, 8, ["modelValue"]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
278408
|
+
class: "arrow-box"
|
|
278409
|
+
}, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278410
|
+
class: "jtIcon icondirection-right",
|
|
278411
|
+
onClick: afterFile
|
|
278412
|
+
})]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isPicture) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", FileViewvue_type_script_setup_true_lang_js_hoisted_2, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278413
|
+
class: "jtIcon iconjia1",
|
|
278414
|
+
title: "放大",
|
|
278415
|
+
onClick: _cache[1] || (_cache[1] = $event => imgHandler(1))
|
|
278416
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278417
|
+
class: "jtIcon iconjianshao",
|
|
278418
|
+
title: "缩小",
|
|
278419
|
+
onClick: _cache[2] || (_cache[2] = $event => imgHandler(2))
|
|
278420
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278421
|
+
class: "jtIcon iconxiazai2",
|
|
278422
|
+
title: "下载",
|
|
278423
|
+
onClick: _cache[3] || (_cache[3] = $event => imgHandler(3))
|
|
278424
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278425
|
+
class: "jtIcon iconxuanzhuan-2",
|
|
278426
|
+
title: "左旋转",
|
|
278427
|
+
onClick: _cache[4] || (_cache[4] = $event => imgHandler(4))
|
|
278428
|
+
}), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
278429
|
+
class: "jtIcon iconxuanzhuan-1",
|
|
278430
|
+
title: "右旋转",
|
|
278431
|
+
onClick: _cache[5] || (_cache[5] = $event => imgHandler(5))
|
|
278432
|
+
})])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("", true)]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withDirectives)(((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", FileViewvue_type_script_setup_true_lang_js_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isPicture) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("img", {
|
|
278682
278433
|
key: 0,
|
|
278683
|
-
|
|
278684
|
-
|
|
278434
|
+
class: "preview-img",
|
|
278435
|
+
style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)(imgStyle.value),
|
|
278685
278436
|
src: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(fileUrl),
|
|
278686
|
-
"
|
|
278687
|
-
|
|
278688
|
-
"min-scale": 0.2,
|
|
278689
|
-
"preview-src-list": (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(picList),
|
|
278690
|
-
fit: "fill",
|
|
278691
|
-
loading: "lazy"
|
|
278692
|
-
}, null, 8, ["src", "zoom-rate", "min-scale", "preview-src-list"])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("", true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isDocx) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createBlock)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)((lib_default())), {
|
|
278437
|
+
alt: ""
|
|
278438
|
+
}, null, 12, FileViewvue_type_script_setup_true_lang_js_hoisted_4)) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isDocx) ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createBlock)((0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)((lib_default())), {
|
|
278693
278439
|
key: 1,
|
|
278694
278440
|
src: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(fileUrl),
|
|
278695
278441
|
onRendered: rendered,
|
|
@@ -278719,17 +278465,17 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278719
278465
|
"height": "98%",
|
|
278720
278466
|
"border": "0"
|
|
278721
278467
|
}
|
|
278722
|
-
}, null, 8,
|
|
278468
|
+
}, null, 8, FileViewvue_type_script_setup_true_lang_js_hoisted_5))])), [[_directive_loading, fileLoading.value]])], 4);
|
|
278723
278469
|
};
|
|
278724
278470
|
}
|
|
278725
278471
|
|
|
278726
278472
|
});
|
|
278727
278473
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/FileView.vue?vue&type=script&setup=true&lang=js
|
|
278728
278474
|
/* unplugin-vue-components disabled */
|
|
278729
|
-
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/FileView.vue?vue&type=style&index=0&id=
|
|
278475
|
+
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/FileView.vue?vue&type=style&index=0&id=9bec2f9c&scoped=true&lang=scss
|
|
278730
278476
|
/* unplugin-vue-components disabled */// extracted by mini-css-extract-plugin
|
|
278731
278477
|
|
|
278732
|
-
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/FileView.vue?vue&type=style&index=0&id=
|
|
278478
|
+
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/FileView.vue?vue&type=style&index=0&id=9bec2f9c&scoped=true&lang=scss
|
|
278733
278479
|
/* unplugin-vue-components disabled */
|
|
278734
278480
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/FileView.vue
|
|
278735
278481
|
/* unplugin-vue-components disabled */
|
|
@@ -278738,7 +278484,7 @@ const FileViewvue_type_script_setup_true_lang_js_hoisted_3 = ["src"];
|
|
|
278738
278484
|
;
|
|
278739
278485
|
|
|
278740
278486
|
|
|
278741
|
-
const FileView_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(FileViewvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-
|
|
278487
|
+
const FileView_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(FileViewvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-9bec2f9c"]])
|
|
278742
278488
|
|
|
278743
278489
|
/* harmony default export */ var FileView = (FileView_exports_);
|
|
278744
278490
|
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/jtbuild/index.vue?vue&type=template&id=2b13b804&scoped=true
|
|
@@ -279407,465 +279153,8 @@ const sshDeployvue_type_script_setup_true_lang_js_hoisted_12 = {
|
|
|
279407
279153
|
const sshDeploy_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(sshDeployvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-03830466"]])
|
|
279408
279154
|
|
|
279409
279155
|
/* harmony default export */ var sshDeploy = (sshDeploy_exports_);
|
|
279410
|
-
;// CONCATENATED MODULE: ./
|
|
279411
|
-
|
|
279412
|
-
|
|
279413
|
-
|
|
279414
|
-
//获取本地存储
|
|
279415
|
-
|
|
279416
|
-
function getStorage(type, key) {
|
|
279417
|
-
if (type == 'local') {
|
|
279418
|
-
return localStorage.getItem(key);
|
|
279419
|
-
} else if (type == 'session') {
|
|
279420
|
-
return sessionStorage.getItem(key);
|
|
279421
|
-
}
|
|
279422
|
-
}
|
|
279423
|
-
function parseJson(data) {
|
|
279424
|
-
if (!data) {
|
|
279425
|
-
return {};
|
|
279426
|
-
}
|
|
279427
|
-
|
|
279428
|
-
if (typeof data !== 'string') {
|
|
279429
|
-
return data;
|
|
279430
|
-
}
|
|
279431
|
-
|
|
279432
|
-
let obj = {};
|
|
279433
|
-
|
|
279434
|
-
try {
|
|
279435
|
-
obj = JSON.parse(data);
|
|
279436
|
-
obj = obj ? obj : {};
|
|
279437
|
-
} catch (e) {}
|
|
279438
|
-
|
|
279439
|
-
return obj;
|
|
279440
|
-
}
|
|
279441
|
-
function getUrl2(key) {
|
|
279442
|
-
let _key = key;
|
|
279443
|
-
let path = "";
|
|
279444
|
-
|
|
279445
|
-
if (/\//.test(key)) {
|
|
279446
|
-
let strs = key.split("/");
|
|
279447
|
-
key = strs[0];
|
|
279448
|
-
path = strs[1];
|
|
279449
|
-
}
|
|
279450
|
-
|
|
279451
|
-
let obj = parseJson(localStorage.getItem("activeMenu"));
|
|
279452
|
-
let params = obj.params;
|
|
279453
|
-
|
|
279454
|
-
if (!params || !params[key]) {
|
|
279455
|
-
return _key;
|
|
279456
|
-
}
|
|
279457
|
-
|
|
279458
|
-
return params[key] + path;
|
|
279459
|
-
}
|
|
279460
|
-
const getUrl = () => {
|
|
279461
|
-
try {
|
|
279462
|
-
const root = JSON.parse(getStorage('local', 'activeMenu'));
|
|
279463
|
-
return root.params || {};
|
|
279464
|
-
} catch (_) {
|
|
279465
|
-
return {};
|
|
279466
|
-
}
|
|
279467
|
-
}; //字符串转boolean
|
|
279468
|
-
|
|
279469
|
-
function stringToBoolean(v) {
|
|
279470
|
-
v = v == 'false' ? 0 : v;
|
|
279471
|
-
v = v == 'true' ? 1 : v;
|
|
279472
|
-
return Boolean(v);
|
|
279473
|
-
} //得到JSON对象
|
|
279474
|
-
|
|
279475
|
-
function getJson(val) {
|
|
279476
|
-
return typeof val === 'string' ? JSON.parse(val) : val;
|
|
279477
|
-
} //生成uuid
|
|
279478
|
-
|
|
279479
|
-
function uuid() {
|
|
279480
|
-
var s = [];
|
|
279481
|
-
var hexDigits = "0123456789abcdef";
|
|
279482
|
-
|
|
279483
|
-
for (var i = 0; i < 32; i++) {
|
|
279484
|
-
s[i] = hexDigits.substr(Math.floor(Math.random() * 0x10), 1);
|
|
279485
|
-
}
|
|
279486
|
-
|
|
279487
|
-
s[14] = "4"; // bits 12-15 of the time_hi_and_version field to 0010
|
|
279488
|
-
|
|
279489
|
-
s[19] = hexDigits.substr(s[19] & 0x3 | 0x8, 1); // bits 6-7 of the clock_seq_hi_and_reserved to 01
|
|
279490
|
-
|
|
279491
|
-
var uuid = s.join("");
|
|
279492
|
-
return uuid;
|
|
279493
|
-
} //设置本地存储
|
|
279494
|
-
|
|
279495
|
-
function setStorage(type, key, value) {
|
|
279496
|
-
if (type == 'local') {
|
|
279497
|
-
if (value == null) {
|
|
279498
|
-
return localStorage.getItem(key) && localStorage.removeItem(key);
|
|
279499
|
-
} else {
|
|
279500
|
-
return localStorage.setItem(key, value);
|
|
279501
|
-
}
|
|
279502
|
-
} else if (type == 'session') {
|
|
279503
|
-
if (value == null) {
|
|
279504
|
-
return sessionStorage.getItem(key) && sessionStorage.removeItem(key);
|
|
279505
|
-
} else {
|
|
279506
|
-
return sessionStorage.setItem(key, value);
|
|
279507
|
-
}
|
|
279508
|
-
}
|
|
279509
|
-
} //获取文件名后缀
|
|
279510
|
-
|
|
279511
|
-
function extname(filename) {
|
|
279512
|
-
if (!filename || typeof filename != 'string') {
|
|
279513
|
-
return false;
|
|
279514
|
-
}
|
|
279515
|
-
|
|
279516
|
-
let a = filename.split('').reverse().join('');
|
|
279517
|
-
let b = a.substring(0, a.search(/\./)).split('').reverse().join('');
|
|
279518
|
-
return b;
|
|
279519
|
-
}
|
|
279520
|
-
function getLoading(target, msg) {
|
|
279521
|
-
let param = {
|
|
279522
|
-
fullscreen: false,
|
|
279523
|
-
target: target ? target : '',
|
|
279524
|
-
background: 'rgba(0, 0, 0, 0.65)'
|
|
279525
|
-
};
|
|
279526
|
-
|
|
279527
|
-
if (msg) {
|
|
279528
|
-
param.text = msg;
|
|
279529
|
-
}
|
|
279530
|
-
|
|
279531
|
-
return ElLoading.service(param);
|
|
279532
|
-
} //下载文件(不支持不同源的图片文件)
|
|
279533
|
-
|
|
279534
|
-
function download(src, name) {
|
|
279535
|
-
let tempa = document.createElement('a');
|
|
279536
|
-
tempa.href = src;
|
|
279537
|
-
tempa.download = name;
|
|
279538
|
-
document.body.append(tempa);
|
|
279539
|
-
tempa.click();
|
|
279540
|
-
tempa.remove();
|
|
279541
|
-
}
|
|
279542
|
-
const downloadFile = async (url, axios) => {
|
|
279543
|
-
const {
|
|
279544
|
-
data
|
|
279545
|
-
} = await axios({
|
|
279546
|
-
url,
|
|
279547
|
-
method: 'get',
|
|
279548
|
-
responseType: 'blob'
|
|
279549
|
-
});
|
|
279550
|
-
let name = getFileName(url);
|
|
279551
|
-
(0,FileSaver_min.saveAs)(data, name);
|
|
279552
|
-
};
|
|
279553
|
-
|
|
279554
|
-
function getFileName(url) {
|
|
279555
|
-
const urlAry = url.split('/');
|
|
279556
|
-
return urlAry[urlAry.length - 1];
|
|
279557
|
-
}
|
|
279558
|
-
|
|
279559
|
-
const fileLinkToStreamDownload = (url, fileName, type) => {
|
|
279560
|
-
// let reg = /^([hH][tT]{2}[pP]:\/\/|[hH][tT]{2}[pP][sS]:\/\/)(([A-Za-z0-9-~]+).)+([A-Za-z0-9-~\/])+$/;
|
|
279561
|
-
// if (!reg.test(url)) {
|
|
279562
|
-
// throw new Error("传入参数不合法,不是标准的文件链接");
|
|
279563
|
-
// } else {
|
|
279564
|
-
// let xhr = new XMLHttpRequest();
|
|
279565
|
-
// xhr.open('get', url, true);
|
|
279566
|
-
// xhr.setRequestHeader('Content-Type', `application/${type}`);
|
|
279567
|
-
// xhr.responseType = "blob";
|
|
279568
|
-
// xhr.onload = function () {
|
|
279569
|
-
// if (this.status == 200) {
|
|
279570
|
-
// //接受二进制文件流
|
|
279571
|
-
// console.log(this)
|
|
279572
|
-
// var blob = this.response;
|
|
279573
|
-
// const blobUrl = window.URL.createObjectURL(blob);
|
|
279574
|
-
// // 这里的文件名根据实际情况从响应头或者url里获取
|
|
279575
|
-
// const a = document.createElement('a');
|
|
279576
|
-
// a.href = blobUrl;
|
|
279577
|
-
// a.download = fileName;
|
|
279578
|
-
// a.click();
|
|
279579
|
-
// window.URL.revokeObjectURL(blobUrl);
|
|
279580
|
-
// }
|
|
279581
|
-
// }
|
|
279582
|
-
// xhr.send();
|
|
279583
|
-
// }
|
|
279584
|
-
let xhr = new XMLHttpRequest();
|
|
279585
|
-
xhr.open('get', url, true);
|
|
279586
|
-
|
|
279587
|
-
if (type) {
|
|
279588
|
-
xhr.setRequestHeader('Content-Type', `application/${type}`);
|
|
279589
|
-
}
|
|
279590
|
-
|
|
279591
|
-
xhr.responseType = "blob";
|
|
279592
|
-
|
|
279593
|
-
xhr.onload = function () {
|
|
279594
|
-
if (this.status == 200) {
|
|
279595
|
-
//接受二进制文件流
|
|
279596
|
-
console.log(this);
|
|
279597
|
-
var blob = this.response;
|
|
279598
|
-
const blobUrl = window.URL.createObjectURL(blob); // 这里的文件名根据实际情况从响应头或者url里获取
|
|
279599
|
-
|
|
279600
|
-
const a = document.createElement('a');
|
|
279601
|
-
a.href = blobUrl;
|
|
279602
|
-
a.download = fileName;
|
|
279603
|
-
a.click();
|
|
279604
|
-
window.URL.revokeObjectURL(blobUrl);
|
|
279605
|
-
}
|
|
279606
|
-
};
|
|
279607
|
-
|
|
279608
|
-
xhr.send();
|
|
279609
|
-
}; // 函数防抖
|
|
279610
|
-
|
|
279611
|
-
function utils_debounce(fn, delay) {
|
|
279612
|
-
var timer = null;
|
|
279613
|
-
delay = delay || 200;
|
|
279614
|
-
return function () {
|
|
279615
|
-
var args = arguments;
|
|
279616
|
-
var that = this;
|
|
279617
|
-
clearTimeout(timer);
|
|
279618
|
-
timer = setTimeout(function () {
|
|
279619
|
-
fn.apply(that, args);
|
|
279620
|
-
}, delay);
|
|
279621
|
-
};
|
|
279622
|
-
}
|
|
279623
|
-
/****
|
|
279624
|
-
* 四舍六入 保留n为有效数字
|
|
279625
|
-
*/
|
|
279626
|
-
|
|
279627
|
-
function keepSignificantFigures(number, digit) {
|
|
279628
|
-
number = number.toString();
|
|
279629
|
-
let tempArr = [...number];
|
|
279630
|
-
let res = null;
|
|
279631
|
-
|
|
279632
|
-
if (tempArr.length <= digit) {
|
|
279633
|
-
res = (number - 0).toPrecision(digit);
|
|
279634
|
-
} else {
|
|
279635
|
-
let index = digit + 1;
|
|
279636
|
-
let tarindex = digit;
|
|
279637
|
-
let subindex = digit;
|
|
279638
|
-
let tempStr = number.substring(0, index);
|
|
279639
|
-
let tarnum1 = null;
|
|
279640
|
-
let tarnum2 = null;
|
|
279641
|
-
|
|
279642
|
-
if (tempStr.indexOf('.') != -1) {
|
|
279643
|
-
//有小数点
|
|
279644
|
-
//判断最后一位是否是小数
|
|
279645
|
-
if (tempStr[tempStr.length - 1] == '.') {
|
|
279646
|
-
tarnum1 = tempArr[index + 1];
|
|
279647
|
-
subindex = index + 1;
|
|
279648
|
-
tarnum2 = tempArr[index - 2];
|
|
279649
|
-
tarindex = index - 2; //判断倒数第二位位是否是小数
|
|
279650
|
-
} else if (tempStr[tempStr.length - 2] == '.') {
|
|
279651
|
-
tarnum1 = tempArr[index];
|
|
279652
|
-
subindex = index;
|
|
279653
|
-
tarnum2 = tempArr[index - 1];
|
|
279654
|
-
tarindex = index - 1;
|
|
279655
|
-
} else {
|
|
279656
|
-
tarnum1 = tempArr[index];
|
|
279657
|
-
subindex = index;
|
|
279658
|
-
tarnum2 = tempArr[index - 1];
|
|
279659
|
-
tarindex = index - 1;
|
|
279660
|
-
}
|
|
279661
|
-
} else {
|
|
279662
|
-
//无小数
|
|
279663
|
-
tarnum1 = tempArr[index];
|
|
279664
|
-
subindex = index;
|
|
279665
|
-
tarnum2 = tempArr[index - 1];
|
|
279666
|
-
tarindex = index - 1;
|
|
279667
|
-
}
|
|
279668
|
-
|
|
279669
|
-
if (tarnum2 % 2 == 0) {
|
|
279670
|
-
//是否为偶数
|
|
279671
|
-
if (tarnum1 > 6) {
|
|
279672
|
-
tempArr[tarindex] = tarnum2 - 0 + 1;
|
|
279673
|
-
}
|
|
279674
|
-
}
|
|
279675
|
-
|
|
279676
|
-
res = tempArr.join("").substring(0, subindex);
|
|
279677
|
-
}
|
|
279678
|
-
|
|
279679
|
-
return res;
|
|
279680
|
-
} //字符串转number
|
|
279681
|
-
|
|
279682
|
-
function isInput(val) {
|
|
279683
|
-
if (val == undefined || val == null || val == "") {
|
|
279684
|
-
return 0;
|
|
279685
|
-
} else {
|
|
279686
|
-
return Number(val);
|
|
279687
|
-
}
|
|
279688
|
-
} // 格式化为float
|
|
279689
|
-
|
|
279690
|
-
function fomatFloat(num, n) {
|
|
279691
|
-
var f = parseFloat(num);
|
|
279692
|
-
|
|
279693
|
-
if (isNaN(f)) {
|
|
279694
|
-
return false;
|
|
279695
|
-
}
|
|
279696
|
-
|
|
279697
|
-
f = Math.round(num * Math.pow(10, n)) / Math.pow(10, n); // n 幂
|
|
279698
|
-
|
|
279699
|
-
var s = f.toString();
|
|
279700
|
-
var rs = s.indexOf('.'); //判定如果是整数,增加小数点再补0
|
|
279701
|
-
|
|
279702
|
-
if (rs < 0 && n > 0) {
|
|
279703
|
-
rs = s.length;
|
|
279704
|
-
s += '.';
|
|
279705
|
-
}
|
|
279706
|
-
|
|
279707
|
-
while (s.length <= rs + n) {
|
|
279708
|
-
s += '0';
|
|
279709
|
-
}
|
|
279710
|
-
|
|
279711
|
-
return s;
|
|
279712
|
-
} // 检查对象或纯数组中属性值是否有为空的情况
|
|
279713
|
-
|
|
279714
|
-
function isRepeatObj(item) {
|
|
279715
|
-
console.log(item, 'kkkk');
|
|
279716
|
-
|
|
279717
|
-
for (let index in item) {
|
|
279718
|
-
if (item[index] === '') {
|
|
279719
|
-
return false;
|
|
279720
|
-
}
|
|
279721
|
-
}
|
|
279722
|
-
|
|
279723
|
-
return true;
|
|
279724
|
-
} // 检查对象数组中属性值是否有为空的情况
|
|
279725
|
-
|
|
279726
|
-
function isRepeatArr(item) {
|
|
279727
|
-
for (let index of item) {
|
|
279728
|
-
for (let ind in index) {
|
|
279729
|
-
if (index[ind] === '') {
|
|
279730
|
-
return false;
|
|
279731
|
-
}
|
|
279732
|
-
}
|
|
279733
|
-
}
|
|
279734
|
-
|
|
279735
|
-
return true;
|
|
279736
|
-
} // 深拷贝
|
|
279737
|
-
|
|
279738
|
-
function deepCopy(obj1) {
|
|
279739
|
-
var obj2 = Array.isArray(obj1) ? [] : {};
|
|
279740
|
-
|
|
279741
|
-
if (obj1 && typeof obj1 === "object") {
|
|
279742
|
-
for (let i in obj1) {
|
|
279743
|
-
if (obj1.i) {
|
|
279744
|
-
// 如果子属性为引用数据类型,递归复制
|
|
279745
|
-
if (obj1[i] && typeof obj1[i] === "object") {
|
|
279746
|
-
obj2[i] = deepCopy(obj1[i]);
|
|
279747
|
-
} else {
|
|
279748
|
-
// 如果是基本数据类型,只是简单的复制
|
|
279749
|
-
obj2[i] = obj1[i];
|
|
279750
|
-
}
|
|
279751
|
-
}
|
|
279752
|
-
}
|
|
279753
|
-
}
|
|
279754
|
-
|
|
279755
|
-
return obj2;
|
|
279756
|
-
}
|
|
279757
|
-
/**
|
|
279758
|
-
* 得到有效数字
|
|
279759
|
-
*/
|
|
279760
|
-
|
|
279761
|
-
function getEffeNum(num, digit) {
|
|
279762
|
-
if (!isNumber(num)) {
|
|
279763
|
-
return num;
|
|
279764
|
-
}
|
|
279765
|
-
|
|
279766
|
-
let _num = num;
|
|
279767
|
-
|
|
279768
|
-
if (Math.abs(_num) >= Math.pow(10, digit) / 10) {
|
|
279769
|
-
let _numlen = parseInt(_num).toString().replaceAll(/^-/g, "").length;
|
|
279770
|
-
|
|
279771
|
-
let _len = Math.pow(10, _numlen - digit);
|
|
279772
|
-
|
|
279773
|
-
_num = parseInt(parseFloat(_num / _len / 10).toFixed(1) * _len * 10).toString();
|
|
279774
|
-
} else if (-1 <= _num && _num <= 1) {
|
|
279775
|
-
_num = parseFloat(_num).toFixed(digit);
|
|
279776
|
-
|
|
279777
|
-
if (_num == 1 || _num == -1) {
|
|
279778
|
-
_num = parseFloat(_num).toPrecision(digit);
|
|
279779
|
-
}
|
|
279780
|
-
} else {
|
|
279781
|
-
_num = parseFloat(_num).toPrecision(digit);
|
|
279782
|
-
}
|
|
279783
|
-
|
|
279784
|
-
return _num;
|
|
279785
|
-
}
|
|
279786
|
-
function getMaxMin(datas, key) {
|
|
279787
|
-
let min = 999999999999;
|
|
279788
|
-
let max = -999999999999;
|
|
279789
|
-
datas.forEach(item => {
|
|
279790
|
-
let data = key ? item[key] : item;
|
|
279791
|
-
|
|
279792
|
-
if (data == null || data == undefined) {
|
|
279793
|
-
return;
|
|
279794
|
-
}
|
|
279795
|
-
|
|
279796
|
-
let num = Number(data);
|
|
279797
|
-
min = min > num ? num : min;
|
|
279798
|
-
max = max < num ? num : max;
|
|
279799
|
-
});
|
|
279800
|
-
return {
|
|
279801
|
-
max: max,
|
|
279802
|
-
min: min
|
|
279803
|
-
};
|
|
279804
|
-
}
|
|
279805
|
-
function convertMaxMin(data) {
|
|
279806
|
-
let ymin = data.min ? Number(data.min) : 0;
|
|
279807
|
-
let ymax = data.max ? Number(data.max) : 0;
|
|
279808
|
-
let min = Math.floor(ymin * 100 - 1);
|
|
279809
|
-
let gw = min % 10;
|
|
279810
|
-
|
|
279811
|
-
if (gw > 5) {
|
|
279812
|
-
min = min - gw - 10;
|
|
279813
|
-
} else {
|
|
279814
|
-
min = min - gw - 5;
|
|
279815
|
-
}
|
|
279816
|
-
|
|
279817
|
-
ymin = (min / 100).toFixed(2);
|
|
279818
|
-
let max = Math.floor(ymax * 100 + 1);
|
|
279819
|
-
gw = max % 10;
|
|
279820
|
-
|
|
279821
|
-
if (gw > 5) {
|
|
279822
|
-
max = max - gw + 10;
|
|
279823
|
-
} else {
|
|
279824
|
-
max = max - gw + 5;
|
|
279825
|
-
}
|
|
279826
|
-
|
|
279827
|
-
ymax = (max / 100).toFixed(2);
|
|
279828
|
-
return {
|
|
279829
|
-
max: ymax,
|
|
279830
|
-
min: ymin
|
|
279831
|
-
};
|
|
279832
|
-
}
|
|
279833
|
-
function getDate(tm) {
|
|
279834
|
-
if (tm instanceof Date) {
|
|
279835
|
-
return tm;
|
|
279836
|
-
}
|
|
279837
|
-
|
|
279838
|
-
return new Date(tm.replace(/-/g, '/'));
|
|
279839
|
-
}
|
|
279840
|
-
function utils_formatDate(date, format) {
|
|
279841
|
-
let year = date.getFullYear();
|
|
279842
|
-
let month = (date.getMonth() + 1 < 10 ? '0' : '') + (date.getMonth() + 1);
|
|
279843
|
-
let day = (date.getDate() < 10 ? '0' : '') + date.getDate();
|
|
279844
|
-
let hour = (date.getHours() < 10 ? '0' : '') + date.getHours();
|
|
279845
|
-
let mi = (date.getMinutes() < 10 ? '0' : '') + date.getMinutes();
|
|
279846
|
-
let second = (date.getSeconds() < 10 ? '0' : '') + date.getSeconds();
|
|
279847
|
-
let formatFields = {
|
|
279848
|
-
yyyy: '{{year}}',
|
|
279849
|
-
MM: '{{month}}',
|
|
279850
|
-
dd: '{{day}}',
|
|
279851
|
-
HH: '{{hour}}',
|
|
279852
|
-
mm: '{{mi}}',
|
|
279853
|
-
ss: '{{second}}'
|
|
279854
|
-
};
|
|
279855
|
-
|
|
279856
|
-
for (let field of Object.keys(formatFields)) {
|
|
279857
|
-
format = format.replaceAll(field, formatFields[field]);
|
|
279858
|
-
}
|
|
279156
|
+
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/icon/style/css.mjs
|
|
279859
279157
|
|
|
279860
|
-
return replace(format, {
|
|
279861
|
-
year: year,
|
|
279862
|
-
month: month,
|
|
279863
|
-
day: day,
|
|
279864
|
-
hour: hour,
|
|
279865
|
-
mi: mi,
|
|
279866
|
-
second: second
|
|
279867
|
-
});
|
|
279868
|
-
}
|
|
279869
279158
|
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/jtbuild/jarBuild.vue?vue&type=script&setup=true&lang=js
|
|
279870
279159
|
/* unplugin-vue-components disabled */
|
|
279871
279160
|
|
|
@@ -299005,7 +298294,7 @@ const jtbuild_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(jtbuildvue
|
|
|
299005
298294
|
|
|
299006
298295
|
|
|
299007
298296
|
|
|
299008
|
-
const jt_manager_tree_contentvue_type_script_setup_true_lang_js_withScopeId = n => (_pushScopeId("data-v-
|
|
298297
|
+
const jt_manager_tree_contentvue_type_script_setup_true_lang_js_withScopeId = n => (_pushScopeId("data-v-f3523c74"), n = n(), _popScopeId(), n);
|
|
299009
298298
|
|
|
299010
298299
|
const jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_1 = {
|
|
299011
298300
|
class: "jt-manager-tree-content"
|
|
@@ -299160,8 +298449,9 @@ const jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_7 = /*#_
|
|
|
299160
298449
|
}, null, 8, ["width", "height", "submit", "openPath", "closePath", "title", "logUrl"])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createCommentVNode)("", true)])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).oprtype === 'jt-file-view' ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(FileView, {
|
|
299161
298450
|
width: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).width || 700,
|
|
299162
298451
|
height: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).height || 1300,
|
|
298452
|
+
axios: __props.axios,
|
|
299163
298453
|
rowParams: rowParams
|
|
299164
|
-
}, null, 8, ["width", "height", "rowParams"])])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).oprtype === 'jt-build' ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_4, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(jtbuild, {
|
|
298454
|
+
}, null, 8, ["width", "height", "axios", "rowParams"])])) : (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).oprtype === 'jt-build' ? ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_4, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createVNode)(jtbuild, {
|
|
299165
298455
|
buildFun: buildFun.value,
|
|
299166
298456
|
width: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).width || 700,
|
|
299167
298457
|
height: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(form).height || 1300,
|
|
@@ -299219,10 +298509,10 @@ const jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_7 = /*#_
|
|
|
299219
298509
|
});
|
|
299220
298510
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue?vue&type=script&setup=true&lang=js
|
|
299221
298511
|
/* unplugin-vue-components disabled */
|
|
299222
|
-
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue?vue&type=style&index=0&id=
|
|
298512
|
+
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue?vue&type=style&index=0&id=f3523c74&lang=scss&scoped=true
|
|
299223
298513
|
/* unplugin-vue-components disabled */// extracted by mini-css-extract-plugin
|
|
299224
298514
|
|
|
299225
|
-
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue?vue&type=style&index=0&id=
|
|
298515
|
+
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue?vue&type=style&index=0&id=f3523c74&lang=scss&scoped=true
|
|
299226
298516
|
/* unplugin-vue-components disabled */
|
|
299227
298517
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-content.vue
|
|
299228
298518
|
/* unplugin-vue-components disabled */
|
|
@@ -299231,7 +298521,7 @@ const jt_manager_tree_contentvue_type_script_setup_true_lang_js_hoisted_7 = /*#_
|
|
|
299231
298521
|
;
|
|
299232
298522
|
|
|
299233
298523
|
|
|
299234
|
-
const jt_manager_tree_content_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(jt_manager_tree_contentvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-
|
|
298524
|
+
const jt_manager_tree_content_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(jt_manager_tree_contentvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-f3523c74"]])
|
|
299235
298525
|
|
|
299236
298526
|
/* harmony default export */ var jt_manager_tree_content = (jt_manager_tree_content_exports_);
|
|
299237
298527
|
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/jt-page-manager-tree-table/jt-manager-tree-modal.vue?vue&type=script&setup=true&lang=js
|
|
@@ -300736,6 +300026,7 @@ function MttPanelHook(props) {
|
|
|
300736
300026
|
|
|
300737
300027
|
formList.value.forEach(item => {
|
|
300738
300028
|
if (item.funcode === funcode) {
|
|
300029
|
+
console.log(item);
|
|
300739
300030
|
forms_item.value = item;
|
|
300740
300031
|
formsItemCopy.value = deepCopy(item);
|
|
300741
300032
|
const type = item.oprtype;
|
|
@@ -300793,7 +300084,7 @@ function MttPanelHook(props) {
|
|
|
300793
300084
|
}
|
|
300794
300085
|
|
|
300795
300086
|
if (forms_item.value?.sideBtn) {
|
|
300796
|
-
|
|
300087
|
+
operFunc[type.toLowerCase() + "_handler"](pageData, forms_item.value, 1);
|
|
300797
300088
|
} else {
|
|
300798
300089
|
operFunc[type.toLowerCase() + "_handler"](pageData, forms_item.value, activeRow.value.$level);
|
|
300799
300090
|
}
|
|
@@ -300914,7 +300205,9 @@ function MttPanelHook(props) {
|
|
|
300914
300205
|
customEvents,
|
|
300915
300206
|
loadListData,
|
|
300916
300207
|
customBtns,
|
|
300917
|
-
cellRenderMethods
|
|
300208
|
+
cellRenderMethods,
|
|
300209
|
+
loading,
|
|
300210
|
+
tooltipId
|
|
300918
300211
|
};
|
|
300919
300212
|
}
|
|
300920
300213
|
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/btn-render.vue?vue&type=script&setup=true&lang=js
|
|
@@ -301149,7 +300442,7 @@ const btn_render_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(btn_ren
|
|
|
301149
300442
|
|
|
301150
300443
|
|
|
301151
300444
|
|
|
301152
|
-
const mtt_panelvue_type_script_setup_true_lang_js_withScopeId = n => ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.pushScopeId)("data-v-
|
|
300445
|
+
const mtt_panelvue_type_script_setup_true_lang_js_withScopeId = n => ((0,external_commonjs_vue_commonjs2_vue_root_Vue_.pushScopeId)("data-v-330f6448"), n = n(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.popScopeId)(), n);
|
|
301153
300446
|
|
|
301154
300447
|
const mtt_panelvue_type_script_setup_true_lang_js_hoisted_1 = {
|
|
301155
300448
|
class: "mtt-panel-box"
|
|
@@ -301250,7 +300543,9 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301250
300543
|
loadListData,
|
|
301251
300544
|
handlerColClick,
|
|
301252
300545
|
customBtns,
|
|
301253
|
-
cellRenderMethods
|
|
300546
|
+
cellRenderMethods,
|
|
300547
|
+
loading,
|
|
300548
|
+
tooltipId
|
|
301254
300549
|
} = MttPanelHook(props);
|
|
301255
300550
|
expose({
|
|
301256
300551
|
cardClick,
|
|
@@ -301305,7 +300600,7 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301305
300600
|
class: "box-item",
|
|
301306
300601
|
effect: "dark",
|
|
301307
300602
|
content: item[(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(retjson).header[0].prop],
|
|
301308
|
-
visible: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isTooltip) &&
|
|
300603
|
+
visible: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isTooltip) && (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(tooltipId) === item.rowid,
|
|
301309
300604
|
placement: "top-start"
|
|
301310
300605
|
}, {
|
|
301311
300606
|
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", mtt_panelvue_type_script_setup_true_lang_js_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("span", {
|
|
@@ -301366,7 +300661,7 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301366
300661
|
class: "box-item",
|
|
301367
300662
|
effect: "dark",
|
|
301368
300663
|
content: item[(0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(retjson_2).header[0].prop],
|
|
301369
|
-
visible: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isTooltip) &&
|
|
300664
|
+
visible: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(isTooltip) && (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(tooltipId) === item.rowid,
|
|
301370
300665
|
placement: "top-start"
|
|
301371
300666
|
}, {
|
|
301372
300667
|
default: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.withCtx)(() => [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
|
|
@@ -301423,7 +300718,7 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301423
300718
|
retjson: item?.retjson_3,
|
|
301424
300719
|
DataArray: item?.tableData_3
|
|
301425
300720
|
}],
|
|
301426
|
-
loading:
|
|
300721
|
+
loading: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(loading),
|
|
301427
300722
|
cellRenderMethods: {
|
|
301428
300723
|
cellRenderMethods: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.unref)(cellRenderMethods)
|
|
301429
300724
|
},
|
|
@@ -301465,10 +300760,10 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301465
300760
|
});
|
|
301466
300761
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue?vue&type=script&setup=true&lang=js
|
|
301467
300762
|
/* unplugin-vue-components disabled */
|
|
301468
|
-
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue?vue&type=style&index=0&id=
|
|
300763
|
+
;// CONCATENATED MODULE: ./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[33].use[0]!./node_modules/unplugin/dist/webpack/loaders/transform.js??ruleSet[1].rules[34].use[0]!./node_modules/mini-css-extract-plugin/dist/loader.js??clonedRuleSet-22.use[0]!./node_modules/css-loader/dist/cjs.js??clonedRuleSet-22.use[1]!./node_modules/vue-loader/dist/stylePostLoader.js!./node_modules/postcss-loader/dist/cjs.js??clonedRuleSet-22.use[2]!./node_modules/sass-loader/dist/cjs.js??clonedRuleSet-22.use[3]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue?vue&type=style&index=0&id=330f6448&lang=scss&scoped=true
|
|
301469
300764
|
/* unplugin-vue-components disabled */// extracted by mini-css-extract-plugin
|
|
301470
300765
|
|
|
301471
|
-
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue?vue&type=style&index=0&id=
|
|
300766
|
+
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue?vue&type=style&index=0&id=330f6448&lang=scss&scoped=true
|
|
301472
300767
|
/* unplugin-vue-components disabled */
|
|
301473
300768
|
;// CONCATENATED MODULE: ./packages/manage-tree-table/components/mtt-panel/mtt-panel.vue
|
|
301474
300769
|
/* unplugin-vue-components disabled */
|
|
@@ -301477,7 +300772,7 @@ const mtt_panelvue_type_script_setup_true_lang_js_hoisted_19 = {
|
|
|
301477
300772
|
;
|
|
301478
300773
|
|
|
301479
300774
|
|
|
301480
|
-
const mtt_panel_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(mtt_panelvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-
|
|
300775
|
+
const mtt_panel_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(mtt_panelvue_type_script_setup_true_lang_js, [['__scopeId',"data-v-330f6448"]])
|
|
301481
300776
|
|
|
301482
300777
|
/* harmony default export */ var mtt_panel = (mtt_panel_exports_);
|
|
301483
300778
|
;// CONCATENATED MODULE: ./node_modules/element-plus/es/components/header/style/css.mjs
|