Fixed all preview urls
This commit is contained in:
parent
afc8cde2c2
commit
47f8a12042
|
@ -21,3 +21,5 @@ SFTP_USERNAME=someuser
|
||||||
SFTP_HOST=host.com
|
SFTP_HOST=host.com
|
||||||
SFTP_DESTINATION_PATH_ROOT="/absolute/path/to/destination/root/folder"
|
SFTP_DESTINATION_PATH_ROOT="/absolute/path/to/destination/root/folder"
|
||||||
SFTP_BASE_URL=https://base-url.com
|
SFTP_BASE_URL=https://base-url.com
|
||||||
|
|
||||||
|
PAYLOAD_PUBLIC_FRONTEND_BASE_URL=https://domain.com
|
|
@ -28,7 +28,7 @@ export const Audios = buildCollectionConfig({
|
||||||
defaultSort: fields.updatedAt,
|
defaultSort: fields.updatedAt,
|
||||||
admin: {
|
admin: {
|
||||||
group: CollectionGroups.Media,
|
group: CollectionGroups.Media,
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/audios/${slug}`,
|
preview: ({ id }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/audios/${id}`,
|
||||||
defaultColumns: [
|
defaultColumns: [
|
||||||
fields.filename,
|
fields.filename,
|
||||||
fields.thumbnail,
|
fields.thumbnail,
|
||||||
|
|
|
@ -128,7 +128,7 @@ export const Collectibles = buildVersionedCollectionConfig({
|
||||||
"A physical or digital item. This can be a book, a CD/DVD, a video game copy...\
|
"A physical or digital item. This can be a book, a CD/DVD, a video game copy...\
|
||||||
any product related to our Scope.\
|
any product related to our Scope.\
|
||||||
This can also include merchandises such as figurines, music boxes, posters, key chains...",
|
This can also include merchandises such as figurines, music boxes, posters, key chains...",
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/collectibles/${slug}`,
|
preview: ({ slug }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/collectibles/${slug}`,
|
||||||
hooks: {
|
hooks: {
|
||||||
beforeDuplicate: beforeDuplicatePiping([
|
beforeDuplicate: beforeDuplicatePiping([
|
||||||
beforeDuplicateUnpublish,
|
beforeDuplicateUnpublish,
|
||||||
|
|
|
@ -38,7 +38,7 @@ export const Folders = buildCollectionConfig({
|
||||||
],
|
],
|
||||||
description:
|
description:
|
||||||
"Folders provide a way to structure our content. A folder can contain subfolders and/or files.",
|
"Folders provide a way to structure our content. A folder can contain subfolders and/or files.",
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/folders/${slug}`,
|
preview: ({ slug }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/folders/${slug}`,
|
||||||
},
|
},
|
||||||
endpoints: [getBySlugEndpoint],
|
endpoints: [getBySlugEndpoint],
|
||||||
fields: [
|
fields: [
|
||||||
|
|
|
@ -26,7 +26,7 @@ export const Images = buildImageCollectionConfig({
|
||||||
plural: "Images",
|
plural: "Images",
|
||||||
},
|
},
|
||||||
admin: {
|
admin: {
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/images/${slug}`,
|
preview: ({ id }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/images/${id}`,
|
||||||
defaultColumns: [fields.filename, fields.posts, fields.updatedAt],
|
defaultColumns: [fields.filename, fields.posts, fields.updatedAt],
|
||||||
},
|
},
|
||||||
upload: {
|
upload: {
|
||||||
|
|
|
@ -53,7 +53,7 @@ export const Pages = buildVersionedCollectionConfig({
|
||||||
fields.folders,
|
fields.folders,
|
||||||
],
|
],
|
||||||
group: CollectionGroups.Collections,
|
group: CollectionGroups.Collections,
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/pages/${slug}`,
|
preview: ({ slug }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/pages/${slug}`,
|
||||||
components: {
|
components: {
|
||||||
BeforeListTable: [
|
BeforeListTable: [
|
||||||
() =>
|
() =>
|
||||||
|
|
|
@ -37,7 +37,7 @@ export const Videos = buildCollectionConfig({
|
||||||
defaultSort: fields.updatedAt,
|
defaultSort: fields.updatedAt,
|
||||||
admin: {
|
admin: {
|
||||||
group: CollectionGroups.Media,
|
group: CollectionGroups.Media,
|
||||||
preview: ({ slug }) => `https://v3.accords-library.com/en/videos/${slug}`,
|
preview: ({ id }) => `${process.env.PAYLOAD_PUBLIC_FRONTEND_BASE_URL}/en/videos/${id}`,
|
||||||
defaultColumns: [
|
defaultColumns: [
|
||||||
fields.filename,
|
fields.filename,
|
||||||
fields.thumbnail,
|
fields.thumbnail,
|
||||||
|
|
Loading…
Reference in New Issue