hi,
I am trying to implement the following example
https://docs.telerik.com/kendo-ui/api/javascript/ui/orgchart/configuration/editable.fields
But it doesn't seem to work even on the website
Am I right?
I expect that after the implementation I will not be able to edit the fields shown in the edit popup.
3 Answers, 1 is accepted
Hi Ruth,
The described issue is due to a mistake in the demonstrated example in the API. If you don't want your OrgChart to be "editable" you should set the "editable" option to false like the snippet below:
editable: false
Here is the dojo example where this is demonstrated.
We will update the example in the API accordingly as soon as possible. As a small token of gratitude for reporting an issue in our documentation, I have updated your Telerik points.
Regards,
Lyuboslav
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.
Hi Lyuboslav,
Thanks for your response, The solution you offer completely blocks the possibility of viewing the data,
I want the popup to open but it will only be possible to view the data and not edit it.
and I want it like that:
Hello Ruth,
Thanks for your screenshots.
To disable the inputs in the ORgChart editor form you can use the editorOptions configuration that will allow you to customize the items in the Form that is integrated into the OrgChart. After that, you could set the option "enable" to 'false' as demonstrated below:
form: {
items: [{
field: "title",
label: "Position",
editor: "DropDownList",
editorOptions:{
enable: false
}
}]
The above example is summarized in this sample dojo.
Another opinion is to handle the "edit" event, and get the reference to all inputs in the form. Then you can add the "disabled" attributes to the inputs. This is demonstrated in the Dojo linked here.
edit:function(e){
setTimeout(()=>{
var form = [...$('*input')];
form.forEach(el=>el.disabled = 'disabled');
},0)
},
I hope this will help you to reach your goal.
Regards,
Lyuboslav
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.
This is exactly what I need,
Thanks for your help!