af-mobile-client-vue3 1.3.11 → 1.3.13
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/.claude/settings.local.json +10 -0
- package/.cursorrules +60 -60
- package/.editorconfig +9 -9
- package/.env +10 -10
- package/.env.development +1 -1
- package/.env.production +1 -1
- package/.node-version +1 -1
- package/.vscode/extensions.json +12 -12
- package/.vscode/settings.json +66 -66
- package/CLAUDE.md +189 -184
- package/README.md +182 -181
- package/af-example-mobile-vue-web.iml +9 -9
- package/build/vite/index.ts +98 -98
- package/build/vite/optimize.ts +34 -34
- package/build/vite/vconsole.ts +47 -47
- package/commitlint.config.ts +32 -32
- package/compress.js +36 -36
- package/eslint.config.ts +30 -30
- package/index.html +23 -23
- package/mock/data.ts +20 -20
- package/mock/index.ts +7 -7
- package/mock/modules/prose.mock.ts +13 -13
- package/mock/modules/user.mock.ts +152 -152
- package/mock/util.ts +19 -19
- package/netlify.toml +12 -12
- package/package.json +114 -114
- package/postcss.config.ts +27 -27
- package/public/favicon.svg +4 -4
- package/public/safari-pinned-tab.svg +4 -4
- package/scripts/verifyCommit.js +19 -19
- package/src/App.vue +79 -79
- package/src/api/mock/index.ts +30 -30
- package/src/api/user/index.ts +40 -40
- package/src/assets/img/user/login/background-shadow-1.svg +20 -20
- package/src/assets/img/user/login/logo-background.svg +20 -20
- package/src/bootstrap.ts +26 -26
- package/src/components/core/BeautifulLoading/index.vue +52 -52
- package/src/components/core/ImageUploader/index.vue +244 -244
- package/src/components/core/NavBar/index.vue +53 -53
- package/src/components/core/Tabbar/index.vue +32 -32
- package/src/components/core/Uploader/index.vue +124 -124
- package/src/components/core/XGridDropOption/index.vue +154 -156
- package/src/components/core/XMultiSelect/index.vue +183 -183
- package/src/components/core/XSelect/index.vue +149 -149
- package/src/components/data/InfoDisplay/index.vue +132 -0
- package/src/components/data/UserDetail/api.ts +24 -0
- package/src/components/data/UserDetail/index.vue +539 -0
- package/src/components/data/UserDetail/recordEntries.ts +159 -0
- package/src/components/data/UserDetail/types.ts +26 -0
- package/src/components/data/XBadge/index.vue +82 -82
- package/src/components/data/XCellDetail/index.vue +105 -105
- package/src/components/data/XCellList/XCellList.md +313 -313
- package/src/components/data/XCellList/index.vue +1075 -1075
- package/src/components/data/XCellListFilter/QrScanner/index.vue +207 -207
- package/src/components/data/XCellListFilter/QrScanner/startScanAnimation.ts +53 -53
- package/src/components/data/XCellListFilter/VpnRecognition/index.vue +119 -119
- package/src/components/data/XCellListFilter/index.vue +705 -705
- package/src/components/data/XForm/index.vue +659 -659
- package/src/components/data/XFormGroup/doc/DeviceForm.vue +121 -121
- package/src/components/data/XFormGroup/doc/FormGroupDemo.vue +56 -56
- package/src/components/data/XFormGroup/doc/README.md +286 -273
- package/src/components/data/XFormGroup/doc/UserForm.vue +101 -101
- package/src/components/data/XFormGroup/index.vue +240 -240
- package/src/components/data/XFormItem/index.vue +1310 -1310
- package/src/components/data/XOlMap/README.md +227 -227
- package/src/components/data/XOlMap/XLocationPicker/index.vue +226 -225
- package/src/components/data/XOlMap/index.vue +1490 -1490
- package/src/components/data/XOlMap/types.ts +149 -149
- package/src/components/data/XOlMap/utils/wgs84ToGcj02.js +154 -154
- package/src/components/data/XReportForm/DateTimeSecondsPicker.vue +208 -208
- package/src/components/data/XReportForm/XReportFormJsonRender.vue +220 -220
- package/src/components/data/XReportForm/index.vue +1393 -1393
- package/src/components/data/XReportGrid/XAddReport/XAddReport.vue +198 -198
- package/src/components/data/XReportGrid/XAddReport/index.js +3 -3
- package/src/components/data/XReportGrid/XAddReport/index.md +53 -52
- package/src/components/data/XReportGrid/XAddReport/index.ts +10 -10
- package/src/components/data/XReportGrid/XReport.vue +960 -960
- package/src/components/data/XReportGrid/XReportDesign.vue +597 -597
- package/src/components/data/XReportGrid/XReportDrawer/XReportDrawer.vue +148 -148
- package/src/components/data/XReportGrid/XReportDrawer/index.js +3 -3
- package/src/components/data/XReportGrid/XReportDrawer/index.ts +10 -10
- package/src/components/data/XReportGrid/XReportJsonRender.vue +399 -399
- package/src/components/data/XReportGrid/XReportTrGroup.vue +592 -592
- package/src/components/data/XReportGrid/index.md +46 -42
- package/src/components/data/XSignature/index.vue +284 -285
- package/src/components/data/XTag/index.vue +10 -10
- package/src/components/layout/NormalDataLayout/index.vue +69 -69
- package/src/components/layout/TabBarLayout/index.vue +40 -40
- package/src/composables/dark.ts +5 -5
- package/src/config/routes.ts +9 -9
- package/src/constants/index.ts +2 -2
- package/src/enums/requestEnum.ts +25 -25
- package/src/expression/ExpressionRunner.ts +28 -28
- package/src/expression/TestExpression.ts +510 -510
- package/src/expression/core/Delegate.ts +116 -116
- package/src/expression/core/Expression.ts +1359 -1359
- package/src/expression/core/Program.ts +985 -985
- package/src/expression/core/Token.ts +29 -29
- package/src/expression/enums/ExpressionType.ts +81 -81
- package/src/expression/enums/TokenType.ts +11 -11
- package/src/expression/exception/BreakWayException.ts +2 -2
- package/src/expression/exception/ContinueWayException.ts +2 -2
- package/src/expression/exception/ExpressionException.ts +29 -29
- package/src/expression/exception/ReturnWayException.ts +14 -14
- package/src/expression/exception/ServiceException.ts +22 -22
- package/src/expression/instances/JSONArray.ts +52 -52
- package/src/expression/instances/JSONObject.ts +118 -118
- package/src/expression/instances/LogicConsole.ts +31 -31
- package/src/font-style/font.css +4 -4
- package/src/hooks/useBoolean.ts +26 -0
- package/src/hooks/useCommon.ts +9 -9
- package/src/hooks/useLogin.ts +97 -97
- package/src/icons/svg/check-in.svg +32 -32
- package/src/icons/svg/dark.svg +4 -4
- package/src/icons/svg/github.svg +4 -4
- package/src/icons/svg/light.svg +4 -4
- package/src/icons/svg/link.svg +4 -4
- package/src/icons/svgo.yml +22 -22
- package/src/layout/GridView/index.vue +16 -16
- package/src/layout/PageLayout.vue +9 -9
- package/src/layout/SingleLayout.vue +9 -9
- package/src/locales/en-US.json +128 -128
- package/src/locales/zh-CN.json +128 -128
- package/src/logic/LogicRunner.ts +67 -67
- package/src/logic/TestLogic.ts +13 -13
- package/src/logic/plugins/common/DateTools.ts +35 -35
- package/src/logic/plugins/common/VueTools.ts +30 -30
- package/src/logic/plugins/index.ts +7 -7
- package/src/main.ts +44 -44
- package/src/plugins/AppData.ts +38 -38
- package/src/plugins/GetLoginInfoService.ts +10 -10
- package/src/plugins/collectIcons.ts +10 -0
- package/src/plugins/index.ts +11 -11
- package/src/router/README.md +8 -8
- package/src/router/guards.ts +59 -59
- package/src/router/index.ts +35 -35
- package/src/router/invoiceRoutes.ts +33 -33
- package/src/router/routes.ts +341 -171
- package/src/router/types.ts +7 -7
- package/src/services/api/Login.ts +6 -6
- package/src/services/api/common.ts +109 -109
- package/src/services/api/index.ts +7 -7
- package/src/services/api/manage.ts +8 -8
- package/src/services/api/search.ts +16 -16
- package/src/services/api/user.ts +17 -17
- package/src/services/restTools.ts +56 -56
- package/src/services/v3Api.ts +147 -147
- package/src/stores/index.ts +11 -11
- package/src/stores/modules/counter.ts +19 -19
- package/src/stores/modules/routeCache.ts +23 -23
- package/src/stores/modules/setting.ts +76 -76
- package/src/stores/modules/user.ts +235 -235
- package/src/stores/mutation-type.ts +7 -7
- package/src/styles/app.less +36 -36
- package/src/styles/login.less +109 -109
- package/src/styles/var.less +16 -16
- package/src/types/env.d.ts +16 -16
- package/src/types/settings.ts +1 -1
- package/src/types/vue-router.d.ts +9 -9
- package/src/utils/Storage.ts +124 -124
- package/src/utils/authority-utils.ts +84 -84
- package/src/utils/common.ts +41 -41
- package/src/utils/crypto.ts +39 -39
- package/src/utils/dataUtil.ts +42 -42
- package/src/utils/dictUtil.ts +52 -52
- package/src/utils/http/index.ts +199 -199
- package/src/utils/i18n.ts +72 -72
- package/src/utils/indexedDB.ts +195 -195
- package/src/utils/inline-px-to-vw.ts +28 -28
- package/src/utils/mobileUtil.ts +34 -34
- package/src/utils/progress.ts +19 -19
- package/src/utils/queryFormDefaultRangePicker.ts +57 -57
- package/src/utils/routerUtil.ts +271 -271
- package/src/utils/runEvalFunction.ts +13 -13
- package/src/utils/secureStorage.ts +71 -71
- package/src/utils/set-page-title.ts +5 -5
- package/src/utils/validate.ts +6 -6
- package/src/utils/wechatUtil.ts +9 -9
- package/src/views/chat/index.vue +153 -153
- package/src/views/common/LoadError.vue +63 -63
- package/src/views/common/NotFound.vue +67 -67
- package/src/views/component/EvaluateRecordView/index.vue +40 -40
- package/src/views/component/IconifyView/index.vue +504 -507
- package/src/views/component/UserDetailView/UserDetailPage.vue +77 -0
- package/src/views/component/UserDetailView/index.vue +224 -0
- package/src/views/component/XCellDetailView/index.vue +217 -217
- package/src/views/component/XCellListView/index.vue +108 -147
- package/src/views/component/XFormAppraiseView/index.vue +174 -174
- package/src/views/component/XFormGroupView/index.vue +78 -91
- package/src/views/component/XFormView/index.vue +27 -107
- package/src/views/component/XOlMapView/XLocationPicker/index.vue +118 -118
- package/src/views/component/XOlMapView/index.vue +434 -434
- package/src/views/component/XOlMapView/testData.ts +64 -64
- package/src/views/component/XReportFormIframeView/index.vue +47 -47
- package/src/views/component/XReportFormView/index.vue +13 -13
- package/src/views/component/XReportGridView/index.vue +17 -17
- package/src/views/component/XRequestView/index.vue +234 -234
- package/src/views/component/XSignatureView/index.vue +50 -50
- package/src/views/component/index.vue +181 -177
- package/src/views/component/menu.vue +117 -117
- package/src/views/component/notice.vue +46 -46
- package/src/views/component/topNav.vue +36 -36
- package/src/views/invoiceShow/index.vue +61 -61
- package/src/views/user/login/ForgetPasswordForm.vue +94 -94
- package/src/views/user/login/LoginForm.vue +346 -346
- package/src/views/user/login/LoginTitle.vue +76 -76
- package/src/views/user/login/LoginWave.vue +109 -109
- package/src/views/user/login/index.vue +22 -22
- package/src/views/user/my/comm/ModifyPassword.vue +346 -346
- package/src/views/user/my/index.vue +340 -340
- package/src/views/userRecords/AbnormalAlarmRecords.vue +21 -0
- package/src/views/userRecords/CardReplacementRecords.vue +21 -0
- package/src/views/userRecords/ChangeRecords.vue +19 -0
- package/src/views/userRecords/CommandViewRecords.vue +20 -0
- package/src/views/userRecords/GasCompensationRecords.vue +20 -0
- package/src/views/userRecords/InstrumentCollectionRecords.vue +21 -0
- package/src/views/userRecords/MeterRecords.vue +20 -0
- package/src/views/userRecords/OperateRecords.vue +51 -0
- package/src/views/userRecords/OtherChargeRecords.vue +19 -0
- package/src/views/userRecords/PaymentRecords.vue +28 -0
- package/src/views/userRecords/PriceAdjustmentRecords.vue +19 -0
- package/src/views/userRecords/ReplacementRecords.vue +19 -0
- package/src/views/userRecords/SafetyRecords.vue +19 -0
- package/src/views/userRecords/TransactionRecords.vue +21 -0
- package/src/views/userRecords/TransferRecords.vue +19 -0
- package/src/views/userRecords/operateRecordDetail/index.vue +316 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/AddUserDetail.vue +124 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/AdvanceDeliveryDetail.vue +88 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/AutoAccountsCancelDetail.vue +205 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/AutoAccountsDetail.vue +192 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/BankDkDetail.vue +192 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/BankPayDetail.vue +192 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/BlacklistDetail.vue +153 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/CancellationDetail.vue +101 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/CardMeterCenterCancelDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/CardMeterCenterDetail.vue +153 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/CardOverUserDetail.vue +153 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/ChangeMeterCancelDetail.vue +166 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/ChangeMeterDetail.vue +205 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/DisableManageDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/EnableManageDetail.vue +114 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/FaZheChangeDetail.vue +124 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/FeeDeductionDetail.vue +153 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/GasPriceChangeDetail.vue +126 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/InputtorChangeDetail.vue +126 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/IotMeterCenterCancelDetail.vue +114 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/IotMeterCenterDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/IotOpenDetail.vue +88 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/MachineCardDetail.vue +101 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/MachineMeterCenterCancelDetail.vue +218 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/MachineMeterCenterDetail.vue +153 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/OffGasAddGasDetail.vue +140 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/OtherChargeCancelDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/OtherChargeDetail.vue +114 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/OverUserChangeDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/ReBillDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/RefundDetail.vue +114 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/ReplaceCardManageCancelDetail.vue +127 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/ReplaceCardManageDetail.vue +114 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/SaleCardGasDetail.vue +140 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/TransferManageCancelDetail.vue +152 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/TransferManageDetail.vue +178 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/UserChangeDetail.vue +123 -0
- package/src/views/userRecords/operateRecordDetail/operateRecordDetails/WechatPayDetail.vue +192 -0
- package/src/views/userRecords/types.ts +66 -0
- package/tsconfig.json +39 -39
- package/uno.config.ts +82 -78
- package/vite.config.ts +118 -118
|
@@ -1,597 +1,597 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { getConfigByName } from '@af-mobile-client-vue3/services/api/common'
|
|
3
|
-
|
|
4
|
-
import { computed, onMounted, ref, watch } from 'vue'
|
|
5
|
-
import XReportJsonRender from './XReportJsonRender.vue'
|
|
6
|
-
import XReportTrGroup from './XReportTrGroup.vue'
|
|
7
|
-
|
|
8
|
-
// Props 类型定义
|
|
9
|
-
interface Props {
|
|
10
|
-
config: {
|
|
11
|
-
data: Record<string, any>
|
|
12
|
-
designMode?: string
|
|
13
|
-
width?: number
|
|
14
|
-
title?: string
|
|
15
|
-
style?: Record<string, string>
|
|
16
|
-
columns?: any[][]
|
|
17
|
-
subTitle?: Array<{
|
|
18
|
-
type: string
|
|
19
|
-
text?: string
|
|
20
|
-
format?: string
|
|
21
|
-
dataIndex?: string
|
|
22
|
-
inputWidth?: number
|
|
23
|
-
inputReadOnly?: boolean
|
|
24
|
-
}>
|
|
25
|
-
}
|
|
26
|
-
showImgInCell?: boolean
|
|
27
|
-
forDisplay?: boolean
|
|
28
|
-
serverName?: string
|
|
29
|
-
env?: string
|
|
30
|
-
displayOnly?: boolean
|
|
31
|
-
slotConfigName?: string
|
|
32
|
-
showImages?: boolean
|
|
33
|
-
imageList?: any[]
|
|
34
|
-
noPadding?: boolean
|
|
35
|
-
noTopBorder?: boolean
|
|
36
|
-
showTitle?: boolean
|
|
37
|
-
useOssForImg?: boolean
|
|
38
|
-
imgPrefix?: string
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
// Props
|
|
42
|
-
const props = withDefaults(defineProps<Props>(), {
|
|
43
|
-
serverName: 'af-system',
|
|
44
|
-
env: 'prod',
|
|
45
|
-
displayOnly: false,
|
|
46
|
-
noPadding: true,
|
|
47
|
-
noTopBorder: false,
|
|
48
|
-
showTitle: true,
|
|
49
|
-
useOssForImg: true,
|
|
50
|
-
})
|
|
51
|
-
|
|
52
|
-
// Emits
|
|
53
|
-
const emit = defineEmits(['updateImg', 'selectRow', 'slotRendered'])
|
|
54
|
-
|
|
55
|
-
// 注入
|
|
56
|
-
const isWidget = false // inject('isWidget', false)
|
|
57
|
-
|
|
58
|
-
// 状态
|
|
59
|
-
const data = ref(props.config.data || {})
|
|
60
|
-
const slotConfig = ref<any>()
|
|
61
|
-
const render = ref(false)
|
|
62
|
-
const activatedConfig = ref<any>({})
|
|
63
|
-
|
|
64
|
-
// 计算属性
|
|
65
|
-
const flexItemBodyState = computed(() => ({
|
|
66
|
-
padding: isWidget ? '0px' : '24px',
|
|
67
|
-
}))
|
|
68
|
-
|
|
69
|
-
// 方法
|
|
70
|
-
function slotRendered() {
|
|
71
|
-
emit('slotRendered')
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
function updateImg(data: any) {
|
|
75
|
-
emit('updateImg', data)
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
function selectRow(selectedRowKeys: any[], selectedRows: any[]) {
|
|
79
|
-
console.log('XReportDesign')
|
|
80
|
-
emit('selectRow', selectedRowKeys, selectedRows)
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
// 格式化相关方法
|
|
84
|
-
function calcFormatInputNum(formatStr: string) {
|
|
85
|
-
let count = 0
|
|
86
|
-
for (let i = 0; i < formatStr.length; i++) {
|
|
87
|
-
if (formatStr[i] === '{')
|
|
88
|
-
count++
|
|
89
|
-
}
|
|
90
|
-
return count
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
function displayFormatText(formatStr: string, num: number) {
|
|
94
|
-
let start = 0
|
|
95
|
-
let count = 0
|
|
96
|
-
num++
|
|
97
|
-
for (let i = 0; i < formatStr.length; i++) {
|
|
98
|
-
if (formatStr[i] === '}') {
|
|
99
|
-
start = i
|
|
100
|
-
count++
|
|
101
|
-
}
|
|
102
|
-
if (count === num) {
|
|
103
|
-
for (let j = start + 1; j < formatStr.length; j++) {
|
|
104
|
-
if (formatStr[j] === '{')
|
|
105
|
-
return formatStr.slice(start + 1, j)
|
|
106
|
-
|
|
107
|
-
if (j === formatStr.length - 1 && formatStr[j] !== '}')
|
|
108
|
-
return formatStr[j]
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
function displayFormatStartText(formatStr: string) {
|
|
115
|
-
let count = 0
|
|
116
|
-
for (let i = 0; i < formatStr.length; i++) {
|
|
117
|
-
if (formatStr[i] === '{')
|
|
118
|
-
break
|
|
119
|
-
count++
|
|
120
|
-
}
|
|
121
|
-
return formatStr.slice(0, count)
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
// 生命周期
|
|
125
|
-
onMounted(() => {
|
|
126
|
-
console.log('>>>> xreportdesign 渲染')
|
|
127
|
-
if (props.slotConfigName) {
|
|
128
|
-
getConfigByName(props.slotConfigName, (res: any) => {
|
|
129
|
-
slotConfig.value = res
|
|
130
|
-
res.data = { ...res.data, ...data.value }
|
|
131
|
-
// eslint-disable-next-line vue/no-mutating-props
|
|
132
|
-
props.config.data = res.data
|
|
133
|
-
activatedConfig.value = res
|
|
134
|
-
render.value = true
|
|
135
|
-
}, props.serverName)
|
|
136
|
-
}
|
|
137
|
-
else {
|
|
138
|
-
activatedConfig.value = props.config
|
|
139
|
-
render.value = true
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
if (activatedConfig.value.designMode !== 'json') {
|
|
143
|
-
activatedConfig.value.columns?.forEach((row: any[]) => {
|
|
144
|
-
if (row[0]?.type === 'list' && row[0]?.listLength === 1) {
|
|
145
|
-
row.forEach((cell) => {
|
|
146
|
-
cell.listLength = activatedConfig.value.data[cell.dataIndex].length
|
|
147
|
-
})
|
|
148
|
-
}
|
|
149
|
-
})
|
|
150
|
-
}
|
|
151
|
-
})
|
|
152
|
-
|
|
153
|
-
// 监听
|
|
154
|
-
watch(() => props.config, () => {
|
|
155
|
-
// 配置变化时的处理
|
|
156
|
-
}, { deep: true })
|
|
157
|
-
|
|
158
|
-
watch(() => activatedConfig.value, (val) => {
|
|
159
|
-
console.log('>>>> activatedConfig: ', val)
|
|
160
|
-
})
|
|
161
|
-
</script>
|
|
162
|
-
|
|
163
|
-
<template>
|
|
164
|
-
<div id="xreportdesign">
|
|
165
|
-
<template v-if="activatedConfig.designMode === 'json'">
|
|
166
|
-
<XReportJsonRender
|
|
167
|
-
:img-prefix="imgPrefix"
|
|
168
|
-
:server-name="serverName"
|
|
169
|
-
:display-only="displayOnly"
|
|
170
|
-
:show-title="showTitle"
|
|
171
|
-
:no-padding="noPadding"
|
|
172
|
-
:no-top-border="noTopBorder"
|
|
173
|
-
:config="activatedConfig"
|
|
174
|
-
@update-img="updateImg"
|
|
175
|
-
@select-row="selectRow"
|
|
176
|
-
/>
|
|
177
|
-
</template>
|
|
178
|
-
<template v-else-if="isWidget">
|
|
179
|
-
<template v-for="(row, rowIndex) in activatedConfig.columns">
|
|
180
|
-
<!-- 插槽展示 -->
|
|
181
|
-
<template v-if="row[0].type === 'slot'">
|
|
182
|
-
<XReportTrGroup
|
|
183
|
-
:key="rowIndex"
|
|
184
|
-
:show-img-in-cell="showImgInCell"
|
|
185
|
-
:img-prefix="imgPrefix"
|
|
186
|
-
:server-name="serverName"
|
|
187
|
-
:env="env"
|
|
188
|
-
:use-oss-for-img="useOssForImg"
|
|
189
|
-
:columns="row"
|
|
190
|
-
:no-top-border="noTopBorder"
|
|
191
|
-
:config-data="activatedConfig.data"
|
|
192
|
-
:config="activatedConfig"
|
|
193
|
-
:display="true"
|
|
194
|
-
@update-img="updateImg"
|
|
195
|
-
@select-row="selectRow"
|
|
196
|
-
/>
|
|
197
|
-
</template>
|
|
198
|
-
<!-- 普通行 -->
|
|
199
|
-
<template v-else>
|
|
200
|
-
<template v-if="!forDisplay">
|
|
201
|
-
<XReportTrGroup
|
|
202
|
-
:key="rowIndex"
|
|
203
|
-
:show-img-in-cell="showImgInCell"
|
|
204
|
-
:img-prefix="imgPrefix"
|
|
205
|
-
:server-name="serverName"
|
|
206
|
-
:env="env"
|
|
207
|
-
:use-oss-for-img="useOssForImg"
|
|
208
|
-
:columns="row"
|
|
209
|
-
:no-top-border="noTopBorder"
|
|
210
|
-
:config-data="activatedConfig.data"
|
|
211
|
-
:config="activatedConfig"
|
|
212
|
-
@update-img="updateImg"
|
|
213
|
-
/>
|
|
214
|
-
</template>
|
|
215
|
-
<template v-else>
|
|
216
|
-
<XReportTrGroup
|
|
217
|
-
:key="rowIndex"
|
|
218
|
-
:show-img-in-cell="showImgInCell"
|
|
219
|
-
:img-prefix="imgPrefix"
|
|
220
|
-
:server-name="serverName"
|
|
221
|
-
:env="env"
|
|
222
|
-
:use-oss-for-img="useOssForImg"
|
|
223
|
-
:config="activatedConfig"
|
|
224
|
-
:columns="row"
|
|
225
|
-
:no-top-border="noTopBorder"
|
|
226
|
-
:config-data="activatedConfig.data"
|
|
227
|
-
:display="true"
|
|
228
|
-
@update-img="updateImg"
|
|
229
|
-
@select-row="selectRow"
|
|
230
|
-
/>
|
|
231
|
-
</template>
|
|
232
|
-
</template>
|
|
233
|
-
</template>
|
|
234
|
-
</template>
|
|
235
|
-
<template v-else>
|
|
236
|
-
<div :class=" noPadding ? 'reportMainNoPadding' : 'reportMain'" :style="activatedConfig.width > 0 ? (`width:${activatedConfig.width}px`) : undefined">
|
|
237
|
-
<!-- 大标题 -->
|
|
238
|
-
<h2 v-if="showTitle && activatedConfig.title" class="reportTitle" v-html="activatedConfig.title" />
|
|
239
|
-
<!-- 小标题 / 介乎于标题与表格之间的内容 -->
|
|
240
|
-
<div v-if="activatedConfig.subTitle && activatedConfig.subTitle.length" class="subTitle">
|
|
241
|
-
<div v-for="(item, itemIndex) in activatedConfig.subTitle" :key="itemIndex" class="subTitleItems">
|
|
242
|
-
<template v-if="item.type === 'column'">
|
|
243
|
-
<span>{{ item.text }}</span>
|
|
244
|
-
</template>
|
|
245
|
-
<template v-else-if="item.type === 'inputs'">
|
|
246
|
-
<div class="inputsDiv">
|
|
247
|
-
<div v-for="(num, index) of calcFormatInputNum(item.format)" :key="index" class="inputsDivItem">
|
|
248
|
-
<span class="inputsDivItemLabel">{{ displayFormatStartText(item.format) }}</span>
|
|
249
|
-
<template v-if="!forDisplay">
|
|
250
|
-
<template v-if="item.inputReadOnly === true">
|
|
251
|
-
<van-field v-model="data[item.dataIndex][index]" :style="`width:${item.inputWidth ? item.inputWidth : '100'}%`" :disabled="true" />
|
|
252
|
-
</template>
|
|
253
|
-
<template v-else>
|
|
254
|
-
<van-field v-model="data[item.dataIndex][index]" :style="`width:${item.inputWidth ? item.inputWidth : '100'}%`" />
|
|
255
|
-
</template>
|
|
256
|
-
</template>
|
|
257
|
-
<template v-else>
|
|
258
|
-
{{ activatedConfig.data[item.dataIndex][index] }}
|
|
259
|
-
</template>
|
|
260
|
-
<span class="inputsDivItemLabel">{{ displayFormatText(item.format, index) }}</span>
|
|
261
|
-
</div>
|
|
262
|
-
</div>
|
|
263
|
-
</template>
|
|
264
|
-
</div>
|
|
265
|
-
</div>
|
|
266
|
-
<!-- 主体表格 -->
|
|
267
|
-
<table v-if="render" class="reportTable" :style="activatedConfig.style ? activatedConfig.style : undefined">
|
|
268
|
-
<tbody class="reportTable">
|
|
269
|
-
<template v-for="(row, rowIndex) in activatedConfig.columns">
|
|
270
|
-
<!-- 插槽展示 -->
|
|
271
|
-
<template v-if="row[0].type === 'slot'">
|
|
272
|
-
<XReportTrGroup
|
|
273
|
-
:key="rowIndex"
|
|
274
|
-
:show-img-in-cell="showImgInCell"
|
|
275
|
-
:img-prefix="imgPrefix"
|
|
276
|
-
:server-name="serverName"
|
|
277
|
-
:env="env"
|
|
278
|
-
:use-oss-for-img="useOssForImg"
|
|
279
|
-
:columns="row"
|
|
280
|
-
:no-top-border="noTopBorder"
|
|
281
|
-
:config-data="activatedConfig.data"
|
|
282
|
-
:config="activatedConfig"
|
|
283
|
-
:display="true"
|
|
284
|
-
@update-img="updateImg"
|
|
285
|
-
@select-row="selectRow"
|
|
286
|
-
@slot-rendered="slotRendered"
|
|
287
|
-
/>
|
|
288
|
-
</template>
|
|
289
|
-
<!-- 列表 list -->
|
|
290
|
-
<template v-else-if="row[0].type === 'list'">
|
|
291
|
-
<template v-for="(num, listIndex) in row[0].listLength + 1">
|
|
292
|
-
<template v-if="!forDisplay">
|
|
293
|
-
<XReportTrGroup
|
|
294
|
-
:key="rowIndex + listIndex"
|
|
295
|
-
:show-img-in-cell="showImgInCell"
|
|
296
|
-
:img-prefix="imgPrefix"
|
|
297
|
-
:server-name="serverName"
|
|
298
|
-
:env="env"
|
|
299
|
-
:use-oss-for-img="useOssForImg"
|
|
300
|
-
:config="activatedConfig"
|
|
301
|
-
:columns="row"
|
|
302
|
-
:no-top-border="noTopBorder"
|
|
303
|
-
:config-data="activatedConfig.data"
|
|
304
|
-
:list-index="listIndex"
|
|
305
|
-
@slot-rendered="slotRendered"
|
|
306
|
-
@update-img="updateImg"
|
|
307
|
-
@select-row="selectRow"
|
|
308
|
-
/>
|
|
309
|
-
</template>
|
|
310
|
-
<template v-else>
|
|
311
|
-
<XReportTrGroup
|
|
312
|
-
:key="rowIndex + listIndex"
|
|
313
|
-
:show-img-in-cell="showImgInCell"
|
|
314
|
-
:img-prefix="imgPrefix"
|
|
315
|
-
:server-name="serverName"
|
|
316
|
-
:env="env"
|
|
317
|
-
:use-oss-for-img="useOssForImg"
|
|
318
|
-
:config="activatedConfig"
|
|
319
|
-
:columns="row"
|
|
320
|
-
:no-top-border="noTopBorder"
|
|
321
|
-
:config-data="activatedConfig.data"
|
|
322
|
-
:list-index="listIndex"
|
|
323
|
-
:display="true"
|
|
324
|
-
@slot-rendered="slotRendered"
|
|
325
|
-
@update-img="updateImg"
|
|
326
|
-
@select-row="selectRow"
|
|
327
|
-
/>
|
|
328
|
-
</template>
|
|
329
|
-
</template>
|
|
330
|
-
</template>
|
|
331
|
-
<!-- 动态行 inputColumns -->
|
|
332
|
-
<template v-else-if="row[0].type === 'inputColumns'">
|
|
333
|
-
<template v-if="forDisplay">
|
|
334
|
-
<XReportTrGroup
|
|
335
|
-
v-for="(item, definitionIndex) in activatedConfig.data[row[0].dataIndex]"
|
|
336
|
-
:key="row[0].dataIndex + definitionIndex + rowIndex"
|
|
337
|
-
:show-img-in-cell="showImgInCell"
|
|
338
|
-
:img-prefix="imgPrefix"
|
|
339
|
-
:server-name="serverName"
|
|
340
|
-
:env="env"
|
|
341
|
-
:use-oss-for-img="useOssForImg"
|
|
342
|
-
:config="activatedConfig"
|
|
343
|
-
:columns="row[0].definition"
|
|
344
|
-
:config-data="{ arr: activatedConfig.data[row[0].dataIndex] }"
|
|
345
|
-
:input-columns="true"
|
|
346
|
-
:no-top-border="noTopBorder"
|
|
347
|
-
:input-columns-definition-index="definitionIndex"
|
|
348
|
-
:display="true"
|
|
349
|
-
@slot-rendered="slotRendered"
|
|
350
|
-
@update-img="updateImg"
|
|
351
|
-
@select-row="selectRow"
|
|
352
|
-
/>
|
|
353
|
-
</template>
|
|
354
|
-
<template v-if="!forDisplay">
|
|
355
|
-
<XReportTrGroup
|
|
356
|
-
v-for="(item, definitionIndex) in activatedConfig.data[row[0].dataIndex]"
|
|
357
|
-
:key="row[0].dataIndex + definitionIndex + rowIndex"
|
|
358
|
-
:show-img-in-cell="showImgInCell"
|
|
359
|
-
:img-prefix="imgPrefix"
|
|
360
|
-
:server-name="serverName"
|
|
361
|
-
:env="env"
|
|
362
|
-
:use-oss-for-img="useOssForImg"
|
|
363
|
-
:config="activatedConfig"
|
|
364
|
-
:columns="row[0].definition"
|
|
365
|
-
:config-data="{ arr: activatedConfig.data[row[0].dataIndex] }"
|
|
366
|
-
:input-columns="true"
|
|
367
|
-
:no-top-border="noTopBorder"
|
|
368
|
-
:input-columns-definition-index="definitionIndex"
|
|
369
|
-
@slot-rendered="slotRendered"
|
|
370
|
-
@update-img="updateImg"
|
|
371
|
-
@select-row="selectRow"
|
|
372
|
-
/>
|
|
373
|
-
<!-- 动态行交互按钮 -->
|
|
374
|
-
<XReportTrGroup
|
|
375
|
-
:key="rowIndex"
|
|
376
|
-
:show-img-in-cell="showImgInCell"
|
|
377
|
-
:img-prefix="imgPrefix"
|
|
378
|
-
:server-name="serverName"
|
|
379
|
-
:env="env"
|
|
380
|
-
:use-oss-for-img="useOssForImg"
|
|
381
|
-
:config="activatedConfig"
|
|
382
|
-
:columns="row"
|
|
383
|
-
:no-top-border="noTopBorder"
|
|
384
|
-
:config-data="activatedConfig.data"
|
|
385
|
-
:input-columns-button="true"
|
|
386
|
-
:input-columns="true"
|
|
387
|
-
@slot-rendered="slotRendered"
|
|
388
|
-
@update-img="updateImg"
|
|
389
|
-
@select-row="selectRow"
|
|
390
|
-
/>
|
|
391
|
-
</template>
|
|
392
|
-
</template>
|
|
393
|
-
<!-- 普通行 -->
|
|
394
|
-
<template v-else>
|
|
395
|
-
<template v-if="!forDisplay">
|
|
396
|
-
<XReportTrGroup
|
|
397
|
-
:key="rowIndex"
|
|
398
|
-
:show-img-in-cell="showImgInCell"
|
|
399
|
-
:img-prefix="imgPrefix"
|
|
400
|
-
:server-name="serverName"
|
|
401
|
-
:env="env"
|
|
402
|
-
:use-oss-for-img="useOssForImg"
|
|
403
|
-
:columns="row"
|
|
404
|
-
:no-top-border="noTopBorder"
|
|
405
|
-
:config-data="activatedConfig.data"
|
|
406
|
-
:config="activatedConfig"
|
|
407
|
-
@slot-rendered="slotRendered"
|
|
408
|
-
@update-img="updateImg"
|
|
409
|
-
@select-row="selectRow"
|
|
410
|
-
/>
|
|
411
|
-
</template>
|
|
412
|
-
<template v-else>
|
|
413
|
-
<XReportTrGroup
|
|
414
|
-
:key="rowIndex"
|
|
415
|
-
:show-img-in-cell="showImgInCell"
|
|
416
|
-
:img-prefix="imgPrefix"
|
|
417
|
-
:server-name="serverName"
|
|
418
|
-
:env="env"
|
|
419
|
-
:use-oss-for-img="useOssForImg"
|
|
420
|
-
:config="activatedConfig"
|
|
421
|
-
:columns="row"
|
|
422
|
-
:no-top-border="noTopBorder"
|
|
423
|
-
:config-data="activatedConfig.data"
|
|
424
|
-
:display="true"
|
|
425
|
-
@slot-rendered="slotRendered"
|
|
426
|
-
@update-img="updateImg"
|
|
427
|
-
@select-row="selectRow"
|
|
428
|
-
/>
|
|
429
|
-
</template>
|
|
430
|
-
</template>
|
|
431
|
-
</template>
|
|
432
|
-
</tbody>
|
|
433
|
-
</table>
|
|
434
|
-
<div v-if="showImages" style="margin-top: 5%; display: flex;margin-bottom: 5%">
|
|
435
|
-
<p>图片:</p>
|
|
436
|
-
<div v-for="(img, imgIndex) in imageList" :key="imgIndex" style="margin-left: 3%;width: 200px">
|
|
437
|
-
<img :src="img.url" class="img" :alt="img.name">
|
|
438
|
-
<p style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;width: 100%;">
|
|
439
|
-
{{ img.name }}
|
|
440
|
-
</p>
|
|
441
|
-
</div>
|
|
442
|
-
</div>
|
|
443
|
-
</div>
|
|
444
|
-
</template>
|
|
445
|
-
</div>
|
|
446
|
-
</template>
|
|
447
|
-
|
|
448
|
-
<style lang="less" scoped>
|
|
449
|
-
.img {
|
|
450
|
-
width: 95%;
|
|
451
|
-
height: 180px;
|
|
452
|
-
object-fit: cover;
|
|
453
|
-
}
|
|
454
|
-
.reportMain {
|
|
455
|
-
text-align: center;
|
|
456
|
-
margin: 0 auto;
|
|
457
|
-
font-size: 16px;
|
|
458
|
-
color: #000;
|
|
459
|
-
background-color: #fff;
|
|
460
|
-
border-radius: 8px;
|
|
461
|
-
|
|
462
|
-
.reportTitle {
|
|
463
|
-
font-weight: bold;
|
|
464
|
-
}
|
|
465
|
-
|
|
466
|
-
.subTitle {
|
|
467
|
-
display: flex;
|
|
468
|
-
justify-content: space-between;
|
|
469
|
-
margin-bottom: 1%;
|
|
470
|
-
|
|
471
|
-
.subTitleItems {
|
|
472
|
-
max-width: 30%;
|
|
473
|
-
}
|
|
474
|
-
}
|
|
475
|
-
|
|
476
|
-
.inputsDiv {
|
|
477
|
-
display: flex;
|
|
478
|
-
justify-content: space-between;
|
|
479
|
-
.inputsDivItem {
|
|
480
|
-
display: flex;
|
|
481
|
-
align-items: center;
|
|
482
|
-
padding: 0 4px;
|
|
483
|
-
white-space: nowrap;
|
|
484
|
-
.inputsDivItemLabel {
|
|
485
|
-
padding: 0 4px;
|
|
486
|
-
}
|
|
487
|
-
}
|
|
488
|
-
}
|
|
489
|
-
|
|
490
|
-
.reportTable {
|
|
491
|
-
width: 100%;
|
|
492
|
-
border-collapse: collapse;
|
|
493
|
-
table-layout: fixed;
|
|
494
|
-
word-break: break-all;
|
|
495
|
-
}
|
|
496
|
-
}
|
|
497
|
-
.reportMainForDisplay {
|
|
498
|
-
text-align: center;
|
|
499
|
-
margin: 10% auto;
|
|
500
|
-
font-size: 16px;
|
|
501
|
-
color: #000;
|
|
502
|
-
background-color: #fff;
|
|
503
|
-
border-radius: 8px;
|
|
504
|
-
|
|
505
|
-
.reportTitle {
|
|
506
|
-
font-weight: bold;
|
|
507
|
-
}
|
|
508
|
-
|
|
509
|
-
.subTitle {
|
|
510
|
-
display: flex;
|
|
511
|
-
justify-content: space-between;
|
|
512
|
-
|
|
513
|
-
.subTitleItems {
|
|
514
|
-
max-width: 30%;
|
|
515
|
-
}
|
|
516
|
-
}
|
|
517
|
-
|
|
518
|
-
.inputsDiv {
|
|
519
|
-
display: flex;
|
|
520
|
-
justify-content: space-around;
|
|
521
|
-
.inputsDivItem {
|
|
522
|
-
display: flex;
|
|
523
|
-
align-items: center;
|
|
524
|
-
padding: 0 4px;
|
|
525
|
-
white-space: nowrap;
|
|
526
|
-
.inputsDivItemLabel {
|
|
527
|
-
padding: 0 4px;
|
|
528
|
-
}
|
|
529
|
-
}
|
|
530
|
-
}
|
|
531
|
-
|
|
532
|
-
.reportTable {
|
|
533
|
-
width: 100%;
|
|
534
|
-
border-collapse: collapse;
|
|
535
|
-
table-layout: fixed;
|
|
536
|
-
word-break: break-all;
|
|
537
|
-
}
|
|
538
|
-
}
|
|
539
|
-
.reportMainNoPadding {
|
|
540
|
-
// text-align: center;
|
|
541
|
-
margin: 0 auto;
|
|
542
|
-
font-size: 16px;
|
|
543
|
-
color: #000;
|
|
544
|
-
// background-color: #fff;
|
|
545
|
-
border-radius: 8px;
|
|
546
|
-
height: auto;
|
|
547
|
-
min-height: 20vh;
|
|
548
|
-
overflow-y: auto;
|
|
549
|
-
overflow-x: hidden;
|
|
550
|
-
|
|
551
|
-
.reportTitle {
|
|
552
|
-
font-weight: bold;
|
|
553
|
-
}
|
|
554
|
-
|
|
555
|
-
.subTitle {
|
|
556
|
-
display: flex;
|
|
557
|
-
justify-content: space-between;
|
|
558
|
-
|
|
559
|
-
.subTitleItems {
|
|
560
|
-
max-width: 30%;
|
|
561
|
-
}
|
|
562
|
-
}
|
|
563
|
-
|
|
564
|
-
.inputsDiv {
|
|
565
|
-
display: flex;
|
|
566
|
-
justify-content: space-between;
|
|
567
|
-
.inputsDivItem {
|
|
568
|
-
display: flex;
|
|
569
|
-
align-items: center;
|
|
570
|
-
padding: 0 4px;
|
|
571
|
-
white-space: nowrap;
|
|
572
|
-
.inputsDivItemLabel {
|
|
573
|
-
padding: 0 4px;
|
|
574
|
-
}
|
|
575
|
-
}
|
|
576
|
-
}
|
|
577
|
-
|
|
578
|
-
.reportTable {
|
|
579
|
-
width: 100%;
|
|
580
|
-
border-collapse: collapse;
|
|
581
|
-
table-layout: fixed;
|
|
582
|
-
word-break: break-all;
|
|
583
|
-
}
|
|
584
|
-
}
|
|
585
|
-
.tools {
|
|
586
|
-
position: fixed;
|
|
587
|
-
right: 2%;
|
|
588
|
-
text-align: right;
|
|
589
|
-
width: 60%;
|
|
590
|
-
cursor: pointer;
|
|
591
|
-
.toolsItem {
|
|
592
|
-
width: 15%;
|
|
593
|
-
margin-right: 3%;
|
|
594
|
-
display: inline-block;
|
|
595
|
-
}
|
|
596
|
-
}
|
|
597
|
-
</style>
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { getConfigByName } from '@af-mobile-client-vue3/services/api/common'
|
|
3
|
+
|
|
4
|
+
import { computed, onMounted, ref, watch } from 'vue'
|
|
5
|
+
import XReportJsonRender from './XReportJsonRender.vue'
|
|
6
|
+
import XReportTrGroup from './XReportTrGroup.vue'
|
|
7
|
+
|
|
8
|
+
// Props 类型定义
|
|
9
|
+
interface Props {
|
|
10
|
+
config: {
|
|
11
|
+
data: Record<string, any>
|
|
12
|
+
designMode?: string
|
|
13
|
+
width?: number
|
|
14
|
+
title?: string
|
|
15
|
+
style?: Record<string, string>
|
|
16
|
+
columns?: any[][]
|
|
17
|
+
subTitle?: Array<{
|
|
18
|
+
type: string
|
|
19
|
+
text?: string
|
|
20
|
+
format?: string
|
|
21
|
+
dataIndex?: string
|
|
22
|
+
inputWidth?: number
|
|
23
|
+
inputReadOnly?: boolean
|
|
24
|
+
}>
|
|
25
|
+
}
|
|
26
|
+
showImgInCell?: boolean
|
|
27
|
+
forDisplay?: boolean
|
|
28
|
+
serverName?: string
|
|
29
|
+
env?: string
|
|
30
|
+
displayOnly?: boolean
|
|
31
|
+
slotConfigName?: string
|
|
32
|
+
showImages?: boolean
|
|
33
|
+
imageList?: any[]
|
|
34
|
+
noPadding?: boolean
|
|
35
|
+
noTopBorder?: boolean
|
|
36
|
+
showTitle?: boolean
|
|
37
|
+
useOssForImg?: boolean
|
|
38
|
+
imgPrefix?: string
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
// Props
|
|
42
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
43
|
+
serverName: 'af-system',
|
|
44
|
+
env: 'prod',
|
|
45
|
+
displayOnly: false,
|
|
46
|
+
noPadding: true,
|
|
47
|
+
noTopBorder: false,
|
|
48
|
+
showTitle: true,
|
|
49
|
+
useOssForImg: true,
|
|
50
|
+
})
|
|
51
|
+
|
|
52
|
+
// Emits
|
|
53
|
+
const emit = defineEmits(['updateImg', 'selectRow', 'slotRendered'])
|
|
54
|
+
|
|
55
|
+
// 注入
|
|
56
|
+
const isWidget = false // inject('isWidget', false)
|
|
57
|
+
|
|
58
|
+
// 状态
|
|
59
|
+
const data = ref(props.config.data || {})
|
|
60
|
+
const slotConfig = ref<any>()
|
|
61
|
+
const render = ref(false)
|
|
62
|
+
const activatedConfig = ref<any>({})
|
|
63
|
+
|
|
64
|
+
// 计算属性
|
|
65
|
+
const flexItemBodyState = computed(() => ({
|
|
66
|
+
padding: isWidget ? '0px' : '24px',
|
|
67
|
+
}))
|
|
68
|
+
|
|
69
|
+
// 方法
|
|
70
|
+
function slotRendered() {
|
|
71
|
+
emit('slotRendered')
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function updateImg(data: any) {
|
|
75
|
+
emit('updateImg', data)
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
function selectRow(selectedRowKeys: any[], selectedRows: any[]) {
|
|
79
|
+
console.log('XReportDesign')
|
|
80
|
+
emit('selectRow', selectedRowKeys, selectedRows)
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// 格式化相关方法
|
|
84
|
+
function calcFormatInputNum(formatStr: string) {
|
|
85
|
+
let count = 0
|
|
86
|
+
for (let i = 0; i < formatStr.length; i++) {
|
|
87
|
+
if (formatStr[i] === '{')
|
|
88
|
+
count++
|
|
89
|
+
}
|
|
90
|
+
return count
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
function displayFormatText(formatStr: string, num: number) {
|
|
94
|
+
let start = 0
|
|
95
|
+
let count = 0
|
|
96
|
+
num++
|
|
97
|
+
for (let i = 0; i < formatStr.length; i++) {
|
|
98
|
+
if (formatStr[i] === '}') {
|
|
99
|
+
start = i
|
|
100
|
+
count++
|
|
101
|
+
}
|
|
102
|
+
if (count === num) {
|
|
103
|
+
for (let j = start + 1; j < formatStr.length; j++) {
|
|
104
|
+
if (formatStr[j] === '{')
|
|
105
|
+
return formatStr.slice(start + 1, j)
|
|
106
|
+
|
|
107
|
+
if (j === formatStr.length - 1 && formatStr[j] !== '}')
|
|
108
|
+
return formatStr[j]
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
function displayFormatStartText(formatStr: string) {
|
|
115
|
+
let count = 0
|
|
116
|
+
for (let i = 0; i < formatStr.length; i++) {
|
|
117
|
+
if (formatStr[i] === '{')
|
|
118
|
+
break
|
|
119
|
+
count++
|
|
120
|
+
}
|
|
121
|
+
return formatStr.slice(0, count)
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// 生命周期
|
|
125
|
+
onMounted(() => {
|
|
126
|
+
console.log('>>>> xreportdesign 渲染')
|
|
127
|
+
if (props.slotConfigName) {
|
|
128
|
+
getConfigByName(props.slotConfigName, (res: any) => {
|
|
129
|
+
slotConfig.value = res
|
|
130
|
+
res.data = { ...res.data, ...data.value }
|
|
131
|
+
// eslint-disable-next-line vue/no-mutating-props
|
|
132
|
+
props.config.data = res.data
|
|
133
|
+
activatedConfig.value = res
|
|
134
|
+
render.value = true
|
|
135
|
+
}, props.serverName)
|
|
136
|
+
}
|
|
137
|
+
else {
|
|
138
|
+
activatedConfig.value = props.config
|
|
139
|
+
render.value = true
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
if (activatedConfig.value.designMode !== 'json') {
|
|
143
|
+
activatedConfig.value.columns?.forEach((row: any[]) => {
|
|
144
|
+
if (row[0]?.type === 'list' && row[0]?.listLength === 1) {
|
|
145
|
+
row.forEach((cell) => {
|
|
146
|
+
cell.listLength = activatedConfig.value.data[cell.dataIndex].length
|
|
147
|
+
})
|
|
148
|
+
}
|
|
149
|
+
})
|
|
150
|
+
}
|
|
151
|
+
})
|
|
152
|
+
|
|
153
|
+
// 监听
|
|
154
|
+
watch(() => props.config, () => {
|
|
155
|
+
// 配置变化时的处理
|
|
156
|
+
}, { deep: true })
|
|
157
|
+
|
|
158
|
+
watch(() => activatedConfig.value, (val) => {
|
|
159
|
+
console.log('>>>> activatedConfig: ', val)
|
|
160
|
+
})
|
|
161
|
+
</script>
|
|
162
|
+
|
|
163
|
+
<template>
|
|
164
|
+
<div id="xreportdesign">
|
|
165
|
+
<template v-if="activatedConfig.designMode === 'json'">
|
|
166
|
+
<XReportJsonRender
|
|
167
|
+
:img-prefix="imgPrefix"
|
|
168
|
+
:server-name="serverName"
|
|
169
|
+
:display-only="displayOnly"
|
|
170
|
+
:show-title="showTitle"
|
|
171
|
+
:no-padding="noPadding"
|
|
172
|
+
:no-top-border="noTopBorder"
|
|
173
|
+
:config="activatedConfig"
|
|
174
|
+
@update-img="updateImg"
|
|
175
|
+
@select-row="selectRow"
|
|
176
|
+
/>
|
|
177
|
+
</template>
|
|
178
|
+
<template v-else-if="isWidget">
|
|
179
|
+
<template v-for="(row, rowIndex) in activatedConfig.columns">
|
|
180
|
+
<!-- 插槽展示 -->
|
|
181
|
+
<template v-if="row[0].type === 'slot'">
|
|
182
|
+
<XReportTrGroup
|
|
183
|
+
:key="rowIndex"
|
|
184
|
+
:show-img-in-cell="showImgInCell"
|
|
185
|
+
:img-prefix="imgPrefix"
|
|
186
|
+
:server-name="serverName"
|
|
187
|
+
:env="env"
|
|
188
|
+
:use-oss-for-img="useOssForImg"
|
|
189
|
+
:columns="row"
|
|
190
|
+
:no-top-border="noTopBorder"
|
|
191
|
+
:config-data="activatedConfig.data"
|
|
192
|
+
:config="activatedConfig"
|
|
193
|
+
:display="true"
|
|
194
|
+
@update-img="updateImg"
|
|
195
|
+
@select-row="selectRow"
|
|
196
|
+
/>
|
|
197
|
+
</template>
|
|
198
|
+
<!-- 普通行 -->
|
|
199
|
+
<template v-else>
|
|
200
|
+
<template v-if="!forDisplay">
|
|
201
|
+
<XReportTrGroup
|
|
202
|
+
:key="rowIndex"
|
|
203
|
+
:show-img-in-cell="showImgInCell"
|
|
204
|
+
:img-prefix="imgPrefix"
|
|
205
|
+
:server-name="serverName"
|
|
206
|
+
:env="env"
|
|
207
|
+
:use-oss-for-img="useOssForImg"
|
|
208
|
+
:columns="row"
|
|
209
|
+
:no-top-border="noTopBorder"
|
|
210
|
+
:config-data="activatedConfig.data"
|
|
211
|
+
:config="activatedConfig"
|
|
212
|
+
@update-img="updateImg"
|
|
213
|
+
/>
|
|
214
|
+
</template>
|
|
215
|
+
<template v-else>
|
|
216
|
+
<XReportTrGroup
|
|
217
|
+
:key="rowIndex"
|
|
218
|
+
:show-img-in-cell="showImgInCell"
|
|
219
|
+
:img-prefix="imgPrefix"
|
|
220
|
+
:server-name="serverName"
|
|
221
|
+
:env="env"
|
|
222
|
+
:use-oss-for-img="useOssForImg"
|
|
223
|
+
:config="activatedConfig"
|
|
224
|
+
:columns="row"
|
|
225
|
+
:no-top-border="noTopBorder"
|
|
226
|
+
:config-data="activatedConfig.data"
|
|
227
|
+
:display="true"
|
|
228
|
+
@update-img="updateImg"
|
|
229
|
+
@select-row="selectRow"
|
|
230
|
+
/>
|
|
231
|
+
</template>
|
|
232
|
+
</template>
|
|
233
|
+
</template>
|
|
234
|
+
</template>
|
|
235
|
+
<template v-else>
|
|
236
|
+
<div :class=" noPadding ? 'reportMainNoPadding' : 'reportMain'" :style="activatedConfig.width > 0 ? (`width:${activatedConfig.width}px`) : undefined">
|
|
237
|
+
<!-- 大标题 -->
|
|
238
|
+
<h2 v-if="showTitle && activatedConfig.title" class="reportTitle" v-html="activatedConfig.title" />
|
|
239
|
+
<!-- 小标题 / 介乎于标题与表格之间的内容 -->
|
|
240
|
+
<div v-if="activatedConfig.subTitle && activatedConfig.subTitle.length" class="subTitle">
|
|
241
|
+
<div v-for="(item, itemIndex) in activatedConfig.subTitle" :key="itemIndex" class="subTitleItems">
|
|
242
|
+
<template v-if="item.type === 'column'">
|
|
243
|
+
<span>{{ item.text }}</span>
|
|
244
|
+
</template>
|
|
245
|
+
<template v-else-if="item.type === 'inputs'">
|
|
246
|
+
<div class="inputsDiv">
|
|
247
|
+
<div v-for="(num, index) of calcFormatInputNum(item.format)" :key="index" class="inputsDivItem">
|
|
248
|
+
<span class="inputsDivItemLabel">{{ displayFormatStartText(item.format) }}</span>
|
|
249
|
+
<template v-if="!forDisplay">
|
|
250
|
+
<template v-if="item.inputReadOnly === true">
|
|
251
|
+
<van-field v-model="data[item.dataIndex][index]" :style="`width:${item.inputWidth ? item.inputWidth : '100'}%`" :disabled="true" />
|
|
252
|
+
</template>
|
|
253
|
+
<template v-else>
|
|
254
|
+
<van-field v-model="data[item.dataIndex][index]" :style="`width:${item.inputWidth ? item.inputWidth : '100'}%`" />
|
|
255
|
+
</template>
|
|
256
|
+
</template>
|
|
257
|
+
<template v-else>
|
|
258
|
+
{{ activatedConfig.data[item.dataIndex][index] }}
|
|
259
|
+
</template>
|
|
260
|
+
<span class="inputsDivItemLabel">{{ displayFormatText(item.format, index) }}</span>
|
|
261
|
+
</div>
|
|
262
|
+
</div>
|
|
263
|
+
</template>
|
|
264
|
+
</div>
|
|
265
|
+
</div>
|
|
266
|
+
<!-- 主体表格 -->
|
|
267
|
+
<table v-if="render" class="reportTable" :style="activatedConfig.style ? activatedConfig.style : undefined">
|
|
268
|
+
<tbody class="reportTable">
|
|
269
|
+
<template v-for="(row, rowIndex) in activatedConfig.columns">
|
|
270
|
+
<!-- 插槽展示 -->
|
|
271
|
+
<template v-if="row[0].type === 'slot'">
|
|
272
|
+
<XReportTrGroup
|
|
273
|
+
:key="rowIndex"
|
|
274
|
+
:show-img-in-cell="showImgInCell"
|
|
275
|
+
:img-prefix="imgPrefix"
|
|
276
|
+
:server-name="serverName"
|
|
277
|
+
:env="env"
|
|
278
|
+
:use-oss-for-img="useOssForImg"
|
|
279
|
+
:columns="row"
|
|
280
|
+
:no-top-border="noTopBorder"
|
|
281
|
+
:config-data="activatedConfig.data"
|
|
282
|
+
:config="activatedConfig"
|
|
283
|
+
:display="true"
|
|
284
|
+
@update-img="updateImg"
|
|
285
|
+
@select-row="selectRow"
|
|
286
|
+
@slot-rendered="slotRendered"
|
|
287
|
+
/>
|
|
288
|
+
</template>
|
|
289
|
+
<!-- 列表 list -->
|
|
290
|
+
<template v-else-if="row[0].type === 'list'">
|
|
291
|
+
<template v-for="(num, listIndex) in row[0].listLength + 1">
|
|
292
|
+
<template v-if="!forDisplay">
|
|
293
|
+
<XReportTrGroup
|
|
294
|
+
:key="rowIndex + listIndex"
|
|
295
|
+
:show-img-in-cell="showImgInCell"
|
|
296
|
+
:img-prefix="imgPrefix"
|
|
297
|
+
:server-name="serverName"
|
|
298
|
+
:env="env"
|
|
299
|
+
:use-oss-for-img="useOssForImg"
|
|
300
|
+
:config="activatedConfig"
|
|
301
|
+
:columns="row"
|
|
302
|
+
:no-top-border="noTopBorder"
|
|
303
|
+
:config-data="activatedConfig.data"
|
|
304
|
+
:list-index="listIndex"
|
|
305
|
+
@slot-rendered="slotRendered"
|
|
306
|
+
@update-img="updateImg"
|
|
307
|
+
@select-row="selectRow"
|
|
308
|
+
/>
|
|
309
|
+
</template>
|
|
310
|
+
<template v-else>
|
|
311
|
+
<XReportTrGroup
|
|
312
|
+
:key="rowIndex + listIndex"
|
|
313
|
+
:show-img-in-cell="showImgInCell"
|
|
314
|
+
:img-prefix="imgPrefix"
|
|
315
|
+
:server-name="serverName"
|
|
316
|
+
:env="env"
|
|
317
|
+
:use-oss-for-img="useOssForImg"
|
|
318
|
+
:config="activatedConfig"
|
|
319
|
+
:columns="row"
|
|
320
|
+
:no-top-border="noTopBorder"
|
|
321
|
+
:config-data="activatedConfig.data"
|
|
322
|
+
:list-index="listIndex"
|
|
323
|
+
:display="true"
|
|
324
|
+
@slot-rendered="slotRendered"
|
|
325
|
+
@update-img="updateImg"
|
|
326
|
+
@select-row="selectRow"
|
|
327
|
+
/>
|
|
328
|
+
</template>
|
|
329
|
+
</template>
|
|
330
|
+
</template>
|
|
331
|
+
<!-- 动态行 inputColumns -->
|
|
332
|
+
<template v-else-if="row[0].type === 'inputColumns'">
|
|
333
|
+
<template v-if="forDisplay">
|
|
334
|
+
<XReportTrGroup
|
|
335
|
+
v-for="(item, definitionIndex) in activatedConfig.data[row[0].dataIndex]"
|
|
336
|
+
:key="row[0].dataIndex + definitionIndex + rowIndex"
|
|
337
|
+
:show-img-in-cell="showImgInCell"
|
|
338
|
+
:img-prefix="imgPrefix"
|
|
339
|
+
:server-name="serverName"
|
|
340
|
+
:env="env"
|
|
341
|
+
:use-oss-for-img="useOssForImg"
|
|
342
|
+
:config="activatedConfig"
|
|
343
|
+
:columns="row[0].definition"
|
|
344
|
+
:config-data="{ arr: activatedConfig.data[row[0].dataIndex] }"
|
|
345
|
+
:input-columns="true"
|
|
346
|
+
:no-top-border="noTopBorder"
|
|
347
|
+
:input-columns-definition-index="definitionIndex"
|
|
348
|
+
:display="true"
|
|
349
|
+
@slot-rendered="slotRendered"
|
|
350
|
+
@update-img="updateImg"
|
|
351
|
+
@select-row="selectRow"
|
|
352
|
+
/>
|
|
353
|
+
</template>
|
|
354
|
+
<template v-if="!forDisplay">
|
|
355
|
+
<XReportTrGroup
|
|
356
|
+
v-for="(item, definitionIndex) in activatedConfig.data[row[0].dataIndex]"
|
|
357
|
+
:key="row[0].dataIndex + definitionIndex + rowIndex"
|
|
358
|
+
:show-img-in-cell="showImgInCell"
|
|
359
|
+
:img-prefix="imgPrefix"
|
|
360
|
+
:server-name="serverName"
|
|
361
|
+
:env="env"
|
|
362
|
+
:use-oss-for-img="useOssForImg"
|
|
363
|
+
:config="activatedConfig"
|
|
364
|
+
:columns="row[0].definition"
|
|
365
|
+
:config-data="{ arr: activatedConfig.data[row[0].dataIndex] }"
|
|
366
|
+
:input-columns="true"
|
|
367
|
+
:no-top-border="noTopBorder"
|
|
368
|
+
:input-columns-definition-index="definitionIndex"
|
|
369
|
+
@slot-rendered="slotRendered"
|
|
370
|
+
@update-img="updateImg"
|
|
371
|
+
@select-row="selectRow"
|
|
372
|
+
/>
|
|
373
|
+
<!-- 动态行交互按钮 -->
|
|
374
|
+
<XReportTrGroup
|
|
375
|
+
:key="rowIndex"
|
|
376
|
+
:show-img-in-cell="showImgInCell"
|
|
377
|
+
:img-prefix="imgPrefix"
|
|
378
|
+
:server-name="serverName"
|
|
379
|
+
:env="env"
|
|
380
|
+
:use-oss-for-img="useOssForImg"
|
|
381
|
+
:config="activatedConfig"
|
|
382
|
+
:columns="row"
|
|
383
|
+
:no-top-border="noTopBorder"
|
|
384
|
+
:config-data="activatedConfig.data"
|
|
385
|
+
:input-columns-button="true"
|
|
386
|
+
:input-columns="true"
|
|
387
|
+
@slot-rendered="slotRendered"
|
|
388
|
+
@update-img="updateImg"
|
|
389
|
+
@select-row="selectRow"
|
|
390
|
+
/>
|
|
391
|
+
</template>
|
|
392
|
+
</template>
|
|
393
|
+
<!-- 普通行 -->
|
|
394
|
+
<template v-else>
|
|
395
|
+
<template v-if="!forDisplay">
|
|
396
|
+
<XReportTrGroup
|
|
397
|
+
:key="rowIndex"
|
|
398
|
+
:show-img-in-cell="showImgInCell"
|
|
399
|
+
:img-prefix="imgPrefix"
|
|
400
|
+
:server-name="serverName"
|
|
401
|
+
:env="env"
|
|
402
|
+
:use-oss-for-img="useOssForImg"
|
|
403
|
+
:columns="row"
|
|
404
|
+
:no-top-border="noTopBorder"
|
|
405
|
+
:config-data="activatedConfig.data"
|
|
406
|
+
:config="activatedConfig"
|
|
407
|
+
@slot-rendered="slotRendered"
|
|
408
|
+
@update-img="updateImg"
|
|
409
|
+
@select-row="selectRow"
|
|
410
|
+
/>
|
|
411
|
+
</template>
|
|
412
|
+
<template v-else>
|
|
413
|
+
<XReportTrGroup
|
|
414
|
+
:key="rowIndex"
|
|
415
|
+
:show-img-in-cell="showImgInCell"
|
|
416
|
+
:img-prefix="imgPrefix"
|
|
417
|
+
:server-name="serverName"
|
|
418
|
+
:env="env"
|
|
419
|
+
:use-oss-for-img="useOssForImg"
|
|
420
|
+
:config="activatedConfig"
|
|
421
|
+
:columns="row"
|
|
422
|
+
:no-top-border="noTopBorder"
|
|
423
|
+
:config-data="activatedConfig.data"
|
|
424
|
+
:display="true"
|
|
425
|
+
@slot-rendered="slotRendered"
|
|
426
|
+
@update-img="updateImg"
|
|
427
|
+
@select-row="selectRow"
|
|
428
|
+
/>
|
|
429
|
+
</template>
|
|
430
|
+
</template>
|
|
431
|
+
</template>
|
|
432
|
+
</tbody>
|
|
433
|
+
</table>
|
|
434
|
+
<div v-if="showImages" style="margin-top: 5%; display: flex;margin-bottom: 5%">
|
|
435
|
+
<p>图片:</p>
|
|
436
|
+
<div v-for="(img, imgIndex) in imageList" :key="imgIndex" style="margin-left: 3%;width: 200px">
|
|
437
|
+
<img :src="img.url" class="img" :alt="img.name">
|
|
438
|
+
<p style="overflow: hidden;text-overflow: ellipsis;white-space: nowrap;width: 100%;">
|
|
439
|
+
{{ img.name }}
|
|
440
|
+
</p>
|
|
441
|
+
</div>
|
|
442
|
+
</div>
|
|
443
|
+
</div>
|
|
444
|
+
</template>
|
|
445
|
+
</div>
|
|
446
|
+
</template>
|
|
447
|
+
|
|
448
|
+
<style lang="less" scoped>
|
|
449
|
+
.img {
|
|
450
|
+
width: 95%;
|
|
451
|
+
height: 180px;
|
|
452
|
+
object-fit: cover;
|
|
453
|
+
}
|
|
454
|
+
.reportMain {
|
|
455
|
+
text-align: center;
|
|
456
|
+
margin: 0 auto;
|
|
457
|
+
font-size: 16px;
|
|
458
|
+
color: #000;
|
|
459
|
+
background-color: #fff;
|
|
460
|
+
border-radius: 8px;
|
|
461
|
+
|
|
462
|
+
.reportTitle {
|
|
463
|
+
font-weight: bold;
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
.subTitle {
|
|
467
|
+
display: flex;
|
|
468
|
+
justify-content: space-between;
|
|
469
|
+
margin-bottom: 1%;
|
|
470
|
+
|
|
471
|
+
.subTitleItems {
|
|
472
|
+
max-width: 30%;
|
|
473
|
+
}
|
|
474
|
+
}
|
|
475
|
+
|
|
476
|
+
.inputsDiv {
|
|
477
|
+
display: flex;
|
|
478
|
+
justify-content: space-between;
|
|
479
|
+
.inputsDivItem {
|
|
480
|
+
display: flex;
|
|
481
|
+
align-items: center;
|
|
482
|
+
padding: 0 4px;
|
|
483
|
+
white-space: nowrap;
|
|
484
|
+
.inputsDivItemLabel {
|
|
485
|
+
padding: 0 4px;
|
|
486
|
+
}
|
|
487
|
+
}
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
.reportTable {
|
|
491
|
+
width: 100%;
|
|
492
|
+
border-collapse: collapse;
|
|
493
|
+
table-layout: fixed;
|
|
494
|
+
word-break: break-all;
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
.reportMainForDisplay {
|
|
498
|
+
text-align: center;
|
|
499
|
+
margin: 10% auto;
|
|
500
|
+
font-size: 16px;
|
|
501
|
+
color: #000;
|
|
502
|
+
background-color: #fff;
|
|
503
|
+
border-radius: 8px;
|
|
504
|
+
|
|
505
|
+
.reportTitle {
|
|
506
|
+
font-weight: bold;
|
|
507
|
+
}
|
|
508
|
+
|
|
509
|
+
.subTitle {
|
|
510
|
+
display: flex;
|
|
511
|
+
justify-content: space-between;
|
|
512
|
+
|
|
513
|
+
.subTitleItems {
|
|
514
|
+
max-width: 30%;
|
|
515
|
+
}
|
|
516
|
+
}
|
|
517
|
+
|
|
518
|
+
.inputsDiv {
|
|
519
|
+
display: flex;
|
|
520
|
+
justify-content: space-around;
|
|
521
|
+
.inputsDivItem {
|
|
522
|
+
display: flex;
|
|
523
|
+
align-items: center;
|
|
524
|
+
padding: 0 4px;
|
|
525
|
+
white-space: nowrap;
|
|
526
|
+
.inputsDivItemLabel {
|
|
527
|
+
padding: 0 4px;
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
|
|
532
|
+
.reportTable {
|
|
533
|
+
width: 100%;
|
|
534
|
+
border-collapse: collapse;
|
|
535
|
+
table-layout: fixed;
|
|
536
|
+
word-break: break-all;
|
|
537
|
+
}
|
|
538
|
+
}
|
|
539
|
+
.reportMainNoPadding {
|
|
540
|
+
// text-align: center;
|
|
541
|
+
margin: 0 auto;
|
|
542
|
+
font-size: 16px;
|
|
543
|
+
color: #000;
|
|
544
|
+
// background-color: #fff;
|
|
545
|
+
border-radius: 8px;
|
|
546
|
+
height: auto;
|
|
547
|
+
min-height: 20vh;
|
|
548
|
+
overflow-y: auto;
|
|
549
|
+
overflow-x: hidden;
|
|
550
|
+
|
|
551
|
+
.reportTitle {
|
|
552
|
+
font-weight: bold;
|
|
553
|
+
}
|
|
554
|
+
|
|
555
|
+
.subTitle {
|
|
556
|
+
display: flex;
|
|
557
|
+
justify-content: space-between;
|
|
558
|
+
|
|
559
|
+
.subTitleItems {
|
|
560
|
+
max-width: 30%;
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
.inputsDiv {
|
|
565
|
+
display: flex;
|
|
566
|
+
justify-content: space-between;
|
|
567
|
+
.inputsDivItem {
|
|
568
|
+
display: flex;
|
|
569
|
+
align-items: center;
|
|
570
|
+
padding: 0 4px;
|
|
571
|
+
white-space: nowrap;
|
|
572
|
+
.inputsDivItemLabel {
|
|
573
|
+
padding: 0 4px;
|
|
574
|
+
}
|
|
575
|
+
}
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
.reportTable {
|
|
579
|
+
width: 100%;
|
|
580
|
+
border-collapse: collapse;
|
|
581
|
+
table-layout: fixed;
|
|
582
|
+
word-break: break-all;
|
|
583
|
+
}
|
|
584
|
+
}
|
|
585
|
+
.tools {
|
|
586
|
+
position: fixed;
|
|
587
|
+
right: 2%;
|
|
588
|
+
text-align: right;
|
|
589
|
+
width: 60%;
|
|
590
|
+
cursor: pointer;
|
|
591
|
+
.toolsItem {
|
|
592
|
+
width: 15%;
|
|
593
|
+
margin-right: 3%;
|
|
594
|
+
display: inline-block;
|
|
595
|
+
}
|
|
596
|
+
}
|
|
597
|
+
</style>
|