Example usage for com.liferay.portal.kernel.util PortletKeys DOCUMENT_LIBRARY_ADMIN

List of usage examples for com.liferay.portal.kernel.util PortletKeys DOCUMENT_LIBRARY_ADMIN

Introduction

In this page you can find the example usage for com.liferay.portal.kernel.util PortletKeys DOCUMENT_LIBRARY_ADMIN.

Prototype

String DOCUMENT_LIBRARY_ADMIN

To view the source code for com.liferay.portal.kernel.util PortletKeys DOCUMENT_LIBRARY_ADMIN.

Click Source Link

Usage

From source file:blade.document.action.displaycontext.BladeActionDisplayContext.java

License:Apache License

/**
 * Read settings from page Documents And Media portlet "Show Actions" portlet configuration.<br/>
 * But for Documents And Media admin portlet, it will always be true.
 *//*www. j  a  v  a  2s  .  co m*/
private boolean _showAction() throws SettingsException {
    PortletDisplay portletDisplay = _themeDisplay.getPortletDisplay();

    String portletName = portletDisplay.getPortletName();

    if (portletName.equals(PortletKeys.DOCUMENT_LIBRARY_ADMIN)) {
        return true;
    }

    Settings settings = SettingsFactoryUtil
            .getSettings(new PortletInstanceSettingsLocator(_themeDisplay.getLayout(), portletDisplay.getId()));

    TypedSettings typedSettings = new TypedSettings(settings);

    return typedSettings.getBooleanValue("showActions");
}

From source file:com.liferay.document.library.web.internal.dynamic.data.mapping.util.DocumentsAndMediaDDMDisplayTabItem.java

License:Open Source License

@Override
public String getURL(LiferayPortletRequest liferayPortletRequest, LiferayPortletResponse liferayPortletResponse)
        throws Exception {

    PortletURL portletURL = _portal.getControlPanelPortletURL(liferayPortletRequest,
            PortletKeys.DOCUMENT_LIBRARY_ADMIN, PortletRequest.RENDER_PHASE);

    portletURL.setParameter("mvcRenderCommandName", "/document_library/view");

    return portletURL.toString();
}

From source file:com.liferay.document.library.web.internal.dynamic.data.mapping.util.DocumentTypesDDMDisplayTabItem.java

License:Open Source License

@Override
public String getURL(LiferayPortletRequest liferayPortletRequest, LiferayPortletResponse liferayPortletResponse)
        throws Exception {

    PortletURL portletURL = _portal.getControlPanelPortletURL(liferayPortletRequest,
            PortletKeys.DOCUMENT_LIBRARY_ADMIN, PortletRequest.RENDER_PHASE);

    portletURL.setParameter("mvcRenderCommandName", "/document_library/view_file_entry_types");

    return portletURL.toString();
}