I have grid which displays a group of records. Then some custom actions to perform on this records. One of the custom actions will open a popup window which displays another grid with child information about the original table. I'm doing this by passing a custom query string with the parent key.
In this child table, when I try to create a new record, the foreign key that is passing to the controller is 0 event though when editing, the binding will show the correct value. Through jquery I'm able to read the parentID and put it in a hidden field in the child screen, but when submitting, is goes as 0 again even though it has a number on it. The only way I'm able to solve the issue is by passing a value directly to the model in the child window in the OnEdit event like this:
Anyone knows why is passing a 0 value although I'm assigning a value for it: $("#GroupID").val($("#txtGroupID").val());