You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Ritz123 <ri...@gmail.com> on 2008/02/05 19:44:33 UTC

what does layoutSettings.javascript[+0] mean?

Hi,

Have couple of questions...

1. What does layoutSettings.javascript[+0] mean? 
2. Where is layoutSettings object defined?
3. Is there an alternative to screen widgets which people may have used with
Ofbiz controller (controller.xml)?

Thanks
-- 
View this message in context: http://www.nabble.com/what-does-layoutSettings.javascript-%2B0--mean--tp15296728p15296728.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: what does layoutSettings.javascript[+0] mean?

Posted by Adrian Crum <ad...@hlmksw.com>.
Ritz123 wrote:
> Also, is it possible to use other dynamic content resource (like jsp) inside
> a widget? basically to be able to use ftls in combination with jsps etc.?

OFBiz abandoned JSPs several years ago. Widgets are easier to use. Take another look at what you are 
trying to accomplish to see if JSPs are really necessary.

-Adrian

Re: what does layoutSettings.javascript[+0] mean?

Posted by Ritz123 <ri...@gmail.com>.
Thanks Scott. Perfect. That made sense. 

Couple of more follow up questions - sorry

I see that both <set> and <property-map> tags have global attribute. I
presume declaring global = true would make those variables available to
other screens? also, I think I may have seen a case or two where UiLabelMap
is declared global multiple times when a screen is included within a screen
and both the screens have the same UiLabelMap declared. shouldnt all the
common uilabelmaps be loaded globally first?

Also, is it possible to use other dynamic content resource (like jsp) inside
a widget? basically to be able to use ftls in combination with jsps etc.?



Scott Gray wrote:
> 
> 1.  +0 pushes the entry into position zero rather than replacing the
> current
> entry at zero, so whatever entry is at zero at the moment will end up at
> position 1
> 2.  layoutSettings is defined the first time it is called, there isn't
> anything special about it, it's just a variable like any other.  Because
> there is an entry "javascripts[]" appended to it, the <set> tag knows to
> create a map named "layoutSettings" if one doesn't already exist.  That
> map
> will have an entry named "javascripts" which will be treated as a list
> because of the square brackets.  Make any sense?
> 3.  Can't really comment, I have no experience myself.
> 
> Regards
> Scott
> 
> On 06/02/2008, Ritz123 <ri...@gmail.com> wrote:
>>
>>
>> Hi,
>>
>> Have couple of questions...
>>
>> 1. What does layoutSettings.javascript[+0] mean?
>> 2. Where is layoutSettings object defined?
>> 3. Is there an alternative to screen widgets which people may have used
>> with
>> Ofbiz controller (controller.xml)?
>>
>> Thanks
>> --
>> View this message in context:
>> http://www.nabble.com/what-does-layoutSettings.javascript-%2B0--mean--tp15296728p15296728.html
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/what-does-layoutSettings.javascript-%2B0--mean--tp15296728p15297487.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: what does layoutSettings.javascript[+0] mean?

Posted by Scott Gray <le...@gmail.com>.
1.  +0 pushes the entry into position zero rather than replacing the current
entry at zero, so whatever entry is at zero at the moment will end up at
position 1
2.  layoutSettings is defined the first time it is called, there isn't
anything special about it, it's just a variable like any other.  Because
there is an entry "javascripts[]" appended to it, the <set> tag knows to
create a map named "layoutSettings" if one doesn't already exist.  That map
will have an entry named "javascripts" which will be treated as a list
because of the square brackets.  Make any sense?
3.  Can't really comment, I have no experience myself.

Regards
Scott

On 06/02/2008, Ritz123 <ri...@gmail.com> wrote:
>
>
> Hi,
>
> Have couple of questions...
>
> 1. What does layoutSettings.javascript[+0] mean?
> 2. Where is layoutSettings object defined?
> 3. Is there an alternative to screen widgets which people may have used
> with
> Ofbiz controller (controller.xml)?
>
> Thanks
> --
> View this message in context:
> http://www.nabble.com/what-does-layoutSettings.javascript-%2B0--mean--tp15296728p15296728.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>
>

Re: what does layoutSettings.javascript[+0] mean?

Posted by Adrian Crum <ad...@hlmksw.com>.
layoutSettings is a Map that contains settings to control the page layout. It is typically 
initialized in the widget XML file or a BSH script.

Some of the layoutSettings elements are lists, and the layoutSettings.javascript[+0] syntax 
indicates that something is being added to a list.

-Adrian

Ritz123 wrote:

> Hi,
> 
> Have couple of questions...
> 
> 1. What does layoutSettings.javascript[+0] mean? 
> 2. Where is layoutSettings object defined?
> 3. Is there an alternative to screen widgets which people may have used with
> Ofbiz controller (controller.xml)?
> 
> Thanks