I followed this article for a simple CRUD operation with MVC.
I binded edit button click as suggested in that article, like
$(".editDialog").live("click", function (e) {
var url = $(this).attr('href');
$("#dialog-edit").dialog({
title: 'Edit Employee Detail',
autoOpen: false,
resizable: false,
height: 455,
width: 550,
show: { effect: 'drop', direction: "up" },
modal: true,
draggable: true,
open: function (event, ui) {
$(this).load(url);
},
close: function (event, ui) {
$(this).dialog('close');
}
});
$("#dialog-edit").dialog('open');
return false;
});
but, when I click on the edit button, its calling the controller action only once, when I click on that for second time, same info which was loaded while the page load is coming again.
I need to call the controller action, each time when I click on edit button. Can any one help me in this. Thanks in advance.