Author: deepak
Date: Fri Dec 15 08:56:27 2017 New Revision: 1818245 URL: http://svn.apache.org/viewvc?rev=1818245&view=rev Log: Improved: Update markup of Home page according to standard markup given by Bootstrap v4.0.0 (OFBIZ-10011) Thanks Parakh and Mayank for your contribution Added: ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl (with props) ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl (with props) ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl (with props) Modified: ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CartScreens.xml ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CatalogScreens.xml ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CommonScreens.xml Added: ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl?rev=1818245&view=auto ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl (added) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl Fri Dec 15 08:56:27 2017 @@ -0,0 +1,91 @@ +<#-- +Licensed to the Apache Software Foundation (ASF) under one +or more contributor license agreements. See the NOTICE file +distributed with this work for additional information +regarding copyright ownership. The ASF licenses this file +to you under the Apache License, Version 2.0 (the +"License"); you may not use this file except in compliance +with the License. You may obtain a copy of the License at + +http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, +software distributed under the License is distributed on an +"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +KIND, either express or implied. See the License for the +specific language governing permissions and limitations +under the License. +--> + +<#assign shoppingCart = sessionAttributes.shoppingCart!> +<#if shoppingCart?has_content> + <#assign shoppingCartSize = shoppingCart.size()> +<#else> + <#assign shoppingCartSize = 0> +</#if> + +<div id="minicart" class="card"> + <div class="card-header"> + ${uiLabelMap.OrderCartSummary} + </div> + <div class="card-body"> + <#if (shoppingCartSize > 0)> + <#if hidetoplinks?default("N") != "Y"> + <ul> + <li><a href="<@ofbizUrl>view/showcart</@ofbizUrl>" class="button">${uiLabelMap.OrderViewCart}</a></li> + <li><a href="<@ofbizUrl>checkoutoptions</@ofbizUrl>" class="button">${uiLabelMap.OrderCheckout}</a></li> + <li><a href="<@ofbizUrl>quickcheckout</@ofbizUrl>" class="button">${uiLabelMap.OrderCheckoutQuick}</a></li> + <li><a href="<@ofbizUrl>onePageCheckout</@ofbizUrl>" class="button">${uiLabelMap.EcommerceOnePageCheckout}</a></li> + </ul> + </#if> + <table class="table"> + <thead> + <tr> + <th>${uiLabelMap.OrderQty}</th> + <th>${uiLabelMap.OrderItem}</th> + <th>${uiLabelMap.CommonSubtotal}</th> + </tr> + </thead> + <tfoot> + <tr> + <td colspan="3"> + ${uiLabelMap.OrderTotal}: <@ofbizCurrency amount=shoppingCart.getDisplayGrandTotal() isoCode=shoppingCart.getCurrency()/> + </td> + </tr> + </tfoot> + <tbody> + <#list shoppingCart.items() as cartLine> + <tr> + <td>${cartLine.getQuantity()?string.number}</td> + <td> + <#if cartLine.getProductId()??> + <#if cartLine.getParentProductId()??> + <a href="<@ofbizCatalogAltUrl productId=cartLine.getParentProductId()/>" class="linktext">${cartLine.getName(dispatcher)}</a> + <#else> + <a href="<@ofbizCatalogAltUrl productId=cartLine.getProductId()/>" class="linktext">${cartLine.getName(dispatcher)}</a> + </#if> + <#else> + <strong>${cartLine.getItemTypeDescription()!}</strong> + </#if> + </td> + <td><@ofbizCurrency amount=cartLine.getDisplayItemSubTotal() isoCode=shoppingCart.getCurrency()/></td> + </tr> + <#if cartLine.getReservStart()??> + <tr><td> </td><td colspan="2">(${cartLine.getReservStart()?string("yyyy-MM-dd")}, ${cartLine.getReservLength()} <#if cartLine.getReservLength() == 1>${uiLabelMap.CommonDay}<#else>${uiLabelMap.CommonDays}</#if>)</td></tr> + </#if> + </#list> + </tbody> + </table> + <#if hidebottomlinks?default("N") != "Y"> + <ul> + <li><a href="<@ofbizUrl>view/showcart</@ofbizUrl>" class="button">${uiLabelMap.OrderViewCart}</a></li> + <li><a href="<@ofbizUrl>checkoutoptions</@ofbizUrl>" class="button">${uiLabelMap.OrderCheckout}</a></li> + <li><a href="<@ofbizUrl>quickcheckout</@ofbizUrl>" class="button">${uiLabelMap.OrderCheckoutQuick}</a></li> + <li><a href="<@ofbizUrl>onePageCheckout</@ofbizUrl>" class="button">${uiLabelMap.EcommerceOnePageCheckout}</a></li> + </ul> + </#if> + <#else> + <p>${uiLabelMap.OrderShoppingCartEmpty}</p> + </#if> + </div> +</div> Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/cart/MiniCart.ftl ------------------------------------------------------------------------------ svn:mime-type = text/plain Added: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl?rev=1818245&view=auto ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl (added) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl Fri Dec 15 08:56:27 2017 @@ -0,0 +1,53 @@ +<#-- +Licensed to the Apache Software Foundation (ASF) under one +or more contributor license agreements. See the NOTICE file +distributed with this work for additional information +regarding copyright ownership. The ASF licenses this file +to you under the Apache License, Version 2.0 (the +"License"); you may not use this file except in compliance +with the License. You may obtain a copy of the License at + +http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, +software distributed under the License is distributed on an +"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +KIND, either express or implied. See the License for the +specific language governing permissions and limitations +under the License. +--> +<div id="productcomparelist" class="card"> + <div class="card-header"> + ${uiLabelMap.ProductCompareProducts} + </div> + <div class="card-body"> + <#assign productCompareList = Static["org.apache.ofbiz.product.product.ProductEvents"].getProductCompareList(request)/> + <#if productCompareList?has_content> + <table> + <#list productCompareList as product> + <tr> + <td> + ${Static["org.apache.ofbiz.product.product.ProductContentWrapper"].getProductContentAsText(product, "PRODUCT_NAME", request, "html")} + </td> + <td> + <form method="post" action="<@ofbizUrl>removeFromCompare</@ofbizUrl>" name="removeFromCompare${product_index}form"> + <input type="hidden" name="productId" value="${product.productId}"/> + </form> + <a href="javascript:document.removeFromCompare${product_index}form.submit()" class="btn btn-link btn-sm">${uiLabelMap.CommonRemove}</a> + </td> + </tr> + </#list> + </table> + <div> + <a href="<@ofbizUrl>clearCompareList</@ofbizUrl>" class="btn btn-outline-secondary">${uiLabelMap.CommonClearAll}</a> + </div> + <div> + <a href="javascript:popUp('<@ofbizUrl secure="${request.isSecure()?string}">compareProducts</@ofbizUrl>', 'compareProducts', '650', '750')" class="btn btn-outline-secondary">${uiLabelMap.ProductCompareProducts}</a> + </div> + <#else> + <div> + ${uiLabelMap.ProductNoProductsToCompare} + </div> + </#if> + </div> +</div> \ No newline at end of file Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/CompareProductsList.ftl ------------------------------------------------------------------------------ svn:mime-type = text/plain Added: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl?rev=1818245&view=auto ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl (added) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl Fri Dec 15 08:56:27 2017 @@ -0,0 +1,76 @@ +<#-- +Licensed to the Apache Software Foundation (ASF) under one +or more contributor license agreements. See the NOTICE file +distributed with this work for additional information +regarding copyright ownership. The ASF licenses this file +to you under the Apache License, Version 2.0 (the +"License"); you may not use this file except in compliance +with the License. You may obtain a copy of the License at + +http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, +software distributed under the License is distributed on an +"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +KIND, either express or implied. See the License for the +specific language governing permissions and limitations +under the License. +--> + +<div id="keywordsearchbox" class="card"> + <div class="card-header"> + ${uiLabelMap.ProductSearchCatalog}</li> + </div> + <div class="card-body"> + <form name="keywordsearchform" id="keywordsearchbox_keywordsearchform" method="post" action="<@ofbizUrl>keywordsearch</@ofbizUrl>"> + <div class="form-group"> + <input type="hidden" name="VIEW_SIZE" value="10" /> + <input type="hidden" name="PAGING" value="Y" /> + <label for="catalogInput">${uiLabelMap.Catalog}</label> + <input type="text" name="SEARCH_STRING" size="14" class="form-control" id="catalogInput" maxlength="50" value="${requestParameters.SEARCH_STRING!}" /> + </div> + <#if 0 < otherSearchProdCatalogCategories?size> + <div class="form-group"> + <select name="SEARCH_CATEGORY_ID" class="form-control" size="1"> + <option value="${searchCategoryId!}">${uiLabelMap.ProductEntireCatalog}</option> + <#list otherSearchProdCatalogCategories as otherSearchProdCatalogCategory> + <#assign searchProductCategory = otherSearchProdCatalogCategory.getRelatedOne("ProductCategory", true)> + <#if searchProductCategory??> + <option value="${searchProductCategory.productCategoryId}">${searchProductCategory.description?default("No Description " + searchProductCategory.productCategoryId)}</option> + </#if> + </#list> + </select> + </div> + <#else> + <input type="hidden" name="SEARCH_CATEGORY_ID" value="${searchCategoryId!}" /> + </#if> + <div class="form-group"> + <div class="form-check"> + <label class="form-check-label" for="SEARCH_OPERATOR_OR"><input type="radio" class="form-check-input" name="SEARCH_OPERATOR" id="SEARCH_OPERATOR_OR" value="OR" <#if "OR" == searchOperator>checked="checked"</#if> />${uiLabelMap.CommonAny}</label> + </div> + <div class="form-check"> + <label class="form-check-label" for="SEARCH_OPERATOR_AND"><input type="radio" class="form-check-input" name="SEARCH_OPERATOR" id="SEARCH_OPERATOR_AND" value="AND" <#if "AND" == searchOperator>checked="checked"</#if> />${uiLabelMap.CommonAll}</label> + </div> + </div> + <input type="submit" value="${uiLabelMap.CommonFind}" class="btn btn-outline-secondary" /> + + </form> + <form name="advancedsearchform" id="keywordsearchbox_advancedsearchform" method="post" action="<@ofbizUrl>advancedsearch</@ofbizUrl>"> + <#if 0 < otherSearchProdCatalogCategories?size> + <label for="SEARCH_CATEGORY_ID">${uiLabelMap.ProductAdvancedSearchIn}: </label> + <select name="SEARCH_CATEGORY_ID" id="SEARCH_CATEGORY_ID" class="form-control" size="1"> + <option value="${searchCategoryId!}">${uiLabelMap.ProductEntireCatalog}</option> + <#list otherSearchProdCatalogCategories as otherSearchProdCatalogCategory> + <#assign searchProductCategory = otherSearchProdCatalogCategory.getRelatedOne("ProductCategory", true)> + <#if searchProductCategory??> + <option value="${searchProductCategory.productCategoryId}">${searchProductCategory.description?default("No Description " + searchProductCategory.productCategoryId)}</option> + </#if> + </#list> + </select> + <#else> + <input type="hidden" name="SEARCH_CATEGORY_ID" value="${searchCategoryId!}" /> + </#if> + <input type="submit" value="${uiLabelMap.ProductAdvancedSearch}" class="btn btn-outline-secondary" /> + </form> + </div> +</div> \ No newline at end of file Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl ------------------------------------------------------------------------------ svn:eol-style = native Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl ------------------------------------------------------------------------------ svn:keywords = Date Rev Author URL Id Propchange: ofbiz/ofbiz-plugins/trunk/ecommerce/template/catalog/KeywordSearchBox.ftl ------------------------------------------------------------------------------ svn:mime-type = text/plain Modified: ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CartScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CartScreens.xml?rev=1818245&r1=1818244&r2=1818245&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CartScreens.xml (original) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CartScreens.xml Fri Dec 15 08:56:27 2017 @@ -39,7 +39,7 @@ under the License. <set field="hidebottomlinks" value="N"/> </actions> <widgets> - <platform-specific><html><html-template location="component://order/template/entry/cart/MiniCart.ftl"/></html></platform-specific> + <platform-specific><html><html-template location="component://ecommerce/template/cart/MiniCart.ftl"/></html></platform-specific> </widgets> </section> </screen> Modified: ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CatalogScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CatalogScreens.xml?rev=1818245&r1=1818244&r2=1818245&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CatalogScreens.xml (original) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CatalogScreens.xml Fri Dec 15 08:56:27 2017 @@ -40,7 +40,15 @@ under the License. <script location="component://order/groovyScripts/entry/catalog/KeywordSearchOptions.groovy"/> </actions> <widgets> - <platform-specific><html><html-template location="component://order/template/entry/catalog/KeywordSearchBox.ftl"/></html></platform-specific> + <platform-specific><html><html-template location="component://ecommerce/template/catalog/KeywordSearchBox.ftl"/></html></platform-specific> + </widgets> + </section> + </screen> + + <screen name="compareproductslist"> + <section> + <widgets> + <platform-specific><html><html-template location="component://ecommerce/template/catalog/CompareProductsList.ftl"/></html></platform-specific> </widgets> </section> </screen> Modified: ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CommonScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CommonScreens.xml?rev=1818245&r1=1818244&r2=1818245&view=diff ============================================================================== --- ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CommonScreens.xml (original) +++ ofbiz/ofbiz-plugins/trunk/ecommerce/widget/CommonScreens.xml Fri Dec 15 08:56:27 2017 @@ -131,7 +131,7 @@ under the License. <widgets> <include-screen name="language"/> <include-screen name="minicart" location="component://ecommerce/widget/CartScreens.xml"/> - <include-screen name="compareproductslist" location="component://order/widget/ordermgr/OrderEntryCatalogScreens.xml"/> + <include-screen name="compareproductslist" location="component://ecommerce/widget/CatalogScreens.xml"/> <include-screen name="minipromotext" location="component://ecommerce/widget/CartScreens.xml"/> <include-screen name="miniassocprods" location="component://ecommerce/widget/CatalogScreens.xml"/> <include-screen name="factoids" location="component://ecommerce/widget/ContentScreens.xml"/> |
Free forum by Nabble | Edit this page |