Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • pat 124 posts 346 karma points
    Dec 07, 2017 @ 13:10
    pat
    0

    buttons in partial render inside a partial does not work

    Hi all , I have two partial views one is listing records and second one is to Edit record. so in my listing View on click Edit I am loading second partial view in to a div inside the listing partial view. this is done sing ajax

    $.ajax({
                    url: "/Umbraco/Surface/RecManager/loadpartialforedit/?type=" + type + "&id=" + id + "&name=" + name + "&content=" + content  + "&enduser=" + enduser,
                    type: 'GET',
                    cache: false,
                    success: function(data) {
                        $('#placeholderforform').html(data);
                        $('#placeholderforform').fadeIn('fast');
                    }
                });
    

    this load Edit form but When I edit details and hit update button this view reopen in browser with out page layout.

    I have registered button click event on edit partial view but does same it reopen without page layout...

    below is my loadpartialforedit action on listing surfacecontroller

     public ActionResult loadpartialforedit(string type, string id, string name, string content, string enduser)
            {
               DRecordModel dr = new DRecordModel();           
                dr.name = name;
                dr.type = type;
                dr.id = id;
                dr.content = content;   
                dr.action = "update";          
                dr.enduser = enduser;
    
                return PartialView("EditD", dr);
    }
    

    any help would be higly appriciate

Please Sign in or register to post replies

Write your reply to:

Draft