You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ofbiz.apache.org by Deepak Dixit <de...@hotwaxsystems.com> on 2016/03/01 05:14:49 UTC

Re: New Screen css layoutSettings issue

Hi hoboy2,

Could you please share your controller request as well as web-app
definition?

https://cwiki.apache.org/confluence/x/cQFk



Thanks & Regards
--
Deepak Dixit
www.hotwaxsystems.com

On Mon, Feb 29, 2016 at 5:47 PM, hoboy2 <je...@novitek.dk> wrote:

> Thanks very much in advance for any helps.
>
>
> I have followed your advice, still have the problem.
>
> The situation is that I have received an html file called index.html that I
> have renamed to index.ftl
> I am trying to create a screen.xml using the index.html renamed to
> index.ftl
>
>
> ---------------------------------------------------------------------------------------------------------------------
> The head of index.hml is bellow.
>                --------------------
> <title>test</title>
> <meta name="viewport" content="width=device-width, initial-scale=1.0">
> <meta name="description" content="">
> <meta name="author" content="">
>
>
>
>
>
>
> <link href="css/bootstrap.min.css" rel="stylesheet">
> <link href="css/style.css" rel="stylesheet">
>
> <link href="css/font-awesome.css" rel="stylesheet">
>
> <link href="css/font-awesome.min.css" rel="stylesheet">
>
>
>
>
>
> <link rel="apple-touch-icon-precomposed" sizes="144x144"
> href="img/apple-touch-icon-144-precomposed.png">
> <link rel="apple-touch-icon-precomposed" sizes="114x114"
> href="img/apple-touch-icon-114-precomposed.png">
> <link rel="apple-touch-icon-precomposed" sizes="72x72"
> href="img/apple-touch-icon-72-precomposed.png">
> <link rel="apple-touch-icon-precomposed"
> href="img/apple-touch-icon-57-precomposed.png">
> <link rel="shortcut icon" href="img/favicon.png">
>
>
>
> </head>
>
> ----------------------------------------------------------------------------------------------------------------------
>
>
> The screen works but the items images are not found
>
> Bellow is a snap of the div from index.html
>
> ------------------------------------------------------------------------------------------------------------------
> <div class="carousel-inner">
>                 <div class="item  active">
>                   <div class="row">
>                     <div class="col-md-3">  <img class="img-responsive"
> alt="" src="img/1.jpg"> <#>   item title</div>
>                     <div class="col-md-3">  <img alt="" src="img/2.png">
> <#>
> item title </div>
>                     <div class="col-md-3">  <img alt="" src="img/3.png">
> <#>
> item title </div>
>                     <div class="col-md-3">  <img alt="" src="img/4.jpg">
> <#>
> item title</div>
>                   </div>
>                 </div>
>
> ---------------------------------------------------------------------------------------------------------------------
> Bellow is the screen I want to create using the index.html renamed to
> index.ftl.
>
> <?xml version="1.0" encoding="UTF-8"?>
> <screens xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>
> xsi:noNamespaceSchemaLocation="
> http://ofbiz.apache.org/dtds/widget-screen.xsd">
>     <screen name="calis">
>         <section>
>         <actions>
>                 <set field="headerItem" value="test"/>
>
>                 <set field="layoutSettings.javaScripts[]"
> value="/osafe/webapp/osafe/common/test/js/bootstrap.min.js" global="true"
> />
>
>                          <set field="layoutSettings.styleSheets[]"
> value="/osafe/webapp/osafe/common/test/css/cssbootstrap.min.css"
> global="true"/>
>
>
>         <script
>
> location="component://osafe/webapp/osafe/WEB-INF/actions/test/test.groovy"/>
>         </actions>
>         <widgets>
>
>                <decorator-section name="body">
>                     <platform-specific>
>                         <html>
>                             <html-template
> location="component://osafe/webapp/osafe/common/test/index.ftl"/>
>                         </html>
>                     </platform-specific>
>                 </decorator-section>
>
>         </widgets>
>     </section>
>     </screen>
> </screens>
>
>
>
>
>
> --
> View this message in context:
> http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677554.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.
>

Re: New Screen css layoutSettings issue

Posted by hoboy2 <je...@novitek.dk>.
UPS sorry Deepak Dixit my apologies.
Thanks very much for informing about the mistake.



--
View this message in context: http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677576.html
Sent from the OFBiz - User mailing list archive at Nabble.com.

Re: New Screen css layoutSettings issue

Posted by hoboy2 <je...@novitek.dk>.
UPS Julien, my mistake
Thanks,
 merci :)

in advance
---------------------------------------
ofbiz-component.xml

<?xml version="1.0" encoding="UTF-8"?>
<ofbiz-component name="osafe"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/ofbiz-component.xsd">
    
    <resource-loader name="main" type="component"/>

    
    <classpath type="dir" location="config"/>
    <classpath type="dir" location="dtd"/>

    
    <classpath type="jar" location="build/lib/*"/>
    <classpath type="jar" location="lib/*"/>

    
    <entity-resource type="model" reader-name="main" loader="main"
location="entitydef/entitymodel.xml"/>
    <entity-resource type="model" reader-name="main" loader="main"
location="entitydef/entityImportModel.xml"/>
    <entity-resource type="model" reader-name="main" loader="main"
location="entitydef/entitymodel_custom.xml"/>
    <entity-resource type="group" reader-name="main" loader="main"
location="entitydef/entitygroup.xml"/>
    

    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceSecurityData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/bigFishTypes.xml"/> 
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceSeedData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommercePaymentCustomMethods.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/clientStoreSeedData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/bigFishContentMenu.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceContentEmailData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceSeedShippingData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceContentSeedData.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/eCommerceShipmentCustomMethods.xml"/>
    
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/01-GeoAssocType.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/02-GeoType.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/100-Geo_Country.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/110-Geo_State.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/120-Geo_Province.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/130-Geo_PostalCode.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/140-Geo_Region.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/150-Geo_Territory.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/160-Geo_Group.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/170-Geo_Zone.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/200-Geo_GB-County.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/201-Geo_Irl-County.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/202-Geo_Nirl-County.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/203-Geo_NY-County.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/204-Geo_Utah-County.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/300-Geo_Assoc_REGIONS.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/310-Geo_Assoc_GroupMember.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/320-Geo_Assoc_UPS_DAS_ZONE.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/330-Geo_Assco_UPS_DAS_EXT_ZONE.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/340-Geo_Assoc_UPS_GRD_ZONE.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/400-Tax_Party.xml"/>
    <entity-resource type="data" reader-name="seed" loader="main"
location="data/seed/ecommerceSeedShippingMethods.xml"/>


    
    <entity-resource type="data" reader-name="demodata" loader="main"
location="data/demo/eCommerceShippingOptions.xml"/>
    <entity-resource type="data" reader-name="demodata" loader="main"
location="data/demo/XProductStoreParm.xml"/>
    <entity-resource type="data" reader-name="demodata" loader="main"
location="data/demo/BigfishContent.xml"/>

    
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/000-ProductCategory.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/010-ProductCategoryFeature.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/020-Manufacturer.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/030-Product.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/040-ProductVariant.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/043-ProductSelectableFeature.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/045-ProductGoodIdentification.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/050-ProductContent.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/055-ProductVariantContent.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/060-ProductDistinguishingFeature.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/065-ProductFeatureImage.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/070-ProductAssoc.xml"/>
    <entity-resource type="data" reader-name="proddata" loader="main"
location="data/demo/075-ProductAttribute.xml"/>

    
    
    <entity-resource type="data" reader-name="customshipmentmethods"
loader="main" location="data/seed/eCommerceShipmentCustomMethods.xml"/>
    
    <entity-resource type="data" reader-name="custompaymentmethods"
loader="main" location="data/seed/eCommercePaymentCustomMethods.xml"/>
    
    <entity-resource type="data" reader-name="gifcardpaymentsettings"
loader="main" location="data/seed/ecommerceGiftCardPaymentSettings.xml"/>
    
    <entity-resource type="data" reader-name="tendercardpaymentsettings"
loader="main" location="data/seed/ecommerceTenderCardPaymentSettings.xml"/>
    
    <entity-resource type="data" reader-name="parameters" loader="main"
location="data/bigFishParameters.xml"/>
    
    <entity-resource type="data" reader-name="contentmenu" loader="main"
location="data/seed/bigFishContentMenu.xml"/>
    
    <entity-resource type="data" reader-name="bigfishtypes" loader="main"
location="data/seed/bigFishTypes.xml"/> 
    
    <entity-resource type="data" reader-name="version" loader="main"
location="data/bigFishParameters.xml"/>
    <entity-resource type="data" reader-name="version" loader="main"
location="data/seed/bigFishTypes.xml"/> 
    <entity-resource type="data" reader-name="version" loader="main"
location="data/seed/bigFishContentMenu.xml"/>

    
    <entity-resource type="data" reader-name="extendedstore" loader="main"
location="data/bigFishExtendedStore.xml"/>
    
    <entity-resource type="data" reader-name="schedulers" loader="main"
location="data/eCommerceBigfishScheduledJobs.xml"/>

    
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/PaymentGatewayConfData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/OfbizSetupSecurityData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/HumanResPortletData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/BiSecurityData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/CommonSystemPropertyData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/GeoData_CA.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/GeoData_PL.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/GeoData_MX.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/ServiceSeedData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/HhFacilitySecurityData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/scrumTypeData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/scrumSecurityData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/scrumHelpData.xml"/>
    <entity-resource type="data" reader-name="ofbizversion12" loader="main"
location="data/migration/r12/MiscData.xml"/>

    
    <service-resource type="model" loader="main"
location="servicedef/services.xml"/>
    <service-resource type="model" loader="main"
location="servicedef/services_paymentmethod.xml"/>
    <service-resource type="model" loader="main"
location="servicedef/services_sagepay.xml"/>
    <service-resource type="model" loader="main"
location="servicedef/services_ebs.xml"/>
    <service-resource type="model" loader="main"
location="servicedef/services_scheduledJobs.xml"/>
    <service-resource type="model" loader="main"
location="servicedef/services_custom.xml"/>
    <service-resource type="eca" loader="main"
location="servicedef/secas.xml"/>
    <service-resource type="eca" loader="main"
location="servicedef/secas_custom.xml"/>

    
    <webapp name="osafe"
        title="BF Ofbiz"
        server="default-server"
        location="webapp/osafe"
        mount-point="/"/>

</ofbiz-component>



--
View this message in context: http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677572.html
Sent from the OFBiz - User mailing list archive at Nabble.com.

Re: New Screen css layoutSettings issue

Posted by Deepak Dixit <de...@hotwaxsystems.com>.
Hi Hoboy2

As per your web-app definition webapp mount point is root "/" and you are
trying to access resources using full path.This will not working.

{code}
                <set field="layoutSettings.javaScripts[]"
value="/osafe/webapp/osafe/common/test/js/bootstrap.min.js" global="true" />
{code}

Suggestion 1:
Please change your mount point from "/" to "/osafe" and access resources
using following pattern:
{code}
                <set field="layoutSettings.javaScripts[]"
value="/osafe/common/test/js/bootstrap.min.js" global="true" />
{code}

Suggestion 2:

Create new web-app for static resources and serve static resources from
this web-app, do not use "/" mount point.

Suggestion 3:

Use only one web-app with root mount point and separate out the
css/js/images request using default servlet:
https://tomcat.apache.org/tomcat-7.0-doc/default-servlet.html



Thanks & Regards
--
Deepak Dixit
www.hotwaxsystems.com

On Wed, Mar 2, 2016 at 2:28 PM, Julien NICOLAS <ju...@nereide.fr>
wrote:

> Sorry, I can't found it in this thread...
>
>
> Le 02/03/2016 09:26, hoboy2 a écrit :
>
>> Hi Deepak Dixit-3
>>
>> I have send ofbiz-component.xml
>>
>> Thanks in advance
>>
>>
>>
>> --
>> View this message in context:
>> http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677570.html
>> Sent from the OFBiz - User mailing list archive at Nabble.com.
>>
>
>

Re: New Screen css layoutSettings issue

Posted by Julien NICOLAS <ju...@nereide.fr>.
Sorry, I can't found it in this thread...

Le 02/03/2016 09:26, hoboy2 a écrit :
> Hi Deepak Dixit-3
>
> I have send ofbiz-component.xml
>
> Thanks in advance
>
>
>
> --
> View this message in context: http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677570.html
> Sent from the OFBiz - User mailing list archive at Nabble.com.


Re: New Screen css layoutSettings issue

Posted by hoboy2 <je...@novitek.dk>.
Hi Deepak Dixit-3

I have send ofbiz-component.xml

Thanks in advance



--
View this message in context: http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677570.html
Sent from the OFBiz - User mailing list archive at Nabble.com.

Re: New Screen css layoutSettings issue

Posted by hoboy2 <je...@novitek.dk>.
Hi Deepack 
Here is my controller.
<?xml version="1.0" encoding="UTF-8"?>
<site-conf xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/site-conf.xsd">
    
    <request-map uri="test">
        <security https="false" auth="false"/>
        <response name="success" type="view" value="test"/>
    </request-map>
   
  
    
    <view-map name="test" type="screen"
page="component://osafe/widget/TestEcommerceScreen.xml#test"/>
</site-conf>

Where is the web-app  located ?

Thanks in advance




--
View this message in context: http://ofbiz.135035.n4.nabble.com/New-Screen-css-layoutSettings-issue-tp4677488p4677557.html
Sent from the OFBiz - User mailing list archive at Nabble.com.