Skip to main content
Nintex Community Menu Bar
Question

Table : Field becoming read only after editing it

  • July 9, 2024
  • 8 replies
  • 0 views
  • Translate

Forum|alt.badge.img+1

we have a java script in field on a table. In this Field we are displaying different fields based on some pick list values.Before It was working fine .

when ever we tried to edit the this field its becoming readonly after editing it which was not happening before. Please find the code below :

var $ = skuid.$, model = arguments[0].model,
row = arguments[0].row ,
element = arguments[0].element;
var valueType = model.getFieldValue( row , ‘Data_Type__c’ );

function renderField( fieldName,defaultValue ){
var field = new skuid.ui.Field( row, model, null, { fieldId: fieldName, register: true } ),
value = model.getFieldValue( row , fieldName ) ||defaultValue;
console.log( field, value );
if(field && field.metadata && field.metadata.displaytype ){
//skuid.ui.fieldRenderers[field.metadata.displaytype][field.mode]( field, value );
console.log( fieldName + ’ rendered!', field.element );
skuid.ui.fieldRenderers[field.metadata.displaytype].edit( field, value );
}
return field.element;
}

switch ( valueType ){
case ‘Extended Amount’:
element.append(
//$(‘’).text(’ Qty: '),

        renderField( 'Quantity__c' ,''),
      //  $('<span>').text(' Unit: '),

        renderField( 'Unit__c','' ),
      //  $('<span>').text(' Rate: '),

        renderField( 'Rate__c','' ),
      //  $('<span>').text(' Total: '),

        renderField( 'Total__c' ,'') );
    break;

}

Did this topic help you find an answer to your question?

8 replies

Forum|alt.badge.img+2

As added clarification, we’ve attempted to configure a custom field renderer that renders a certain in table row based on the value of another field. For some reason, when a value is keyed into the rendered field, about 2 seconds after the last keystroke, the field becomes read-only (i.e. non-editable; italicized in yellow)–see screenshot. How can we modify the code to prevent this from happening?

Translate

Forum|alt.badge.img+3

Soundar - Please file a ticket with Skuid support as well. This issue is putting the release schedule at risk. Thanks!

Translate

Forum|alt.badge.img+17
  • Nintex Employee
  • 3763 replies
  • July 9, 2024

We’ll get back to you guys this morning on this.  I don’t think further escalation is necessary. 

Translate

Forum|alt.badge.img+17
  • Nintex Employee
  • 3763 replies
  • July 9, 2024

A few questions: 

1. What version of Skuid are you running?
2. Do you have any other components tied to this model and fields?  (We’ve especially found this to be a problem when you have a template component with an iFrame tied to the same model where you are doing data entry.  In this case the iFrame rerenders on any data change - which resets that field…
3. It doesn’t look like the full code is copied above.  There is only one case in your switch statement. 
4. What is the default mode of the table? Is it read only by default? 

Translate

Forum|alt.badge.img+17
  • Nintex Employee
  • 3763 replies
  • July 9, 2024

Would you mind giving us login rights to your org so we can take a look at what is going on?   Here is how: 

1. Use this tutorial to give us login rights: http://help.skuidify.com/m/getting-started/l/182412-getting-help-how-to-grant-skuid-login-rights-to-your-org

2. Then send an email to support@skuidify.com  with the following information: 

- Your org Id 

- The name of the page where the problem is happening 

- The steps required to reproduce the problem.  

We’ll see what’s going on...
Translate

Forum|alt.badge.img+1

Yes we can do that.thanks

Translate

Forum|alt.badge.img+8

Changing this line in your snippet…

var field = new skuid.ui.Field( row, model, null, { fieldId: fieldName, register: true } ),

to…

var field = new skuid.ui.Field( row, model, null, { fieldId: fieldName, register: true, mode: ‘edit’ } ),

should fix your issue.

Translate

Forum|alt.badge.img+1

Thanks. it resolved the issue.

Translate

Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie Settings