Package org.exoplatform.portal.mop.page

Examples of org.exoplatform.portal.mop.page.PageState


                    Page page = configService.createPageTemplate(PAGE_TEMPLATE, siteKey.getTypeName(), siteKey.getName());
                    page.setName(DEFAULT_TAB_NAME);
                    page.setTitle(DEFAULT_TAB_NAME);

                    //
                    PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                            page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page
                                    .getAccessPermissions()) : null, page.getEditPermission());
                    configService.getPageService().savePage(new PageContext(page.getPageKey(), pageState));

                    //
View Full Code Here


                            page.setChildren(new ArrayList<ModelObject>());
                        }

                        //
                        PageService pageService = uiPage.getApplicationComponent(PageService.class);
                        PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                                page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page
                                        .getAccessPermissions()) : null, page.getEditPermission());
                        pageService.savePage(new PageContext(page.getPageKey(), pageState));

                        //
View Full Code Here

                    page.setChildren(new ArrayList<ModelObject>());
                }

                //
                PageService pageService = uiPage.getApplicationComponent(PageService.class);
                PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                        page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions())
                                : null, page.getEditPermission());
                pageService.savePage(new PageContext(page.getPageKey(), pageState));

                //
View Full Code Here

        return pages;
    }

    public static PageState toPageState(Page page) {
        return new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(), page.getFactoryId(),
                page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions()) : null,
                page.getEditPermission());
    }
View Full Code Here

            // Perform model update
            DataStorage dataService = uiWorkingWS.getApplicationComponent(DataStorage.class);
            PageService pageService = uiWorkingWS.getApplicationComponent(PageService.class);
            try {
                PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                        page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions())
                                : null, page.getEditPermission());
                pageService.savePage(new PageContext(pageKey, pageState));
                dataService.save(page);
            } catch (StaleModelException ex) {
View Full Code Here

                if (page.getChildren() == null) {
                    page.setChildren(new ArrayList<ModelObject>());
                }

                //
                PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                        page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions())
                                : null, page.getEditPermission());
                pageService.savePage(new PageContext(page.getPageKey(), pageState));

                //
View Full Code Here

        createdNode.setPageRef(page.getPageKey());

        //
        PageService pageService = getApplicationComponent(PageService.class);
        PageState pageState = new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(),
                page.getFactoryId(), page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions()) : null,
                page.getEditPermission());
        pageService.savePage(new PageContext(page.getPageKey(), pageState));

        //
View Full Code Here

            default:
                throw new AssertionError();
        }

        if (dst != null) {
            PageState dstState = new PageState(dst.getTitle(), dst.getDescription(), dst.isShowMaxWindow(), dst.getFactoryId(),
                    dst.getAccessPermissions() != null ? Arrays.asList(dst.getAccessPermissions()) : null,
                    dst.getEditPermission());

            pageService.savePage(new PageContext(src.getPageKey(), dstState));
            service.save(dst);
View Full Code Here

            default:
                throw new AssertionError();
        }

        if (dst != null) {
            PageState dstState = PageUtils.toPageState(dst);

            pageService.savePage(new PageContext(src.getPageKey(), dstState));
            service.save(dst);
        }
    }
View Full Code Here

        return pages;
    }

    public static PageState toPageState(Page page) {
        return new PageState(page.getTitle(), page.getDescription(), page.isShowMaxWindow(), page.getFactoryId(),
                page.getAccessPermissions() != null ? Arrays.asList(page.getAccessPermissions()) : null,
                page.getEditPermission(), page.getMoveAppsPermissions() != null ? Arrays.asList(page.getMoveAppsPermissions()) : null,
                page.getMoveContainersPermissions() != null ? Arrays.asList(page.getMoveContainersPermissions()) : null);
    }
View Full Code Here

TOP

Related Classes of org.exoplatform.portal.mop.page.PageState

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.