super-pages 0.0.16-up → 0.0.18-up
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/super-pages.css +1 -1
- package/lib/super-pages.js +2437 -2362
- package/lib/super-pages.umd.cjs +14 -14
- package/package.json +1 -1
- package/packages/super-page/src/button-group.vue +1 -1
- package/packages/super-page/src/chart-page.vue +2 -2
- package/packages/super-page/src/chart-query-page.vue +17 -7
- package/packages/super-page/src/common-form-page.vue +2 -2
- package/packages/super-page/src/list-page.vue +8 -6
- package/packages/super-page/src/my-button-base.vue +17 -9
- package/packages/super-page/src/my-button.vue +1 -1
- package/packages/super-page/src/page-custom-component.vue +1 -1
- package/packages/super-page/src/super-page.vue +5 -8
- package/packages/super-page/src/tab-page.vue +1 -1
- package/packages/super-page/src/util/ListButtonEvent.js +14 -3
- package/packages/super-page/src/util/chartButtonEvent.js +88 -0
- package/packages/super-page/src/util/formButtonEvent.js +25 -1
- package/packages/super-page/src/util/util.js +11 -11
- package/packages/super-page/src/util/workflowButtonEvent.js +4 -0
- package/packages/super-page/src/widget-col-page.vue +2 -2
- package/packages/super-page/src/widget-page.vue +16 -0
- package/packages/super-page/src/workflow-button-group.vue +1 -1
- package/packages/super-page/src/workflow-form-page.vue +2 -2
- package/packages/super-page-dialog/src/super-page-dialog.vue +3 -3
package/package.json
CHANGED
|
@@ -119,7 +119,7 @@ export default {
|
|
|
119
119
|
const that = this
|
|
120
120
|
// 关闭弹框事件回调使用
|
|
121
121
|
eventBus.$on(this.pageCode + '_close-dialog-get-entity', () => {
|
|
122
|
-
|
|
122
|
+
eventBus.$emit(that.pageCode + '_close-super-dialog')
|
|
123
123
|
})
|
|
124
124
|
},
|
|
125
125
|
mounted() {
|
|
@@ -130,7 +130,7 @@ export default {
|
|
|
130
130
|
// 响应点击统计按钮
|
|
131
131
|
eventBus.$on(
|
|
132
132
|
that.chartQueryCode + '-clickChartSearchButton',
|
|
133
|
-
|
|
133
|
+
function ({ searchParam, isInitSearch }) {
|
|
134
134
|
console.log('准备传递数据', searchParam)
|
|
135
135
|
if (that.isPreview) {
|
|
136
136
|
// 预览时,统计按钮不生效
|
|
@@ -26,6 +26,7 @@
|
|
|
26
26
|
</template>
|
|
27
27
|
|
|
28
28
|
<script>
|
|
29
|
+
import { $emit } from '../../utils/gogocodeTransfer'
|
|
29
30
|
import eventBus from './util/eventBus'
|
|
30
31
|
import { getStoreInfo } from './util/common-util'
|
|
31
32
|
import Util from './util/util'
|
|
@@ -90,7 +91,7 @@ export default {
|
|
|
90
91
|
mounted() {
|
|
91
92
|
const that = this
|
|
92
93
|
// 刷新指定页签的图表数据
|
|
93
|
-
|
|
94
|
+
eventBus.$on(that.pageCode + '-refresh-tab', function ({ tabCode, entity }){
|
|
94
95
|
const refName =
|
|
95
96
|
'chartQueryRef' + that.colSetting.baseSetting.componentCode
|
|
96
97
|
if (that.$refs[refName]) {
|
|
@@ -99,9 +100,22 @@ export default {
|
|
|
99
100
|
})
|
|
100
101
|
}
|
|
101
102
|
})
|
|
103
|
+
// 获得图表页面查询区域的值
|
|
104
|
+
eventBus.$on(this.pageCode + '_click-chart-page-button', () => {
|
|
105
|
+
console.log('点击了图表页面查询页面的按钮11===')
|
|
106
|
+
const refName = 'chartQueryRef' + that.colSetting.baseSetting.componentCode
|
|
107
|
+
if (that.$refs[refName]) {
|
|
108
|
+
console.log('点击了图表页面查询页面的按钮22===')
|
|
109
|
+
that.$refs[refName].getSearchParams().then((searchForm) => {
|
|
110
|
+
console.log('点击了图表页面查询页面的按钮33==searchForm=', searchForm)
|
|
111
|
+
eventBus.$emit(that.pageCode + '_get-chart-page-search-form', searchForm)
|
|
112
|
+
})
|
|
113
|
+
}
|
|
114
|
+
})
|
|
102
115
|
},
|
|
103
116
|
beforeUnmount() {
|
|
104
117
|
eventBus.$off(this.pageCode + '-refresh-tab')
|
|
118
|
+
eventBus.$off(this.pageCode + '_click-chart-page-button')
|
|
105
119
|
},
|
|
106
120
|
methods: {
|
|
107
121
|
...Util,
|
|
@@ -109,9 +123,7 @@ export default {
|
|
|
109
123
|
search(searchParam) {
|
|
110
124
|
$emit(
|
|
111
125
|
eventBus,
|
|
112
|
-
this.queryCode + '-clickChartSearchButton',
|
|
113
|
-
searchParam,
|
|
114
|
-
false
|
|
126
|
+
this.queryCode + '-clickChartSearchButton',{ searchParam, isInitSearch:false }
|
|
115
127
|
)
|
|
116
128
|
},
|
|
117
129
|
resetForm(searchParam) {
|
|
@@ -128,9 +140,7 @@ export default {
|
|
|
128
140
|
setTimeout(function () {
|
|
129
141
|
$emit(
|
|
130
142
|
eventBus,
|
|
131
|
-
that.queryCode + '-clickChartSearchButton',
|
|
132
|
-
searchParam,
|
|
133
|
-
true
|
|
143
|
+
that.queryCode + '-clickChartSearchButton',{ searchParam, isInitSearch:true }
|
|
134
144
|
)
|
|
135
145
|
}, 500)
|
|
136
146
|
},
|
|
@@ -265,7 +265,7 @@ export default {
|
|
|
265
265
|
const that = this
|
|
266
266
|
eventBus.$on(
|
|
267
267
|
jumpPageSetting.pageCode + '-close-dialog',
|
|
268
|
-
|
|
268
|
+
function ({ pageCode, successOperation, popEntity, popPageCode }) {
|
|
269
269
|
if (pageCode === jumpPageSetting.pageCode) {
|
|
270
270
|
that.closeInPageEvent(
|
|
271
271
|
popEntity,
|
|
@@ -305,7 +305,7 @@ export default {
|
|
|
305
305
|
const that = this
|
|
306
306
|
eventBus.$on(
|
|
307
307
|
this.pageCode + '-close-component-page-dialog',
|
|
308
|
-
|
|
308
|
+
function ({ jumpInfo, popEntity, popPageCode }) {
|
|
309
309
|
console.log(
|
|
310
310
|
'closeFormPageDialog------',
|
|
311
311
|
jumpInfo,
|
|
@@ -399,7 +399,7 @@ export default {
|
|
|
399
399
|
const that = this
|
|
400
400
|
eventBus.$on(
|
|
401
401
|
jumpPageSetting.pageCode + '-close-dialog',
|
|
402
|
-
(pageCode, successOperation, popEntity, popPageCode)
|
|
402
|
+
function({ pageCode, successOperation, popEntity, popPageCode }) {
|
|
403
403
|
if (pageCode === jumpPageSetting.pageCode) {
|
|
404
404
|
that.closeInPageEvent(
|
|
405
405
|
popEntity,
|
|
@@ -408,7 +408,7 @@ export default {
|
|
|
408
408
|
that
|
|
409
409
|
)
|
|
410
410
|
}
|
|
411
|
-
that
|
|
411
|
+
that.selections= null
|
|
412
412
|
// that.selections = null
|
|
413
413
|
// 关闭事件
|
|
414
414
|
eventBus.$off(pageCode + '-close-dialog')
|
|
@@ -444,7 +444,7 @@ export default {
|
|
|
444
444
|
const that = this
|
|
445
445
|
eventBus.$on(
|
|
446
446
|
that.pageCode + '-close-component-page-dialog',
|
|
447
|
-
|
|
447
|
+
function({ jumpInfo, popEntity, popPageCode }){
|
|
448
448
|
console.log(
|
|
449
449
|
'close-component-page-dialog-list------',
|
|
450
450
|
jumpInfo,
|
|
@@ -460,7 +460,7 @@ export default {
|
|
|
460
460
|
}
|
|
461
461
|
)
|
|
462
462
|
// 刷新指定页签的表格数据
|
|
463
|
-
eventBus.$on(that.pageCode + '-refresh-tab', (tabCode)
|
|
463
|
+
eventBus.$on(that.pageCode + '-refresh-tab', function({ tabCode, entity }) {
|
|
464
464
|
if (
|
|
465
465
|
that.$refs.grid &&
|
|
466
466
|
tabCode !== undefined &&
|
|
@@ -471,7 +471,7 @@ export default {
|
|
|
471
471
|
})
|
|
472
472
|
// 关闭弹框事件回调使用
|
|
473
473
|
eventBus.$on(this.pageCode + '_close-dialog-get-entity', () => {
|
|
474
|
-
|
|
474
|
+
eventBus.$emit(that.pageCode + '_close-super-dialog')
|
|
475
475
|
})
|
|
476
476
|
},
|
|
477
477
|
beforeUnmount() {
|
|
@@ -808,7 +808,9 @@ export default {
|
|
|
808
808
|
additionalParamMap,
|
|
809
809
|
that.beanName,
|
|
810
810
|
that.isWorkflowEntity,
|
|
811
|
-
button.functionCode
|
|
811
|
+
button.functionCode,
|
|
812
|
+
false,
|
|
813
|
+
button.isPermission
|
|
812
814
|
)
|
|
813
815
|
.then((commonEntity) => {
|
|
814
816
|
if (commonEntity) {
|
|
@@ -23,6 +23,7 @@
|
|
|
23
23
|
@prohibi-edit="fnProhibitToEdit"
|
|
24
24
|
@refresh-tab="refreshTab"
|
|
25
25
|
@refresh-from="refreshFrom"
|
|
26
|
+
@click="clickMyButton(button)"
|
|
26
27
|
/>
|
|
27
28
|
<el-button
|
|
28
29
|
v-else
|
|
@@ -30,7 +31,7 @@
|
|
|
30
31
|
:disabled="disabled ? disabled : preventReclick"
|
|
31
32
|
:size="button.size ? button.size : 'small'"
|
|
32
33
|
:type="getButtonType(button)"
|
|
33
|
-
:icon="icon"
|
|
34
|
+
:icon="faIcon?'':icon"
|
|
34
35
|
:class="button.code"
|
|
35
36
|
:plain="
|
|
36
37
|
typeof button.isPlain === 'undefined' ? false : button.isPlain
|
|
@@ -42,8 +43,11 @@
|
|
|
42
43
|
typeof button.isCircle === 'undefined' ? false : button.isCircle
|
|
43
44
|
"
|
|
44
45
|
@click="clickMyButton(button)"
|
|
45
|
-
>
|
|
46
|
-
|
|
46
|
+
>
|
|
47
|
+
<template v-if="faIcon" #icon>
|
|
48
|
+
<i :class="icon"></i>
|
|
49
|
+
</template>
|
|
50
|
+
{{ getButtonLabel(button) }}</el-button>
|
|
47
51
|
</span>
|
|
48
52
|
<span v-else>
|
|
49
53
|
<export-pdf-button
|
|
@@ -155,7 +159,7 @@ export default {
|
|
|
155
159
|
let permission = 'true'
|
|
156
160
|
if (
|
|
157
161
|
this.button.isPermission === undefined ||
|
|
158
|
-
this.button.isPermission === true
|
|
162
|
+
this.button.isPermission === 'true'
|
|
159
163
|
) {
|
|
160
164
|
// 表示按钮受权限保护
|
|
161
165
|
permission = this.permissionPrefix + '.' + this.button.code
|
|
@@ -180,13 +184,16 @@ export default {
|
|
|
180
184
|
const displayConditions = this.button.buttonDisplayConditionsList
|
|
181
185
|
let isCustomVisible = false
|
|
182
186
|
const isView = this.isViewDetail(this.position)
|
|
183
|
-
|
|
184
|
-
|
|
187
|
+
let icon = this.button.icon
|
|
188
|
+
let faIcon = false
|
|
189
|
+
if (icon && (icon.indexOf('fa') === 0)) {
|
|
185
190
|
// 表示以“fa-”开头,使用font-awesome中的图标
|
|
186
|
-
|
|
191
|
+
icon = 'fa fa-custom ' + icon
|
|
192
|
+
faIcon = true
|
|
187
193
|
}
|
|
188
194
|
if (this.position === 'chart' && !icon && this.button.code === 'export') {
|
|
189
|
-
|
|
195
|
+
icon = 'fa fa-custom fa-cloud-download'
|
|
196
|
+
faIcon = true
|
|
190
197
|
}
|
|
191
198
|
const formDataFun = this.myFormDataFun
|
|
192
199
|
let initFormData
|
|
@@ -218,7 +225,8 @@ export default {
|
|
|
218
225
|
showExportForm: false,
|
|
219
226
|
initFormData, // 表单初始值
|
|
220
227
|
backButtonName,
|
|
221
|
-
|
|
228
|
+
customParams: {},
|
|
229
|
+
faIcon
|
|
222
230
|
}
|
|
223
231
|
},
|
|
224
232
|
computed: {
|
|
@@ -48,7 +48,7 @@ export default {
|
|
|
48
48
|
if (tabCode === undefined || tabCode === null) {
|
|
49
49
|
tabCode = getStoreInfo(this.pageCode, '_activeTab')
|
|
50
50
|
}
|
|
51
|
-
$emit(eventBus, this.pageCode + '-refresh-tab', tabCode, entity)
|
|
51
|
+
$emit(eventBus, this.pageCode + '-refresh-tab', { tabCode:tabCode, entity:entity })
|
|
52
52
|
},
|
|
53
53
|
},
|
|
54
54
|
emits: ['getSystemRef'],
|
|
@@ -103,15 +103,12 @@ export default {
|
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
105
|
if (this.pathQuery.ids) {
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
if (
|
|
109
|
-
|
|
110
|
-
pageSettingStoreInfo._pathQuery = {
|
|
111
|
-
_idsStr: idsStr,
|
|
112
|
-
}
|
|
113
|
-
}
|
|
106
|
+
const idsStr = this.pathQuery.ids
|
|
107
|
+
if (idsStr) {
|
|
108
|
+
if (!pageSettingStoreInfo._pathQuery) {
|
|
109
|
+
pageSettingStoreInfo._pathQuery = {}
|
|
114
110
|
}
|
|
111
|
+
pageSettingStoreInfo._pathQuery._idsStr = idsStr
|
|
115
112
|
}
|
|
116
113
|
store.set(this.pageCode, pageSettingStoreInfo)
|
|
117
114
|
}
|
|
@@ -141,7 +141,7 @@ export default {
|
|
|
141
141
|
},
|
|
142
142
|
// 刷新页签内容:列表数据或表单数据
|
|
143
143
|
refreshTab(tabCode) {
|
|
144
|
-
$emit(eventBus, this.pageCode + '-refresh-tab', tabCode)
|
|
144
|
+
$emit(eventBus, this.pageCode + '-refresh-tab', { tabCode:tabCode })
|
|
145
145
|
},
|
|
146
146
|
// chartQuery组件,导出报告
|
|
147
147
|
exportReport(beanName) {
|
|
@@ -220,7 +220,7 @@ const buttonEvents = {
|
|
|
220
220
|
isAsync = false
|
|
221
221
|
}
|
|
222
222
|
// 页面编码 this.pageCode
|
|
223
|
-
this.export(listCode, button.functionCode, uuid, isAsync, this.pageCode)
|
|
223
|
+
this.export(listCode, button.functionCode, uuid, isAsync, this.pageCode, button.isPermission)
|
|
224
224
|
} else if (button.code === 'viewDetail') {
|
|
225
225
|
// 查看详情
|
|
226
226
|
let dataId
|
|
@@ -416,9 +416,11 @@ const buttonEvents = {
|
|
|
416
416
|
path = baseUrl + '/dsc/commons/' + tableName
|
|
417
417
|
}
|
|
418
418
|
path = this.getRealRestApiPath(path, system)
|
|
419
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
419
420
|
const param = {
|
|
420
421
|
ids: ids,
|
|
421
422
|
functionCode: button.functionCode,
|
|
423
|
+
isPermission: isPermission + ''
|
|
422
424
|
}
|
|
423
425
|
if (entityName) {
|
|
424
426
|
// 表示需要重写删除的实现
|
|
@@ -550,6 +552,10 @@ const buttonEvents = {
|
|
|
550
552
|
if (tableName) {
|
|
551
553
|
param += '&tableName=' + tableName
|
|
552
554
|
}
|
|
555
|
+
if (button) {
|
|
556
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
557
|
+
param += '&isPermission=' + isPermission
|
|
558
|
+
}
|
|
553
559
|
const baseUrl = this.getBaseUrl(system)
|
|
554
560
|
window.open(baseUrl + '/dsc/commons/download-files' + param)
|
|
555
561
|
},
|
|
@@ -645,6 +651,8 @@ const buttonEvents = {
|
|
|
645
651
|
JSON.stringify(this.additionalParamMap)
|
|
646
652
|
)
|
|
647
653
|
}
|
|
654
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
655
|
+
param.append('isPermission', isPermission)
|
|
648
656
|
|
|
649
657
|
let path = restfulApiPath
|
|
650
658
|
if (system.standard === false && !path) {
|
|
@@ -713,7 +721,7 @@ const buttonEvents = {
|
|
|
713
721
|
}
|
|
714
722
|
},
|
|
715
723
|
// 列表-导出。导出台账数据,有查询条件则导出查询条件对应的数据,没有查询条件则导出所有记录
|
|
716
|
-
export(listCode, functionCode, uuid, isAsync, pageCode) {
|
|
724
|
+
export(listCode, functionCode, uuid, isAsync, pageCode, isPermission) {
|
|
717
725
|
const dataParam = {}
|
|
718
726
|
if (this.selections && this.selections.length > 0) {
|
|
719
727
|
dataParam.data = this.selections
|
|
@@ -735,7 +743,8 @@ const buttonEvents = {
|
|
|
735
743
|
uuid,
|
|
736
744
|
null,
|
|
737
745
|
isAsync,
|
|
738
|
-
pageCode
|
|
746
|
+
pageCode,
|
|
747
|
+
isPermission
|
|
739
748
|
)
|
|
740
749
|
// afterClick回调方法
|
|
741
750
|
this.callAfterClickButton(this.listEvents, this.listCode + '__export', {
|
|
@@ -772,11 +781,13 @@ const buttonEvents = {
|
|
|
772
781
|
}
|
|
773
782
|
)
|
|
774
783
|
.then(() => {
|
|
784
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
775
785
|
const param = {
|
|
776
786
|
ids: ids,
|
|
777
787
|
formNoRuleCode,
|
|
778
788
|
tableName: tableName,
|
|
779
789
|
functionCode: button.functionCode,
|
|
790
|
+
isPermission: isPermission + ''
|
|
780
791
|
}
|
|
781
792
|
if (this.judgeHeavyList) {
|
|
782
793
|
// 判重组合字段配置
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
+
import eventBus from './eventBus'
|
|
1
2
|
const buttonEvents = {
|
|
2
3
|
// 点击按钮触发
|
|
3
4
|
clickListButton(button) {
|
|
4
5
|
if (button) {
|
|
6
|
+
console.log('点击了图表页面查询页面的按钮===开始====')
|
|
7
|
+
eventBus.$emit(this.pageCode + '_click-chart-page-button')
|
|
5
8
|
if (button.code === 'export') {
|
|
6
9
|
// 导出按钮
|
|
7
10
|
this.exportChart()
|
|
@@ -56,5 +59,90 @@ const buttonEvents = {
|
|
|
56
59
|
// }
|
|
57
60
|
}
|
|
58
61
|
},
|
|
62
|
+
getSearchForm () {
|
|
63
|
+
return this.searchForm
|
|
64
|
+
},
|
|
65
|
+
getParamsByQueryAndEvent (query) {
|
|
66
|
+
const param = {}
|
|
67
|
+
if (query) {
|
|
68
|
+
if (query.normalFields) {
|
|
69
|
+
// 获取normalFields整体对象
|
|
70
|
+
const normalFieldsObj = this.getSearchFromTypeObj(query.normalFields)
|
|
71
|
+
if (normalFieldsObj) {
|
|
72
|
+
const normalFieldsKeys = Object.keys(normalFieldsObj)
|
|
73
|
+
if (normalFieldsKeys && normalFieldsKeys.length > 0) {
|
|
74
|
+
normalFieldsKeys.forEach(key => {
|
|
75
|
+
param[key] = normalFieldsObj[key]
|
|
76
|
+
})
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
if (query.groupByFields) {
|
|
81
|
+
const groupByFieldsObj = this.getSearchFromTypeObj(query.groupByFields)
|
|
82
|
+
const groupByFieldsKeys = Object.keys(groupByFieldsObj)
|
|
83
|
+
if (groupByFieldsKeys && groupByFieldsKeys.length > 0) {
|
|
84
|
+
groupByFieldsKeys.forEach(key => {
|
|
85
|
+
param[key] = groupByFieldsObj[key]
|
|
86
|
+
})
|
|
87
|
+
}
|
|
88
|
+
}
|
|
89
|
+
if (query.orderByFields) {
|
|
90
|
+
const orderByFieldsObj = this.getSearchFromTypeObj(query.orderByFields)
|
|
91
|
+
const orderByFieldsKeys = Object.keys(orderByFieldsObj)
|
|
92
|
+
if (orderByFieldsKeys && orderByFieldsKeys.length > 0) {
|
|
93
|
+
orderByFieldsKeys.forEach(key => {
|
|
94
|
+
param[key] = orderByFieldsObj[key]
|
|
95
|
+
})
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
if (query.limitFields) {
|
|
99
|
+
const limitFieldsObj = this.getSearchFromTypeObj(query.limitFields)
|
|
100
|
+
const limitFieldsKeys = Object.keys(limitFieldsObj)
|
|
101
|
+
if (limitFieldsKeys && limitFieldsKeys.length > 0) {
|
|
102
|
+
limitFieldsKeys.forEach(key => {
|
|
103
|
+
param[key] = limitFieldsObj[key]
|
|
104
|
+
})
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
return param
|
|
109
|
+
},
|
|
110
|
+
getSearchFromTypeObj (fields) {
|
|
111
|
+
let returnObj = null
|
|
112
|
+
if (fields) {
|
|
113
|
+
returnObj = {}
|
|
114
|
+
for (let i = 0; i < fields.length; i++) {
|
|
115
|
+
const field = fields[i]
|
|
116
|
+
if (field.propName) {
|
|
117
|
+
let returnObjVal = returnObj[field.propName]
|
|
118
|
+
if (field.propValue !== undefined && field.propValue !== null) {
|
|
119
|
+
if (returnObjVal !== undefined && returnObjVal !== null) {
|
|
120
|
+
returnObjVal += ',' + field.propValue
|
|
121
|
+
} else {
|
|
122
|
+
returnObjVal = field.propValue
|
|
123
|
+
}
|
|
124
|
+
} else {
|
|
125
|
+
returnObjVal = field.propValue
|
|
126
|
+
}
|
|
127
|
+
returnObj[field.propName] = returnObjVal
|
|
128
|
+
const valueArr = []
|
|
129
|
+
if (field.startValue) {
|
|
130
|
+
valueArr[0] = field.startValue
|
|
131
|
+
} else {
|
|
132
|
+
valueArr[0] = null
|
|
133
|
+
}
|
|
134
|
+
if (field.endValue) {
|
|
135
|
+
valueArr[1] = field.endValue
|
|
136
|
+
} else {
|
|
137
|
+
valueArr[1] = null
|
|
138
|
+
}
|
|
139
|
+
if (valueArr[0] || valueArr[1]) {
|
|
140
|
+
returnObj[field.propName] = valueArr
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
return returnObj
|
|
146
|
+
}
|
|
59
147
|
}
|
|
60
148
|
export default buttonEvents
|
|
@@ -49,6 +49,23 @@ const buttonEvents = {
|
|
|
49
49
|
if (additionalParamMap) {
|
|
50
50
|
param.additionalParamMap = additionalParamMap
|
|
51
51
|
}
|
|
52
|
+
if (button.dataConversionRule) {
|
|
53
|
+
param.dataConversionRule = button.dataConversionRule.join(',')
|
|
54
|
+
}
|
|
55
|
+
if (button.autoSetValueData) {
|
|
56
|
+
param.autoSetValueData = JSON.stringify(button.autoSetValueData)
|
|
57
|
+
}
|
|
58
|
+
if (needDeleteFileUuidS) {
|
|
59
|
+
param.needDeleteFileUuid = needDeleteFileUuidS
|
|
60
|
+
}
|
|
61
|
+
if (button.jumpPage) {
|
|
62
|
+
let dataId
|
|
63
|
+
if (formData) {
|
|
64
|
+
dataId = formData.id || formData.ID
|
|
65
|
+
}
|
|
66
|
+
this.jumpToPage(button.jumpPage, system, dataId, formData, additionalParamMap, null, button.code, this.pageCode)
|
|
67
|
+
return
|
|
68
|
+
}
|
|
52
69
|
if (
|
|
53
70
|
button.successOperation &&
|
|
54
71
|
button.successOperation === 'noOperation'
|
|
@@ -217,7 +234,8 @@ const buttonEvents = {
|
|
|
217
234
|
beanName,
|
|
218
235
|
false,
|
|
219
236
|
button.functionCode,
|
|
220
|
-
isUnControlVersion
|
|
237
|
+
isUnControlVersion,
|
|
238
|
+
button.isPermission
|
|
221
239
|
)
|
|
222
240
|
if (request) {
|
|
223
241
|
request.then((data) => {
|
|
@@ -305,11 +323,13 @@ const buttonEvents = {
|
|
|
305
323
|
}
|
|
306
324
|
)
|
|
307
325
|
.then(() => {
|
|
326
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
308
327
|
const param = {
|
|
309
328
|
entity: formData,
|
|
310
329
|
tableName: tableName,
|
|
311
330
|
formNoRuleCode,
|
|
312
331
|
functionCode: button.functionCode,
|
|
332
|
+
isPermission: isPermission + ''
|
|
313
333
|
}
|
|
314
334
|
if (this.judgeHeavyList) {
|
|
315
335
|
// 判重组合字段配置
|
|
@@ -486,6 +506,10 @@ const buttonEvents = {
|
|
|
486
506
|
if (tableName) {
|
|
487
507
|
param += '&tableName=' + tableName
|
|
488
508
|
}
|
|
509
|
+
if (button) {
|
|
510
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
511
|
+
param += '&isPermission=' + isPermission
|
|
512
|
+
}
|
|
489
513
|
// filePath格式如:用户定义的文件名~~服务器上磁盘中存储的文件路径及文件名。例如:user-info.xls~~iMatrix/b03dr45f5h4g.xls
|
|
490
514
|
// let fileShowName = ''
|
|
491
515
|
if (
|
|
@@ -450,9 +450,11 @@ const Util = {
|
|
|
450
450
|
beanName,
|
|
451
451
|
isWorkflow,
|
|
452
452
|
functionCode,
|
|
453
|
-
isUnControlVersion
|
|
453
|
+
isUnControlVersion,
|
|
454
|
+
isPermission
|
|
454
455
|
) {
|
|
455
456
|
// 自定义系统时,封装CommonEntity
|
|
457
|
+
isPermission = isPermission === undefined || isPermission === 'true'
|
|
456
458
|
const param = {
|
|
457
459
|
entity: formData,
|
|
458
460
|
formViewCode: formViewCode,
|
|
@@ -461,6 +463,7 @@ const Util = {
|
|
|
461
463
|
formNoRuleCode,
|
|
462
464
|
isWorkflowEntity: isWorkflow,
|
|
463
465
|
functionCode: functionCode,
|
|
466
|
+
isPermission: isPermission + ''
|
|
464
467
|
}
|
|
465
468
|
if (this.judgeHeavyList) {
|
|
466
469
|
// 判重组合字段配置
|
|
@@ -573,6 +576,7 @@ const Util = {
|
|
|
573
576
|
if (this.$refs.superForm) {
|
|
574
577
|
// 通过getViewModels获得处理了下拉框、复选框的值之后的表单数据,用于导出报告使用
|
|
575
578
|
this.$refs.superForm.getViewModels().then(async (viewModels) => {
|
|
579
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
576
580
|
const param = {
|
|
577
581
|
entity: viewModels,
|
|
578
582
|
fileName: templateUUID, // uuid
|
|
@@ -582,6 +586,7 @@ const Util = {
|
|
|
582
586
|
isWorkflowForm, // 是否是流程表单
|
|
583
587
|
functionCode: button.functionCode,
|
|
584
588
|
tableName,
|
|
589
|
+
isPermission: isPermission + ''
|
|
585
590
|
}
|
|
586
591
|
if (logSettingText) {
|
|
587
592
|
param.logSettingText = logSettingText
|
|
@@ -1059,10 +1064,8 @@ const Util = {
|
|
|
1059
1064
|
)
|
|
1060
1065
|
$emit(
|
|
1061
1066
|
eventBus,
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
myFormData,
|
|
1065
|
-
this.pageCode
|
|
1067
|
+
sourcePageCode + '-close-component-page-dialog',
|
|
1068
|
+
{ jumpInfo:jumpInfoObj, popEntity:myFormData, popPageCode:this.pageCode }
|
|
1066
1069
|
)
|
|
1067
1070
|
} else {
|
|
1068
1071
|
// 页面组件中关闭弹框
|
|
@@ -1076,11 +1079,8 @@ const Util = {
|
|
|
1076
1079
|
)
|
|
1077
1080
|
$emit(
|
|
1078
1081
|
eventBus,
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
successOperation,
|
|
1082
|
-
myFormData,
|
|
1083
|
-
this.pageCode
|
|
1082
|
+
pageCode + '-close-dialog',
|
|
1083
|
+
{ pageCode:pageCode, successOperation:successOperation, popEntity:myFormData, popPageCode:this.pageCode }
|
|
1084
1084
|
)
|
|
1085
1085
|
}
|
|
1086
1086
|
} else if (jumpMode === 'openWindow' || jumpMode === 'newTab') {
|
|
@@ -1521,7 +1521,7 @@ const Util = {
|
|
|
1521
1521
|
if (tabCode === undefined || tabCode === null) {
|
|
1522
1522
|
tabCode = getStoreInfo(this.pageCode, '_activeTab')
|
|
1523
1523
|
}
|
|
1524
|
-
$emit(eventBus, this.pageCode + '-refresh-tab', tabCode, entity)
|
|
1524
|
+
$emit(eventBus, this.pageCode + '-refresh-tab', { tabCode:tabCode, entity:entity })
|
|
1525
1525
|
},
|
|
1526
1526
|
}
|
|
1527
1527
|
export default Util
|
|
@@ -1722,6 +1722,10 @@ const buttonEvents = {
|
|
|
1722
1722
|
'&showName=' +
|
|
1723
1723
|
encodeURI(templateShowPath)
|
|
1724
1724
|
}
|
|
1725
|
+
if (button) {
|
|
1726
|
+
const isPermission = button.isPermission === undefined || button.isPermission === 'true'
|
|
1727
|
+
param += '&isPermission=' + isPermission
|
|
1728
|
+
}
|
|
1725
1729
|
const baseUrl = this.getBaseUrl(system)
|
|
1726
1730
|
window.open(baseUrl + '/dsc/commons/download-files' + param)
|
|
1727
1731
|
},
|
|
@@ -221,7 +221,7 @@ export default {
|
|
|
221
221
|
mounted() {
|
|
222
222
|
const that = this
|
|
223
223
|
// 切换页签时刷新流转历史
|
|
224
|
-
|
|
224
|
+
eventBus.$on('refreshHistory', () => {
|
|
225
225
|
// console.log('-refreshHistory--')
|
|
226
226
|
if (that.$refs.historyList) {
|
|
227
227
|
that.$refs.historyList.refresh()
|
|
@@ -232,7 +232,7 @@ export default {
|
|
|
232
232
|
})
|
|
233
233
|
},
|
|
234
234
|
beforeUnmount() {
|
|
235
|
-
|
|
235
|
+
eventBus.$off('refreshHistory')
|
|
236
236
|
console.log('-refreshHistory-off')
|
|
237
237
|
},
|
|
238
238
|
methods: {
|