[jira] [Comment Edited] (OFBIZ-10489) Unnecessary ship groups in orders

2019-06-27 Thread Jacques Le Roux (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10489?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16870233#comment-16870233
 ] 

Jacques Le Roux edited comment on OFBIZ-10489 at 6/28/19 6:55 AM:
--

The issue is generated because of the code committed in the patch from the 
ticket OFBIZ-5416. Here the code was properly handled in 
_ShoppingCartEvents.java_ but not in _ShoppingCartHelper.java._

Did the same handling in _ShoppingCartHelper.java_  in the patch 
*OFBIZ-10489.patch*.


was (Author: mohammad k):
The issue is generated because of the code committed in the patch from the 
ticket https://issues.apache.org/jira/browse/OFBIZ-5416. Here the code was 
properly handled in _ShoppingCartEvents.java_ but not in 
_ShoppingCartHelper.java._

Did the same handling in _ShoppingCartHelper.java_  in the patch 
*OFBIZ-10489.patch*.

> Unnecessary ship groups in orders
> -
>
> Key: OFBIZ-10489
> URL: https://issues.apache.org/jira/browse/OFBIZ-10489
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Trunk
>Reporter: Oleg Andreyev
>Assignee: Mohammad Kathawala
>Priority: Minor
> Fix For: Trunk
>
> Attachments: OFBIZ-10489.patch, empty_ship_group.diff
>
>
> Under some conditions, checkout creates extra ship groups in the order.
> Steps to reproduce:
>  # create a couple of products P1 and P2 (just to get clear results).
>  # create a new order and add 1 P1 and 1 P2
>  # change quantity P1 to 2 (or both) and Recalculate Order (key step really)
>  # finish checkout
> You will see 2 order items linked with ship group 1 and another ship 
> group 2 that should not have been created. You may see in the patch that 
> the code address a ship group using index of the order item and the shopping 
> cart creates new ship group if the index is greater than the number of 
> existing groups. 
> In one of my projects based on 16.11, I noticed even more serious trouble 
> that takes place if both products are drop-shipping order but don't explain 
> it here because it seems do not appear in the trunk.  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Closed] (OFBIZ-11128) Error when manually loading data in "XML Data Import" using "Import Text"

2019-06-27 Thread Jacques Le Roux (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11128?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jacques Le Roux closed OFBIZ-11128.
---
Resolution: Invalid

I was wrong, surrounding by   works! 
It's also stated in the page:
bq. These documents all have a root tag of "".
This was not necessary before, I now know it's needed

> Error when manually loading data in "XML Data Import" using "Import Text"
> -
>
> Key: OFBIZ-11128
> URL: https://issues.apache.org/jira/browse/OFBIZ-11128
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework/webtools
>Affects Versions: Trunk, Release Branch 16.11, Release Branch 17.12, 
> Release Branch 18.12
>Reporter: Jacques Le Roux
>Priority: Major
>
> I cross this issue for already some times and while testing OFBIZ-10966 I 
> decided to report it. It' still present once the today OFBIZ-10966 patch is 
> applied. I guess R16 is also concerned.
> I thought only Windows was concerned but I tested today by copying the 1st 
> block of line in AccountingDemoData.xml and stable as trunk demo also fail.
> Reproducing is easy: simply copy a block of lines from a data file either in 
> Eclipse or in another editor.
> The error is
> {{org.xml.sax.SAXParseException: The markup in the document following the 
> root element must be well-formed.}}
> * Importing only the 1st line works.
> * Removing the lines delimiter (ie have the text not separated by lines) in 
> the OFBiz textarea does not work
> * Converting CR/LF to LF does not help
> * Removing heading or trailing white spaces does not help
> * Surrounding by   does not help
> In other words you have to import lines one by one.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Comment Edited] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jacques Le Roux (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874517#comment-16874517
 ] 

Jacques Le Roux edited comment on OFBIZ-10966 at 6/27/19 9:33 PM:
--

I agree Mathieu, I thought about it. I let you take over :)

Please assign yourself...


was (Author: jacques.le.roux):
I agree Mathieu, I thought about it. I let you take over :)

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jacques Le Roux (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874517#comment-16874517
 ] 

Jacques Le Roux commented on OFBIZ-10966:
-

I agree Mathieu, I thought about it. I let you take over :)

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Reopened] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Mathieu Lirzin (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mathieu Lirzin reopened OFBIZ-10966:


> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Mathieu Lirzin (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874471#comment-16874471
 ] 

Mathieu Lirzin commented on OFBIZ-10966:


Hello,

Even if this feature is interesting, I must say that I am really unhappy with 
the poor quality of the code that has been committed to trunk. Dead code, 
unused imports, redundant dependency, low level iterator instead of foreach 
loops... to me this is unacceptable given the programming standards I expect 
from this community.

One major issue that need to be fixed ASAP is the usage of a new dependency for 
JSON manipulation which is outdated (no generics) and pointless since we 
already depend on Jackson which is doing a better job.

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-11100) Remove support for "ofbiz-containers.xml"

2019-06-27 Thread Mathieu Lirzin (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-11100?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874234#comment-16874234
 ] 

Mathieu Lirzin commented on OFBIZ-11100:


I updated the patches to trunk. Additionally I have included 3 refactoring 
patches enabled by the removal.

> Remove support for "ofbiz-containers.xml"
> -
>
> Key: OFBIZ-11100
> URL: https://issues.apache.org/jira/browse/OFBIZ-11100
> Project: OFBiz
>  Issue Type: Improvement
>  Components: framework
>Affects Versions: Trunk
>Reporter: Mathieu Lirzin
>Assignee: Mathieu Lirzin
>Priority: Major
> Attachments: 
> OFBIZ-11100_0001-Improved-Remove-support-for-ofbiz-containers.xml.patch, 
> OFBIZ-11100_0002-Improved-Deprecate-ContainerConfig-getConfiguration-.patch, 
> OFBIZ-11100_0003-Improved-Inline-filterContainersHavingMatchingLoader.patch, 
> OFBIZ-11100_0004-Improved-Access-configurations-inside-loadContainers.patch, 
> OFBIZ-11100_0005-Improved-Pass-directly-the-loaders-to-loadContainers.patch
>
>
> To extend the containers loaded on startup, it is possible define a
> container element either in the global “ofbiz-containers.xml” file or in
> the “ofbiz-component.xml” file from each component.
> This redundancy adds extra complexity in the startup process for no good
> extensibility reason.  The component container loader is more flexible
> since it allows developper to add new containers without touching the
> framework so it is better to only rely on this option.
> In order to simplify the startup process I am proposing to remove the
> "ofbiz-containers.xml" config file and hard-code the required base
> container which is loading the components which is currently defined in
> this file.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (OFBIZ-11100) Remove support for "ofbiz-containers.xml"

2019-06-27 Thread Mathieu Lirzin (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11100?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mathieu Lirzin updated OFBIZ-11100:
---
Attachment: 
OFBIZ-11100_0001-Improved-Remove-support-for-ofbiz-containers.xml.patch

OFBIZ-11100_0002-Improved-Deprecate-ContainerConfig-getConfiguration-.patch

OFBIZ-11100_0003-Improved-Inline-filterContainersHavingMatchingLoader.patch

OFBIZ-11100_0004-Improved-Access-configurations-inside-loadContainers.patch

OFBIZ-11100_0005-Improved-Pass-directly-the-loaders-to-loadContainers.patch

> Remove support for "ofbiz-containers.xml"
> -
>
> Key: OFBIZ-11100
> URL: https://issues.apache.org/jira/browse/OFBIZ-11100
> Project: OFBiz
>  Issue Type: Improvement
>  Components: framework
>Affects Versions: Trunk
>Reporter: Mathieu Lirzin
>Assignee: Mathieu Lirzin
>Priority: Major
> Attachments: 
> OFBIZ-11100_0001-Improved-Remove-support-for-ofbiz-containers.xml.patch, 
> OFBIZ-11100_0002-Improved-Deprecate-ContainerConfig-getConfiguration-.patch, 
> OFBIZ-11100_0003-Improved-Inline-filterContainersHavingMatchingLoader.patch, 
> OFBIZ-11100_0004-Improved-Access-configurations-inside-loadContainers.patch, 
> OFBIZ-11100_0005-Improved-Pass-directly-the-loaders-to-loadContainers.patch
>
>
> To extend the containers loaded on startup, it is possible define a
> container element either in the global “ofbiz-containers.xml” file or in
> the “ofbiz-component.xml” file from each component.
> This redundancy adds extra complexity in the startup process for no good
> extensibility reason.  The component container loader is more flexible
> since it allows developper to add new containers without touching the
> framework so it is better to only rely on this option.
> In order to simplify the startup process I am proposing to remove the
> "ofbiz-containers.xml" config file and hard-code the required base
> container which is loading the components which is currently defined in
> this file.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (OFBIZ-11100) Remove support for "ofbiz-containers.xml"

2019-06-27 Thread Mathieu Lirzin (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11100?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mathieu Lirzin updated OFBIZ-11100:
---
Attachment: (was: 
OFBIZ-11100_Deprecate-ContainerConfig-getConfiguration.patch)

> Remove support for "ofbiz-containers.xml"
> -
>
> Key: OFBIZ-11100
> URL: https://issues.apache.org/jira/browse/OFBIZ-11100
> Project: OFBiz
>  Issue Type: Improvement
>  Components: framework
>Affects Versions: Trunk
>Reporter: Mathieu Lirzin
>Assignee: Mathieu Lirzin
>Priority: Major
>
> To extend the containers loaded on startup, it is possible define a
> container element either in the global “ofbiz-containers.xml” file or in
> the “ofbiz-component.xml” file from each component.
> This redundancy adds extra complexity in the startup process for no good
> extensibility reason.  The component container loader is more flexible
> since it allows developper to add new containers without touching the
> framework so it is better to only rely on this option.
> In order to simplify the startup process I am proposing to remove the
> "ofbiz-containers.xml" config file and hard-code the required base
> container which is loading the components which is currently defined in
> this file.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Updated] (OFBIZ-11100) Remove support for "ofbiz-containers.xml"

2019-06-27 Thread Mathieu Lirzin (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11100?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mathieu Lirzin updated OFBIZ-11100:
---
Attachment: (was: 
OFBIZ-11100_Remove-support-for-ofbiz-containers.xml.patch)

> Remove support for "ofbiz-containers.xml"
> -
>
> Key: OFBIZ-11100
> URL: https://issues.apache.org/jira/browse/OFBIZ-11100
> Project: OFBiz
>  Issue Type: Improvement
>  Components: framework
>Affects Versions: Trunk
>Reporter: Mathieu Lirzin
>Assignee: Mathieu Lirzin
>Priority: Major
>
> To extend the containers loaded on startup, it is possible define a
> container element either in the global “ofbiz-containers.xml” file or in
> the “ofbiz-component.xml” file from each component.
> This redundancy adds extra complexity in the startup process for no good
> extensibility reason.  The component container loader is more flexible
> since it allows developper to add new containers without touching the
> framework so it is better to only rely on this option.
> In order to simplify the startup process I am proposing to remove the
> "ofbiz-containers.xml" config file and hard-code the required base
> container which is loading the components which is currently defined in
> this file.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-11125) No proper error message displayed if user misses to select entities

2019-06-27 Thread Jayansh Shinde (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-11125?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874059#comment-16874059
 ] 

Jayansh Shinde commented on OFBIZ-11125:


Thanks again Jacques!!!




On Thu, Jun 27, 2019 at 5:35 PM Jacques Le Roux (JIRA) 



> No proper error message displayed if user misses to select entities 
> 
>
> Key: OFBIZ-11125
> URL: https://issues.apache.org/jira/browse/OFBIZ-11125
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework/webtools
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Major
> Fix For: 17.12.01, 16.11.06, 18.12.01
>
> Attachments: OFBiz-11125.patch, 
> OFBiz-Web-Tools-XML-Data-Export_no_proper_error_msg.png
>
>
> No Proper error message is displayed if user misses to select entities from 
> the list, and throw error message as shown in attached image



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jayansh Shinde (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874056#comment-16874056
 ] 

Jayansh Shinde commented on OFBIZ-10966:


Thanks Jacques, will take care of it...
Thanks,

Jayansh

On Thu, Jun 27, 2019 at 5:32 PM Jacques Le Roux (JIRA) 



> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Closed] (OFBIZ-11125) No proper error message displayed if user misses to select entities

2019-06-27 Thread Jacques Le Roux (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11125?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jacques Le Roux closed OFBIZ-11125.
---
   Resolution: Fixed
Fix Version/s: 18.12.01
   16.11.06
   17.12.01

Thanks Jayansh,

Your patch is in
trunk r1862207
R18 r1862208
R17 r1862209
R16 r1862210


> No proper error message displayed if user misses to select entities 
> 
>
> Key: OFBIZ-11125
> URL: https://issues.apache.org/jira/browse/OFBIZ-11125
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework/webtools
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Major
> Fix For: 17.12.01, 16.11.06, 18.12.01
>
> Attachments: OFBiz-11125.patch, 
> OFBiz-Web-Tools-XML-Data-Export_no_proper_error_msg.png
>
>
> No Proper error message is displayed if user misses to select entities from 
> the list, and throw error message as shown in attached image



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jayansh Shinde (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874053#comment-16874053
 ] 

Jayansh Shinde commented on OFBIZ-10966:


Thank you very much Jacques, for fixing issues and putting patch in trunk. 

 

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jacques Le Roux (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874050#comment-16874050
 ] 

Jacques Le Roux commented on OFBIZ-10966:
-

BTW Jayansh,

You don't need to delete old patches and put a date in new ones, just use the 
same name. Jira is smart enough to handle and will simply gray the old ones :)

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Assigned] (OFBIZ-11125) No proper error message displayed if user misses to select entities

2019-06-27 Thread Jacques Le Roux (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-11125?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jacques Le Roux reassigned OFBIZ-11125:
---

Assignee: Jacques Le Roux  (was: Jayansh Shinde)

> No proper error message displayed if user misses to select entities 
> 
>
> Key: OFBIZ-11125
> URL: https://issues.apache.org/jira/browse/OFBIZ-11125
> Project: OFBiz
>  Issue Type: Bug
>  Components: framework/webtools
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Major
> Attachments: OFBiz-11125.patch, 
> OFBiz-Web-Tools-XML-Data-Export_no_proper_error_msg.png
>
>
> No Proper error message is displayed if user misses to select entities from 
> the list, and throw error message as shown in attached image



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Closed] (OFBIZ-10966) JSON entity data import and export utility

2019-06-27 Thread Jacques Le Roux (JIRA)


 [ 
https://issues.apache.org/jira/browse/OFBIZ-10966?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jacques Le Roux closed OFBIZ-10966.
---
   Resolution: Implemented
 Assignee: Jacques Le Roux  (was: Jayansh Shinde)
Fix Version/s: Upcoming Branch

Thanks Jayansh,

Your slightly modified patch is in trunk at revision: 1862206  

While testing, I have noticed 2 trivial things I fixed
# The web page title of EntityImportJson was "Web Tools: XML Data Import"
# You added commons-text:1.6 in build.gradle, it's already there

You also added org.json:json:20140107, not the latest version. I understand 
that this is for legal reason (license: 
http://www.apache.org/legal/resolved.html#json), and it's OK

> JSON entity data import and export utility
> --
>
> Key: OFBIZ-10966
> URL: https://issues.apache.org/jira/browse/OFBIZ-10966
> Project: OFBiz
>  Issue Type: New Feature
>  Components: framework
>Reporter: Jayansh Shinde
>Assignee: Jacques Le Roux
>Priority: Minor
> Fix For: Upcoming Branch
>
> Attachments: OFBIZ-10966_27062019.patch, 
> OFBiz-Web-Tools-JSON-Data-Export-All.png, 
> OFBiz-Web-Tools-JSON-Data-Import-Dir.png, exportJson.png, importJson.png
>
>
> Currently, we support import/export entity data in XML format.
>  Nowadays JSON is widely used in industry, we can have support for JSON 
> format which looks quite similar to XML support.
> Here is example of XML data and it's JSON version
> {code:java}
> 
> {code}
> {code:java}
> {“Party”: 
> {"partyId":"123456","partyTypeId":"PERSON","statusId":"PARTY_ENABLED”}}
> {code}
>  
> *Design Proposal*
> We can write *entityImportJson* and *entityImportDirJson* services for 
> importing JSON from screen and directory respectively.
> And the *entityExportAllJson* service for exporting entity data in JSON.
>  
> *Import Design*
>  The import service will perform following operations:
>  1.) Validate the input JSON data (I am in process of exploring the way for 
> this)
>  2.) On successful validation, convert JSON to OFBiz's entity model 
> (GenericValue)
>  3.) The GenericValue will be inserted in database by some handler class for 
> e.g we can write JsonDataHandler, it will convert given JSON to 
> List, and finally write it to database (Similar pattern is used 
> in XML import).
>  
> *Export Design*
>  Based on existing XML pattern the writeXmlText method of GenericEntity class 
> write the exported data in XML format. 
>  In the similar way, we can implement writeJsonText to export data in JSON 
> format.
> Please free feel to share your thought.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Created] (OFBIZ-11128) Error when manually loading data in "XML Data Import" using "Import Text"

2019-06-27 Thread Jacques Le Roux (JIRA)
Jacques Le Roux created OFBIZ-11128:
---

 Summary: Error when manually loading data in "XML Data Import" 
using "Import Text"
 Key: OFBIZ-11128
 URL: https://issues.apache.org/jira/browse/OFBIZ-11128
 Project: OFBiz
  Issue Type: Bug
  Components: framework/webtools
Affects Versions: Release Branch 16.11, Trunk, Release Branch 17.12, 
Release Branch 18.12
Reporter: Jacques Le Roux


I cross this issue for already some times and while testing OFBIZ-10966 I 
decided to report it. It' still present once the today OFBIZ-10966 patch is 
applied. I guess R16 is also concerned.

I thought only Windows was concerned but I tested today by copying the 1st 
block of line in AccountingDemoData.xml and stable as trunk demo also fail.

Reproducing is easy: simply copy a block of lines from a data file either in 
Eclipse or in another editor.

The error is
{{org.xml.sax.SAXParseException: The markup in the document following the root 
element must be well-formed.}}

* Importing only the 1st line works.
* Removing the lines delimiter (ie have the text not separated by lines) in the 
OFBiz textarea does not work
* Converting CR/LF to LF does not help
* Removing heading or trailing white spaces does not help
* Surrounding by   does not help

In other words you have to import lines one by one.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)


[jira] [Commented] (OFBIZ-11127) Code improvement in ShoppingCartEvents.java

2019-06-27 Thread Pawan Verma (JIRA)


[ 
https://issues.apache.org/jira/browse/OFBIZ-11127?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16873963#comment-16873963
 ] 

Pawan Verma commented on OFBIZ-11127:
-

Hi [~amit.gadaley],

Thanks for the patch, I have reviewed it and I think we can also improve it for 
destroyCart() method, Please let me know your thoughts on this. Thanks!

> Code improvement in ShoppingCartEvents.java
> ---
>
> Key: OFBIZ-11127
> URL: https://issues.apache.org/jira/browse/OFBIZ-11127
> Project: OFBiz
>  Issue Type: Improvement
>  Components: order
>Affects Versions: Trunk
>Reporter: Amit Gadaley
>Assignee: Pawan Verma
>Priority: Minor
> Attachments: OFBIZ-11127.patch
>
>
> Method 'getCartObject' of ShoppingCartEvents class accessed incorrectly at 
> some places in ShoppingCartEvents class.
> It should be called by following below syntax:
> getCartObject(parameters);
>  
> But, at some places, it is called incorrectly like this:
> ShoppingCartEvents.getCartObject(parameters)
>  
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)