module fields not available in process definition

My users are not able to create process definitions based on the Tasks module. None of the fields for this module show up as available for evaluation. I have tried accessing these fields from a process definition based on a related module, but the fields dropdown just sticks at "loading..." The Tasks module works fine otherwise, including with various post-save hooks I have created. I have checked my Vardefs, which look fine, and so I am stuck. Any suggestions?

  • Hi Andrew Rappaport,

    I believe Andres Lopez is referring to Defect 79009. If this is a fit, here are some troubleshooting steps you can follow to confirm the root cause:

    Symptom:

    1. In the design canvas of the process definition, drop an Action element and set Action Type to Change Field
    2. Ensure the URL does not have index.php in the URL, so it goes straight through: .com/#pmse_Project/
    3. Right click on the Action element and select Settings to try to open the setting configurator.

    Result:
    The screen infinitely shows "Loading..."

    Chrome's Console shows:

    pmse.ui.min.js?v=n_uoNg_14JZtBsU40q9-Jg:501
    Uncaught Error: _toOptionsArray(): The parameter must be an object or array.
    at UpdaterField._toOptionsArray (pmse.ui.min.js?v=n_uoNg_14JZtBsU40q9-Jg:501)
    at UpdaterField.setOptions (pmse.ui.min.js?v=n_uoNg_14JZtBsU40q9-Jg:502)
    at SugarProxy.success (pmse.designer.min.js?v=n_uoNg_14JZtBsU40q9-Jg:374)
    at Object.success (pmse.ui.min.js?v=n_uoNg_14JZtBsU40q9-Jg:364)
    at Object.params.success (sugarapi.js:637)
    at j (eval at module.exports (addScript.js:9), <anonymous>:2:27309)
    at Object.fireWith [as resolveWith] (eval at module.exports (addScript.js:9), <anonymous>:2:28122)
    at x (eval at module.exports (addScript.js:9), <anonymous>:5:22111)
    at XMLHttpRequest.b (eval at module.exports (addScript.js:9), <anonymous>:5:26030)

    Additional Information:
    To use the browser to confirm this field and dropdown list are the root cause of the issue, do the following:

    1. With console open and the error showing, click on pmse.ui.min.js?v=n_uoNg_14JZtBsU40q9-Jg:501 to the right of the error to open the JS in the Sources tab as shown here: https://www.screencast.com/t/lvtnNTjnjF
    2. Click the { } button at the bottom to Pretty Print the JS file as shown here: https://www.screencast.com/t/0myk61sERsIk
    3. Right click the number of the highlighted line throwing the error and Add breakpoint, as shown here: https://screencast.com/t/rNsUdFejx5I
    4. Double-click the obj in the previous line to select it
    5. Right click and Add selected text to watches, as shown here: https://screencast.com/t/32CwpjmQSUV
    6. Keeping Sources open in the console, refresh the browser page looking at the design canvas.
    7. Right-click on the Action element to reproduce the error

    Result:

    In the Watch side-section to the right of the Sources page shows -- obj: "bad_data_list"

    8. In the file system of the instance, grep the custom/Extensions/modules/ directory to find out which field is using this non-existent dropdown list.

    Note that this is also reproducible in definitions targeting modules related to the culprit module in which the Action element calls to the culprit module, for example if the Action element creates a new record in the culprit module. For this reason, do not grep from the target module's directory, but look at all modules by running the grep from the custom/Extensions/modules/ directory.

    Workarounds when you have hit this defect:

    Make a dropdown list with that name, and update the field definition in Studio to use that list, or configure the culprit field in Studio to use a list that exists.

    If the field was introduced in a custom Module Loadable package, which is the most likely cause for this, advise the case submitter that the custom package should be corrected to avoid this scenario.

    Note: That this same bug can show up when attempting to view the field of the affected module from a related module.
    In this case the list of fields never refreshes to show those that are appropriate to the selected related module.

    I hope this helps!