portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hugh Brien" <hugh.br...@novuscg.com>
Subject RE: ADD/REMOVE tab/entry TO ALL users PSML at once
Date Fri, 18 Oct 2002 00:52:32 GMT
How about something like this in the JetspeedTool code for getPane(String name).  This adds
the Group VMI88  as a new Menu Item or tab.  It does not appear user customizes.

Need to specify a DEFAULT_GROUP  and store it in the User/Session.  One could also grab a
couple of other
references to other Portlets using the PortletToolkit and add them also.  If I am way here
could someone point it out. 

 public ConcreteElement getPane(String name)
    {
        ConcreteElement result = null;
        String msg = "";
        if (null != rundata)
        {
            Profile profile = rundata.getProfile();
                if (null == profile)
                {
                    profile = Profiler.getProfile(rundata);
                    if (profile == null)
                    {
                        throw new ProfileException("Profile not found.");
                    }
                    rundata.setProfile(profile);
                }
            
                if ((name == null) ||  Profiler.DEFAULT_PROFILE.equals(name) || "".equals(name))
                    ;
                else
                    profile.setName(name);
     
>>                PSMLDocument doc = profile.getDocument();
>>                Portlets docPortlets = doc.getPortlets();
>>                if(rundata.getUser().hasLoggedIn())
>>    	    {            
>>                	// Need to get a DEFAULT_GROUP from the Session instead of this hard
code. 
>>		Portlets groupPortlets = PortalToolkit.getReference("/group/VMI88/page/default.psml/media-type/html");
       
>>                	groupPortlets.setTitle("GroupPortlets");
>>	            docPortlets.addPortlets(groupPortlets);
                }

                if (null != doc)
                {
>>                   result = PortalToolkit.getSet(docPortlets).getContent(rundata);
                }
   

r,
Hugh








    



-----Original Message-----
From: David Sean Taylor [mailto:david@bluesunrise.com]
Sent: Thursday, October 17, 2002 12:15 PM
To: Jetspeed Developers List
Subject: RE: ADD/REMOVE tab/entry TO ALL users PSML at once




> -----Original Message-----
> From: Luta, Raphael (VUN) [mailto:Raphael.Luta@groupvu.Com]
> Sent: Thursday, October 17, 2002 9:00 AM
> To: 'Jetspeed Developers List'
> Subject: RE: ADD/REMOVE tab/entry TO ALL users PSML at once
>
>
> How about this:
>
> If you have this type of requirements, you probably don't want
> your user to
> have full control over his portal space.
>
> If this is true, then you should be able security restrictions to
> allow the
> user to customize only *some*
> elemnts of his portal page:
>
> - Set the top level PSML <portlets> element with a security level of
> "admin". This should ensure that no user can
>   edit their top level panes in the page root.
>
> - Define your tabs in your root page by using refs to other
> "template" pages
> for which the user has no customization rights
>   (ex: a "company" pane, then a "department" pane, then a "My
> Boss" pane and
> finally a "My Pane" one)

docs on psml refs:

http://jakarta.apache.org/jetspeed/site/psml.html

Recommend  using the RegistryAccessController service, where you can define
your security constraints

http://jakarta.apache.org/jetspeed/site/security.html#Registry%20Access%20Co
ntrol

>   Only the "My Pane" pane defintion would be actually physically defined
> within the user PSML with a security setting allowing
>   the user to manipulate and customize his own pane.
>
> I've not actually tested it out and I can't right now but I don't see any
> reason why it should not work (except bugs, of course :)
>
> Would that fit your need ?
>
>
>
> > -----Message d'origine-----
> > De : mmosttler@yci.com [mailto:mmosttler@yci.com]
> > Envoyé : jeudi 17 octobre 2002 17:24
> > A : jetspeed-dev@jakarta.apache.org
> > Objet : RE: ADD/REMOVE tab/entry TO ALL users PSML at once
> >
> >
> > It sounds easy, but how are you going to add the Group PSML
> > to the User
> > PSML?  How do you know where in the PSML to do the add?  Are
> > you enforcing a
> > standard that would allow you to merge the 2?
> >
> > -----Original Message-----
> > From: Hugh Brien [mailto:hugh.brien@novuscg.com]
> > Sent: Thursday, October 17, 2002 7:49 AM
> > To: Jetspeed Users List
> > Cc: jetspeed-dev@jakarta.apache.org
> > Subject: RE: ADD/REMOVE tab/entry TO ALL users PSML at once
> >
> >
> > We are working on this right now.  We are going to try the following:
> >
> > 1. We have defined a default Group for each user and save
> > that value in the
> > session.  We have an business rule that determines default group.
> > 2. We plan on adding functionality that will append the
> > Group's portlets the
> > PortletSet for the user.
> > 3. It's a simple thing to do it's just finding the right
> > place to put the
> > code. I think it's actually at the Profile level.  Where the
> > Portlets class
> > is passed to the PortletFactory to return a PortletSet
> >
> > r,
> > Hugh
> >
> >
> >
> > -----Original Message-----
> > From: Marian Skalsky [mailto:ms@euromove.sk]
> > Sent: Thursday, October 17, 2002 3:56 AM
> > To: jetspeed-user@jakarta.apache.org
> > Subject: ADD/REMOVE tab/entry TO ALL users PSML at once
> >
> >
> > Hi there!
> >
> > We have JetSpeed used in our company intranet and I have made
> > a default user
> > XXX and all new users when created get his psml.
> > This is fine. But my boss wants to be able to add a TAB in
> > the menu to all
> > users when he decides. Other way said, he wants to login to
> > his account and
> > then add something.. and this should appear in every users
> > home (PSML).
> > Is there a some way how to add something (e.g. TAB item in
> > the menu) to all
> > users PSMLs or how to share a part of PSML by all users, that
> > may be then
> > changed anytime?
> > Or how would you solve this?
> >
> > Any suggestion will be very appreciated.
> > Thank you.
> > $kala.
> >
> >
> > ---
> > Odchádzajúca správa neobsahuje vírusy.
> > Skontrolované antivírusovým systémom AVG (http://www.grisoft.cz).
> > Verzia: 6.0.401 / Vírusová databáza: 226 - dátum vydania: 11. 10. 2002
> >
> > --
> > To unsubscribe, e-mail:
> > <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> > <mailto:jetspeed-dev-help@jakarta.apache.org>
> >
> > --
> > To unsubscribe, e-mail:
> > <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
> > For additional commands, e-mail:
> > <mailto:jetspeed-dev-help@jakarta.apache.org>
> >
>
> --
> To unsubscribe, e-mail:
<mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail:
<mailto:jetspeed-dev-help@jakarta.apache.org>



--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message