cloud-web-corejs 1.0.54-dev.35 → 1.0.54-dev.350
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 +8 -3
- package/src/components/Qrcode/fileParse.vue +0 -1
- package/src/components/VabUpload/mixins.js +1 -1
- package/src/components/VabUpload/propertiesDialog.vue +1 -1
- package/src/components/VabUpload/view.vue +218 -120
- package/src/components/advancedSearchDialog/mixins.js +1 -1
- package/src/components/baseAttachment/index.vue +49 -40
- package/src/components/baseAttachment/mixins.js +1 -1
- package/src/components/baseInputExport/mixins.js +386 -1
- package/src/components/errorMsg/mixins.js +94 -5
- package/src/components/excelExport/button.vue +57 -4
- package/src/components/excelExport/exportFieldDialog.vue +16 -6
- package/src/components/excelExport/index.js +7 -5
- package/src/components/excelExport/index.vue +64 -8
- package/src/components/excelExport/mixins.js +3 -2
- package/src/components/excelImport/mixins.js +750 -1
- package/src/components/fileLibrary/fileObjAuthEditDialog.vue +6 -0
- package/src/components/fileLibrary/filterDialog.vue +383 -0
- package/src/components/fileLibrary/index.vue +23 -24
- package/src/components/fileLibrary/mixins/categoryMoveDialogMixins.js +1 -1
- package/src/components/fileLibrary/mixins/fileCategoryDialogMixins.js +1 -1
- package/src/components/fileLibrary/mixins/fileHistoryDialogMixins.js +2 -2
- package/src/components/fileLibrary/mixins/fileObjAuthDialogMixin.js +335 -212
- package/src/components/fileLibrary/mixins/fileObjAuthEditDialogMixin.js +31 -27
- package/src/components/fileLibrary/mixins/fileObjAuthEditMixin.js +4 -4
- package/src/components/fileLibrary/mixins/indexMixins.js +69 -26
- package/src/components/fileLibrary/mixins/propertiesDialogMixins.js +63 -3
- package/src/components/fileLibrary/mixins/recycleBinDialogMixins.js +1 -1
- package/src/components/fileLibrary/propertiesDialog.vue +18 -0
- package/src/components/fileLibrary/shareDialog.vue +1 -1
- package/src/components/formOplog/mixins.js +1 -1
- package/src/components/jsonImport/index.js +1 -1
- package/src/components/jsonImport/mixins.js +333 -1
- package/src/components/langImport/mixins.js +500 -16
- package/src/components/statusTag/mixins.js +1 -1
- package/src/components/table/CellSlot.vue +1 -0
- package/src/components/table/index.js +12 -10
- package/src/components/table/tableForm.vue +99 -63
- package/src/components/table/tableFormMixin.js +1 -1
- package/src/components/table/util/index.js +328 -0
- package/src/components/table/vxeFilter/mixin.js +6 -6
- package/src/components/tempStorage/index.vue +9 -6
- package/src/components/tempStorage/tempStorageDialog.vue +1 -1
- package/src/components/vb-tabs/x-tabs.vue +3 -2
- package/src/components/wf/addOpinionButton.vue +57 -0
- package/src/components/wf/content.vue +833 -362
- package/src/components/wf/mixins/addOpinionButton.js +3 -0
- package/src/components/wf/mixins/setCandidateButton.js +6 -0
- package/src/components/wf/mixins/setCandidateDialog.js +2 -1
- package/src/components/wf/mixins/setCandidateDialog2.js +6 -0
- package/src/components/wf/mixins/wfFlowEleScriptDialog.js +131 -0
- package/src/components/wf/mixins/wfTaskUserRangeDialog.js +3 -0
- package/src/components/wf/setCandidateButton.vue +40 -0
- package/src/components/wf/setCandidateDialog.vue +10 -0
- package/src/components/wf/setCandidateDialog2.vue +95 -0
- package/src/components/wf/wf.js +2117 -1
- package/src/components/wf/wfFlowEleScriptDialog.vue +89 -0
- package/src/components/wf/wfStartDialog.vue +70 -42
- package/src/components/wf/wfTaskUserRangeDialog.vue +65 -0
- package/src/components/wf/wfUtil.js +1 -1
- package/src/components/xform/form-designer/designer.js +1649 -3
- package/src/components/xform/form-designer/form-widget/container-widget/containerMixin.js +3 -3
- package/src/components/xform/form-designer/form-widget/container-widget/data-table-mixin.js +289 -8
- package/src/components/xform/form-designer/form-widget/container-widget/data-table-widget.vue +4 -1
- package/src/components/xform/form-designer/form-widget/container-widget/detail-widget.vue +3 -3
- package/src/components/xform/form-designer/form-widget/dialog/exportDialog.vue +13 -0
- package/src/components/xform/form-designer/form-widget/dialog/fileReferenceDialog.vue +301 -0
- package/src/components/xform/form-designer/form-widget/dialog/formDialog.vue +16 -4
- package/src/components/xform/form-designer/form-widget/dialog/formDrawer.vue +5 -1
- package/src/components/xform/form-designer/form-widget/dialog/importDialog.vue +37 -6
- package/src/components/xform/form-designer/form-widget/dialog/importDialogMixin.js +1331 -1
- package/src/components/xform/form-designer/form-widget/dialog/searchFormDialog.vue +26 -7
- package/src/components/xform/form-designer/form-widget/field-widget/a-link-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/a-text-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/baseAttachment-widget.vue +34 -5
- package/src/components/xform/form-designer/form-widget/field-widget/button-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/checkbox-widget.vue +14 -6
- package/src/components/xform/form-designer/form-widget/field-widget/copy_button-widget.vue +89 -0
- package/src/components/xform/form-designer/form-widget/field-widget/date-range-widget.vue +1 -0
- package/src/components/xform/form-designer/form-widget/field-widget/date-widget.vue +21 -2
- package/src/components/xform/form-designer/form-widget/field-widget/dropdown-item-widget.vue +77 -0
- package/src/components/xform/form-designer/form-widget/field-widget/dropdown-menu-widget.vue +106 -0
- package/src/components/xform/form-designer/form-widget/field-widget/echart-bar-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/echart-category-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/echart-pie-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/fieldMixin.js +1615 -16
- package/src/components/xform/form-designer/form-widget/field-widget/form-item-wrapper.vue +652 -379
- package/src/components/xform/form-designer/form-widget/field-widget/import-button-widget.vue +10 -8
- package/src/components/xform/form-designer/form-widget/field-widget/import2-button-widget.vue +81 -0
- package/src/components/xform/form-designer/form-widget/field-widget/mixins/echart-bar-mixin.js +49 -8
- package/src/components/xform/form-designer/form-widget/field-widget/mixins/echart-category-mixin.js +61 -88
- package/src/components/xform/form-designer/form-widget/field-widget/mixins/echart-pie-mixin.js +13 -0
- package/src/components/xform/form-designer/form-widget/field-widget/mixins/vabsearch-mixin.js +176 -0
- package/src/components/xform/form-designer/form-widget/field-widget/multiSearch-widget.vue +53 -0
- package/src/components/xform/form-designer/form-widget/field-widget/number-widget.vue +107 -81
- package/src/components/xform/form-designer/form-widget/field-widget/oplog-widget.vue +185 -0
- package/src/components/xform/form-designer/form-widget/field-widget/print-button-widget.vue +1 -1
- package/src/components/xform/form-designer/form-widget/field-widget/print-detail-button-widget.vue +108 -0
- package/src/components/xform/form-designer/form-widget/field-widget/project-tag-widget.vue +70 -3
- package/src/components/xform/form-designer/form-widget/field-widget/radio-widget.vue +21 -5
- package/src/components/xform/form-designer/form-widget/field-widget/search_button-widget.vue +2 -2
- package/src/components/xform/form-designer/form-widget/field-widget/select-export-button-widget.vue +86 -0
- package/src/components/xform/form-designer/form-widget/field-widget/select-widget.vue +17 -5
- package/src/components/xform/form-designer/form-widget/field-widget/singerSearch-widget.vue +53 -0
- package/src/components/xform/form-designer/form-widget/field-widget/singleUpload-widget.vue +145 -0
- package/src/components/xform/form-designer/form-widget/field-widget/static-content-wrapper.vue +2 -1
- package/src/components/xform/form-designer/form-widget/field-widget/status-widget.vue +31 -17
- package/src/components/xform/form-designer/form-widget/field-widget/table-export-button-widget.vue +6 -1
- package/src/components/xform/form-designer/form-widget/field-widget/tableexportbuttonwidget.vue +99 -0
- package/src/components/xform/form-designer/form-widget/field-widget/tempStorage-widget.vue +127 -0
- package/src/components/xform/form-designer/form-widget/field-widget/text-widget.vue +46 -34
- package/src/components/xform/form-designer/form-widget/field-widget/time-range-widget.vue +2 -2
- package/src/components/xform/form-designer/form-widget/field-widget/vabSearch-widget.vue +2 -170
- package/src/components/xform/form-designer/form-widget/field-widget/vabUpload-widget.vue +259 -58
- package/src/components/xform/form-designer/form-widget/field-widget/vabUpload2-widget.vue +725 -0
- package/src/components/xform/form-designer/indexMixin.js +825 -2
- package/src/components/xform/form-designer/setting-panel/form-setting.vue +927 -159
- package/src/components/xform/form-designer/setting-panel/index.vue +4 -0
- package/src/components/xform/form-designer/setting-panel/indexMixin.js +1 -1
- package/src/components/xform/form-designer/setting-panel/option-items-setting.vue +376 -302
- package/src/components/xform/form-designer/setting-panel/property-editor/a-link-editor.vue +4 -4
- package/src/components/xform/form-designer/setting-panel/property-editor/a-text-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/autoValueEnabled-editor.vue +38 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/censusClass-editor.vue +6 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/colorClass-editor.vue +28 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/commonAttributeEnabled-editor.vue +41 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/columnRenderDialog.vue +126 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/data-table-editor.vue +1196 -1042
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/onCheckboxChange-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-data-table/table-column-dialog.vue +1160 -511
- package/src/components/xform/form-designer/setting-panel/property-editor/container-detail/detail-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/container-detail-pane/detail-pane-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-offset-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-pull-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-grid-col/grid-col-push-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/container-list-h5/list-h5-editor.vue +0 -8
- package/src/components/xform/form-designer/setting-panel/property-editor/copyButton-editor.vue +36 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/event-handler/eventMixin.js +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/event-handler/onAfterConfirmFile-editor.vue +32 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/event-handler/onClick-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/clickBindEvent-editor.vue +35 -20
- package/src/components/xform/form-designer/setting-panel/property-editor/field-button/search-dialog-event-editor.vue +64 -5
- package/src/components/xform/form-designer/setting-panel/property-editor/field-date-range/date-range-defaultTime-editor.vue +27 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-dropdown-menu/dropdown-item-editor.vue +21 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-dropdown-menu/dropdown-menu-editor.vue +59 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-bar-editor.vue +185 -69
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-category-editor.vue +188 -86
- package/src/components/xform/form-designer/setting-panel/property-editor/field-echart/echart-pie-editor.vue +84 -39
- package/src/components/xform/form-designer/setting-panel/property-editor/field-import-button/import-button-editor.vue +32 -9
- package/src/components/xform/form-designer/setting-panel/property-editor/field-import-button/import2-button-editor.vue +86 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-print-button/print-button-editor.vue +8 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-print-button/print-detail-button-editor.vue +91 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-rate/rate-defaultValue-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-status/field-status-editor.vue +67 -41
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/select-export-button-editor.vue +56 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/field-table-export-button/table-export-button-editor.vue +26 -7
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabSearch/vabSearchName-editor.vue +13 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabUpload/field-vabUpload-editor.vue +30 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/field-vabUpload2/field-vabUpload2-editor.vue +62 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/formScriptEnabled-editor.vue +52 -5
- package/src/components/xform/form-designer/setting-panel/property-editor/formula-editor.vue +721 -466
- package/src/components/xform/form-designer/setting-panel/property-editor/labelColor-editor.vue +20 -11
- package/src/components/xform/form-designer/setting-panel/property-editor/labelIconClass-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelIconPosition-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/labelTooltip-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/limit-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/multiple-editor.vue +19 -14
- package/src/components/xform/form-designer/setting-panel/property-editor/multipleLimit-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/oplog-editor.vue +31 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/precision-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/project-tag-editor.vue +318 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/required-editor.vue +10 -6
- package/src/components/xform/form-designer/setting-panel/property-editor/requiredHint-editor.vue +3 -3
- package/src/components/xform/form-designer/setting-panel/property-editor/showRuleFlag-editor.vue +1 -1
- package/src/components/xform/form-designer/setting-panel/property-editor/tempStorage-editor.vue +23 -0
- package/src/components/xform/form-designer/setting-panel/property-editor/textFlag-editor.vue +305 -19
- package/src/components/xform/form-designer/setting-panel/property-editor/validation-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/validationHint-editor.vue +2 -2
- package/src/components/xform/form-designer/setting-panel/property-editor/wfFlag-editor.vue +384 -53
- package/src/components/xform/form-designer/setting-panel/property-editor/widgetShowRuleFlag-editor.vue +263 -0
- package/src/components/xform/form-designer/setting-panel/propertyRegister.js +30 -11
- package/src/components/xform/form-designer/toolbar-panel/index.vue +12 -11
- package/src/components/xform/form-designer/toolbar-panel/indexMixin.js +1 -1
- package/src/components/xform/form-designer/widget-panel/index.vue +21 -1
- package/src/components/xform/form-designer/widget-panel/indexMixin.js +19 -18
- package/src/components/xform/form-designer/widget-panel/widgetsConfig.js +1576 -874
- package/src/components/xform/form-render/container-item/containerItemMixin.js +359 -11
- package/src/components/xform/form-render/container-item/data-table-item.vue +89 -42
- package/src/components/xform/form-render/container-item/data-table-mixin.js +2728 -18
- package/src/components/xform/form-render/container-item/detail-pane-item.vue +17 -3
- package/src/components/xform/form-render/container-item/grid-col-item.vue +10 -3
- package/src/components/xform/form-render/container-item/grid-item.vue +1 -1
- package/src/components/xform/form-render/container-item/list-h5-item.vue +1 -9
- package/src/components/xform/form-render/container-item/list-h5-item2.vue +1 -8
- package/src/components/xform/form-render/container-item/tab-item.vue +11 -6
- package/src/components/xform/form-render/container-item/table-cell-item.vue +38 -32
- package/src/components/xform/form-render/container-item/table-item.vue +4 -2
- package/src/components/xform/form-render/index.vue +4 -1
- package/src/components/xform/form-render/indexMixin.js +3129 -4
- package/src/components/xform/lang/zh-CN.js +20 -3
- package/src/components/xform/mixins/defaultHandle.js +1 -1
- package/src/components/xform/mixins/scriptHttp.js +175 -1
- package/src/components/xform/utils/emitter.js +4 -4
- package/src/components/xform/utils/format.js +21 -30
- package/src/components/xform/utils/formula-util.js +669 -0
- package/src/components/xform/utils/util.js +1451 -1
- package/src/components/xform/utils/validators.js +1 -5
- package/src/index.js +2 -2
- package/src/layout/components/AppMain.vue +5 -1
- package/src/layout/components/Sidebar/default.vue +50 -6
- package/src/layout/components/TagsView/index.vue +37 -12
- package/src/layout/components/extractedCode/createDialog.vue +92 -0
- package/src/layout/components/extractedCode/queryDialog.vue +96 -0
- package/src/layout/components/extractedCode/viewDialog.vue +193 -0
- package/src/layout/components/watermark/index.vue +83 -0
- package/src/layout/defaultLayout.vue +1 -1
- package/src/mixins/selectDialog/index.js +1 -1
- package/src/mixins/tableTree/index.js +1 -1
- package/src/router/modules/customer.js +61 -8
- package/src/store/config/index.js +1 -532
- package/src/store/modules/permission.js +1 -1
- package/src/store/modules/settings.js +1 -1
- package/src/store/modules/tagsView.js +1 -14
- package/src/store/modules/user.js +1 -1
- package/src/utils/index.js +2 -3
- package/src/utils/pddLog.js +103 -0
- package/src/utils/pdfUtil.js +71 -0
- package/src/utils/request.js +359 -1
- package/src/utils/vab.js +1113 -27
- package/src/views/bd/setting/bd_attach_setting/edit.vue +5 -5
- package/src/views/bd/setting/bd_attach_setting/list.vue +28 -55
- package/src/views/bd/setting/bd_attach_setting/mixins/edit.js +4 -5
- package/src/views/bd/setting/bd_attach_setting/mixins/list.js +239 -1
- package/src/views/bd/setting/bd_company_env/dialog.vue +174 -0
- package/src/views/bd/setting/bd_company_env/edit.vue +193 -0
- package/src/views/bd/setting/bd_company_env/list.vue +175 -0
- package/src/views/bd/setting/config_manage/list.vue +66 -0
- package/src/views/bd/setting/form_import_log/edit.vue +127 -0
- package/src/views/bd/setting/form_import_log/list.vue +206 -0
- package/src/views/bd/setting/form_script/edit.vue +9 -0
- package/src/views/bd/setting/form_script/edit1.vue +36 -3
- package/src/views/bd/setting/form_script/form_list.vue +1 -1
- package/src/views/bd/setting/form_script/list1.vue +4 -4
- package/src/views/bd/setting/form_script/mixins/dialog.js +130 -1
- package/src/views/bd/setting/form_script/mixins/edit.js +201 -1
- package/src/views/bd/setting/form_script/mixins/edit1.js +193 -1
- package/src/views/bd/setting/form_script/mixins/form_list.js +1 -1
- package/src/views/bd/setting/form_script/mixins/list.js +236 -1
- package/src/views/bd/setting/form_script/mixins/list1.js +423 -14
- package/src/views/bd/setting/form_script/mixins/otherAuthDialog.js +194 -0
- package/src/views/bd/setting/form_script/otherAuthDialog.vue +83 -0
- package/src/views/bd/setting/form_template/batchWfObjConfigDialog.vue +105 -0
- package/src/views/bd/setting/form_template/edit.vue +22 -1
- package/src/views/bd/setting/form_template/editWfObjConfigDialog.vue +2 -2
- package/src/views/bd/setting/form_template/list.vue +5 -5
- package/src/views/bd/setting/form_template/mixins/batchWfObjConfigDialog.js +282 -0
- package/src/views/bd/setting/form_template/mixins/edit.js +234 -9
- package/src/views/bd/setting/form_template/mixins/list.js +689 -22
- package/src/views/bd/setting/form_template/mixins/otherAuthDialog.js +193 -0
- package/src/views/bd/setting/form_template/mixins/wf_list.js +12 -0
- package/src/views/bd/setting/form_template/otherAuthDialog.vue +83 -0
- package/src/views/bd/setting/form_template/wfObjConfigDialog.vue +140 -75
- package/src/views/bd/setting/form_template/{list2.vue → wf_list.vue} +25 -35
- package/src/views/bd/setting/logic_param/edit.vue +146 -0
- package/src/views/bd/setting/logic_param/edit1.vue +106 -0
- package/src/views/bd/setting/logic_param/edit2.vue +122 -0
- package/src/views/bd/setting/logic_param/list.vue +74 -0
- package/src/views/bd/setting/logic_param/list1.vue +12 -0
- package/src/views/bd/setting/logic_param/list2.vue +12 -0
- package/src/views/bd/setting/logic_param/mixins/edit.js +93 -0
- package/src/views/bd/setting/logic_param/mixins/list.js +358 -0
- package/src/views/bd/setting/menu_kind/list.vue +4 -0
- package/src/views/bd/setting/menu_kind/mixins/authDialog.js +300 -7
- package/src/views/bd/setting/menu_kind/mixins/list.js +201 -1
- package/src/views/bd/setting/push_data/edit.vue +139 -0
- package/src/views/bd/setting/push_data/list.vue +283 -0
- package/src/views/bd/setting/push_data_h/edit.vue +153 -0
- package/src/views/bd/setting/push_data_h/list.vue +293 -0
- package/src/views/bd/setting/request_async_setting/edit.vue +320 -0
- package/src/views/bd/setting/request_async_setting/list.vue +372 -0
- package/src/views/bd/setting/request_setting/edit.vue +300 -0
- package/src/views/bd/setting/request_setting/list.vue +311 -0
- package/src/views/bd/setting/table_model/edit.vue +875 -426
- package/src/views/bd/setting/table_model/list.vue +4 -4
- package/src/views/bd/setting/table_model/mixins/dialog.js +1 -1
- package/src/views/bd/setting/table_model/mixins/edit.js +1202 -13
- package/src/views/bd/setting/table_model/mixins/list.js +440 -14
- package/src/views/bd/setting/table_model/mixins/otherAuthDialog.js +201 -0
- package/src/views/bd/setting/table_model/otherAuthDialog.vue +83 -0
- package/src/views/user/area/dialog.vue +21 -9
- package/src/views/user/bill_setting/edit.vue +1 -1
- package/src/views/user/bill_setting/list.vue +1 -1
- package/src/views/user/common_attribute/itemEdit.vue +2 -2
- package/src/views/user/common_attribute/list.vue +1 -1
- package/src/views/user/common_script/edit.vue +1 -1
- package/src/views/user/common_script/list.vue +1 -1
- package/src/views/user/company_info/dialog.vue +164 -154
- package/src/views/user/company_info/edit.vue +1 -1
- package/src/views/user/extend_datasource/dialog.vue +1 -0
- package/src/views/user/extend_datasource/edit.vue +3 -0
- package/src/views/user/extend_datasource/list.vue +2 -1
- package/src/views/user/fieldTranslation/editDialog.vue +7 -7
- package/src/views/user/fieldTranslation/list.vue +32 -32
- package/src/views/user/form/vform/designer.vue +775 -749
- package/src/views/user/form/vform/out_render.vue +1 -1
- package/src/views/user/form/vform/render.vue +8 -4
- package/src/views/user/form/view/edit.vue +38 -37
- package/src/views/user/form/view/list.vue +68 -15
- package/src/views/user/groups/edit.vue +2 -0
- package/src/views/user/groups/list.vue +1 -0
- package/src/views/user/home/default.vue +1025 -979
- package/src/views/user/home/dev.vue +29 -0
- package/src/views/user/home/index.vue +16 -6
- package/src/views/user/home/taili/index.vue +1034 -0
- package/src/views/user/login/default.vue +32 -3
- package/src/views/user/login/indexMixin.js +117 -3
- package/src/views/user/notify_message/dialog.vue +39 -18
- package/src/views/user/notify_template/edit.vue +188 -187
- package/src/views/user/notify_template/edit2.vue +176 -0
- package/src/views/user/notify_template/list.vue +4 -1
- package/src/views/user/notify_template/list2.vue +190 -0
- package/src/views/user/outLink/form_view.vue +211 -184
- package/src/views/user/outLink/index.vue +17 -0
- package/src/views/user/outLink/view.vue +28 -23
- package/src/views/user/position/edit.vue +116 -83
- package/src/views/user/position/list.vue +118 -86
- package/src/views/user/project_tag/dialog.vue +9 -4
- package/src/views/user/project_tag/edit.vue +2 -2
- package/src/views/user/project_tag/list.vue +9 -4
- package/src/views/user/push_setting/list.vue +2 -2
- package/src/views/user/request_setting/edit.vue +258 -0
- package/src/views/user/request_setting/list.vue +248 -0
- package/src/views/user/role/dialog.vue +1 -1
- package/src/views/user/role/list.vue +4 -4
- package/src/views/user/sale_org/dialog.vue +1 -1
- package/src/views/user/sale_org/list.vue +4 -1
- package/src/views/user/user/dialog.vue +46 -23
- package/src/views/user/user/edit.vue +1059 -1021
- package/src/views/user/user/form_dialog.vue +158 -0
- package/src/views/user/user/form_edit.vue +9 -0
- package/src/views/user/user/form_info.vue +210 -0
- package/src/views/user/user/form_list.vue +1 -0
- package/src/views/user/user/list.vue +647 -563
- package/src/views/user/wf/wfReport/index.vue +498 -0
- package/src/views/user/wf/wf_auto_submit_data/list.vue +2 -0
- package/src/views/user/wf/wf_manage/list.vue +371 -249
- package/src/views/user/wf/wf_manage/wfContentDialog.vue +1 -1
- package/src/views/user/wf/wf_obj_config/importItemDialog.vue +109 -0
- package/src/views/user/wf/wf_obj_config/itemEdit.vue +25 -1
- package/src/views/user/wf/wf_obj_config/list.vue +114 -9
- package/src/views/user/wf/wf_obj_config/wfBizDataSettingDialog.vue +2 -2
- package/src/views/user/wf/wf_transfer_setting/edit.vue +229 -0
- package/src/views/user/wf/wf_transfer_setting/list.vue +308 -0
- package/src/views/bd/setting/form_template/mixins/list2.js +0 -12
@@ -1,206 +1,279 @@
|
|
1
1
|
<template>
|
2
|
-
<
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
>
|
17
|
-
<
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
2
|
+
<el-dialog
|
3
|
+
custom-class="dialog-style list-dialog"
|
4
|
+
:title="i18nt('designer.setting.tableColEdit')"
|
5
|
+
:visible.sync="showDialog"
|
6
|
+
:modal="false"
|
7
|
+
:show-close="!0"
|
8
|
+
:close-on-click-modal="!1"
|
9
|
+
:close-on-press-escape="!1"
|
10
|
+
:destroy-on-close="!0"
|
11
|
+
top="5vh"
|
12
|
+
width="1220px"
|
13
|
+
v-dialog-drag
|
14
|
+
:before-close="closeHandle"
|
15
|
+
>
|
16
|
+
<div class="cont">
|
17
|
+
<el-table
|
18
|
+
ref="singleTable"
|
19
|
+
width="100%"
|
20
|
+
:data="tableData"
|
21
|
+
height="500"
|
22
|
+
border=""
|
23
|
+
row-key="columnId"
|
24
|
+
stripe=""
|
25
|
+
:tree-props="{ children: 'children' }"
|
26
|
+
default-expand-all
|
27
|
+
v-loading="pictLoading"
|
28
|
+
element-loading-background="rgba(0, 0, 0, 0)"
|
29
|
+
element-loading-text="数据正在加载中"
|
30
|
+
element-loading-spinner="el-icon-loading"
|
31
|
+
>
|
32
|
+
<el-table-column label="" width="80" fixed="left">
|
33
|
+
<template #default="scope">
|
34
|
+
<span>{{ scope.$index + 1 }}</span>
|
35
|
+
</template>
|
36
|
+
</el-table-column>
|
37
|
+
<el-table-column label="" width="35" fixed="left"
|
38
|
+
><i class="el-icon-s-operation drag-option"></i>
|
39
|
+
</el-table-column>
|
40
|
+
<el-table-column
|
41
|
+
:label="i18nt('designer.setting.columnLabel')"
|
42
|
+
width="150"
|
43
|
+
prop="label"
|
44
|
+
fixed="left"
|
28
45
|
>
|
29
|
-
<
|
30
|
-
<
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
<
|
42
|
-
<
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
<el-switch v-model="scope.row.required"></el-switch>
|
59
|
-
</template>
|
60
|
-
</el-table-column>
|
61
|
-
<el-table-column :label="i18nt('designer.setting.sortableColumn')" width="70" prop="sortable">
|
62
|
-
<template slot-scope="scope">
|
63
|
-
<el-switch v-model="scope.row.sortable"></el-switch>
|
64
|
-
</template>
|
65
|
-
</el-table-column>
|
66
|
-
<el-table-column :label="i18nt('designer.setting.fixedColumn')" width="100" prop="fixed">
|
67
|
-
<template slot-scope="scope">
|
68
|
-
<el-select v-model="scope.row.fixed" clearable>
|
69
|
-
<el-option value="left">left</el-option>
|
70
|
-
<el-option value="right">right</el-option>
|
71
|
-
</el-select>
|
72
|
-
</template>
|
73
|
-
</el-table-column>
|
74
|
-
<!-- <el-table-column :label="i18nt('designer.setting.alignTypeOfColumn')" width="100" prop="align">
|
75
|
-
<template slot-scope="scope">
|
76
|
-
<el-select v-model="scope.row.align">
|
77
|
-
<el-option v-for="(e,index) in alignOptions" :key="index" :value="e.value" :label="e.label"></el-option>
|
78
|
-
</el-select>
|
79
|
-
</template>
|
80
|
-
</el-table-column>-->
|
81
|
-
<el-table-column :label="i18nt('designer.setting.formatOfColumn')" width="200" prop="formatS">
|
82
|
-
<template slot-scope="scope">
|
83
|
-
<el-select v-model="scope.row.formatS" @change="changeFormatS(scope.row)" clearable>
|
84
|
-
<el-option-group :label="i18nt('designer.setting.customRenderGroup')">
|
85
|
-
<el-option value="render" label="render"></el-option>
|
86
|
-
</el-option-group>
|
87
|
-
<el-option-group v-for="t in op" :key="t.label" :label="t.label">
|
88
|
-
<el-option v-for="e in t.options" :key="e.value" :value="e.value" :label="e.label"></el-option>
|
89
|
-
</el-option-group>
|
90
|
-
</el-select>
|
91
|
-
</template>
|
92
|
-
</el-table-column>
|
93
|
-
<el-table-column :label="i18nt('自定义表格列配置')" width="150">
|
94
|
-
<template slot-scope="scope">
|
95
|
-
<a href="javascript:void(0);" class="a-link link-oneLind"
|
96
|
-
@click="openTableColumnConfigDialog(scope.row,scope.$index)">
|
97
|
-
<span>{{ scope.row.tableColumnConfig }}</span>
|
98
|
-
<i class="el-icon-edit"></i>
|
99
|
-
</a>
|
100
|
-
</template>
|
101
|
-
</el-table-column>
|
102
|
-
<el-table-column :label="i18nt('编辑下拉列')" width="70" prop="sortable">
|
103
|
-
<template slot-scope="scope">
|
104
|
-
<el-switch v-model="scope.row.treeNode"></el-switch>
|
105
|
-
</template>
|
106
|
-
</el-table-column>
|
107
|
-
<el-table-column :label="i18nt('编辑插槽类型')" width="200" prop="editFormatS">
|
108
|
-
<template slot-scope="scope">
|
109
|
-
<el-select v-model="scope.row.editFormatS" @change="changeFormatS(scope.row)" clearable>
|
110
|
-
<el-option v-for="e in editOp" :key="e.value" :value="e.value" :label="e.label"></el-option>
|
111
|
-
</el-select>
|
112
|
-
</template>
|
113
|
-
</el-table-column>
|
114
|
-
<el-table-column label="编辑插槽配置" width="70" align="center">
|
115
|
-
<template slot-scope="scope">
|
116
|
-
<el-button size="mini" plain="" round="" icon="el-icon-edit"
|
117
|
-
@click="openEditFormatConfigDialog(scope.row,scope.$index)"
|
118
|
-
:disabled="!scope.row.editFormatS"></el-button>
|
119
|
-
</template>
|
120
|
-
</el-table-column>
|
121
|
-
<el-table-column label="格式化配置" width="90" fixed="right" align="center">
|
122
|
-
<template slot-scope="scope">
|
123
|
-
<el-button size="mini" plain="" round="" icon="el-icon-edit"
|
124
|
-
@click="openFormatConfigDialog(scope.row,scope.$index)"
|
125
|
-
:disabled="!columnFormatMap[scope.row.formatS]"></el-button>
|
126
|
-
</template>
|
127
|
-
</el-table-column>
|
128
|
-
<el-table-column :label="i18nt('designer.setting.renderFunction')" width="70" fixed="right" align="center">
|
129
|
-
<template slot-scope="scope">
|
130
|
-
<el-button :disabled="'render' !== scope.row.formatS" size="mini" plain="" round="" icon="el-icon-edit"
|
131
|
-
@click="showRenderDialog(scope.row)"></el-button>
|
132
|
-
</template>
|
133
|
-
</el-table-column>
|
134
|
-
<el-table-column label="操作" width="150" fixed="right">
|
135
|
-
<template slot="header">
|
136
|
-
<el-tooltip
|
137
|
-
:hide-after="500"
|
138
|
-
class="item"
|
139
|
-
effect="dark"
|
140
|
-
content="添加根节点"
|
141
|
-
placement="top"
|
142
|
-
>
|
143
|
-
<el-button
|
144
|
-
size="mini" type="" circle=""
|
145
|
-
icon="el-icon-plus"
|
146
|
-
@click="onAddRoot"
|
147
|
-
/>
|
148
|
-
</el-tooltip>
|
149
|
-
</template>
|
150
|
-
<template #default="{ row, $index }">
|
151
|
-
<el-tooltip
|
152
|
-
:hide-after="hideAfter"
|
153
|
-
:open-delay="openDelay"
|
154
|
-
effect="dark"
|
155
|
-
content="添加兄弟节点"
|
156
|
-
placement="top"
|
157
|
-
>
|
158
|
-
<el-button
|
159
|
-
size="mini" type="" circle=""
|
160
|
-
icon="el-icon-plus"
|
161
|
-
@click="onAddSibling(row, $index)"
|
162
|
-
/>
|
163
|
-
</el-tooltip>
|
46
|
+
<template #default="scope">
|
47
|
+
<el-input
|
48
|
+
v-model="scope.row.label"
|
49
|
+
@change="changeRowLabel(scope.row)"
|
50
|
+
></el-input>
|
51
|
+
</template>
|
52
|
+
</el-table-column>
|
53
|
+
<el-table-column
|
54
|
+
:label="i18nt('designer.setting.columnName')"
|
55
|
+
width="150"
|
56
|
+
prop="prop"
|
57
|
+
>
|
58
|
+
<template #default="scope">
|
59
|
+
<el-input
|
60
|
+
v-model="scope.row.prop"
|
61
|
+
@change="changeRowProp(scope.row)"
|
62
|
+
:disabled="'editAttachment' == scope.row.formatS"
|
63
|
+
></el-input>
|
64
|
+
</template>
|
65
|
+
</el-table-column>
|
66
|
+
<el-table-column
|
67
|
+
:label="i18nt('designer.setting.columnWidth')"
|
68
|
+
width="100"
|
69
|
+
prop="width"
|
70
|
+
>
|
71
|
+
<template #default="scope">
|
72
|
+
<el-input v-model="scope.row.width"></el-input>
|
73
|
+
</template>
|
74
|
+
</el-table-column>
|
164
75
|
|
165
|
-
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
171
|
-
|
172
|
-
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
177
|
-
|
178
|
-
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
76
|
+
<el-table-column :label="i18nt('必填')" width="70" prop="required">
|
77
|
+
<template #default="scope">
|
78
|
+
<el-switch
|
79
|
+
v-model="scope.row.required"
|
80
|
+
@change="changeRowRequired(scope.row)"
|
81
|
+
></el-switch>
|
82
|
+
</template>
|
83
|
+
</el-table-column>
|
84
|
+
<el-table-column
|
85
|
+
:label="i18nt('designer.setting.fixedColumn')"
|
86
|
+
width="100"
|
87
|
+
prop="fixed"
|
88
|
+
>
|
89
|
+
<template #default="scope">
|
90
|
+
<el-select v-model="scope.row.fixed" clearable>
|
91
|
+
<el-option value="left">left</el-option>
|
92
|
+
<el-option value="right">right</el-option>
|
93
|
+
</el-select>
|
94
|
+
</template>
|
95
|
+
</el-table-column>
|
96
|
+
<el-table-column
|
97
|
+
:label="i18nt('designer.setting.formatOfColumn')"
|
98
|
+
width="200"
|
99
|
+
prop="formatS"
|
100
|
+
>
|
101
|
+
<template #default="scope">
|
102
|
+
<el-select
|
103
|
+
v-model="scope.row.formatS"
|
104
|
+
@change="changeFormatS(scope.row, false)"
|
105
|
+
clearable
|
106
|
+
>
|
107
|
+
<el-option-group
|
108
|
+
:label="i18nt('designer.setting.customRenderGroup')"
|
184
109
|
>
|
185
|
-
<el-
|
186
|
-
|
187
|
-
|
188
|
-
|
189
|
-
|
190
|
-
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
195
|
-
|
196
|
-
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
|
202
|
-
|
203
|
-
|
110
|
+
<el-option value="render" label="render"></el-option>
|
111
|
+
</el-option-group>
|
112
|
+
<el-option-group v-for="t in op" :key="t.label" :label="t.label">
|
113
|
+
<el-option
|
114
|
+
v-for="e in t.options"
|
115
|
+
:key="e.value"
|
116
|
+
:value="e.value"
|
117
|
+
:label="e.label"
|
118
|
+
></el-option>
|
119
|
+
</el-option-group>
|
120
|
+
</el-select>
|
121
|
+
</template>
|
122
|
+
</el-table-column>
|
123
|
+
<el-table-column label="格式化配置" width="90" align="center">
|
124
|
+
<template #default="scope">
|
125
|
+
<el-button
|
126
|
+
size="mini"
|
127
|
+
plain=""
|
128
|
+
round=""
|
129
|
+
icon="el-icon-edit"
|
130
|
+
@click="openFormatConfigDialog(scope.row, scope.$index)"
|
131
|
+
:disabled="
|
132
|
+
!columnFormatMap[scope.row.formatS] &&
|
133
|
+
'widgetRender' !== scope.row.formatS
|
134
|
+
"
|
135
|
+
></el-button>
|
136
|
+
</template>
|
137
|
+
</el-table-column>
|
138
|
+
<el-table-column
|
139
|
+
:label="i18nt('designer.setting.renderFunction')"
|
140
|
+
width="70"
|
141
|
+
align="center"
|
142
|
+
>
|
143
|
+
<template #default="scope">
|
144
|
+
<el-button
|
145
|
+
:disabled="'render' !== scope.row.formatS"
|
146
|
+
size="mini"
|
147
|
+
plain=""
|
148
|
+
round=""
|
149
|
+
icon="el-icon-edit"
|
150
|
+
@click="showRenderDialog(scope.row)"
|
151
|
+
></el-button>
|
152
|
+
</template>
|
153
|
+
</el-table-column>
|
154
|
+
<el-table-column
|
155
|
+
:label="i18nt('designer.setting.visibleColumn')"
|
156
|
+
width="70"
|
157
|
+
prop="show"
|
158
|
+
>
|
159
|
+
<template #default="scope">
|
160
|
+
<el-switch v-model="scope.row.show"></el-switch>
|
161
|
+
</template>
|
162
|
+
</el-table-column>
|
163
|
+
<el-table-column
|
164
|
+
:label="i18nt('designer.setting.sortableColumn')"
|
165
|
+
width="70"
|
166
|
+
prop="sortable"
|
167
|
+
>
|
168
|
+
<template #default="scope">
|
169
|
+
<el-switch v-model="scope.row.sortable"></el-switch>
|
170
|
+
</template>
|
171
|
+
</el-table-column>
|
172
|
+
<el-table-column
|
173
|
+
label="编辑更多属性"
|
174
|
+
width="100"
|
175
|
+
align="center"
|
176
|
+
fixed="right"
|
177
|
+
>
|
178
|
+
<template #default="scope">
|
179
|
+
<el-button
|
180
|
+
size="mini"
|
181
|
+
plain=""
|
182
|
+
round=""
|
183
|
+
icon="el-icon-edit"
|
184
|
+
@click="openRowEditDialog(scope.row, scope.$index)"
|
185
|
+
></el-button>
|
186
|
+
</template>
|
187
|
+
</el-table-column>
|
188
|
+
<el-table-column label="操作" width="150" fixed="right">
|
189
|
+
<template slot="header">
|
190
|
+
<el-tooltip
|
191
|
+
:hide-after="500"
|
192
|
+
class="item"
|
193
|
+
effect="dark"
|
194
|
+
content="添加根节点"
|
195
|
+
placement="top"
|
196
|
+
>
|
197
|
+
<el-button
|
198
|
+
size="mini"
|
199
|
+
type=""
|
200
|
+
circle=""
|
201
|
+
icon="el-icon-plus"
|
202
|
+
@click="onAddRoot"
|
203
|
+
/>
|
204
|
+
</el-tooltip>
|
205
|
+
</template>
|
206
|
+
<template #default="{ row, $index }">
|
207
|
+
<el-tooltip
|
208
|
+
:hide-after="hideAfter"
|
209
|
+
:open-delay="openDelay"
|
210
|
+
effect="dark"
|
211
|
+
content="添加兄弟节点"
|
212
|
+
placement="top"
|
213
|
+
>
|
214
|
+
<el-button
|
215
|
+
size="mini"
|
216
|
+
type=""
|
217
|
+
circle=""
|
218
|
+
icon="el-icon-plus"
|
219
|
+
@click="onAddSibling(row, $index)"
|
220
|
+
/>
|
221
|
+
</el-tooltip>
|
222
|
+
|
223
|
+
<el-tooltip
|
224
|
+
:hide-after="hideAfter"
|
225
|
+
:open-delay="openDelay"
|
226
|
+
effect="dark"
|
227
|
+
content="添加子节点"
|
228
|
+
placement="top"
|
229
|
+
>
|
230
|
+
<el-button
|
231
|
+
size="mini"
|
232
|
+
type=""
|
233
|
+
circle=""
|
234
|
+
icon="el-icon-circle-plus-outline"
|
235
|
+
@click="onAddChild(row, $index)"
|
236
|
+
/>
|
237
|
+
</el-tooltip>
|
238
|
+
<el-tooltip
|
239
|
+
:hide-after="hideAfter"
|
240
|
+
:open-delay="openDelay"
|
241
|
+
effect="dark"
|
242
|
+
content="删除"
|
243
|
+
placement="top"
|
244
|
+
>
|
245
|
+
<el-button
|
246
|
+
size="mini"
|
247
|
+
type=""
|
248
|
+
circle=""
|
249
|
+
icon="el-icon-delete"
|
250
|
+
@click="onDelete(row, $index)"
|
251
|
+
/>
|
252
|
+
</el-tooltip>
|
253
|
+
</template>
|
254
|
+
</el-table-column>
|
255
|
+
</el-table>
|
256
|
+
<columnRenderDialog
|
257
|
+
:column="currentTableColumn"
|
258
|
+
:sourceData="sourceData"
|
259
|
+
v-if="showColumnRenderDialog"
|
260
|
+
:visiable.sync="showColumnRenderDialog"
|
261
|
+
@confirm="confirmWidgetRenderDialog"
|
262
|
+
></columnRenderDialog>
|
263
|
+
</div>
|
264
|
+
<div class="dialog-footer" slot="footer">
|
265
|
+
<el-button @click="closeHandle" class="button-sty" icon="el-icon-close">
|
266
|
+
{{ i18nt("designer.hint.cancel") }}
|
267
|
+
</el-button>
|
268
|
+
<el-button
|
269
|
+
type="primary"
|
270
|
+
@click="colSubmit"
|
271
|
+
class="button-sty"
|
272
|
+
icon="el-icon-check"
|
273
|
+
>
|
274
|
+
{{ i18nt("designer.hint.confirm") }}
|
275
|
+
</el-button>
|
276
|
+
</div>
|
204
277
|
<el-dialog
|
205
278
|
v-if="showRenderDialogFlag"
|
206
279
|
:title="i18nt('designer.setting.renderFunction')"
|
@@ -213,16 +286,35 @@
|
|
213
286
|
:destroy-on-close="!0"
|
214
287
|
v-dialog-drag
|
215
288
|
top="7vh"
|
289
|
+
:append-to-body="true"
|
216
290
|
>
|
217
|
-
<el-alert
|
218
|
-
|
219
|
-
|
291
|
+
<el-alert
|
292
|
+
type="info"
|
293
|
+
:closable="!1"
|
294
|
+
title="function customRender(params,h) {"
|
295
|
+
/>
|
296
|
+
<code-editor
|
297
|
+
ref="dsResultEditor"
|
298
|
+
mode="javascript"
|
299
|
+
:readonly="!1"
|
300
|
+
v-model="renderJson"
|
301
|
+
></code-editor>
|
302
|
+
<el-alert type="info" :closable="!1" title="}" />
|
220
303
|
<div class="dialog-footer" slot="footer">
|
221
|
-
<el-button
|
222
|
-
|
304
|
+
<el-button
|
305
|
+
@click="showRenderDialogFlag = !1"
|
306
|
+
class="button-sty"
|
307
|
+
icon="el-icon-close"
|
308
|
+
>
|
309
|
+
{{ i18nt("designer.hint.cancel") }}
|
223
310
|
</el-button>
|
224
|
-
<el-button
|
225
|
-
|
311
|
+
<el-button
|
312
|
+
type="primary"
|
313
|
+
@click="saveColumnRender"
|
314
|
+
class="button-sty"
|
315
|
+
icon="el-icon-check"
|
316
|
+
>
|
317
|
+
{{ i18nt("designer.hint.confirm") }}
|
226
318
|
</el-button>
|
227
319
|
</div>
|
228
320
|
</el-dialog>
|
@@ -241,39 +333,318 @@
|
|
241
333
|
top="5vh"
|
242
334
|
>
|
243
335
|
<div class="cont">
|
244
|
-
<el-alert
|
245
|
-
|
246
|
-
|
336
|
+
<el-alert
|
337
|
+
type="info"
|
338
|
+
:closable="false"
|
339
|
+
:title="tableColumnConfigHeader"
|
340
|
+
></el-alert>
|
341
|
+
<code-editor
|
342
|
+
:mode="'javascript'"
|
343
|
+
:readonly="false"
|
344
|
+
v-model="tableColumnConfigCode"
|
345
|
+
ref="ecEditor"
|
346
|
+
></code-editor>
|
347
|
+
<el-alert type="info" :closable="false" title="}"></el-alert>
|
348
|
+
</div>
|
349
|
+
<div slot="footer" class="dialog-footer">
|
350
|
+
<el-button
|
351
|
+
@click="showTableColumnConfigDialog = false"
|
352
|
+
class="button-sty"
|
353
|
+
icon="el-icon-close"
|
354
|
+
>
|
355
|
+
{{ i18nt("designer.hint.cancel") }}
|
356
|
+
</el-button>
|
357
|
+
<el-button
|
358
|
+
type="primary"
|
359
|
+
@click="saveTableColumnConfigDialog"
|
360
|
+
class="button-sty"
|
361
|
+
icon="el-icon-check"
|
362
|
+
>
|
363
|
+
{{ i18nt("designer.hint.confirm") }}
|
364
|
+
</el-button>
|
365
|
+
</div>
|
366
|
+
</el-dialog>
|
367
|
+
<el-dialog
|
368
|
+
:title="i18nt('designer.setting.editFormEventHandler')"
|
369
|
+
:visible.sync="showFormEventDialogFlag"
|
370
|
+
v-if="showFormEventDialogFlag"
|
371
|
+
:show-close="true"
|
372
|
+
custom-class="dialog-style list-dialog"
|
373
|
+
v-dialog-drag
|
374
|
+
:close-on-click-modal="false"
|
375
|
+
:close-on-press-escape="false"
|
376
|
+
:destroy-on-close="true"
|
377
|
+
:append-to-body="true"
|
378
|
+
:modal-append-to-body="true"
|
379
|
+
top="5vh"
|
380
|
+
>
|
381
|
+
<div class="cont">
|
382
|
+
<el-alert
|
383
|
+
type="info"
|
384
|
+
:closable="false"
|
385
|
+
:title="'form.' + eventParamsMap[curEventName]"
|
386
|
+
></el-alert>
|
387
|
+
<code-editor
|
388
|
+
:mode="'javascript'"
|
389
|
+
:readonly="false"
|
390
|
+
v-model="formEventHandlerCode"
|
391
|
+
ref="ecEditor"
|
392
|
+
></code-editor>
|
247
393
|
<el-alert type="info" :closable="false" title="}"></el-alert>
|
248
394
|
</div>
|
249
395
|
<div slot="footer" class="dialog-footer">
|
250
|
-
<el-button
|
251
|
-
|
396
|
+
<el-button
|
397
|
+
@click="showFormEventDialogFlag = false"
|
398
|
+
class="button-sty"
|
399
|
+
icon="el-icon-close"
|
400
|
+
>
|
401
|
+
{{ i18nt("designer.hint.cancel") }}
|
252
402
|
</el-button>
|
253
|
-
<el-button
|
254
|
-
|
403
|
+
<el-button
|
404
|
+
type="primary"
|
405
|
+
@click="saveFormEventHandler"
|
406
|
+
class="button-sty"
|
407
|
+
icon="el-icon-check"
|
408
|
+
>
|
409
|
+
{{ i18nt("designer.hint.confirm") }}
|
255
410
|
</el-button>
|
256
411
|
</div>
|
257
412
|
</el-dialog>
|
258
|
-
</div>
|
259
413
|
|
414
|
+
<el-dialog
|
415
|
+
custom-class="dialog-style list-dialog"
|
416
|
+
:title="i18nt('designer.setting.tableColEdit')"
|
417
|
+
:visible.sync="showRowEditDialog"
|
418
|
+
v-if="showRowEditDialog"
|
419
|
+
:modal="false"
|
420
|
+
:show-close="!0"
|
421
|
+
:close-on-click-modal="!1"
|
422
|
+
:close-on-press-escape="!1"
|
423
|
+
:destroy-on-close="!0"
|
424
|
+
top="5vh"
|
425
|
+
width="409px"
|
426
|
+
v-dialog-drag
|
427
|
+
>
|
428
|
+
<div class="cont">
|
429
|
+
<el-form :model="rowData" class="form-m2" label-position="top">
|
430
|
+
<el-form-item :label="i18nt('designer.setting.columnLabel')">
|
431
|
+
<el-input
|
432
|
+
v-model="rowData.label"
|
433
|
+
@change="changeRowLabel(rowData)"
|
434
|
+
></el-input>
|
435
|
+
</el-form-item>
|
436
|
+
<el-form-item :label="i18nt('designer.setting.columnName')">
|
437
|
+
<el-input
|
438
|
+
v-model="rowData.prop"
|
439
|
+
@change="changeRowProp(rowData)"
|
440
|
+
:disabled="'editAttachment' == rowData.formatS"
|
441
|
+
></el-input>
|
442
|
+
</el-form-item>
|
443
|
+
<el-form-item :label="i18nt('designer.setting.columnWidth')">
|
444
|
+
<el-input v-model="rowData.width"></el-input>
|
445
|
+
</el-form-item>
|
446
|
+
<el-form-item :label="i18nt('必填')">
|
447
|
+
<el-switch
|
448
|
+
v-model="rowData.required"
|
449
|
+
@change="changeRowRequired(rowData)"
|
450
|
+
></el-switch>
|
451
|
+
</el-form-item>
|
452
|
+
<el-form-item :label="i18nt('designer.setting.fixedColumn')">
|
453
|
+
<el-select v-model="rowData.fixed" clearable>
|
454
|
+
<el-option value="left">left</el-option>
|
455
|
+
<el-option value="right">right</el-option>
|
456
|
+
</el-select>
|
457
|
+
</el-form-item>
|
458
|
+
<el-form-item :label="i18nt('designer.setting.formatOfColumn')">
|
459
|
+
<el-select
|
460
|
+
v-model="rowData.formatS"
|
461
|
+
@change="changeFormatS(rowData, false)"
|
462
|
+
clearable
|
463
|
+
>
|
464
|
+
<el-option-group
|
465
|
+
:label="i18nt('designer.setting.customRenderGroup')"
|
466
|
+
>
|
467
|
+
<el-option value="render" label="render"></el-option>
|
468
|
+
</el-option-group>
|
469
|
+
<el-option-group v-for="t in op" :key="t.label" :label="t.label">
|
470
|
+
<el-option
|
471
|
+
v-for="e in t.options"
|
472
|
+
:key="e.value"
|
473
|
+
:value="e.value"
|
474
|
+
:label="e.label"
|
475
|
+
></el-option>
|
476
|
+
</el-option-group>
|
477
|
+
</el-select>
|
478
|
+
</el-form-item>
|
479
|
+
<el-form-item label="格式化配置">
|
480
|
+
<el-button
|
481
|
+
size="mini"
|
482
|
+
plain=""
|
483
|
+
round=""
|
484
|
+
icon="el-icon-edit"
|
485
|
+
@click="openFormatConfigDialog(rowData, rowDataIndex)"
|
486
|
+
:disabled="
|
487
|
+
!columnFormatMap[rowData.formatS] &&
|
488
|
+
'widgetRender' !== rowData.formatS
|
489
|
+
"
|
490
|
+
></el-button>
|
491
|
+
</el-form-item>
|
492
|
+
<el-form-item :label="i18nt('designer.setting.renderFunction')">
|
493
|
+
<el-button
|
494
|
+
:disabled="'render' !== rowData.formatS"
|
495
|
+
size="mini"
|
496
|
+
plain=""
|
497
|
+
round=""
|
498
|
+
icon="el-icon-edit"
|
499
|
+
@click="showRenderDialog(rowData)"
|
500
|
+
></el-button>
|
501
|
+
</el-form-item>
|
502
|
+
<el-form-item :label="i18nt('designer.setting.visibleColumn')">
|
503
|
+
<el-switch v-model="rowData.show"></el-switch>
|
504
|
+
</el-form-item>
|
505
|
+
<el-form-item :label="i18nt('designer.setting.sortableColumn')">
|
506
|
+
<el-switch v-model="rowData.sortable"></el-switch>
|
507
|
+
</el-form-item>
|
508
|
+
<el-form-item :label="i18nt('明细行')">
|
509
|
+
<el-switch v-model="rowData.isItemLine"></el-switch>
|
510
|
+
</el-form-item>
|
511
|
+
|
512
|
+
<el-form-item :label="i18nt('下拉列')">
|
513
|
+
<el-switch v-model="rowData.treeNode"></el-switch>
|
514
|
+
</el-form-item>
|
515
|
+
<el-form-item :label="i18nt('自定义表格列配置')">
|
516
|
+
<a
|
517
|
+
href="javascript:void(0);"
|
518
|
+
class="a-link link-oneLind"
|
519
|
+
@click="openTableColumnConfigDialog(rowData, rowDataIndex)"
|
520
|
+
>
|
521
|
+
<span>{{ rowData.tableColumnConfig }}</span>
|
522
|
+
<i class="el-icon-edit"></i>
|
523
|
+
</a>
|
524
|
+
</el-form-item>
|
525
|
+
<el-form-item :label="i18nt('编辑插槽类型')">
|
526
|
+
<el-select
|
527
|
+
v-model="rowData.editFormatS"
|
528
|
+
@change="changeFormatS(rowData, true)"
|
529
|
+
clearable
|
530
|
+
>
|
531
|
+
<el-option
|
532
|
+
v-for="e in editOp"
|
533
|
+
:key="e.value"
|
534
|
+
:value="e.value"
|
535
|
+
:label="e.label"
|
536
|
+
></el-option>
|
537
|
+
</el-select>
|
538
|
+
</el-form-item>
|
539
|
+
<el-form-item label="编辑插槽配置">
|
540
|
+
<el-button
|
541
|
+
size="mini"
|
542
|
+
plain=""
|
543
|
+
round=""
|
544
|
+
icon="el-icon-edit"
|
545
|
+
@click="openEditFormatConfigDialog(rowData, rowDataIndex)"
|
546
|
+
:disabled="!rowData.editFormatS"
|
547
|
+
></el-button>
|
548
|
+
</el-form-item>
|
549
|
+
<el-form-item :label="i18nt('导出类型')">
|
550
|
+
<el-select v-model="rowData.exportType" clearable>
|
551
|
+
<el-option value="Image2" label="图片"></el-option>
|
552
|
+
<el-option value="Number" label="数值"></el-option>
|
553
|
+
</el-select>
|
554
|
+
</el-form-item>
|
555
|
+
<el-form-item :label="i18nt('表尾统计行类型')">
|
556
|
+
<el-select v-model="rowData.footerDataType" clearable>
|
557
|
+
<el-option value="1" label="合计"></el-option>
|
558
|
+
<el-option value="2" label="平均"></el-option>
|
559
|
+
<el-option value="3" label="自定义"></el-option>
|
560
|
+
</el-select>
|
561
|
+
</el-form-item>
|
562
|
+
<el-form-item label="表尾统计行配置">
|
563
|
+
<el-button
|
564
|
+
size="mini"
|
565
|
+
plain=""
|
566
|
+
round=""
|
567
|
+
icon="el-icon-edit"
|
568
|
+
@click="
|
569
|
+
editFormEventHandler(rowData, rowDataIndex, 'footerMethodConfg')
|
570
|
+
"
|
571
|
+
:disabled="rowData.footerDataType !== '3'"
|
572
|
+
></el-button>
|
573
|
+
</el-form-item>
|
574
|
+
<el-form-item :label="i18nt('显示名称颜色')">
|
575
|
+
<el-select v-model="rowData.labelColor" clearable>
|
576
|
+
<el-option value="#e6a23c" label="橙"></el-option>
|
577
|
+
<el-option value="#2a6494" label="蓝"></el-option>
|
578
|
+
<el-option value="#30b08f" label="绿"></el-option>
|
579
|
+
<el-option value="#909399" label="灰"></el-option>
|
580
|
+
<el-option value="#ea5353" label="红"></el-option>
|
581
|
+
</el-select>
|
582
|
+
</el-form-item>
|
583
|
+
</el-form>
|
584
|
+
</div>
|
585
|
+
<div class="dialog-footer" slot="footer">
|
586
|
+
<el-button
|
587
|
+
@click="closeRowEditDialog"
|
588
|
+
class="button-sty"
|
589
|
+
icon="el-icon-close"
|
590
|
+
>
|
591
|
+
{{ i18nt("designer.hint.cancel") }}
|
592
|
+
</el-button>
|
593
|
+
<el-button
|
594
|
+
type="primary"
|
595
|
+
@click="submitRowEditDialog"
|
596
|
+
class="button-sty"
|
597
|
+
icon="el-icon-check"
|
598
|
+
>
|
599
|
+
{{ i18nt("designer.hint.confirm") }}
|
600
|
+
</el-button>
|
601
|
+
</div>
|
602
|
+
</el-dialog>
|
603
|
+
</el-dialog>
|
260
604
|
</template>
|
261
605
|
<script>
|
262
606
|
import i18n from "../../../../../../components/xform/utils/i18n";
|
263
607
|
import Sortable from "sortablejs";
|
264
|
-
import {
|
608
|
+
import {
|
609
|
+
generateId,
|
610
|
+
loopHandleWidget,
|
611
|
+
deepClone,
|
612
|
+
columnFormatMap
|
613
|
+
} from "../../../../../../components/xform/utils/util";
|
614
|
+
import columnRenderDialog from "./columnRenderDialog.vue";
|
615
|
+
|
616
|
+
let businessOptions = [
|
617
|
+
{
|
618
|
+
value: "_createBy",
|
619
|
+
label: "创建人",
|
620
|
+
},
|
621
|
+
{
|
622
|
+
value: "_modifyBy",
|
623
|
+
label: "更新人",
|
624
|
+
},
|
625
|
+
{
|
626
|
+
value: "create_date",
|
627
|
+
label: "创建时间",
|
628
|
+
},
|
629
|
+
{
|
630
|
+
value: "modify_date",
|
631
|
+
label: "更新时间",
|
632
|
+
},
|
633
|
+
];
|
634
|
+
let userFields = ["_createBy", "_modifyBy", "create_date", "modify_date"];
|
265
635
|
|
266
636
|
export default {
|
267
637
|
mixins: [i18n],
|
268
638
|
props: {
|
269
639
|
designer: Object,
|
270
640
|
selectedWidget: Object,
|
271
|
-
optionModel: Object
|
641
|
+
optionModel: Object,
|
272
642
|
},
|
273
|
-
components: {},
|
274
|
-
inject: [
|
643
|
+
components: { columnRenderDialog },
|
644
|
+
inject: ["openWidgetPropertyDialog"],
|
275
645
|
data() {
|
276
646
|
return {
|
647
|
+
pictLoading: true,
|
277
648
|
tableColumnConfigTitle: null,
|
278
649
|
showTableColumnConfigDialog: false,
|
279
650
|
tableColumnConfigHeader: null,
|
@@ -282,264 +653,349 @@ export default {
|
|
282
653
|
dialogVisible: true,
|
283
654
|
alignOptions: [
|
284
655
|
{
|
285
|
-
value:
|
286
|
-
label:
|
656
|
+
value: "left",
|
657
|
+
label: "left",
|
287
658
|
},
|
288
659
|
{
|
289
|
-
value:
|
290
|
-
label:
|
660
|
+
value: "center",
|
661
|
+
label: "center",
|
291
662
|
},
|
292
663
|
{
|
293
|
-
value:
|
294
|
-
label:
|
295
|
-
}
|
664
|
+
value: "right",
|
665
|
+
label: "right",
|
666
|
+
},
|
296
667
|
],
|
668
|
+
businessOptions,
|
669
|
+
userFields,
|
297
670
|
op: [
|
298
671
|
{
|
299
|
-
label:
|
672
|
+
label: "edit Format",
|
300
673
|
options: [
|
301
674
|
{
|
302
|
-
value:
|
303
|
-
label:
|
675
|
+
value: "editInput",
|
676
|
+
label: "文本输入框",
|
304
677
|
},
|
305
678
|
{
|
306
|
-
value:
|
307
|
-
label:
|
679
|
+
value: "editNumber",
|
680
|
+
label: "数字输入框",
|
308
681
|
},
|
309
682
|
{
|
310
|
-
value:
|
311
|
-
label:
|
683
|
+
value: "editDate",
|
684
|
+
label: "日期输入框",
|
312
685
|
},
|
313
686
|
{
|
314
|
-
value:
|
315
|
-
label:
|
687
|
+
value: "editSelect",
|
688
|
+
label: "下拉框",
|
316
689
|
},
|
317
690
|
{
|
318
|
-
value:
|
319
|
-
label:
|
691
|
+
value: "checkbox",
|
692
|
+
label: "复选框",
|
320
693
|
},
|
321
694
|
{
|
322
|
-
value:
|
323
|
-
label:
|
695
|
+
value: "radio",
|
696
|
+
label: "单选框",
|
324
697
|
},
|
325
698
|
{
|
326
|
-
value:
|
327
|
-
label:
|
699
|
+
value: "editAttachment",
|
700
|
+
label: "附件",
|
328
701
|
},
|
329
702
|
{
|
330
|
-
value:
|
331
|
-
label:
|
703
|
+
value: "editSearch",
|
704
|
+
label: "搜索框",
|
332
705
|
},
|
333
706
|
{
|
334
|
-
value:
|
335
|
-
label:
|
707
|
+
value: "editStatus",
|
708
|
+
label: "状态",
|
336
709
|
},
|
337
710
|
{
|
338
|
-
value:
|
339
|
-
label:
|
711
|
+
value: "text",
|
712
|
+
label: "文本",
|
340
713
|
},
|
341
714
|
{
|
342
|
-
value:
|
343
|
-
label:
|
715
|
+
value: "editDelete",
|
716
|
+
label: "删除按钮",
|
344
717
|
},
|
345
718
|
{
|
346
|
-
value:
|
347
|
-
label:
|
719
|
+
value: "editButton",
|
720
|
+
label: "查看按钮",
|
348
721
|
},
|
349
722
|
{
|
350
|
-
value:
|
351
|
-
label:
|
352
|
-
}
|
353
|
-
|
723
|
+
value: "aText",
|
724
|
+
label: "超链接文本",
|
725
|
+
},
|
726
|
+
{
|
727
|
+
value: "aLink",
|
728
|
+
label: "超链接按钮",
|
729
|
+
},
|
730
|
+
{
|
731
|
+
value: "button",
|
732
|
+
label: "按钮",
|
733
|
+
},
|
734
|
+
{
|
735
|
+
value: "editTreeButtonGroup",
|
736
|
+
label: "编辑行按钮组",
|
737
|
+
},
|
738
|
+
{
|
739
|
+
value: "widgetRender",
|
740
|
+
label: "自定义组件",
|
741
|
+
},
|
742
|
+
],
|
354
743
|
},
|
355
744
|
{
|
356
|
-
label:
|
745
|
+
label: "树控件",
|
357
746
|
options: [
|
358
747
|
{
|
359
|
-
value:
|
360
|
-
label:
|
748
|
+
value: "addSiblingEditRow",
|
749
|
+
label: "新增兄弟节点",
|
361
750
|
},
|
362
751
|
{
|
363
|
-
value:
|
364
|
-
label:
|
752
|
+
value: "addChildTreeRow",
|
753
|
+
label: "新增子节点",
|
365
754
|
},
|
366
755
|
{
|
367
|
-
value:
|
368
|
-
label:
|
756
|
+
value: "moveUpRow",
|
757
|
+
label: "上移",
|
369
758
|
},
|
370
759
|
{
|
371
|
-
value:
|
372
|
-
label:
|
760
|
+
value: "moveDownRow",
|
761
|
+
label: "下移",
|
373
762
|
},
|
374
763
|
{
|
375
|
-
value:
|
376
|
-
label:
|
377
|
-
}
|
378
|
-
]
|
764
|
+
value: "removeTreeRow",
|
765
|
+
label: "删除树节点",
|
766
|
+
},
|
767
|
+
],
|
768
|
+
},
|
769
|
+
|
770
|
+
{
|
771
|
+
label: "业务模块",
|
772
|
+
options: businessOptions,
|
379
773
|
},
|
380
774
|
{
|
381
|
-
label:
|
775
|
+
label: "Date Format",
|
382
776
|
options: [
|
383
777
|
{
|
384
|
-
value:
|
385
|
-
label:
|
778
|
+
value: "d1",
|
779
|
+
label: "yyyy-MM-dd",
|
386
780
|
},
|
387
781
|
{
|
388
|
-
value:
|
389
|
-
label:
|
782
|
+
value: "d2",
|
783
|
+
label: "yyyy/MM/dd",
|
390
784
|
},
|
391
785
|
{
|
392
|
-
value:
|
393
|
-
label:
|
786
|
+
value: "d3",
|
787
|
+
label: "yyyy年MM月dd日",
|
394
788
|
},
|
395
789
|
{
|
396
|
-
value:
|
397
|
-
label:
|
790
|
+
value: "d4",
|
791
|
+
label: "yyyy-MM-dd HH:mm:ss",
|
398
792
|
},
|
399
793
|
{
|
400
|
-
value:
|
401
|
-
label:
|
402
|
-
}
|
403
|
-
]
|
794
|
+
value: "d5",
|
795
|
+
label: "yyyy-MM-dd hh:mm:ss",
|
796
|
+
},
|
797
|
+
],
|
404
798
|
},
|
405
799
|
{
|
406
|
-
label:
|
800
|
+
label: "Number Format",
|
407
801
|
options: [
|
408
802
|
{
|
409
|
-
value:
|
410
|
-
label:
|
803
|
+
value: "n1",
|
804
|
+
label: "###,###,###,##0.######",
|
411
805
|
},
|
412
806
|
{
|
413
|
-
value:
|
414
|
-
label:
|
807
|
+
value: "n2",
|
808
|
+
label: "###,###,###,##0.00####",
|
415
809
|
},
|
416
810
|
{
|
417
|
-
value:
|
418
|
-
label:
|
811
|
+
value: "n3",
|
812
|
+
label: "###,###,###,##0.000000",
|
419
813
|
},
|
420
814
|
{
|
421
|
-
value:
|
422
|
-
label:
|
815
|
+
value: "n4",
|
816
|
+
label: "###,###,###,##0.000",
|
423
817
|
},
|
424
818
|
{
|
425
|
-
value:
|
426
|
-
label:
|
819
|
+
value: "n5",
|
820
|
+
label: "###,###,###,##0.00",
|
427
821
|
},
|
428
822
|
{
|
429
|
-
value:
|
430
|
-
label:
|
823
|
+
value: "n6",
|
824
|
+
label: "###,###,###,##0",
|
431
825
|
},
|
432
826
|
{
|
433
|
-
value:
|
434
|
-
label:
|
435
|
-
}
|
436
|
-
]
|
437
|
-
}
|
827
|
+
value: "n7",
|
828
|
+
label: "###,##0.00##%",
|
829
|
+
},
|
830
|
+
],
|
831
|
+
},
|
438
832
|
],
|
439
833
|
editOp: [
|
440
834
|
{
|
441
|
-
value:
|
442
|
-
label:
|
835
|
+
value: "editInput",
|
836
|
+
label: "文本输入框",
|
443
837
|
},
|
444
838
|
{
|
445
|
-
value:
|
446
|
-
label:
|
839
|
+
value: "editNumber",
|
840
|
+
label: "数字输入框",
|
447
841
|
},
|
448
842
|
{
|
449
|
-
value:
|
450
|
-
label:
|
843
|
+
value: "editDate",
|
844
|
+
label: "日期输入框",
|
451
845
|
},
|
452
846
|
{
|
453
|
-
value:
|
454
|
-
label:
|
847
|
+
value: "editSelect",
|
848
|
+
label: "下拉框",
|
455
849
|
},
|
456
850
|
{
|
457
|
-
value:
|
458
|
-
label:
|
851
|
+
value: "editAttachment",
|
852
|
+
label: "附件",
|
459
853
|
},
|
460
854
|
{
|
461
|
-
value:
|
462
|
-
label:
|
463
|
-
}
|
855
|
+
value: "editSearch",
|
856
|
+
label: "搜索框",
|
857
|
+
},
|
464
858
|
],
|
465
859
|
showRenderDialogFlag: !1,
|
466
|
-
renderJson:
|
860
|
+
renderJson: "",
|
467
861
|
currentTableColumn: null,
|
862
|
+
sourceData: null,
|
468
863
|
|
469
864
|
hideAfter: 1500,
|
470
865
|
openDelay: 500,
|
471
|
-
tableData: []
|
866
|
+
tableData: [], //树形结构数据转的数组
|
472
867
|
tableDataArray: [],
|
473
868
|
dragSort: null,
|
474
|
-
columnFormatMap
|
475
|
-
|
476
|
-
|
477
|
-
|
478
|
-
|
479
|
-
|
480
|
-
|
481
|
-
|
482
|
-
|
483
|
-
aLink: 'a-link',
|
484
|
-
editDelete: 'a-link',
|
485
|
-
editButton: 'a-link',
|
486
|
-
button: 'button',
|
487
|
-
addSiblingEditRow: 'a-link',
|
488
|
-
addChildTreeRow: 'a-link',
|
489
|
-
moveUpRow: 'a-link',
|
490
|
-
moveDownRow: 'a-link',
|
491
|
-
removeTreeRow: 'a-link'
|
869
|
+
columnFormatMap,
|
870
|
+
|
871
|
+
showFormEventDialogFlag: false,
|
872
|
+
formEventHandlerCode: "",
|
873
|
+
curEventName: "",
|
874
|
+
curEventRow:null,
|
875
|
+
|
876
|
+
eventParamsMap: {
|
877
|
+
footerMethodConfg: "footerMethodConfg(dataId,formCode,param) {",
|
492
878
|
},
|
493
|
-
|
879
|
+
|
880
|
+
showColumnRenderDialog: false,
|
881
|
+
|
882
|
+
editRowData: null,
|
883
|
+
rowData: null,
|
884
|
+
rowDataIndex: 0,
|
885
|
+
showRowEditDialog: false,
|
886
|
+
};
|
494
887
|
},
|
495
888
|
beforeDestroy() {
|
496
|
-
if (this.dragSort) this.dragSort.destroy()
|
497
|
-
},
|
498
|
-
created() {
|
499
|
-
|
889
|
+
if (this.dragSort) this.dragSort.destroy();
|
500
890
|
},
|
891
|
+
created() {},
|
501
892
|
mounted() {
|
502
893
|
this.init();
|
503
894
|
},
|
504
895
|
methods: {
|
896
|
+
editFormEventHandler(row, index, eventName) {
|
897
|
+
this.curEventRow = row;
|
898
|
+
this.curEventName = eventName;
|
899
|
+
this.curEventIndex = index;
|
900
|
+
this.formEventHandlerCode = row[eventName];
|
901
|
+
this.showFormEventDialogFlag = true;
|
902
|
+
},
|
903
|
+
|
904
|
+
saveFormEventHandler() {
|
905
|
+
const codeHints = this.$refs.ecEditor.getEditorAnnotations();
|
906
|
+
let syntaxErrorFlag = false;
|
907
|
+
if (!!codeHints && codeHints.length > 0) {
|
908
|
+
codeHints.forEach((chItem) => {
|
909
|
+
if (chItem.type === "error") {
|
910
|
+
syntaxErrorFlag = true;
|
911
|
+
}
|
912
|
+
});
|
913
|
+
|
914
|
+
if (syntaxErrorFlag) {
|
915
|
+
this.$message.error(
|
916
|
+
this.i18nt("designer.setting.syntaxCheckWarning")
|
917
|
+
);
|
918
|
+
return;
|
919
|
+
}
|
920
|
+
}
|
921
|
+
this.curEventRow[this.curEventName] =
|
922
|
+
this.formEventHandlerCode;
|
923
|
+
this.showFormEventDialogFlag = false;
|
924
|
+
},
|
505
925
|
init() {
|
506
|
-
|
507
|
-
|
926
|
+
setTimeout(() => {
|
927
|
+
this.tableData = this.$baseLodash.cloneDeep(
|
928
|
+
this.optionModel.tableColumns
|
929
|
+
);
|
930
|
+
this.$nextTick(() => {
|
931
|
+
this.rowDrop();
|
932
|
+
setTimeout(() => {
|
933
|
+
this.pictLoading = false;
|
934
|
+
}, 200);
|
935
|
+
});
|
936
|
+
}, 10);
|
937
|
+
|
938
|
+
/*this.$nextTick(() => {
|
508
939
|
this.rowDrop();
|
509
|
-
})
|
940
|
+
});*/
|
510
941
|
},
|
511
942
|
colSubmit() {
|
512
943
|
this.dialogVisible = !1;
|
513
944
|
this.optionModel.tableColumns = this.tableData;
|
514
945
|
this.closeHandle();
|
515
946
|
},
|
947
|
+
openWidgetRenderDialog(row, sourceData) {
|
948
|
+
this.currentTableColumn = row;
|
949
|
+
this.sourceData = sourceData;
|
950
|
+
|
951
|
+
// this.widgetList =
|
952
|
+
|
953
|
+
// this.designer.widgetList
|
954
|
+
|
955
|
+
this.showColumnRenderDialog = true;
|
956
|
+
},
|
957
|
+
confirmWidgetRenderDialog(widgetList) {
|
958
|
+
this.currentTableColumn.widgetList = widgetList;
|
959
|
+
this.showColumnRenderDialog = false;
|
960
|
+
},
|
516
961
|
showRenderDialog: function (e) {
|
517
|
-
(
|
962
|
+
/*if(e.formatS == 'widgetRender'){
|
963
|
+
this.openWidgetRenderDialog(e);
|
964
|
+
return
|
965
|
+
}*/
|
966
|
+
|
967
|
+
(this.currentTableColumn = e),
|
968
|
+
(this.renderJson = e.render || ""),
|
969
|
+
(this.showRenderDialogFlag = !0);
|
518
970
|
},
|
519
971
|
saveColumnRender: function () {
|
520
|
-
this.$set(this.currentTableColumn,
|
972
|
+
this.$set(this.currentTableColumn, "render", this.renderJson),
|
973
|
+
(this.showRenderDialogFlag = !1);
|
521
974
|
},
|
522
975
|
closeHandle() {
|
523
|
-
this.$emit(
|
524
|
-
this.$emit(
|
976
|
+
this.$emit("update:visiable", false);
|
977
|
+
this.$emit("close");
|
525
978
|
},
|
526
979
|
// 添加同级节点
|
527
980
|
onAddSibling(row, index) {
|
528
|
-
console.log(
|
529
|
-
const parentId = row.parentId || null
|
981
|
+
console.log("onAddSibling", row, index);
|
982
|
+
const parentId = row.parentId || null;
|
530
983
|
// 先判断是不是根节点
|
531
984
|
if (!parentId) {
|
532
985
|
// 当前节点直接添加
|
533
986
|
// this.tableData.push(this.generateRow(parentId))
|
534
|
-
let addIndex =
|
535
|
-
|
987
|
+
let addIndex =
|
988
|
+
this.tableData
|
989
|
+
.filter((item) => !item.parentId)
|
990
|
+
.findIndex((item) => item.columnId == row.columnId) + 1;
|
991
|
+
this.tableData.splice(addIndex, 0, this.generateRow(parentId));
|
536
992
|
} else {
|
537
|
-
this.handleAddOneRow(row, index,
|
993
|
+
this.handleAddOneRow(row, index, "SIBLING");
|
538
994
|
}
|
539
995
|
},
|
540
996
|
// 添加子节点 todo
|
541
997
|
onAddChild(row, index) {
|
542
|
-
this.handleAddOneRow(row, index,
|
998
|
+
this.handleAddOneRow(row, index, "CHILD");
|
543
999
|
},
|
544
1000
|
/**
|
545
1001
|
* 处理添加一行数据
|
@@ -548,36 +1004,36 @@ export default {
|
|
548
1004
|
* @param {string} type 操作类型 SIBLING 同级 / CHILD 子级
|
549
1005
|
*/
|
550
1006
|
handleAddOneRow(row, index, type) {
|
551
|
-
|
552
|
-
const
|
553
|
-
|
554
|
-
let curRow = {}
|
1007
|
+
const { parentId, columnId } = row;
|
1008
|
+
const curId = type === "SIBLING" ? parentId : columnId;
|
1009
|
+
let curRow = {};
|
555
1010
|
// 在 tableData 中,找到当前节点
|
556
1011
|
const findRow = (data) => {
|
557
1012
|
data.forEach((item) => {
|
558
1013
|
if (item.columnId === curId) {
|
559
|
-
curRow = item
|
1014
|
+
curRow = item;
|
560
1015
|
}
|
561
1016
|
if (item.children && item.children.length) {
|
562
|
-
findRow(item.children)
|
1017
|
+
findRow(item.children);
|
563
1018
|
}
|
564
|
-
})
|
565
|
-
}
|
1019
|
+
});
|
1020
|
+
};
|
566
1021
|
|
567
|
-
findRow(this.tableData)
|
1022
|
+
findRow(this.tableData);
|
568
1023
|
|
569
|
-
const {columnId: generateParentId, children} = curRow
|
1024
|
+
const { columnId: generateParentId, children } = curRow;
|
570
1025
|
|
571
|
-
let newRow = this.generateRow(generateParentId)
|
1026
|
+
let newRow = this.generateRow(generateParentId);
|
572
1027
|
if (children) {
|
573
|
-
if (type ===
|
574
|
-
let addIndex =
|
575
|
-
|
1028
|
+
if (type === "SIBLING") {
|
1029
|
+
let addIndex =
|
1030
|
+
children.findIndex((item) => item.columnId == row.columnId) + 1;
|
1031
|
+
children.splice(addIndex, 0, newRow);
|
576
1032
|
} else {
|
577
|
-
children.push(newRow)
|
1033
|
+
children.push(newRow);
|
578
1034
|
}
|
579
1035
|
} else {
|
580
|
-
this.$set(curRow,
|
1036
|
+
this.$set(curRow, "children", [newRow]);
|
581
1037
|
}
|
582
1038
|
},
|
583
1039
|
getUuid() {
|
@@ -587,7 +1043,7 @@ export default {
|
|
587
1043
|
* 生成一行数据
|
588
1044
|
*/
|
589
1045
|
generateRow(parentId) {
|
590
|
-
let tmpId =
|
1046
|
+
let tmpId = "column" + generateId();
|
591
1047
|
let uuid = this.getUuid();
|
592
1048
|
var row = {
|
593
1049
|
columnId: uuid,
|
@@ -597,46 +1053,53 @@ export default {
|
|
597
1053
|
width: 150,
|
598
1054
|
prop: tmpId,
|
599
1055
|
label: tmpId,
|
600
|
-
align:
|
1056
|
+
align: "left",
|
601
1057
|
show: true,
|
602
1058
|
sortable: true,
|
603
|
-
|
1059
|
+
exportType: null,
|
1060
|
+
footerDataType: null,
|
1061
|
+
footerMethodConfg: null,
|
1062
|
+
widgetList: [],
|
1063
|
+
labelColor: null,
|
604
1064
|
// treeNode: false,
|
605
|
-
|
606
1065
|
};
|
607
1066
|
return row;
|
608
1067
|
},
|
609
1068
|
// 添加根节点
|
610
1069
|
onAddRoot() {
|
611
|
-
this.tableData.push(this.generateRow())
|
1070
|
+
this.tableData.push(this.generateRow());
|
612
1071
|
},
|
613
1072
|
// 删除当前节点及对应子节点数据
|
614
1073
|
onDelete(row) {
|
615
|
-
const {parentId, columnId} = row
|
1074
|
+
const { parentId, columnId } = row;
|
616
1075
|
// 根节点直接删除
|
617
1076
|
if (!parentId) {
|
618
|
-
const delIndex = this.tableData.findIndex(
|
619
|
-
|
1077
|
+
const delIndex = this.tableData.findIndex(
|
1078
|
+
(item) => item.columnId === columnId
|
1079
|
+
);
|
1080
|
+
this.tableData.splice(delIndex, 1);
|
620
1081
|
} else {
|
621
1082
|
// 找到父节点,通过父节点删除
|
622
|
-
let parentRow = {}
|
1083
|
+
let parentRow = {};
|
623
1084
|
const findRow = (data) => {
|
624
1085
|
data.forEach((item) => {
|
625
1086
|
if (item.columnId === parentId) {
|
626
|
-
parentRow = {...item}
|
1087
|
+
parentRow = { ...item };
|
627
1088
|
}
|
628
1089
|
if (item.children && item.children.length) {
|
629
|
-
findRow(item.children)
|
1090
|
+
findRow(item.children);
|
630
1091
|
}
|
631
|
-
})
|
632
|
-
}
|
633
|
-
findRow(this.tableData)
|
1092
|
+
});
|
1093
|
+
};
|
1094
|
+
findRow(this.tableData);
|
634
1095
|
|
635
|
-
const {children} = parentRow
|
1096
|
+
const { children } = parentRow;
|
636
1097
|
|
637
|
-
const delIndex = children.findIndex(
|
1098
|
+
const delIndex = children.findIndex(
|
1099
|
+
(item) => item.columnId === columnId
|
1100
|
+
);
|
638
1101
|
|
639
|
-
children.splice(delIndex, 1)
|
1102
|
+
children.splice(delIndex, 1);
|
640
1103
|
}
|
641
1104
|
},
|
642
1105
|
// 数据准备 生成 id 和 parentId
|
@@ -644,30 +1107,34 @@ export default {
|
|
644
1107
|
const tableFormat = (tableData, parentId) => {
|
645
1108
|
tableData.forEach((item) => {
|
646
1109
|
// item.parentId = parentId || null
|
647
|
-
if (!item.kid) item.kid = item.columnId
|
1110
|
+
if (!item.kid) item.kid = item.columnId;
|
648
1111
|
if (item.children && item.children.length > 0) {
|
649
|
-
tableFormat(item.children, item.columnId)
|
1112
|
+
tableFormat(item.children, item.columnId);
|
650
1113
|
}
|
651
|
-
})
|
652
|
-
}
|
1114
|
+
});
|
1115
|
+
};
|
653
1116
|
|
654
|
-
tableFormat(data)
|
655
|
-
return data
|
1117
|
+
tableFormat(data);
|
1118
|
+
return data;
|
656
1119
|
},
|
657
1120
|
//drag begin
|
658
1121
|
//行拖拽
|
659
1122
|
rowDrop() {
|
660
|
-
if (this.dragSort) this.dragSort.destroy() // 防止在Dom上重复绑定事件
|
1123
|
+
if (this.dragSort) this.dragSort.destroy(); // 防止在Dom上重复绑定事件
|
661
1124
|
// const tbody = document.querySelector('.drag .el-table__body-wrapper tbody');
|
662
|
-
var tbody = this.$refs.singleTable.$el.querySelectorAll(
|
1125
|
+
var tbody = this.$refs.singleTable.$el.querySelectorAll(
|
1126
|
+
".el-table__fixed-body-wrapper > table > tbody"
|
1127
|
+
)[0];
|
663
1128
|
const _this = this;
|
664
1129
|
this.dragSort = Sortable.create(tbody, {
|
665
|
-
ghostClass:
|
1130
|
+
ghostClass: "sortable-ghost",
|
1131
|
+
// draggable: ".drag-option", // 修改可拖拽元素
|
1132
|
+
handle: ".drag-option", // 指定拖动按钮
|
666
1133
|
setData: function (e) {
|
667
|
-
e.setData(
|
1134
|
+
e.setData("Text", "");
|
668
1135
|
},
|
669
|
-
onEnd({newIndex, oldIndex}) {
|
670
|
-
_this.rowDropEnd(newIndex, oldIndex)
|
1136
|
+
onEnd({ newIndex, oldIndex }) {
|
1137
|
+
_this.rowDropEnd(newIndex, oldIndex);
|
671
1138
|
},
|
672
1139
|
});
|
673
1140
|
},
|
@@ -678,7 +1145,7 @@ export default {
|
|
678
1145
|
data.forEach((item) => {
|
679
1146
|
const loop = (data) => {
|
680
1147
|
result.push({
|
681
|
-
...data
|
1148
|
+
...data,
|
682
1149
|
});
|
683
1150
|
let child = data.children;
|
684
1151
|
if (child) {
|
@@ -694,7 +1161,9 @@ export default {
|
|
694
1161
|
//数组转树
|
695
1162
|
arrToTree(arr, parentId) {
|
696
1163
|
return arr
|
697
|
-
.filter((item) =>
|
1164
|
+
.filter((item) =>
|
1165
|
+
!parentId ? !item.parentId : item.parentId === parentId
|
1166
|
+
)
|
698
1167
|
.map((item) => {
|
699
1168
|
item.children = this.arrToTree(arr, item.columnId);
|
700
1169
|
return item;
|
@@ -732,13 +1201,7 @@ export default {
|
|
732
1201
|
let newRow = this.tableDataArray[newIndex];
|
733
1202
|
|
734
1203
|
//判断是否把该行 拖拽到 自己的底级中
|
735
|
-
if (
|
736
|
-
this.isTreeBottom(
|
737
|
-
this.tableData,
|
738
|
-
oldRow.columnId,
|
739
|
-
newRow.columnId
|
740
|
-
)
|
741
|
-
) {
|
1204
|
+
if (this.isTreeBottom(this.tableData, oldRow.columnId, newRow.columnId)) {
|
742
1205
|
this.$message({
|
743
1206
|
type: "error",
|
744
1207
|
message: "不能放到子节点",
|
@@ -784,72 +1247,101 @@ export default {
|
|
784
1247
|
let isButtontCell = false;
|
785
1248
|
let widgetType = this.columnFormatMap[formatS];
|
786
1249
|
if (widgetType) {
|
787
|
-
isButtontCell = widgetType ===
|
1250
|
+
isButtontCell = widgetType === "a-link" || widgetType === "button";
|
788
1251
|
}
|
789
1252
|
return isButtontCell;
|
790
1253
|
},
|
791
1254
|
//drag end
|
792
|
-
changeFormatS(row) {
|
793
|
-
let
|
794
|
-
let
|
795
|
-
let
|
796
|
-
|
797
|
-
|
798
|
-
|
799
|
-
|
800
|
-
|
801
|
-
|
802
|
-
|
803
|
-
row.prop = null;
|
804
|
-
row.label = null;
|
805
|
-
row.sortable = false;
|
806
|
-
row.width = 150;
|
807
|
-
} else if (isButtontCell) {
|
808
|
-
if (row.formatS == 'aLink' || row.formatS == 'button') {
|
809
|
-
if (!row.width || row.width == 47) row.width = 150;
|
1255
|
+
changeFormatS(row, isEdit) {
|
1256
|
+
let formatS = isEdit ? row.editFormatS : row.formatS;
|
1257
|
+
let isButtontCell = this.getIsButtontCell(formatS);
|
1258
|
+
// let columnWidgetConfig = this.getColumnWidgetConfig(row, true, isEdit);
|
1259
|
+
// let { columnSelectedWidget, columnEditFields } = columnWidgetConfig;
|
1260
|
+
let columnSelectedWidget = this.designer.createColumnWidget(row, isEdit)
|
1261
|
+
if (!isEdit) {
|
1262
|
+
//格式化类型
|
1263
|
+
if (columnSelectedWidget) {
|
1264
|
+
row.columnOption = columnSelectedWidget.options;
|
1265
|
+
row.widget = columnSelectedWidget;
|
810
1266
|
} else {
|
811
|
-
row.
|
1267
|
+
row.columnOption = {};
|
1268
|
+
row.widget = null;
|
812
1269
|
}
|
813
|
-
row.prop = null;
|
814
|
-
row.label = null;
|
815
|
-
row.sortable = false;
|
816
1270
|
} else {
|
817
|
-
|
818
|
-
if (
|
819
|
-
|
820
|
-
|
821
|
-
|
1271
|
+
//编辑插槽类型
|
1272
|
+
if (columnSelectedWidget) {
|
1273
|
+
row.columnOption = columnSelectedWidget.options;
|
1274
|
+
row.editWidget = columnSelectedWidget;
|
1275
|
+
} else {
|
1276
|
+
row.editColumnOption = {};
|
1277
|
+
row.editWidget = null;
|
1278
|
+
}
|
1279
|
+
}
|
822
1280
|
|
823
|
-
|
824
|
-
|
1281
|
+
if (!isEdit) {
|
1282
|
+
if (row.formatS == "editTreeButtonGroup") {
|
1283
|
+
row.prop = null;
|
1284
|
+
row.label = null;
|
1285
|
+
row.sortable = false;
|
1286
|
+
row.width = 150;
|
1287
|
+
} else if (isButtontCell) {
|
1288
|
+
if (row.formatS == "aLink" || row.formatS == "button") {
|
1289
|
+
if (!row.width || row.width == 47) row.width = 150;
|
1290
|
+
} else {
|
1291
|
+
row.width = 47;
|
1292
|
+
}
|
1293
|
+
row.prop = null;
|
1294
|
+
row.label = null;
|
1295
|
+
row.sortable = false;
|
825
1296
|
} else {
|
826
|
-
let
|
827
|
-
row.
|
1297
|
+
let tmpId = "column" + generateId();
|
1298
|
+
if (!row.width || row.width == 47) row.width = 150;
|
1299
|
+
if (!row.prop) row.prop = tmpId;
|
1300
|
+
if (!row.label) row.label = tmpId;
|
1301
|
+
|
1302
|
+
if (this.userFields.includes(row.formatS)) {
|
1303
|
+
let item = this.businessOptions.find(
|
1304
|
+
(item) => item.value == row.formatS
|
1305
|
+
);
|
1306
|
+
if (item) {
|
1307
|
+
row.prop = item.value;
|
1308
|
+
row.label = item.label;
|
1309
|
+
}
|
1310
|
+
}
|
1311
|
+
|
1312
|
+
row.sortable = true;
|
1313
|
+
|
1314
|
+
if (row.formatS == "editAttachment") {
|
1315
|
+
row.prop = this.designer.createAttachmentKeyName();
|
1316
|
+
} else {
|
1317
|
+
let attachmentPrefix = this.designer.getAttachmentPrefix();
|
1318
|
+
row.prop = row.prop.replaceAll(attachmentPrefix, "");
|
1319
|
+
}
|
828
1320
|
}
|
829
1321
|
}
|
830
1322
|
},
|
831
1323
|
getColumnWidgetConfig(row, isChange, isEdit) {
|
832
|
-
let formatS = isEdit ? row.editFormatS : row.formatS
|
1324
|
+
let formatS = isEdit ? row.editFormatS : row.formatS;
|
833
1325
|
let columnSelectedWidget = null;
|
834
1326
|
let columnEditFields = null;
|
835
1327
|
|
836
1328
|
let type = this.columnFormatMap[formatS];
|
837
|
-
/*if (type == 'date') {
|
838
|
-
columnEditFields = ['type', 'format', 'valueFormat']
|
839
|
-
} else if (type == 'select') {
|
840
|
-
|
841
|
-
}
|
842
|
-
if (type == 'vabsearch') {
|
843
|
-
columnEditFields = ['vabSearchField', 'formCode', 'formVersion', 'required', 'showFormField', 'onSearchConfirm', 'onSearchClear']
|
844
|
-
}*/
|
845
1329
|
|
846
1330
|
if (type) {
|
847
1331
|
// columnSelectedWidget = this.$baseLodash.cloneDeep(this.designer.getFieldWidgetByType(type));
|
848
|
-
columnSelectedWidget = this.designer.copyNewFieldWidget(
|
1332
|
+
columnSelectedWidget = this.designer.copyNewFieldWidget(
|
1333
|
+
this.designer.getFieldWidgetByType(type)
|
1334
|
+
);
|
849
1335
|
/*let tmpId = generateId();
|
850
1336
|
let idVal = row.prop ? row.prop : (type + tmpId);*/
|
851
1337
|
/*columnSelectedWidget.id = idVal;*/
|
852
1338
|
// columnSelectedWidget.options.name = idVal;
|
1339
|
+
/*if (isEdit) {
|
1340
|
+
columnSelectedWidget.id = "edit_" + row.columnId;
|
1341
|
+
} else {
|
1342
|
+
columnSelectedWidget.id = row.columnId;
|
1343
|
+
}*/
|
1344
|
+
// columnSelectedWidget.id = row.columnId;
|
853
1345
|
let columnOption;
|
854
1346
|
if (!isEdit) {
|
855
1347
|
columnOption = row.columnOption;
|
@@ -859,61 +1351,70 @@ export default {
|
|
859
1351
|
if (!isChange && columnOption && Object.keys(columnOption).length) {
|
860
1352
|
columnOption.required = row.required || false;
|
861
1353
|
columnSelectedWidget.options = columnOption;
|
862
|
-
if (
|
863
|
-
columnSelectedWidget.options.hiddenByWf =
|
864
|
-
|
865
|
-
|
866
|
-
|
1354
|
+
if ("editDelete" == formatS) {
|
1355
|
+
columnSelectedWidget.options.hiddenByWf =
|
1356
|
+
columnSelectedWidget.options.hiddenByWf ?? true;
|
1357
|
+
columnSelectedWidget.options.prefixIcon =
|
1358
|
+
columnSelectedWidget.options.prefixIcon || "el-icon-delete";
|
1359
|
+
} else if ("editButton" == formatS) {
|
1360
|
+
columnSelectedWidget.options.prefixIcon =
|
1361
|
+
columnSelectedWidget.options.prefixIcon || "el-icon-edit";
|
867
1362
|
}
|
868
1363
|
} else {
|
869
1364
|
columnSelectedWidget.options.required = row.required || false;
|
870
1365
|
|
871
|
-
if (
|
1366
|
+
if ("editDelete" == formatS) {
|
872
1367
|
columnSelectedWidget.options.prefixIcon = "el-icon-delete";
|
873
1368
|
columnSelectedWidget.options.label = "删除";
|
874
1369
|
columnSelectedWidget.options.labelHidden = true;
|
875
1370
|
columnSelectedWidget.options.hiddenByWf = true;
|
876
|
-
columnSelectedWidget.options.onClick =
|
877
|
-
|
1371
|
+
columnSelectedWidget.options.onClick =
|
1372
|
+
"let tableParam = this.tableParam;\nlet tableRef = this.getWidgetRef(this.parentWidget.options.name);\ntableRef.deleteRow(tableParam.row,tableParam.rowIndex);";
|
1373
|
+
} else if ("editButton" == formatS) {
|
878
1374
|
columnSelectedWidget.options.prefixIcon = "el-icon-edit";
|
879
1375
|
columnSelectedWidget.options.label = "查看";
|
880
1376
|
columnSelectedWidget.options.labelHidden = true;
|
881
|
-
columnSelectedWidget.options.onClick =
|
882
|
-
|
1377
|
+
columnSelectedWidget.options.onClick =
|
1378
|
+
"let tableParam = this.tableParam;\nlet tableRef = this.getWidgetRef(this.parentWidget.options.name);\ntableRef.openEditDialog(tableParam.row)";
|
1379
|
+
} else if ("addSiblingEditRow" == formatS) {
|
883
1380
|
columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
884
1381
|
columnSelectedWidget.options.label = "新增兄弟节点";
|
885
1382
|
columnSelectedWidget.options.labelHidden = false;
|
886
|
-
columnSelectedWidget.options.onClick =
|
887
|
-
|
1383
|
+
columnSelectedWidget.options.onClick =
|
1384
|
+
"let tableParam = this.tableParam;\nthis.getParentTarget().addSiblingTreeRow(null,tableParam);";
|
1385
|
+
} else if ("addChildTreeRow" == formatS) {
|
888
1386
|
columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
889
1387
|
columnSelectedWidget.options.label = "新增子节点";
|
890
1388
|
columnSelectedWidget.options.labelHidden = false;
|
891
|
-
columnSelectedWidget.options.onClick =
|
892
|
-
|
1389
|
+
columnSelectedWidget.options.onClick =
|
1390
|
+
"let tableParam = this.tableParam;\nthis.getParentTarget().addChildTreeRow(null,tableParam);";
|
1391
|
+
} else if ("moveUpRow" == formatS) {
|
893
1392
|
// columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
894
1393
|
columnSelectedWidget.options.label = "↑上移";
|
895
1394
|
columnSelectedWidget.options.labelHidden = false;
|
896
|
-
columnSelectedWidget.options.onClick =
|
897
|
-
|
1395
|
+
columnSelectedWidget.options.onClick =
|
1396
|
+
"let tableParam = this.tableParam;\nthis.getParentTarget().moveUpRow(tableParam);";
|
1397
|
+
} else if ("moveDownRow" == formatS) {
|
898
1398
|
// columnSelectedWidget.options.prefixIcon = "el-icon-plus";
|
899
1399
|
columnSelectedWidget.options.label = "↓下移";
|
900
1400
|
columnSelectedWidget.options.labelHidden = false;
|
901
|
-
columnSelectedWidget.options.onClick =
|
902
|
-
|
1401
|
+
columnSelectedWidget.options.onClick =
|
1402
|
+
"let tableParam = this.tableParam;\nthis.getParentTarget().moveDownRow(tableParam);";
|
1403
|
+
} else if ("removeTreeRow" == formatS) {
|
903
1404
|
columnSelectedWidget.options.prefixIcon = "el-icon-delete";
|
904
1405
|
columnSelectedWidget.options.label = "删除";
|
905
1406
|
columnSelectedWidget.options.labelHidden = true;
|
906
|
-
columnSelectedWidget.options.onClick =
|
1407
|
+
columnSelectedWidget.options.onClick =
|
1408
|
+
"let tableParam = this.tableParam;\nthis.getParentTarget().removeTreeRow(tableParam);";
|
907
1409
|
}
|
908
1410
|
|
909
1411
|
columnOption = columnSelectedWidget.options;
|
910
|
-
|
911
1412
|
}
|
912
1413
|
|
913
1414
|
// columnSelectedWidget.options.name = isEdit? (type + row.columnId) : row.prop;
|
914
1415
|
// columnSelectedWidget.options.name = type + row.columnId;
|
915
1416
|
// columnSelectedWidget.options.name = row.prop;
|
916
|
-
if (columnSelectedWidget.options.hasOwnProperty(
|
1417
|
+
if (columnSelectedWidget.options.hasOwnProperty("keyName")) {
|
917
1418
|
columnSelectedWidget.options.keyName = row.prop;
|
918
1419
|
columnSelectedWidget.options.keyNameEnabled = true;
|
919
1420
|
} else {
|
@@ -925,10 +1426,75 @@ export default {
|
|
925
1426
|
columnSelectedWidget.options.labelHidden = true;
|
926
1427
|
}
|
927
1428
|
}
|
928
|
-
return {columnSelectedWidget, columnEditFields};
|
1429
|
+
return { columnSelectedWidget, columnEditFields };
|
1430
|
+
},
|
1431
|
+
findColumnByColumnId(columnList, columnId) {
|
1432
|
+
let result = null;
|
1433
|
+
if (columnList) {
|
1434
|
+
let column = columnList.find((item) => item.columnId == columnId);
|
1435
|
+
if (!column) {
|
1436
|
+
}
|
1437
|
+
for (let column of columnList) {
|
1438
|
+
if (column.columnId == columnId) {
|
1439
|
+
result = column;
|
1440
|
+
break;
|
1441
|
+
} else if (column.children && column.children.length) {
|
1442
|
+
let subColumn = this.findColumnByColumnId(
|
1443
|
+
column.children,
|
1444
|
+
children
|
1445
|
+
);
|
1446
|
+
if (subColumn) {
|
1447
|
+
result = subColumn;
|
1448
|
+
break;
|
1449
|
+
}
|
1450
|
+
}
|
1451
|
+
}
|
1452
|
+
}
|
1453
|
+
return result;
|
1454
|
+
},
|
1455
|
+
|
1456
|
+
getRowWidget(row) {
|
1457
|
+
let widget = row.widget;
|
1458
|
+
if (!widget) {
|
1459
|
+
widget.options.a = a;
|
1460
|
+
widget.options.a = a;
|
1461
|
+
}
|
1462
|
+
return widget;
|
929
1463
|
},
|
930
1464
|
openFormatConfigDialog(row, index) {
|
931
|
-
|
1465
|
+
if (row.formatS == "widgetRender") {
|
1466
|
+
let formWidgetList = deepClone(this.designer.widgetList);
|
1467
|
+
let tableData = deepClone(this.tableData);
|
1468
|
+
let columnId = row.columnId;
|
1469
|
+
|
1470
|
+
let dataTableName = this.optionModel.name;
|
1471
|
+
|
1472
|
+
let targetColumn = null;
|
1473
|
+
loopHandleWidget(formWidgetList, (item) => {
|
1474
|
+
if (item.options.name == dataTableName) {
|
1475
|
+
item.options.tableColumns = tableData;
|
1476
|
+
targetColumn = this.findColumnByColumnId(
|
1477
|
+
item.options.tableColumns,
|
1478
|
+
columnId
|
1479
|
+
);
|
1480
|
+
}
|
1481
|
+
});
|
1482
|
+
let getWidgetList = (subWidgetList = []) => {
|
1483
|
+
targetColumn.widgetList = this.$baseLodash.cloneDeep(subWidgetList);
|
1484
|
+
return formWidgetList;
|
1485
|
+
};
|
1486
|
+
let sourceData = {
|
1487
|
+
formWidgetList,
|
1488
|
+
dataTableName,
|
1489
|
+
columnId,
|
1490
|
+
getWidgetList,
|
1491
|
+
};
|
1492
|
+
|
1493
|
+
this.openWidgetRenderDialog(row, sourceData);
|
1494
|
+
return;
|
1495
|
+
}
|
1496
|
+
|
1497
|
+
/*let option = row.columnOption;
|
932
1498
|
let selectedWidget;
|
933
1499
|
let columnWidgetConfig = this.getColumnWidgetConfig(row);
|
934
1500
|
let {columnSelectedWidget, columnEditFields} = columnWidgetConfig;
|
@@ -936,35 +1502,45 @@ export default {
|
|
936
1502
|
option = columnSelectedWidget.options;
|
937
1503
|
selectedWidget = columnSelectedWidget;
|
938
1504
|
} else {
|
939
|
-
option = {}
|
1505
|
+
option = {};
|
940
1506
|
selectedWidget = {};
|
941
1507
|
}
|
942
1508
|
|
943
1509
|
let columnOption = this.$baseLodash.cloneDeep(option);
|
944
|
-
row.columnOption = columnOption
|
1510
|
+
row.columnOption = columnOption;*/
|
1511
|
+
let selectedWidget = row.widget;
|
945
1512
|
this.operateIndex = index;
|
946
1513
|
|
1514
|
+
let tableColumns = this.tableData;
|
947
1515
|
this.openWidgetPropertyDialog({
|
948
1516
|
row: row,
|
949
1517
|
columnSelectedWidget: selectedWidget,
|
1518
|
+
tableColumns,
|
950
1519
|
index: index,
|
951
|
-
columnEditFields: columnEditFields,
|
1520
|
+
// columnEditFields: columnEditFields,
|
952
1521
|
callback: (columnOption) => {
|
953
|
-
this.confirmFormatConfigDialog(columnOption);
|
954
|
-
}
|
955
|
-
})
|
1522
|
+
this.confirmFormatConfigDialog(columnOption, row);
|
1523
|
+
},
|
1524
|
+
});
|
956
1525
|
},
|
957
1526
|
getFieldKeyNameByOptions(options) {
|
958
1527
|
let o = options.name;
|
959
|
-
return (
|
960
|
-
(options.keyNameEnabled
|
961
|
-
&& options.keyName)
|
962
|
-
|| o
|
963
|
-
);
|
1528
|
+
return (options.keyNameEnabled && options.keyName) || o;
|
964
1529
|
},
|
965
|
-
confirmFormatConfigDialog(columnOption) {
|
966
|
-
let row = this.tableData[this.operateIndex];
|
1530
|
+
confirmFormatConfigDialog(columnOption, row) {
|
1531
|
+
// let row = this.tableData[this.operateIndex];
|
967
1532
|
row.columnOption = columnOption;
|
1533
|
+
|
1534
|
+
if (row.widget) {
|
1535
|
+
row.widget.options = columnOption;
|
1536
|
+
} else {
|
1537
|
+
let type = this.columnFormatMap[row.formatS];
|
1538
|
+
let fieldWidget = this.designer.createColumnWidget(row, false);
|
1539
|
+
fieldWidget.options = columnOption;
|
1540
|
+
row.widget = fieldWidget;
|
1541
|
+
this.$forceUpdate();
|
1542
|
+
}
|
1543
|
+
|
968
1544
|
let isButtontCell = this.getIsButtontCell(row.formatS);
|
969
1545
|
if (!isButtontCell) {
|
970
1546
|
row.prop = this.getFieldKeyNameByOptions(columnOption);
|
@@ -973,74 +1549,147 @@ export default {
|
|
973
1549
|
}
|
974
1550
|
},
|
975
1551
|
openEditFormatConfigDialog(row, index) {
|
976
|
-
let option = row.columnOption;
|
977
|
-
let selectedWidget;
|
978
|
-
let columnWidgetConfig = this.getColumnWidgetConfig(row, null, true);
|
979
|
-
let {columnSelectedWidget, columnEditFields} = columnWidgetConfig;
|
980
|
-
if (columnSelectedWidget) {
|
981
|
-
option = columnSelectedWidget.options;
|
982
|
-
selectedWidget = columnSelectedWidget;
|
983
|
-
} else {
|
984
|
-
option = {}
|
985
|
-
selectedWidget = {};
|
986
|
-
}
|
987
1552
|
|
988
|
-
let
|
989
|
-
row.editColumnOption = columnOption;
|
1553
|
+
let selectedWidget = row.editWidget;
|
990
1554
|
this.operateIndex = index;
|
991
1555
|
|
1556
|
+
let tableColumns = this.tableData;
|
992
1557
|
this.openWidgetPropertyDialog({
|
993
1558
|
row: row,
|
1559
|
+
tableColumns,
|
994
1560
|
columnSelectedWidget: selectedWidget,
|
995
1561
|
index: index,
|
996
|
-
columnEditFields: columnEditFields,
|
1562
|
+
// columnEditFields: columnEditFields,
|
997
1563
|
callback: (columnOption) => {
|
998
|
-
this.confirmEditFormatConfigDialog(columnOption);
|
999
|
-
}
|
1000
|
-
})
|
1564
|
+
this.confirmEditFormatConfigDialog(columnOption, row);
|
1565
|
+
},
|
1566
|
+
});
|
1001
1567
|
},
|
1002
|
-
confirmEditFormatConfigDialog(columnOption) {
|
1003
|
-
let row = this.tableData[this.operateIndex];
|
1568
|
+
confirmEditFormatConfigDialog(columnOption, row) {
|
1569
|
+
// let row = this.tableData[this.operateIndex];
|
1004
1570
|
row.editColumnOption = columnOption;
|
1571
|
+
// row.editWidget.options = columnOption;
|
1572
|
+
|
1573
|
+
if (row.editWidget) {
|
1574
|
+
row.editWidget.options = columnOption;
|
1575
|
+
} else {
|
1576
|
+
let type = this.columnFormatMap[row.editFormatS];
|
1577
|
+
let fieldWidget = this.designer.createColumnWidget(row, true);
|
1578
|
+
fieldWidget.options = columnOption;
|
1579
|
+
row.editWidget = fieldWidget;
|
1580
|
+
this.$forceUpdate();
|
1581
|
+
}
|
1582
|
+
|
1005
1583
|
/*row.prop = columnOption.name;
|
1006
1584
|
row.label = columnOption.label;
|
1007
1585
|
row.required = columnOption.required;*/
|
1008
1586
|
},
|
1009
1587
|
openTableColumnConfigDialog(row, index) {
|
1010
1588
|
this.operateIndex = index;
|
1589
|
+
this.currentTableColumn = row;
|
1011
1590
|
let eventName = "tableColumnConfig";
|
1012
|
-
let eventParams = ["dataId", "formCode"]
|
1013
|
-
this.tableColumnConfigHeader = `${
|
1014
|
-
|
1591
|
+
let eventParams = ["dataId", "formCode"];
|
1592
|
+
this.tableColumnConfigHeader = `${
|
1593
|
+
this.optionModel.name
|
1594
|
+
}.${eventName}(${eventParams.join(", ")}) {`;
|
1595
|
+
this.tableColumnConfigCode = this.$baseLodash.cloneDeep(
|
1596
|
+
row.tableColumnConfig || ""
|
1597
|
+
);
|
1015
1598
|
|
1016
1599
|
this.tableColumnConfigTitle = `自定义表格列属性配置(${row.label})`;
|
1017
1600
|
this.showTableColumnConfigDialog = true;
|
1018
1601
|
},
|
1019
1602
|
saveTableColumnConfigDialog() {
|
1020
|
-
let row = this.tableData[this.operateIndex];
|
1603
|
+
// let row = this.tableData[this.operateIndex];
|
1604
|
+
let row = this.currentTableColumn;
|
1021
1605
|
const codeHints = this.$refs.ecEditor.getEditorAnnotations();
|
1022
1606
|
let syntaxErrorFlag = false;
|
1023
1607
|
if (!!codeHints && codeHints.length > 0) {
|
1024
|
-
codeHints.forEach(chItem => {
|
1025
|
-
if (chItem.type ===
|
1608
|
+
codeHints.forEach((chItem) => {
|
1609
|
+
if (chItem.type === "error") {
|
1026
1610
|
syntaxErrorFlag = true;
|
1027
1611
|
}
|
1028
1612
|
});
|
1029
1613
|
|
1030
1614
|
if (syntaxErrorFlag) {
|
1031
|
-
this.$message.error(
|
1615
|
+
this.$message.error(
|
1616
|
+
this.i18nt("designer.setting.syntaxCheckWarning")
|
1617
|
+
);
|
1032
1618
|
return;
|
1033
1619
|
}
|
1034
1620
|
}
|
1035
|
-
this.$set(
|
1621
|
+
this.$set(
|
1622
|
+
row,
|
1623
|
+
"tableColumnConfig",
|
1624
|
+
this.$baseLodash.cloneDeep(this.tableColumnConfigCode)
|
1625
|
+
);
|
1036
1626
|
this.showTableColumnConfigDialog = false;
|
1627
|
+
},
|
1628
|
+
changeRowLabel(row) {
|
1629
|
+
this.setRowWidgetAttars(row, "label", row.label);
|
1630
|
+
},
|
1631
|
+
changeRowProp(row) {
|
1632
|
+
this.setRowWidgetAttars(row, "keyName", row.prop);
|
1633
|
+
},
|
1634
|
+
changeRowRequired(row) {
|
1635
|
+
this.setRowWidgetAttars(row, "required", row.required);
|
1636
|
+
},
|
1637
|
+
setRowWidgetAttars(row, key, value) {
|
1638
|
+
let type1 = this.columnFormatMap[row.formatS];
|
1639
|
+
let type2 = this.columnFormatMap[row.editFormatS];
|
1640
|
+
let newWidget = type1
|
1641
|
+
? this.designer.copyNewFieldWidget(
|
1642
|
+
this.designer.getFieldWidgetByType(type1)
|
1643
|
+
)
|
1644
|
+
: null;
|
1645
|
+
|
1646
|
+
let newEditWidget = type2
|
1647
|
+
? this.designer.copyNewFieldWidget(
|
1648
|
+
this.designer.getFieldWidgetByType(type2)
|
1649
|
+
)
|
1650
|
+
: null;
|
1651
|
+
|
1652
|
+
if (newWidget.formItemFlag) {
|
1653
|
+
if (row.widget) {
|
1654
|
+
if (row.widget.options[key] !== undefined)
|
1655
|
+
row.widget.options[key] = value;
|
1656
|
+
}
|
1657
|
+
if (row.columnOption) {
|
1658
|
+
if (row.columnOption[key] !== undefined)
|
1659
|
+
row.columnOption[key] = value;
|
1660
|
+
}
|
1661
|
+
}
|
1037
1662
|
|
1663
|
+
if (newWidget.formItemFlag) {
|
1664
|
+
if (row.editWidget) {
|
1665
|
+
if (row.editWidget.options[key] !== undefined)
|
1666
|
+
row.editWidget.options[key] = value;
|
1667
|
+
}
|
1668
|
+
if (row.editColumnOption) {
|
1669
|
+
if (row.editColumnOption[key] !== undefined)
|
1670
|
+
row.editColumnOption[key] = value;
|
1671
|
+
}
|
1672
|
+
}
|
1038
1673
|
},
|
1039
|
-
|
1040
|
-
|
1674
|
+
openRowEditDialog(row, index) {
|
1675
|
+
this.editRowData = row;
|
1676
|
+
this.rowData = this.$baseLodash.cloneDeep(row);
|
1677
|
+
this.rowDataIndex = index;
|
1678
|
+
this.showRowEditDialog = true;
|
1679
|
+
},
|
1680
|
+
submitRowEditDialog() {
|
1681
|
+
Object.assign(this.editRowData, this.$baseLodash.cloneDeep(this.rowData));
|
1682
|
+
// this.editRowData = this.$baseLodash.cloneDeep(this.rowData);
|
1683
|
+
this.showRowEditDialog = false;
|
1684
|
+
},
|
1685
|
+
closeRowEditDialog() {
|
1686
|
+
this.showRowEditDialog = false;
|
1687
|
+
},
|
1688
|
+
},
|
1689
|
+
};
|
1041
1690
|
</script>
|
1042
1691
|
<style scoped lang="scss">
|
1043
1692
|
.icon-drag:before {
|
1044
|
-
content:
|
1693
|
+
content: "\e61d";
|
1045
1694
|
}
|
1046
1695
|
</style>
|