[jira] [Commented] (OFBIZ-6770) createCustRequestContent Hasn't worked in 6 years and 7 months

2015-12-15 Thread Forrest Rae (JIRA)

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

Forrest Rae commented on OFBIZ-6770:


Sorry, I didn't mean to leave out important details, and sorry for all the 
emails to the Dev mailing list while trying to correct the description.  You 
click anywhere outside of the description and it saves.

> createCustRequestContent Hasn't worked in 6 years and 7 months
> --
>
> Key: OFBIZ-6770
> URL: https://issues.apache.org/jira/browse/OFBIZ-6770
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Release Branch 11.04, Release Branch 12.04, Release 
> Branch 13.07, Release Branch 14.12, Trunk
>Reporter: Forrest Rae
> Attachments: OFBIZ-6770-option1.patch, OFBIZ-6770-option2.patch, 
> OFBIZ-6770-option3.patch
>
>
> This [commit|https://fisheye6.atlassian.com/changelog/ofbiz?cs=768661] 
> disabled the mimeTypeId argument in 
> applications/order/widget/ordermgr/CustRequestForms.xml, in order to provide 
> "various fixes".  I wonder how many people have been frustrated by this when 
> looking for example code on how to upload documents.  
> The issue is that mimeTypeId field that was commented out from 
> [applications/order/widget/ordermgr/CustRequestForms.xml|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/widget/ordermgr/CustRequestForms.xml?r=1686674#to608],
>  is a required parameter by 
> [createCustRequestContent|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to23].
>   Lines 52-54 check it's value for the following:
> Line 
> [52|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to52]:
>  if-compare is "Does the web browser's choice of mimeTypeId equal what the 
> user thinks the mimeTypeId is?"
> Line 
> [53|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to53]:
>  if-compare is "Did the user select anything at all in the mimeTypeId 
> dropdown?" (Before the mimeTypeId field was commented out.)
> Line 
> [54|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to54]:
>  if-compare is "Did the user submit mimeTypeId form field, but remove the 
> value, submitting a blank form field?"  This is the weird case, as really 
> this should be a is-null check.
> My question is why are we even doing any of this when the event just goes on 
> to set the mimeType to what the web browser decided it was, and then to call 
> createContentFromUploadedFile service?  Also, if mimeTypeId is in fact empty, 
> the call to createContentFromUploadedFile calls createDataResource, which at 
> applications/content/script/org/ofbiz/content/data/DataServices.xml:53 calls 
> org.apache.tika.Tika#detect(byte[]) to detect the mimeType anyway.  Why not 
> just let tika handle the mimeType?
> Anyway, I dunno enough about the Content component to make the decision here. 
>  I've attached three different patches.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OFBIZ-6770) createCustRequestContent Hasn't worked in 6 years and 7 months

2015-12-15 Thread Jacques Le Roux (JIRA)

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

Jacques Le Roux commented on OFBIZ-6770:


The joys of Ajax ;)

> createCustRequestContent Hasn't worked in 6 years and 7 months
> --
>
> Key: OFBIZ-6770
> URL: https://issues.apache.org/jira/browse/OFBIZ-6770
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Release Branch 11.04, Release Branch 12.04, Release 
> Branch 13.07, Release Branch 14.12, Trunk
>Reporter: Forrest Rae
> Attachments: OFBIZ-6770-option1.patch, OFBIZ-6770-option2.patch, 
> OFBIZ-6770-option3.patch
>
>
> This [commit|https://fisheye6.atlassian.com/changelog/ofbiz?cs=768661] 
> disabled the mimeTypeId argument in 
> applications/order/widget/ordermgr/CustRequestForms.xml, in order to provide 
> "various fixes".  I wonder how many people have been frustrated by this when 
> looking for example code on how to upload documents.  
> The issue is that mimeTypeId field that was commented out from 
> [applications/order/widget/ordermgr/CustRequestForms.xml|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/widget/ordermgr/CustRequestForms.xml?r=1686674#to608],
>  is a required parameter by 
> [createCustRequestContent|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to23].
>   Lines 52-54 check it's value for the following:
> Line 
> [52|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to52]:
>  if-compare is "Does the web browser's choice of mimeTypeId equal what the 
> user thinks the mimeTypeId is?"
> Line 
> [53|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to53]:
>  if-compare is "Did the user select anything at all in the mimeTypeId 
> dropdown?" (Before the mimeTypeId field was commented out.)
> Line 
> [54|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to54]:
>  if-compare is "Did the user submit mimeTypeId form field, but remove the 
> value, submitting a blank form field?"  This is the weird case, as really 
> this should be a is-null check.
> My question is why are we even doing any of this when the event just goes on 
> to set the mimeType to what the web browser decided it was, and then to call 
> createContentFromUploadedFile service?  Also, if mimeTypeId is in fact empty, 
> the call to createContentFromUploadedFile calls createDataResource, which at 
> applications/content/script/org/ofbiz/content/data/DataServices.xml:53 calls 
> org.apache.tika.Tika#detect(byte[]) to detect the mimeType anyway.  Why not 
> just let tika handle the mimeType?
> Anyway, I dunno enough about the Content component to make the decision here. 
>  I've attached three different patches.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OFBIZ-6770) createCustRequestContent Hasn't worked in 6 years and 7 months

2015-12-15 Thread Forrest Rae (JIRA)

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

Forrest Rae commented on OFBIZ-6770:


Pierre, While it seems that in trunk createContentFromUploadedFile has been 
replaced by a more modular design, createCustRequestContent event seems to 
still be available in trunk.

> createCustRequestContent Hasn't worked in 6 years and 7 months
> --
>
> Key: OFBIZ-6770
> URL: https://issues.apache.org/jira/browse/OFBIZ-6770
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Release Branch 11.04, Release Branch 12.04, Release 
> Branch 13.07, Release Branch 14.12, Trunk
>Reporter: Forrest Rae
> Attachments: OFBIZ-6770-option1.patch, OFBIZ-6770-option2.patch, 
> OFBIZ-6770-option3.patch
>
>
> This [commit|https://fisheye6.atlassian.com/changelog/ofbiz?cs=768661] 
> disabled the mimeTypeId argument in 
> applications/order/widget/ordermgr/CustRequestForms.xml, in order to provide 
> "various fixes".  I wonder how many people have been frustrated by this when 
> looking for example code on how to upload documents.  
> The issue is that mimeTypeId field that was commented out from 
> [applications/order/widget/ordermgr/CustRequestForms.xml|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/widget/ordermgr/CustRequestForms.xml?r=1686674#to608],
>  is a required parameter by 
> [createCustRequestContent|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to23].
>   Lines 52-54 check it's value for the following:
> Line 
> [52|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to52]:
>  if-compare is "Does the web browser's choice of mimeTypeId equal what the 
> user thinks the mimeTypeId is?"
> Line 
> [53|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to53]:
>  if-compare is "Did the user select anything at all in the mimeTypeId 
> dropdown?" (Before the mimeTypeId field was commented out.)
> Line 
> [54|https://fisheye6.atlassian.com/browse/~br=trunk/ofbiz/trunk/applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml?r=1328827#to54]:
>  if-compare is "Did the user submit mimeTypeId form field, but remove the 
> value, submitting a blank form field?"  This is the weird case, as really 
> this should be a is-null check.
> My question is why are we even doing any of this when the event just goes on 
> to set the mimeType to what the web browser decided it was, and then to call 
> createContentFromUploadedFile service?  Also, if mimeTypeId is in fact empty, 
> the call to createContentFromUploadedFile calls createDataResource, which at 
> applications/content/script/org/ofbiz/content/data/DataServices.xml:53 calls 
> org.apache.tika.Tika#detect(byte[]) to detect the mimeType anyway.  Why not 
> just let tika handle the mimeType?
> Anyway, I dunno enough about the Content component to make the decision here. 
>  I've attached three different patches.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OFBIZ-6770) createCustRequestContent Hasn't worked in 6 years and 7 months

2015-12-15 Thread Jacques Le Roux (JIRA)

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

Jacques Le Roux commented on OFBIZ-6770:


Which field (did not look into details yet)?

> createCustRequestContent Hasn't worked in 6 years and 7 months
> --
>
> Key: OFBIZ-6770
> URL: https://issues.apache.org/jira/browse/OFBIZ-6770
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Release Branch 11.04, Release Branch 12.04, Release 
> Branch 13.07, Release Branch 14.12, Trunk
>Reporter: Forrest Rae
> Attachments: OFBIZ-6770-option1.patch, OFBIZ-6770-option2.patch, 
> OFBIZ-6770-option3.patch
>
>
> This commit disabled the mimeTypeId argument in 
> applications/order/widget/ordermgr/CustRequestForms.xml, in order to provide 
> "various fixes"
> https://fisheye6.atlassian.com/changelog/ofbiz?cs=768661
> I wonder how many people have been frustrated by this when looking for 
> example code on how to upload documents.
> This patch isn't really a fix, but more of a work around.  The issue lies in 
> the seemly arbitrary check of the mimeTypeId parameter in 
> applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml, 
> lines 52-54.
> First if-compare is "Does the web browser's choice of mimeTypeId equal what 
> the user thinks the mimeTypeId is?"
> Second if-compare is "Did the user select anything at all in the mimeTypeId 
> dropdown?"
> Third choice is "Did the user submit mimeTypeId form field, but remove the 
> value, submitting a blank form field?"
> My question is why are we even doing any of this when the event just goes on 
> to set the mimeType to what the web browser decided it was, and then to call 
> createContentFromUploadedFile service?  Also, if mimeTypeId is in fact empty, 
> the call to createContentFromUploadedFile calls createDataResource, which at 
> applications/content/script/org/ofbiz/content/data/DataServices.xml:53 calls 
> org.apache.tika.Tika#detect(byte[]) to detect the mimeType anyway.  Why not 
> just let tika handle the mimeType?
> Anyway, I dunno enough about the Content component to make the decision here. 
>  I've attached three different patches.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (OFBIZ-6770) createCustRequestContent Hasn't worked in 6 years and 7 months

2015-12-15 Thread Pierre Smits (JIRA)

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

Pierre Smits commented on OFBIZ-6770:
-

To which release (and/or release branch) is this issue actually refering, 
because the field is commented out in trunk and in release branch 14.12?

> createCustRequestContent Hasn't worked in 6 years and 7 months
> --
>
> Key: OFBIZ-6770
> URL: https://issues.apache.org/jira/browse/OFBIZ-6770
> Project: OFBiz
>  Issue Type: Bug
>  Components: order
>Affects Versions: Release Branch 11.04, Release Branch 12.04, Release 
> Branch 13.07, Release Branch 14.12, Trunk
>Reporter: Forrest Rae
> Attachments: OFBIZ-6770-option1.patch, OFBIZ-6770-option2.patch, 
> OFBIZ-6770-option3.patch
>
>
> This commit disabled the mimeTypeId argument in 
> applications/order/widget/ordermgr/CustRequestForms.xml, in order to provide 
> "various fixes"
> https://fisheye6.atlassian.com/changelog/ofbiz?cs=768661
> I wonder how many people have been frustrated by this when looking for 
> example code on how to upload documents.
> This patch isn't really a fix, but more of a work around.  The issue lies in 
> the seemly arbitrary check of the mimeTypeId parameter in 
> applications/order/script/org/ofbiz/order/request/CustRequestEvents.xml, 
> lines 52-54.
> First if-compare is "Does the web browser's choice of mimeTypeId equal what 
> the user thinks the mimeTypeId is?"
> Second if-compare is "Did the user select anything at all in the mimeTypeId 
> dropdown?"
> Third choice is "Did the user submit mimeTypeId form field, but remove the 
> value, submitting a blank form field?"
> My question is why are we even doing any of this when the event just goes on 
> to set the mimeType to what the web browser decided it was, and then to call 
> createContentFromUploadedFile service?  Also, if mimeTypeId is in fact empty, 
> the call to createContentFromUploadedFile calls createDataResource, which at 
> applications/content/script/org/ofbiz/content/data/DataServices.xml:53 calls 
> org.apache.tika.Tika#detect(byte[]) to detect the mimeType anyway.  Why not 
> just let tika handle the mimeType?
> Anyway, I dunno enough about the Content component to make the decision here. 
>  I've attached three different patches.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)