';
+
+
+
+
+ |
+ |
+ |
+ |
+ |
+
+
+
- rows += '';
- rows += logData['dateOccurred'];
- rows += ' | ';
+
+
- rows += '';
- var typeId = logData['typeId'];
- var typeDescription;
- if ( typeId )
- typeDescription = typeDescriptions[typeId];
- if ( ! typeDescription ) {
- // this should never occur but just in case
- typeDescription = '['+typeId+']';
- }
- rows += typeDescription;
- rows += ' | ';
- rows += '';
- if ( logData['userId'] ) {
- rows += definePortraitPopover(logData['userPortraitId'], logData['userId'], logData['userName'], logData['userName']);
- } else {
- rows += '-';
- }
- rows += ' | ';
- rows += '';
- if ( logData['targetUserId'] ) {
- rows += definePortraitPopover(logData['targetUserPortraitId'], logData['targetUserId'], logData['targetUserName'], logData['targetUserName']);
- } else {
- rows += '-';
- }
- rows += ' | ';
-
- rows += '';
- var lesson = null, activity = null, description = null, lineCount = 0;
- if ( logData['lessonId'] ) {
- lesson = LESSON_LABEL.replace('{0}',logData['lessonName']).replace('{1}',logData['lessonId']);
- lineCount++;
- }
- if ( logData['activityId'] ) {
- activity = ACTIVITY_LABEL.replace('{0}',logData['activityName']).replace('{1}',logData['activityId']);
- lineCount++;
- }
- if ( logData['description'] ) {
- description = logData['description'];
- lineCount++;
- }
- if ( lesson != null ) {
- rows+=lesson;
- if ( lineCount > 1 )
- rows+=' ';
- }
- if ( activity != null ) {
- rows+=activity;
- if ( lineCount > 1 )
- rows+=' ';
- }
- if ( description != null ) {
- rows+=description;
- }
- rows += ' | ';
-
- rows += '
';
- }
-
- json.total = data.total_rows;
- json.rows = $(rows);
- return json;
-
- }
- },
- customAjaxUrl: function(table, url) {
- var startDate = $("#startDatePicker").datepicker("getDate");
- if ( startDate )
- url += "&startDate="+startDate.getTime();
- var endDate = $("#endDatePicker").datepicker("getDate");
- if ( endDate )
- url += "&endDate="+endDate.getTime();
- var area = $("#areaMenu").val();
- if ( area )
- url += "&area="+area;
- var typeId = $("#typeMenu").val();
- if ( typeId )
- url += "&typeId="+typeId;
- return url;
- },
- })
- .bind('pagerInitialized pagerComplete', function(event, options){
- if ( options.totalRows == 0 ) {
- $.tablesorter.showError($(this), '