thainv-dev: fix
This commit is contained in:
@@ -27,13 +27,12 @@ export const useDynamicPageStore = defineStore("dynamicPageStore", () => {
|
||||
contentArr.push(section.content && typeof section.content === 'string' && JSON.parse(section.content));
|
||||
return section;
|
||||
});
|
||||
console.log(currentPage.value.sections ,'sectionPublished 2')
|
||||
|
||||
|
||||
sectionPublished.value = currentPage.value.sections && currentPage.value.sections.filter(
|
||||
(section: any) => section.isPublished && !contentArr.flat().some((_section: any) => _section && _section.data && _section.type === "section" && section.id === _section.data)
|
||||
);
|
||||
|
||||
console.log(sectionPublished.value ,'sectionPublished')
|
||||
};
|
||||
|
||||
const setComponentPublished = () => {
|
||||
@@ -43,7 +42,7 @@ export const useDynamicPageStore = defineStore("dynamicPageStore", () => {
|
||||
return section;
|
||||
});
|
||||
componentPublished.value = currentPage.value.components && currentPage.value.components.filter((section: any) => section.isPublished);
|
||||
console.log(componentPublished.value, 'componentPublished2')
|
||||
|
||||
};
|
||||
|
||||
const setDataQuery = (query: any, componentId: number | string) => {
|
||||
|
||||
Reference in New Issue
Block a user