This only fixes a 1st issue found while debugging.
Adds the order package to be able to debug Groovy in Eclipse. We need to add
packages to all Groovy scripts to be able to easily debug Groovy in Eclipse.
Adds .first() in updateReturnStatusFromReceipt at OrderReturnServices.groovy[506]
That is the fix
A lot of non functional formatting
Steps:
Locate any completed order.
From the order's view screen "Action" section click Create Return.
Select some items to return then accept the return.
From the "Return Item" menu click Receive Return button.
You will land on the facility application "Receive Return" screen.
Try receiving items, which will generate an error
Thanks: Nameet Jain
When the webshop (ecommerce component) has been set up for retail (B2C), with
the tax setting 'Show prices with VAT tax included' set to 'Y' in store 9000
the appropriat Tax Auth Geo and Tax Auth set in store 9000
the flag 'Include Tax In Price' set to 'Y' for the Tax Auth
the price for a virtual product is shown including VAT.
However, for a selected variant the price shown is without VAT
Thanks: Pierre Smits to raise the issue and Priya Sharma for solved it
(OFBIZ-12239)
After a fresh data base init with only seed, if you create your company without invoice or quote prefix, your sequence will be generate with 'null' string where the invoice or quote prefix should be have :
> null10001, null10002, ...
There is no "basePrice" resulting from calculatePurchasePrice service calling but
a simple "price".
This was put in with d04f777 commit and OFBIZ-11955
Thanks: Woyce Batkins for report
When a dropship only (or dropship on low ATP) product with no qualified supplier
added to shopping cart and cart converted to sales order. System should return
errors and should not create sales order.
Thanks: Amit Gadaley
(OFBIZ-7327)
Use a data URL rather than a regular URL for company logos when a
logo has been specified as a Party Content item. This works around the
problem of Apache FOP failing to retrieve content from HTTPS URLs.
Thanks: Deepak Dixit for the review and suggestions
(OFBIZ-12076)
After a fresh data base init with only seed, if you create your company without order prefix, your orderId sequence will be generate with 'null' string where the order prefix should be have :
> null10001, null10002, ...
This come from the groovy migration of service 'getNextOrderId' where productStore.orderNumberPrefix is loaded on the sequence without control if is empty or not
The variant products' images are being saved in the variable IMG encoded as urls,
thus selecting the variant triggers an image override with an unsuitable file name.
Thanks: Alex Bodnaru
There are some inconsistencies in the code for string comparison statusId.equals(PRUN_COMPLETED) whereas it should be written as PRUN_COMPLETED.equals(statusId) cause the former can throw NullPointerException if the variable found to be NULL.
Thanks: Devanshu for your contribution.
Sometimes use wrong type castings for BigDecimal:
I have observed that for typecasting in groovy, we have used the wrong coding
pattern like
(BigDecimal) 0
It should be like
0 as BigDecimal
Note that this does not apply to decimal because in case of decimal, the default
type is always BigDecimal in Groovy.
Thanks: Pritam Kute for spotting the issue in OFBIZ-11843
https://demo-stable.ofbiz.apache.org/ecommerce/control/order.pdf?orderId=WSCO10000
In the above URL, the parameter 'orderId' has the value 'WSCO10000' and after
incrementing the value to 'WSCO10001' or 'WSCO10002' will download the receipt
of other orders which have been placed by other users.
All the available order receipts can be downloaded by running an automated tool
(Burp Intruder) on the parameter 'orderId=WSCOXXXXX'
I have successfully tested this by using 2 different accounts: DemoCustomer and
DemoCustomer2
An attacker can download order receipts of other users and this could lead to
information disclosure.
The only real solution to this issue is to implement access control. The user
needs to be authorized for the requested information before the server provides
it.
Thanks: Harshit Shukla [mailto:harshit.shukz@gmail.com]reported this IDOR
vulnerability to the OFBiz security team, and we thank him for that.
* [Improved]: Use GroovyBaseScript's logging utility methods instead of using Debug
- Replaced the debug.log methods with the respective groovy utility method
- Enhanced the GroovyBaseScript to entertain the fetch the current class name as the module name for logging
- Overloaded the logError method to entertain throwbale object for better logging
- Removed unused import statements and module variables.
(OFBIZ-11762)
* [Removed]: Extra line spaces. (OFBIZ-11762)
* [Revert]: Unwanted changes. (OFBIZ-11762)
* [Added] Same changes to these files. (OFBIZ-11762)
Co-authored-by: Priya Sharma <priya.sharma@example.com>
communication about the order (mail, phone etc.)
(OFBIZ-11210)
This is in order detail view for following communication about the order
(mail, phone etc.) to keep an eye about all com' event linked to the order.
Thanks: Carl Demus
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1867581 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-11176)
When you search orders on the standard screen [1] you can't unselect a country.
The problem come from the populate country list by countries.ftl who select by default a country without possibility to escape it.
We added a possibility to escape it through variable doNotPreselectDefaultCountryGeoId
[1] https://localhost:8443/ordermgr/control/findorders
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1866012 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-7257)
Here is an implementation plan for the proposed solution.
Order Attachment Flow:
1) Show 'Attachments' instead of 'Image' on the order view screen.
2) If there are any attachments associated with the order, then their information will be displayed in the form of a button(Content link) else 'No Attachment' label should be shown.
3) If no attachments are there, then along with the label, a button(Add Attachment) will be displayed.
On clicking the Add Attachment button, a user will be redirected to a page where he/she can add different types of content(image, document, URL, etc.) to the order.
Order Attachment Modeling:
Used OrderContent as the entity to store the content and order association.
Created OrderContentType data for an image and document for starters.
Thanks Avnindra Sharma for reporting the original issue, Devanshu Vyas for providing the patch and Jacques for review and suggestions.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1861853 13f79535-47bb-0310-9956-ffa450edef68
(OFBIZ-11064)
As we all know, Groovy is a powerful language with great built-in functions.
Groovy Truth[1] is one of them, which is not used properly in our code base.
We have used UtilValidate Class to validate arguments for Empty or NotEmpty,
which can easily be done in groovy with built-in functionality[1].
Current Code: if (UtilValidate.isNotEmpty(locations)) { ... }
Groovy Built-in Code: if (locations) { ... }
[1] - http://groovy-lang.org/semantics.html#Groovy-Truth
We need to careful for some points while we change this:
Like:
maxRetry = 0
if (!maxRetry)
{ // Not set, use a default maxRetry = -1 }
Because groovy evaluates zero to be false, it wouldn't be possible to set
maxRetry to zero. So it's best not to use groovy truth for null-checks on
numbers in some cases.
Thanks: Pawan Verma
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/ofbiz-framework/trunk@1860051 13f79535-47bb-0310-9956-ffa450edef68