This fixes it by renaming GetInvoiceItemTypes.groovy to GetAccountOrganizationAndClass.groovy and removing the now useless invoiceItemTypes list inside it.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1547742 13f79535-47bb-0310-9956-ffa450edef68
Better groovy scriplets (elvis operator)
I believe using BigDecimal for both fields quantity and total can't hurt
Increases size of both fields quantity and total
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1547719 13f79535-47bb-0310-9956-ffa450edef68
While iterating the adjustments list we are checking with orderAdjustment.productPromoId rather then the adjustment.productPromoId. Using orderAdjustment.productPromoId the condition will never true and the newOrderAdjustmentTotal will always be 0.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1547548 13f79535-47bb-0310-9956-ffa450edef68
Selected ship group destinations are displayed incorrectly on the purchase order entry Shipping page. The first ship group destination is selected without checking if any of the other destinations were selected. Part of the problem is that the facilityId of the destination chosen is not specified in the parameters passed to CheckOutEvents finalizeOrderEntry function.
To reproduce:
1. Create an order to DemoSupplier
2. Add any supplier product to the order and click Finalize Order
3. Click Continue until you reach the Shipping page
4. Choose the second shipping destination and click Continue
5. Click the Shipping link to go back to the previous shipping page
6. Notice that the second destination is not selected
The second destination is actually assigned because it appears on the confirmation page but no code exists to check the correct radio option. The facilityId will have to be passed in somehow to allow such logic to be correctly implemented.
Using the @ symbol probably isn't the best one to use for separating fields. I wanted to provide the facility destination contactMechIds in a drop down list rather than as a list of radio options and when the @ symbol is used, it is encoded as @ which prevents matching of the key. This means that I don't get an accurate description in the drop down list of the selected record. Replacing the @ symbol with something else such as _ fixes the issue but might cause problems if some facilities or contactMechIds contain an _.
jleroux:I simply used the token _@_ as separator to prevent wrong splits in case @ or _ would have been used in facilities or contactMechIds (though it's not possible OOTB from UI, those Ids are generated)
This solution works well with radio buttons. There are a lof of information to show in each ship group address and I believe in such case it's easier to read as it's currently done (multiple lines for each address) than using a drop-down.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1544444 13f79535-47bb-0310-9956-ffa450edef68
When using locale DE or NL several quantities (ATP, QOH and others) get transformed wrong.
E.g. a ATP of 250 for a product is 250.00 in locale EN or FR, but for DE and NL the output is 250.000.000,00
jleroux: I completed Pierre's patch in 2 ways:
* used also BigDecimal for minimumStock in getProductInventoryAndFacilitySummary service and groovy script
* Fixed the same kind of issue in CountFacilityInventoryByProduct.groovy
In by and large i18n contexts, this fixes number of Inventory views and reports, also in Asset Maint and Birt components where those 2 service/groovy scripts are used
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1543766 13f79535-47bb-0310-9956-ffa450edef68
This did not make sense: the pattern was compiled and then the string compiled was retrieved.
Also removes 2 trailing blanks
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1542704 13f79535-47bb-0310-9956-ffa450edef68
So better be safe than sorry, even if in the loops we loose a bit of performance (here only "short" loops anyway)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1541641 13f79535-47bb-0310-9956-ffa450edef68
While rebuilding it, it seems I inadvertently pushed a OK button somewhere...
This reverts r1541470 and all pending stuff which should not have slipped in
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1541485 13f79535-47bb-0310-9956-ffa450edef68
The ship estimate field of the shipping options page of the purchase order finalization screen is not populated with the itemShipGroupEstimate value.
To reproduce:
1. Create an purchase order to DemoSupplier for product
GZ-1000
2. Finalize the order and click continue until reaching the shipping options page
3. Set the Shipping Estimate Amount and click Continue
4. Click the "Options" link to navigate to the previous page and notice that the shipping estimate field is not set to the value submitted in the previous step
This patch sets the value of the shipping estimate field to the ship group estimate.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1539156 13f79535-47bb-0310-9956-ffa450edef68
ShipBeforeDate/ShipAfterDate fields are not created as renderDateFields for additional ship groups on orderview page.
The problem is that additional ship groups share the same id as the first ship group date fields. The javascript renderDateField logic requires unique ids the all fields that are supposed to be created by renderDateField.
To reproduce:
1. Create an order for DemoCustCompany
2. Add 10 GZ-BASKET products to the order and click "Finalize Order"
3. Add an additional ship group and click "Continue"
4. Assign 5 of GZ-BASKET to second ship group and click "Continue"
5. Complete the remaining steps required to complete the order
6. On the page after the "Create Order" link is clicked, notice the date fields of the second ship group were not rendered with a calendar.
This patch allows all ship group date fields to be rendered correctly by changing the renderDateField id field from "shipBeforeDate" to "shipBeforeDate_${shipGroup.shipGroupSeqId}" and the same for shipAfterDate
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1539147 13f79535-47bb-0310-9956-ffa450edef68
The only effect is to remove the disabled item
This is due to r1517353 which introduced a NPE in MacroMenuRenderer.java
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1537833 13f79535-47bb-0310-9956-ffa450edef68
After r751990, <<allow-html="any">> and <<allow-html="safe">> are the same: they do nothing! The only difference is the warning message from the OWASP Antisamy IntrusionDetector, which is both, as Christoph noted "giving you a false sense of security" or as I wrote "disturbing, wrong and useless". So there are no longer any reasons for differencing "safe" and "any".
This
* Deprecates "safe" (making it clear in the XSD documentation), keeping only "none" and "any". This is for backward compatibility, else we could completely remove the misleading "safe". Note that "none" is the default.
* Replaces in services definition all allow-html="safe" by allow-html="any"
* Remove from ModelService.java (near line 587) the code which throws the OWASP Antisamy IntrusionDetector message in log
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1536324 13f79535-47bb-0310-9956-ffa450edef68
It was already flawed in R10.04.
If you click on the Gizmos node, the pagination page shows 3 pages when there should be only 2 and if you get to the page 3 it crashes.
If you come from the breadcrumb the problem is the same.
On the other hand, from R11.04 there is a "Popular Categories" section at top of the main screen, and from there it works correctly.
But in this version the "Featured Products" pagination shows the same symptom than the category pagination.
The "Featured Products" pagination works almost correctly from R12.04, but shows 2 pages when the second is useless and empty, at least no crashes!
Note:
This has no side effects on the same in order component
Actually what we should do is to create an unique paginationControls macro but there are subtle differences and I'm afraid it would open a can of worms. I will though check...
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1535961 13f79535-47bb-0310-9956-ffa450edef68
Validated all xml files and compiled all groovy files and found a few errors. Look at patch for details
jleroux: For webapptests.xml, I prefered to revert it from r959261 (I saw an issue in my xml editor, did not check more)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1532366 13f79535-47bb-0310-9956-ffa450edef68
"Addition of item to shopping list is not working" https://issues.apache.org/jira/browse/OFBIZ-4903
"Problem when saving a product to a shopping list" https://issues.apache.org/jira/browse/OFBIZ-4589
I don't pretend it's glorious code. For instance I gave up on trying to have the groovy changes snippets consistent in both components and to reuse the way it's done in party. And the way I secured the indexes remember me when I was hacking in APL. For my defense, it was really a mess... and my time is limited...
Anyway, at least it fixes all the issues I crossed in shopping list editing in both party and ecommerce components:
* NPE on sessions ending
* wrong and failing (NPE in ftl) pagination
* error on pagination links after adding a product
Tested with both 2 and 20 size view on both sides
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1532342 13f79535-47bb-0310-9956-ffa450edef68
When order items are issued to a shipment, the accounting_quantity_total
for the corresponding inventory records are updated but afterwards when
the shipment is cancelled, the accounting_quantity_total is not reverted
back to the original values. Is this a bug or is there a reason the
quantity is not reverted?
The problem is that when I try to create another shipment and issue the
same quantity, I receive the following error:
The following error occurs when I try to issue the same previously
cancelled quantity to a newly created shipment:
Error:<br/> ERROR: Could not complete the Issue OrderItemShipGrpInvRes
to Shipment
[file:/dev/apache-ofbiz-11.04.02/applications/product/script/org/ofbiz/shipment/issuance/IssuanceServices.xml#issueOrderItemShipGrpInvResToShipment]
process [problem removing the orderItemShipGrpInvRes value: The current
transaction is marked for rollback, not beginning a new transaction and
aborting current operation; the rollbackOnly was caused by: Error in
simple-method [Create an accounting transactions for a sales shipment
issuance (D: INVENTORY_ACCOUNT, C: COGS_ACCOUNT)
[file:/home/stan/dev/apache-ofbiz-11.04.02/applications/accounting/script/org/ofbiz/accounting/ledger/GeneralLedgerServices.xml#createAcctgTransForSalesShipmentIssuance]]:
; {Could not find enough accounting inventory for product DOUGH;
remaining quantity: 1}] <br/> <br/>
The service is looking for inventory_item records with an
accounting_quantity_total > 0 but finds none because the quantity was
decremented to 0 from the cancelled shipment issuance.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1531030 13f79535-47bb-0310-9956-ffa450edef68