Users - Jpublish to Screens

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

Users - Jpublish to Screens

cjhowe
If you're using the widgets at their current potential
and simplying your .ftl for reuse, there really
shouldn't be a need to use screen.render.  That
command appears to have been made for a quick/simple
transition from pages.get.  Most of the time, if a
screen.render is used inside a list iterator, you
would probably benefit by using the form widget(of
course conceeding to some current style limitations
which is more likely to see improvement over non
declaration ftl includes) and excluding another ftl
altogether.  If a screen.render is used outside of a
list iterator, then you might benefit from breaking up
your ftl for reuse anyway.

========== BJ Freeman wrote:

Just a thought. Then declaration would make it
difficult to use
components in other modules.
In my stuff, I call screens in other modules, but for
the most part to
use my own.

tibor katelbach sent the following on 3/13/06 3:56 AM:
> Thanks for the answer Jacopo
> any idea if this will be implemented in a future
release?
> Thx
> Tibor
>
> On 3/13/06, Jacopo Cappellato <tiz at sastau.it>
wrote:
>
>>Hi Tibor,
>>
>>yes I think that (at the moment) this is the only
way to implement 'ftl
>>includes'.
>>
>>Jacopo
>>
>>tibor katelbach wrote:
>>
>>>Hi
>>>I'm transforming our Jpublish Structure into
Screens
>>>one thing that was quite simple that now seems a
bit heavy to me, if I'm
>>>not mistaken when I want to include a simple ftl
into my page.

>>>
>>>Before I'd just have to do this
>>>${pages.get("/templates/navg1-img.ftl")}
>>>
>>>where as now I have to
>>>${screens.render
>>
>>("component://myapp/widget/CommonScreens.xml#navg1-img")}
>>
>>>and declare my nav1-img as a screen
>>><screen>....</screen>
>>>
>>>isn't there a way to go directly to the ftl without
passing through a

>>>declaration?
>>>
>>>maybe something like this
>>>${screens.render("/templates/navg1-img.ftl")}
>>>
>>>Thanks for the help
>>>Tibor
>>>
>>>
>>>------------------------------------------------------------------------
>>>
>>>
>>>_______________________________________________
>>>Users mailing list
>>>Users at lists.ofbiz.org
>>>http://lists.ofbiz.org/mailman/listinfo/users
>>
>>
>>_______________________________________________
>>Users mailing list
>>Users at lists.ofbiz.org
>>http://lists.ofbiz.org/mailman/listinfo/users
>>
>
>
>
>
------------------------------------------------------------------------
>
>  
> _______________________________________________
> Users mailing list
> Users at lists.ofbiz.org
> http://lists.ofbiz.org/mailman/listinfo/users

 
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Users - Jpublish to Screens

oceatoon
Hi Chris

Please tell me if I understood this properly:
you say that I should do my page declaration as a combination of widgets, widget-includes, decorators, instead of inserting bits of pages (ftl) into a base ftl ?

I think I'm not mistaken if I say that this is probably the main difference between jpublish and screens: there's an external construction of the page. some things were so practical though that I wished they were still around.

It sounds like a nice idea but in practise is a lot of effort and cutting up than the usual template engine approach. where pages are built with combinations of includes inside the final template (JPublish). Here the construction is external and in my use case produces more declarations than code itself.

I'm still very new to screens but It seems at first use that SOC has been a bit mixed up (Mixing declarations of BSH, conditions and declartion of ftl's) .
or is this one new separation I'm just not used to yet ?
I'm interested in hearing users experience with the screen-widget compared to the jpublish ?

Thanks for your thoughts
Regards
Tibor

If you're using the widgets at their current potential
and simplying your .ftl for reuse, there really
shouldn't be a need to use screen.render.  That
command appears to have been made for a quick/simple
transition from pages.get.  Most of the time, if a
screen.render is used inside a list iterator, you
would probably benefit by using the form widget(of
course conceeding to some current style limitations
which is more likely to see improvement over non
declaration ftl includes) and excluding another ftl
altogether.  If a screen.render is used outside of a
list iterator, then you might benefit from breaking up
your ftl for reuse anyway.

========== BJ Freeman wrote:

Just a thought. Then declaration would make it
difficult to use
components in other modules.
In my stuff, I call screens in other modules, but for
the most part to
use my own.

tibor katelbach sent the following on 3/13/06 3:56 AM:
> Thanks for the answer Jacopo
> any idea if this will be implemented in a future
release?
> Thx
> Tibor
>
> On 3/13/06, Jacopo Cappellato <tiz at sastau.it >
wrote:
>
>>Hi Tibor,
>>
>>yes I think that (at the moment) this is the only
way to implement 'ftl
>>includes'.
>>
>>Jacopo
>>
>>tibor katelbach wrote:
>>
>>>Hi
>>>I'm transforming our Jpublish Structure into
Screens
>>>one thing that was quite simple that now seems a
bit heavy to me, if I'm
>>>not mistaken when I want to include a simple ftl
into my page.

>>>
>>>Before I'd just have to do this
>>>${pages.get("/templates/navg1-img.ftl")}
>>>
>>>where as now I have to
>>>${screens.render
>>
>>("component://myapp/widget/CommonScreens.xml#navg1-img")}
>>
>>>and declare my nav1-img as a screen
>>><screen>....</screen>
>>>
>>>isn't there a way to go directly to the ftl without
passing through a

>>>declaration?
>>>
>>>maybe something like this
>>>${screens.render("/templates/navg1- img.ftl")}
>>>
>>>Thanks for the help
>>>Tibor
>>>
>>>
>>>------------------------------------------------------------------------
>>>
>>>
>>>_______________________________________________
>>>Users mailing list
>>>Users at lists.ofbiz.org
>>> http://lists.ofbiz.org/mailman/listinfo/users
>>
>>
>>_______________________________________________
>>Users mailing list
>>Users at lists.ofbiz.org
>>http://lists.ofbiz.org/mailman/listinfo/users
>>
>
>
>
>
------------------------------------------------------------------------
>
>
> _______________________________________________
> Users mailing list
> Users at lists.ofbiz.org
> http://lists.ofbiz.org/mailman/listinfo/users


_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users


 
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Users - Jpublish to Screens

Andrew Sykes
Tibor,

There is a simpler way, but it involves using the content module.

You can define your ftl's as Content and then use...
<@renderSubContentCache subContentId="contentId" />

Andrew

On Mon, 2006-03-13 at 17:07 +0100, tibor katelbach wrote:

> Hi Chris
>
> Please tell me if I understood this properly:
> you say that I should do my page declaration as a combination of
> widgets, widget-includes, decorators, instead of inserting bits of
> pages (ftl) into a base ftl ?
>
> I think I'm not mistaken if I say that this is probably the main
> difference between jpublish and screens: there's an external
> construction of the page. some things were so practical though that I
> wished they were still around.
>
> It sounds like a nice idea but in practise is a lot of effort and
> cutting up than the usual template engine approach. where pages are
> built with combinations of includes inside the final template
> (JPublish). Here the construction is external and in my use case
> produces more declarations than code itself.
>
> I'm still very new to screens but It seems at first use that SOC has
> been a bit mixed up (Mixing declarations of BSH, conditions and
> declartion of ftl's) .
> or is this one new separation I'm just not used to yet ?
> I'm interested in hearing users experience with the screen-widget
> compared to the jpublish ?
>
> Thanks for your thoughts
> Regards
> Tibor
>
>         If you're using the widgets at their current potential
>         and simplying your .ftl for reuse, there really
>         shouldn't be a need to use screen.render.  That
>         command appears to have been made for a quick/simple
>         transition from pages.get.  Most of the time, if a
>         screen.render is used inside a list iterator, you
>         would probably benefit by using the form widget(of
>         course conceeding to some current style limitations
>         which is more likely to see improvement over non
>         declaration ftl includes) and excluding another ftl
>         altogether.  If a screen.render is used outside of a
>         list iterator, then you might benefit from breaking up
>         your ftl for reuse anyway.
>        
>         ========== BJ Freeman wrote:
>        
>         Just a thought. Then declaration would make it
>         difficult to use
>         components in other modules.
>         In my stuff, I call screens in other modules, but for
>         the most part to
>         use my own.
>        
>         tibor katelbach sent the following on 3/13/06 3:56 AM:
>         > Thanks for the answer Jacopo
>         > any idea if this will be implemented in a future
>         release?
>         > Thx
>         > Tibor
>         >
>         > On 3/13/06, Jacopo Cappellato <tiz at sastau.it>
>         wrote:
>         >
>         >>Hi Tibor,
>         >>
>         >>yes I think that (at the moment) this is the only
>         way to implement 'ftl
>         >>includes'.
>         >>
>         >>Jacopo
>         >>
>         >>tibor katelbach wrote:
>         >>
>         >>>Hi
>         >>>I'm transforming our Jpublish Structure into
>         Screens
>         >>>one thing that was quite simple that now seems a
>         bit heavy to me, if I'm
>         >>>not mistaken when I want to include a simple ftl
>         into my page.
>         >>>
>         >>>Before I'd just have to do this
>         >>>${pages.get("/templates/navg1-img.ftl")}
>         >>>
>         >>>where as now I have to
>         >>>${screens.render
>         >>
>         >>("component://myapp/widget/CommonScreens.xml#navg1-img")}
>         >>
>         >>>and declare my nav1-img as a screen
>         >>><screen>....</screen>
>         >>>
>         >>>isn't there a way to go directly to the ftl without
>         passing through a
>         >>>declaration?
>         >>>
>         >>>maybe something like this
>         >>>${screens.render("/templates/navg1- img.ftl")}
>         >>>
>         >>>Thanks for the help
>         >>>Tibor
>         >>>
>         >>>
>         >>>------------------------------------------------------------------------
>         >>>
>         >>>
>         >>>_______________________________________________
>         >>>Users mailing list
>         >>>Users at lists.ofbiz.org
>         >>>http://lists.ofbiz.org/mailman/listinfo/users
>         >>
>         >>
>         >>_______________________________________________
>         >>Users mailing list
>         >>Users at lists.ofbiz.org
>         >>http://lists.ofbiz.org/mailman/listinfo/users
>         >>
>         >
>         >
>         >
>         >
>         ------------------------------------------------------------------------
>         >
>         >
>         > _______________________________________________
>         > Users mailing list
>         > Users at lists.ofbiz.org
>         > http://lists.ofbiz.org/mailman/listinfo/users
>        
>        
>         _______________________________________________
>         Users mailing list
>         [hidden email]
>         http://lists.ofbiz.org/mailman/listinfo/users
>
>  _______________________________________________
> Users mailing list
> [hidden email]
> http://lists.ofbiz.org/mailman/listinfo/users
--
Kind Regards
Andrew Sykes <[hidden email]>
Sykes Development Ltd
http://www.sykesdevelopment.com

 
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Users - Jpublish to Screens

oceatoon
that's a nice one

it's interesting for a functionality I was intending to develop, I was thinking of using the content but didn't know how and you just validated it... I suspect you reading my mind ;-)
Thanks for that.
Is that technique internationalable (i18n) with the data ressource system and associate locale ?

To get back to this inital post subject declaring a content is just as heavy (if not more) as having to declare a screen for any mutualised snippet.

Regards
Tibor


On 3/13/06, Andrew Sykes <[hidden email]> wrote:
Tibor,

There is a simpler way, but it involves using the content module.

You can define your ftl's as Content and then use...
<@renderSubContentCache subContentId="contentId" />

Andrew

On Mon, 2006-03-13 at 17:07 +0100, tibor katelbach wrote:

> Hi Chris
>
> Please tell me if I understood this properly:
> you say that I should do my page declaration as a combination of
> widgets, widget-includes, decorators, instead of inserting bits of
> pages (ftl) into a base ftl ?
>
> I think I'm not mistaken if I say that this is probably the main
> difference between jpublish and screens: there's an external
> construction of the page. some things were so practical though that I
> wished they were still around.
>
> It sounds like a nice idea but in practise is a lot of effort and
> cutting up than the usual template engine approach. where pages are
> built with combinations of includes inside the final template
> (JPublish). Here the construction is external and in my use case
> produces more declarations than code itself.

>
> I'm still very new to screens but It seems at first use that SOC has
> been a bit mixed up (Mixing declarations of BSH, conditions and
> declartion of ftl's) .
> or is this one new separation I'm just not used to yet ?
> I'm interested in hearing users experience with the screen-widget
> compared to the jpublish ?
>
> Thanks for your thoughts
> Regards
> Tibor
>
>         If you're using the widgets at their current potential
>         and simplying your .ftl for reuse, there really
>         shouldn't be a need to use screen.render.  That
>         command appears to have been made for a quick/simple
>         transition from pages.get.  Most of the time, if a
>         screen.render is used inside a list iterator, you
>         would probably benefit by using the form widget(of
>         course conceeding to some current style limitations
>         which is more likely to see improvement over non
>         declaration ftl includes) and excluding another ftl
>         altogether.  If a screen.render is used outside of a
>         list iterator, then you might benefit from breaking up
>         your ftl for reuse anyway.
>
>         ========== BJ Freeman wrote:
>
>         Just a thought. Then declaration would make it
>         difficult to use
>         components in other modules.
>         In my stuff, I call screens in other modules, but for
>         the most part to
>         use my own.
>
>         tibor katelbach sent the following on 3/13/06 3:56 AM:

>         > Thanks for the answer Jacopo
>         > any idea if this will be implemented in a future
>         release?
>         > Thx
>         > Tibor
>         >
>         > On 3/13/06, Jacopo Cappellato <tiz at sastau.it>
>         wrote:
>         >
>         >>Hi Tibor,
>         >>
>         >>yes I think that (at the moment) this is the only
>         way to implement 'ftl
>         >>includes'.
>         >>
>         >>Jacopo
>         >>
>         >>tibor katelbach wrote:
>         >>
>         >>>Hi
>         >>>I'm transforming our Jpublish Structure into
>         Screens
>         >>>one thing that was quite simple that now seems a
>         bit heavy to me, if I'm
>         >>>not mistaken when I want to include a simple ftl
>         into my page.
>         >>>
>         >>>Before I'd just have to do this
>         >>>${pages.get("/templates/navg1-img.ftl")}
>         >>>
>         >>>where as now I have to
>         >>>${screens.render
>         >>
>         >>("component://myapp/widget/CommonScreens.xml#navg1-img")}
>         >>
>         >>>and declare my nav1-img as a screen
>         >>><screen>....</screen>
>         >>>
>         >>>isn't there a way to go directly to the ftl without
>         passing through a
>         >>>declaration?
>         >>>
>         >>>maybe something like this
>         >>>${screens.render("/templates/navg1- img.ftl")}
>         >>>
>         >>>Thanks for the help
>         >>>Tibor
>         >>>
>         >>>
>         >>>------------------------------------------------------------------------
>         >>>
>         >>>
>         >>>_______________________________________________
>         >>>Users mailing list
>         >>>Users at lists.ofbiz.org
>         >>>http://lists.ofbiz.org/mailman/listinfo/users
>         >>
>         >>
>         >>_______________________________________________
>         >>Users mailing list
>         >>Users at lists.ofbiz.org
>         >>http://lists.ofbiz.org/mailman/listinfo/users
>         >>
>         >
>         >
>         >
>         >
>         ------------------------------------------------------------------------
>         >
>         >
>         > _______________________________________________
>         > Users mailing list
>         > Users at lists.ofbiz.org
>         > http://lists.ofbiz.org/mailman/listinfo/users
>
>
>         _______________________________________________
>         Users mailing list
>         [hidden email]
>         http://lists.ofbiz.org/mailman/listinfo/users
>
>  _______________________________________________
> Users mailing list
> [hidden email]
> http://lists.ofbiz.org/mailman/listinfo/users
--
Kind Regards
Andrew Sykes <[hidden email]>
Sykes Development Ltd
http://www.sykesdevelopment.com


_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users


 
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users
Reply | Threaded
Open this post in threaded view
|

Re: Users - Jpublish to Screens

Andrew Sykes
Tibor,

> Is that technique internationalable (i18n) with the data ressource
> system and associate locale ?

I don't see why not, although I haven't actually tested it.
--
Kind Regards
Andrew Sykes <[hidden email]>
Sykes Development Ltd
http://www.sykesdevelopment.com

 
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users