vue2-client 1.8.171 → 1.8.172
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
CHANGED
|
@@ -16,7 +16,10 @@
|
|
|
16
16
|
<template v-if="row.type === 'jsonKey'">
|
|
17
17
|
<tr :key="rowIndex">
|
|
18
18
|
<!-- 表头 -->
|
|
19
|
-
<td
|
|
19
|
+
<td
|
|
20
|
+
:class="noTopBorder ? 'tdWithNoTopBorder' : 'tdWithBorder'"
|
|
21
|
+
:style="determineCellStyle(receivedFunction[rowIndex].labelFunction(config, item))"
|
|
22
|
+
colspan="6">
|
|
20
23
|
<template v-if="receivedFunction[rowIndex].labelFunction(config).type === 'key'">
|
|
21
24
|
{{ config.data[receivedFunction[rowIndex].labelFunction(config).content] }}
|
|
22
25
|
</template>
|
|
@@ -47,7 +50,10 @@
|
|
|
47
50
|
<template v-else-if="row.type === 'jsonArray'">
|
|
48
51
|
<tr :key="rowIndex + '' + jsonArrayItemIndex" v-for="(item, jsonArrayItemIndex) in config.data[row.jsonArrayDataIndex]">
|
|
49
52
|
<!-- 表头 -->
|
|
50
|
-
<td
|
|
53
|
+
<td
|
|
54
|
+
:class="noTopBorder ? 'tdWithNoTopBorder' : 'tdWithBorder'"
|
|
55
|
+
:style="determineCellStyle(receivedFunction[rowIndex].labelFunction(config, item))"
|
|
56
|
+
colspan="6">
|
|
51
57
|
<template v-if="receivedFunction[rowIndex].labelFunction(config, item).type === 'key'">
|
|
52
58
|
{{ item[receivedFunction[rowIndex].labelFunction(config, item).content] }}
|
|
53
59
|
</template>
|
|
@@ -56,7 +62,9 @@
|
|
|
56
62
|
</template>
|
|
57
63
|
</td>
|
|
58
64
|
<!-- 内容 -->
|
|
59
|
-
<td
|
|
65
|
+
<td
|
|
66
|
+
:class="noTopBorder ? 'tdWithNoTopBorder' : 'tdWithBorder'"
|
|
67
|
+
colspan="6">
|
|
60
68
|
<template v-if="receivedFunction[rowIndex].valueFunction(config, item).type === 'key'">
|
|
61
69
|
{{ item[receivedFunction[rowIndex].valueFunction(config, item).content] }}
|
|
62
70
|
</template>
|
|
@@ -114,6 +122,13 @@ export default {
|
|
|
114
122
|
}
|
|
115
123
|
},
|
|
116
124
|
methods: {
|
|
125
|
+
determineCellStyle (labelFunctionReturn) {
|
|
126
|
+
if (labelFunctionReturn.style !== undefined) {
|
|
127
|
+
return labelFunctionReturn.style
|
|
128
|
+
} else {
|
|
129
|
+
return undefined
|
|
130
|
+
}
|
|
131
|
+
},
|
|
117
132
|
handleShowImgOk () {
|
|
118
133
|
this.showImgModal = false
|
|
119
134
|
this.showImageSrc = undefined
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
v-if="!cell.dontShowRow"
|
|
9
9
|
:key="cellIndex"
|
|
10
10
|
:class=" calcTDBorder(cell.noBoarder) "
|
|
11
|
-
:style="cell
|
|
11
|
+
:style="determineCellStyle(cell)"
|
|
12
12
|
:colspan="cell.colSpan ? cell.colSpan : undefined">
|
|
13
13
|
<template v-if="cell.type === 'column'">
|
|
14
14
|
<template v-if="cell.customFunction">
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
:key="cellIndex"
|
|
76
76
|
:class=" calcTDBorder(cell.noBoarder) "
|
|
77
77
|
:colspan="cell.colSpan ? cell.colSpan : undefined"
|
|
78
|
-
:style="cell
|
|
78
|
+
:style="determineCellStyle(cell)"
|
|
79
79
|
:rowspan="cell.rowSpan ? cell.rowSpan : undefined">
|
|
80
80
|
<template v-if="cell.type === 'column'">
|
|
81
81
|
{{ cell.text }}
|
|
@@ -128,7 +128,7 @@
|
|
|
128
128
|
:key="cellIndex"
|
|
129
129
|
:class=" calcTDBorder(cell.noBoarder) "
|
|
130
130
|
:colspan="cell.colSpan ? cell.colSpan : undefined"
|
|
131
|
-
:style="cell
|
|
131
|
+
:style="determineCellStyle(cell)"
|
|
132
132
|
:rowspan="cell.rowSpan ? cell.rowSpan : undefined">
|
|
133
133
|
<template v-if="cell.type === 'column'">
|
|
134
134
|
<template v-if="cell.customFunction">
|
|
@@ -271,7 +271,7 @@
|
|
|
271
271
|
:key="cellIndex"
|
|
272
272
|
:class=" calcTDBorder(cell.noBoarder) "
|
|
273
273
|
:colspan="cell.colSpan ? cell.colSpan : undefined"
|
|
274
|
-
:style="cell
|
|
274
|
+
:style="determineCellStyle(cell)"
|
|
275
275
|
:rowspan="cell.rowSpan ? cell.rowSpan : undefined">
|
|
276
276
|
<template v-if="cell.type === 'column'">
|
|
277
277
|
{{ cell.text }}
|
|
@@ -387,6 +387,17 @@ export default {
|
|
|
387
387
|
}
|
|
388
388
|
},
|
|
389
389
|
methods: {
|
|
390
|
+
determineCellStyle (cell) {
|
|
391
|
+
if (cell.style) {
|
|
392
|
+
return cell.style
|
|
393
|
+
}
|
|
394
|
+
if (cell.type === 'column') {
|
|
395
|
+
if (this.config.labelStyle !== undefined) {
|
|
396
|
+
return this.config.labelStyle
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
return undefined
|
|
400
|
+
},
|
|
390
401
|
handleInputDeepChange () {
|
|
391
402
|
this.$forceUpdate()
|
|
392
403
|
},
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
<!-- <XReport :config-name="'test_table_config_forEditor'" :dont-format="true"/>-->
|
|
17
17
|
<!-- <XReport config-name="test_tableConfig" :local-config="test_config_json" :config-data="test_config_json_data"/>-->
|
|
18
18
|
<!-- <XReport config-name="test_tableConfig" :local-config="test_yangchun" :config-data="test_yangchun_data" :show-title="false"/>-->
|
|
19
|
-
<XReport config-name="
|
|
19
|
+
<XReport config-name="report_ticket" :local-config="test" :config-data="test.testJsonData" :dont-format="true"/>
|
|
20
20
|
<a-button @click="testExport">导出</a-button>
|
|
21
21
|
</div>
|
|
22
22
|
</template>
|
|
@@ -1258,40 +1258,40 @@ export default {
|
|
|
1258
1258
|
// id: 35917,
|
|
1259
1259
|
// f_type: '改管维修'
|
|
1260
1260
|
// },
|
|
1261
|
-
test_upload: {
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
},
|
|
1261
|
+
// test_upload: {
|
|
1262
|
+
// slotsDefine: {},
|
|
1263
|
+
// subTitle: [],
|
|
1264
|
+
// slotsDeclare: [],
|
|
1265
|
+
// data: {
|
|
1266
|
+
// images: []
|
|
1267
|
+
// },
|
|
1268
|
+
// columns: [
|
|
1269
|
+
// [
|
|
1270
|
+
// {
|
|
1271
|
+
// rowSpan: 1,
|
|
1272
|
+
// colSpan: 12,
|
|
1273
|
+
// text: '测试上传',
|
|
1274
|
+
// originalRowIndex: 0,
|
|
1275
|
+
// type: 'column',
|
|
1276
|
+
// originalCellIndex: 0
|
|
1277
|
+
// }
|
|
1278
|
+
// ],
|
|
1279
|
+
// [
|
|
1280
|
+
// {
|
|
1281
|
+
// rowSpan: 1,
|
|
1282
|
+
// colSpan: 12,
|
|
1283
|
+
// dataIndex: 'imgs',
|
|
1284
|
+
// originalRowIndex: 1,
|
|
1285
|
+
// type: 'images',
|
|
1286
|
+
// originalCellIndex: 0
|
|
1287
|
+
// }
|
|
1288
|
+
// ]
|
|
1289
|
+
// ],
|
|
1290
|
+
// width: 'auto',
|
|
1291
|
+
// style: {},
|
|
1292
|
+
// title: '',
|
|
1293
|
+
// designMode: 'VisualTable'
|
|
1294
|
+
// },
|
|
1295
1295
|
// test_yulin_config: {
|
|
1296
1296
|
// slotsDefine: {},
|
|
1297
1297
|
// subTitle: [],
|
|
@@ -1415,46 +1415,83 @@ export default {
|
|
|
1415
1415
|
// }
|
|
1416
1416
|
// ]
|
|
1417
1417
|
// }
|
|
1418
|
-
test_data: {
|
|
1419
|
-
images: {
|
|
1420
|
-
serviceall: {
|
|
1421
|
-
imgs: []
|
|
1422
|
-
}
|
|
1423
|
-
}
|
|
1424
|
-
},
|
|
1425
1418
|
test: {
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
data: {
|
|
1430
|
-
'serviceall@@@imgs': []
|
|
1419
|
+
title: {
|
|
1420
|
+
type: 'titleKey',
|
|
1421
|
+
value: 'f_type'
|
|
1431
1422
|
},
|
|
1432
|
-
|
|
1433
|
-
|
|
1423
|
+
content: [
|
|
1424
|
+
{
|
|
1425
|
+
customFunctionForLabel: "function (config) {\n\treturn { type: 'key', content: 'f_project',\n style: {\n \"backgroundColor\": \"rgb(247,247,247)\",\n \t\t\"fontWeight\": \"bold\"\n }\n }\n}",
|
|
1426
|
+
customFunctionForValue: "function (config, item) {\n if (!item.f_content || item.f_content === null) {\n return { type: 'value', content: '无' }\n }else {\n return { type: 'key', content: 'f_content'}\n }\n}",
|
|
1427
|
+
jsonArrayDataIndex: 'details',
|
|
1428
|
+
type: 'jsonArray'
|
|
1429
|
+
}
|
|
1430
|
+
],
|
|
1431
|
+
designMode: 'json',
|
|
1432
|
+
testJsonData: {
|
|
1433
|
+
imgs: [],
|
|
1434
|
+
details: [
|
|
1434
1435
|
{
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
type: '
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1436
|
+
f_project: '旧表表号',
|
|
1437
|
+
f_service_id: 35917,
|
|
1438
|
+
f_is_must: 'false',
|
|
1439
|
+
id: 224392,
|
|
1440
|
+
type: 'string'
|
|
1441
|
+
},
|
|
1442
|
+
{
|
|
1443
|
+
f_project: '新表表号',
|
|
1444
|
+
f_service_id: 35917,
|
|
1445
|
+
f_is_must: 'false',
|
|
1446
|
+
id: 224393,
|
|
1447
|
+
type: 'string'
|
|
1448
|
+
},
|
|
1449
|
+
{
|
|
1450
|
+
f_project: '引入方式',
|
|
1451
|
+
f_service_id: 35917,
|
|
1452
|
+
f_is_must: 'false',
|
|
1453
|
+
id: 224394,
|
|
1454
|
+
type: 'selector'
|
|
1455
|
+
},
|
|
1456
|
+
{
|
|
1457
|
+
f_project: '是否高空作业',
|
|
1458
|
+
f_service_id: 35917,
|
|
1459
|
+
f_is_must: 'false',
|
|
1460
|
+
id: 224395,
|
|
1461
|
+
type: 'selector'
|
|
1462
|
+
},
|
|
1444
1463
|
{
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
type: '
|
|
1450
|
-
|
|
1464
|
+
f_project: '处理结果',
|
|
1465
|
+
f_service_id: 35917,
|
|
1466
|
+
f_is_must: 'false',
|
|
1467
|
+
id: 224396,
|
|
1468
|
+
type: 'selector'
|
|
1469
|
+
},
|
|
1470
|
+
{
|
|
1471
|
+
f_project: '位置',
|
|
1472
|
+
f_service_id: 35917,
|
|
1473
|
+
f_is_must: 'false',
|
|
1474
|
+
id: 224397,
|
|
1475
|
+
type: 'selector'
|
|
1476
|
+
},
|
|
1477
|
+
{
|
|
1478
|
+
f_project: '补装管卡',
|
|
1479
|
+
f_service_id: 35917,
|
|
1480
|
+
f_is_must: 'false',
|
|
1481
|
+
id: 224398,
|
|
1482
|
+
type: 'selector'
|
|
1483
|
+
},
|
|
1484
|
+
{
|
|
1485
|
+
f_project: '备注',
|
|
1486
|
+
f_service_id: 35917,
|
|
1487
|
+
f_is_must: 'false',
|
|
1488
|
+
id: 224399,
|
|
1489
|
+
type: 'string'
|
|
1451
1490
|
}
|
|
1452
|
-
]
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
designMode: 'VisualTable',
|
|
1457
|
-
title: ''
|
|
1491
|
+
],
|
|
1492
|
+
id: 35917,
|
|
1493
|
+
f_type: '改管维修'
|
|
1494
|
+
}
|
|
1458
1495
|
}
|
|
1459
1496
|
}
|
|
1460
1497
|
},
|