Uploaded image for project: 'OFBiz'
  1. OFBiz
  2. OFBIZ-6084

Find account doesn't return accounts anymore

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Blocker
    • Resolution: Fixed
    • Affects Version/s: Trunk, 14.12.01
    • Fix Version/s: 16.11.01
    • Component/s: marketing
    • Labels:

      Description

      Since after r13.07 searching for accounts in the SFA application no results are displayed anymore.

      1. OFBIZ-6084.patch
        1.0 kB
        Deepak Dixit
      2. OFBIZ-6084.patch
        1.0 kB
        Deepak Dixit

        Issue Links

          Activity

          Hide
          deepak.dixit Deepak Dixit added a comment -

          Thanks Adrian.

          Show
          deepak.dixit Deepak Dixit added a comment - Thanks Adrian.
          Hide
          pfm.smits Pierre Smits added a comment -

          Thanks, Adrian.

          Show
          pfm.smits Pierre Smits added a comment - Thanks, Adrian.
          Hide
          adrianc@hlmksw.com Adrian Crum added a comment -

          Fixed in rev 1661760. Thanks!

          Show
          adrianc@hlmksw.com Adrian Crum added a comment - Fixed in rev 1661760. Thanks!
          Hide
          deepak.dixit Deepak Dixit added a comment -

          Here is the patch with isEmpty() condition.

          Show
          deepak.dixit Deepak Dixit added a comment - Here is the patch with isEmpty() condition.
          Hide
          deepak.dixit Deepak Dixit added a comment - - edited

          Thanks Adrian,

          type not set in forms.xml, Please refer FoundWorkEfforts form at component://workeffort/widget/WorkEffortForms.xml for reference.
          As we have handling at ModelForm.java that if type is missing and parentForm exists then we are using the parentFrom.type.
          Either we can use that condition in ModelSingleForm.java (that is unnecessary) or we can add empty check for type as well.

          if (parentElement.getAttribute("name").equals(parentForm)
                                      && (formType.isEmpty() || formType.equals(parentElement.getAttribute("type")))) {
          
          Show
          deepak.dixit Deepak Dixit added a comment - - edited Thanks Adrian, type not set in forms.xml, Please refer FoundWorkEfforts form at component://workeffort/widget/WorkEffortForms.xml for reference. As we have handling at ModelForm.java that if type is missing and parentForm exists then we are using the parentFrom.type. Either we can use that condition in ModelSingleForm.java (that is unnecessary) or we can add empty check for type as well. if (parentElement.getAttribute( "name" ).equals(parentForm) && (formType.isEmpty() || formType.equals(parentElement.getAttribute( "type" )))) {
          Hide
          adrianc@hlmksw.com Adrian Crum added a comment -

          I added the type check as a validation - so you can't extend a single form to a list form (or the other way around). It would be better to find out why the form type is empty and fix it.

          Show
          adrianc@hlmksw.com Adrian Crum added a comment - I added the type check as a validation - so you can't extend a single form to a list form (or the other way around). It would be better to find out why the form type is empty and fix it.
          Hide
          deepak.dixit Deepak Dixit added a comment -

          Here is the patch for this issue, IMO we can remove the problematic condition, as in ModelForm.java if type is null then it check for parentForm type and used it for the same. So instead of adding this check here we can remove the the condition.

          Hi Adrian Crum please have a look at it as its added at r1654670.

          Show
          deepak.dixit Deepak Dixit added a comment - Here is the patch for this issue, IMO we can remove the problematic condition, as in ModelForm.java if type is null then it check for parentForm type and used it for the same. So instead of adding this check here we can remove the the condition. Hi Adrian Crum please have a look at it as its added at r1654670.
          Hide
          deepak.dixit Deepak Dixit added a comment -

          I am able to figure out the root cause, In ModelSingleForm.java if

          (parentElement.getAttribute("name").equals(parentForm)
                                      && formType.equals(parentElement.getAttribute("type"))) {
          

          This condition causes issue, Here formType is empty hence condition fails and it fails to get the parentForm.

          Show
          deepak.dixit Deepak Dixit added a comment - I am able to figure out the root cause, In ModelSingleForm.java if (parentElement.getAttribute( "name" ).equals(parentForm) && formType.equals(parentElement.getAttribute( "type" ))) { This condition causes issue, Here formType is empty hence condition fails and it fails to get the parentForm.
          Hide
          deepak.dixit Deepak Dixit added a comment -


          All the form that are using extends and extend-resource is not set (extended forms exists in same file) are broken, if we pass the extend-resource then its working fine.

          Show
          deepak.dixit Deepak Dixit added a comment - All the form that are using extends and extend-resource is not set (extended forms exists in same file) are broken, if we pass the extend-resource then its working fine.
          Hide
          pfm.smits Pierre Smits added a comment -

          It seems the issue is bigger than I anticipated.

          Thanks for spotting the other, Deepak.

          Show
          pfm.smits Pierre Smits added a comment - It seems the issue is bigger than I anticipated. Thanks for spotting the other, Deepak.
          Hide
          deepak.dixit Deepak Dixit added a comment -
          Show
          deepak.dixit Deepak Dixit added a comment - FindWorkEffort also broken, https://localhost:8443/workeffort/control/FindWorkEffort

            People

            • Assignee:
              adrianc@hlmksw.com Adrian Crum
              Reporter:
              pfm.smits Pierre Smits
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development