Author: lektran
Date: Sat Jul 12 03:54:27 2008 New Revision: 676143 URL: http://svn.apache.org/viewvc?rev=676143&view=rev Log: A few more bsh -> groovy conversions Added: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy - copied, changed from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy - copied, changed from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy - copied, changed from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy - copied, changed from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutPayment.groovy - copied, changed from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh Removed: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh Modified: ofbiz/trunk/applications/ecommerce/widget/OrderScreens.xml ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryScreens.xml Modified: ofbiz/trunk/applications/ecommerce/widget/OrderScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/ecommerce/widget/OrderScreens.xml?rev=676143&r1=676142&r2=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/ecommerce/widget/OrderScreens.xml (original) +++ ofbiz/trunk/applications/ecommerce/widget/OrderScreens.xml Sat Jul 12 03:54:27 2008 @@ -235,7 +235,7 @@ <set field="titleProperty" value="PageTitleCheckoutOptions"/> <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh"/> - <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh"/> + <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy"/> <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/storepaymentoptions.bsh"/> </actions> <widgets> Copied: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy (from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh) URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy?p2=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy&p1=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh&r1=675904&r2=676143&rev=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy Sat Jul 12 03:54:27 2008 @@ -22,40 +22,34 @@ import org.ofbiz.entity.*; import org.ofbiz.base.util.*; -delegator = request.getAttribute("delegator"); - cart = ShoppingCartEvents.getCartObject(request); additionalPartyRole = cart.getAdditionalPartyRoleMap(); -it = additionalPartyRole.entrySet().iterator(); -roleData = new HashMap(); -partyData = new HashMap(); +roleData = [:]; +partyData = [:]; -while (it.hasNext()) { - me = (Map.Entry) it.next(); - roleData.put(me.getKey(), delegator.findByPrimaryKeyCache("RoleType", UtilMisc.toMap("roleTypeId", me.getKey()))); - pIt = ((List)me.getValue()).iterator(); +additionalPartyRole.each { roleTypeId, partyList -> + roleData[roleTypeId] = delegator.findByPrimaryKeyCache("RoleType", [roleTypeId : roleTypeId]); - while (pIt.hasNext()) { - partyId = pIt.next(); - party = new HashMap(); - party.put("partyId", partyId); - gv = delegator.findByPrimaryKeyCache("Party", UtilMisc.toMap("partyId", partyId)); - if (gv.get("partyTypeId").equals("PERSON")) { - gv = gv.getRelatedOneCache("Person"); - party.put("type", "person"); - party.put("firstName", gv.get("firstName")); - party.put("lastName", gv.get("lastName")); + partyList.each { partyId -> + partyMap = [:]; + partyMap.partyId = partyId; + party = delegator.findByPrimaryKeyCache("Party", [partyId : partyId]); + if (party.partyTypeId.equals("PERSON")) { + party = party.getRelatedOneCache("Person"); + partyMap.type = "person"; + partyMap.firstName = party.firstName; + partyMap.lastName = party.lastName; } else { - gv = gv.getRelatedOneCache("PartyGroup"); - party.put("type", "group"); - party.put("groupName", gv.get("groupName")); + party = party.getRelatedOneCache("PartyGroup"); + partyMap.type = "group"; + partyMap.groupName = party.groupName; } - partyData.put(partyId, party); + partyData[partyId] = partyMap; } } -context.put("additionalPartyRoleMap", additionalPartyRole); -context.put("roleList", cart.getAdditionalPartyRoleMap().keySet()); -context.put("roleData", roleData); -context.put("partyData", partyData); +context.additionalPartyRoleMap = additionalPartyRole; +context.roleList = additionalPartyRole.keySet(); +context.roleData = roleData; +context.partyData = partyData; Copied: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy (from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh) URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy?p2=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy&p1=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh&r1=675904&r2=676143&rev=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy Sat Jul 12 03:54:27 2008 @@ -24,13 +24,11 @@ import org.ofbiz.order.shoppingcart.*; import org.ofbiz.party.contact.*; -delegator = request.getAttribute("delegator"); -dispatcher = request.getAttribute("dispatcher"); cart = session.getAttribute("shoppingCart"); orderPartyId = cart.getPartyId(); currencyUomId = cart.getCurrency(); -context.put("cart", cart); -context.put("paymentMethodType", request.getParameter("paymentMethodType")); +context.cart = cart; +context.paymentMethodType = request.getParameter("paymentMethodType"); // nuke the event messages request.removeAttribute("_EVENT_MESSAGE_"); @@ -38,58 +36,58 @@ // If there's a paymentMethodId request attribute, the user has just created a new payment method, // so put the new paymentMethodId in the context for the UI newPaymentMethodId=request.getAttribute("paymentMethodId"); -if(! UtilValidate.isEmpty(newPaymentMethodId)) { - context.put("checkOutPaymentId", newPaymentMethodId); +if (newPaymentMethodId) { + context.checkOutPaymentId = newPaymentMethodId; } -if (orderPartyId != null && !orderPartyId.equals("_NA_")) { - orderParty = delegator.findByPrimaryKey("Party", UtilMisc.toMap("partyId", orderPartyId)); +if (orderPartyId && !orderPartyId.equals("_NA_")) { + orderParty = delegator.findByPrimaryKey("Party", [partyId : orderPartyId]); orderPerson = orderParty.getRelatedOne("Person"); - context.put("orderParty", orderParty); - context.put("orderPerson", orderPerson); - if (orderParty != null) { - context.put("paymentMethodList", EntityUtil.filterByDate(orderParty.getRelated("PaymentMethod"), true)); - + context.orderParty = orderParty; + context.orderPerson = orderPerson; + if (orderParty) { + context.paymentMethodList = EntityUtil.filterByDate(orderParty.getRelated("PaymentMethod"), true); + billingAccountList = BillingAccountWorker.makePartyBillingAccountList(userLogin, currencyUomId, orderPartyId, delegator, dispatcher); - if (billingAccountList != null && billingAccountList.size() > 0) { - context.put("selectedBillingAccountId", cart.getBillingAccountId()); - context.put("billingAccountList", billingAccountList); + if (billingAccountList) { + context.selectedBillingAccountId = cart.getBillingAccountId(); + context.billingAccountList = billingAccountList; } } } -if (request.getParameter("useShipAddr") != null && cart.getShippingContactMechId() != null) { +if (request.getParameter("useShipAddr") && cart.getShippingContactMechId()) { shippingContactMech = cart.getShippingContactMechId(); - postalAddress = delegator.findByPrimaryKey("PostalAddress", UtilMisc.toMap("contactMechId", shippingContactMech)); - context.put("postalFields", postalAddress); + postalAddress = delegator.findByPrimaryKey("PostalAddress", [contactMechId : shippingContactMech]); + context.postalFields = postalAddress; } else { - context.put("postalFields", UtilHttp.getParameterMap(request)); + context.postalFields = UtilHttp.getParameterMap(request); } -if (cart != null) { - if (cart.getPaymentMethodIds().size() > 0) { +if (cart) { + if (cart.getPaymentMethodIds()) { checkOutPaymentId = cart.getPaymentMethodIds().get(0); - context.put("checkOutPaymentId", checkOutPaymentId); - if (orderParty == null) { - paymentMethod = delegator.findByPrimaryKey("PaymentMethod", UtilMisc.toMap("paymentMethodId", checkOutPaymentId)); - if (paymentMethod != null && paymentMethod.getString("paymentMethodTypeId").equals("CREDIT_CARD")) { + context.checkOutPaymentId = checkOutPaymentId; + if (!orderParty) { + paymentMethod = delegator.findByPrimaryKey("PaymentMethod", [paymentMethodId : checkOutPaymentId]); + if ("CREDIT_CARD".equals(paymentMethod?.paymentMethodTypeId)) { paymentMethodType = "CC"; account = paymentMethod.getRelatedOne("CreditCard"); - context.put("creditCard", account); - context.put("paymentMethodType", paymentMethodType); - } else if (paymentMethod != null && paymentMethod.getString("paymentMethodTypeId").equals("EFT_ACCOUNT")) { + context.creditCard = account; + context.paymentMethodType = paymentMethodType; + } else if ("EFT_ACCOUNT".equals(paymentMethod.paymentMethodTypeId)) { paymentMethodType = "EFT"; account = paymentMethod.getRelatedOne("EftAccount"); - context.put("eftAccount", account); - context.put("paymentMethodType", paymentMethodType); + context.eftAccount = account; + context.paymentMethodType = paymentMethodType; } - if (account != null) { + if (account) { address = account.getRelatedOne("PostalAddress"); - context.put("postalAddress", address); + context.postalAddress = address; } - } - } else if (cart.getPaymentMethodTypeIds().size() > 0) { + } + } else if (cart.getPaymentMethodTypeIds()) { checkOutPaymentId = cart.getPaymentMethodTypeIds().get(0); - context.put("checkOutPaymentId", checkOutPaymentId); + context.checkOutPaymentId = checkOutPaymentId; } } Copied: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy (from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh) URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy?p2=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy&p1=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh&r1=675904&r2=676143&rev=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy Sat Jul 12 03:54:27 2008 @@ -29,32 +29,24 @@ import org.ofbiz.order.shoppingcart.product.ProductDisplayWorker; import org.ofbiz.order.shoppingcart.product.ProductPromoWorker; -delegator = request.getAttribute("delegator"); -security = request.getAttribute("security"); -dispatcher= (LocalDispatcher)request.getAttribute("dispatcher"); -userLogin = session.getAttribute("userLogin"); - -context.put("dispatcher",dispatcher); - productStore = ProductStoreWorker.getProductStore(request); -if( productStore != null ){ - context.put("defaultProductStore", productStore); - if( productStore.getString("defaultSalesChannelEnumId") != null ) - context.put("defaultSalesChannel", delegator.findByPrimaryKeyCache("Enumeration", - UtilMisc.toMap("enumId",productStore.getString("defaultSalesChannelEnumId")))); +if (productStore) { + context.defaultProductStore = productStore; + if (productStore.defaultSalesChannelEnumId) + context.defaultSalesChannel = delegator.findByPrimaryKeyCache("Enumeration", [enumId : productStore.defaultSalesChannelEnumId]); } // Get the Cart shoppingCart = session.getAttribute("shoppingCart"); -context.put("shoppingCart", shoppingCart); +context.shoppingCart = shoppingCart; -salesChannels = delegator.findByAndCache("Enumeration", UtilMisc.toMap("enumTypeId", "ORDER_SALES_CHANNEL"), UtilMisc.toList("sequenceId")); -context.put("salesChannels", salesChannels); +salesChannels = delegator.findByAndCache("Enumeration", [enumTypeId : "ORDER_SALES_CHANNEL"], ["sequenceId"]); +context.salesChannels = salesChannels; -productStores = delegator.findList("ProductStore", null, null, UtilMisc.toList("storeName"), null, true); -context.put("productStores", productStores); +productStores = delegator.findList("ProductStore", null, null, ["storeName"], null, true); +context.productStores = productStores; -suppliers = delegator.findByAnd("PartyRole", UtilMisc.toMap("roleTypeId", "SUPPLIER")); -context.put("suppliers", suppliers); +suppliers = delegator.findByAnd("PartyRole", [roleTypeId : "SUPPLIER"]); +context.suppliers = suppliers; -organizations = delegator.findByAnd("PartyRole", UtilMisc.toMap("roleTypeId", "INTERNAL_ORGANIZATIO")); -context.put("organizations", organizations); +organizations = delegator.findByAnd("PartyRole", [roleTypeId : "INTERNAL_ORGANIZATIO"]); +context.organizations = organizations; Copied: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy (from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh) URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy?p2=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy&p1=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh&r1=675904&r2=676143&rev=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy Sat Jul 12 03:54:27 2008 @@ -28,49 +28,49 @@ shoppingCart = session.getAttribute("shoppingCart"); currencyUomId = shoppingCart.getCurrency(); partyId = shoppingCart.getPartyId(); -party = delegator.findByPrimaryKeyCache("Party", UtilMisc.toMap("partyId", partyId)); +party = delegator.findByPrimaryKeyCache("Party", [partyId : partyId]); productStore = ProductStoreWorker.getProductStore(request); shippingEstWpr = null; -if (shoppingCart != null) { +if (shoppingCart) { shippingEstWpr = new ShippingEstimateWrapper(dispatcher, shoppingCart, 0); - context.put("shippingEstWpr", shippingEstWpr); - context.put("carrierShipmentMethodList", shippingEstWpr.getShippingMethods()); + context.shippingEstWpr = shippingEstWpr; + context.carrierShipmentMethodList = shippingEstWpr.getShippingMethods(); } // Reassign items requiring drop-shipping to new or existing drop-ship groups -if (shoppingCart != null) { +if (shoppingCart) { shoppingCart.createDropShipGroups(dispatcher); } -profiledefs = delegator.findByPrimaryKey("PartyProfileDefault", UtilMisc.toMap("partyId", userLogin.getString("partyId"), "productStoreId", productStoreId)); -context.put("profiledefs", profiledefs); +profiledefs = delegator.findByPrimaryKey("PartyProfileDefault", [partyId : userLogin.partyId, productStoreId : productStoreId]); +context.profiledefs : profiledefs; -context.put("shoppingCart", shoppingCart); -context.put("userLogin", userLogin); -context.put("productStoreId", productStore.get("productStoreId")); -context.put("productStore", productStore); -shipToParty = delegator.findByPrimaryKeyCache("Party", UtilMisc.toMap("partyId", shoppingCart.getShipToCustomerPartyId())); -context.put("shippingContactMechList", ContactHelper.getContactMech(shipToParty, "SHIPPING_LOCATION", "POSTAL_ADDRESS", false)); -context.put("emailList", ContactHelper.getContactMechByType(party, "EMAIL_ADDRESS", false)); - -if (shoppingCart.getShipmentMethodTypeId() != null && shoppingCart.getCarrierPartyId() != null) { - context.put("chosenShippingMethod", shoppingCart.getShipmentMethodTypeId() + '@' + shoppingCart.getCarrierPartyId()); -} else if (profiledefs != null && profiledefs.get("defaultShipMeth") != null) { - context.put("chosenShippingMethod", profiledefs.get("defaultShipMeth")); +context.shoppingCart = shoppingCart; +context.userLogin = userLogin; +context.productStoreId = productStore.get("productStoreId"); +context.productStore = productStore; +shipToParty = delegator.findByPrimaryKeyCache("Party", [partyId : shoppingCart.getShipToCustomerPartyId()]); +context.shippingContactMechList = ContactHelper.getContactMech(shipToParty, "SHIPPING_LOCATION", "POSTAL_ADDRESS", false); +context.emailList = ContactHelper.getContactMechByType(party, "EMAIL_ADDRESS", false); + +if (shoppingCart.getShipmentMethodTypeId() && shoppingCart.getCarrierPartyId()) { + context.chosenShippingMethod = shoppingCart.getShipmentMethodTypeId() + '@' + shoppingCart.getCarrierPartyId(); +} else if (profiledefs?.defaultShipMeth) { + context.chosenShippingMethod = profiledefs.defaultShipMeth; } // other profile defaults -if (shoppingCart.getShippingAddress() == null && profiledefs != null && profiledefs.get("defaultShipAddr") != null) { - shoppingCart.setShippingContactMechId(profiledefs.get("defaultShipAddr")); +if (!shoppingCart.getShippingAddress() && profiledefs?.defaultShipAddr) { + shoppingCart.setShippingContactMechId(profiledefs.defaultShipAddr); } -if (shoppingCart.selectedPayments() == 0 && profiledefs != null && profiledefs.get("defaultPayMeth") != null) { - shoppingCart.addPayment(profiledefs.get("defaultPayMeth")); +if (shoppingCart.selectedPayments() == 0 && profiledefs?.defaultPayMeth) { + shoppingCart.addPayment(profiledefs.defaultPayMeth); } // create a list containing all the parties associated to the current cart, useful to change // the ship to party id -List cartParties = UtilMisc.toList(shoppingCart.getShipToCustomerPartyId()); +cartParties = [shoppingCart.getShipToCustomerPartyId()]; if (!cartParties.contains(partyId)) { cartParties.add(partyId); } @@ -89,13 +89,12 @@ if (!cartParties.contains(shoppingCart.getSupplierAgentPartyId())) { cartParties.add(shoppingCart.getSupplierAgentPartyId()); } -List salesReprs = (List)shoppingCart.getAdditionalPartyRoleMap().get("SALES_REP"); -if (salesReprs != null) { - for (int i = 0; i < salesReprs.size(); i++) { - String salesRep = (String)salesReprs.get(i); +salesReps = shoppingCart.getAdditionalPartyRoleMap().SALES_REP; +if (salesReps) { + salesReps.each { salesRep -> if (!cartParties.contains(salesRep)) { cartParties.add(salesRep); } } } -context.put("cartParties", cartParties); +context.cartParties = cartParties; Copied: ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutPayment.groovy (from r675904, ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh) URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutPayment.groovy?p2=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutPayment.groovy&p1=ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh&r1=675904&r2=676143&rev=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh (original) +++ ofbiz/trunk/applications/order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutPayment.groovy Sat Jul 12 03:54:27 2008 @@ -28,31 +28,31 @@ currencyUomId = cart.getCurrency(); userLogin = session.getAttribute("userLogin"); partyId = cart.getPartyId(); -party = delegator.findByPrimaryKeyCache("Party", UtilMisc.toMap("partyId", partyId)); +party = delegator.findByPrimaryKeyCache("Party", [partyId : partyId]); productStoreId = ProductStoreWorker.getProductStoreId(request); checkOutPaymentId = ""; -if (cart != null) { - if (cart.getPaymentMethodIds().size() > 0) { +if (cart) { + if (cart.getPaymentMethodIds()) { checkOutPaymentId = cart.getPaymentMethodIds().get(0); - } else if (cart.getPaymentMethodTypeIds().size() > 0) { + } else if (cart.getPaymentMethodTypeIds()) { checkOutPaymentId = cart.getPaymentMethodTypeIds().get(0); } } -finAccounts = delegator.findByAnd("FinAccountAndRole", UtilMisc.toMap("partyId", partyId, "roleTypeId", "OWNER")); +finAccounts = delegator.findByAnd("FinAccountAndRole", [partyId : partyId, roleTypeId : "OWNER"]); finAccounts = EntityUtil.filterByDate(finAccounts, UtilDateTime.nowTimestamp(), "roleFromDate", "roleThruDate", true); finAccounts = EntityUtil.filterByDate(finAccounts); -context.put("finAccounts",finAccounts); +context.finAccounts = finAccounts; -context.put("shoppingCart", cart); -context.put("userLogin", userLogin); -context.put("productStoreId", productStoreId); -context.put("checkOutPaymentId", checkOutPaymentId); -context.put("paymentMethodList", EntityUtil.filterByDate(party.getRelated("PaymentMethod", null, UtilMisc.toList("paymentMethodTypeId")), true)); +context.shoppingCart = cart; +context.userLogin = userLogin; +context.productStoreId = productStoreId; +context.checkOutPaymentId = checkOutPaymentId; +context.paymentMethodList = EntityUtil.filterByDate(party.getRelated("PaymentMethod", null, ["paymentMethodTypeId"]), true); billingAccountList = BillingAccountWorker.makePartyBillingAccountList(userLogin, currencyUomId, partyId, delegator, dispatcher); -if (billingAccountList != null && billingAccountList.size() > 0) { - context.put("selectedBillingAccountId", cart.getBillingAccountId()); - context.put("billingAccountList", billingAccountList); +if (billingAccountList) { + context.selectedBillingAccountId = cart.getBillingAccountId(); + context.billingAccountList = billingAccountList; } Modified: ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml?rev=676143&r1=676142&r2=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml (original) +++ ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryOrderScreens.xml Sat Jul 12 03:54:27 2008 @@ -51,7 +51,7 @@ <set field="headerItem" value="orderentry"/> <set field="title-property" value="PageTitleCheckoutOptions"/> <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/checkoutpayment.bsh"/> - <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/checkoutoptions.bsh"/> + <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/CheckoutOptions.groovy"/> <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/storepaymentoptions.bsh"/> </actions> <widgets> @@ -160,7 +160,7 @@ <actions> <set field="stepTitleId" value="OrderOrderEntryPaymentSettings"/> <set field="stepLabelId" value="AccountingPayment"/> - <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/billsettings.bsh"/> + <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/BillSettings.groovy"/> </actions> <widgets> <decorator-screen name="CommonOrderCheckoutDecorator"> @@ -179,7 +179,7 @@ <set field="stepTitleId" value="PartyAdditionalPartyEntry"/> <set field="stepLabelId" value="PartyParties"/> <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/setAdditionalParty.bsh"/> - <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/additionalPartyListing.bsh"/> + <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/AdditionalPartyListing.groovy"/> </actions> <widgets> <decorator-screen name="CommonOrderCheckoutDecorator"> Modified: ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryScreens.xml?rev=676143&r1=676142&r2=676143&view=diff ============================================================================== --- ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryScreens.xml (original) +++ ofbiz/trunk/applications/order/widget/ordermgr/OrderEntryScreens.xml Sat Jul 12 03:54:27 2008 @@ -23,7 +23,7 @@ <actions> <set field="titleProperty" value="PageTitleOrderInits"/> <set field="headerItem" value="orderentry"/> - <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/checkinits.bsh"/> + <script location="component://order/webapp/ordermgr/WEB-INF/actions/entry/CheckInits.groovy"/> </actions> <widgets> <decorator-screen name="main-decorator" location="${parameters.mainDecoratorLocation}"> |
Free forum by Nabble | Edit this page |