1234567891011121314151617181920212223242526272829303132333435363738394041 |
- <template>
- <div>
- <list ref="list">
- <add v-if="tool.checkAuth($route.name,'insert')" slot="add" @addClick="addClick" style="margin-bottom:10px"></add>
- <template v-if="tool.checkAuth($route.name,'delete')" v-slot:del="scope">
- <ondel class="inline-16" :data="scope.data.data" @onSuccess="$refs.list.queryTypeList()"></ondel>
- </template>
- <template v-if="tool.checkAuth($route.name,'update')" v-slot:edit="scope">
- <edit class="inline-16" :data="scope.data.data" @onSuccess="$refs.list.queryTypeList()" @onEdit="onEdit"></edit>
- </template>
- </list>
- </div>
- </template>
- <script>
- import list from './modules/list.vue'
- import add from './modules/add.vue'
- import edit from './modules/edit.vue'
- import ondel from './modules/del.vue'
- export default {
- components:{
- list,
- add,
- edit,
- ondel
- },
- methods: {
- addClick () {
- this.$refs.list.addPate()
- },
- onEdit (data) {
- this.$refs.list.cellClick(data)
- }
- }
- }
- </script>
- <style>
- </style>
|