angularjs - spring boot html redirect -


i using angularjs along spring boot.

in restcontroller, passing in json object. end goal invoke new html.

 @requestmapping(value="loadpatientdetails", method=requestmethod.post)   public string loadpatientdetails(model model, @requestbody info patientinfo){         system.out.println("inside loadpatientdetails "+patientinfo.getid());         model.addattribute("json", new gson().tojson(patientinfo));      return "html2"; } 

my angularjs calling code following:

function (patientid){     return $http({         method : 'post',         url : '/loadpatientdetails',         data : patientid,         headers: {'content-type': 'application/json; charset=utf-8'}     }).then( function(status){         return status;     });; }; 

problem: getting complete html i.e. html2 in response.. need html2 should automatically rendered.

what missing?


Comments

Popular posts from this blog

javascript - Clear button on addentry page doesn't work -

c# - Selenium Authentication Popup preventing driver close or quit -

tensorflow when input_data MNIST_data , zlib.error: Error -3 while decompressing: invalid block type -