or
Timestamp: 21-3-2013 14:18:05
Error: TypeError: $(...).kendoValidator is not a function
Source File: http://localhost/nead/producten
Line: 909
$(document).ready(
function
() {
$(
'#addReview'
).hide();
var
validator = $(
"#addReview"
).kendoValidator().data(
"kendoValidator"
);
//status = $(".status");
$(
"<%=submit.ClientID %>"
).click(
function
() {
if
(validator.validate()) {
status.text(
"Hooray! Your tickets has been booked!"
)
.removeClass(
"invalid"
)
.addClass(
"valid"
);
}
else
{
status.text(
"Oops! There is invalid data in the form."
)
.removeClass(
"valid"
)
.addClass(
"invalid"
);
}
});
});
var _detailDataSource = new kendo.data.DataSource({
transport: {
read: {
type: "POST",
url: "/Admin/GetDetailUsage",
dataType: "json",
data: {
beginDate: function () {
return $('#beginDate').val();
},
endDate: function () {
return $('#endDate').val();
}
}
}
},
schema: {
model: {
fields: {
RequestId: { type: "number" },
RequestDate: { type: "date" },
Interface: { type: "string" },
ProviderName: { type: "string" },
EmployeeId: { type: "string" },
EmployeeName: { type: "string" },
EmployeeType: { type: "string" },
Department: { type: "string" }
}
}
},
pageSize: 20
});
function dashboardChart() {
$("#chart").kendoChart({
dataSource: _detailDataSource,
title: {
text: "Units sold"
},
series: [{
type: "area",
field: "RequestId",
aggregate: "count"
}],
categoryAxis: {
baseUnit: "weeks",
field: "RequestDate"
}
});
}
and then I call the chart like so: dashboardChart();
So, can someone tell me what I'm doing wrong? I want to aggregate the data from the datasource by week and display the number of Requests in an area chart.
Thanks,
Chad.