centaline-data-driven 1.4.62 → 1.4.64
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/package.json +2 -2
- package/src/centaline/dynamicDetail/src/dynamicPropertyDetailOFI.vue +10 -1
- package/src/centaline/dynamicDetail/src/dynamicPropertyDetailRET.vue +9 -0
- package/src/centaline/dynamicDetail/src/dynamicPropertySimpleDetailRET.vue +9 -0
- package/src/centaline/dynamicEditPictures/src/dynamicEditPictures.vue +109 -58
- package/src/centaline/dynamicFile/src/dynamicFile.vue +7 -0
- package/src/centaline/dynamicForm/src/dynamicForm.vue +9 -0
- package/src/centaline/dynamicSearchList/src/dynamicSearchList.vue +5 -0
- package/src/centaline/dynamicSearchList/src/dynamicSearchTable.vue +9 -0
- package/src/centaline/loader/src/ctl/File.js +1 -15
- package/src/centaline/loader/src/ctl/Router.js +3 -0
- package/src/centaline/loader/src/ctl/lib/Enum.js +5 -0
- package/src/main.js +4 -1
- package/wwwroot/static/centaline/centaline-data-driven.js +3 -12
- package/wwwroot/static/centaline/centaline-data-driven.js.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "centaline-data-driven",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.64",
|
|
4
4
|
"description": "ccai",
|
|
5
5
|
"author": "hjc <3226136347@qq.com>",
|
|
6
6
|
"private": false,
|
|
@@ -15,13 +15,13 @@
|
|
|
15
15
|
"axios": "^0.24.0",
|
|
16
16
|
"babel-polyfill": "^6.26.0",
|
|
17
17
|
"compression-webpack-plugin": "^2.0.0",
|
|
18
|
-
"cropperjs": "^1.5.13",
|
|
19
18
|
"element-ui": "^2.15.7",
|
|
20
19
|
"module": "^1.2.5",
|
|
21
20
|
"sass": "^1.34.0",
|
|
22
21
|
"save": "^2.4.0",
|
|
23
22
|
"v-viewer": "^1.6.4",
|
|
24
23
|
"vue": "2.5.17",
|
|
24
|
+
"vue-cropper": "^0.5.8",
|
|
25
25
|
"vue-ueditor-wrap": "^2.5.6",
|
|
26
26
|
"vuedraggable": "^2.24.3"
|
|
27
27
|
},
|
|
@@ -918,7 +918,16 @@ export default {
|
|
|
918
918
|
else if (field.isSearchPageInTab) {// 外部框架tab页打开
|
|
919
919
|
submitData = field.getActionPara(submitData).para;
|
|
920
920
|
self.$common.getDataDrivenOpts().handler.openTabSearch(field, submitData);
|
|
921
|
-
}
|
|
921
|
+
}
|
|
922
|
+
else if (field.isUrlInSystemTab) {//外部框架tab页打开URl
|
|
923
|
+
submitData = field.getActionPara(submitData).para;
|
|
924
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
925
|
+
let urlTab = field.action + query;
|
|
926
|
+
if(field.action.indexOf('?')>-1 && query.indexOf('?')>-1){
|
|
927
|
+
urlTab = field.action + '&' +query.substr(1, query.length);
|
|
928
|
+
}
|
|
929
|
+
self.$common.getDataDrivenOpts().handler.openTabUrl(urlTab,field.pageTitle||field.label);
|
|
930
|
+
}
|
|
922
931
|
else if (field.isBrowserNewTab) {// 浏览器打开
|
|
923
932
|
submitData = field.getActionPara(submitData).para;
|
|
924
933
|
let query = self.$common.objectToQueryStr(submitData);
|
|
@@ -928,6 +928,15 @@ export default {
|
|
|
928
928
|
submitData = field.getActionPara(submitData).para;
|
|
929
929
|
self.$common.getDataDrivenOpts().handler.openTabSearch(field, submitData);
|
|
930
930
|
}
|
|
931
|
+
else if (field.isUrlInSystemTab) {//外部框架tab页打开URl
|
|
932
|
+
submitData = field.getActionPara(submitData).para;
|
|
933
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
934
|
+
let urlTab = field.action + query;
|
|
935
|
+
if(field.action.indexOf('?')>-1 && query.indexOf('?')>-1){
|
|
936
|
+
urlTab = field.action + '&' +query.substr(1, query.length);
|
|
937
|
+
}
|
|
938
|
+
self.$common.getDataDrivenOpts().handler.openTabUrl(urlTab,field.pageTitle||field.label);
|
|
939
|
+
}
|
|
931
940
|
else if (field.isBrowserNewTab) {// 浏览器打开
|
|
932
941
|
submitData = field.getActionPara(submitData).para;
|
|
933
942
|
let query = self.$common.objectToQueryStr(submitData);
|
|
@@ -438,6 +438,15 @@
|
|
|
438
438
|
submitData = field.getActionPara(submitData).para;
|
|
439
439
|
self.$common.getDataDrivenOpts().handler.openTabSearch(field, submitData);
|
|
440
440
|
}
|
|
441
|
+
else if (field.isUrlInSystemTab) {//外部框架tab页打开URl
|
|
442
|
+
submitData = field.getActionPara(submitData).para;
|
|
443
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
444
|
+
let urlTab = field.action + query;
|
|
445
|
+
if(field.action.indexOf('?')>-1 && query.indexOf('?')>-1){
|
|
446
|
+
urlTab = field.action + '&' +query.substr(1, query.length);
|
|
447
|
+
}
|
|
448
|
+
self.$common.getDataDrivenOpts().handler.openTabUrl(urlTab,field.pageTitle||field.label);
|
|
449
|
+
}
|
|
441
450
|
else if (field.isBrowserNewTab) {// 浏览器打开
|
|
442
451
|
submitData = field.getActionPara(submitData).para;
|
|
443
452
|
let query = self.$common.objectToQueryStr(submitData);
|
|
@@ -1,7 +1,31 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class="picedit-modal" style="width:100%; height:100%;background-color: #1e1e1e">
|
|
3
3
|
<div class="picedit-stage">
|
|
4
|
-
<
|
|
4
|
+
<div style="width:100%; height:100%;" v-if="croppShow">
|
|
5
|
+
<vue-cropper ref="cropper"
|
|
6
|
+
:img="options.img"
|
|
7
|
+
:output-size="options.size"
|
|
8
|
+
:output-type="options.outputType"
|
|
9
|
+
:info="options.info"
|
|
10
|
+
:full="options.full"
|
|
11
|
+
:canScale="options.canScale"
|
|
12
|
+
:can-move="options.canMove"
|
|
13
|
+
:can-move-box="options.canMoveBox"
|
|
14
|
+
:fixed="options.fixed"
|
|
15
|
+
:fixed-box="options.fixedBox"
|
|
16
|
+
:original="options.original"
|
|
17
|
+
:auto-crop="options.autoCrop"
|
|
18
|
+
:auto-crop-width="options.autoCropWidth"
|
|
19
|
+
:auto-crop-height="options.autoCropHeight"
|
|
20
|
+
:center-box="options.centerBox"
|
|
21
|
+
:high="options.high"
|
|
22
|
+
:info-true="options.infoTrue"
|
|
23
|
+
:max-img-size="options.maxImageSize"
|
|
24
|
+
:enlarge="options.enlarge"
|
|
25
|
+
:mode="options.mode"
|
|
26
|
+
:maxImgSize="options.maxImgSize" />
|
|
27
|
+
</div>
|
|
28
|
+
<canvas v-else id="drawCanvas" ref="canvas" style="position:absolute;"></canvas>
|
|
5
29
|
</div>
|
|
6
30
|
<div class="picedit-Original" v-if="flagOriginal">
|
|
7
31
|
<el-row>
|
|
@@ -21,7 +45,7 @@
|
|
|
21
45
|
</a>
|
|
22
46
|
</div>
|
|
23
47
|
</div>
|
|
24
|
-
<div class="stream-total-tips"
|
|
48
|
+
<div class="stream-total-tips" v-if="progressFlag">
|
|
25
49
|
<el-progress type="circle"
|
|
26
50
|
:percentage="typeof loadProgress !== 'undefined' && loadProgress !== null ? loadProgress : 0.00"
|
|
27
51
|
:width="150" :height="150" class="file-cirle"></el-progress>
|
|
@@ -32,12 +56,11 @@
|
|
|
32
56
|
<script>
|
|
33
57
|
import dynamicElement from "../../mixins/dynamicElement";
|
|
34
58
|
import { upload, uploadByPieces } from "../../loader/src/ctl/SliceUpload";
|
|
35
|
-
import
|
|
36
|
-
import Cropper from 'cropperjs'
|
|
37
|
-
import 'cropperjs/dist/cropper.min.css'
|
|
59
|
+
import { VueCropper } from "vue-cropper";
|
|
38
60
|
export default {
|
|
39
61
|
name: "ct-editpictures",
|
|
40
62
|
mixins: [dynamicElement],
|
|
63
|
+
components: { VueCropper },
|
|
41
64
|
props: {
|
|
42
65
|
file: Object,
|
|
43
66
|
api: String,
|
|
@@ -49,7 +72,6 @@
|
|
|
49
72
|
flagOriginal: false,
|
|
50
73
|
progressFlag: false,
|
|
51
74
|
loadProgress: 0,
|
|
52
|
-
cropper: null,
|
|
53
75
|
croppShow: false,
|
|
54
76
|
canvas: Object,
|
|
55
77
|
ctx: Object,
|
|
@@ -60,7 +82,7 @@
|
|
|
60
82
|
isActive: false,
|
|
61
83
|
bodywidth: 0,
|
|
62
84
|
bodyheight: 0,
|
|
63
|
-
scale:1,
|
|
85
|
+
scale: 1,
|
|
64
86
|
tx: 0,
|
|
65
87
|
ty: 0,
|
|
66
88
|
tl: 0,
|
|
@@ -71,23 +93,24 @@
|
|
|
71
93
|
nt: 0,
|
|
72
94
|
ratio: 0,
|
|
73
95
|
cropBoxResizable: false,
|
|
74
|
-
bntindex
|
|
96
|
+
bntindex: -1,
|
|
97
|
+
canvasImg:'',
|
|
75
98
|
bntList: [
|
|
76
99
|
{
|
|
77
100
|
name: "左旋转",
|
|
78
101
|
ico: "el-icon-refresh-left",
|
|
79
|
-
key:"rotLeft",
|
|
102
|
+
key: "rotLeft",
|
|
80
103
|
},
|
|
81
104
|
{
|
|
82
105
|
name: "右旋转",
|
|
83
106
|
ico: "el-icon-refresh-right",
|
|
84
107
|
key: "rotRight",
|
|
85
108
|
},
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
109
|
+
{
|
|
110
|
+
name: "裁剪",
|
|
111
|
+
ico: "el-icon-crop",
|
|
112
|
+
key: "Crop",
|
|
113
|
+
},
|
|
91
114
|
{
|
|
92
115
|
name: "拖动",
|
|
93
116
|
ico: "el-icon-rank",
|
|
@@ -119,6 +142,28 @@
|
|
|
119
142
|
key: "preservation",
|
|
120
143
|
},
|
|
121
144
|
],
|
|
145
|
+
options: {
|
|
146
|
+
img: '', //裁剪图片的地址
|
|
147
|
+
outputSize: 1, // 裁剪生成图片的质量
|
|
148
|
+
outputType: 'jpeg', // 裁剪生成图片的格式
|
|
149
|
+
full: false, // 是否输出原图比例的截图
|
|
150
|
+
info: true, // 图片大小信息
|
|
151
|
+
canScale: true, // 图片是否允许滚轮缩放
|
|
152
|
+
autoCrop: true, // 是否默认生成截图框
|
|
153
|
+
//autoCropWidth: 800, // 默认生成截图框宽度
|
|
154
|
+
//autoCropHeight: 600, // 默认生成截图框高度
|
|
155
|
+
canMove: true, // 上传图片是否可以移动
|
|
156
|
+
//fixedBox: true, // 固定截图框大小 不允许改变
|
|
157
|
+
fixed: false, // 是否开启截图框宽高固定比例
|
|
158
|
+
canMoveBox: true, // 截图框能否拖动
|
|
159
|
+
original: false, // 上传图片按照原始比例渲染
|
|
160
|
+
centerBox: true, // 截图框是否被限制在图片里面
|
|
161
|
+
height: true,
|
|
162
|
+
infoTrue: true, // true 为展示真实输出图片宽高 false 展示看到的截图框宽高
|
|
163
|
+
enlarge: 1, // 图片根据截图框输出比例倍数
|
|
164
|
+
mode: 'cover', // 图片默认渲染方式
|
|
165
|
+
maxImgSize: 6000 // 限制图片最大宽度和高度
|
|
166
|
+
},
|
|
122
167
|
}
|
|
123
168
|
},
|
|
124
169
|
computed: {
|
|
@@ -131,9 +176,6 @@
|
|
|
131
176
|
width = width > 1160 ? 1160 : width;
|
|
132
177
|
this.bodywidth = width;
|
|
133
178
|
this.bodyheight = parseInt(window.document.body.clientHeight * 0.8);
|
|
134
|
-
if (typeof this.minWidth == 'undefined' || typeof this.minWidth == 'undefined') {
|
|
135
|
-
this.cropBoxResizable = true;
|
|
136
|
-
}
|
|
137
179
|
if (typeof this.file.originalSavedFileName !== 'undefined' && this.file.originalSavedFileName !== this.file.savedFileName) {
|
|
138
180
|
this.flagOriginal = true;
|
|
139
181
|
}
|
|
@@ -143,14 +185,14 @@
|
|
|
143
185
|
drawCanv(href) {
|
|
144
186
|
this.$nextTick(() => {
|
|
145
187
|
let _this = this
|
|
146
|
-
_this.canvas =
|
|
188
|
+
_this.canvas = this.$refs.canvas;
|
|
147
189
|
_this.ctx = _this.canvas.getContext("2d");
|
|
148
190
|
|
|
149
191
|
_this.canvas.width = 0;
|
|
150
192
|
_this.canvas.height = 0;
|
|
151
193
|
|
|
152
194
|
_this.imgObj = new Image()
|
|
153
|
-
_this.imgObj.src = href||_this.file.mediaUrl;
|
|
195
|
+
_this.imgObj.src = href || _this.file.mediaUrl;
|
|
154
196
|
_this.imgObj.setAttribute("crossOrigin", 'Anonymous')
|
|
155
197
|
_this.imgObj.onload = function (e) {
|
|
156
198
|
//获取原始宽高
|
|
@@ -182,8 +224,19 @@
|
|
|
182
224
|
this.canvas.addEventListener("pointermove", _this.draw, false);
|
|
183
225
|
this.canvas.addEventListener("pointerup", _this.endDraw, false);
|
|
184
226
|
this.canvas.addEventListener("pointerout", _this.outdraw, false);
|
|
227
|
+
this.canvas.addEventListener("mousewheel", _this.onMousewheel, false);
|
|
185
228
|
})
|
|
186
229
|
},
|
|
230
|
+
//滚动缩放
|
|
231
|
+
onMousewheel(e) {
|
|
232
|
+
if (e.wheelDelta > 0) {
|
|
233
|
+
// 放大
|
|
234
|
+
this.scaleDom(this.canvas, "+");
|
|
235
|
+
} else {
|
|
236
|
+
// 缩小
|
|
237
|
+
this.scaleDom(this.canvas, "-")
|
|
238
|
+
}
|
|
239
|
+
},
|
|
187
240
|
outdraw() {
|
|
188
241
|
this.isActive = false;
|
|
189
242
|
},
|
|
@@ -289,9 +342,12 @@
|
|
|
289
342
|
//放大缩小
|
|
290
343
|
scaleDom(canvas, type) {
|
|
291
344
|
if (type == "-") {
|
|
292
|
-
this.scale
|
|
345
|
+
if (this.scale - 0.05 < 0) {
|
|
346
|
+
return;
|
|
347
|
+
}
|
|
348
|
+
this.scale += -0.05;
|
|
293
349
|
} else if (type == "+") {
|
|
294
|
-
this.scale += 0.
|
|
350
|
+
this.scale += 0.05;
|
|
295
351
|
}
|
|
296
352
|
else {
|
|
297
353
|
this.scale = 1;
|
|
@@ -347,50 +403,37 @@
|
|
|
347
403
|
img.style.display = "none";
|
|
348
404
|
this.scaleDomSize(canvas);
|
|
349
405
|
},
|
|
406
|
+
//开始裁剪
|
|
350
407
|
Crop() {
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
408
|
+
if (typeof this.minWidth !== 'undefined' && typeof this.minHeight !== 'undefined') {
|
|
409
|
+
this.cropBoxResizable = true;
|
|
410
|
+
if (parseInt(this.minWidth) > this.bodywidth || parseInt(this.minHeight) > this.bodyheight) {
|
|
411
|
+
this.options.enlarge = 2;
|
|
412
|
+
}
|
|
413
|
+
this.options.autoCropWidth = parseInt(this.minWidth) / this.options.enlarge;
|
|
414
|
+
this.options.autoCropHeight = parseInt(this.minHeight) / this.options.enlarge;
|
|
415
|
+
if (this.canvas.width < parseInt(this.minWidth) || this.canvas.height < parseInt(this.minHeight)) {
|
|
416
|
+
this.options.mode = this.canvas.width / this.options.enlarge + "px auto";
|
|
417
|
+
}
|
|
359
418
|
}
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
cropBoxResizable: _this.cropBoxResizable,
|
|
365
|
-
data: {
|
|
366
|
-
width: w,
|
|
367
|
-
height: h
|
|
368
|
-
},
|
|
369
|
-
zoom(e) {
|
|
370
|
-
if (_this.ratio == 0) {
|
|
371
|
-
_this.ratio = e.detail.oldRatio
|
|
372
|
-
}
|
|
373
|
-
if (e.detail.ratio > _this.ratio) {
|
|
374
|
-
e.preventDefault();
|
|
375
|
-
}
|
|
376
|
-
},
|
|
377
|
-
})
|
|
378
|
-
this.cropper = cropper
|
|
419
|
+
this.canvasImg = this.canvas.toDataURL('image/jpeg');
|
|
420
|
+
this.options.img = this.canvasImg;
|
|
421
|
+
this.options.fixedBox = this.cropBoxResizable;
|
|
422
|
+
this.croppShow = true
|
|
379
423
|
},
|
|
380
424
|
// 确认裁剪
|
|
381
425
|
sureCropper() {
|
|
382
426
|
let _this = this
|
|
383
|
-
this.cropper.
|
|
427
|
+
this.$refs.cropper.getCropBlob(blob => {
|
|
384
428
|
const href = window.URL.createObjectURL(blob)
|
|
429
|
+
_this.croppShow = false;
|
|
385
430
|
_this.drawCanv(href)
|
|
386
|
-
}
|
|
387
|
-
this.cancelCropper()
|
|
431
|
+
});
|
|
388
432
|
},
|
|
389
433
|
// 销毁裁剪框
|
|
390
434
|
cancelCropper() {
|
|
391
|
-
this.cropper.destroy()
|
|
392
435
|
this.croppShow = false
|
|
393
|
-
this.
|
|
436
|
+
this.drawCanv(this.canvasImg);
|
|
394
437
|
},
|
|
395
438
|
Original() {
|
|
396
439
|
var url = this.file.mediaUrl.replace(this.file.savedFileName, this.file.originalSavedFileName);
|
|
@@ -458,6 +501,8 @@
|
|
|
458
501
|
this.file.mediaUrl = res.content.media.mediaUrl;
|
|
459
502
|
this.file.savedFileName = res.content.media.savedFileName;
|
|
460
503
|
this.file.mediaDate = res.content.media.mediaDate;
|
|
504
|
+
this.file.width = this.canvas.width;
|
|
505
|
+
this.file.height = this.canvas.height;
|
|
461
506
|
this.$emit('handleEditPhoto', this.file);
|
|
462
507
|
}
|
|
463
508
|
return true;
|
|
@@ -579,6 +624,7 @@
|
|
|
579
624
|
color: #fff;
|
|
580
625
|
z-index: 9;
|
|
581
626
|
}
|
|
627
|
+
|
|
582
628
|
.picedit-cropper {
|
|
583
629
|
height: 50px;
|
|
584
630
|
bottom: 0;
|
|
@@ -588,6 +634,7 @@
|
|
|
588
634
|
color: #fff;
|
|
589
635
|
z-index: 9;
|
|
590
636
|
}
|
|
637
|
+
|
|
591
638
|
.picedit-Original {
|
|
592
639
|
height: 50px;
|
|
593
640
|
top: 50px;
|
|
@@ -596,6 +643,7 @@
|
|
|
596
643
|
color: #fff;
|
|
597
644
|
z-index: 9;
|
|
598
645
|
}
|
|
646
|
+
|
|
599
647
|
.picedit-toolbar {
|
|
600
648
|
display: inline-block;
|
|
601
649
|
height: 50px;
|
|
@@ -616,19 +664,22 @@
|
|
|
616
664
|
font-size: 24px;
|
|
617
665
|
cursor: pointer;
|
|
618
666
|
}
|
|
667
|
+
|
|
619
668
|
.picedit-toolbar .active {
|
|
620
669
|
background-color: #fff;
|
|
621
|
-
color
|
|
622
|
-
}
|
|
623
|
-
.rc-cropper {
|
|
624
|
-
position: relative;
|
|
670
|
+
color: #333;
|
|
625
671
|
}
|
|
626
672
|
|
|
673
|
+
.rc-cropper {
|
|
674
|
+
position: relative;
|
|
675
|
+
}
|
|
676
|
+
|
|
627
677
|
.rc-cropper__iconCrop1 {
|
|
628
678
|
position: absolute;
|
|
629
679
|
right: 4%;
|
|
630
680
|
top: 0%;
|
|
631
681
|
}
|
|
682
|
+
|
|
632
683
|
.mask {
|
|
633
684
|
position: fixed;
|
|
634
685
|
z-index: 9998;
|
|
@@ -638,11 +689,11 @@
|
|
|
638
689
|
left: 0;
|
|
639
690
|
background-color: rgba(0, 0, 0, .3);
|
|
640
691
|
}
|
|
692
|
+
|
|
641
693
|
.stream-total-tips {
|
|
642
694
|
position: fixed;
|
|
643
695
|
top: 40%;
|
|
644
696
|
left: 45%;
|
|
645
697
|
z-index: 9999;
|
|
646
698
|
}
|
|
647
|
-
|
|
648
699
|
</style>
|
|
@@ -561,6 +561,13 @@
|
|
|
561
561
|
this.model.setByPieces(res, Progress, file);
|
|
562
562
|
|
|
563
563
|
if (res.content.finished == 1) {
|
|
564
|
+
var self = this;
|
|
565
|
+
let img = new Image();
|
|
566
|
+
img.src = self.model.fileList[self.model.fileList.length - 1].mediaUrl;
|
|
567
|
+
img.onload = function () {
|
|
568
|
+
self.model.fileList[self.model.fileList.length - 1].width = img.width;
|
|
569
|
+
self.model.fileList[self.model.fileList.length - 1].height = img.height;
|
|
570
|
+
};
|
|
564
571
|
this.handleChange();
|
|
565
572
|
}
|
|
566
573
|
return true;
|
|
@@ -510,6 +510,15 @@
|
|
|
510
510
|
let query = self.$common.objectToQueryStr(submitData);
|
|
511
511
|
window.open(field.action + query, "_blank");
|
|
512
512
|
}
|
|
513
|
+
else if (field.isUrlInSystemTab) {//外部框架tab页打开URl
|
|
514
|
+
submitData = field.getActionPara(submitData).para;
|
|
515
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
516
|
+
let urlTab = field.action + query;
|
|
517
|
+
if(field.action.indexOf('?')>-1 && query.indexOf('?')>-1){
|
|
518
|
+
urlTab = field.action + '&' +query.substr(1, query.length);
|
|
519
|
+
}
|
|
520
|
+
self.$common.getDataDrivenOpts().handler.openTabUrl(urlTab,field.pageTitle||field.label);
|
|
521
|
+
}
|
|
513
522
|
else if (field.isSeeVoice) {//看视频
|
|
514
523
|
self.$common.browseVideo(field, submitData)
|
|
515
524
|
}
|
|
@@ -219,6 +219,10 @@
|
|
|
219
219
|
this.flagSideBar=false;
|
|
220
220
|
}
|
|
221
221
|
|
|
222
|
+
if(document.body.clientWidth && document.body.clientWidth<1024){
|
|
223
|
+
this.flagSideBar=false;
|
|
224
|
+
}
|
|
225
|
+
|
|
222
226
|
if(this.flagSideBar){
|
|
223
227
|
this.selectIndex=-1;
|
|
224
228
|
if(this.flagDefaultDisplaySideBar && !this.sideBarStatus){
|
|
@@ -285,6 +289,7 @@
|
|
|
285
289
|
}
|
|
286
290
|
}
|
|
287
291
|
}
|
|
292
|
+
this.$refs.table.setTableHeight();
|
|
288
293
|
},
|
|
289
294
|
closeSideHandler() {
|
|
290
295
|
this.$refs.sideMenu.clickHandler();
|
|
@@ -886,6 +886,15 @@ export default {
|
|
|
886
886
|
let query = self.$common.objectToQueryStr(submitData);
|
|
887
887
|
window.open(action + query, "_blank");
|
|
888
888
|
}
|
|
889
|
+
else if (field.isUrlInSystemTab) {//外部框架tab页打开URl
|
|
890
|
+
submitData = field.getActionPara(submitData).para;
|
|
891
|
+
let query = self.$common.objectToQueryStr(submitData);
|
|
892
|
+
let urlTab = field.action + query;
|
|
893
|
+
if(field.action.indexOf('?')>-1 && query.indexOf('?')>-1){
|
|
894
|
+
urlTab = field.action + '&' +query.substr(1, query.length);
|
|
895
|
+
}
|
|
896
|
+
self.$common.getDataDrivenOpts().handler.openTabUrl(urlTab,field.pageTitle||field.label);
|
|
897
|
+
}
|
|
889
898
|
else if (field.isSeeVoice) {//看视频
|
|
890
899
|
self.$common.browseVideo(field, submitData);
|
|
891
900
|
}
|
|
@@ -334,16 +334,7 @@ const box = function (source, fileSourceList, router, optionApi,videoPlayIconUrl
|
|
|
334
334
|
}
|
|
335
335
|
rtn.fileList.push(awaitfile);
|
|
336
336
|
},
|
|
337
|
-
|
|
338
|
-
return new Promise(function (resolve, reject) {
|
|
339
|
-
let img = new Image();
|
|
340
|
-
img.src = url;
|
|
341
|
-
img.onload = function () {
|
|
342
|
-
resolve(img);
|
|
343
|
-
};
|
|
344
|
-
});
|
|
345
|
-
},
|
|
346
|
-
async setByPieces(res, Progress, file) {
|
|
337
|
+
setByPieces(res, Progress, file) {
|
|
347
338
|
if (res.rtnCode === Enum.ReturnCode.Successful) {
|
|
348
339
|
//下面的方式绑定,会有一些问题 todo 不强与页面关联
|
|
349
340
|
var data = {};
|
|
@@ -356,11 +347,6 @@ const box = function (source, fileSourceList, router, optionApi,videoPlayIconUrl
|
|
|
356
347
|
data = rtn.getFileData(res.content.media);
|
|
357
348
|
data.progressFlag = false;
|
|
358
349
|
data.loadProgress = 100;
|
|
359
|
-
if (data.mediaTypeID == 2) {
|
|
360
|
-
const img = await this.imgFn(data.mediaUrl);
|
|
361
|
-
w = img.width;
|
|
362
|
-
h = img.height;
|
|
363
|
-
}
|
|
364
350
|
Vue.set(file, "width", w);
|
|
365
351
|
Vue.set(file, "height", h);
|
|
366
352
|
Vue.set(file, "url", data.url);
|
|
@@ -98,6 +98,9 @@ const Router = function (source) {
|
|
|
98
98
|
get isUrlInLayer() {
|
|
99
99
|
return source.pageStyle === Enum.PageStyle.UrlInLayer;
|
|
100
100
|
},
|
|
101
|
+
get isUrlInSystemTab() {
|
|
102
|
+
return source.pageStyle === Enum.PageStyle.UrlInSystemTab;
|
|
103
|
+
},
|
|
101
104
|
get isOpenUrlInBrowse() {
|
|
102
105
|
return source.actionType === Enum.ActionType.OpenUrlInBrowse;
|
|
103
106
|
},
|
package/src/main.js
CHANGED
|
@@ -40,11 +40,14 @@ Vue.use(centaline, {
|
|
|
40
40
|
closeTab: function () {
|
|
41
41
|
alert("关闭当前tab")
|
|
42
42
|
},
|
|
43
|
+
openTabUrl: function (action) {
|
|
44
|
+
alert("打开tab页URL:" + action)
|
|
45
|
+
},
|
|
43
46
|
// 获取请求头
|
|
44
47
|
getRequestHeaders: function () {
|
|
45
48
|
return {
|
|
46
49
|
oldToken: '3ba3f510-93fd-4103-9249-73c13f3f6fc2',
|
|
47
|
-
token:'aplus eyJhbGciOiJIUzI1NiIsInppcCI6IkRFRiJ9.
|
|
50
|
+
token:'aplus eyJhbGciOiJIUzI1NiIsInppcCI6IkRFRiJ9.eNrEjkEKwjAQRe-StQNJZiYz6S5tmo2HkMZWqCuxLSji3a14CLePz3v_ZZatmsZgKy1nFgiJCcj3BJqlAIVMklVKl-gUCmfvRQClKHTOInifMtjvFDPGIPaUKSb1hLAj3E2uB20xgWdSwsIUhc3BTI-baVwQdYzk9WDmYf0Bu1u-YFum-3F6_uPcdZ337Og4ajgTTJdQgWwYYdCqMNpYeajjhSOb9wcAAP__.FwJrqBiqDn1H2KI7t-vmBjLQYadNyXFFaId5kR1WL_8',
|
|
48
51
|
|
|
49
52
|
originalRequestURL: 'http://10.88.22.67:8080',
|
|
50
53
|
EstateInfo: '{"estateId":"FAF029E8-EC28-4297-83CF-B8FFD826DB91","estateName":"AABBCC"}',
|