You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by Mark Orciuch <ma...@ngsltd.com> on 2002/08/08 19:26:34 UTC

[PROPOSAL] Portlet preview in the customizer

I would like to propose enhancing the customizer to allow for previewing
portlets before they are selected in the profile. I have a working prototype
in place but there are issues which may need to be discussed. Here's a list
of my issues:

1. Since we will be creating an instance of portlet which is not in the user
profile, we cannot use the peid - we have to create a new instance directly
from the registry. If we assign a static id to the instance, will all users
previewing the portlet be hitting the same instance? I would hope that all
users would be "sharing" the same instance.
2. How to prevent customizing/closing the portlet since it's not in the
profile yet? I guess using the ClearPortletControl would be one way to hide
the action icons but one should be able to use any control for the preview.
Adding a preview mode would be much more involving than my prototype
implementation.
3. How to handle interactive portlets such as the database browser? In my
prototype, this does not work very well.

I have created an enhancement request in Bugzilla for tracking purposes
(http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11565). I will attach all
pertinent patches and new files from my prototype there. Please let me know
if this sounds like a useful feature. I can do the actual implementation
provided that I get some guidance in resolving the above issues. Thanks!

Best regards,

Mark C. Orciuch
Next Generation Solutions, Ltd.
e-Mail: mark_orciuch@ngsltd.com
web: http://www.ngsltd.com


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: [PATCH] Broken PsmlBrowser

Posted by Paul Spencer <pa...@mindspring.com>.
Mark,
I have applied the patch.  

Thank you,
Paul Spencer

Mark Orciuch wrote:

>Here's a patch to fix broken PsmlBrowseAction - try clicking the PSML
>Browser in admin profile with cvs head. I'm not sure why the build didn't
>report a compile error. I won't bother submitting this to Bugzilla.
>
>Best regards,
>
>Mark C. Orciuch
>Next Generation Solutions, Ltd.
>e-Mail: mark_orciuch@ngsltd.com
>web: http://www.ngsltd.com
>  
>
>  
>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


[PATCH] Broken PsmlBrowser

Posted by Mark Orciuch <ma...@ngsltd.com>.
Here's a patch to fix broken PsmlBrowseAction - try clicking the PSML
Browser in admin profile with cvs head. I'm not sure why the build didn't
report a compile error. I won't bother submitting this to Bugzilla.

Best regards,

Mark C. Orciuch
Next Generation Solutions, Ltd.
e-Mail: mark_orciuch@ngsltd.com
web: http://www.ngsltd.com

RE: [PROPOSAL] Portlet preview in the customizer

Posted by David Sean Taylor <da...@bluesunrise.com>.
Makes me wonder about (yet another) mode: Preview.
In this mode, all the resources necessary for the portlet may not be there.
The portlet can then use an alternative method of displaying itself to give
the user an idea of what the portlet would look like. For ex. in a
DatabaseBrowser, you may not have all the connection info, so the
DatabaseBrowser would show the dummy rows of data.

As for the implementation, can't you have a PreviewPortlet, with a generic
role 'user' psml file, doing something like this:

public class PreviewPortlet extends AbstractPortlet
{
    /**
     * @param rundata The RunData object for the current request
     */
    public ConcreteElement getContent( RunData rundata )
    {
        String portletName =
rundata.getParameters().getString("previewedPortletName");
        Portlet portlet;

        try
        {
            portlet = PortletFactory.getPortlet(portletName);,
       }
        catch (Exception e)
        {
            Log.error(e);
            String s =  StringUtils.stackTrace(e);
            return new ClearElement("Error Previewing portlet: " +
portletName + " -- " + s);
        }

        return portlet.getContent(rundata);
    }

I already do this kind of stuff for getting portlets dynamically.
However I think a PreviewPortlet would be a nice addition


> -----Original Message-----
> From: Mark Orciuch [mailto:mark_orciuch@ngsltd.com]
> Sent: Thursday, August 08, 2002 10:27 AM
> To: Jetspeed Developers List
> Subject: [PROPOSAL] Portlet preview in the customizer
>
>
> I would like to propose enhancing the customizer to allow for previewing
> portlets before they are selected in the profile. I have a
> working prototype
> in place but there are issues which may need to be discussed.
> Here's a list
> of my issues:
>
> 1. Since we will be creating an instance of portlet which is not
> in the user
> profile, we cannot use the peid - we have to create a new
> instance directly
> from the registry. If we assign a static id to the instance, will
> all users
> previewing the portlet be hitting the same instance? I would hope that all
> users would be "sharing" the same instance.
> 2. How to prevent customizing/closing the portlet since it's not in the
> profile yet? I guess using the ClearPortletControl would be one
> way to hide
> the action icons but one should be able to use any control for
> the preview.
> Adding a preview mode would be much more involving than my prototype
> implementation.
> 3. How to handle interactive portlets such as the database browser? In my
> prototype, this does not work very well.
>
> I have created an enhancement request in Bugzilla for tracking purposes
> (http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11565). I will
> attach all
> pertinent patches and new files from my prototype there. Please
> let me know
> if this sounds like a useful feature. I can do the actual implementation
> provided that I get some guidance in resolving the above issues. Thanks!
>
> Best regards,
>
> Mark C. Orciuch
> Next Generation Solutions, Ltd.
> e-Mail: mark_orciuch@ngsltd.com
> web: http://www.ngsltd.com
>
>
> --
> To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>