Hi. I am testing IgniteUI 2012.2's igGrid in RowEditTemplate update mode within MVC/Razor. I noticed that when I am in "row" mode, the igCombo displays the value from the cell properly. However, when utilizing the RowEditTemplate mode, the value in the igCombo is blank. Is there anything special that need to be done to display the value that should be passed from the grid row to the R.E.T? I am just pulling a country list from a ViewData to populate the combobox. Nothing fancy is going on within the project.
Here are my js script calls:
<script src="~/Scripts/modernizr-1.7.min.js" type="text/javascript"></script> <script src="~/scripts/jquery.min.js" type="text/javascript"></script> <script src="~/scripts/jquery-ui.min.js" type="text/javascript"></script> <script src="~/scripts/jquery.tmpl.min.js" type="text/javascript"></script> <script src="~/Scripts/js/infragistics.loader.js"></script>
Here is my loader:
@(Html.Infragistics().Loader() .ScriptPath(Url.Content("~/Scripts/js/")) .CssPath(Url.Content("~/Content/css/")) .Resources("igEditors,igCombo,igValidator,igGrid.Updating") //.Theme("Metro") .Render() )
My Update call for the column is:
settings.ColumnSetting().ColumnKey("Region").EditorType(ColumnEditorType.Combo).ComboEditorOptions(options => { options.ValidatorOptions(option => { option.KeepFocus(ValidatorKeepFocus.Never); option.BodyAsParent(false); option.Required(true); }); options .DataSource(ViewData["RegionDS"]) .TextKey("name") .ValueKey("id") .AllowCustomValue(false) .Mode(ComboMode.DropDown); });
The template pulls up fine if I display as a text field. Can you provide an explanation based on my snippets and/or provide a sample?
Thanks
Hello sirplaya ,
Thank you for the details. After some investigation I believe that this behavior could be caused by an issue in the rowEditTemplate functionality therefore I log it in our issue tracking system with the id of 130199. In order to track the progress of the issue I have created a private support ticket for you with the id of CAS-107608-P8N9V5. This way you will be notified as soon as our developers suggest a resolution for this behavior.
I will provide you with more details through the support ticket.
Hello sirplaya,
While we release the service release containing the resolution for this issue you can set the text manually. In order to do so you can handle the rowEditDialogOpened event and get the dom element for the combo. Then using the igCombo api you can set the text property to the current value:
rowEditDialogOpened: function (event, ui) {
var comboInput = $("td[data-key='Color']").find('input');
comboInput.igCombo('text', comboInput.data('igCombo').options.value);
},
Hi Elena,
Can you look at the file attached, its a modified code of your that should support LookUp ID on combo. We tried to fix this via formatter function but at some point we have null issue when dealing with multiple combos.
thanks ,
Hello Simplicio,
The resolution for this issue has been included for IgniteUI_20122_2086 . For additional reference please check the attached sample. If the issue still persist on your side even with this release would you please modify the my sample in order to represent it so I can continue my research on the matter.
Thanks in advance.
Hi Elana,
We have the same issue we install the IgniteUI_20122.2086_SR, but we have the same issue. can you verify if this was fixed on hotfix?
The service release containing the fix for your issue is out, you can download it from: https://ko.infragistics.com/my-account/keys-and-downloads/
I'd be glad to receive a feedback on the outcome.
Hello,
I'll certainly give this a try and report back on the results. Thanks for the prompt response.