Html.Kendo().Grid(Of SPIMS.ViewModel.EventViewModel.Index)() _ .Name("grid") _ .Columns(Sub(c) c.Bound(Function(p) p.ID).HeaderHtmlAttributes(New With {.style = "text-align: center; font-weight: bold"}).Width(10) c.Bound(Function(p) p.CreatedDate).Width(20).Title("Date").HeaderHtmlAttributes(New With {.style = "text-align: center; font-weight: bold"}).ClientTemplate("#=CreatedDate ? kendo.format('{0:dd-MMM-yy}', kendo.parseDate(CreatedDate)) : ''#") c.Bound(Function(p) p.Source).HeaderHtmlAttributes(New With {.style = "text-align: center; font-weight: bold"}).Width(20) c.Bound(Function(p) p.Message).HeaderHtmlAttributes(New With {.style = "text-align: center; font-weight: bold"}).Width(50).Title("Description") c.Command(Sub(commands) commands.Custom("View").Click("showDetails") End Sub).Title(" ").Width(10) End Sub) _ .Pageable(Sub(pager) pager.Input(True) pager.Numeric(True) pager.Input(True) pager.PreviousNext(True) pager.Refresh(True) pager.PageSizes(True) pager.ButtonCount(10) End Sub) _ .Sortable(Function(sorting) sorting.AllowUnsort(True)) _ .Filterable() _ .Scrollable() _ .HtmlAttributes(New With {.style = "height:450px;width:900px;"}) _ .DataSource(Sub(d) d.Ajax() _ .PageSize(10) _ .Model(Sub(model) model.Id(Function(p) p.ID)) _ .ServerOperation(True) _ .Read(Function(read) read.Action("Model_Read", "Event")) End Sub).Render()
<script type="text/x-kendo-template" id="template"> <div id="details-container"> <div id="hand_left" style="float:left; width:100px;height:150px"> <br /> <i>ID: </i> <br /><br /> <i>Date: </i> <br /><br /> <i>Source: </i> <br /><br /> <i>Description: </i> </div> <div id="hand_right" style="text-align:left;width:380px"> <br /> <b>#= ID #</b> <br /><br /> <b>#= CreatedDate #</b> <br /><br /> <b>#= Source #</b> <br /><br /> <b>#= Message #</b> </div> </div> </script>
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)