field processing indicator puzzle

field processing indicator puzzle

LimpEmuLimpEmu Posts: 65Questions: 18Answers: 1

I am wondering whether there might be a conflict between having bootstrap loaded and using the default display controller (lightbox). The page was previously developed without bootstrap styles, works without problems without bootstrap, and I do not want to change the current setup as lightbox is fine and looks good.

The problem I am running into is that for some strange reason, the field processing indicator for one of the fields is active when a record is opened in editor. The field, that the field processing indicator is active for, is the one field with a dependency.

I was able to turn the field processing indicator off (see below), but I am wondering why I am encountering this problem.

Mainly I want to make sure that there is no bigger problem that I should be aware of. Is there a list of known issues relating to loading bootstrap and using the lightbox display controller?

Thank you for your kind feedback,
Beate

editor.dependent( 'resolve', function ( val,data ) {
   if (data.row.resolve == "Y") return {
        messages: {'resolve':'<span class="spit">'+data.row.resolvestatus+'</span>'}
   };
    /* get rid of field processing indicators! */
    var prcssInds=$('.DTE_Processing_Indicator');
    for (var i=1; i<prcssInds.length; i++) {
        if (prcssInds[i].outerHTML.indexOf("field-processing") >= 0) {
            prcssInds[i].style.display="none";
        }
    }
});

Replies

  • colincolin Posts: 15,144Questions: 1Answers: 2,586

    Hi @LimpEmu ,

    I believe that's a bug in Editor 1.8.0, which will be fixed in pending 1.8.1 release due out early next week. If your callback doesn't return anything then it assumes the callback is still processing - you could modify your callback or try again when the release is cut (should be a day or two),

    Cheers,

    Colin

  • allanallan Posts: 61,723Questions: 1Answers: 10,108 Site admin

    Actually, the 1.8.1 release won't change the behaviour, but it will clarify this in the documentation.

    If you don't return anything that Editor assumes you are going to use a callback function to tell it when an async command is complete.

    Add return {}; to your function to resolve the issue.

    Allan

  • LimpEmuLimpEmu Posts: 65Questions: 18Answers: 1

    Thank you for your responses!

    I see your point Alan, when the condition isn't met I am not returning anything! Added that, and voila, problem fixed!

    I apologize for my late reply, I do not get e-mail notifications and was absorbed in other puzzles ...

  • rf1234rf1234 Posts: 2,808Questions: 85Answers: 406

    Thanks for mentioning this. Had a hard time getting rid of these indicators. I use "dependent" about a million times and usually don't return anything. Thank god I call a certain routine "on open" of all of my Editor instances. Just added this and I don't get bothered any longer. It doesn't turn off the global processing indicator in the upper right of the form. If you just select the class DTE_Processing_Indicator the global one gets turned off as well.

    ...........
    $('*[data-dte-e="field-processing"][class="DTE_Processing_Indicator"]').addClass('hidden');
    
This discussion has been closed.