vue2-client 1.18.29 → 1.18.31
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/.eslintrc.js +90 -90
- package/Components.md +60 -60
- package/docs/index.md +30 -30
- package/index.js +31 -31
- package/jest-transform-stub.js +8 -8
- package/jest.setup.js +7 -7
- package/package.json +1 -1
- package/src/assets/img/querySlotDemo.svg +15 -15
- package/src/base-client/components/common/AmapMarker/AmapPointRendering.vue +120 -120
- package/src/base-client/components/common/CitySelect/index.js +3 -3
- package/src/base-client/components/common/CitySelect/index.md +109 -109
- package/src/base-client/components/common/CreateQuery/CreateQuery.vue +669 -669
- package/src/base-client/components/common/CreateQuery/index.js +3 -3
- package/src/base-client/components/common/CreateQuery/index.md +42 -42
- package/src/base-client/components/common/CreateSimpleFormQuery/index.js +3 -3
- package/src/base-client/components/common/CreateSimpleFormQuery/index.md +42 -42
- package/src/base-client/components/common/FormGroupEdit/index.js +3 -3
- package/src/base-client/components/common/FormGroupEdit/index.md +43 -43
- package/src/base-client/components/common/FormGroupQuery/FormGroupQuery.vue +166 -166
- package/src/base-client/components/common/FormGroupQuery/index.js +3 -3
- package/src/base-client/components/common/FormGroupQuery/index.md +43 -43
- package/src/base-client/components/common/JSONToTree/jsontotree.vue +271 -271
- package/src/base-client/components/common/PersonSetting/PersonSetting.vue +208 -208
- package/src/base-client/components/common/PersonSetting/index.js +3 -3
- package/src/base-client/components/common/Tree/Tree.vue +149 -149
- package/src/base-client/components/common/Tree/index.js +2 -2
- package/src/base-client/components/common/Upload/index.js +3 -3
- package/src/base-client/components/common/XAddNativeForm/index.md +146 -146
- package/src/base-client/components/common/XCard/XCard.vue +64 -64
- package/src/base-client/components/common/XDataDrawer/XDataDrawer.vue +180 -180
- package/src/base-client/components/common/XDataDrawer/index.js +3 -3
- package/src/base-client/components/common/XDataDrawer/index.md +41 -41
- package/src/base-client/components/common/XDescriptions/index.js +3 -3
- package/src/base-client/components/common/XDescriptions/index.md +322 -322
- package/src/base-client/components/common/XForm/index.md +178 -178
- package/src/base-client/components/common/XFormTable/XFormTable.vue +71 -64
- package/src/base-client/components/common/XStepView/XStepView.vue +252 -252
- package/src/base-client/components/common/XStepView/index.js +3 -3
- package/src/base-client/components/common/XStepView/index.md +31 -31
- package/src/base-client/components/common/XTable/XTable.vue +1715 -1710
- package/src/base-client/components/common/XTable/XTableWrapper.vue +8 -3
- package/src/base-client/components/common/XTable/index.md +255 -255
- package/src/base-client/components/his/HChart/HChart.vue +35 -9
- package/src/base-client/components/his/HChart/demo.vue +88 -88
- package/src/base-client/components/his/HChart/index.md +798 -798
- package/src/base-client/components/his/XIcon/XIcon.vue +73 -73
- package/src/base-client/components/his/XIcon/index.js +3 -3
- package/src/base-client/components/his/XIcon/index.md +177 -177
- package/src/base-client/components/system/DictionaryDetailsView/DictionaryDetailsView.vue +232 -232
- package/src/base-client/plugins/Config.js +19 -19
- package/src/base-client/plugins/tabs-page-plugin.js +39 -39
- package/src/components/Charts/Bar.vue +62 -62
- package/src/components/Charts/ChartCard.vue +134 -134
- package/src/components/Charts/Liquid.vue +67 -67
- package/src/components/Charts/MiniArea.vue +39 -39
- package/src/components/Charts/MiniBar.vue +39 -39
- package/src/components/Charts/MiniProgress.vue +75 -75
- package/src/components/Charts/MiniSmoothArea.vue +40 -40
- package/src/components/Charts/Radar.vue +68 -68
- package/src/components/Charts/RankList.vue +77 -77
- package/src/components/Charts/TagCloud.vue +113 -113
- package/src/components/Charts/TransferBar.vue +64 -64
- package/src/components/Charts/Trend.vue +82 -82
- package/src/components/Charts/chart.less +12 -12
- package/src/components/Charts/smooth.area.less +13 -13
- package/src/components/NumberInfo/NumberInfo.vue +54 -54
- package/src/components/NumberInfo/index.js +3 -3
- package/src/components/NumberInfo/index.less +54 -54
- package/src/components/NumberInfo/index.md +43 -43
- package/src/components/STable/index.js +10 -1
- package/src/components/card/ChartCard.vue +79 -79
- package/src/components/chart/Bar.vue +60 -60
- package/src/components/chart/MiniArea.vue +67 -67
- package/src/components/chart/MiniBar.vue +59 -59
- package/src/components/chart/MiniProgress.vue +57 -57
- package/src/components/chart/Radar.vue +80 -80
- package/src/components/chart/RankingList.vue +60 -60
- package/src/components/chart/Trend.vue +79 -79
- package/src/components/chart/index.less +9 -9
- package/src/components/checkbox/ColorCheckbox.vue +157 -157
- package/src/components/input/IInput.vue +66 -66
- package/src/components/menu/SideMenu.vue +75 -75
- package/src/components/menu/menu.js +273 -273
- package/src/components/tool/AStepItem.vue +60 -60
- package/src/layouts/CommonLayout.vue +56 -56
- package/src/layouts/header/HeaderNotice.vue +177 -177
- package/src/lib.js +1 -1
- package/src/mock/extend/index.js +84 -84
- package/src/mock/goods/index.js +108 -108
- package/src/pages/dashboard/workplace/WorkPlace.vue +141 -141
- package/src/pages/system/dictionary/index.vue +44 -44
- package/src/pages/system/monitor/loginInfor/index.vue +37 -37
- package/src/pages/system/monitor/operLog/index.vue +37 -37
- package/src/services/api/cas.js +79 -79
- package/src/store/modules/setting.js +119 -119
- package/src/utils/authority-utils.js +85 -85
- package/src/utils/errorCode.js +6 -6
- package//350/277/201/347/247/273/346/227/245/345/277/227.md +15 -15
- package/src/assets/img/paymentMethod/icon1.png +0 -0
- package/src/assets/img/paymentMethod/icon2.png +0 -0
- package/src/assets/img/paymentMethod/icon3.png +0 -0
- package/src/assets/img/paymentMethod/icon4.png +0 -0
- package/src/assets/img/paymentMethod/icon5.png +0 -0
- package/src/assets/img/paymentMethod/icon6.png +0 -0
- package/src/base-client/components/common/XReport/XReportHospitalizationDemo.vue +0 -45
- package/src-base-client/components/his/XCharge/README.md +0 -0
- package/src-base-client/components/his/XCharge/XCharge.vue +0 -0
|
@@ -69,6 +69,7 @@
|
|
|
69
69
|
:autoSave="autoSave"
|
|
70
70
|
:extraHeight="extraHeight"
|
|
71
71
|
:serviceName="serviceName"
|
|
72
|
+
:defaultPageSize="defaultPageSize"
|
|
72
73
|
:pageMaxSize="realQueryConfig.queryPagesSize"
|
|
73
74
|
:externalSelectedRowKeys="externalSelectedRowKeys"
|
|
74
75
|
:customPagination="customPagination"
|
|
@@ -139,6 +140,7 @@
|
|
|
139
140
|
:autoSave="autoSave"
|
|
140
141
|
:extraHeight="extraHeight"
|
|
141
142
|
:serviceName="serviceName"
|
|
143
|
+
:defaultPageSize="defaultPageSize"
|
|
142
144
|
:pageMaxSize="realQueryConfig.queryPagesSize"
|
|
143
145
|
:externalSelectedRowKeys="externalSelectedRowKeys"
|
|
144
146
|
:customPagination="customPagination"
|
|
@@ -210,17 +212,17 @@ import XAddReport from '@vue2-client/base-client/components/common/XAddReport'
|
|
|
210
212
|
import XTable from '@vue2-client/base-client/components/common/XTable'
|
|
211
213
|
import XTree from '@vue2-client/base-client/components/common/XTree'
|
|
212
214
|
import XImportExcel from '@vue2-client/base-client/components/common/XImportExcel'
|
|
213
|
-
import {Splitpanes, Pane} from 'splitpanes'
|
|
215
|
+
import { Splitpanes, Pane } from 'splitpanes'
|
|
214
216
|
import 'splitpanes/dist/splitpanes.css'
|
|
215
217
|
import {
|
|
216
218
|
getConfigByName,
|
|
217
219
|
getConfigByLogic,
|
|
218
220
|
parseConfig, runLogic, getConfigByNameAsync,
|
|
219
221
|
} from '@vue2-client/services/api/common'
|
|
220
|
-
import {mapState} from 'vuex'
|
|
222
|
+
import { mapState } from 'vuex'
|
|
221
223
|
import XTreePro from '@vue2-client/base-client/components/common/XTree/XTreePro.vue'
|
|
222
|
-
import {executeStrFunctionByContext} from '@vue2-client/utils/runEvalFunction'
|
|
223
|
-
import {getRealKeyData} from '@vue2-client/utils/util'
|
|
224
|
+
import { executeStrFunctionByContext } from '@vue2-client/utils/runEvalFunction'
|
|
225
|
+
import { getRealKeyData } from '@vue2-client/utils/util'
|
|
224
226
|
import * as util from '@vue2-client/utils/util'
|
|
225
227
|
import UserInfoDetailManage from '@vue2-client/pages/userInfoDetailManage/index.vue'
|
|
226
228
|
|
|
@@ -238,7 +240,7 @@ export default {
|
|
|
238
240
|
Splitpanes,
|
|
239
241
|
Pane
|
|
240
242
|
},
|
|
241
|
-
provide() {
|
|
243
|
+
provide () {
|
|
242
244
|
return {
|
|
243
245
|
getSelf: () => this,
|
|
244
246
|
emitEvent: this.emitEvent.bind(this)
|
|
@@ -284,7 +286,7 @@ export default {
|
|
|
284
286
|
currUser: {
|
|
285
287
|
default: () => {
|
|
286
288
|
console.warn('currUser is not provided.')
|
|
287
|
-
return {id: null, name: 'Guest'}
|
|
289
|
+
return { id: null, name: 'Guest' }
|
|
288
290
|
},
|
|
289
291
|
},
|
|
290
292
|
|
|
@@ -304,7 +306,7 @@ export default {
|
|
|
304
306
|
}
|
|
305
307
|
}
|
|
306
308
|
},
|
|
307
|
-
data() {
|
|
309
|
+
data () {
|
|
308
310
|
return {
|
|
309
311
|
// 加载状态
|
|
310
312
|
loading: false,
|
|
@@ -524,28 +526,33 @@ export default {
|
|
|
524
526
|
hiddenFunctionalArea: {
|
|
525
527
|
type: Boolean,
|
|
526
528
|
default: false
|
|
527
|
-
}
|
|
529
|
+
},
|
|
530
|
+
// 默认查询的当页行数
|
|
531
|
+
defaultPageSize: {
|
|
532
|
+
type: Number,
|
|
533
|
+
default: 10
|
|
534
|
+
},
|
|
528
535
|
},
|
|
529
536
|
watch: {
|
|
530
537
|
logicParam: {
|
|
531
|
-
handler() {
|
|
538
|
+
handler () {
|
|
532
539
|
this.initConfig()
|
|
533
540
|
},
|
|
534
541
|
deep: true
|
|
535
542
|
},
|
|
536
543
|
queryParamsJson: {
|
|
537
|
-
handler() {
|
|
544
|
+
handler () {
|
|
538
545
|
this.initConfig()
|
|
539
546
|
},
|
|
540
547
|
deep: true
|
|
541
548
|
},
|
|
542
549
|
queryParamsName: {
|
|
543
|
-
handler() {
|
|
550
|
+
handler () {
|
|
544
551
|
this.initConfig()
|
|
545
552
|
}
|
|
546
553
|
},
|
|
547
554
|
serviceName: {
|
|
548
|
-
handler() {
|
|
555
|
+
handler () {
|
|
549
556
|
this.initConfig()
|
|
550
557
|
}
|
|
551
558
|
}
|
|
@@ -555,20 +562,20 @@ export default {
|
|
|
555
562
|
getRealKeyData,
|
|
556
563
|
getConfigByNameAsync,
|
|
557
564
|
getConfigByName,
|
|
558
|
-
storePaneSize(treeSize) {
|
|
565
|
+
storePaneSize (treeSize) {
|
|
559
566
|
localStorage.setItem('CURD::' + this.xTreeConfigName + '::TreeSize', treeSize[0].size)
|
|
560
567
|
},
|
|
561
|
-
customEvent(func, data) {
|
|
568
|
+
customEvent (func, data) {
|
|
562
569
|
this.$emit(func, data)
|
|
563
570
|
},
|
|
564
|
-
columnClick(key, value, record) {
|
|
571
|
+
columnClick (key, value, record) {
|
|
565
572
|
this.$emit('columnClick', key, value, record)
|
|
566
573
|
},
|
|
567
|
-
gotoUserDetail(key, value, record) {
|
|
574
|
+
gotoUserDetail (key, value, record) {
|
|
568
575
|
this.$refs.userInfo.init(getRealKeyData(record))
|
|
569
576
|
},
|
|
570
577
|
// 获取主表的数据内容,去掉主表别名
|
|
571
|
-
getPrimaryData(rows) {
|
|
578
|
+
getPrimaryData (rows) {
|
|
572
579
|
const alias = this.realQueryConfig.tableAliasName // 获取主表的别名
|
|
573
580
|
const prefix = `${alias}_` // 构建前缀
|
|
574
581
|
const result = []
|
|
@@ -589,7 +596,7 @@ export default {
|
|
|
589
596
|
},
|
|
590
597
|
|
|
591
598
|
// 给数据区域添加主表数据,给的数据没有主表别名,放着时添加主表别名
|
|
592
|
-
pushPrimaryData(rows) {
|
|
599
|
+
pushPrimaryData (rows) {
|
|
593
600
|
const alias = this.realQueryConfig.tableAliasName // 获取主表的别名
|
|
594
601
|
const prefix = `${alias}_` // 构建前缀
|
|
595
602
|
const result = rows.map(row => {
|
|
@@ -604,7 +611,7 @@ export default {
|
|
|
604
611
|
},
|
|
605
612
|
|
|
606
613
|
// 设置固定查询条件,主表别名自动带
|
|
607
|
-
setFixedQueryForm(data) {
|
|
614
|
+
setFixedQueryForm (data) {
|
|
608
615
|
const alias = this.realQueryConfig.tableAliasName // 获取主表的别名
|
|
609
616
|
const prefixedData = {}
|
|
610
617
|
|
|
@@ -616,10 +623,10 @@ export default {
|
|
|
616
623
|
Object.assign(this.fixedQueryForm, prefixedData)
|
|
617
624
|
},
|
|
618
625
|
|
|
619
|
-
importExcelOk(data) {
|
|
626
|
+
importExcelOk (data) {
|
|
620
627
|
this.$emit('importExcelOk', data)
|
|
621
628
|
},
|
|
622
|
-
initConfig() {
|
|
629
|
+
initConfig () {
|
|
623
630
|
this.loading = true
|
|
624
631
|
this.loadError = false
|
|
625
632
|
if (this.queryParamsName) {
|
|
@@ -634,7 +641,7 @@ export default {
|
|
|
634
641
|
}
|
|
635
642
|
},
|
|
636
643
|
|
|
637
|
-
getConfig() {
|
|
644
|
+
getConfig () {
|
|
638
645
|
getConfigByName(this.queryParamsName, this.serviceName, (res) => {
|
|
639
646
|
if (!res) {
|
|
640
647
|
this.loading = false
|
|
@@ -644,7 +651,7 @@ export default {
|
|
|
644
651
|
this.updateComponents(res)
|
|
645
652
|
}, this.env === 'dev')
|
|
646
653
|
},
|
|
647
|
-
getConfigBySource() {
|
|
654
|
+
getConfigBySource () {
|
|
648
655
|
parseConfig(this.queryParamsJson, 'CRUD_FORM', this.serviceName, this.env === 'dev').then(res => {
|
|
649
656
|
if (!res) {
|
|
650
657
|
this.loading = false
|
|
@@ -654,7 +661,7 @@ export default {
|
|
|
654
661
|
this.updateComponents(res, true)
|
|
655
662
|
})
|
|
656
663
|
},
|
|
657
|
-
getColumnJsonByLogic() {
|
|
664
|
+
getColumnJsonByLogic () {
|
|
658
665
|
getConfigByLogic(this.logicName, this.logicParam, this.serviceName, (res) => {
|
|
659
666
|
if (!res) {
|
|
660
667
|
this.loading = false
|
|
@@ -670,7 +677,7 @@ export default {
|
|
|
670
677
|
* @param res 参数
|
|
671
678
|
* @param setQueryParams 是否设置queryParams参数
|
|
672
679
|
*/
|
|
673
|
-
updateComponents(res, setQueryParams) {
|
|
680
|
+
updateComponents (res, setQueryParams) {
|
|
674
681
|
this.realQueryConfig = res
|
|
675
682
|
// 读取表格展示模式配置
|
|
676
683
|
this.tableShowMode = res.tableShowMode || 'default'
|
|
@@ -745,7 +752,7 @@ export default {
|
|
|
745
752
|
this.loading = false
|
|
746
753
|
},
|
|
747
754
|
// 自定义按钮
|
|
748
|
-
editButtonStateDataClick(functionName, rows) {
|
|
755
|
+
editButtonStateDataClick (functionName, rows) {
|
|
749
756
|
console.log('functionName', functionName)
|
|
750
757
|
console.log('rows', rows)
|
|
751
758
|
this.$emit(functionName, rows)
|
|
@@ -755,7 +762,7 @@ export default {
|
|
|
755
762
|
* 提交查询表单事件
|
|
756
763
|
* @param res 参数
|
|
757
764
|
*/
|
|
758
|
-
onSearchSubmit(res) {
|
|
765
|
+
onSearchSubmit (res) {
|
|
759
766
|
if (res.valid) {
|
|
760
767
|
// 如果是弹框模式,显示表单加载动画,不立即打开弹框
|
|
761
768
|
if (this.tableShowMode === 'popup') {
|
|
@@ -775,11 +782,11 @@ export default {
|
|
|
775
782
|
/**
|
|
776
783
|
* 关闭表格弹框
|
|
777
784
|
*/
|
|
778
|
-
closeTableModal() {
|
|
785
|
+
closeTableModal () {
|
|
779
786
|
this.tableModalVisible = false
|
|
780
787
|
},
|
|
781
788
|
|
|
782
|
-
active(props) {
|
|
789
|
+
active (props) {
|
|
783
790
|
let num = false
|
|
784
791
|
for (const key in props) {
|
|
785
792
|
// eslint-disable-next-line no-prototype-builtins
|
|
@@ -799,7 +806,7 @@ export default {
|
|
|
799
806
|
/**
|
|
800
807
|
* 提交新增/修改表单后事件
|
|
801
808
|
*/
|
|
802
|
-
onAddOrEditSubmitAfterSubmit(res) {
|
|
809
|
+
onAddOrEditSubmitAfterSubmit (res) {
|
|
803
810
|
this.refreshTable(res.businessType === '新增')
|
|
804
811
|
// commit
|
|
805
812
|
this.$emit('afterSubmit', res)
|
|
@@ -809,7 +816,7 @@ export default {
|
|
|
809
816
|
* @param res 参数(可能是 Promise)
|
|
810
817
|
* @param conditionParams 查询条件
|
|
811
818
|
*/
|
|
812
|
-
async afterQuery(res, conditionParams) {
|
|
819
|
+
async afterQuery (res, conditionParams) {
|
|
813
820
|
// 如果是弹框模式且正在查询中
|
|
814
821
|
if (this.tableShowMode === 'popup' && this.formQueryLoading) {
|
|
815
822
|
// 兼容 Promise
|
|
@@ -837,20 +844,20 @@ export default {
|
|
|
837
844
|
* @param actionType 操作类型
|
|
838
845
|
* @param fun 向上级传递的事件
|
|
839
846
|
*/
|
|
840
|
-
action(record, id, actionType, fun = 'action', index) {
|
|
847
|
+
action (record, id, actionType, fun = 'action', index) {
|
|
841
848
|
this.$emit('innerXFormTableEmit', fun, record, id, actionType, index, this)
|
|
842
849
|
this.$emit(fun, record, id, actionType, index, this)
|
|
843
850
|
},
|
|
844
|
-
treeOnChecked(checkedKeys, deepNodes, deepKeys) {
|
|
851
|
+
treeOnChecked (checkedKeys, deepNodes, deepKeys) {
|
|
845
852
|
this.$emit('treeOnChecked', checkedKeys, deepNodes, deepKeys)
|
|
846
853
|
},
|
|
847
|
-
treeBtnFuncClick(index, func) {
|
|
854
|
+
treeBtnFuncClick (index, func) {
|
|
848
855
|
this.$emit('treeBtnFuncClick', index, func)
|
|
849
856
|
},
|
|
850
857
|
/**
|
|
851
858
|
* 新增按钮事件
|
|
852
859
|
*/
|
|
853
|
-
add() {
|
|
860
|
+
add () {
|
|
854
861
|
if (this.customAdd) {
|
|
855
862
|
this.$emit('add')
|
|
856
863
|
} else {
|
|
@@ -861,7 +868,7 @@ export default {
|
|
|
861
868
|
}
|
|
862
869
|
}
|
|
863
870
|
},
|
|
864
|
-
addFormInit() {
|
|
871
|
+
addFormInit () {
|
|
865
872
|
const res = this.realQueryConfig
|
|
866
873
|
const localEditMode = !this.localEditMode ? res.localEditMode : this.localEditMode
|
|
867
874
|
this.$refs.xAddForm.init({
|
|
@@ -886,7 +893,7 @@ export default {
|
|
|
886
893
|
/**
|
|
887
894
|
* 添加按钮事件
|
|
888
895
|
*/
|
|
889
|
-
move() {
|
|
896
|
+
move () {
|
|
890
897
|
this.moveType = true
|
|
891
898
|
this.$nextTick(
|
|
892
899
|
() => {
|
|
@@ -901,7 +908,7 @@ export default {
|
|
|
901
908
|
* 修改按钮事件
|
|
902
909
|
* @param modifyModelData 修改表单数据
|
|
903
910
|
*/
|
|
904
|
-
edit(modifyModelData) {
|
|
911
|
+
edit (modifyModelData) {
|
|
905
912
|
if (this.customEdit) {
|
|
906
913
|
this.$emit('edit')
|
|
907
914
|
} else {
|
|
@@ -929,7 +936,7 @@ export default {
|
|
|
929
936
|
/**
|
|
930
937
|
* 删除按钮事件
|
|
931
938
|
*/
|
|
932
|
-
del(keys, callback) {
|
|
939
|
+
del (keys, callback) {
|
|
933
940
|
if (this.customDelete) {
|
|
934
941
|
this.$emit('del', keys, callback)
|
|
935
942
|
}
|
|
@@ -938,14 +945,14 @@ export default {
|
|
|
938
945
|
* 删除后事件
|
|
939
946
|
* @param res
|
|
940
947
|
*/
|
|
941
|
-
afterDelete(res) {
|
|
948
|
+
afterDelete (res) {
|
|
942
949
|
this.$emit('afterDelete', res)
|
|
943
950
|
},
|
|
944
951
|
/**
|
|
945
952
|
* 行选择事件
|
|
946
953
|
* @param row 选中行
|
|
947
954
|
*/
|
|
948
|
-
rowChoose(row) {
|
|
955
|
+
rowChoose (row) {
|
|
949
956
|
this.$emit('rowChoose', row)
|
|
950
957
|
},
|
|
951
958
|
/**
|
|
@@ -953,13 +960,13 @@ export default {
|
|
|
953
960
|
* @param currRow 当前行
|
|
954
961
|
* @param defaultAppendRowData 默认追加的行数据
|
|
955
962
|
*/
|
|
956
|
-
validateTableAndSyncData(currRow, defaultAppendRowData) {
|
|
963
|
+
validateTableAndSyncData (currRow, defaultAppendRowData) {
|
|
957
964
|
this.$refs.xTable.validateTableAndSyncData(currRow, defaultAppendRowData)
|
|
958
965
|
},
|
|
959
966
|
/**
|
|
960
967
|
* 更多条件是否展示
|
|
961
968
|
*/
|
|
962
|
-
toggleAdvanced() {
|
|
969
|
+
toggleAdvanced () {
|
|
963
970
|
// 只有在非弹出模式下才需要调整表格滚动高度
|
|
964
971
|
if (this.tableShowMode !== 'popup') {
|
|
965
972
|
this.$refs.xTable.setScrollYHeight({})
|
|
@@ -968,7 +975,7 @@ export default {
|
|
|
968
975
|
/**
|
|
969
976
|
* 查询表单部分显示/隐藏切换
|
|
970
977
|
*/
|
|
971
|
-
toggleIsFormShow() {
|
|
978
|
+
toggleIsFormShow () {
|
|
972
979
|
this.toggleIsFormIcon = this.toggleIsFormIcon === 'vertical-align-top' ? 'vertical-align-bottom' : 'vertical-align-top'
|
|
973
980
|
this.$refs.xForm.toggleVisible()
|
|
974
981
|
// 只有在非弹出模式下才需要调整表格滚动高度
|
|
@@ -981,7 +988,7 @@ export default {
|
|
|
981
988
|
* @param selectedRowKeys 选中列Key集合
|
|
982
989
|
* @param selectedRows 选中列
|
|
983
990
|
*/
|
|
984
|
-
selectRow(selectedRowKeys, selectedRows) {
|
|
991
|
+
selectRow (selectedRowKeys, selectedRows) {
|
|
985
992
|
this.table_selectedRowKeys = selectedRowKeys
|
|
986
993
|
this.table_selectedRows = selectedRows
|
|
987
994
|
this.$emit('selectRow', selectedRowKeys, selectedRows)
|
|
@@ -989,14 +996,14 @@ export default {
|
|
|
989
996
|
/**
|
|
990
997
|
* 清除勾选数据
|
|
991
998
|
*/
|
|
992
|
-
clearRowKeys() {
|
|
999
|
+
clearRowKeys () {
|
|
993
1000
|
this.$refs.xTable.clearRowKeys()
|
|
994
1001
|
},
|
|
995
1002
|
/**
|
|
996
1003
|
* 刷新表格
|
|
997
1004
|
* @param toFirstPage 是否到第一页
|
|
998
1005
|
*/
|
|
999
|
-
refreshTable(toFirstPage = true) {
|
|
1006
|
+
refreshTable (toFirstPage = true) {
|
|
1000
1007
|
if (this.tableShowMode === 'popup') {
|
|
1001
1008
|
this.formQueryLoading = true
|
|
1002
1009
|
}
|
|
@@ -1006,7 +1013,7 @@ export default {
|
|
|
1006
1013
|
* 刷新表格
|
|
1007
1014
|
* @param toFirstPage 是否到第一页
|
|
1008
1015
|
*/
|
|
1009
|
-
refresh(toFirstPage = true) {
|
|
1016
|
+
refresh (toFirstPage = true) {
|
|
1010
1017
|
if (this.tableShowMode === 'popup') {
|
|
1011
1018
|
this.formQueryLoading = true
|
|
1012
1019
|
}
|
|
@@ -1015,7 +1022,7 @@ export default {
|
|
|
1015
1022
|
/**
|
|
1016
1023
|
* 主动传递条件查询表格
|
|
1017
1024
|
*/
|
|
1018
|
-
queryTable(conditionParams) {
|
|
1025
|
+
queryTable (conditionParams) {
|
|
1019
1026
|
if (this.tableShowMode === 'popup') {
|
|
1020
1027
|
this.formQueryLoading = true
|
|
1021
1028
|
}
|
|
@@ -1024,30 +1031,30 @@ export default {
|
|
|
1024
1031
|
/**
|
|
1025
1032
|
* 向外暴露 resetForm 函数
|
|
1026
1033
|
*/
|
|
1027
|
-
resetForm() {
|
|
1034
|
+
resetForm () {
|
|
1028
1035
|
this.$refs.xForm.resetForm()
|
|
1029
1036
|
},
|
|
1030
1037
|
/**
|
|
1031
1038
|
* 获取表格数据
|
|
1032
1039
|
*/
|
|
1033
|
-
getTableData() {
|
|
1040
|
+
getTableData () {
|
|
1034
1041
|
return this.$refs.xTable.getTableData()
|
|
1035
1042
|
},
|
|
1036
1043
|
// 在行编辑等情况下,让界面生效
|
|
1037
|
-
update() {
|
|
1044
|
+
update () {
|
|
1038
1045
|
this.getTableData().push(...[])
|
|
1039
1046
|
},
|
|
1040
1047
|
|
|
1041
1048
|
/**
|
|
1042
1049
|
* 设置表格数据
|
|
1043
1050
|
*/
|
|
1044
|
-
setTableData(data) {
|
|
1051
|
+
setTableData (data) {
|
|
1045
1052
|
this.$refs.xTable.setTableData(data)
|
|
1046
1053
|
},
|
|
1047
1054
|
/**
|
|
1048
1055
|
* 表单本地提交
|
|
1049
1056
|
*/
|
|
1050
|
-
onLocalSubmit(res, callback) {
|
|
1057
|
+
onLocalSubmit (res, callback) {
|
|
1051
1058
|
const form = res.realForm
|
|
1052
1059
|
if (res.businessType === '新增') {
|
|
1053
1060
|
this.$refs.xTable.appendLocalData(form)
|
|
@@ -1060,25 +1067,25 @@ export default {
|
|
|
1060
1067
|
callback()
|
|
1061
1068
|
}
|
|
1062
1069
|
},
|
|
1063
|
-
emitFunc(func, ...args) {
|
|
1070
|
+
emitFunc (func, ...args) {
|
|
1064
1071
|
this.$emit(func, ...args)
|
|
1065
1072
|
this.$emit('getEmitFuncData', func, ...args)
|
|
1066
1073
|
},
|
|
1067
1074
|
// 直接转发事件的函数
|
|
1068
|
-
emitEvent(event, ...args) {
|
|
1075
|
+
emitEvent (event, ...args) {
|
|
1069
1076
|
this.$emit(event, ...args)
|
|
1070
1077
|
},
|
|
1071
1078
|
// 添加处理 rowClick 的方法
|
|
1072
|
-
handleRowClick(record) {
|
|
1079
|
+
handleRowClick (record) {
|
|
1073
1080
|
this.$emit('rowClick', record)
|
|
1074
1081
|
},
|
|
1075
|
-
handleRowDblClick(record) {
|
|
1082
|
+
handleRowDblClick (record) {
|
|
1076
1083
|
this.$emit('rowDblClick', record)
|
|
1077
1084
|
},
|
|
1078
|
-
beforeDataChange(record) {
|
|
1085
|
+
beforeDataChange (record) {
|
|
1079
1086
|
this.$emit('beforeDataChange', record)
|
|
1080
1087
|
},
|
|
1081
|
-
onExpand(expanded, record) {
|
|
1088
|
+
onExpand (expanded, record) {
|
|
1082
1089
|
this.$emit('expand', expanded, record)
|
|
1083
1090
|
}
|
|
1084
1091
|
},
|
|
@@ -1086,7 +1093,7 @@ export default {
|
|
|
1086
1093
|
/**
|
|
1087
1094
|
* 实现doAction方法
|
|
1088
1095
|
*/
|
|
1089
|
-
doAction(actionType, args, data) {
|
|
1096
|
+
doAction (actionType, args, data) {
|
|
1090
1097
|
switch (actionType) {
|
|
1091
1098
|
case 'refreshTable':
|
|
1092
1099
|
for (const item in args) {
|
|
@@ -1098,7 +1105,7 @@ export default {
|
|
|
1098
1105
|
}
|
|
1099
1106
|
}
|
|
1100
1107
|
},
|
|
1101
|
-
mounted() {
|
|
1108
|
+
mounted () {
|
|
1102
1109
|
if (!this.isMounted) {
|
|
1103
1110
|
// 防止多次调用
|
|
1104
1111
|
// 不知道为啥他会执行两次 mounted 暂时处理方式
|
|
@@ -1119,8 +1126,8 @@ export default {
|
|
|
1119
1126
|
Object.assign(this.fixedAddForm, data)
|
|
1120
1127
|
Object.assign(this.fixedQueryForm, data)
|
|
1121
1128
|
} else {
|
|
1122
|
-
Object.assign(this.fixedAddForm, {selected_id: selectedId})
|
|
1123
|
-
Object.assign(this.fixedQueryForm, {selected_id: selectedId})
|
|
1129
|
+
Object.assign(this.fixedAddForm, { selected_id: selectedId })
|
|
1130
|
+
Object.assign(this.fixedQueryForm, { selected_id: selectedId })
|
|
1124
1131
|
}
|
|
1125
1132
|
}
|
|
1126
1133
|
}
|