At the beginning of
\ofbiz\applications\product\webapp\catalog\store\EditProductStorePaySetup.ftl, there is the following code. I'm wondering where 'paymentSettings' is coming from? I assume something like from the context, having been put there. But how and where? <#list paymentSettings as setting> <#assign payMeth = setting.getRelatedOne("PaymentMethodType")> <#assign enum = setting.getRelatedOne("Enumeration")> <tr> <td><div class="tabletext">${payMeth.get("description",locale)}</div></td> <td><div class="tabletext">${enum.get("description",locale)}</div></td> CJ _______________________________________________ Users mailing list [hidden email] http://lists.ofbiz.org/mailman/listinfo/users |
Hi Charles,
I'd start from the screen definition for the "EditProductStorePaySetup" screen that is located in: \ofbiz\applications\product\widget\catalog\StoreScreens.xml Here you'll see that the script: product/webapp/catalog/WEB-INF/actions/store/EditProductStorePaySetup.bsh is called to prepare data for the ftl template. Hope this helps, Jacopo Charles Johnson wrote: > At the beginning of > \ofbiz\applications\product\webapp\catalog\store\EditProductStorePaySetup.ftl, > there is the following code. > I'm wondering where 'paymentSettings' is coming from? I assume something > like from the context, having been put there. But how and where? > > <#list paymentSettings as setting> > <#assign payMeth = setting.getRelatedOne("PaymentMethodType")> > <#assign enum = setting.getRelatedOne("Enumeration")> > <tr> > <td><div > class="tabletext">${payMeth.get("description",locale)}</div></td> > <td><div > class="tabletext">${enum.get("description",locale)}</div></td> > > CJ > > > _______________________________________________ > Users mailing list > [hidden email] > http://lists.ofbiz.org/mailman/listinfo/users > _______________________________________________ Users mailing list [hidden email] http://lists.ofbiz.org/mailman/listinfo/users |
In reply to this post by Charles Johnson-2
Hi, Charles
Hope those steps will help you understand where the 'paymentSettings' is coming from. First, open StoreScreens.xml in /application/product/widget directory. <screen name="EditProductStorePaySetup"> <section> <actions> <set field="titleProperty" value="PageTitleEditProductStorePaySetup"/> <set field="headerItem" value="store"/> <set field="tabButtonItem" value="EditProductStorePaySetup"/> <set field="labelTitleProperty" value="ProductProductStorePaymentSettings"/> <set field="productStoreId" from-field="parameters.productStoreId"/> <entity-one entity-name="ProductStore" value-name="productStore" auto-field-map="true"/> <script location="<a href="component://product/webapp/catalog/WEB-INF/actions/store/EditProductStorePaySetup.bsh">component://product/webapp/catalog/WEB-INF/actions/store/EditProductStorePaySetup.bsh "/> </actions> <widgets> <decorator-screen name="CommonProductStoreDecorator" location="${parameters.mainDecoratorLocation }"> <decorator-section name="body"> <platform-specific> <html><html-template location=" <a href="component://product/webapp/catalog/store/EditProductStorePaySetup.ftl">component://product/webapp/catalog/store/EditProductStorePaySetup.ftl"/></html> </platform-specific> </decorator-section> </decorator-screen> </widgets> </section> </screen> the paymentSettings is coming from EditProductStorePaySetup.bsh, Next step, open EditProductStorePaySetup.bsh. at line 32, you will see where the 'paymentSettings' come from context.put("paymentSettings", paymentSettings); Regards Jinsong On 12/10/05, Charles Johnson <[hidden email]> wrote: At the beginning of _______________________________________________ Users mailing list [hidden email] http://lists.ofbiz.org/mailman/listinfo/users |
Free forum by Nabble | Edit this page |