123456789101112131415161718192021222324252627282930313233343536373839404142434445 |
- <template>
- <div id="data-index">
- <data-slot>
- <component :is="model"></component>
- </data-slot>
- </div>
- </template>
- <script>
- import dataSlot from './data-slot.vue';
- import { mapState, createNamespacedHelpers } from 'vuex';
- export default {
- name: 'data-index',
- props: {},
- components: {
- dataSlot,
- modelexpert: () => import('../expert/index.vue'),
- modelproduct: () => import('../product/index.vue'),
- modelnews: () => import('../news/index.vue'),
- },
- data: function() {
- return {};
- },
- created() {},
- methods: {},
- computed: {
- ...mapState(['user']),
- model() {
- return `model${this.$route.query.viewType}`;
- },
- },
- metaInfo() {
- return { title: this.$route.meta.title };
- },
- watch: {
- test: {
- deep: true,
- immediate: true,
- handler(val) {},
- },
- },
- };
- </script>
- <style lang="less" scoped></style>
|