Ghost/core/frontend/services/routing/config/v3.js
Nazar Gargol bd92fcd282 🐛 Fixed /edit route redirect for tag taxonomies
refs 183e22e0bf (diff-f3a289058604b2b069d07bb8e2cda60cL39)

- When using the `/edit` route in the end of tag taxonomy redirect was landing on 404 page in Ghost-Admin. For example redirect for `/tags/getting-started/edit/` would redirect to `/#/settings/tags/getting-started`, instead of `/#/tags/getting-started`
- Referenced commit is where the routing in Ghost-Admin was changed from `/settings/tags/:slug/` to `/tags/:slug`
2020-04-16 21:23:38 +12:00

55 lines
1.1 KiB
JavaScript

/* eslint-disable */
module.exports.QUERY = {
tag: {
controller: 'tagsPublic',
type: 'read',
resource: 'tags',
options: {
slug: '%s',
visibility: 'public'
}
},
author: {
controller: 'authorsPublic',
type: 'read',
resource: 'authors',
options: {
slug: '%s'
}
},
post: {
controller: 'postsPublic',
type: 'read',
resource: 'posts',
options: {
slug: '%s'
}
},
page: {
controller: 'pagesPublic',
type: 'read',
resource: 'pages',
options: {
slug: '%s'
}
},
preview: {
controller: 'preview',
resource: 'preview'
}
};
module.exports.TAXONOMIES = {
tag: {
filter: 'tags:\'%s\'+tags.visibility:public',
editRedirect: '#/tags/:slug/',
resource: 'tags'
},
author: {
filter: 'authors:\'%s\'',
editRedirect: '#/team/:slug/',
resource: 'authors'
}
};
/* eslint-enable */