You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by mr...@apache.org on 2009/01/07 19:40:28 UTC
svn commit: r732423 [4/4] - in /ofbiz/trunk/applications: content/config/
content/widget/ order/config/ order/src/org/ofbiz/order/order/
order/src/org/ofbiz/order/shoppingcart/
order/src/org/ofbiz/order/shoppinglist/ order/webapp/ordermgr/entry/cart/
o...
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/order/OrderServices.java Wed Jan 7 10:40:27 2009
@@ -222,7 +222,7 @@
// check to make sure we have something to order
List orderItems = (List) context.get("orderItems");
if (orderItems.size() < 1) {
- return ServiceUtil.returnError(UtilProperties.getMessage(resource, "items.none", locale));
+ return ServiceUtil.returnError(UtilProperties.getMessage(resource_error, "items.none", locale));
}
// all this marketing pkg auto stuff is deprecated in favor of MARKETING_PKG_AUTO productTypeId and a BOM of MANUF_COMPONENT assocs
@@ -286,14 +286,14 @@
try {
product = delegator.findByPrimaryKeyCache("Product", UtilMisc.toMap("productId", currentProductId));
} catch (GenericEntityException e) {
- String errMsg = UtilProperties.getMessage(resource, "product.not_found", new Object[] { currentProductId }, locale);
+ String errMsg = UtilProperties.getMessage(resource_error, "product.not_found", new Object[] { currentProductId }, locale);
Debug.logError(e, errMsg, module);
errorMessages.add(errMsg);
continue;
}
if (product == null) {
- String errMsg = UtilProperties.getMessage(resource, "product.not_found", new Object[] { currentProductId }, locale);
+ String errMsg = UtilProperties.getMessage(resource_error, "product.not_found", new Object[] { currentProductId }, locale);
Debug.logError(errMsg, module);
errorMessages.add(errMsg);
continue;
@@ -302,7 +302,7 @@
if ("SALES_ORDER".equals(orderTypeId)) {
// check to see if introductionDate hasn't passed yet
if (product.get("introductionDate") != null && nowTimestamp.before(product.getTimestamp("introductionDate"))) {
- String excMsg = UtilProperties.getMessage(resource, "product.not_yet_for_sale",
+ String excMsg = UtilProperties.getMessage(resource_error, "product.not_yet_for_sale",
new Object[] { getProductName(product, itemName), product.getString("productId") }, locale);
Debug.logWarning(excMsg, module);
errorMessages.add(excMsg);
@@ -313,7 +313,7 @@
if ("SALES_ORDER".equals(orderTypeId)) {
// check to see if salesDiscontinuationDate has passed
if (product.get("salesDiscontinuationDate") != null && nowTimestamp.after(product.getTimestamp("salesDiscontinuationDate"))) {
- String excMsg = UtilProperties.getMessage(resource, "product.no_longer_for_sale",
+ String excMsg = UtilProperties.getMessage(resource_error, "product.no_longer_for_sale",
new Object[] { getProductName(product, itemName), product.getString("productId") }, locale);
Debug.logWarning(excMsg, module);
errorMessages.add(excMsg);
@@ -329,7 +329,7 @@
errorMessages.add(invReqResult.get(ModelService.ERROR_MESSAGE));
errorMessages.addAll((List) invReqResult.get(ModelService.ERROR_MESSAGE_LIST));
} else if (!"Y".equals((String) invReqResult.get("availableOrNotRequired"))) {
- String invErrMsg = UtilProperties.getMessage(resource, "product.out_of_stock",
+ String invErrMsg = UtilProperties.getMessage(resource_error, "product.out_of_stock",
new Object[] { getProductName(product, itemName), currentProductId }, locale);
Debug.logWarning(invErrMsg, module);
errorMessages.add(invErrMsg);
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutEvents.java Wed Jan 7 10:40:27 2009
@@ -64,7 +64,7 @@
if (UtilValidate.isNotEmpty(cart)) {
return "success";
} else {
- errMsg = UtilProperties.getMessage(resource, "checkevents.cart_empty", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkevents.cart_empty", (cart != null ? cart.getLocale() : Locale.getDefault()));
request.setAttribute("_ERROR_MESSAGE_", errMsg);
return "error";
}
@@ -306,7 +306,7 @@
amount = new BigDecimal(amountStr);
} catch (NumberFormatException e) {
Debug.logError(e, module);
- errMsg = UtilProperties.getMessage(resource, "checkevents.invalid_amount_set_for_payment_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkevents.invalid_amount_set_for_payment_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
request.setAttribute("_ERROR_MESSAGE_", errMsg);
return null;
}
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/CheckOutHelper.java Wed Jan 7 10:40:27 2009
@@ -92,7 +92,7 @@
if (UtilValidate.isNotEmpty(this.cart)) {
errorMessages.addAll(setCheckOutShippingAddressInternal(shippingContactMechId));
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
if (errorMessages.size() == 1) {
@@ -115,7 +115,7 @@
this.cart.setShippingContactMechId(shippingContactMechId);
} else if (cart.shippingApplies()) {
// only return an error if shipping is required for this purchase
- errMsg = UtilProperties.getMessage(resource,"checkhelper.select_shipping_destination", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_shipping_destination", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -132,7 +132,7 @@
errorMessages.addAll(setCheckOutShippingOptionsInternal(shippingMethod, shippingInstructions,
orderAdditionalEmails, maySplit, giftMessage, isGift, internalCode, shipBeforeDate, shipAfterDate));
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -167,7 +167,7 @@
this.cart.setCarrierPartyId(carrierPartyId);
} else if (cart.shippingApplies()) {
// only return an error if shipping is required for this purchase
- errMsg = UtilProperties.getMessage(resource,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -177,7 +177,7 @@
if (UtilValidate.isNotEmpty(maySplit)) {
cart.setMaySplit(Boolean.valueOf(maySplit));
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.select_splitting_preference", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_splitting_preference", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -187,7 +187,7 @@
if (UtilValidate.isNotEmpty(isGift)) {
cart.setIsGift(Boolean.valueOf(isGift));
} else {
- errMsg = UtilProperties.getMessage(resource, "checkhelper.specify_if_order_is_gift", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkhelper.specify_if_order_is_gift", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -198,7 +198,7 @@
if (UtilValidate.isDate(shipBeforeDate)) {
cart.setShipBeforeDate(UtilDateTime.toTimestamp(shipBeforeDate));
} else {
- errMsg = UtilProperties.getMessage(resource, "checkhelper.specify_if_shipBeforeDate_is_date", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkhelper.specify_if_shipBeforeDate_is_date", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
}
@@ -207,7 +207,7 @@
if (UtilValidate.isDate(shipAfterDate)) {
cart.setShipAfterDate(UtilDateTime.toTimestamp(shipAfterDate));
} else {
- errMsg = UtilProperties.getMessage(resource, "checkhelper.specify_if_shipAfterDate_is_date", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkhelper.specify_if_shipAfterDate_is_date", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
}
@@ -226,7 +226,7 @@
if (UtilValidate.isNotEmpty(this.cart)) {
errorMessages.addAll(setCheckOutPaymentInternal(selectedPaymentMethods, singleUsePayments, billingAccountId));
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -287,7 +287,7 @@
// if an amount was entered, check that it doesn't exceed availalble amount
if (amountToUse.compareTo(BigDecimal.ZERO) > 0 && amountToUse.compareTo(accountCredit) > 0) {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.insufficient_credit_available_on_account",
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.insufficient_credit_available_on_account",
(cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
} else {
@@ -299,7 +299,7 @@
BigDecimal grandTotal = cart.getGrandTotal();
if (grandTotal.compareTo(amountToUse) > 0) {
cart.setBillingAccount(null, BigDecimal.ZERO); // erase existing billing account data
- errMsg = UtilProperties.getMessage(resource,"checkhelper.insufficient_credit_available_on_account",
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.insufficient_credit_available_on_account",
(cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
} else {
@@ -351,7 +351,7 @@
}
} else if (cart.getGrandTotal().compareTo(BigDecimal.ZERO) != 0) {
// only return an error if the order total is not 0.00
- errMsg = UtilProperties.getMessage(resource,"checkhelper.select_method_of_payment",
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_method_of_payment",
(cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -368,7 +368,7 @@
this.cart.setShipBeforeDate(shipBefore);
this.cart.setShipAfterDate(shipAfter);
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.no_items_in_cart",
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.no_items_in_cart",
(cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -418,7 +418,7 @@
errorMessages.addAll(setCheckOutPaymentInternal(selectedPaymentMethods, singleUsePayments, billingAccountId));
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.no_items_in_cart", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
@@ -447,14 +447,14 @@
boolean gcFieldsOkay = true;
if (gcNum == null || gcNum.length() == 0) {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.enter_gift_card_number", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.enter_gift_card_number", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
}
if (cart.isPinRequiredForGC(delegator)) {
// if a PIN is required, make sure the PIN is valid
if ((gcPin == null) || (gcPin.length() == 0)) {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.enter_gift_card_pin_number", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.enter_gift_card_pin_number", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
}
@@ -466,13 +466,13 @@
if (!cart.isPinRequiredForGC(delegator)) {
GenericValue finAccount = FinAccountHelper.getFinAccountFromCode(gcNum, delegator);
if (finAccount == null) {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.gift_card_does_not_exist", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.gift_card_does_not_exist", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
} else if ((finAccount.getBigDecimal("availableBalance") == null) ||
!((finAccount.getBigDecimal("availableBalance")).compareTo(FinAccountHelper.ZERO) > 0)) {
// if account's available balance (including authorizations) is not greater than zero, then return an error
- errMsg = UtilProperties.getMessage(resource,"checkhelper.gift_card_has_no_value", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.gift_card_has_no_value", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
}
@@ -486,7 +486,7 @@
if (UtilValidate.isNotEmpty(selectedPaymentMethods)) {
if (gcAmt == null || gcAmt.length() == 0) {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.enter_amount_to_place_on_gift_card", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.enter_amount_to_place_on_gift_card", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
}
@@ -496,7 +496,7 @@
gcAmount = new BigDecimal(gcAmt);
} catch (NumberFormatException e) {
Debug.logError(e, module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.invalid_amount_for_gift_card", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.invalid_amount_for_gift_card", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
gcFieldsOkay = false;
}
@@ -533,7 +533,7 @@
result.put("amount", giftCardAmount);
}
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problem_with_gift_card_information", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problem_with_gift_card_information", (cart != null ? cart.getLocale() : Locale.getDefault()));
errorMessages.add(errMsg);
}
}
@@ -602,14 +602,14 @@
} catch (GenericServiceException e) {
String service = e.getMessage();
Map messageMap = UtilMisc.toMap("service", service);
- String errMsg = UtilProperties.getMessage(resource, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
+ String errMsg = UtilProperties.getMessage(resource_error, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
Debug.logError(e, errMsg, module);
return ServiceUtil.returnError(errMsg);
}
// check for error message(s)
if (ServiceUtil.isError(storeResult)) {
- String errMsg = UtilProperties.getMessage(resource, "checkhelper.did_not_complete_order_following_occurred", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ String errMsg = UtilProperties.getMessage(resource_error, "checkhelper.did_not_complete_order_following_occurred", (cart != null ? cart.getLocale() : Locale.getDefault()));
List resErrorMessages = new LinkedList();
resErrorMessages.add(errMsg);
resErrorMessages.add(ServiceUtil.getErrorMessage(storeResult));
@@ -649,7 +649,7 @@
} catch (Exception e) {
String service = e.getMessage();
Map messageMap = UtilMisc.toMap("service", service);
- String errMsg = UtilProperties.getMessage(resource, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
+ String errMsg = UtilProperties.getMessage(resource_error, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
Debug.logError(e, errMsg, module);
return ServiceUtil.returnError(errMsg);
}
@@ -674,7 +674,7 @@
} catch (Exception e) {
String service = e.getMessage();
Map messageMap = UtilMisc.toMap("service", service);
- String errMsg = UtilProperties.getMessage(resource, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
+ String errMsg = UtilProperties.getMessage(resource_error, "checkhelper.could_not_create_order_invoking_service", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
Debug.logError(e, errMsg, module);
return ServiceUtil.returnError(errMsg);
}
@@ -1143,7 +1143,7 @@
billingAddress = creditCard.getRelatedOne("PostalAddress");
} catch (GenericEntityException e) {
Debug.logError(e, "Problems getting credit card from payment method", module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problems_reading_database", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problems_reading_database", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
if (creditCard != null) {
@@ -1170,7 +1170,7 @@
blacklistFound = this.delegator.findList("OrderBlacklist", ecl, null, null, null, false);
} catch (GenericEntityException e) {
Debug.logError(e, "Problems with OrderBlacklist lookup.", module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problems_reading_database", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problems_reading_database", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
}
@@ -1198,7 +1198,7 @@
}
} catch (GenericEntityException e) {
Debug.logError(e, module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.database_error", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.database_error", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
return result;
}
@@ -1223,7 +1223,7 @@
orderHeader = this.delegator.findByPrimaryKey("OrderHeader", UtilMisc.toMap("orderId", orderId));
} catch (GenericEntityException e) {
Debug.logError(e, "Problems getting order header", module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problems_getting_order_header", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problems_getting_order_header", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
return result;
}
@@ -1233,7 +1233,7 @@
paymentPrefs = orderHeader.getRelated("OrderPaymentPreference");
} catch (GenericEntityException e) {
Debug.logError(e, "Problems getting order payments", module);
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problems_getting_payment_preference", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problems_getting_payment_preference", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
return result;
}
@@ -1254,7 +1254,7 @@
result.put("type", "none");
return result;
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.problems_getting_order_header", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.problems_getting_order_header", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
result.put("type", "error");
return result;
@@ -1280,7 +1280,7 @@
}
result = ServiceUtil.returnSuccess();
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.enter_shipping_address", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.enter_shipping_address", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
}
@@ -1326,7 +1326,7 @@
this.cart.setShipmentMethodTypeId(shipGroupIndex, shipmentMethodTypeId);
this.cart.setCarrierPartyId(shipGroupIndex, carrierPartyId);
} else {
- errMsg = UtilProperties.getMessage(resource,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error,"checkhelper.select_shipping_method", (cart != null ? cart.getLocale() : Locale.getDefault()));
result = ServiceUtil.returnError(errMsg);
}
@@ -1429,7 +1429,7 @@
BigDecimal availableAmount = this.availableAccountBalance(billingAccountId);
if (billingAccountAmt.compareTo(availableAmount) > 0) {
Map messageMap = UtilMisc.toMap("billingAccountId", billingAccountId);
- errMsg = UtilProperties.getMessage(resource, "checkevents.not_enough_available_on_account", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkevents.not_enough_available_on_account", messageMap, (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
@@ -1438,7 +1438,7 @@
List paymentTypes = cart.getPaymentMethodTypeIds();
if (paymentTypes.contains("EXT_BILLACT") && paymentTypes.size() == 1 && paymentMethods.size() == 0) {
if (cart.getGrandTotal().compareTo(availableAmount) > 0) {
- errMsg = UtilProperties.getMessage(resource, "checkevents.insufficient_credit_available_on_account", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkevents.insufficient_credit_available_on_account", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
}
@@ -1490,14 +1490,14 @@
BigDecimal requiredAmount = reqAmtPreParse.setScale(scale, rounding);
if (paymentMethods != null && paymentMethods.size() > 0 && requiredAmount.compareTo(selectedPaymentTotal) > 0) {
Debug.logError("Required Amount : " + requiredAmount + " / Selected Amount : " + selectedPaymentTotal, module);
- errMsg = UtilProperties.getMessage(resource, "checkevents.payment_not_cover_this_order", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkevents.payment_not_cover_this_order", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
if (paymentMethods != null && paymentMethods.size() > 0 && requiredAmount.compareTo(selectedPaymentTotal) < 0) {
BigDecimal changeAmount = selectedPaymentTotal.subtract(requiredAmount);
if (!paymentTypes.contains("CASH")){
Debug.logError("Change Amount : " + changeAmount + " / No cash.", module);
- errMsg = UtilProperties.getMessage(resource, "checkhelper.change_returned_cannot_be_greater_than_cash", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkhelper.change_returned_cannot_be_greater_than_cash", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}else{
int cashIndex = paymentTypes.indexOf("CASH");
@@ -1505,7 +1505,7 @@
BigDecimal cashAmount = cart.getPaymentAmount(cashId);
if (cashAmount.compareTo(changeAmount) < 0){
Debug.logError("Change Amount : " + changeAmount + " / Cash Amount : " + cashAmount, module);
- errMsg = UtilProperties.getMessage(resource, "checkhelper.change_returned_cannot_be_greater_than_cash", (cart != null ? cart.getLocale() : Locale.getDefault()));
+ errMsg = UtilProperties.getMessage(resource_error, "checkhelper.change_returned_cannot_be_greater_than_cash", (cart != null ? cart.getLocale() : Locale.getDefault()));
return ServiceUtil.returnError(errMsg);
}
}
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartEvents.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartEvents.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartEvents.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartEvents.java Wed Jan 7 10:40:27 2009
@@ -193,7 +193,7 @@
if (UtilValidate.isEmpty(productId)) {
// before returning error; check make sure we aren't adding a special item type
if (UtilValidate.isEmpty(itemType)) {
- request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource, "cart.addToCart.noProductInfoPassed", locale));
+ request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource_error, "cart.addToCart.noProductInfoPassed", locale));
return "success"; // not critical return to same page
}
} else {
@@ -235,7 +235,7 @@
if (!configWrapper.isCompleted()) {
// The configuration is not valid
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage(resource, "cart.addToCart.configureProductBeforeAddingToCart", locale));
+ request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage(resource_error, "cart.addToCart.configureProductBeforeAddingToCart", locale));
return "product";
}
}
@@ -258,7 +258,7 @@
// check if features are selected
if (UtilValidate.isEmpty(selectedFeatures)) {
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource,"cart.addToCart.chooseVariationBeforeAddingToCart",locale));
+ request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource_error,"cart.addToCart.chooseVariationBeforeAddingToCart",locale));
return "product";
}
@@ -267,13 +267,13 @@
productId = variantProductId;
} else {
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource,"cart.addToCart.incompatibilityVariantFeature",locale));
+ request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource_error,"cart.addToCart.incompatibilityVariantFeature",locale));
return "product";
}
} else {
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource,"cart.addToCart.chooseVariationBeforeAddingToCart",locale));
+ request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource_error,"cart.addToCart.chooseVariationBeforeAddingToCart",locale));
return "product";
}
}
@@ -301,7 +301,7 @@
Debug.logWarning(e,"Problems parsing Reservation start string: "
+ reservStartStr, module);
reservStart = null;
- request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource,"cart.addToCart.rental.startDate", locale));
+ request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource_error,"cart.addToCart.rental.startDate", locale));
return "error";
}
}
@@ -318,7 +318,7 @@
} catch (Exception e) {
Debug.logWarning(e,"Problems parsing Reservation end string: " + reservEndStr, module);
reservEnd = null;
- request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource,"cart.addToCart.rental.endDate", locale));
+ request.setAttribute("_ERROR_MESSAGE_", UtilProperties.getMessage(resource_error,"cart.addToCart.rental.endDate", locale));
return "error";
}
}
@@ -359,7 +359,7 @@
//check for valid rental parameters
if (UtilValidate.isEmpty(reservStart) && UtilValidate.isEmpty(reservLength) && UtilValidate.isEmpty(reservPersons)) {
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage(resource, "cart.addToCart.enterBookingInforamtionBeforeAddingToCart", locale));
+ request.setAttribute("_EVENT_MESSAGE_", UtilProperties.getMessage(resource_error, "cart.addToCart.enterBookingInforamtionBeforeAddingToCart", locale));
return "product";
}
@@ -418,7 +418,7 @@
// check for required amount
if ((ProductWorker.isAmountRequired(delegator, productId)) && (amount == null || amount.doubleValue() == 0.0)) {
request.setAttribute("product_id", productId);
- request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource,"cart.addToCart.enterAmountBeforeAddingToCart",locale));
+ request.setAttribute("_EVENT_MESSAGE_",UtilProperties.getMessage(resource_error,"cart.addToCart.enterAmountBeforeAddingToCart",locale));
return "product";
}
@@ -709,7 +709,7 @@
Map messageMap = UtilMisc.toMap("totalQuantity", UtilFormatOut.formatQuantity(totalQuantity.doubleValue()) );
request.setAttribute("_EVENT_MESSAGE_",
- UtilProperties.getMessage(resource, "cart.add_category_defaults",
+ UtilProperties.getMessage(resource_error, "cart.add_category_defaults",
messageMap, locale ));
return "success";
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCartItem.java Wed Jan 7 10:40:27 2009
@@ -181,7 +181,7 @@
if (product == null) {
Map messageMap = UtilMisc.toMap("productId", productId );
- String excMsg = UtilProperties.getMessage(resource, "item.product_not_found",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.product_not_found",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -194,7 +194,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_virtual",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_virtual",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -209,7 +209,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_not_configured_correctly",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_not_configured_correctly",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -329,7 +329,7 @@
if (product == null) {
Map messageMap = UtilMisc.toMap("productId", productId );
- String excMsg = UtilProperties.getMessage(resource, "item.product_not_found", messageMap , cart.getLocale() );
+ String excMsg = UtilProperties.getMessage(resource_error, "item.product_not_found", messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
throw new ItemNotFoundException(excMsg);
@@ -419,7 +419,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_virtual",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_virtual",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -434,7 +434,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_not_yet_available",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_not_yet_available",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -446,7 +446,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_no_longer_available",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_no_longer_available",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -461,7 +461,7 @@
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_no_longer_available",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_no_longer_available",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
@@ -475,7 +475,7 @@
if (configWrapper == null || !configWrapper.isCompleted()) {
Map messageMap = UtilMisc.toMap("productName", product.getString("productName"),
"productId", product.getString("productId"));
- String excMsg = UtilProperties.getMessage(resource, "item.cannot_add_product_not_configured_correctly",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.cannot_add_product_not_configured_correctly",
messageMap , cart.getLocale() );
Debug.logWarning(excMsg, module);
throw new CartItemModifyException(excMsg);
@@ -486,20 +486,20 @@
// check to see if the product is a rental item
if ("ASSET_USAGE".equals(product.getString("productTypeId"))) {
if (reservStart == null) {
- String excMsg = UtilProperties.getMessage(resource, "item.missing_reservation_starting_date",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.missing_reservation_starting_date",
cart.getLocale() );
throw new CartItemModifyException(excMsg);
}
if (reservStart.before(UtilDateTime.nowTimestamp())) {
- String excMsg = UtilProperties.getMessage(resource, "item.reservation_from_tomorrow",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.reservation_from_tomorrow",
cart.getLocale() );
throw new CartItemModifyException(excMsg);
}
newItem.setReservStart(reservStart);
if (reservLength.compareTo(BigDecimal.ONE) < 0) {
- String excMsg = UtilProperties.getMessage(resource, "item.number_of_days",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.number_of_days",
cart.getLocale() );
throw new CartItemModifyException(excMsg);
}
@@ -510,7 +510,7 @@
if (reservMaxPersons.compareTo(reservPersons) < 0) {
Map messageMap = UtilMisc.toMap("reservMaxPersons", product.getString("reservMaxPersons"),
"reservPersons", reservPersons);
- String excMsg = UtilProperties.getMessage(resource, "item.maximum_number_of_person_renting",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.maximum_number_of_person_renting",
messageMap, cart.getLocale() );
Debug.logInfo(excMsg,module);
@@ -534,7 +534,7 @@
if(isAvailable.compareTo("OK") != 0) {
Map messageMap = UtilMisc.toMap("productId", product.getString("productId"),
"availableMessage", isAvailable);
- String excMsg = UtilProperties.getMessage(resource, "item.product_not_available",
+ String excMsg = UtilProperties.getMessage(resource_error, "item.product_not_available",
messageMap, cart.getLocale() );
Debug.logInfo(excMsg, module);
throw new CartItemModifyException(isAvailable);
@@ -854,7 +854,7 @@
selFixedAssetProduct = EntityUtil.filterByDate(allFixedAssetProduct, UtilDateTime.nowTimestamp(), "fromDate", "thruDate", true);
} catch (GenericEntityException e) {
Map messageMap = UtilMisc.toMap("productId", productId);
- String msg = UtilProperties.getMessage(resource, "item.cannot_find_Fixed_Asset", messageMap , cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.cannot_find_Fixed_Asset", messageMap , cart.getLocale());
return msg;
}
if (UtilValidate.isNotEmpty(selFixedAssetProduct)) {
@@ -862,7 +862,7 @@
fixedAssetProduct = (GenericValue) firstOne.next();
} else {
Map messageMap = UtilMisc.toMap("productId", productId);
- String msg = UtilProperties.getMessage(resource, "item.cannot_find_Fixed_Asset", messageMap , cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.cannot_find_Fixed_Asset", messageMap , cart.getLocale());
return msg;
}
@@ -872,12 +872,12 @@
fixedAsset = fixedAssetProduct.getRelatedOne("FixedAsset");
} catch (GenericEntityException e) {
Map messageMap = UtilMisc.toMap("fixedAssetId", fixedAssetProduct.getString("fixedAssetId"));
- String msg = UtilProperties.getMessage(resource, "item.fixed_Asset_not_found", messageMap , cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.fixed_Asset_not_found", messageMap , cart.getLocale());
return msg;
}
if (fixedAsset == null) {
Map messageMap = UtilMisc.toMap("fixedAssetId", fixedAssetProduct.getString("fixedAssetId"));
- String msg = UtilProperties.getMessage(resource, "item.fixed_Asset_not_found", messageMap , cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.fixed_Asset_not_found", messageMap , cart.getLocale());
return msg;
}
//Debug.logInfo("Checking availability for product: " + productId.toString() + " and related FixedAsset: " + fixedAssetProduct.getString("fixedAssetId"),module);
@@ -893,12 +893,12 @@
if(techDataCalendar == null) {
// no calendar ok, when not more that total capacity
if (fixedAsset.getBigDecimal("productionCapacity").compareTo(quantity) >= 0) {
- String msg = UtilProperties.getMessage(resource, "item.availableOk", cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.availableOk", cart.getLocale());
return msg;
} else {
Map messageMap = UtilMisc.toMap("quantityReq", quantity,
"quantityAvail", fixedAsset.getString("productionCapacity"));
- String msg = UtilProperties.getMessage(resource, "item.availableQnt", messageMap , cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.availableQnt", messageMap , cart.getLocale());
return msg;
}
}
@@ -943,12 +943,12 @@
}
}
if (resultMessage.compareTo("") == 0) {
- String msg = UtilProperties.getMessage(resource, "item.availableOk", cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.availableOk", cart.getLocale());
return msg;
}
else {
Map messageMap = UtilMisc.toMap("resultMessage", resultMessage);
- String msg = UtilProperties.getMessage(resource, "item.notAvailable", messageMap, cart.getLocale());
+ String msg = UtilProperties.getMessage(resource_error, "item.notAvailable", messageMap, cart.getLocale());
return msg;
}
}
Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppinglist/ShoppingListEvents.java Wed Jan 7 10:40:27 2009
@@ -64,7 +64,6 @@
public static final String module = ShoppingListEvents.class.getName();
public static final String resource = "OrderUiLabels";
- public static final String err_resource = "OrderErrorUiLabel";
public static final String resource_error = "OrderErrorUiLabels";
public static final String PERSISTANT_LIST_NAME = "auto-save";
@@ -95,7 +94,7 @@
String errMsg = null;
if (items == null || items.length == 0) {
- errMsg = UtilProperties.getMessage(resource, "shoppinglistevents.select_items_to_add_to_list", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error, "shoppinglistevents.select_items_to_add_to_list", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
@@ -106,7 +105,7 @@
newListResult = dispatcher.runSync("createShoppingList", UtilMisc.<String, Object>toMap("userLogin", userLogin, "productStoreId", cart.getProductStoreId(), "partyId", cart.getOrderPartyId(), "currencyUom", cart.getCurrency()));
} catch (GenericServiceException e) {
Debug.logError(e, "Problems creating new ShoppingList", module);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.cannot_create_new_shopping_list", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.cannot_create_new_shopping_list", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
@@ -122,7 +121,7 @@
// if no list was created throw an error
if (shoppingListId == null || shoppingListId.equals("")) {
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.shoppingListId_is_required_parameter", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.shoppingListId_is_required_parameter", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
} else if (!append) {
@@ -159,7 +158,7 @@
serviceResult = dispatcher.runSync("createShoppingListItem", ctx);
} catch (GenericServiceException e) {
Debug.logError(e, "Problems creating ShoppingList item entity", module);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.error_adding_item_to_shopping_list", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.error_adding_item_to_shopping_list", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
@@ -204,7 +203,7 @@
// no list; no add
if (shoppingListId == null) {
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.choose_shopping_list", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.choose_shopping_list", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
@@ -214,7 +213,7 @@
try {
shoppingList = delegator.findByPrimaryKey("ShoppingList", UtilMisc.toMap("shoppingListId", shoppingListId));
if (shoppingList == null) {
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.error_getting_shopping_list_and_items", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.error_getting_shopping_list_and_items", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
@@ -236,13 +235,13 @@
} catch (GenericEntityException e) {
Debug.logError(e, "Problems getting ShoppingList and ShoppingListItem records", module);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.error_getting_shopping_list_and_items", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.error_getting_shopping_list_and_items", cart.getLocale());
throw new IllegalArgumentException(errMsg);
}
// no items; not an error; just mention that nothing was added
if (shoppingListItems == null || shoppingListItems.size() == 0) {
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.no_items_added", cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.no_items_added", cart.getLocale());
return errMsg;
}
@@ -296,17 +295,17 @@
cart.addOrIncreaseItem(productId, null, quantity, reservStart, reservLength, reservPersons, null, null, null, null, null, attributes, prodCatalogId, configWrapper, null, null, null, dispatcher);
}
Map messageMap = UtilMisc.toMap("productId", productId);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.added_product_to_cart", messageMap, cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.added_product_to_cart", messageMap, cart.getLocale());
eventMessage.append(errMsg + "\n");
} catch (CartItemModifyException e) {
Debug.logWarning(e, UtilProperties.getMessage(resource_error,"OrderProblemsAddingItemFromListToCart", cart.getLocale()));
Map messageMap = UtilMisc.toMap("productId", productId);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.problem_adding_product_to_cart", messageMap, cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.problem_adding_product_to_cart", messageMap, cart.getLocale());
eventMessage.append(errMsg + "\n");
} catch (ItemNotFoundException e) {
Debug.logWarning(e, UtilProperties.getMessage(resource_error,"OrderProductNotFound", cart.getLocale()));
Map messageMap = UtilMisc.toMap("productId", productId);
- errMsg = UtilProperties.getMessage(resource,"shoppinglistevents.problem_adding_product_to_cart", messageMap, cart.getLocale());
+ errMsg = UtilProperties.getMessage(resource_error,"shoppinglistevents.problem_adding_product_to_cart", messageMap, cart.getLocale());
eventMessage.append(errMsg + "\n");
}
}
@@ -344,7 +343,7 @@
try {
result = dispatcher.runSync("updateShoppingListItem", serviceInMap);
} catch (GenericServiceException e) {
- String errMsg = UtilProperties.getMessage(ShoppingListEvents.err_resource,"shoppingListEvents.error_calling_update", locale) + ": " + e.toString();
+ String errMsg = UtilProperties.getMessage(resource_error,"shoppingListEvents.error_calling_update", locale) + ": " + e.toString();
request.setAttribute("_ERROR_MESSAGE_", errMsg);
String errorMsg = "Error calling the updateShoppingListItem in handleShoppingListItemVariant: " + e.toString();
Debug.logError(e, errorMsg, module);
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/associatedProducts.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/associatedProducts.ftl?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/associatedProducts.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/associatedProducts.ftl Wed Jan 7 10:40:27 2009
@@ -24,7 +24,7 @@
<#if associatedProducts?has_content>
<div class="screenlet">
<div class="screenlet-header">
- <div class="boxhead"> ${uiLabelMap.help_also_interested_in}</div>
+ <div class="boxhead"> ${uiLabelMap.OrderHelpAlsoInterestedIn}</div>
</div>
<div class="screenlet-body">
<table cellspacing="0" cellpadding="1" border="0">
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcart.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcart.ftl?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcart.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcart.ftl Wed Jan 7 10:40:27 2009
@@ -44,7 +44,7 @@
<td>
<div>
<input type="text" size="25" maxlength="30" name="itemDesiredDeliveryDate"<#if useAsDefaultDesiredDeliveryDate?exists> value="${defaultDesiredDeliveryDate}"</#if>/>
- <a href="javascript:call_cal(document.quickaddform.itemDesiredDeliveryDate,'${defaultDesiredDeliveryDate} 00:00:00.0');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.quickaddform.itemDesiredDeliveryDate,'${defaultDesiredDeliveryDate} 00:00:00.0');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
<input type="checkbox" name="useAsDefaultDesiredDeliveryDate" value="true"<#if useAsDefaultDesiredDeliveryDate?exists> checked="checked"</#if>/>
${uiLabelMap.OrderUseDefaultDesiredDeliveryDate}
</div>
@@ -55,7 +55,7 @@
<td>
<div>
<input type="text" size="20" maxlength="30" name="shipAfterDate" value="${shoppingCart.getDefaultShipAfterDate()?default("")}"/>
- <a href="javascript:call_cal(document.quickaddform.shipAfterDate,'${shoppingCart.getDefaultShipAfterDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.quickaddform.shipAfterDate,'${shoppingCart.getDefaultShipAfterDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
</div>
</td>
</tr>
@@ -64,7 +64,7 @@
<td>
<div>
<input type="text" size="20" maxlength="30" name="shipBeforeDate" value="${shoppingCart.getDefaultShipBeforeDate()?default("")}"/>
- <a href="javascript:call_cal(document.quickaddform.shipBeforeDate,'${shoppingCart.getDefaultShipBeforeDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.quickaddform.shipBeforeDate,'${shoppingCart.getDefaultShipBeforeDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
</div>
</td>
</tr>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcartitems.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcartitems.ftl?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcartitems.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/entry/cart/showcartitems.ftl Wed Jan 7 10:40:27 2009
@@ -179,7 +179,7 @@
<div>${uiLabelMap.OrderShipAfterDate}
<input type="text" size="20" maxlength="30" name="shipAfterDate_${cartLineIndex}"
value="${cartLine.getShipAfterDate()?default("")}"/>
- <a href="javascript:call_cal(document.cartform.shipAfterDate_${cartLineIndex},'${shoppingCart.getShipAfterDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.cartform.shipAfterDate_${cartLineIndex},'${shoppingCart.getShipAfterDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
</div>
</td>
<td> </td>
@@ -187,7 +187,7 @@
<div>${uiLabelMap.OrderShipBeforeDate}
<input type="text" size="20" maxlength="30" name="shipBeforeDate_${cartLineIndex}"
value="${cartLine.getShipBeforeDate()?default("")}"/>
- <a href="javascript:call_cal(document.cartform.shipBeforeDate_${cartLineIndex},'${shoppingCart.getShipBeforeDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.cartform.shipBeforeDate_${cartLineIndex},'${shoppingCart.getShipBeforeDate()?default("")}');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
</div>
</td>
</tr>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/order/appendorderitem.ftl
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/order/appendorderitem.ftl?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/order/appendorderitem.ftl (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/order/appendorderitem.ftl Wed Jan 7 10:40:27 2009
@@ -80,7 +80,7 @@
<td class="label">${uiLabelMap.OrderDesiredDeliveryDate}</td>
<td>
<input type="text" size="25" maxlength="30" name="itemDesiredDeliveryDate"/>
- <a href="javascript:call_cal(document.appendItemForm.itemDesiredDeliveryDate,'${toDayDate} 00:00:00.0');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.calendar_click_here_for_calendar}"/></a>
+ <a href="javascript:call_cal(document.appendItemForm.itemDesiredDeliveryDate,'${toDayDate} 00:00:00.0');"><img src="<@o...@ofbizContentUrl>" width="16" height="16" border="0" alt="${uiLabelMap.OrderCalendarClickHereForCalendar}"/></a>
</td>
</tr>
<tr>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/request/RequestForms.xml Wed Jan 7 10:40:27 2009
@@ -111,7 +111,7 @@
<field name="statusId">
<display-entity also-hidden="false" entity-name="StatusItem"/>
</field>
- <field name="addNote"><hyperlink description="addNote" target="requestitemnotes?custRequestId=${custRequestId}&custRequestItemSeqId=${custRequestItemSeqId}"/></field>
+ <field name="addNote"><hyperlink description="${uiLabelMap.FormFieldTitle_addNote}" target="requestitemnotes?custRequestId=${custRequestId}&custRequestItemSeqId=${custRequestItemSeqId}"/></field>
</form>
<form name="OverviewRequestItems" extends="ListRequestItems">
<field name="priority"><ignored/></field>
Modified: ofbiz/trunk/applications/order/webapp/ordermgr/return/ReturnForms.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/webapp/ordermgr/return/ReturnForms.xml?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/webapp/ordermgr/return/ReturnForms.xml (original)
+++ ofbiz/trunk/applications/order/webapp/ordermgr/return/ReturnForms.xml Wed Jan 7 10:40:27 2009
@@ -29,8 +29,8 @@
</actions>
<alt-target use-when="returnHeader==null" target="createReturn"/>
<auto-fields-service service-name="updateReturnHeader"/>
- <field use-when="returnHeader!=null" name="returnId" tooltip="This cannot be changed without re-creating the Return."><display/></field>
- <field use-when="returnHeader==null&&returnId!=null" name="returnId" tooltip="Could not find Return with ID [${returnId}]"><text size="20" maxlength="20"/></field>
+ <field use-when="returnHeader!=null" name="returnId" tooltip="${uiLabelMap.OrderReturnCannotBeChanged}"><display/></field>
+ <field use-when="returnHeader==null&&returnId!=null" name="returnId" tooltip="${uiLabelMap.OrderReturnCannotBeFound} ${returnId}"><text size="20" maxlength="20"/></field>
<field use-when="returnHeader==null&&returnId==null" name="returnId"><ignored/></field>
<field name="currentStatusId" entry-name="statusId"><hidden/></field>
<field name="returnHeaderTypeId" id-name="returnHeaderTypeId">
@@ -96,7 +96,7 @@
<field name="newCreditCard" widget-style="buttontext" use-when="returnHeader!=null&&returnHeader.getString("fromPartyId")!=null">
<hyperlink also-hidden="false" target="/partymgr/control/editcreditcard?partyId=${returnHeader.fromPartyId}${externalKeyParam}" target-window="partymgr" description="${uiLabelMap.AccountingCreateNewCreditCard}" target-type="inter-app"/>
</field>
- <field name="needsInventoryReceive" tooltip="If this is Y then the return will be automatically Completed when it is Accepted, skipping the Received status and process.">
+ <field name="needsInventoryReceive" tooltip="${uiLabelMap.OrderReturnNecessaryReceiveInventoryMessage}">
<drop-down no-current-selected-key="N"><option key="N"/><option key="Y"/></drop-down>
</field>
<field name="createdBy"><display/></field>
Modified: ofbiz/trunk/applications/order/widget/ordermgr/RequestMenus.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/widget/ordermgr/RequestMenus.xml?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/widget/ordermgr/RequestMenus.xml (original)
+++ ofbiz/trunk/applications/order/widget/ordermgr/RequestMenus.xml Wed Jan 7 10:40:27 2009
@@ -22,19 +22,19 @@
xsi:noNamespaceSchemaLocation="http://ofbiz.apache.org/dtds/widget-menu.xsd">
<menu name="RequestTabBar" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
- <menu-item name="ViewRequest" title="Overview" >
+ <menu-item name="ViewRequest" title="${uiLabelMap.OrderRequestOverview}">
<link target="ViewRequest?custRequestId=${custRequest.custRequestId}"/>
</menu-item>
- <menu-item name="request" title="Request" >
+ <menu-item name="request" title="${uiLabelMap.OrderRequest}">
<link target="request?custRequestId=${custRequest.custRequestId}"/>
</menu-item>
- <menu-item name="requestroles" title="Request Roles" >
+ <menu-item name="requestroles" title="${uiLabelMap.OrderRequestRoles}">
<link target="requestroles?custRequestId=${custRequest.custRequestId}"/>
</menu-item>
- <menu-item name="requestitems" title="Request Items" >
+ <menu-item name="requestitems" title="${uiLabelMap.OrderRequestItems}">
<link target="/requestitems?custRequestId=${custRequest.custRequestId}"/>
</menu-item>
- <menu-item name="custRequestContent" title="Content">
+ <menu-item name="custRequestContent" title="${uiLabelMap.OrderRequestContent}">
<condition>
<and>
<not><if-empty field-name="custRequest"/></not>
@@ -51,22 +51,22 @@
<menu-item name="newRequest" title="${uiLabelMap.OrderNewRequest}">
<link target="request"/>
</menu-item>
- <menu-item name="createQuoteFromRequest" title="Create Quote from request" >
+ <menu-item name="createQuoteFromRequest" title="${uiLabelMap.OrderCreateQuoteFromRequest}">
<link target="createQuoteFromCustRequest?custRequestId=${custRequest.custRequestId}"/>
</menu-item>
</menu>
<menu name="editrequestitemmenu" extends="CommonTabBarMenu" extends-resource="component://common/widget/CommonMenus.xml">
- <menu-item name="requestitem">
+ <menu-item name="requestitem" title="${uiLabelMap.OrderRequestItem}">
<link id="requestitem" target="requestitem?custRequestId=${custRequest.custRequestId}&custRequestItemSeqId=${custRequestItem.custRequestItemSeqId}"/>
</menu-item>
- <menu-item name="requestitemnotes" title="Request Item Notes" >
+ <menu-item name="requestitemnotes" title="${uiLabelMap.OrderRequestItemNotes}">
<link id="requestitemnotes" target="requestitemnotes?custRequestId=${custRequest.custRequestId}&custRequestItemSeqId=${custRequestItem.custRequestItemSeqId}"/>
</menu-item>
- <menu-item name="requestitemquotes" title="Request Item Quotes" >
+ <menu-item name="requestitemquotes" title="${uiLabelMap.OrderRequestItemQuotes}">
<link id="requestitemquotes" target="RequestItemQuotes?custRequestId=${custRequest.custRequestId}&custRequestItemSeqId=${custRequestItem.custRequestItemSeqId}"/>
</menu-item>
- <menu-item name="workeffortrequirements" title="WorkEffort Requirements" >
+ <menu-item name="workeffortrequirements" title="${uiLabelMap.OrderRequestItemWorkEffort}">
<link id="workeffortrequirements" target="requestitemrequirements?custRequestId=${custRequest.custRequestId}&custRequestItemSeqId=${custRequestItem.custRequestItemSeqId}"/>
</menu-item>
</menu>
Modified: ofbiz/trunk/applications/party/config/PartyUiLabels.xml
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/config/PartyUiLabels.xml?rev=732423&r1=732422&r2=732423&view=diff
==============================================================================
--- ofbiz/trunk/applications/party/config/PartyUiLabels.xml (original)
+++ ofbiz/trunk/applications/party/config/PartyUiLabels.xml Wed Jan 7 10:40:27 2009
@@ -229,6 +229,10 @@
<value xml:lang="en">Delete email</value>
<value xml:lang="it">Cancella email</value>
</property>
+ <property key="FormFieldTitle_destinationFacilityId">
+ <value xml:lang="en">Destination Facility Id</value>
+ <value xml:lang="it">Stabilimento destinazione</value>
+ </property>
<property key="FormFieldTitle_disabledDateTime">
<value xml:lang="de">Ausgeschaltet Zeitpunkt</value>
<value xml:lang="en">Disabled Date Time</value>
@@ -672,6 +676,10 @@
<value xml:lang="nl">Oorsprong communicatie-actie</value>
<value xml:lang="th">รหัสà¸à¸²à¸£à¸à¸´à¸à¸à¹à¸à¹à¸à¸´à¸¡</value>
</property>
+ <property key="FormFieldTitle_originContactMechId">
+ <value xml:lang="en">Origin Contact Mech Id</value>
+ <value xml:lang="it">Contatto origine</value>
+ </property>
<property key="FormFieldTitle_otherLocal">
<value xml:lang="en">Other Local</value>
<value xml:lang="es">Otro local</value>
@@ -996,6 +1004,10 @@
<value xml:lang="th">รหัสà¸à¸£à¸°à¹à¸ à¸à¸ªà¸à¸²à¸à¸°à¸à¸¶à¸</value>
<value xml:lang="zh">è§è²ç±»åæ è¯å°</value>
</property>
+ <property key="FormFieldTitle_roleTypeList">
+ <value xml:lang="en">Role Type List</value>
+ <value xml:lang="it">Lista tipo ruolo</value>
+ </property>
<property key="FormFieldTitle_salutation">
<value xml:lang="de">Anrede</value>
<value xml:lang="en">Salutation</value>
@@ -1104,6 +1116,10 @@
<value xml:lang="nl">T.a.v.</value>
<value xml:lang="th">à¸à¸¶à¸à¸à¸·à¹à¸</value>
</property>
+ <property key="FormFieldTitle_toPartyId">
+ <value xml:lang="en">To Party Id</value>
+ <value xml:lang="it">Al soggetto</value>
+ </property>
<property key="FormFieldTitle_totalInvoiceNotApplied">
<value xml:lang="en">Total Invoice Not Applied</value>
<value xml:lang="fr">Total des factures non allouées</value>