Re: Replace ftl with html in ofbiz

2016-01-29 Thread hoboy2
>OK this was in 2008 and this person was smart :/ 

Monsieur Jaques... je devine ..

some people are smart :)



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676637.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Replace ftl with html in ofbiz

2016-01-29 Thread Jacques Le Roux

Le 29/01/2016 10:18, Jacques Le Roux a écrit :
I'd not go the JSP way, it's insane when you compare with FTL+Groovy (OFBiz switched from JSP to FTL+BSH 12 years ago, and later from BSH to Groovy 
9 years ago)

I mean better for you to convince them to use FTL+Groovy

Jacques


Re: Replace ftl with html in ofbiz

2016-01-29 Thread Jacques Le Roux

Taher is right.

But if you really can't do otherwise simply let them fill their HTML files (with JS in I read), and when you put them in OFBiz simply rename them FTL, 
et voilà!
I'd not go the JSP way, it's insane when you compare with FTL+Groovy (OFBiz switched from JSP to FTL+BSH 12 years ago, and later from BSH to Groovy 9 
years ago)


Jacques

Le 29/01/2016 09:09, hoboy2 a écrit :

Taher and Julien NICOLAS.

Thanks for the advices.
  it is a task outsourced to a different company.

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676629.html
Sent from the OFBiz - User mailing list archive at Nabble.com.



Re: Replace ftl with html in ofbiz

2016-01-29 Thread Jacques Le Roux
I remember a person who did not know anything about programming but a little about Internet (learned HTML and JS on his own at home) who mastered FTL 
in a week! He really produced creative things, it was amazing!

OK this was in 2008 and this person was smart :/

Jacques

Le 29/01/2016 09:35, Nicolas Malin a écrit :

Damned, the sentence "make life simple" it's difficult to apply some time. And 
some time is all the time :)

Nicolas

Le 29/01/2016 09:09, hoboy2 a écrit :

Taher and Julien NICOLAS.

Thanks for the advices.
  it is a task outsourced to a different company.

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676629.html
Sent from the OFBiz - User mailing list archive at Nabble.com.





Re: Replace ftl with html in ofbiz

2016-01-29 Thread Nicolas Malin
Damned, the sentence "make life simple" it's difficult to apply some 
time. And some time is all the time :)


Nicolas

Le 29/01/2016 09:09, hoboy2 a écrit :

Taher and Julien NICOLAS.

Thanks for the advices.
  it is a task outsourced to a different company.

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676629.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Replace ftl with html in ofbiz

2016-01-29 Thread hoboy2
Taher and Julien NICOLAS.

Thanks for the advices.
 it is a task outsourced to a different company.

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676629.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Replace ftl with html in ofbiz

2016-01-29 Thread Julien NICOLAS

Jean-Luc,

I think you must take a look at what Taher said :

 With that being said you only need to teach your
developer minimal ftl.

He is right, your developpers need to know minimal ftl functions. It's 
not a big deal and with javascript and JQuery, it's powerful in OFBiz !


Julien.

Le 29/01/2016 08:55, hoboy2 a écrit :

Julien NICOLAS

Thanks very much you have answered to my question
Thanks to everybody who have used time and effort to help.



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676627.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Replace ftl with html in ofbiz

2016-01-29 Thread hoboy2
Julien NICOLAS

Thanks very much you have answered to my question
Thanks to everybody who have used time and effort to help.



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676627.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Replace ftl with html in ofbiz

2016-01-29 Thread Taher Alkhateeb
Hi,

You cannot create any dynamic application that talks to your database or
interacts with external systems using pure html, css and Javascript. You
need a templating engine. With that being said you only need to teach your
developer minimal ftl. you just give him/her a list of your defined
variables for each screen and they use it with a simple ${varNameHere} and
sometimes if it is a list of things you use a <#list ...> syntax which is
very simple to learn. That's pretty much all they need to learn to start
using ftl. The rest is all css, html and JavaScript.

Taher Alkhateeb

On Friday, 29 January 2016, hoboy2 > wrote:

> Thanks Taher
>
> We have to create severals new screens for our currents application,
> normally one will just used ftl.
> But the person responsible for ui implementation have told us that they can
> not do this using ftl.
> they are familiar with jquery, javaScript, html.
> So I am trying to find out how to use that ui in ofbiz.
>
>
>
>
> --
> View this message in context:
> http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676623.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>


Re: Replace ftl with html in ofbiz

2016-01-29 Thread Julien NICOLAS

Ok, so I understand.

Just let them create pages with html and just put them in ftl.
You can use the html in the ftl but the power is, if you need something 
available in OFBiz in your html, you can call it from the ftl \o/


If you want to include javascript or jquery files just do it like that 
in the screen :





value="HIBOrderAlertInformation"/>
value="/myapp/images/js/myapp-uxscreens.js" global="true" />



Re: Replace ftl with html in ofbiz

2016-01-29 Thread Nicolas Malin

Hoboy2,

re read the thread, all people said, you can write your html file as 
html file and name it .ftl insteadof .html


Nicolas

Le 29/01/2016 08:44, hoboy2 a écrit :

Thanks Taher

We have to create severals new screens for our currents application,
normally one will just used ftl.
But the person responsible for ui implementation have told us that they can
not do this using ftl.
they are familiar with jquery, javaScript, html.
So I am trying to find out how to use that ui in ofbiz.




--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676623.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Replace ftl with html in ofbiz

2016-01-29 Thread hoboy2
Thanks Taher

We have to create severals new screens for our currents application,
normally one will just used ftl.
But the person responsible for ui implementation have told us that they can
not do this using ftl.
they are familiar with jquery, javaScript, html.
So I am trying to find out how to use that ui in ofbiz.




--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676623.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Replace ftl with html in ofbiz

2016-01-28 Thread Taher Alkhateeb
Hi,

Your question is not very clear to me. why do you want to replace ftl with
jsp or html. Freemarker is just a templating engine like many others that
exist out there including jsp. You do not replace free marker with HTML you
just remove any freemarker tags (i.e. anything that starts with <#...> and
you've got HTML. However you lose the ability to code variables into your
HTML which is the main purpose why a templating language exists.

Perhaps if you clarify exactly what you want with an example then we can
help more

Taher Alkhateeb

On Friday, 29 January 2016, hoboy2  wrote:

> Thanks guys.
> I will like to add little more to what my colleague has written.
> The issue is that we will like to create new screen on the current running
> ofbiz application, we will like to reused the services we have witch are
> groovy and java.
> For the  new screen we will like to use html instead of ftl.
> Can jsp or something else be used ?
>
> Example:
>
> bellow is a portion of fetch_category_sector.ftl.
>
> --
> fetch_category_sector.ftl
>
>  && className?has_content> ${className}">
>   
>
> Category Selection
>
> 
> 
>   <#list allCategories as cat>
>   
>  formaction="<@ofbizUrl>main"
> type="submit">${cat.categoryName}
> <#list allSectors as sec>
>   <#if sec.primaryParentOrgCategoryId ==
> cat.organizationCategoryId>
> main"
> type="submit">${sec.sectorName}
>   
> 
> 
>   
> 
> n
>   
> 
>
> -
> The screen
>
>  
> 
> 
> 
>  map-name="uiLabelMap"
> global="true" />
> 
> 
>  value="${groovy:if(request.getAttribute('setFieldLevelErrors') ==
> 'N')return
> '' else return 'Y';}" />
> 

Re: Replace ftl with html in ofbiz

2016-01-28 Thread hoboy2
Thanks guys.
I will like to add little more to what my colleague has written.
The issue is that we will like to create new screen on the current running
ofbiz application, we will like to reused the services we have witch are
groovy and java.
For the  new screen we will like to use html instead of ftl.
Can jsp or something else be used ?

Example:

bellow is a portion of fetch_category_sector.ftl.
--
fetch_category_sector.ftl

 ${className}">
  

Category Selection



  <#list allCategories as cat>
  
main"
type="submit">${cat.categoryName}
<#list allSectors as sec>
  <#if sec.primaryParentOrgCategoryId == cat.organizationCategoryId>
main"
type="submit">${sec.sectorName} 
  


  

n
  

-
The screen

  














 














-

The question is can I code fetch_category_sector.ftl in html ?
and use it in the testscreen ?

Thanks




--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676620.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Replace ftl with html in ofbiz

2016-01-28 Thread Barou
Thanks guys.
I have an ofbiz application running fine using ftl.
 I want to use the same services(it can be groovy or java) of the that
application to use  html instead of ftl
in screen design.
I was hoping for something like what Pierre did.
so maybe my last option is jsp I am right ?
if ftl is not used.

Thanks





--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594p4676603.html
Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: Replace ftl with html in ofbiz

2016-01-28 Thread Jacques Le Roux

Le 28/01/2016 17:01, gil portenseigne a écrit :

Indeed like Pierre shows, only *.ftl files are supported.


Simply rename the file extension from html to ftl, is that a big deal?

Jacques



So depending on your need, you can use ftl files...

Gil

On 28/01/2016 16:20, gil portenseigne wrote:











Re: Replace ftl with html in ofbiz

2016-01-28 Thread gil portenseigne

Indeed like Pierre shows, only *.ftl files are supported.

So depending on your need, you can use ftl files...

Gil

On 28/01/2016 16:20, gil portenseigne wrote:



location="component://mycomponent/path/to/my/index.html"/>






Re: Replace ftl with html in ofbiz

2016-01-28 Thread Julien NICOLAS

Sorry but this link is not... linked to this subject ;)

Le 28/01/2016 16:33, Julien NICOLAS a écrit :

...new Jira creation ;)




Re: Replace ftl with html in ofbiz

2016-01-28 Thread Julien NICOLAS
Yes, but it could be interesting to understand the needs of Jean-Luc and 
maybe the solution is in OFBiz and not in the new Jira creation 
;)


Le 28/01/2016 16:29, Pierre Smits a écrit :

Feel free to file a JIRA issue pertaining this matter.




Re: Replace ftl with html in ofbiz

2016-01-28 Thread Pierre Smits
Hi,

Incorporation of a html file in a screen, like in:
{code}

















































**












{code}

renders the following result:
{code}
ERROR in error page, (infinite loop or error page not found with name
[/error/error.jsp]), but here is the text just in case it helps you:
org.ofbiz.widget.renderer.ScreenRenderException: Error rendering screen
[component://myshop/widget/CustomerScreens.xml#newcustomer]:
org.ofbiz.widget.renderer.ScreenRenderException: Error rendering screen
[component://myshop/widget/CommonScreens.xml#main-decorator]:
java.lang.IllegalArgumentException: Rendering not yet supported for the
template at location:
component://myshop/templates/customer/newcustomer.html (Rendering not yet
supported for the template at location:
component://myshop/templates/customer/newcustomer.html) (Error rendering
screen [component://myshop/widget/CommonScreens.xml#main-decorator]:
java.lang.IllegalArgumentException: Rendering not yet supported for the
template at location:
component://myshop/templates/customer/newcustomer.html (Rendering not yet
supported for the template at location:
component://myshop/templates/customer/newcustomer.html))
{code}

So, to answer your question completely: it is currently *not* supported.
Feel free to file a JIRA issue pertaining this matter.

Best regards,

Pierre Smits

ORRTIZ.COM <http://www.orrtiz.com>
OFBiz based solutions & services

OFBiz Extensions Marketplace
http://oem.ofbizci.net/oci-2/

On Thu, Jan 28, 2016 at 4:21 PM, Julien NICOLAS 
wrote:

> Hi Jean-Luc,
>
> What is really your need. We need the background of your think and
> understand the reason of your question to find a way to help you.
>
> For example, if you don't want to parse ftl file, you can use <#noparse>
> 
>
> http://freemarker.incubator.apache.org/docs/ref_directive_noparse.html
>
> Julien.
>
> Le 28/01/2016 15:48, hoboy2 a écrit :
>
>> Hi
>>
>> Ok I have partially asked this question before.
>> I have looked into ofbiz doc I can not find an example
>> of where to use html instead of ftl.
>> I will like to use html instead of ftl
>> any link ?
>>
>> Thanks
>>
>>
>>
>> --
>> View this message in context:
>> http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594.html
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
>
>


Re: Replace ftl with html in ofbiz

2016-01-28 Thread Julien NICOLAS

Hi Jean-Luc,

What is really your need. We need the background of your think and 
understand the reason of your question to find a way to help you.


For example, if you don't want to parse ftl file, you can use <#noparse> 



http://freemarker.incubator.apache.org/docs/ref_directive_noparse.html

Julien.

Le 28/01/2016 15:48, hoboy2 a écrit :

Hi

Ok I have partially asked this question before.
I have looked into ofbiz doc I can not find an example
of where to use html instead of ftl.
I will like to use html instead of ftl
any link ?

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Replace ftl with html in ofbiz

2016-01-28 Thread gil portenseigne

Hello,

In OFBiz ftl files contain html, if you read 
http://freemarker.incubator.apache.org/


You'll see that freemarker improve your html content with loop, 
variables, etc.


If you want to use pure static html, it could be done in screens with 
(not tested but i guess it works):



location="component://mycomponent/path/to/my/index.html"/>



Or be done in ftl files directly.

Regards

Gil


On 28/01/2016 15:48, hoboy2 wrote:

Hi

Ok I have partially asked this question before.
I have looked into ofbiz doc I can not find an example
of where to use html instead of ftl.
I will like to use html instead of ftl
any link ?

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Re: Replace ftl with html in ofbiz

2016-01-28 Thread Nicolas Malin

Hi Can you explain more your problem ?

Because if you set only html code in a ftl file, it's work fine.

Nicolas

Le 28/01/2016 15:48, hoboy2 a écrit :

Hi

Ok I have partially asked this question before.
I have looked into ofbiz doc I can not find an example
of where to use html instead of ftl.
I will like to use html instead of ftl
any link ?

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594.html
Sent from the OFBiz - User mailing list archive at Nabble.com.




Replace ftl with html in ofbiz

2016-01-28 Thread hoboy2
Hi

Ok I have partially asked this question before.
I have looked into ofbiz doc I can not find an example 
of where to use html instead of ftl.
I will like to use html instead of ftl 
any link ?

Thanks



--
View this message in context: 
http://ofbiz.135035.n4.nabble.com/Replace-ftl-with-html-in-ofbiz-tp4676594.html
Sent from the OFBiz - User mailing list archive at Nabble.com.