show tables filtering by instance id.
This commit is contained in:
parent
803409f151
commit
5780eb5bbe
2 changed files with 55 additions and 32 deletions
|
@ -174,20 +174,6 @@ class Application_Service_HistoryService
|
|||
" LEFT JOIN {$filter} USING(history_id)";
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
//need to count the total rows to tell Datatables.
|
||||
$stmt = $this->con->prepare($mainSqlQuery);
|
||||
foreach ($paramMap as $param => $v) {
|
||||
$stmt->bindValue($param, $v);
|
||||
}
|
||||
|
||||
if ($stmt->execute()) {
|
||||
$totalRows = $stmt->rowCount();
|
||||
}
|
||||
else {
|
||||
$msg = implode(',', $stmt->errorInfo());
|
||||
throw new Exception("Error: $msg");
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------
|
||||
//Using the instance_id to filter the data.
|
||||
|
@ -199,6 +185,21 @@ class Application_Service_HistoryService
|
|||
|
||||
$paramMap["instance"] = $instanceId;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------
|
||||
//need to count the total rows to tell Datatables.
|
||||
$stmt = $this->con->prepare($mainSqlQuery);
|
||||
foreach ($paramMap as $param => $v) {
|
||||
$stmt->bindValue($param, $v);
|
||||
}
|
||||
|
||||
if ($stmt->execute()) {
|
||||
$totalRows = $stmt->rowCount();
|
||||
}
|
||||
else {
|
||||
$msg = implode(',', $stmt->errorInfo());
|
||||
throw new Exception("Error: $msg");
|
||||
}
|
||||
|
||||
//------------------------------------------------------------------------
|
||||
//Using Datatables parameters to sort the data.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue