Tags Collection nach unten verschoben. Icon für external Collection geändert. Content Collection erweitert um neues linkedEntries field.

This commit is contained in:
Mario Linz 2022-06-30 12:19:10 +02:00
parent d8e4f9c902
commit 49896d6978
6 changed files with 383 additions and 363 deletions

Binary file not shown.

View File

@ -39,7 +39,7 @@ meta:
tablist:
meta:
expand: general
expand: assignments
tabs:
- name: general
meta:
@ -61,6 +61,7 @@ meta:
source: meta
subFields:
- source: pages
- source: linkedArticleEntries
imageFilter:
xs:
@ -160,6 +161,24 @@ fields:
name: "path"
params:
sort: "path"
- name: linkedArticleEntries
type: string[]
meta:
hideInRoot: true
widget: linkedEntries
helperText:
de: "Verknüpfte Artikel dieser Seite."
en: "Linked articles to this page."
label:
de: Verknüpfte Artikel
en: Linked articles
defaultValue: []
choices:
endpoint: "articles"
params:
sort: "article.publish_date.from"
filter: { "article.assignments.pages": { source: "path" } }
template: { twig: "{{ article.content.title }}" }
- name: tags
type: string[]
meta:

View File

@ -11,7 +11,7 @@ meta:
# Navigationseintrag in der Admin-UI
label: { de: "Extern", en: "External" }
# Icon (Material UI) für den Navigationseintrag
muiIcon: web
muiIcon: download
# Identifizierung eines Eintrags für z.B. Select-Boxen in der Admin-UI
rowIdentTpl: { twig: "{{ path }}" }
# Standardsortierung der Liste

View File

@ -9,9 +9,9 @@ meta:
collections:
- !include collections/general.yml
- !include collections/navigation.yml
- !include collections/tags.yml
- !include collections/articles.yml
- !include collections/content.yml
- !include collections/external.yml
- !include collections/contact_form.yml
- !include collections/tags.yml
- !include collections/ssr.yml

View File

@ -218,15 +218,16 @@ export const getGeneralInformation = async (): Promise<GeneralInfo[]> => {
export const getArticles = async (collectionName: string, apiParams: APIParams): Promise<TibiArticle[]> => {
try {
let response = await api<TibiArticle[]>(collectionName, {
let apiParameters = {
method: "get",
offset: 0,
filter: {
"article.general.public": true,
},
filter: {},
sort: "article.general.sort",
...apiParams,
})
}
apiParameters.filter["article.general.public"] = true
let response = await api<TibiArticle[]>(collectionName, apiParameters)
return response.data
} catch (e) {
console.error(e)

710
yarn.lock

File diff suppressed because it is too large Load Diff