How java script will work when field editor component in edit mode?

edited August 2017 in Questions
I have written javascript it's working only when "field editor” is on “read and edit inline” mode ,It's
not working when "field editor"  is on "edit" mode .

Comments

  • edited August 2017
    vicky,

    I think you have a custom render (javascript) that works in 'read and edit inline' mode, but not 'edit' mode.  You will need to add to your javascript snippet some code to tell Skuid what to display when in 'edit' mode.  Here is a simple example:

    //render the field in read and edit mode
    if(field.mode == 'read') {
        
        skuid.ui.fieldRenderers.STRING.read(field, value);
    }
    if(field.mode == 'edit') {
        
        skuid.ui.fieldRenderers.STRING.edit(field, value);
    }
    Thanks,

    Bill
  • edited August 2017
    Thanks Bill.
Sign In or Register to comment.