Files
dvcp_v2_webapp/project/qianxinan/AppPointsDetails/AppPointsDetails.vue

64 lines
1.2 KiB
Vue
Raw Normal View History

2022-12-21 10:17:03 +08:00
<template>
2023-01-03 11:54:23 +08:00
<div class="AppPointsDetails">
<keep-alive :include="['List']">
<component ref="component" :is="component" @change="onChange" :params="params" :instance="instance" :dict="dict"></component>
</keep-alive>
</div>
2022-12-21 10:17:03 +08:00
</template>
<script>
2023-01-03 11:54:23 +08:00
import List from './components/List'
import Detail from './components/Detail'
2022-12-21 10:17:03 +08:00
2023-01-03 11:54:23 +08:00
export default {
name: 'AppPointsDetails',
label: '积分明细(黔西南)',
props: {
instance: Function,
dict: Object
2022-12-21 10:17:03 +08:00
},
2023-01-03 11:54:23 +08:00
data () {
return {
component: 'List',
params: {},
include: []
2022-12-21 10:17:03 +08:00
}
},
2023-01-03 11:54:23 +08:00
components: {
Detail,
List
2022-12-21 10:17:03 +08:00
},
2023-01-03 11:54:23 +08:00
methods: {
onChange (data) {
if (data.type === 'Detail') {
this.component = 'Detail'
this.params = data.params
2022-12-21 10:17:03 +08:00
}
2023-01-03 11:54:23 +08:00
if (data.type === 'List') {
this.component = 'List'
this.params = data.params
2022-12-21 10:17:03 +08:00
2023-01-03 11:54:23 +08:00
this.$nextTick(() => {
if (data.isRefresh) {
this.$refs.component.getList()
2022-12-21 10:17:03 +08:00
}
})
}
}
}
}
2023-01-03 11:54:23 +08:00
</script>
2022-12-21 10:17:03 +08:00
2023-01-03 11:54:23 +08:00
<style lang="scss">
.AppPointsDetails {
height: 100%;
background: #F3F6F9;
overflow: auto;
2022-12-21 10:17:03 +08:00
}
</style>