Merge branch 'master' into 6592-chat-component-+-button-open-search

This commit is contained in:
Hannes Heine 2023-07-20 10:11:41 +02:00 committed by GitHub
commit b881daef91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 14 additions and 14 deletions

View File

@ -58,14 +58,14 @@ export default {
routes.push({ routes.push({
label: this.$t('group.contentMenu.visitGroupPage'), label: this.$t('group.contentMenu.visitGroupPage'),
icon: 'home', icon: 'home',
name: 'group-id-slug', path: `/groups/${this.group.id}`,
params: { id: this.group.id, slug: this.group.slug }, params: { id: this.group.id, slug: this.group.slug },
}) })
} }
if (this.group.myRole === 'owner') { if (this.group.myRole === 'owner') {
routes.push({ routes.push({
label: this.$t('admin.settings.name'), label: this.$t('admin.settings.name'),
path: `/group/edit/${this.group.id}`, path: `/groups/edit/${this.group.id}`,
icon: 'edit', icon: 'edit',
}) })
} }

View File

@ -1,7 +1,7 @@
<template> <template>
<nuxt-link <nuxt-link
class="group-teaser" class="group-teaser"
:to="{ name: 'group-id-slug', params: { id: group.id, slug: group.slug } }" :to="{ name: 'groups-id-slug', params: { id: group.id, slug: group.slug } }"
> >
<base-card <base-card
:class="{ :class="{

View File

@ -9,7 +9,7 @@
<p class="description">{{ $t(`notifications.reason.${notification.reason}`) }}</p> <p class="description">{{ $t(`notifications.reason.${notification.reason}`) }}</p>
<nuxt-link <nuxt-link
class="link" class="link"
:to="{ name: isGroup ? 'group-id-slug' : 'post-id-slug', params, ...hashParam }" :to="{ name: isGroup ? 'groups-id-slug' : 'post-id-slug', params, ...hashParam }"
@click.native="$emit('read')" @click.native="$emit('read')"
> >
<base-card wideContent> <base-card wideContent>

View File

@ -65,7 +65,7 @@
class="notification-mention-post" class="notification-mention-post"
:class="{ 'notification-status': notification.read }" :class="{ 'notification-status': notification.read }"
:to="{ :to="{
name: isGroup(notification.from) ? 'group-id-slug' : 'post-id-slug', name: isGroup(notification.from) ? 'groups-id-slug' : 'post-id-slug',
params: params(notification.from), params: params(notification.from),
hash: hashParam(notification.from), hash: hashParam(notification.from),
}" }"

View File

@ -96,7 +96,7 @@ export default {
groupLink() { groupLink() {
const { id, slug } = this.group const { id, slug } = this.group
if (!(id && slug)) return '' if (!(id && slug)) return ''
return { name: 'group-id-slug', params: { slug, id } } return { name: 'groups-id-slug', params: { slug, id } }
}, },
groupSlug() { groupSlug() {
const { slug } = this.group || {} const { slug } = this.group || {}

View File

@ -148,7 +148,7 @@ export default {
case 'User': case 'User':
return 'profile-id-slug' return 'profile-id-slug'
case 'Group': case 'Group':
return 'group-id-slug' return 'groups-id-slug'
default: default:
return null return null
} }

View File

@ -24,7 +24,7 @@ const options = {
} }
`, `,
message: 'error-pages.group-not-found', message: 'error-pages.group-not-found',
path: 'group', path: 'groups',
} }
const persistentLinks = PersistentLinks(options) const persistentLinks = PersistentLinks(options)

View File

@ -59,7 +59,7 @@ export default {
}) })
this.$toast.success(this.$t('group.groupCreated')) this.$toast.success(this.$t('group.groupCreated'))
this.$router.history.push({ this.$router.history.push({
name: 'group-id-slug', name: 'groups-id-slug',
params: { id: responseId, slug: responseSlug }, params: { id: responseId, slug: responseSlug },
}) })
} catch (error) { } catch (error) {

View File

@ -33,11 +33,11 @@ export default {
return [ return [
{ {
name: this.$t('group.general'), name: this.$t('group.general'),
path: `/group/edit/${this.group.id}`, path: `/groups/edit/${this.group.id}`,
}, },
{ {
name: this.$t('group.members'), name: this.$t('group.members'),
path: `/group/edit/${this.group.id}/members`, path: `/groups/edit/${this.group.id}/members`,
}, },
] ]
}, },

View File

@ -60,7 +60,7 @@ export default {
}) })
this.$toast.success(this.$t('group.updatedGroup')) this.$toast.success(this.$t('group.updatedGroup'))
this.$router.history.push({ this.$router.history.push({
name: 'group-id-slug', name: 'groups-id-slug',
params: { id: responseId, slug: responseSlug }, params: { id: responseId, slug: responseSlug },
}) })
} catch (error) { } catch (error) {

View File

@ -1,5 +1,5 @@
import { mount } from '@vue/test-utils' import { mount } from '@vue/test-utils'
import groups from './groups.vue' import groups from './index.vue'
const localVue = global.localVue const localVue = global.localVue

View File

@ -7,7 +7,7 @@
<ds-space> <ds-space>
<!-- create group --> <!-- create group -->
<ds-space centered> <ds-space centered>
<nuxt-link :to="{ name: 'group-create' }"> <nuxt-link :to="{ name: 'groups-create' }">
<base-button <base-button
class="group-add-button" class="group-add-button"
icon="plus" icon="plus"