I have a View in my SQL database defined in BackEndServices for my project.
When the following view runs, I get an "Uncaught TypeError: undefined is not a function" with my datasource.
Any thoughts?
<div data-role="view" data-title="TheTest" data-layout="main" data-show="onShow"> <!--Page Title--> <div data-bind="html: title" class="pagetitle">INSPECTIONS</div> <!--ListView Headings--> <div> <table> <tr> <td style="width: 50%"> NAME </td> <td style="width: 50%"> DATE UPLOADED </td> </tr> </table> </div> <!--List of Inspections for the company--> <div><ul id="attachmentList"></ul></div></div><script> // attachments DataSource var attachments = new kendo.data.dataSource({ type: 'everlive', transport: { typeName: 'dbo_View_InspectionAttachments' }, schema: { model: { fields: { 'Id': { type: 'number' }, 'fileName': { type: 'string' }, 'dateuploaded': { type: 'date' } } } }, serverFiltering: true, filter: { logic: "and", filters: [ { field: 'inspectionid', operator: 'eq', value: 8385 }, { field: 'confidential', operator: 'eq', value: false } ] }, serverSorting: true, sort: { field: 'fileName', dir: 'asc' } });</script><script> function onShow(e) { //Find the attachment listview var attachList = e.view.content.find("#attachmentList"); // Passing template, datasource, and style to Attachment listview attachList.kendoListView({ template: "<div><table><tr><td style='width: 50%'><label>#: fileName #</label></td>" + "<td style='width: 50%'><label>#: dateuploaded #</label></td></tr></table></div>", style: "inset", dataSource: attachments }); }</script>