implement Events view as table
This commit is contained in:
		
							parent
							
								
									e7ba2acc0c
								
							
						
					
					
						commit
						d1279eb098
					
				
					 1 changed files with 27 additions and 1 deletions
				
			
		|  | @ -1,10 +1,36 @@ | |||
| <template> | ||||
|     <p>Events</p> | ||||
|   <div class="container-fluid px-xl-5 mt-3"> | ||||
|     <div class="row"> | ||||
|       <div class="col-xl-8 offset-xl-2"> | ||||
|         <Table | ||||
|           :columns="['slug', 'name']" | ||||
|           :items="events" | ||||
|           :keyName="'slug'" | ||||
|           v-slot="{ item }" | ||||
|         > | ||||
|           <div class="btn-group"> | ||||
|             <button class="btn btn-secondary" @click.stop="changeEvent(item)" > | ||||
|               <font-awesome-icon icon="archive"/> use | ||||
|             </button> | ||||
|             <button class="btn btn-danger" @click.stop="" > | ||||
|               <font-awesome-icon icon="trash"/> delete | ||||
|             </button> | ||||
|           </div> | ||||
|         </Table> | ||||
|       </div> | ||||
|     </div> | ||||
|   </div> | ||||
| </template> | ||||
| 
 | ||||
| <script> | ||||
| import {mapActions, mapState} from 'vuex'; | ||||
| import Table from '@/components/Table'; | ||||
| 
 | ||||
| export default { | ||||
|   name: 'Events', | ||||
|   components: {Table}, | ||||
|   computed: mapState(['events']), | ||||
|   methods: mapActions(['changeEvent']), | ||||
| }; | ||||
| </script> | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue