Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoFinAccountData.xml
URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoFinAccountData.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoFinAccountData.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoFinAccountData.xml Mon Sep 22 08:09:27 2014 @@ -33,7 +33,7 @@ under the License. organizationPartyId="Company" ownerPartyId="Company" postToGlAccountId="231000" isRefundable="Y" replenishLevel="0.00" actualBalance="0.00" availableBalance="0.00"/> <FinAccountStatus finAccountId="AMEX_01" statusId="FNACT_ACTIVE" statusDate="2009-04-01 00:00:01.000"/> <PaymentMethod paymentMethodId="AMEX_01" paymentMethodTypeId="CREDIT_CARD" partyId="Company" description="AmEx 0005" glAccountId="231000" finAccountId="AMEX_01" fromDate="2009-04-01 00:00:00.000"/> - <CreditCard paymentMethodId="AMEX_01" cardType="AmericanExpress" cardNumber="378282246310005" expireDate="02/2020" companyNameOnCard="Your Company Name" + <CreditCard paymentMethodId="AMEX_01" cardType="CCT_AMERICANEXPRESS" cardNumber="378282246310005" expireDate="02/2020" companyNameOnCard="Your Company Name" titleOnCard="" firstNameOnCard="Smart" middleNameOnCard="" lastNameOnCard="Guy" suffixOnCard="" contactMechId="9000"/> <PaymentMethod paymentMethodId="PETTY_CASH" paymentMethodTypeId="CASH" partyId="Company" description="Petty Cash" glAccountId="110000" fromDate="2009-04-01 00:00:00.000"/> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoGlSetupData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoGlSetupData.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoGlSetupData.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/data/DemoGlSetupData.xml Mon Sep 22 08:09:27 2014 @@ -364,12 +364,6 @@ under the License. <CreditCardTypeGlAccount organizationPartyId="Company" cardType="CCT_VISA" glAccountId="122300"/> <CreditCardTypeGlAccount organizationPartyId="Company" cardType="CCT_MASTERCARD" glAccountId="122300"/> - <!-- The following ones are required until the issue OFBIZ-1524 is resolved --> - <CreditCardTypeGlAccount organizationPartyId="Company" cardType="AmericanExpress" glAccountId="122100"/> - <CreditCardTypeGlAccount organizationPartyId="Company" cardType="DinersClub" glAccountId="122100"/> - <CreditCardTypeGlAccount organizationPartyId="Company" cardType="Discover" glAccountId="122200"/> - <CreditCardTypeGlAccount organizationPartyId="Company" cardType="Visa" glAccountId="122300"/> - <CreditCardTypeGlAccount organizationPartyId="Company" cardType="MasterCard" glAccountId="122300"/> <!-- No need to load these if they are set with the 122000 account (the default for the CREDIT_CARD payment method type) <CreditCardTypeGlAccount organizationPartyId="Company" cardType="CCT_ENROUTE" glAccountId="122000"/> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceWorker.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceWorker.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/invoice/InvoiceWorker.java Mon Sep 22 08:09:27 2014 @@ -299,16 +299,20 @@ public class InvoiceWorker { if (invoice.getString("invoiceTypeId").equals("PURCHASE_INVOICE")) destinationPartyId = invoice.getString("partyId"); try { - locations = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", destinationPartyId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false)); + locations = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", destinationPartyId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); + locations = EntityUtil.filterByDate(locations, null, "contactFromDate", "contactThruDate", true); + locations = EntityUtil.filterByDate(locations, null, "purposeFromDate", "purposeThruDate", true); } catch (GenericEntityException e) { Debug.logError("Trouble getting contact party purpose list", module); } //if still not found get it from the general location if (UtilValidate.isEmpty(locations)) { try { - locations = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", destinationPartyId, "contactMechPurposeTypeId", "GENERAL_LOCATION"), null, false)); + locations = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", destinationPartyId, "contactMechPurposeTypeId", "GENERAL_LOCATION"), null, false); + locations = EntityUtil.filterByDate(locations, null, "contactFromDate", "contactThruDate", true); + locations = EntityUtil.filterByDate(locations, null, "purposeFromDate", "purposeThruDate", true); } catch (GenericEntityException e) { Debug.logError("Trouble getting contact party purpose list", module); } Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentGatewayServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentGatewayServices.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentGatewayServices.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentGatewayServices.java Mon Sep 22 08:09:27 2014 @@ -2868,13 +2868,13 @@ public class PaymentGatewayServices { if (creditCard != null) { String cardType = creditCard.getString("cardType"); // add more types as necessary -- maybe we should create seed data for credit card types?? - if ("Discover".equals(cardType)) { + if ("CCT_DISCOVER".equals(cardType)) { reauthDays = UtilProperties.getPropertyValue(paymentConfig, "payment.general.reauth.disc.days", "90"); - } else if ("AmericanExpress".equals(cardType)) { + } else if ("CCT_AMERICANEXPRESS".equals(cardType)) { reauthDays = UtilProperties.getPropertyValue(paymentConfig, "payment.general.reauth.amex.days", "30"); - } else if ("MasterCard".equals(cardType)) { + } else if ("CCT_MASTERCARD".equals(cardType)) { reauthDays = UtilProperties.getPropertyValue(paymentConfig, "payment.general.reauth.mc.days", "30"); - } else if ("Visa".equals(cardType)) { + } else if ("CCT_VISA".equals(cardType)) { reauthDays = UtilProperties.getPropertyValue(paymentConfig, "payment.general.reauth.visa.days", "7"); } else { reauthDays = UtilProperties.getPropertyValue(paymentConfig, "payment.general.reauth.other.days", "7"); Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentMethodServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentMethodServices.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentMethodServices.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentMethodServices.java Mon Sep 22 08:09:27 2014 @@ -213,10 +213,11 @@ public class PaymentMethodServices { GenericValue tempVal = null; try { - List<GenericValue> allPCMPs = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false), true); - - tempVal = EntityUtil.getFirst(allPCMPs); + List<GenericValue> allPCWPs = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "contactFromDate", "contactThruDate", true); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "purposeFromDate", "purposeThruDate", true); + tempVal = EntityUtil.getFirst(allPCWPs); } catch (GenericEntityException e) { Debug.logWarning(e.getMessage(), module); tempVal = null; @@ -387,10 +388,12 @@ public class PaymentMethodServices { GenericValue tempVal = null; try { - List<GenericValue> allPCMPs = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false), true); + List<GenericValue> allPCWPs = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "contactFromDate", "contactThruDate", true); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "purposeFromDate", "purposeThruDate", true); - tempVal = EntityUtil.getFirst(allPCMPs); + tempVal = EntityUtil.getFirst(allPCWPs); } catch (GenericEntityException e) { Debug.logWarning(e.getMessage(), module); tempVal = null; @@ -726,11 +729,12 @@ public class PaymentMethodServices { GenericValue tempVal = null; try { - List<GenericValue> allPCMPs = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, - "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false), true); + List<GenericValue> allPCWPs = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "contactFromDate", "contactThruDate", true); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "purposeFromDate", "purposeThruDate", true); - tempVal = EntityUtil.getFirst(allPCMPs); + tempVal = EntityUtil.getFirst(allPCWPs); } catch (GenericEntityException e) { Debug.logWarning(e.getMessage(), module); tempVal = null; @@ -854,10 +858,11 @@ public class PaymentMethodServices { GenericValue tempVal = null; try { - List<GenericValue> allPCMPs = EntityUtil.filterByDate(delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, - "contactMechPurposeTypeId",contactMechPurposeTypeId), null, false), true); - tempVal = EntityUtil.getFirst(allPCMPs); + List<GenericValue> allPCWPs = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", partyId, "contactMechId", contactMechId, "contactMechPurposeTypeId", contactMechPurposeTypeId), null, false); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "contactFromDate", "contactThruDate", true); + allPCWPs = EntityUtil.filterByDate(allPCWPs, null, "purposeFromDate", "purposeThruDate", true); + tempVal = EntityUtil.getFirst(allPCWPs); } catch (GenericEntityException e) { Debug.logWarning(e.getMessage(), module); tempVal = null; Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentWorker.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentWorker.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentWorker.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/payment/PaymentWorker.java Mon Sep 22 08:09:27 2014 @@ -158,12 +158,13 @@ public class PaymentWorker { public static GenericValue getPaymentAddress(Delegator delegator, String partyId) { List<GenericValue> paymentAddresses = null; try { - paymentAddresses = delegator.findByAnd("PartyContactMechPurpose", - UtilMisc.toMap("partyId", partyId, "contactMechPurposeTypeId", "PAYMENT_LOCATION"), - UtilMisc.toList("-fromDate"), false); - paymentAddresses = EntityUtil.filterByDate(paymentAddresses); + paymentAddresses = delegator.findByAnd("PartyContactWithPurpose", + UtilMisc.toMap("partyId", partyId, "contactMechPurposeTypeId", "PAYMENT_LOCATION"), + UtilMisc.toList("-fromDate"), false); + paymentAddresses = EntityUtil.filterByDate(paymentAddresses, null, "contactFromDate", "contactThruDate", true); + paymentAddresses = EntityUtil.filterByDate(paymentAddresses, null, "purposeFromDate", "purposeThruDate", true); } catch (GenericEntityException e) { - Debug.logError(e, "Trouble getting PartyContactMechPurpose entity list", module); + Debug.logError(e, "Trouble getting PartyContactWithPurpose view entity list", module); } // get the address for the primary contact mech Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/authorizedotnet/AIMPaymentServices.java Mon Sep 22 08:09:27 2014 @@ -810,12 +810,12 @@ public class AIMPaymentServices { } private static String getCardType(String cardType) { - if ((cardType.equalsIgnoreCase("VISA"))) return "V"; - if ((cardType.equalsIgnoreCase("MASTERCARD"))) return "M"; - if (((cardType.equalsIgnoreCase("AMERICANEXPRESS")) || (cardType.equalsIgnoreCase("AMEX")))) return "A"; - if ((cardType.equalsIgnoreCase("DISCOVER"))) return "D"; - if ((cardType.equalsIgnoreCase("JCB"))) return "J"; - if (((cardType.equalsIgnoreCase("DINERSCLUB")))) return "C"; + if (("CCT_VISA".equalsIgnoreCase(cardType))) return "V"; + if (("CCT_MASTERCARD".equalsIgnoreCase(cardType))) return "M"; + if ((("CCT_AMERICANEXPRESS".equalsIgnoreCase(cardType)) || ("CCT_AMEX".equalsIgnoreCase(cardType)))) return "A"; + if (("CCT_DISCOVER".equalsIgnoreCase(cardType))) return "D"; + if (("CCT_JCB".equalsIgnoreCase(cardType))) return "J"; + if ((("CCT_DINERSCLUB".equalsIgnoreCase(cardType)))) return "C"; return ""; } Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCServicesTest.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCServicesTest.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCServicesTest.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/clearcommerce/CCServicesTest.java Mon Sep 22 08:09:27 2014 @@ -56,7 +56,7 @@ public class CCServicesTest extends OFBi creditAmount = new BigDecimal("234.00"); emailAddr = delegator.makeValue("ContactMech", UtilMisc.toMap("infoString","[hidden email]")); orderId = "testOrder1000"; - creditCard = delegator.makeValue("CreditCard", UtilMisc.toMap("cardType","VISA", + creditCard = delegator.makeValue("CreditCard", UtilMisc.toMap("cardType","CCT_VISA", "expireDate","12/2008", // mm/yyyy, gets converted to mm/yy "cardNumber","4111111111111111")); billingAddress = delegator.makeValue("PostalAddress", UtilMisc.toMap("toName","The customer Name", Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/sagepay/SagePayPaymentServices.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/sagepay/SagePayPaymentServices.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/sagepay/SagePayPaymentServices.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/sagepay/SagePayPaymentServices.java Mon Sep 22 08:09:27 2014 @@ -99,16 +99,16 @@ public class SagePayPaymentServices { nameOnCard = firstName + " " + middleName + " " + lastName; cardType = creditCard.getString("cardType"); if (cardType != null) { - if (cardType.equals("MasterCard")) { + if ("CCT_MASTERCARD".equals(cardType)) { cardType = "MC"; } - if (cardType.equals("VisaElectron")) { + if ("CCT_VISAELECTRON".equals(cardType)) { cardType = "UKE"; } - if (cardType.equals("DinersClub")) { + if ("CCT_DINERSCLUB".equals(cardType)) { cardType = "DC"; } - if (cardType.equals("Switch")) { + if ("CCT_SWITCH".equals(cardType)) { cardType = "MAESTRO"; } } Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/securepay/SecurePayServiceTest.java URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/securepay/SecurePayServiceTest.java?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/securepay/SecurePayServiceTest.java (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/src/org/ofbiz/accounting/thirdparty/securepay/SecurePayServiceTest.java Mon Sep 22 08:09:27 2014 @@ -67,7 +67,7 @@ public class SecurePayServiceTest extend "infoString","[hidden email]")); orderId = "Demo1002"; creditCard = delegator.makeValue("CreditCard", UtilMisc.toMap( - "cardType","VISA", + "cardType","CCT_VISA", "expireDate","10/2011", // mm/yyyy, gets converted to mm/yy "cardNumber","4444333322221111")); billingAddress = delegator.makeValue("PostalAddress", UtilMisc.toMap( Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/webapp/accounting/WEB-INF/actions/invoice/GetAccountOrganizationAndClass.groovy URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/webapp/accounting/WEB-INF/actions/invoice/GetAccountOrganizationAndClass.groovy?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/webapp/accounting/WEB-INF/actions/invoice/GetAccountOrganizationAndClass.groovy (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/webapp/accounting/WEB-INF/actions/invoice/GetAccountOrganizationAndClass.groovy Mon Sep 22 08:09:27 2014 @@ -33,13 +33,14 @@ if (!invoice) return; glAccountOrganizationAndClassList = null; if ("SALES_INVOICE".equals(invoice.invoiceTypeId)) { itemTypesCond = exprBldr.OR() { - EQUALS(invoiceItemTypeId: "INVOICE_ADJ") - EQUALS(parentTypeId: "INVOICE_ADJ") - EQUALS(invoiceItemTypeId: "INVOICE_ITM_ADJ") - EQUALS(parentTypeId: "INVOICE_ITM_ADJ") + EQUALS(invoiceItemTypeId: "SINVOICE_ADJ") + EQUALS(parentTypeId: "SINVOICE_ADJ") + EQUALS(invoiceItemTypeId: "SINVOICE_ITM_ADJ") + EQUALS(parentTypeId: "SINVOICE_ITM_ADJ") EQUALS(invoiceItemTypeId: "INV_PROD_ITEM") EQUALS(parentTypeId: "INV_PROD_ITEM") } + invoiceItemTypes = delegator.findList("InvoiceItemType", itemTypesCond, null, ["parentTypeId", "invoiceItemTypeId"], null, false); glAccountOrganizationAndClassList = delegator.findByAnd("GlAccountOrganizationAndClass", [organizationPartyId : invoice.partyIdFrom], null, false); } else if ("PURCHASE_INVOICE".equals(invoice.invoiceTypeId)) { itemTypesCond = exprBldr.OR() { @@ -50,6 +51,7 @@ if ("SALES_INVOICE".equals(invoice.invoi EQUALS(invoiceItemTypeId: "PINV_PROD_ITEM") EQUALS(parentTypeId: "PINV_PROD_ITEM") } + invoiceItemTypes = delegator.findList("InvoiceItemType", itemTypesCond, null, ["parentTypeId", "invoiceItemTypeId"], null, false); glAccountOrganizationAndClassList = delegator.findByAnd("GlAccountOrganizationAndClass", [organizationPartyId : invoice.partyId], null, false); } else if ("PAYROL_INVOICE".equals(invoice.invoiceTypeId)) { itemTypesCond = exprBldr.OR() { @@ -60,6 +62,7 @@ if ("SALES_INVOICE".equals(invoice.invoi EQUALS(invoiceItemTypeId: "PAYROL_TAXES") EQUALS(parentTypeId: "PAYROL_TAXES") } + invoiceItemTypes = delegator.findList("InvoiceItemType", itemTypesCond, null, ["parentTypeId", "invoiceItemTypeId"], null, false); glAccountOrganizationAndClassList = delegator.findByAnd("GlAccountOrganizationAndClass", [organizationPartyId : invoice.partyId], null, false); } else if ("COMMISSION_INVOICE".equals(invoice.invoiceTypeId)) { itemTypesCond = exprBldr.OR() { @@ -68,6 +71,12 @@ if ("SALES_INVOICE".equals(invoice.invoi EQUALS(invoiceItemTypeId: "COMM_INV_ADJ") EQUALS(parentTypeId: "COMM_INV_ADJ") } + invoiceItemTypes = delegator.findList("InvoiceItemType", itemTypesCond, null, ["parentTypeId", "invoiceItemTypeId"], null, false); glAccountOrganizationAndClassList = delegator.findByAnd("GlAccountOrganizationAndClass", [organizationPartyId : invoice.partyId], null, false); +} else { + map = delegator.findByAnd("InvoiceItemTypeMap", [invoiceTypeId : invoice.invoiceTypeId], null, true); + invoiceItemTypes = EntityUtil.getRelated("InvoiceItemType", map, null, false); } +context.invoiceItemTypes = invoiceItemTypes; + context.glAccountOrganizationAndClassList = glAccountOrganizationAndClassList; Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceForms.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceForms.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceForms.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceForms.xml Mon Sep 22 08:09:27 2014 @@ -364,7 +364,7 @@ under the License. <field name="quantity"><text size="10"/></field> <field name="invoiceItemTypeId"> <drop-down allow-empty="false"> - <entity-options entity-name="InvoiceItemType" description="${description}" key-field-name="invoiceItemTypeId"/> + <list-options list-name="invoiceItemTypes" key-name="invoiceItemTypeId" description="${description}"/> </drop-down> </field> <field name="productId"><lookup target-form-name="LookupProduct" size="20"/></field> @@ -392,7 +392,7 @@ under the License. <field name="invoiceId"><hidden/></field> <field position="1" name="invoiceItemTypeId"> <drop-down allow-empty="false"> - <entity-options entity-name="InvoiceItemType" description="${description}" key-field-name="invoiceItemTypeId"/> + <list-options list-name="invoiceItemTypes" key-name="invoiceItemTypeId" description="${description}"/> </drop-down> </field> <field position="1" name="description"><text size="80"/></field> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceScreens.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceScreens.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceScreens.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/accounting/widget/InvoiceScreens.xml Mon Sep 22 08:09:27 2014 @@ -206,6 +206,11 @@ under the License. <decorator-section name="body"> <section> <condition> + <not><if-empty field="invoice"/></not> + </condition> + <widgets> + <section> + <condition> <if-compare field="invoice.statusId" operator="equals" value="INVOICE_IN_PROCESS"/> </condition> <widgets> @@ -305,6 +310,11 @@ under the License. <include-form name="AcctgTransAndEntries" location="component://accounting/widget/InvoiceForms.xml"/> </screenlet> </fail-widgets> + </section> + </widgets> + <fail-widgets> + <label text="${uiLabelMap.AccountingInvoiceDoesNotExists}"></label> + </fail-widgets> </section> </decorator-section> </decorator-screen> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/CommonExtUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/CommonExtUiLabels.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/CommonExtUiLabels.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/CommonExtUiLabels.xml Mon Sep 22 08:09:27 2014 @@ -28,6 +28,7 @@ <value xml:lang="pt_BR">Criar Mensagem Pública</value> <value xml:lang="vi">Tạo thông Äiá»p công khai</value> <value xml:lang="zh">æ°å»ºå ¬å ±æ¶æ¯</value> + <value xml:lang="zh_TW">æ°å»ºå ¬å ±è¨æ¯</value> </property> <property key="CommonExtDateInfoCreated"> <value xml:lang="de">Datum Info erzeugt</value> @@ -38,9 +39,10 @@ <value xml:lang="pt_BR">Data da informação criada</value> <value xml:lang="vi">Ngà y tạo thông tin</value> <value xml:lang="zh">å·²åå»ºæ¥æä¿¡æ¯</value> + <value xml:lang="zh_TW">å·²æ°å»ºæ¥æè³è¨</value> </property> <property key="CommonExtDateLastChanged"> - <value xml:lang="de">Datum Letzte Ãnderung</value> + <value xml:lang="de">Datum Letzte Ãnderung</value> <value xml:lang="en">Date Last Changed</value> <value xml:lang="fr">Dernière date de changement</value> <value xml:lang="it">Data ultimo cambiamento</value> @@ -48,6 +50,7 @@ <value xml:lang="pt_BR">Data da última modificação</value> <value xml:lang="vi">Ngà y thay Äá»i thông tin</value> <value xml:lang="zh">æåä¿®æ¹æ¥æ</value> + <value xml:lang="zh_TW">æå¾ä¿®æ¹æ¥æ</value> </property> <property key="CommonExtSystemInfoNote"> <value xml:lang="de">Systemnachricht</value> @@ -58,9 +61,10 @@ <value xml:lang="pt_BR">Nota de Informação do Sistema</value> <value xml:lang="vi">Thông tin lưu ý mức há» thá»ng</value> <value xml:lang="zh">ç³»ç»ä¿¡æ¯ä¾¿ç¬º</value> + <value xml:lang="zh_TW">系統è³è¨ä¾¿ç®</value> </property> <property key="CommonExtSystemInfoNoteForUser"> - <value xml:lang="de">Systemnachricht für Benutzer:</value> + <value xml:lang="de">Systemnachricht für Benutzer:</value> <value xml:lang="en">System Info note for user:</value> <value xml:lang="fr">Message d'information système pour l'utilisateur :</value> <value xml:lang="it">Messaggio di sistema per l'utente:</value> @@ -68,9 +72,10 @@ <value xml:lang="pt_BR">Nota de Informação do Sistema para o usuário:</value> <value xml:lang="vi">Thông tin lưu ý mức há» thá»ng tá»i Ngưá»i dùng:</value> <value xml:lang="zh">ç³»ç»ä¿¡æ¯ä¾¿ç¬ºè´ç¨æ·ï¼</value> + <value xml:lang="zh_TW">系統è³è¨ä¾¿ç®è´ä½¿ç¨è :</value> </property> <property key="CommonExtSystemInfoStatus"> - <value xml:lang="de">System Information Status</value> + <value xml:lang="de">System Information Status</value> <value xml:lang="en">System Info Status</value> <value xml:lang="fr">Message d'information d'état</value> <value xml:lang="it">Stato messaggi di sistema</value> @@ -78,9 +83,10 @@ <value xml:lang="pt_BR">Informação de estado do sistema</value> <value xml:lang="vi">Trạng thái mức há» thá»ng</value> <value xml:lang="zh">ç³»ç»ä¿¡æ¯ç¶æ</value> + <value xml:lang="zh_TW">系統è³è¨çæ </value> </property> <property key="CommonExtSystemInfoStatusForUser"> - <value xml:lang="de">System Information Status für Benutzer:</value> + <value xml:lang="de">System Information Status für Benutzer:</value> <value xml:lang="en">System Info status for user:</value> <value xml:lang="fr">Message d'information d'état pour l'utilisateur :</value> <value xml:lang="it">Stato messaggi di sistema per l'utente:</value> @@ -88,5 +94,6 @@ <value xml:lang="pt_BR">Informação de estado do sistema para o usuário:</value> <value xml:lang="vi">Trạng thái mức há» thá»ng tá»i Ngưá»i dùng:</value> <value xml:lang="zh">ç³»ç»ä¿¡æ¯ç¶æä¸ºç¨æ·ï¼</value> + <value xml:lang="zh_TW">系統è³è¨çæ çºä½¿ç¨è :</value> </property> </resource> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/SetupUiLabels.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/SetupUiLabels.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/SetupUiLabels.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/config/SetupUiLabels.xml Mon Sep 22 08:09:27 2014 @@ -57,27 +57,27 @@ <value xml:lang="zh_TW">OFBiz: è¨ç½®æç¨ç¨å¼</value> </property> <property key="SetupCompanySubtitle"> - <!--value xml:lang="ar">جزء Ù Ù Ø¹Ø§Ø¦ÙØ© Ø£ÙÙØ¨Ùز ÙÙØ¨Ø±Ù Ø¬ÙØ§Øª Ø§ÙØØ±Ø©</value--> + <!--value xml:lang="ar">جزء Ù Ù Ø¹Ø§Ø¦ÙØ© Ø£ÙÙØ¨Ùز ÙÙØ¨Ø±Ù Ø¬ÙØ§Øª Ø§ÙØØ±Ø©</value--> <value xml:lang="ar">جزء Ù Ù Ø¹Ø§Ø¦ÙØ© Ø£ÙÙØ¨Ùز ÙÙØªØ·Ø¨ÙÙØ§Øª Ø§ÙØØ±Ø© ÙÙØªØ³ÙÙØ±</value> <value xml:lang="de">Teil der Open For Business Familie von Open Source Software</value> <value xml:lang="en">Part of the Open For Business Family of Open Source Software</value> - <!--value xml:lang="es">Parte de la familia "Open for Bussiness" de Software Libre</value--> + <!--value xml:lang="es">Parte de la familia "Open for Bussiness" de Software Libre</value--> <value xml:lang="es">Parte de la familia de software Open For Business de código abierto</value> <value xml:lang="fr">Un module de la famille Open For Business, logiciel libre de gestion d'entreprise.</value> <value xml:lang="it">Un modulo della famiglia di software open source Open For Business</value> - <!--value xml:lang="nl">Onderdeel van de Open For Business'-suite</value--> + <!--value xml:lang="nl">Onderdeel van de Open For Business'-suite</value--> <value xml:lang="ja">Part of the Open For Business Family of Open Source Software</value> <value xml:lang="nl">Deel van de Open For Business-suite van Open Source Software</value> <value xml:lang="pt_BR">Parte da famÃlia OfBiz de software de fonte aberta</value> - <!--value xml:lang="pt_PT">Parte do Software de Fonte Aberta para Grupos Abertos Para o Negócio</value--> + <!--value xml:lang="pt-PT">Parte do Software de Fonte Aberta para Grupos Abertos Para o Negócio</value--> <value xml:lang="pt_PT">Parte da famÃlia OfBiz de software de fonte aberta</value> - <!--value xml:lang="ro">Parte accesibila pentru Business Family of Open Source Software</valuevalue xml:lang="ro">Parte din Open for Business Family of Open Source Software</value--> + <!--value xml:lang="ro">Parte accesibila pentru Business Family of Open Source Software</valuevalue xml:lang="ro">Parte din Open for Business Family of Open Source Software</value--> <value xml:lang="ro">Partea de Deschidere Pentru Afaceri Familiale din Open Source Software</value> - <!--value xml:lang="ru">ЧаÑÑÑ ÑемейÑÑва ÐÐ Open For Business</valuevalue xml:lang="ru">ЧаÑÑÑ ÑемейÑÑва "Open For Business Family" пÑогÑаммнÑÑ Ð¿ÑодÑкÑов Open Source </value--> + <!--value xml:lang="ru">ЧаÑÑÑ ÑемейÑÑва ÐÐ Open For Business</valuevalue xml:lang="ru">ЧаÑÑÑ ÑемейÑÑва "Open For Business Family" пÑогÑаммнÑÑ Ð¿ÑодÑкÑов Open Source </value--> <value xml:lang="ru">ÐÑ Ð¾Ð´Ð¸Ñ Ð² ÑоÑÑав ÑемейÑÑва Open For Business</value> - <!--value xml:lang="th">à¹à¸à¹à¸à¸ªà¹à¸§à¸à¸«à¸à¸¶à¹à¸à¸à¸à¸à¸à¸¸à¸£à¸à¸´à¸à¹à¸à¸à¸à¸£à¸à¸à¸à¸£à¸±à¸§à¸à¸µà¹à¹à¸à¹à¸à¸à¸à¸à¸à¹à¹à¸§à¸£à¹à¹à¸à¹à¸à¸à¸à¸à¸ª</value--> + <!--value xml:lang="th">à¹à¸à¹à¸à¸ªà¹à¸§à¸à¸«à¸à¸¶à¹à¸à¸à¸à¸à¸à¸¸à¸£à¸à¸´à¸à¹à¸à¸à¸à¸£à¸à¸à¸à¸£à¸±à¸§à¸à¸µà¹à¹à¸à¹à¸à¸à¸à¸à¸à¹à¹à¸§à¸£à¹à¹à¸à¹à¸à¸à¸à¸à¸ª</value--> <value xml:lang="th">สà¹à¸§à¸à¸«à¸à¸¶à¹à¸à¸à¸à¸à¸à¸¸à¸£à¸à¸´à¸à¹à¸à¸à¸à¸£à¸à¸à¸à¸£à¸±à¸§à¸à¸µà¹à¹à¸à¹à¸à¸à¸à¸à¸à¹à¹à¸§à¸£à¹à¹à¸à¹à¸à¸à¸à¸à¸ª</value> - <!--value xml:lang="zh">弿ºè½¯ä»¶OFBizçç»æé¨å</valuevalue xml:lang="zh">弿ºè½¯ä»¶OFBizçç»æé¨å</value--> + <!--value xml:lang="zh">弿ºè½¯ä»¶OFBizçç»æé¨å</valuevalue xml:lang="zh">弿ºè½¯ä»¶OFBizçç»æé¨å</value--> <value xml:lang="vi">Thà nh viên cá»§a gia Äình 'Open For Business Family' cá»§a 'Open Source Software'</value> <value xml:lang="zh">弿ºè½¯ä»¶OFBizå®¶æçä¸é¨å</value> <value xml:lang="zh_CN">OFBizçä¸é¨å</value> @@ -144,6 +144,7 @@ <value xml:lang="pt_BR">Nome da Instalação está faltando</value> <value xml:lang="vi">Bạn chưa nháºp tên cÆ¡ sá» (Facility Name)</value> <value xml:lang="zh">缺å°åºæåç§°</value> + <value xml:lang="zh_TW">缺å°å ´æå稱</value> </property> <property key="SetupFirstCustomer"> <value xml:lang="en">First Customer</value> @@ -214,6 +215,7 @@ <value xml:lang="pt_BR">Nome da organização está faltando</value> <value xml:lang="vi">Bạn chưa nháºp tên doanh nghiá»p</value> <value xml:lang="zh">缺å°ç»ç»åç§°</value> + <value xml:lang="zh_TW">缺å°çµç¹å稱</value> </property> <property key="SetupOrganizationPartyId"> <value xml:lang="en">Organization Party Id</value> @@ -222,7 +224,7 @@ <value xml:lang="pt_BR">Id da Organização</value> <value xml:lang="vi">Id Doanh nghiá»p</value> <value xml:lang="zh">ç»ç»ä¼åæ è¯</value> - <value xml:lang="zh_TW">çµç¹æå¡ID</value> + <value xml:lang="zh_TW">çµç¹åé«èå¥</value> </property> <property key="SetupPageError"> <value xml:lang="en">You do not have sufficient data to access this page.</value> @@ -231,7 +233,7 @@ <value xml:lang="pt_BR">Você não tem dados suficientes para acessar essa página.</value> <value xml:lang="vi">Bạn chưa có Äá»§ quyá»n Äá» truy nháºp và o trang nà y.</value> <value xml:lang="zh">ä½ æ²¡æè¶³å¤çæ°æ®æ¥è®¿é®è¿ä¸ªé¡µé¢ã</value> - <value xml:lang="zh_TW">æ¨æ²æé²å ¥æ¤é é¢çæ¬éã</value> + <value xml:lang="zh_TW">æ¨æ²æé²å ¥æ¤é é¢çæ¬é.</value> </property> <property key="SetupProductCatalog"> <value xml:lang="en">Product Catalog</value> @@ -240,7 +242,7 @@ <value xml:lang="pt_BR">Catálogo de Produtos</value> <value xml:lang="vi">Catalog sản phẩm</value> <value xml:lang="zh">产åç®å½</value> - <value xml:lang="zh_TW">ç¢åç®é</value> + <value xml:lang="zh_TW">ç¢ååé</value> </property> <property key="SetupProductStore"> <value xml:lang="en">Product Store</value> @@ -266,6 +268,7 @@ <value xml:lang="pt_BR">Nome da loja está faltando</value> <value xml:lang="vi">Bạn chưa nháºp tên cá»a hà ng</value> <value xml:lang="zh">缺å°åºéºåç§°</value> + <value xml:lang="zh_TW">缺å°åºéªå稱</value> </property> <property key="SetupResults"> <value xml:lang="en">Results</value> @@ -292,6 +295,7 @@ <value xml:lang="pt_BR">O primeiro cliente de</value> <value xml:lang="vi">Khách hà ng Äầu tiên cá»§a</value> <value xml:lang="zh">第ä¸ä¸ªå®¢æ·å±äº</value> + <value xml:lang="zh_TW">第ä¸å客æ¶å±¬æ¼</value> </property> <property key="SetupWebSite"> <value xml:lang="en">Web Site</value> Modified: ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/data/GlAccountData.xml URL: http://svn.apache.org/viewvc/ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/data/GlAccountData.xml?rev=1626688&r1=1626687&r2=1626688&view=diff ============================================================================== --- ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/data/GlAccountData.xml (original) +++ ofbiz/branches/OFBIZ-5312-ofbiz-ecommerce-seo-2013-10-23/applications/commonext/data/GlAccountData.xml Mon Sep 22 08:09:27 2014 @@ -142,13 +142,6 @@ <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="CCT_VISA" glAccountId="122300"/> <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="CCT_MASTERCARD" glAccountId="122300"/> - <!-- The following ones are required until the issue OFBIZ-1524 is resolved --> - <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="AmericanExpress" glAccountId="122100"/> - <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="DinersClub" glAccountId="122100"/> - <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="Discover" glAccountId="122200"/> - <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="Visa" glAccountId="122300"/> - <CreditCardTypeGlAccount organizationPartyId="ORGPARTYID" cardType="MasterCard" glAccountId="122300"/> - <FinAccountTypeGlAccount organizationPartyId="ORGPARTYID" finAccountTypeId="GIFTCERT_ACCOUNT" glAccountId="213200"/> <FinAccountTypeGlAccount organizationPartyId="ORGPARTYID" finAccountTypeId="DEPOSIT_ACCOUNT" glAccountId="213500"/> <FinAccountTypeGlAccount organizationPartyId="ORGPARTYID" finAccountTypeId="BANK_ACCOUNT" glAccountId="213500"/> |
Free forum by Nabble | Edit this page |