I have the following kendo grid with a sub grid triggered by the ClientDetialTemplateId attribute, which is working correctly before I update the NewtonSoft version. I have verified the only changes to the solutions are the config files and removed/added package files.
@(Html.Kendo().Grid<SurgeryConsent.Web.Models.PatientSearch.NAMES>()
.Name("gridPatients")
.Columns(col =>
{
col.Bound(m => m.NAME_FIRST).Title("First Name");
col.Bound(m => m.NAME_LAST).Title("Last Name");
col.Bound(m => m.SEX).Title("SEX");
col.Bound(m => m.DOB).Title("DOB");
col.Bound(m => m.MRN).Title("MRN");
col.Bound(m => m.PERSON_ID).Title("Person ID").Hidden();
})
.Pageable()
.Sortable()
.ClientDetailTemplateId("TheVisits")
.DataSource(dataSource =>
{
dataSource.Ajax()
.Read(read => read.Action("GetPatientSearch", "Patient").Data("patientSearch.additionalData"))
.PageSize(10)
.ServerOperation(false)
.Events(events =>
{
events.RequestEnd("patientSearch.grdPatients_ajax_onRequestEnd");
});
})
)
@section Scripts {
<script id="TheVisits" type="text/kendo-tmpl">
<div>
@(Html.Kendo().Grid<SurgeryConsent.Web.Models.PatientVisits.ENCOUNTERS>()
.Name("grid_#=PERSON_ID#")
.Columns(col =>
{
col.Bound(m => m.FIN).Title("FIN");
col.Bound(m => m.REG_DT_TM).Title("Admit Date").Format(dateTimeFormat);
col.Bound(m => m.LOCATION).Title("Location");
col.Bound(m => m.STATUS).Title("Status");
col.Bound(m => m.ENCNTR_ID).Title("ENCNTR_ID").Hidden();
col.Bound(m => m.PERSON_ID).Title("PERSON_ID").Hidden();
col.Command(c => c.Custom("Select").Click("patientSearch.directToPdfCreator")).Title(" ");
})
.DataSource(dataSource => dataSource
.Ajax()
.PageSize(10)
.Read(read => read.Action("TheVisits", "Patient", new { PERSON_ID = "#=PERSON_ID#" }))
.Sort(s =>
{
s.Add("STATUS").Ascending();
s.Add("REG_DT_TM").Descending();
})
)
.Events(events => events.DataBound("DisplayNoRecordMessage"))
.Sortable()
.ToClientTemplate()
)
</div>
</script>
}
By placing a break point at the function Patient/TheVisits, it's clear that something went wrong & the function is never hit. Can anyone give me some idea?