mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-27 15:19:57 +09:00
페이징 버그 수정:inst_num>groupby_num>orderby_num() 단계적 적용
git-svn-id: http://xe-core.googlecode.com/svn/trunk@1942 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
c2fab6070f
commit
c399c27605
1 changed files with 16 additions and 7 deletions
|
|
@ -575,14 +575,23 @@
|
||||||
|
|
||||||
if(count($output->groups)) $query .= sprintf(' group by %s', implode(',',$output->groups));
|
if(count($output->groups)) $query .= sprintf(' group by %s', implode(',',$output->groups));
|
||||||
|
|
||||||
if($output->order) {
|
if ($output->order) {
|
||||||
foreach($output->order as $key => $val) {
|
foreach($output->order as $key => $val) {
|
||||||
$index_list[] = sprintf('%s %s', $val[0], $val[1]);
|
$index_list[] = sprintf('%s %s', $val[0], $val[1]);
|
||||||
}
|
}
|
||||||
if(count($index_list)) $query .= ' order by '.implode(',',$index_list);
|
if(count($index_list)) $query .= ' order by '.implode(',',$index_list);
|
||||||
|
$query = sprintf('%s for orderby_num() between %d and %d', $query, $start_count, $list_count);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
if (count($output->groups))
|
||||||
|
$query = sprintf('%s having groupby_num() between %d and %d', $query, $start_count, $list_count);
|
||||||
|
else {
|
||||||
|
if ($condition)
|
||||||
|
$query = sprintf('%s and inst_num() between %d and %d', $query, $start_count, $list_count);
|
||||||
|
else
|
||||||
|
$query = sprintf('%s where inst_num() between %d and %d', $query, $start_count, $list_count);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
$query = sprintf('%s for orderby_num() between %d and %d', $query, $start_count, $list_count);
|
|
||||||
|
|
||||||
$result = $this->_query($query);
|
$result = $this->_query($query);
|
||||||
if($this->isError()) {
|
if($this->isError()) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue