Skip to content

Commit

Permalink
Revert "chore: update the backend-url"
Browse files Browse the repository at this point in the history
This reverts commit 78a1e3d.
  • Loading branch information
AliKdhim87 committed Aug 1, 2023
1 parent 78a1e3d commit cc54065
Show file tree
Hide file tree
Showing 13 changed files with 30 additions and 17 deletions.
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/[...not-found]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { fetchData } from '@/util/fetchData';

const NotFoundPage = async ({ params: { locale } }: { params: { locale: string } }) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_NOT_FOUND_PAGE,
variables: { locale: locale },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/demo/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { fetchData } from '@/util/fetchData';

const Demo = async ({ params: { locale } }: { params: { locale: string } }) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_VISUALISATIES,
variables: { locale: locale },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/not-found.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { fetchData } from '@/util/fetchData';
const NotFoundPage = async () => {
const locale = cookies().get('i18next')?.value;
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_NOT_FOUND_PAGE,
variables: { locale: locale },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ const Home = async ({ params: { locale } }: { params: any }) => {

const productsAvailability = alphabet.map(async (letter) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: CHECK_ALPHABETICALLY_PRODUCTS_AVAILABILITY,
variables: { locale, startsWith: letter },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/products/[slug]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import { fetchData } from '@/util/fetchData';
const getAllProducts = async (locale: string, slug: string) => {
const { isEnabled } = draftMode();
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_PRODUCT_BY_SLUG_FETCH,
variables: {
slug: slug,
Expand Down
4 changes: 2 additions & 2 deletions apps/frontend/src/app/[locale]/products/alphabet/[q]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ const mappingProducts = (products: Product[]): { title: string; url: string }[]

const fetchAllProducts = async ({ locale, page, pageSize, startsWith }: fetchAllProductsTypes) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_ALPHABETICALLY_PRODUCTS_BY_LETTER,
variables: { locale, page, pageSize, startsWith },
});
Expand Down Expand Up @@ -89,7 +89,7 @@ const ProductsAlphabetPage = async ({ params: { locale, q } }: Params) => {

const productsAvailability = alphabet.map(async (letter) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: CHECK_ALPHABETICALLY_PRODUCTS_AVAILABILITY,
variables: { locale, startsWith: letter },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/products/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const mappingProducts = (products: Product[]): { title: string; url: string }[]

const fetchAllProducts = async ({ locale, page, pageSize }: fetchAllProductsTypes) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_ALL_PRODUCTS_SLUG_FETCH,
variables: { locale, page, pageSize },
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { fetchData } from '@/util/fetchData';

export async function GET(_request: NextRequest, ctx: any) {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_SAMENWERKENDECATALOGI_FETCH,
variables: {
locale: ctx.params.locale,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { fetchData } from '@/util/fetchData';

const getSearchTipsPage = async (locale: string) => {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_SEARCH_TIP_PAGE,
variables: { locale: locale },
});
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/[locale]/sitemap.xml/route.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const generateStaticPagesPath = (locales: typeof languages, paths: string[]) =>
export async function GET() {
try {
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_ALL_PRODUCTS_SLUG_FETCH,
variables: {
locale: 'all',
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/api/current-pathname/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export async function GET(request: Request) {
const cookieStore = cookies();
cookieStore.set('slug', slug);
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_PRODUCT_BY_SLUG_FETCH,
variables: {
slug: slug,
Expand Down
2 changes: 1 addition & 1 deletion apps/frontend/src/app/api/preview/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ export async function GET(request: Request) {

// Fetch the headless CMS to check if the provided `slug` exists
const { data } = await fetchData({
url: `${process.env.STRAPI_IMAGE_URL}/graphql` as string,
url: process.env.STRAPI_BACKEND_URL as string,
query: GET_PRODUCT_BY_SLUG_AND_LOCALE_FETCH,
variables: {
slug: slug,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,27 @@
"attributes": {
"singleDigitalGateway": {
"type": "enumeration",
"enum": ["ja", "nee"],
"enum": [
"ja",
"nee"
],
"required": true,
"private": true
},
"attachementAdded": {
"type": "enumeration",
"enum": ["ja", "nee"],
"enum": [
"ja",
"nee"
],
"private": true
},
"linkedEForm": {
"type": "enumeration",
"enum": ["ja", "nee"],
"enum": [
"ja",
"nee"
],
"private": true,
"required": true
},
Expand All @@ -38,7 +47,11 @@
},
"identificationMethod": {
"type": "enumeration",
"enum": ["digid", "eherkenning", "eidas"]
"enum": [
"digid",
"eherkenning",
"eidas"
]
}
}
}

0 comments on commit cc54065

Please sign in to comment.