[jira] Created: (OFBIZ-3625) Adding a portal-page widget

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
18 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
Adding a portal-page widget
---------------------------

                 Key: OFBIZ-3625
                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
             Project: OFBiz
          Issue Type: New Feature
          Components: framework
            Reporter: Bruno Busco
         Attachments: portalPageWidget.patch

Hi,
sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
This would allow a greater integration of the portal/portlet system in every OFBiz screen.
I have done some work on it following how other widgets have been implemented.

I am not a java expert and I have difficulties to step further.
I would like you java gurus to give a look to it and please help in finalizing it.

With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
This is only a test page.

From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
-----------------------------------------------------------------------------------------------------------------
  <#if screenName?has_content>
    <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
    <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
    <div id="${portletIndex}" name="portalPortlet" class="noClass">
      ${setRequestAttribute("portalPageId", portalPageId)}
      ${setRequestAttribute("portalPortletId", portalPortletId)}
      ${setRequestAttribute("portletSeqId", portletSeqId)}
      ${screens.render(screenLocation, screenName)}
      ${screens.setRenderFormUniqueSeq(portletIndex)}
    </div>
    <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
    <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
    <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
    <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
    <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
  </#if>
-----------------------------------------------------------------------------------------------------------------

Thank you for any collaboration to step this to the trunk.

-Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: portalPageWidget.patch

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: ofbiz.log

This is the log file I get when the https://localhost:8443/example/control/FindExample page is hit.



> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12851735#action_12851735 ]

Bruno Busco commented on OFBIZ-3625:
------------------------------------

What is stopping me here is that it seems not possible to use, in macros that are defined in the htmlScreenMacroLibrary.ftl file, things like <@ofbizUrl> or ${setRequestAttribute("portalPageId", portalPageId)}.

I tryed to include a ${context} in any other macro (i.e. <#macro renderScreenBegin>) and got Expression context is undefined on line...  error.

Any pointer on how to fix this?

Many thanks,
Bruno

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: portalPageWidget.patch

Hi,
I have completed the implementation but still need help :-(
In the updated patch there is the implementation of a "include-portal-page" widget.

This can be used as:
<include-portal-page id="PartyProfile"/>

so that a PortalPage can be simply added in any screen.

At a later stage the following syntax will also be available:
<include-portal-page id="PartyProfile" edit-mode="true"/>

So that the Portal page will show all controls to be edited.

The patch is working if applied in trunk rev. 935330 (where I developed it) but when I tryed to update to the latest trunk I was not able to manage the Widget factory update recently done.

Could please someone (Adrian ?) give a look and help?

Thank you.



> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: portalPageWidget.patch

Missed ASF inclusion licence flag

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment:     (was: portalPageWidget.patch)

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: portalPageWidget.patch

Hi guys,
I got it. Now the patch works on the latest trunk.
Could you please review so that if there are not objections I can commit?

Once committed we could slightly move all Portals from the showPortalPage.ftl method to the include-portla-page one.
I have added a menu item in the example menu that simply call a screen where a PortalPage is rendered using the include-portal-page.

Thank you,
Bruno

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco updated OFBIZ-3625:
-------------------------------

    Attachment: portalPageWidget.patch

Patch improved.
- Added missing portlets sorting to have the correct portlet sequence in the column
- Fixed the column width markup rendering
- Rewritten the Catalog and SFA main screens using the <include-portal-page> widget. Each one of those screens are now PortalPages. All the included screens have been deined as portlets and included in the PortalPages so that the main screens look as the original one.



> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12908572#action_12908572 ]

Hans Bakker commented on OFBIZ-3625:
------------------------------------

With this change, do existing portlets still work?

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12908617#action_12908617 ]

Bruno Busco commented on OFBIZ-3625:
------------------------------------

Hi Hans,
the patch does not touch the actual portlet system but adds a new <include-portal-page> tag that can be used.
Once committed we will eliminate redundant code and move definitively to the new pattern.

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12910465#action_12910465 ]

Bruno Busco commented on OFBIZ-3625:
------------------------------------

Hi guys,
I think I will commit this patch during this week end.
Please, comment if you have something against it.

Thank you,
Bruno

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12910499#action_12910499 ]

BJ Freeman commented on OFBIZ-3625:
-----------------------------------

as always keep in mind the production servers that may have added portlet code when you start the definitive move to the new style.

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12910916#action_12910916 ]

Nicolas Malin commented on OFBIZ-3625:
--------------------------------------

Hi review the patch, I like it Bruno :) . Use generic  <include-portal-page> as <include-screen> it's a good idea.

Just remark on code organization, why don't create a directory portal in framework/widget/src/org/ofbiz/widget to put all Portal*.java file ? As menu, from, and tree.

I have in my todo list to continue your work and add others generic call on form widget to call or refresh portlet  but it's an other issue

Tks for your works Bruno
Nicolas

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12910922#action_12910922 ]

Bruno Busco commented on OFBIZ-3625:
------------------------------------

Hi Nicolas,
thank you for your review.
Creating a portalPage widget was something David suggested from the beginning of the portlet system design.
And now time has come! ;-)

I have stepped further with this implementation but I did not find the time to update the patch.
Unfortunately the portlet system has been complicated in the last time introducing elements with a bad design (IMO).

For example a lot of duplicated requests has been added and a strange paginate-target="AddPortlet${Adm}" pattern has been used.
The correct way for doing this would have been IMO using the alt-target tag.

This is requesting a bigger effort to finish my task.

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12911003#action_12911003 ]

Jacques Le Roux commented on OFBIZ-3625:
----------------------------------------

It looks good to me. Beware there are few tabs in MacroScreenRenderer.java

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

    [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12911067#action_12911067 ]

Bruno Busco commented on OFBIZ-3625:
------------------------------------

Thank you Jacques. I have removed them.

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-3625) Adding a portal-page widget

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-3625?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Bruno Busco closed OFBIZ-3625.
------------------------------

    Resolution: Fixed

Committed in trunk at revision 998570

> Adding a portal-page widget
> ---------------------------
>
>                 Key: OFBIZ-3625
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3625
>             Project: OFBiz
>          Issue Type: New Feature
>          Components: framework
>            Reporter: Bruno Busco
>         Attachments: ofbiz.log, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch, portalPageWidget.patch
>
>
> Hi,
> sometime ago we discussed about the opportunity to have the portalPage implemented as a widget.
> This would allow a greater integration of the portal/portlet system in every OFBiz screen.
> I have done some work on it following how other widgets have been implemented.
> I am not a java expert and I have difficulties to step further.
> I would like you java gurus to give a look to it and please help in finalizing it.
> With the actual patch a  <portal-page id="EXAMPLE" /> is added at the bottom of the https://localhost:8443/example/control/FindExample page.
> This is only a test page.
> From the error I get it seems that it is not possible to render the following ftl in the htmlScreenMacroLibrary.ftl
> -----------------------------------------------------------------------------------------------------------------
>   <#if screenName?has_content>
>     <#assign portletFields = '<input name="portalPageId" value="' + portalPageId + '" type="hidden"/><input name="portalPortletId" value="' + portalPortletId + '" type="hidden"/><input name="portletSeqId" value="' + portletSeqId  + '" type="hidden"/>'>
>     <form method="post" action="movePortletToPortalPage" name="movePP_${portletIndex}">${portletFields}<input name="newPortalPageId" value="${portalPageId}" type="hidden"/></form>
>     <div id="${portletIndex}" name="portalPortlet" class="noClass">
>       ${setRequestAttribute("portalPageId", portalPageId)}
>       ${setRequestAttribute("portalPortletId", portalPortletId)}
>       ${setRequestAttribute("portletSeqId", portletSeqId)}
>       ${screens.render(screenLocation, screenName)}
>       ${screens.setRenderFormUniqueSeq(portletIndex)}
>     </div>
>     <#-- DragNDrop is only activated, when the portal Page isn't the Default page -->
>     <#if originalPortalPageId?has_content><script>setMousePointer("${portletIndex}")</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDragable("${portletIndex}");</script></#if>
>     <#if originalPortalPageId?has_content><script type="text/javascript">makeDroppable("${portletIndex}");</script></#if>
>     <form method="post" action="<@ofbizUrl>updatePortalPagePortletAjax</@ofbizUrl>" name="freeMove_${portletIndex}">${portletFields}<input name="columnSeqId" value="${columnSeqId}" type="hidden"/><input name="mode" value="RIGHT" type="hidden"/></form>
>   </#if>
> -----------------------------------------------------------------------------------------------------------------
> Thank you for any collaboration to step this to the trunk.
> -Bruno

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.