Package it.cilea.osd.jdyna.dto

Examples of it.cilea.osd.jdyna.dto.AnagraficaObjectAreaDTO


        // this map contains key-values pairs, key = box shortname and values =
        // collection of metadata
        Map<String, List<IContainable>> mapBoxToContainables = new HashMap<String, List<IContainable>>();

        AnagraficaObjectAreaDTO anagraficaObjectDTO = (AnagraficaObjectAreaDTO) command;

        // check admin authorization
        boolean isAdmin = false;
        Context context = UIUtil.obtainContext(request);
        if (AuthorizeManager.isAdmin(context))
        {
            isAdmin = true;
        }

        // collection of edit tabs (all edit tabs created on system associate to
        // visibility)
        List<EditTabOrganizationUnit> tabs = getApplicationService()
                .getTabsByVisibility(EditTabOrganizationUnit.class, isAdmin);

        // check if request tab from view is active (check on collection before)
        EditTabOrganizationUnit editT = getApplicationService().get(
                EditTabOrganizationUnit.class, anagraficaObjectDTO.getTabId());
        if (!tabs.contains(editT))
        {
            throw new AuthorizeException(
                    "You not have needed authorization level to display this tab");
        }

        // collection of boxs
        List<BoxOrganizationUnit> propertyHolders = new LinkedList<BoxOrganizationUnit>();

        // if edit tab got a display tab (edit tab is hookup to display tab)
        // then edit box will be created from display box otherwise get all boxs
        // in edit tab
        if (editT.getDisplayTab() != null)
        {
            for (BoxOrganizationUnit box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), anagraficaObjectDTO.getTabId());
        }

        // clean boxs list with accesslevel
        List<BoxOrganizationUnit> propertyHoldersCurrentAccessLevel = new LinkedList<BoxOrganizationUnit>();
        for (BoxOrganizationUnit propertyHolder : propertyHolders)
View Full Code Here


    @Override
    protected void onBindAndValidate(HttpServletRequest request,
            Object command, BindException errors) throws Exception
    {

        AnagraficaObjectAreaDTO dto = (AnagraficaObjectAreaDTO) command;
        OrganizationUnit researcher = getApplicationService().get(OrganizationUnit.class,
                dto.getParentId());
        OUAdditionalFieldStorage myObject = researcher.getDynamicField();

        EditTabOrganizationUnit editT = getApplicationService().get(
                EditTabOrganizationUnit.class, dto.getTabId());
        List<BoxOrganizationUnit> propertyHolders = new LinkedList<BoxOrganizationUnit>();
        if (editT.getDisplayTab() != null)
        {
            for (BoxOrganizationUnit box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), dto.getTabId());
        }

        List<IContainable> tipProprietaInArea = new LinkedList<IContainable>();

        for (BoxOrganizationUnit iph : propertyHolders)
View Full Code Here

        // this map contains key-values pairs, key = box shortname and values =
        // collection of metadata
        Map<String, List<IContainable>> mapBoxToContainables = new HashMap<String, List<IContainable>>();

        AnagraficaObjectAreaDTO anagraficaObjectDTO = (AnagraficaObjectAreaDTO) command;

        // check admin authorization
        boolean isAdmin = false;
        Context context = UIUtil.obtainContext(request);
        if (AuthorizeManager.isAdmin(context))
        {
            isAdmin = true;
        }
       
        DynamicAnagraficaObjectDTO object = (DynamicAnagraficaObjectDTO)command;       
        // collection of edit tabs (all edit tabs created on system associate to
        // visibility)
        DynamicObjectType typo = getApplicationService().get(DynamicObjectType.class, object.getTipologiaId());
        List<EditTabDynamicObject> tabs = getApplicationService()
                .<BoxDynamicObject, DynamicObjectType, DynamicPropertiesDefinition, TabDynamicObject, EditTabDynamicObject>getEditTabsByVisibilityAndType(EditTabDynamicObject.class, isAdmin, typo);

        // check if request tab from view is active (check on collection before)
        EditTabDynamicObject editT = getApplicationService().get(
                EditTabDynamicObject.class, anagraficaObjectDTO.getTabId());
        if (!tabs.contains(editT))
        {
            throw new AuthorizeException(
                    "You not have needed authorization level to display this tab");
        }

        // collection of boxs
        List<BoxDynamicObject> propertyHolders = new LinkedList<BoxDynamicObject>();

        // if edit tab got a display tab (edit tab is hookup to display tab)
        // then edit box will be created from display box otherwise get all boxs
        // in edit tab
        if (editT.getDisplayTab() != null)
        {
            for (BoxDynamicObject box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), anagraficaObjectDTO.getTabId());
        }

        // clean boxs list with accesslevel
        List<BoxDynamicObject> propertyHoldersCurrentAccessLevel = new LinkedList<BoxDynamicObject>();
        for (BoxDynamicObject propertyHolder : propertyHolders)
View Full Code Here

    @Override
    protected void onBindAndValidate(HttpServletRequest request,
            Object command, BindException errors) throws Exception
    {

        AnagraficaObjectAreaDTO dto = (AnagraficaObjectAreaDTO) command;
        ResearchObject researcher = getApplicationService().get(
                ResearchObject.class, dto.getParentId());
        DynamicAdditionalFieldStorage myObject = researcher.getDynamicField();

        EditTabDynamicObject editT = getApplicationService().get(
                EditTabDynamicObject.class, dto.getTabId());
        List<BoxDynamicObject> propertyHolders = new LinkedList<BoxDynamicObject>();
        if (editT.getDisplayTab() != null)
        {
            for (BoxDynamicObject box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), dto.getTabId());
        }

        List<IContainable> tipProprietaInArea = new LinkedList<IContainable>();

        for (BoxDynamicObject iph : propertyHolders)
View Full Code Here

        // this map contains key-values pairs, key = box shortname and values =
        // collection of metadata
        Map<String, List<IContainable>> mapBoxToContainables = new HashMap<String, List<IContainable>>();

        AnagraficaObjectAreaDTO anagraficaObjectDTO = (AnagraficaObjectAreaDTO) command;

        // check admin authorization
        boolean isAdmin = false;
        Context context = UIUtil.obtainContext(request);
        if (AuthorizeManager.isAdmin(context))
        {
            isAdmin = true;
        }

        // collection of edit tabs (all edit tabs created on system associate to
        // visibility)
        List<EditTabProject> tabs = getApplicationService()
                .getTabsByVisibility(EditTabProject.class, isAdmin);

        // check if request tab from view is active (check on collection before)
        EditTabProject editT = getApplicationService().get(
                EditTabProject.class, anagraficaObjectDTO.getTabId());
        if (!tabs.contains(editT))
        {
            throw new AuthorizeException(
                    "You not have needed authorization level to display this tab");
        }

        // collection of boxs
        List<BoxProject> propertyHolders = new LinkedList<BoxProject>();

        // if edit tab got a display tab (edit tab is hookup to display tab)
        // then edit box will be created from display box otherwise get all boxs
        // in edit tab
        if (editT.getDisplayTab() != null)
        {
            for (BoxProject box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), anagraficaObjectDTO.getTabId());
        }

        // clean boxs list with accesslevel
        List<BoxProject> propertyHoldersCurrentAccessLevel = new LinkedList<BoxProject>();
        for (BoxProject propertyHolder : propertyHolders)
View Full Code Here

    @Override
    protected void onBindAndValidate(HttpServletRequest request,
            Object command, BindException errors) throws Exception
    {

        AnagraficaObjectAreaDTO dto = (AnagraficaObjectAreaDTO) command;
        Project researcher = getApplicationService().get(Project.class,
                dto.getParentId());
        ProjectAdditionalFieldStorage myObject = researcher.getDynamicField();

        EditTabProject editT = getApplicationService().get(
                EditTabProject.class, dto.getTabId());
        List<BoxProject> propertyHolders = new LinkedList<BoxProject>();
        if (editT.getDisplayTab() != null)
        {
            for (BoxProject box : editT.getDisplayTab().getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), dto.getTabId());
        }

        List<IContainable> tipProprietaInArea = new LinkedList<IContainable>();

        for (BoxProject iph : propertyHolders)
View Full Code Here

        // this map contains key-values pairs, key = box shortname and values =
        // collection of metadata
        Map<String, List<IContainable>> mapBoxToContainables = new HashMap<String, List<IContainable>>();

        AnagraficaObjectAreaDTO anagraficaObjectDTO = (AnagraficaObjectAreaDTO) command;

        // check admin authorization
        boolean isAdmin = false;
        Context context = UIUtil.obtainContext(request);
        if (AuthorizeManager.isAdmin(context))
        {
            isAdmin = true;
        }

        // collection of edit tabs (all edit tabs created on system associate to
        // visibility)
        List<EditTabResearcherPage> tabs = getApplicationService()
                .getTabsByVisibility(EditTabResearcherPage.class,
                        isAdmin);

        // check if request tab from view is active (check on collection before)
        EditTabResearcherPage editT = getApplicationService().get(
                EditTabResearcherPage.class,
                anagraficaObjectDTO.getTabId());
        if (!tabs.contains(editT))
        {
            throw new AuthorizeException(
                    "You not have needed authorization level to display this tab");
        }

        // collection of boxs
        List<BoxResearcherPage> propertyHolders = new LinkedList<BoxResearcherPage>();

        // if edit tab got a display tab (edit tab is hookup to display tab)
        // then edit box will be created from display box otherwise get all boxs
        // in edit tab
        if (editT.getDisplayTab() != null)
        {
            for (BoxResearcherPage box : editT.getDisplayTab()
                    .getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), anagraficaObjectDTO.getTabId());
        }

        // clean boxs list with accesslevel
        List<BoxResearcherPage> propertyHoldersCurrentAccessLevel = new LinkedList<BoxResearcherPage>();
        for (BoxResearcherPage propertyHolder : propertyHolders)
View Full Code Here

    @Override
    protected void onBindAndValidate(HttpServletRequest request,
            Object command, BindException errors) throws Exception
    {

        AnagraficaObjectAreaDTO dto = (AnagraficaObjectAreaDTO) command;
        ResearcherPage researcher = getApplicationService().get(
                ResearcherPage.class, dto.getParentId());
        RPAdditionalFieldStorage myObject = researcher.getDynamicField();

        EditTabResearcherPage editT = getApplicationService().get(
                EditTabResearcherPage.class, dto.getTabId());
        List<BoxResearcherPage> propertyHolders = new LinkedList<BoxResearcherPage>();
        if (editT.getDisplayTab() != null)
        {
            for (BoxResearcherPage box : editT.getDisplayTab()
                    .getMask())
            {
                propertyHolders.add(box);
            }
        }
        else
        {
            propertyHolders = getApplicationService().findPropertyHolderInTab(
                    getClazzTab(), dto.getTabId());
        }

        List<IContainable> tipProprietaInArea = new LinkedList<IContainable>();

        for (BoxResearcherPage iph : propertyHolders)
View Full Code Here

TOP

Related Classes of it.cilea.osd.jdyna.dto.AnagraficaObjectAreaDTO

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.