mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
prework for group list
This commit is contained in:
parent
dc2f5f255d
commit
d50ae27e49
@ -25,8 +25,8 @@
|
|||||||
|
|
||||||
</ds-form>
|
</ds-form>
|
||||||
<ds-space centered>
|
<ds-space centered>
|
||||||
zurück
|
<nuxt-link to="/my-groups">zurück</nuxt-link>
|
||||||
</ds-space>
|
</ds-space>
|
||||||
</ds-container>
|
</ds-container>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@ -35,6 +35,7 @@
|
|||||||
import CategoriesSelect from '~/components/CategoriesSelect/CategoriesSelect'
|
import CategoriesSelect from '~/components/CategoriesSelect/CategoriesSelect'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
name: 'GroupForm',
|
||||||
components: {
|
components: {
|
||||||
CategoriesSelect,
|
CategoriesSelect,
|
||||||
},
|
},
|
||||||
|
|||||||
27
webapp/components/GroupList/GroupList.vue
Normal file
27
webapp/components/GroupList/GroupList.vue
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<ds-container class="group-list">
|
||||||
|
<ds-space><h2>Group List</h2></ds-space>
|
||||||
|
<ds-table :data="items" :fields="fields">
|
||||||
|
<template slot="loves" slot-scope="scope">
|
||||||
|
{{ scope.row.name }} loves {{ scope.row.loves }}
|
||||||
|
</template>
|
||||||
|
<template slot="edit" slot-scope="scope">
|
||||||
|
<ds-button
|
||||||
|
size="small"
|
||||||
|
@click="deleteRow(scope.row)">delete</ds-button>
|
||||||
|
</template>
|
||||||
|
</ds-table>
|
||||||
|
</ds-container>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script lang="ts">
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'GroupList',
|
||||||
|
props: {
|
||||||
|
items: { type: Array, default: () => [] },
|
||||||
|
fields: { type: Array, default: () => [] }
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
@ -1,7 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="group-teaser">
|
<div class="group-teaser">
|
||||||
Group Teaser
|
|
||||||
|
|
||||||
<ds-grid-item :row-span="2" column-span="fullWidth">
|
<ds-grid-item :row-span="2" column-span="fullWidth">
|
||||||
<ds-space centered>
|
<ds-space centered>
|
||||||
<nuxt-link :to="{ name: 'group-create' }">
|
<nuxt-link :to="{ name: 'group-create' }">
|
||||||
@ -22,3 +20,10 @@
|
|||||||
</ds-grid-item>
|
</ds-grid-item>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
<script>
|
||||||
|
|
||||||
|
export default {
|
||||||
|
name: 'GroupTeaser',
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|||||||
@ -2,15 +2,45 @@
|
|||||||
<div>
|
<div>
|
||||||
<div>my groups</div>
|
<div>my groups</div>
|
||||||
<group-teaser />
|
<group-teaser />
|
||||||
|
<group-list :items="items" :fields="fields"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import GroupTeaser from '~/components/GroupTeaser/GroupTeaser.vue'
|
import GroupTeaser from '~/components/GroupTeaser/GroupTeaser.vue'
|
||||||
|
import GroupList from '~/components/GroupList/GroupList.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'MyGroups',
|
name: 'MyGroups',
|
||||||
components: {
|
components: {
|
||||||
GroupTeaser,
|
GroupTeaser,
|
||||||
|
GroupList
|
||||||
},
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
fields: ['name', 'type', 'loves', 'edit'],
|
||||||
|
items: [
|
||||||
|
{
|
||||||
|
name: 'Rengar',
|
||||||
|
type: 'Jungler',
|
||||||
|
loves: 'Hide and seek'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Renekton',
|
||||||
|
type: 'Toplaner',
|
||||||
|
loves: 'Slice and dice'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Twitch',
|
||||||
|
type: 'ADC',
|
||||||
|
loves: 'Spray and pray'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Blitz',
|
||||||
|
type: 'Support',
|
||||||
|
loves: 'Hook you up'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user