olp-table 5.3.4 → 5.3.5
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 +12 -92
- package/.env.build +0 -1
- package/README.md +0 -26
- package/babel.config.js +0 -5
- package/jsconfig.json +0 -22
- package/public/favicon.ico +0 -0
- package/public/index.html +0 -17
- package/rmMode.bat +0 -1
- package/src/App.vue +0 -199
- package/src/api/crud.js +0 -22
- package/src/api/dist.js +0 -6
- package/src/assets/iconfont/iconfont.css +0 -20
- package/src/assets/iconfont/iconfont.json +0 -16
- package/src/assets/iconfont/iconfont.ttf +0 -0
- package/src/assets/iconfont/iconfont.woff +0 -0
- package/src/assets/iconfont/iconfont.woff2 +0 -0
- package/src/assets/logo.png +0 -0
- package/src/components/auto-height/index.vue +0 -75
- package/src/components/codemirror-tag.vue +0 -100
- package/src/components/lazy-load-select.vue +0 -107
- package/src/components/ol-dialog-excel.vue +0 -112
- package/src/components/ol-dialog-import.vue +0 -304
- package/src/components/ol-dialog-json.vue +0 -82
- package/src/components/ol-dialog-table.vue +0 -81
- package/src/components/ol-dialog-upload-file.vue +0 -208
- package/src/components/ol-dict-tag.vue +0 -271
- package/src/components/ol-select-dom.vue +0 -71
- package/src/components/ol-table-filter.vue +0 -28
- package/src/components/ol-table-render.vue +0 -44
- package/src/components/ol-table-select.vue +0 -150
- package/src/components/pinia-init.vue +0 -18
- package/src/components/table/model/ModelMixins.js +0 -43
- package/src/components/table/model/model-index.vue +0 -121
- package/src/components/table/model/ot-left-right.vue +0 -18
- package/src/components/table/model/ot-left-tree-right-table.scss +0 -14
- package/src/components/table/model/ot-left-tree-right-table.vue +0 -41
- package/src/components/table/model/ot-top-1-bottom-2.vue +0 -39
- package/src/components/table/model/ot-top-2-bottom-1.vue +0 -38
- package/src/components/table/model/ot-top-2-bottom-2.vue +0 -38
- package/src/components/table/model/ot-top-bottom.vue +0 -18
- package/src/components/table/model/splitpanesModel.css +0 -22
- package/src/components/table/model/splitpanesModel.vue +0 -54
- package/src/components/table/ol-form/index.vue +0 -537
- package/src/components/table/ol-form-v3/index.vue +0 -455
- package/src/components/table/ol-main-form-sub-table/index.vue +0 -601
- package/src/components/table/ol-pager/index.vue +0 -46
- package/src/components/table/ol-table/components/ol-table-column-config/columnIndex.vue +0 -233
- package/src/components/table/ol-table/components/ol-table-column-config/index.vue +0 -145
- package/src/components/table/ol-table/components/ol-table-column-dict-color/index.vue +0 -88
- package/src/components/table/ol-table/index.vue +0 -232
- package/src/components/table/ol-table-operate/index.vue +0 -61
- package/src/components/table/ol-table-search/index.vue +0 -17
- package/src/components/table/ol-table-tool-btn/index.vue +0 -60
- package/src/components/tree/components/o-tree.vue +0 -289
- package/src/components/tree/index.vue +0 -46
- package/src/components/v-component/index.vue +0 -43
- package/src/config/dev-config.js +0 -5
- package/src/config/prod-config.js +0 -5
- package/src/config/shared-config.js +0 -20
- package/src/data.js +0 -9378
- package/src/directives/permission/hasPermi.js +0 -63
- package/src/directives/permission/hasRole.js +0 -30
- package/src/main.js +0 -55
- package/src/mixins/VTMixin/DefaultMethods.js +0 -749
- package/src/mixins/VTMixin/OTMixinBody.js +0 -105
- package/src/mixins/VTMixin/OTMixinBodyFooter.js +0 -93
- package/src/mixins/VTMixin/OTMixinBodyMethods.js +0 -420
- package/src/mixins/VTMixin/OTMixinColumnMethod.js +0 -450
- package/src/mixins/VTMixin/OTMixinInitMethod.js +0 -130
- package/src/mixins/VTMixin/OTMixinPager.js +0 -38
- package/src/mixins/VTMixin/OTMixinSortable.js +0 -43
- package/src/mixins/VTMixin/index.js +0 -18
- package/src/package/index.js +0 -20
- package/src/plugins/axios.js +0 -61
- package/src/store/dict.js +0 -76
- package/src/store/dictType.js +0 -52
- package/src/store/permi.js +0 -45
- package/src/styles/common.scss +0 -37
- package/src/styles/index.scss +0 -48
- package/src/styles/theme.scss +0 -32
- package/src/utils/AESCRUDUtils.js +0 -87
- package/src/utils/DateUtils.js +0 -35
- package/src/utils/ExcelUtil.js +0 -159
- package/src/utils/TableSortUtil.js +0 -91
- package/src/utils/columnProp.js +0 -3
- package/src/utils/groupCompute.js +0 -68
- package/src/utils/http/httpFactory.js +0 -92
- package/src/utils/http/httpFactory2.js +0 -79
- package/src/utils/http/httpUtil.js +0 -123
- package/src/utils/http/httpUtils.js +0 -38
- package/src/utils/loadStyle.js +0 -14
- package/src/utils/message.js +0 -56
- package/src/utils/object.js +0 -80
- package/src/utils/security/TokenUtil.js +0 -19
- package/src/utils/tree.js +0 -54
- package/src/utils/util.js +0 -127
- package/src/views/Test/index.vue +0 -77
- package/src/views/Test/index2.vue +0 -33
- package/src/views/components/btn-config/index.vue +0 -202
- package/src/views/components/option-config/index.vue +0 -192
- package/src/views/db/chineseToEnglish.vue +0 -127
- package/src/views/db/filed.vue +0 -395
- package/src/views/db/index.vue +0 -192
- package/src/views/db/preview/index.vue +0 -139
- package/src/views/db/preview/left.vue +0 -204
- package/src/views/db/preview/right.vue +0 -466
- package/src/views/groupTable/index.vue +0 -137
- package/src/views/groupTable/ol-table-column-config/columnIndex.vue +0 -194
- package/src/views/groupTable/ol-table-column-config/index.vue +0 -92
- package/src/views/table/add-or-edit/config/base-config/index.vue +0 -539
- package/src/views/table/add-or-edit/config/base-config/table-form.vue +0 -333
- package/src/views/table/add-or-edit/config/column-config/header-config.vue +0 -475
- package/src/views/table/add-or-edit/config/column-config/index.vue +0 -790
- package/src/views/table/add-or-edit/config/data/column.js +0 -218
- package/src/views/table/add-or-edit/config/data/crud.js +0 -122
- package/src/views/table/add-or-edit/config/data/events.js +0 -109
- package/src/views/table/add-or-edit/config/data/method.js +0 -127
- package/src/views/table/add-or-edit/config/data/option.js +0 -725
- package/src/views/table/add-or-edit/config/data/page.js +0 -79
- package/src/views/table/add-or-edit/config/field-config/filed-config-table.vue +0 -42
- package/src/views/table/add-or-edit/config/field-config/index.vue +0 -91
- package/src/views/table/add-or-edit/config/form-config/index.vue +0 -1179
- package/src/views/table/add-or-edit/config/index.vue +0 -376
- package/src/views/table/add-or-edit/config/initFormObject.js +0 -25
- package/src/views/table/add-or-edit/config/script-config/LeftMeun.vue +0 -71
- package/src/views/table/add-or-edit/config/script-config/index.vue +0 -70
- package/src/views/table/add-or-edit/config/table-config/btn-config.vue +0 -340
- package/src/views/table/add-or-edit/config/table-config/btn-sort.vue +0 -132
- package/src/views/table/add-or-edit/config/table-config/index.vue +0 -446
- package/src/views/table/add-or-edit/configOld/dataTags/filed-config-table-model.vue +0 -41
- package/src/views/table/add-or-edit/configOld/dataTags/filed-config.vue +0 -74
- package/src/views/table/add-or-edit/configOld/dataTags/index.vue +0 -439
- package/src/views/table/add-or-edit/configOld/dataTags/set-table-sql.vue +0 -79
- package/src/views/table/add-or-edit/configOld/dataTags/table-on-config.vue +0 -74
- package/src/views/table/add-or-edit/configOld/index.vue +0 -127
- package/src/views/table/add-or-edit/configOld/tableTags/columnConfig.js +0 -5
- package/src/views/table/add-or-edit/configOld/tableTags/index.vue +0 -353
- package/src/views/table/add-or-edit/configOld/tableTags/operation-but-config.vue +0 -75
- package/src/views/table/add-or-edit/configOld/tableTags/tool-but-config.vue +0 -92
- package/src/views/table/add-or-edit/index.vue +0 -201
- package/src/views/table/add-or-edit/themeModel/index.vue +0 -53
- package/src/views/table/add-or-edit/themeModel/init-model-table.vue +0 -48
- package/src/views/table/add-or-edit/themeModel/init-model.vue +0 -81
- package/src/views/table/add-or-edit/themeModel/left-right.vue +0 -24
- package/src/views/table/add-or-edit/themeModel/left-tree-right-table.vue +0 -75
- package/src/views/table/add-or-edit/themeModel/olTableSearchModelMixins.js +0 -42
- package/src/views/table/add-or-edit/themeModel/splitpanesThemeModel.vue +0 -49
- package/src/views/table/add-or-edit/themeModel/top-1-bottom-2.vue +0 -29
- package/src/views/table/add-or-edit/themeModel/top-2-bottom-1.vue +0 -32
- package/src/views/table/add-or-edit/themeModel/top-2-bottom-2.vue +0 -32
- package/src/views/table/add-or-edit/themeModel/top-bottom.vue +0 -14
- package/src/views/table/index.vue +0 -43
- package/src/views/table/index2.vue +0 -199
- package/src/views/table/preview/index.vue +0 -29
- package/src/views/tree/components/config-core-data.vue +0 -85
- package/src/views/tree/components/config-core-table.vue +0 -362
- package/src/views/tree/components/config-core-tree/data/events.js +0 -95
- package/src/views/tree/components/config-core-tree/data/option.js +0 -88
- package/src/views/tree/components/config-core-tree/data/prop.js +0 -28
- package/src/views/tree/components/config-core-tree/index.vue +0 -181
- package/src/views/tree/components/config-core.vue +0 -42
- package/src/views/tree/components/form-config/index.vue +0 -967
- package/src/views/tree/index.vue +0 -424
- package/vue.config.js +0 -44
- /package/{olp-table/demo.html → demo.html} +0 -0
- /package/{olp-table/fonts → fonts}/iconfont.1720006583309.7e4906d9.woff +0 -0
- /package/{olp-table/fonts → fonts}/iconfont.1720006583309.947a27f0.ttf +0 -0
- /package/{olp-table/olp-table.common.js → olp-table.common.js} +0 -0
- /package/{olp-table/olp-table.css → olp-table.css} +0 -0
- /package/{olp-table/olp-table.umd.js → olp-table.umd.js} +0 -0
- /package/{olp-table/olp-table.umd.min.js → olp-table.umd.min.js} +0 -0
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
<!-- 表格选取组件 -->
|
|
2
|
-
<!--使用示例如下:
|
|
3
|
-
@olTableSelectChange 选中数据后的回调方法
|
|
4
|
-
:config 配置下拉选择框的配置信息key和label对应的字段名字
|
|
5
|
-
注意:弹出的table是表格构建的配置出的表格,需要再该表格构建配置页面增加选中和关闭按钮的事件,否则无法正常使用
|
|
6
|
-
按钮名称 | 方法名 | 触发事件
|
|
7
|
-
选中 getSelectRowChange this.$emit('getSelectRowChangeButClick',this.getSelectRows())
|
|
8
|
-
关闭 getSelectRowClose this.$emit('getSelectRowCloseButClick','')
|
|
9
|
-
以下是例子:
|
|
10
|
-
测试下拉框:
|
|
11
|
-
<ol-table-select @olTableSelectChange="olTableSelectChange" :http="http" :uuid="'1900437634399076352'"
|
|
12
|
-
:config="{
|
|
13
|
-
key:'code', //选择的key字段名称
|
|
14
|
-
label:'name', //显示的字段,默认是name
|
|
15
|
-
labelIsAppendCode:true,//标签是否追加编码如:[1]男
|
|
16
|
-
}"></ol-table-select>
|
|
17
|
-
其他属性配置例子:
|
|
18
|
-
{
|
|
19
|
-
"olTableSelect":{
|
|
20
|
-
"uuid":"1901841070608990208",
|
|
21
|
-
"key":"id",
|
|
22
|
-
"label":"name",
|
|
23
|
-
"labelIsAppendCode":true,
|
|
24
|
-
"otherResult":"name:name,age:age,sex:sex"
|
|
25
|
-
}
|
|
26
|
-
}
|
|
27
|
-
-->
|
|
28
|
-
<template>
|
|
29
|
-
<el-select v-model="selectValue.value" placeholder="请选择" @click="openTable"
|
|
30
|
-
@change="updateValue" @clear="clearedSelectValue"
|
|
31
|
-
clearable>
|
|
32
|
-
<el-option
|
|
33
|
-
v-for="item in selectDataList"
|
|
34
|
-
:key="item.value"
|
|
35
|
-
:label="item.label"
|
|
36
|
-
:value="item.value">
|
|
37
|
-
</el-option>
|
|
38
|
-
</el-select>
|
|
39
|
-
|
|
40
|
-
<ol-dialog-table ref="table" @emits="getSelectRowChangeButClick"/>
|
|
41
|
-
|
|
42
|
-
<!-- <el-dialog :close-on-click-modal="false"-->
|
|
43
|
-
<!-- :key="dialogKey"-->
|
|
44
|
-
<!-- top="5vh"-->
|
|
45
|
-
<!-- v-model="dialogVisible"-->
|
|
46
|
-
<!-- title="选择数据"-->
|
|
47
|
-
<!-- width="80%"-->
|
|
48
|
-
<!-- append-to-body>-->
|
|
49
|
-
<!-- <div style="height: 80vh; overflow-y: auto;">-->
|
|
50
|
-
<!-- <model-index ref="modelIndex" :http="http" :uuid="uuid" style="height: calc(100% - 50px)"/>-->
|
|
51
|
-
<!-- <el-row style="height: 50px" justify="center">-->
|
|
52
|
-
<!-- <el-button type="primary" @click="getSelectRowChangeButClick">确定</el-button>-->
|
|
53
|
-
<!-- <el-button @click="getSelectRowCloseButClick">关闭</el-button>-->
|
|
54
|
-
<!-- </el-row>-->
|
|
55
|
-
<!-- </div>-->
|
|
56
|
-
<!-- </el-dialog>-->
|
|
57
|
-
</template>
|
|
58
|
-
|
|
59
|
-
<script>
|
|
60
|
-
|
|
61
|
-
import ModelIndex from "@/components/table/model/model-index.vue";
|
|
62
|
-
import OlDialogTable from "@/components/ol-dialog-table.vue";
|
|
63
|
-
|
|
64
|
-
export default {
|
|
65
|
-
name: 'olTableSelect',
|
|
66
|
-
components: {
|
|
67
|
-
OlDialogTable,
|
|
68
|
-
ModelIndex,
|
|
69
|
-
},
|
|
70
|
-
props: {
|
|
71
|
-
defaultValue: {required: false,default: ''},
|
|
72
|
-
slotName: {required: false},
|
|
73
|
-
uuid: {required: true},
|
|
74
|
-
http: {},
|
|
75
|
-
config: {},
|
|
76
|
-
},
|
|
77
|
-
provide() {
|
|
78
|
-
return {
|
|
79
|
-
tableAll: this.table,
|
|
80
|
-
http: this.http
|
|
81
|
-
}
|
|
82
|
-
},
|
|
83
|
-
data() {
|
|
84
|
-
return {
|
|
85
|
-
selectDataList: [],
|
|
86
|
-
dialogVisible: false,
|
|
87
|
-
selectValue: {
|
|
88
|
-
value: this.defaultValue,
|
|
89
|
-
label: '',
|
|
90
|
-
data: [],
|
|
91
|
-
},
|
|
92
|
-
dialogKey: 1
|
|
93
|
-
}
|
|
94
|
-
},
|
|
95
|
-
methods: {
|
|
96
|
-
//打开表格选择组件
|
|
97
|
-
openTable() {
|
|
98
|
-
this.dialogKey++;//每次打开对话框时,key值加1,防止对话框重复渲染
|
|
99
|
-
this.dialogVisible = true;//打开对话框
|
|
100
|
-
this.$refs.table.init({uuid: this.uuid,title: '选择数据'})
|
|
101
|
-
},
|
|
102
|
-
//选中数据按钮回调
|
|
103
|
-
getSelectRowChangeButClick({v}) {
|
|
104
|
-
// let rows = this.$refs.modelIndex.$refs.tableModel.getSelectRows()
|
|
105
|
-
let rows = v
|
|
106
|
-
if (rows.length === 0) {
|
|
107
|
-
this.clearedSelectValue()//清空下拉框的值
|
|
108
|
-
this.dialogVisible = false;//关闭对话框
|
|
109
|
-
return;
|
|
110
|
-
}
|
|
111
|
-
for (const [index, row] of rows.entries()) {
|
|
112
|
-
//给下拉框选项添加
|
|
113
|
-
let label = this.config.labelIsAppendCode ? `[${row[this.config.key]}]${row[this.config.label]}` : row[this.config.label]
|
|
114
|
-
this.selectDataList.push({
|
|
115
|
-
label: label,
|
|
116
|
-
value: row[this.config.key],
|
|
117
|
-
});
|
|
118
|
-
}
|
|
119
|
-
//选中第一行数据,目前暂时支持单选
|
|
120
|
-
this.selectValue = {
|
|
121
|
-
value: rows[0][this.config.key],
|
|
122
|
-
label: rows[0][this.config.label],
|
|
123
|
-
data: rows[0]
|
|
124
|
-
}
|
|
125
|
-
this.updateValue()//更新下拉框的值
|
|
126
|
-
this.dialogVisible = false;//关闭对话框
|
|
127
|
-
this.$refs.table.cancelEvent()
|
|
128
|
-
},
|
|
129
|
-
//关闭选择数据按钮回调
|
|
130
|
-
getSelectRowCloseButClick() {
|
|
131
|
-
this.dialogVisible = false;
|
|
132
|
-
},
|
|
133
|
-
//更新父组件的值
|
|
134
|
-
updateValue() {
|
|
135
|
-
this.$emit('olTableSelectChange', this.slotName, this.selectValue);
|
|
136
|
-
},
|
|
137
|
-
clearedSelectValue() {
|
|
138
|
-
this.selectValue = {value: '', label: '', data: []};
|
|
139
|
-
this.updateValue();//更新下拉框的值
|
|
140
|
-
this.$refs.table.cancelEvent()
|
|
141
|
-
},
|
|
142
|
-
},
|
|
143
|
-
created() {
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
</script>
|
|
147
|
-
|
|
148
|
-
<style scoped>
|
|
149
|
-
|
|
150
|
-
</style>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<script>
|
|
2
|
-
import {storeDict} from "@/store/dict";
|
|
3
|
-
import {storeDictType} from "@/store/dictType";
|
|
4
|
-
|
|
5
|
-
export default {
|
|
6
|
-
name: 'pinaInit',
|
|
7
|
-
props: {
|
|
8
|
-
http: {}
|
|
9
|
-
}, methods: {
|
|
10
|
-
async init() {
|
|
11
|
-
await storeDict().init(this.props.http);
|
|
12
|
-
await storeDictType().init(this.props.http);
|
|
13
|
-
}
|
|
14
|
-
}, mounted() {
|
|
15
|
-
this.init()
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
</script>
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import {Pane, Splitpanes} from "splitpanes";
|
|
2
|
-
import 'splitpanes/dist/splitpanes.css'
|
|
3
|
-
import {nextTick} from "vue";
|
|
4
|
-
|
|
5
|
-
export const modelMixins = {
|
|
6
|
-
components: {Splitpanes, Pane},
|
|
7
|
-
emits: ['initOk'],
|
|
8
|
-
props: {
|
|
9
|
-
paneSize: {
|
|
10
|
-
minSize: 20, maxSize: 80
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
data() {
|
|
14
|
-
return {
|
|
15
|
-
formConfig: undefined,
|
|
16
|
-
}
|
|
17
|
-
}, methods: {
|
|
18
|
-
initOk(e) {
|
|
19
|
-
let {theme, table, customerForm} = e;
|
|
20
|
-
if (this.searchRow == '1' && theme == 't1') {
|
|
21
|
-
this.formConfig = table.formConfig;//给原有的自定义搜索
|
|
22
|
-
customerForm();//执行自定义表单,这个方法会隐藏table的表单,隐藏搜索按钮
|
|
23
|
-
this.customerForm = customerForm
|
|
24
|
-
}
|
|
25
|
-
this.$emit('initOk', e)
|
|
26
|
-
}, setDataSource(data) {
|
|
27
|
-
nextTick(() => {
|
|
28
|
-
let keys = Object.keys(data).filter(o => o.toString().length == 2 && o.toString().indexOf("t") == 0);
|
|
29
|
-
for (let key of keys) {
|
|
30
|
-
if (this.$refs[key]) {
|
|
31
|
-
this.$refs[key].setDataSource(data[key])
|
|
32
|
-
} else {
|
|
33
|
-
if (this.$refs.splitpanesModel.$refs[key]) {
|
|
34
|
-
this.$refs.splitpanesModel.$refs[key].setDataSource(data[key])
|
|
35
|
-
} else {
|
|
36
|
-
this.$refs.splitpanesModel1.$refs[key].setDataSource(data[key])
|
|
37
|
-
}
|
|
38
|
-
}
|
|
39
|
-
}
|
|
40
|
-
})
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
}
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<auto-height v-slot="{ height }"
|
|
3
|
-
v-loading="loading"
|
|
4
|
-
element-loading-text="正在初始化页面...">
|
|
5
|
-
<olTable v-bind="$attrs" ref="tableModel" v-if="theme == 1" :uuid="uuid" :init-data-source="false"
|
|
6
|
-
theme="t1">
|
|
7
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
8
|
-
<slot :name="item"></slot>
|
|
9
|
-
</template>
|
|
10
|
-
</olTable>
|
|
11
|
-
<otTopBottom v-bind="$attrs" ref="tableModel" v-if="theme == 2" :uuid="uuid">
|
|
12
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
13
|
-
<slot :name="item"></slot>
|
|
14
|
-
</template>
|
|
15
|
-
</otTopBottom>
|
|
16
|
-
<OtLeftRight :searchRow="searchRow" v-bind="$attrs" ref="tableModel" v-else-if="theme == 3" :uuid="uuid">
|
|
17
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
18
|
-
<slot :name="item"></slot>
|
|
19
|
-
</template>
|
|
20
|
-
</OtLeftRight>
|
|
21
|
-
<OtTop1Bottom2 v-bind="$attrs" ref="tableModel" v-else-if="theme == 4" :uuid="uuid">
|
|
22
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
23
|
-
<slot :name="item"></slot>
|
|
24
|
-
</template>
|
|
25
|
-
</OtTop1Bottom2>
|
|
26
|
-
<OtTop2Bottom1 :searchRow="searchRow" v-bind="$attrs" ref="tableModel" v-else-if="theme == 5" :uuid="uuid">
|
|
27
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
28
|
-
<slot :name="item"></slot>
|
|
29
|
-
</template>
|
|
30
|
-
</OtTop2Bottom1>
|
|
31
|
-
<otTop2Bottom2 :searchRow="searchRow" v-bind="$attrs" ref="tableModel" v-else-if="theme == 6" :uuid="uuid">
|
|
32
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
33
|
-
<slot :name="item"></slot>
|
|
34
|
-
</template>
|
|
35
|
-
</otTop2Bottom2>
|
|
36
|
-
<otLeftTreeRightTable v-bind="$attrs" ref="tableModel" v-else-if="theme == 7" :uuid="uuid" :treeUuid="treeUuid">
|
|
37
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
38
|
-
<slot :name="item"></slot>
|
|
39
|
-
</template>
|
|
40
|
-
</otLeftTreeRightTable>
|
|
41
|
-
</auto-height>
|
|
42
|
-
</template>
|
|
43
|
-
<script>
|
|
44
|
-
import OtTopBottom from "@/components/table/model/ot-top-bottom.vue";
|
|
45
|
-
import OtLeftRight from "@/components/table/model/ot-left-right.vue";
|
|
46
|
-
import {get} from "@/utils/http/httpUtils";
|
|
47
|
-
import OtTop1Bottom2 from "@/components/table/model/ot-top-1-bottom-2.vue";
|
|
48
|
-
import OtTop2Bottom1 from "@/components/table/model/ot-top-2-bottom-1.vue";
|
|
49
|
-
import OtTop2Bottom2 from "@/components/table/model/ot-top-2-bottom-2.vue";
|
|
50
|
-
import otLeftTreeRightTable from "@/components/table/model/ot-left-tree-right-table.vue";
|
|
51
|
-
import AutoHeight from "@/components/auto-height/index.vue";
|
|
52
|
-
import {decryptWithDecompress} from "@/utils/AESCRUDUtils";
|
|
53
|
-
export default {
|
|
54
|
-
name: 'modelIndex',
|
|
55
|
-
components: {
|
|
56
|
-
AutoHeight,
|
|
57
|
-
OtTopBottom, OtLeftRight, OtTop1Bottom2, OtTop2Bottom1, OtTop2Bottom2, otLeftTreeRightTable
|
|
58
|
-
},
|
|
59
|
-
props: {
|
|
60
|
-
uuid: {required: true},
|
|
61
|
-
http: {}
|
|
62
|
-
}, provide() {
|
|
63
|
-
return {
|
|
64
|
-
tableAll: this.table,
|
|
65
|
-
http: this.http
|
|
66
|
-
}
|
|
67
|
-
},
|
|
68
|
-
data() {
|
|
69
|
-
return {
|
|
70
|
-
cas: 0,
|
|
71
|
-
table: {},
|
|
72
|
-
theme: 0,
|
|
73
|
-
searchRow: 0,
|
|
74
|
-
treeUuid: '',
|
|
75
|
-
loading: true,
|
|
76
|
-
}
|
|
77
|
-
},
|
|
78
|
-
methods: {
|
|
79
|
-
initConfig() {
|
|
80
|
-
this.loading = true;
|
|
81
|
-
get(this.http, "/onlineAes/initAll", {uuid: this.uuid}).then(data => {
|
|
82
|
-
data = JSON.parse(decryptWithDecompress(data));
|
|
83
|
-
this.theme = data.theme;
|
|
84
|
-
this.searchRow = data.searchRow;
|
|
85
|
-
this.treeUuid = data.treeUuid;
|
|
86
|
-
this.doSetDataSource(data);
|
|
87
|
-
}).finally(() => {
|
|
88
|
-
this.loading = false;
|
|
89
|
-
})
|
|
90
|
-
},
|
|
91
|
-
doSetDataSource(data) {
|
|
92
|
-
this.$nextTick(() => {
|
|
93
|
-
if (this.$refs.tableModel) {
|
|
94
|
-
if (data.theme == 1 || data.theme == 7) {
|
|
95
|
-
this.$refs.tableModel.setDataSource(data['t1'])
|
|
96
|
-
} else {
|
|
97
|
-
this.$refs.tableModel.setDataSource(data)
|
|
98
|
-
}
|
|
99
|
-
} else {
|
|
100
|
-
setTimeout(() => {
|
|
101
|
-
this.cas++;
|
|
102
|
-
if (this.cas <= 5) {
|
|
103
|
-
console.log("自旋》" + this.cas)
|
|
104
|
-
this.doSetDataSource(data)
|
|
105
|
-
}
|
|
106
|
-
}, 500)
|
|
107
|
-
}
|
|
108
|
-
})
|
|
109
|
-
}
|
|
110
|
-
}, created() {
|
|
111
|
-
this.initConfig()
|
|
112
|
-
}
|
|
113
|
-
}
|
|
114
|
-
</script>
|
|
115
|
-
|
|
116
|
-
<style scoped lang="less">
|
|
117
|
-
div {
|
|
118
|
-
height: 100%;
|
|
119
|
-
width: 100%;
|
|
120
|
-
}
|
|
121
|
-
</style>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<splitpanes-model ref="splitpanesModel" :paneSize="paneSize" :horizontal="false" @initOk="initOk" v-bind="$attrs">
|
|
3
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
4
|
-
<slot :name="item"></slot>
|
|
5
|
-
</template>
|
|
6
|
-
</splitpanes-model>
|
|
7
|
-
</template>
|
|
8
|
-
|
|
9
|
-
<script scope>
|
|
10
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
11
|
-
import SplitpanesModel from "@/components/table/model/splitpanesModel.vue";
|
|
12
|
-
|
|
13
|
-
export default {
|
|
14
|
-
name: 'otLeftRight',
|
|
15
|
-
components: {SplitpanesModel},
|
|
16
|
-
mixins: [modelMixins]
|
|
17
|
-
}
|
|
18
|
-
</script>
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div style="height: 100%">
|
|
3
|
-
<el-card class="tree-left">
|
|
4
|
-
<ol-tree :uuid="treeUuid"></ol-tree>
|
|
5
|
-
</el-card>
|
|
6
|
-
<el-card class="table-right">
|
|
7
|
-
<olTable v-bind="$attrs" ref="t1" :uuid="uuid" :init-data-source="false" theme="t1">
|
|
8
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
9
|
-
<slot :name="item"></slot>
|
|
10
|
-
</template>
|
|
11
|
-
</olTable>
|
|
12
|
-
</el-card>
|
|
13
|
-
</div>
|
|
14
|
-
</template>
|
|
15
|
-
|
|
16
|
-
<script scope>
|
|
17
|
-
import OlTree from "@/components/tree/index.vue";
|
|
18
|
-
import {nextTick} from "vue";
|
|
19
|
-
export default {
|
|
20
|
-
name: 'otLeftTreeRightTable',
|
|
21
|
-
components: { OlTree},
|
|
22
|
-
props:{
|
|
23
|
-
uuid:{},
|
|
24
|
-
treeUuid:{},
|
|
25
|
-
},
|
|
26
|
-
methods:{
|
|
27
|
-
setDataSource(data) {
|
|
28
|
-
nextTick(() => {
|
|
29
|
-
this.$refs['t1'].setDataSource(data)
|
|
30
|
-
})
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
</script>
|
|
35
|
-
<style lang="less" scoped>
|
|
36
|
-
@import "ot-left-tree-right-table.scss";
|
|
37
|
-
/deep/ .el-card__body {
|
|
38
|
-
height: 100%;
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
</style>
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<splitpanes class="default-theme" horizontal :push-other-panes="false">
|
|
3
|
-
<pane style="background:transparent" :size="50" v-bind="paneSize">
|
|
4
|
-
<div class="top">
|
|
5
|
-
<olTable v-bind="$attrs" ref="t1" theme="t1" :initDataSource="false">
|
|
6
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
7
|
-
<slot :name="item"></slot>
|
|
8
|
-
</template>
|
|
9
|
-
</olTable>
|
|
10
|
-
</div>
|
|
11
|
-
</pane>
|
|
12
|
-
<pane style="background:transparent" v-bind="paneSize">
|
|
13
|
-
<splitpanes-model ref="splitpanesModel" :paneSize="paneSize" theme1="t2" theme2="t3" :horizontal="false"
|
|
14
|
-
v-bind="$attrs">
|
|
15
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
16
|
-
<slot :name="item"></slot>
|
|
17
|
-
</template>
|
|
18
|
-
</splitpanes-model>
|
|
19
|
-
</pane>
|
|
20
|
-
</splitpanes>
|
|
21
|
-
</template>
|
|
22
|
-
|
|
23
|
-
<script scope>
|
|
24
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
25
|
-
import SplitpanesModel from "@/components/table/model/splitpanesModel.vue";
|
|
26
|
-
|
|
27
|
-
export default {
|
|
28
|
-
name: 'otTop1Bottom2',
|
|
29
|
-
components: {SplitpanesModel},
|
|
30
|
-
mixins: [modelMixins]
|
|
31
|
-
}
|
|
32
|
-
</script>
|
|
33
|
-
<style scoped>
|
|
34
|
-
.top {
|
|
35
|
-
height: 100%;
|
|
36
|
-
padding-bottom: 10px;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
</style>
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<splitpanes class="default-theme" horizontal :push-other-panes="false">
|
|
3
|
-
<pane style="background:transparent" :size="50" v-bind="paneSize">
|
|
4
|
-
<div class="top">
|
|
5
|
-
<splitpanes-model ref="splitpanesModel" :paneSize="paneSize" :horizontal="false" @initOk="initOk" v-bind="$attrs">.
|
|
6
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
7
|
-
<slot :name="item"></slot>
|
|
8
|
-
</template>
|
|
9
|
-
</splitpanes-model>
|
|
10
|
-
</div>
|
|
11
|
-
</pane>
|
|
12
|
-
<pane style="background:transparent;padding-bottom: 5px" v-bind="paneSize">
|
|
13
|
-
<olTable v-bind="$attrs" ref="t3" theme="t3">
|
|
14
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
15
|
-
<slot :name="item"></slot>
|
|
16
|
-
</template>
|
|
17
|
-
</olTable>
|
|
18
|
-
</pane>
|
|
19
|
-
</splitpanes>
|
|
20
|
-
</template>
|
|
21
|
-
|
|
22
|
-
<script scope>
|
|
23
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
24
|
-
import SplitpanesModel from "@/components/table/model/splitpanesModel.vue";
|
|
25
|
-
|
|
26
|
-
export default {
|
|
27
|
-
name: 'otTop2Bottom1',
|
|
28
|
-
components: {SplitpanesModel},
|
|
29
|
-
mixins: [modelMixins]
|
|
30
|
-
}
|
|
31
|
-
</script>
|
|
32
|
-
<style scoped>
|
|
33
|
-
.top {
|
|
34
|
-
height: 100%;
|
|
35
|
-
padding-bottom: 10px;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
</style>
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<splitpanes class="default-theme" horizontal :push-other-panes="false">
|
|
3
|
-
<pane style="background:transparent" :size="50" v-bind="paneSize">
|
|
4
|
-
<div class="top">
|
|
5
|
-
<splitpanes-model ref="splitpanesModel" :paneSize="paneSize" :horizontal="false" @initOk="initOk" v-bind="$attrs">
|
|
6
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
7
|
-
<slot :name="item"></slot>
|
|
8
|
-
</template>
|
|
9
|
-
</splitpanes-model>
|
|
10
|
-
</div>
|
|
11
|
-
</pane>
|
|
12
|
-
<pane style="background:transparent;padding-bottom: 5px" v-bind="paneSize">
|
|
13
|
-
<splitpanes-model ref="splitpanesModel1" :paneSize="paneSize" theme1="t3" theme2="t4" :horizontal="false" v-bind="$attrs">
|
|
14
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
15
|
-
<slot :name="item"></slot>
|
|
16
|
-
</template>
|
|
17
|
-
</splitpanes-model>
|
|
18
|
-
</pane>
|
|
19
|
-
</splitpanes>
|
|
20
|
-
</template>
|
|
21
|
-
|
|
22
|
-
<script scope>
|
|
23
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
24
|
-
import SplitpanesModel from "@/components/table/model/splitpanesModel.vue";
|
|
25
|
-
|
|
26
|
-
export default {
|
|
27
|
-
name: 'otTop2Bottom2',
|
|
28
|
-
components: {SplitpanesModel},
|
|
29
|
-
mixins: [modelMixins]
|
|
30
|
-
}
|
|
31
|
-
</script>
|
|
32
|
-
<style scoped>
|
|
33
|
-
.top {
|
|
34
|
-
height: 100%;
|
|
35
|
-
padding-bottom: 10px;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
</style>
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<splitpanes-model ref="splitpanesModel" :paneSize="paneSize" v-bind="$attrs">
|
|
3
|
-
<template v-for='item in Object.keys($slots)' v-slot:[item]>
|
|
4
|
-
<slot :name="item"></slot>
|
|
5
|
-
</template>
|
|
6
|
-
</splitpanes-model>
|
|
7
|
-
</template>
|
|
8
|
-
|
|
9
|
-
<script scope>
|
|
10
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
11
|
-
import SplitpanesModel from "@/components/table/model/splitpanesModel.vue";
|
|
12
|
-
|
|
13
|
-
export default {
|
|
14
|
-
name: 'otLeftRight',
|
|
15
|
-
components: {SplitpanesModel},
|
|
16
|
-
mixins: [modelMixins]
|
|
17
|
-
}
|
|
18
|
-
</script>
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div style="height: 100%;width: 100%">
|
|
3
|
-
<ol-table-search v-if="formConfig && searchRow == '1'" :formConfig="formConfig"></ol-table-search>
|
|
4
|
-
<splitpanes :style="formConfig ? getStyle : ''" class="default-theme splitpanesModel" :horizontal="horizontal"
|
|
5
|
-
:push-other-panes="false">
|
|
6
|
-
<pane style="background: transparent" :size="50" v-bind="paneSize">
|
|
7
|
-
<div :class="isLR ? 'left' :'top'">
|
|
8
|
-
<olTable :ref="theme1" v-bind="$attrs" @initOk="initOk" :initDataSource="false" :theme="theme1">
|
|
9
|
-
<template v-for='item in Object.keys($slots).filter(o=>o.indexOf("_t1") != -1)' v-slot:[item]>
|
|
10
|
-
<slot :name="item"></slot>
|
|
11
|
-
</template>
|
|
12
|
-
</olTable>
|
|
13
|
-
</div>
|
|
14
|
-
</pane>
|
|
15
|
-
<pane style="background: transparent" v-bind="paneSize">
|
|
16
|
-
<div :class="isLR ? 'right' :'bottom'">
|
|
17
|
-
<olTable :ref="theme2" v-bind="$attrs" :initDataSource="false" :theme="theme2">
|
|
18
|
-
<template v-for='item in Object.keys($slots).filter(o=>o.indexOf("_t2") != -1)' v-slot:[item]>
|
|
19
|
-
<slot :name="item"></slot>
|
|
20
|
-
</template>
|
|
21
|
-
</olTable>
|
|
22
|
-
</div>
|
|
23
|
-
</pane>
|
|
24
|
-
</splitpanes>
|
|
25
|
-
|
|
26
|
-
</div>
|
|
27
|
-
</template>
|
|
28
|
-
<script scope>
|
|
29
|
-
import {Pane, Splitpanes} from "splitpanes";
|
|
30
|
-
import {modelMixins} from "@/components/table/model/ModelMixins";
|
|
31
|
-
|
|
32
|
-
export default {
|
|
33
|
-
name: 'splitpanesModel',
|
|
34
|
-
mixins: [modelMixins],
|
|
35
|
-
components: {Splitpanes, Pane}, props: {
|
|
36
|
-
searchRow: {default: '0'},
|
|
37
|
-
theme1: {default: 't1'},
|
|
38
|
-
theme2: {default: 't2'},
|
|
39
|
-
horizontal: {default: true},
|
|
40
|
-
isLR: {default: true},
|
|
41
|
-
}, computed: {
|
|
42
|
-
getStyle() {
|
|
43
|
-
let px = Math.ceil(this.formConfig.items.length / 4) * 45;
|
|
44
|
-
let style = 'height: calc(100% - ' + px + 'px)'
|
|
45
|
-
return style
|
|
46
|
-
|
|
47
|
-
},
|
|
48
|
-
}, methods: {}, created() {
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
</script>
|
|
52
|
-
<style scoped>
|
|
53
|
-
@import "splitpanesModel.css";
|
|
54
|
-
</style>
|