Merged in feat/SW-286-collectionPage (pull request #765)
Feat(SW-286): CollectionPage Approved-by: Erik Tiekstra Approved-by: Fredrik Thorsson
This commit is contained in:
@@ -5,6 +5,7 @@
|
||||
#import "./Refs/Card.graphql"
|
||||
#import "./Refs/LoyaltyCard.graphql"
|
||||
#import "./Refs/TeaserCard.graphql"
|
||||
|
||||
fragment CardsGrid_ContentPage on ContentPageBlocksCardsGrid {
|
||||
cards_grid {
|
||||
layout
|
||||
@@ -39,6 +40,38 @@ fragment CardsGrid_ContentPageRefs on ContentPageBlocksCardsGrid {
|
||||
}
|
||||
}
|
||||
|
||||
fragment CardsGrid_CollectionPage on CollectionPageBlocksCardsGrid {
|
||||
cards_grid {
|
||||
layout
|
||||
preamble
|
||||
theme
|
||||
title
|
||||
cardConnection(limit: 10) {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CardBlock
|
||||
...TeaserCardBlock
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fragment CardsGrid_CollectionPageRefs on CollectionPageBlocksCardsGrid {
|
||||
cards_grid {
|
||||
cardConnection(limit: 10) {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CardBlockRef
|
||||
...TeaserCardBlockRef
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fragment CardsGrid_LoyaltyPage on LoyaltyPageBlocksCardsGrid {
|
||||
cards_grid {
|
||||
layout
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
#import "../AccountPage/Ref.graphql"
|
||||
#import "../CollectionPage/Ref.graphql"
|
||||
#import "../ContentPage/Ref.graphql"
|
||||
#import "../LoyaltyPage/Ref.graphql"
|
||||
|
||||
#import "../PageLink/AccountPageLink.graphql"
|
||||
#import "../PageLink/CollectionPageLink.graphql"
|
||||
#import "../PageLink/ContentPageLink.graphql"
|
||||
#import "../PageLink/LoyaltyPageLink.graphql"
|
||||
|
||||
@@ -32,6 +34,12 @@ fragment Shortcuts_AccountPage on AccountPageContentShortcuts {
|
||||
}
|
||||
}
|
||||
|
||||
fragment Shortcuts_CollectionPage on CollectionPageBlocksShortcuts {
|
||||
shortcuts {
|
||||
...Shortcuts
|
||||
}
|
||||
}
|
||||
|
||||
fragment Shortcuts_ContentPage on ContentPageBlocksShortcuts {
|
||||
shortcuts {
|
||||
...Shortcuts
|
||||
@@ -65,6 +73,12 @@ fragment Shortcuts_AccountPageRefs on AccountPageContentShortcuts {
|
||||
}
|
||||
}
|
||||
|
||||
fragment Shortcuts_CollectionPageRefs on CollectionPageBlocksShortcuts {
|
||||
shortcuts {
|
||||
...ShortcutsRefs
|
||||
}
|
||||
}
|
||||
|
||||
fragment Shortcuts_ContentPageRefs on ContentPageBlocksShortcuts {
|
||||
shortcuts {
|
||||
...ShortcutsRefs
|
||||
|
||||
@@ -68,3 +68,64 @@ fragment UspGrid_ContentPageRefs on ContentPageBlocksUspGrid {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fragment UspGrid_CollectionPage on CollectionPageBlocksUspGrid {
|
||||
__typename
|
||||
usp_grid {
|
||||
cardsConnection {
|
||||
edges {
|
||||
node {
|
||||
... on UspGrid {
|
||||
usp_card {
|
||||
__typename
|
||||
icon
|
||||
text {
|
||||
embedded_itemsConnection {
|
||||
totalCount
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...AccountPageLink
|
||||
...ContentPageLink
|
||||
...HotelPageLink
|
||||
...LoyaltyPageLink
|
||||
}
|
||||
}
|
||||
}
|
||||
json
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fragment UspGrid_CollectionPageRefs on CollectionPageBlocksUspGrid {
|
||||
usp_grid {
|
||||
cardsConnection {
|
||||
edges {
|
||||
node {
|
||||
... on UspGrid {
|
||||
usp_card {
|
||||
text {
|
||||
embedded_itemsConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...AccountPageRef
|
||||
...ContentPageRef
|
||||
...HotelPageRef
|
||||
...LoyaltyPageRef
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
21
lib/graphql/Fragments/CollectionPage/NavigationLinks.graphql
Normal file
21
lib/graphql/Fragments/CollectionPage/NavigationLinks.graphql
Normal file
@@ -0,0 +1,21 @@
|
||||
#import "../PageLink/CollectionPageLink.graphql"
|
||||
#import "../PageLink/ContentPageLink.graphql"
|
||||
#import "../PageLink/HotelPageLink.graphql"
|
||||
#import "../PageLink/LoyaltyPageLink.graphql"
|
||||
|
||||
fragment NavigationLinks on CollectionPageHeader {
|
||||
navigation_links {
|
||||
title
|
||||
linkConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...HotelPageLink
|
||||
...CollectionPageLink
|
||||
...ContentPageLink
|
||||
...LoyaltyPageLink
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
7
lib/graphql/Fragments/CollectionPage/Ref.graphql
Normal file
7
lib/graphql/Fragments/CollectionPage/Ref.graphql
Normal file
@@ -0,0 +1,7 @@
|
||||
#import "../System.graphql"
|
||||
|
||||
fragment CollectionPageRef on CollectionPage {
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
12
lib/graphql/Fragments/PageLink/CollectionPageLink.graphql
Normal file
12
lib/graphql/Fragments/PageLink/CollectionPageLink.graphql
Normal file
@@ -0,0 +1,12 @@
|
||||
#import "../System.graphql"
|
||||
|
||||
fragment CollectionPageLink on CollectionPage {
|
||||
title
|
||||
url
|
||||
system {
|
||||
...System
|
||||
}
|
||||
web {
|
||||
original_url
|
||||
}
|
||||
}
|
||||
@@ -14,6 +14,14 @@ query GetLoyaltyPageSettings($uid: String!, $locale: String!) {
|
||||
}
|
||||
}
|
||||
|
||||
query GetCollectionPageSettings($uid: String!, $locale: String!) {
|
||||
collection_page(uid: $uid, locale: $locale) {
|
||||
page_settings {
|
||||
hide_booking_widget
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
query GetContentPageSettings($uid: String!, $locale: String!) {
|
||||
content_page(uid: $uid, locale: $locale) {
|
||||
page_settings {
|
||||
|
||||
28
lib/graphql/Query/Breadcrumbs/CollectionPage.graphql
Normal file
28
lib/graphql/Query/Breadcrumbs/CollectionPage.graphql
Normal file
@@ -0,0 +1,28 @@
|
||||
#import "../../Fragments/Breadcrumbs/Breadcrumbs.graphql"
|
||||
#import "../../Fragments/System.graphql"
|
||||
|
||||
query GetCollectionPageBreadcrumbs($locale: String!, $uid: String!) {
|
||||
collection_page(locale: $locale, uid: $uid) {
|
||||
web {
|
||||
breadcrumbs {
|
||||
...Breadcrumbs
|
||||
}
|
||||
}
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
query GetCollectionPageBreadcrumbsRefs($locale: String!, $uid: String!) {
|
||||
collection_page(locale: $locale, uid: $uid) {
|
||||
web {
|
||||
breadcrumbs {
|
||||
...BreadcrumbsRefs
|
||||
}
|
||||
}
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
}
|
||||
83
lib/graphql/Query/CollectionPage/CollectionPage.graphql
Normal file
83
lib/graphql/Query/CollectionPage/CollectionPage.graphql
Normal file
@@ -0,0 +1,83 @@
|
||||
#import "../../Fragments/System.graphql"
|
||||
|
||||
#import "../../Fragments/Blocks/CardsGrid.graphql"
|
||||
#import "../../Fragments/Blocks/Shortcuts.graphql"
|
||||
#import "../../Fragments/Blocks/UspGrid.graphql"
|
||||
|
||||
#import "../../Fragments/CollectionPage/NavigationLinks.graphql"
|
||||
|
||||
query GetCollectionPage($locale: String!, $uid: String!) {
|
||||
collection_page(uid: $uid, locale: $locale) {
|
||||
hero_image
|
||||
title
|
||||
header {
|
||||
heading
|
||||
preamble
|
||||
...NavigationLinks
|
||||
}
|
||||
blocks {
|
||||
__typename
|
||||
...CardsGrid_CollectionPage
|
||||
...Shortcuts_CollectionPage
|
||||
...UspGrid_CollectionPage
|
||||
}
|
||||
system {
|
||||
...System
|
||||
created_at
|
||||
updated_at
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
query GetCollectionPageRefs($locale: String!, $uid: String!) {
|
||||
collection_page(locale: $locale, uid: $uid) {
|
||||
header {
|
||||
navigation_links {
|
||||
linkConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CollectionPageRef
|
||||
...ContentPageRef
|
||||
...HotelPageRef
|
||||
...LoyaltyPageRef
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
blocks {
|
||||
__typename
|
||||
...CardsGrid_CollectionPageRefs
|
||||
...Shortcuts_CollectionPageRefs
|
||||
...UspGrid_CollectionPageRefs
|
||||
}
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
query GetDaDeEnUrlsCollectionPage($uid: String!) {
|
||||
de: collection_page(locale: "de", uid: $uid) {
|
||||
url
|
||||
}
|
||||
en: collection_page(locale: "en", uid: $uid) {
|
||||
url
|
||||
}
|
||||
da: collection_page(locale: "da", uid: $uid) {
|
||||
url
|
||||
}
|
||||
}
|
||||
|
||||
query GetFiNoSvUrlsCollectionPage($uid: String!) {
|
||||
fi: collection_page(locale: "fi", uid: $uid) {
|
||||
url
|
||||
}
|
||||
no: collection_page(locale: "no", uid: $uid) {
|
||||
url
|
||||
}
|
||||
sv: collection_page(locale: "sv", uid: $uid) {
|
||||
url
|
||||
}
|
||||
}
|
||||
@@ -9,6 +9,14 @@ query ResolveEntryByUrl($locale: String!, $url: String!) {
|
||||
}
|
||||
total
|
||||
}
|
||||
all_collection_page(where: { url: $url }, locale: $locale) {
|
||||
items {
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
total
|
||||
}
|
||||
all_content_page(where: { url: $url }, locale: $locale) {
|
||||
items {
|
||||
system {
|
||||
|
||||
Reference in New Issue
Block a user