I have a custom editor template with all the fields on it. When a user adds a new record using the popup editor, I use jquery to show/hide some fields depending on what options are chosen in some dropdowns. This part works fine.
我有一个带有所有字段的自定义编辑器模板。当用户使用弹出编辑器添加新记录时,我使用jquery显示/隐藏一些字段,这取决于在某些下拉菜单中选择了哪些选项。这部分工作正常。
The problem I am running into is when a user tries to edit an existing record. All of the fields are displaying when I would want to evaluate what some of the dropdowns choices were and show/hide fields based on those dropdown selections.
我遇到的问题是当用户试图编辑现有记录时。当我想要评估一些下拉选项时,所有的字段都会显示出来,并基于这些下拉选项显示/隐藏字段。
I tried using the $(document).ready jquery function to evaluate certain controls but they always come back null.
我尝试使用$(文档)。准备好jquery函数来评估某些控件,但它们总是返回null。
How do I reference the selected option for a dropdown control in a popup editor for an existing record in a kendo mvc grid?
如何在弹出编辑器中引用kendo mvc网格中已有记录的下拉控件的选定选项?
1 个解决方案
#1
1
You can use the edit event of the grid. The container field of the event arguments contains all editing UI elements.
您可以使用网格的编辑事件。事件参数的容器字段包含所有编辑UI元素。
#1
1
You can use the edit event of the grid. The container field of the event arguments contains all editing UI elements.
您可以使用网格的编辑事件。事件参数的容器字段包含所有编辑UI元素。