On the Detail Edit page, I have a lookup field to the customer app to retrieve the customer name.
How to make the customer name field “customer_name” editable?
On the Detail Edit page, I have a lookup field to the customer app to retrieve the customer name.
How to make the customer name field “customer_name” editable?
Hi annaylee,
As the details of this app are a bit vague, could you check and see if utilizing the field mappings in a lookup field to manipulate other fields using app.record.create.change.<> (or app.record.edit.change.<>) would help you achieve the desired process?
More details about this can be found from the following post;
https://developer.kintone.io/hc/en-us/community/posts/4411297084953
Fields That Can Be Specified for “Field Mappings”:
https://get.kintone.help/k/en/id/040546.html
Please correct me if I have a different understanding.
Hopefully, this helps.
Hi Sean,
I am talking about how to enable the field that is returned from a lookup editable.
All the data fields that are returned from a lookup are grayed out and can’t be edited.
The customer_name is returned from the lookup. But the field is grayed out and I can’t edit it.
How to make the field editable?
Hi annaylee,
I apologize for the misunderstanding.
Could you try and see if the sample code below works for you?
Please save with UTF-8 encoding.
(function(){
'use strict';
kintone.events.on(['app.record.edit.show', 'app.record.create.show'], function(event){
event.record["customer_name"].disabled = false;
return event;
});
})();
Hopefully, this helps.