vue2-client 1.15.129 → 1.15.131
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 +1 -1
- package/src/base-client/components/common/HIS/HButtons/HButtons.vue +71 -95
- package/src/base-client/components/common/HIS/HFormTable/HFormTable.vue +7 -104
- package/src/base-client/components/common/HIS/HTab/HTab.vue +52 -127
- package/src/components/STable/index.js +2 -12
- package/src/router/async/router.map.js +2 -2
- package/vue.config.js +3 -3
package/package.json
CHANGED
@@ -1,107 +1,21 @@
|
|
1
1
|
<script setup lang="ts">
|
2
2
|
import XButtons from '@vue2-client/base-client/components/common/XButtons/XButtons.vue'
|
3
|
-
import { ref
|
3
|
+
import { ref } from 'vue'
|
4
4
|
|
5
5
|
defineProps({
|
6
|
+
// HButtons特有的属性
|
6
7
|
buttonStyle: {
|
7
8
|
type: String,
|
8
9
|
default: 'button24'
|
9
10
|
}
|
10
11
|
})
|
11
12
|
|
12
|
-
|
13
|
-
const
|
14
|
-
|
15
|
-
// 防抖控制
|
16
|
-
let syncTimeout = null
|
17
|
-
function debounceSync (callback, delay = 100) {
|
18
|
-
if (syncTimeout) clearTimeout(syncTimeout)
|
19
|
-
syncTimeout = setTimeout(callback, delay)
|
20
|
-
}
|
21
|
-
|
22
|
-
// 方法缓存,避免重复挂载
|
23
|
-
const syncedMethods = new WeakMap()
|
24
|
-
|
25
|
-
function syncChildRefs () {
|
26
|
-
if (!instance || !instance.proxy || !xButtonsRef.value) return
|
27
|
-
const proxy = instance.proxy
|
28
|
-
const target = proxy.$refs
|
29
|
-
const childRefs = xButtonsRef.value.$refs
|
30
|
-
if (!childRefs) return
|
31
|
-
|
32
|
-
Object.entries(childRefs).forEach(([key, value]) => {
|
33
|
-
const v = Array.isArray(value) ? value[0] : value
|
34
|
-
if (target[key] !== v) target[key] = v
|
35
|
-
})
|
36
|
-
if (target.xButtonsRef !== xButtonsRef.value) target.xButtonsRef = xButtonsRef.value
|
37
|
-
}
|
38
|
-
|
39
|
-
function getAllFunctionNames (obj) {
|
40
|
-
if (!obj) return []
|
41
|
-
const names = new Set()
|
42
|
-
let current = obj
|
43
|
-
while (current && current !== Object.prototype) {
|
44
|
-
Object.getOwnPropertyNames(current).forEach(name => {
|
45
|
-
if (typeof obj[name] === 'function' && name !== 'constructor') names.add(name)
|
46
|
-
})
|
47
|
-
current = Object.getPrototypeOf(current)
|
48
|
-
}
|
49
|
-
return Array.from(names)
|
50
|
-
}
|
51
|
-
|
52
|
-
function syncChildMethods () {
|
53
|
-
if (!instance || !instance.proxy || !xButtonsRef.value) return
|
54
|
-
const proxy = instance.proxy
|
55
|
-
const inner = xButtonsRef.value
|
56
|
-
const cached = syncedMethods.get(inner) || new Set()
|
57
|
-
|
58
|
-
getAllFunctionNames(inner).forEach(name => {
|
59
|
-
if (cached.has(name) || proxy[name]) return
|
60
|
-
proxy[name] = function () {
|
61
|
-
if (xButtonsRef.value && typeof xButtonsRef.value[name] === 'function') {
|
62
|
-
return xButtonsRef.value[name].apply(xButtonsRef.value, arguments)
|
63
|
-
}
|
64
|
-
}
|
65
|
-
cached.add(name)
|
66
|
-
})
|
67
|
-
syncedMethods.set(inner, cached)
|
68
|
-
}
|
69
|
-
|
70
|
-
function syncAll () {
|
71
|
-
syncChildRefs()
|
72
|
-
syncChildMethods()
|
73
|
-
}
|
74
|
-
|
75
|
-
// 子组件生命周期事件回调,确保及时同步
|
76
|
-
function onInnerMounted () { nextTick(function () { debounceSync(syncAll) }) }
|
77
|
-
function onInnerUpdated () { nextTick(function () { debounceSync(syncChildRefs) }) }
|
78
|
-
|
79
|
-
// 生命周期与监听
|
80
|
-
onMounted(() => nextTick(() => debounceSync(syncAll)))
|
81
|
-
onUpdated(() => nextTick(() => debounceSync(syncAll)))
|
82
|
-
|
83
|
-
watch(() => xButtonsRef.value && xButtonsRef.value.$refs, () => nextTick(() => debounceSync(syncChildRefs)), { deep: true, flush: 'post' })
|
84
|
-
watch(() => xButtonsRef.value, () => nextTick(() => debounceSync(syncChildMethods)), { flush: 'post' })
|
85
|
-
|
86
|
-
// 常用方法显式代理(API更清晰)
|
87
|
-
function createMethodProxy (methodName) {
|
88
|
-
return function () {
|
89
|
-
const inst = xButtonsRef.value
|
90
|
-
if (inst && typeof inst[methodName] === 'function') return inst[methodName].apply(inst, arguments)
|
91
|
-
}
|
92
|
-
}
|
93
|
-
|
94
|
-
const COMMON_METHODS = [
|
95
|
-
'clickByKey', 'setButtons', 'disableButton', 'enableButton'
|
96
|
-
]
|
13
|
+
// 内部 XButtons 实例引用
|
14
|
+
const xButtonsRef = ref()
|
97
15
|
|
16
|
+
// 暴露方法:获取内部 XButtons 实例
|
98
17
|
defineExpose({
|
99
|
-
getXButtonsInstance: ()
|
100
|
-
// 显式常用方法
|
101
|
-
...COMMON_METHODS.reduce((acc, m) => {
|
102
|
-
acc[m] = createMethodProxy(m)
|
103
|
-
return acc
|
104
|
-
}, {})
|
18
|
+
getXButtonsInstance: function () { return xButtonsRef.value }
|
105
19
|
})
|
106
20
|
</script>
|
107
21
|
|
@@ -116,8 +30,6 @@ defineExpose({
|
|
116
30
|
ref="xButtonsRef"
|
117
31
|
v-bind="$attrs"
|
118
32
|
v-on="$listeners"
|
119
|
-
@hook:mounted="onInnerMounted"
|
120
|
-
@hook:updated="onInnerUpdated"
|
121
33
|
>
|
122
34
|
<template v-for="(_, name) in $slots" #[name]="slotData">
|
123
35
|
<slot :name="name" v-bind="slotData" />
|
@@ -127,5 +39,69 @@ defineExpose({
|
|
127
39
|
</template>
|
128
40
|
|
129
41
|
<style scoped lang="less">
|
130
|
-
.h-buttons-wrapper {
|
42
|
+
.h-buttons-wrapper {
|
43
|
+
// 基础样式
|
44
|
+
:deep(.ant-btn-group) {
|
45
|
+
.ant-btn {
|
46
|
+
border-radius: 6px;
|
47
|
+
background-color: #FFFFFF;
|
48
|
+
border: 1px solid #9499A0;
|
49
|
+
color: #313131;
|
50
|
+
font-weight: normal;
|
51
|
+
letter-spacing: 0em;
|
52
|
+
width: 110px;
|
53
|
+
font-size: 16px;
|
54
|
+
font-family: "Source Han Sans";
|
55
|
+
line-height: normal;
|
56
|
+
margin-right: 25px;
|
57
|
+
height: 32px;
|
58
|
+
}
|
59
|
+
}
|
60
|
+
|
61
|
+
// button24样式
|
62
|
+
&.h-buttons-button24 {
|
63
|
+
:deep(.ant-btn-group) {
|
64
|
+
.ant-btn {
|
65
|
+
border: 1px solid #CDCDCD;
|
66
|
+
color: #5D5C5C;
|
67
|
+
font-weight: normal;
|
68
|
+
letter-spacing: 0em;
|
69
|
+
font-size: 16px;
|
70
|
+
line-height: normal;
|
71
|
+
margin-right: 25px;
|
72
|
+
border-radius: 6px;
|
73
|
+
background-color: #FFFFFF;
|
74
|
+
// 这个不合理
|
75
|
+
// top: -100px;
|
76
|
+
width: fit-content;
|
77
|
+
min-width: 110px;
|
78
|
+
font-family: "Source Han Sans";
|
79
|
+
height: 32px;
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
83
|
+
|
84
|
+
// button23样式
|
85
|
+
&.h-buttons-button23 {
|
86
|
+
:deep(.ant-btn-group) {
|
87
|
+
.ant-btn {
|
88
|
+
border: none;
|
89
|
+
padding: 0 !important;
|
90
|
+
color: #FFFFFF;
|
91
|
+
font-weight: normal;
|
92
|
+
letter-spacing: 0em;
|
93
|
+
font-size: 16px;
|
94
|
+
line-height: normal;
|
95
|
+
border-radius: 50%;
|
96
|
+
background-color: #1890FF;
|
97
|
+
margin-left: 10px;
|
98
|
+
top: -88px;
|
99
|
+
width: 30px;
|
100
|
+
font-family: "Source Han Sans";
|
101
|
+
height: 30px;
|
102
|
+
}
|
103
|
+
}
|
104
|
+
}
|
105
|
+
|
106
|
+
}
|
131
107
|
</style>
|
@@ -1,117 +1,22 @@
|
|
1
1
|
<script setup lang="ts">
|
2
2
|
import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable.vue'
|
3
|
-
import { ref
|
3
|
+
import { ref } from 'vue'
|
4
4
|
|
5
5
|
defineProps({
|
6
|
+
// HFormTable特有的属性
|
6
7
|
tableStyle: {
|
7
8
|
type: String,
|
8
9
|
default: 'formtable-col1'
|
9
10
|
}
|
10
11
|
})
|
11
12
|
|
12
|
-
|
13
|
-
const
|
14
|
-
|
15
|
-
// 防抖控制
|
16
|
-
let syncTimeout = null
|
17
|
-
function debounceSync (callback, delay = 100) {
|
18
|
-
if (syncTimeout) clearTimeout(syncTimeout)
|
19
|
-
syncTimeout = setTimeout(callback, delay)
|
20
|
-
}
|
21
|
-
|
22
|
-
// 方法缓存,避免重复挂载
|
23
|
-
const syncedMethods = new WeakMap()
|
24
|
-
|
25
|
-
function syncChildRefs () {
|
26
|
-
if (!instance || !instance.proxy || !xFormTableRef.value) return
|
27
|
-
const proxy = instance.proxy
|
28
|
-
const target = proxy.$refs
|
29
|
-
const childRefs = xFormTableRef.value.$refs
|
30
|
-
if (!childRefs) return
|
31
|
-
|
32
|
-
Object.entries(childRefs).forEach(([key, value]) => {
|
33
|
-
const v = Array.isArray(value) ? value[0] : value
|
34
|
-
if (target[key] !== v) target[key] = v
|
35
|
-
})
|
36
|
-
if (target.xFormTableRef !== xFormTableRef.value) target.xFormTableRef = xFormTableRef.value
|
37
|
-
}
|
38
|
-
|
39
|
-
function getAllFunctionNames (obj) {
|
40
|
-
if (!obj) return []
|
41
|
-
const names = new Set()
|
42
|
-
let current = obj
|
43
|
-
while (current && current !== Object.prototype) {
|
44
|
-
Object.getOwnPropertyNames(current).forEach(name => {
|
45
|
-
if (typeof obj[name] === 'function' && name !== 'constructor') names.add(name)
|
46
|
-
})
|
47
|
-
current = Object.getPrototypeOf(current)
|
48
|
-
}
|
49
|
-
return Array.from(names)
|
50
|
-
}
|
51
|
-
|
52
|
-
function syncChildMethods () {
|
53
|
-
if (!instance || !instance.proxy || !xFormTableRef.value) return
|
54
|
-
const proxy = instance.proxy
|
55
|
-
const inner = xFormTableRef.value
|
56
|
-
const cached = syncedMethods.get(inner) || new Set()
|
57
|
-
|
58
|
-
getAllFunctionNames(inner).forEach(name => {
|
59
|
-
if (cached.has(name) || proxy[name]) return
|
60
|
-
proxy[name] = function () {
|
61
|
-
if (xFormTableRef.value && typeof xFormTableRef.value[name] === 'function') {
|
62
|
-
return xFormTableRef.value[name].apply(xFormTableRef.value, arguments)
|
63
|
-
}
|
64
|
-
}
|
65
|
-
cached.add(name)
|
66
|
-
})
|
67
|
-
syncedMethods.set(inner, cached)
|
68
|
-
}
|
69
|
-
|
70
|
-
function syncAll () {
|
71
|
-
syncChildRefs()
|
72
|
-
syncChildMethods()
|
73
|
-
}
|
74
|
-
|
75
|
-
// 子组件生命周期事件回调,确保及时同步
|
76
|
-
function onInnerMounted () { nextTick(function () { debounceSync(syncAll) }) }
|
77
|
-
function onInnerUpdated () { nextTick(function () { debounceSync(syncChildRefs) }) }
|
78
|
-
|
79
|
-
// 生命周期与监听
|
80
|
-
onMounted(() => nextTick(() => debounceSync(syncAll)))
|
81
|
-
onUpdated(() => nextTick(() => debounceSync(syncAll)))
|
82
|
-
|
83
|
-
watch(() => xFormTableRef.value && xFormTableRef.value.$refs, () => nextTick(() => debounceSync(syncChildRefs)), { deep: true, flush: 'post' })
|
84
|
-
watch(() => xFormTableRef.value, () => nextTick(() => debounceSync(syncChildMethods)), { flush: 'post' })
|
85
|
-
|
86
|
-
// 常用方法显式代理(API更清晰)
|
87
|
-
function createMethodProxy (methodName) {
|
88
|
-
return function () {
|
89
|
-
const inst = xFormTableRef.value
|
90
|
-
if (inst && typeof inst[methodName] === 'function') return inst[methodName].apply(inst, arguments)
|
91
|
-
}
|
92
|
-
}
|
93
|
-
|
94
|
-
const COMMON_METHODS = [
|
95
|
-
'reload', 'init', 'doSearch', 'resetForm', 'refreshTable',
|
96
|
-
'clearRowKeys', 'update', 'setTableData'
|
97
|
-
]
|
13
|
+
// 创建对XFormTable组件的引用
|
14
|
+
const xFormTableRef = ref()
|
98
15
|
|
16
|
+
// 暴露方法给父组件使用
|
99
17
|
defineExpose({
|
100
|
-
getXFormTableInstance
|
101
|
-
|
102
|
-
...COMMON_METHODS.reduce((acc, m) => {
|
103
|
-
acc[m] = createMethodProxy(m)
|
104
|
-
return acc
|
105
|
-
}, {}),
|
106
|
-
// 便捷:获取内部表格/表单ref
|
107
|
-
getTableRef: () => {
|
108
|
-
const refs = xFormTableRef.value && xFormTableRef.value.$refs
|
109
|
-
return (refs && (refs.table || refs.xTable)) || undefined
|
110
|
-
},
|
111
|
-
getFormRef: () => {
|
112
|
-
const refs = xFormTableRef.value && xFormTableRef.value.$refs
|
113
|
-
return (refs && (refs.form || refs.xForm)) || undefined
|
114
|
-
}
|
18
|
+
// 为了兼容性,保留getXFormTableInstance方法
|
19
|
+
getXFormTableInstance: () => xFormTableRef.value
|
115
20
|
})
|
116
21
|
</script>
|
117
22
|
|
@@ -126,8 +31,6 @@ defineExpose({
|
|
126
31
|
ref="xFormTableRef"
|
127
32
|
v-bind="$attrs"
|
128
33
|
v-on="$listeners"
|
129
|
-
@hook:mounted="onInnerMounted"
|
130
|
-
@hook:updated="onInnerUpdated"
|
131
34
|
>
|
132
35
|
<template v-for="(_, name) in $slots" #[name]="slotData">
|
133
36
|
<slot :name="name" v-bind="slotData" />
|
@@ -1,134 +1,22 @@
|
|
1
1
|
<script setup lang="ts">
|
2
2
|
import XTab from '@vue2-client/base-client/components/common/XTab/XTab.vue'
|
3
|
-
import { ref
|
3
|
+
import { ref } from 'vue'
|
4
4
|
|
5
5
|
defineProps({
|
6
|
+
// HTab特有的属性
|
6
7
|
hasTopMargin: {
|
7
8
|
type: Boolean,
|
8
9
|
default: true
|
9
10
|
}
|
10
11
|
})
|
11
12
|
|
12
|
-
|
13
|
-
|
14
|
-
const xTabRef = ref(null)
|
15
|
-
const instance = getCurrentInstance()
|
16
|
-
|
17
|
-
// 就绪承诺
|
18
|
-
let _resolveReady = null
|
19
|
-
let _readyPromise = null
|
20
|
-
function resetReady () {
|
21
|
-
_readyPromise = new Promise(function (resolve) { _resolveReady = resolve })
|
22
|
-
}
|
23
|
-
resetReady()
|
24
|
-
function markReady () {
|
25
|
-
if (_resolveReady) { _resolveReady(); _resolveReady = null }
|
26
|
-
emit('ready')
|
27
|
-
}
|
28
|
-
|
29
|
-
// 防抖控制
|
30
|
-
let syncTimeout = null
|
31
|
-
function debounceSync (callback, delay = 100) {
|
32
|
-
if (syncTimeout) clearTimeout(syncTimeout)
|
33
|
-
syncTimeout = setTimeout(callback, delay)
|
34
|
-
}
|
35
|
-
|
36
|
-
// 方法缓存
|
37
|
-
const syncedMethods = new WeakMap()
|
38
|
-
|
39
|
-
function getAllFunctionNames (obj) {
|
40
|
-
if (!obj) return []
|
41
|
-
const names = new Set()
|
42
|
-
let current = obj
|
43
|
-
while (current && current !== Object.prototype) {
|
44
|
-
Object.getOwnPropertyNames(current).forEach(name => {
|
45
|
-
if (typeof obj[name] === 'function' && name !== 'constructor') names.add(name)
|
46
|
-
})
|
47
|
-
current = Object.getPrototypeOf(current)
|
48
|
-
}
|
49
|
-
return Array.from(names)
|
50
|
-
}
|
51
|
-
|
52
|
-
function syncChildMethods () {
|
53
|
-
if (!instance || !instance.proxy || !xTabRef.value) return
|
54
|
-
const proxy = instance.proxy
|
55
|
-
const inner = xTabRef.value
|
56
|
-
const cached = syncedMethods.get(inner) || new Set()
|
57
|
-
getAllFunctionNames(inner).forEach(name => {
|
58
|
-
if (cached.has(name) || proxy[name]) return
|
59
|
-
proxy[name] = function () {
|
60
|
-
if (xTabRef.value && typeof xTabRef.value[name] === 'function') {
|
61
|
-
return xTabRef.value[name].apply(xTabRef.value, arguments)
|
62
|
-
}
|
63
|
-
}
|
64
|
-
cached.add(name)
|
65
|
-
})
|
66
|
-
syncedMethods.set(inner, cached)
|
67
|
-
}
|
68
|
-
|
69
|
-
// 访问时动态合并 $refs:原始 + 子组件(拍平数组)+ xTabRef
|
70
|
-
function installRefsGetter () {
|
71
|
-
if (!instance || !instance.proxy) return
|
72
|
-
const proxy = instance.proxy
|
73
|
-
const baseRefs = proxy.$refs
|
74
|
-
if (!baseRefs) return
|
75
|
-
try {
|
76
|
-
Object.defineProperty(proxy, '$refs', {
|
77
|
-
configurable: true,
|
78
|
-
get () {
|
79
|
-
const merged = {}
|
80
|
-
// 基础 refs
|
81
|
-
if (baseRefs) {
|
82
|
-
Object.keys(baseRefs).forEach(function (k) { merged[k] = baseRefs[k] })
|
83
|
-
}
|
84
|
-
// 子组件 refs
|
85
|
-
const child = xTabRef.value && xTabRef.value.$refs
|
86
|
-
if (child) {
|
87
|
-
Object.keys(child).forEach(function (k) {
|
88
|
-
const v = Array.isArray(child[k]) ? child[k][0] : child[k]
|
89
|
-
merged[k] = v
|
90
|
-
})
|
91
|
-
}
|
92
|
-
// xTabRef 本身
|
93
|
-
merged.xTabRef = xTabRef.value
|
94
|
-
return merged
|
95
|
-
}
|
96
|
-
})
|
97
|
-
} catch (e) {
|
98
|
-
// 忽略 defineProperty 失败,保持原逻辑
|
99
|
-
}
|
100
|
-
}
|
101
|
-
|
102
|
-
function syncAll () {
|
103
|
-
syncChildMethods()
|
104
|
-
markReady()
|
105
|
-
}
|
106
|
-
|
107
|
-
// 生命周期与监听
|
108
|
-
onMounted(() => nextTick(() => {
|
109
|
-
installRefsGetter()
|
110
|
-
debounceSync(function () { syncAll() })
|
111
|
-
}))
|
112
|
-
onUpdated(() => nextTick(() => debounceSync(function () { syncAll() })))
|
113
|
-
watch(() => xTabRef.value, () => nextTick(() => { resetReady(); debounceSync(function () { syncAll() }) }), { flush: 'post' })
|
114
|
-
|
115
|
-
// 常用方法显式代理
|
116
|
-
function createMethodProxy (methodName) {
|
117
|
-
return function () {
|
118
|
-
const inst = xTabRef.value
|
119
|
-
if (inst && typeof inst[methodName] === 'function') return inst[methodName].apply(inst, arguments)
|
120
|
-
}
|
121
|
-
}
|
122
|
-
|
123
|
-
const COMMON_METHODS = ['tabPaneChange', 'initConfig', 'getConfig']
|
13
|
+
// 创建对XTab组件的引用
|
14
|
+
const xTabRef = ref()
|
124
15
|
|
16
|
+
// 暴露方法给父组件使用
|
125
17
|
defineExpose({
|
18
|
+
// 为了兼容性,保留getXTabInstance方法
|
126
19
|
getXTabInstance: () => xTabRef.value,
|
127
|
-
whenReady: () => _readyPromise,
|
128
|
-
...COMMON_METHODS.reduce((acc, m) => { acc[m] = createMethodProxy(m); return acc }, {}),
|
129
|
-
getActiveKey: () => xTabRef.value && xTabRef.value.activeKey,
|
130
|
-
getConfigData: () => xTabRef.value && xTabRef.value.config,
|
131
|
-
getShowTabBar: () => xTabRef.value && xTabRef.value.showTabBar,
|
132
20
|
})
|
133
21
|
</script>
|
134
22
|
|
@@ -148,9 +36,16 @@ defineExpose({
|
|
148
36
|
|
149
37
|
<style scoped lang="less">
|
150
38
|
.h-tab-wrapper {
|
151
|
-
|
39
|
+
// 基础样式
|
40
|
+
:deep(.ant-tabs-tab-next) {
|
41
|
+
display: none;
|
42
|
+
}
|
43
|
+
|
152
44
|
:deep(.ant-tabs-nav) {
|
153
|
-
.ant-tabs-tab-next-icon {
|
45
|
+
.ant-tabs-tab-next-icon {
|
46
|
+
display: none;
|
47
|
+
}
|
48
|
+
|
154
49
|
.ant-tabs-tab {
|
155
50
|
background-color: transparent;
|
156
51
|
border-radius: 6px 6px 0 0;
|
@@ -164,6 +59,7 @@ defineExpose({
|
|
164
59
|
height: 32px;
|
165
60
|
text-align: center;
|
166
61
|
}
|
62
|
+
|
167
63
|
.ant-tabs-tab-active {
|
168
64
|
background-color: #0057FE;
|
169
65
|
color: #ffffff;
|
@@ -173,14 +69,43 @@ defineExpose({
|
|
173
69
|
text-align: center;
|
174
70
|
}
|
175
71
|
}
|
176
|
-
|
177
|
-
:deep(.ant-tabs-
|
178
|
-
|
179
|
-
|
72
|
+
|
73
|
+
:deep(.ant-tabs-bar) {
|
74
|
+
border-bottom: 2px solid #0057FE;
|
75
|
+
}
|
76
|
+
|
77
|
+
:deep(.ant-tabs-tab-arrow-show) {
|
78
|
+
display: none;
|
79
|
+
}
|
80
|
+
|
81
|
+
:deep(.ant-tabs-ink-bar) {
|
82
|
+
background-color: transparent;
|
83
|
+
bottom: -1px;
|
84
|
+
display: none;
|
85
|
+
height: 0;
|
86
|
+
}
|
87
|
+
|
88
|
+
:deep(.ant-tabs-tab-prev-icon-target) {
|
89
|
+
display: none;
|
90
|
+
}
|
91
|
+
|
92
|
+
// 带顶部边距的样式
|
180
93
|
&.h-tab-has-top-margin {
|
181
|
-
:deep(.ant-tabs-nav) {
|
182
|
-
|
183
|
-
|
94
|
+
:deep(.ant-tabs-nav) {
|
95
|
+
margin-top: 6px;
|
96
|
+
}
|
97
|
+
|
98
|
+
:deep(.ant-tabs-bar) {
|
99
|
+
margin: 0 6px;
|
100
|
+
}
|
101
|
+
|
102
|
+
:deep(.ant-card-body) {
|
103
|
+
padding: 6px 0;
|
104
|
+
|
105
|
+
.ant-card-body {
|
106
|
+
padding: 6px;
|
107
|
+
}
|
108
|
+
}
|
184
109
|
}
|
185
110
|
}
|
186
111
|
</style>
|
@@ -19,8 +19,7 @@ export default {
|
|
19
19
|
sortField: undefined,
|
20
20
|
sortOrder: undefined,
|
21
21
|
pageNum: 1,
|
22
|
-
pageSize: 10
|
23
|
-
localHidePagination: false
|
22
|
+
pageSize: 10
|
24
23
|
}
|
25
24
|
},
|
26
25
|
props: Object.assign({}, T.props, {
|
@@ -116,11 +115,6 @@ export default {
|
|
116
115
|
clickedRowColor () {
|
117
116
|
const themeColor = this.$store.state.setting.theme.color
|
118
117
|
return this.hexToRgba(themeColor || '#1890ff', 0.1)
|
119
|
-
},
|
120
|
-
|
121
|
-
// 计算是否隐藏分页
|
122
|
-
shouldHidePagination () {
|
123
|
-
return this.hidePagination || this.localHidePagination
|
124
118
|
}
|
125
119
|
},
|
126
120
|
watch: {
|
@@ -158,8 +152,6 @@ export default {
|
|
158
152
|
handler (val) {
|
159
153
|
if (val) {
|
160
154
|
this.pageSize = val
|
161
|
-
// 使用计算属性或本地状态来控制分页显示,而不是直接修改prop
|
162
|
-
this.localHidePagination = true
|
163
155
|
// 更新 localPagination
|
164
156
|
if (this.localPagination) {
|
165
157
|
Object.assign(this.localPagination, {
|
@@ -175,10 +167,8 @@ export default {
|
|
175
167
|
const { pageNo } = this.$route.params
|
176
168
|
const localPageNum = this.pageURI && (pageNo && parseInt(pageNo)) || this.pageNum
|
177
169
|
|
178
|
-
// 如果设置了 pageMaxSize,则使用该值作为分页大小并隐藏分页
|
179
170
|
if (this.pageMaxSize) {
|
180
171
|
this.pageSize = this.pageMaxSize
|
181
|
-
this.localHidePagination = true
|
182
172
|
}
|
183
173
|
|
184
174
|
this.localPagination = ['auto', true].includes(this.showPagination) && Object.assign({}, this.localPagination, {
|
@@ -558,7 +548,7 @@ export default {
|
|
558
548
|
<div class="table-wrapper">
|
559
549
|
{showAlert && this.showSelected && this.selectRowMode === 'default' ? this.renderAlert() : null}
|
560
550
|
{table}
|
561
|
-
{!this.
|
551
|
+
{!this.hidePagination ? pagination : null}
|
562
552
|
</div>
|
563
553
|
)
|
564
554
|
}
|
@@ -60,7 +60,7 @@ path: 'example',
|
|
60
60
|
// component: () => import('@vue2-client/base-client/components/common/XAddNativeForm/demo.vue'),
|
61
61
|
// component: () => import('@vue2-client/base-client/components/common/XFormGroup/demo.vue'),
|
62
62
|
// component: () => import('@vue2-client/base-client/components/common/XReport/XReportDemo.vue'),
|
63
|
-
|
63
|
+
component: () => import('@vue2-client/base-client/components/common/XFormTable/demo.vue'),
|
64
64
|
// component: () => import('@vue2-client/base-client/components/common/XDatePicker/demo.vue'),
|
65
65
|
// component: () => import('@vue2-client/base-client/components/common/XTab/XTabDemo.vue'),
|
66
66
|
// component: () => import('@vue2-client/base-client/components/common/XRate/demo.vue'),
|
@@ -79,7 +79,7 @@ path: 'example',
|
|
79
79
|
// component: () => import('@vue2-client/pages/LogicCallExample/index.vue'),
|
80
80
|
// component: () => import('@vue2-client/components/FilePreview/FilePreviewDemo.vue'),
|
81
81
|
// component: () => import('@vue2-client/pages/ReportGrid/index.vue'),
|
82
|
-
component: () => import('@vue2-client/base-client/components/common/HIS/demo.vue'),
|
82
|
+
// component: () => import('@vue2-client/base-client/components/common/HIS/demo.vue'),
|
83
83
|
}
|
84
84
|
// routerResource.example = () =>
|
85
85
|
// import('@vue2-client/pages/Example')
|
package/vue.config.js
CHANGED
@@ -11,11 +11,11 @@ const productionGzipExtensions = ['js', 'css']
|
|
11
11
|
const isProd = process.env.NODE_ENV === 'production'
|
12
12
|
|
13
13
|
// v4 产品演示
|
14
|
-
const v3Server = '
|
14
|
+
const v3Server = 'http://aote-office.8866.org:31567'
|
15
15
|
// const gateway = 'http://192.168.50.67:31467'
|
16
16
|
// const testUpload = 'http://123.60.214.109:8406'
|
17
|
-
const OSSServerDev = '
|
18
|
-
const revenue = '
|
17
|
+
const OSSServerDev = 'http://192.168.50.67:30351'
|
18
|
+
const revenue = 'http://aote-office.8866.org:31567'
|
19
19
|
// const revenue = 'http://127.0.0.1:31467'
|
20
20
|
// const OSSServerProd = 'http://192.168.50.67:31351'
|
21
21
|
// const testUploadLocal = 'http://127.0.0.1:9001'
|