Ejemplo n.º 1
0
 /**
  * This is method parseListIDToArray with index correspond with suffix Table
  *
  * @param string $IDList List ID
  * @param int $intPage page index, <=0: get all
  * @param int $pageSize List ID
  * @param int $iType Loại ID cần parse. 1->alphabet; 6->month.
  * @author ThanhViet edited [20110516]
  */
 public function getListTableName($IDList, $intPage, $pageSize, $iType)
 {
     $arrDocInTable = array();
     //echo '$IDList:'.$IDList;
     if (!is_array($IDList)) {
         $IDList = global_common::splitString($IDList);
     }
     if ($intPage >= 1) {
         $IDList = global_common::getTopOfArray($IDList, ($intPage - 1) * $pageSize, $pageSize);
     }
     foreach ($IDList as $key) {
         $arrDocInTable[substr($key, 0, $iType)] .= '\'' . $key . '\',';
     }
     //echo 'getListTableName:<br>';
     //print_r($arrDocInTable);
     return $arrDocInTable;
 }