Пример #1
0
 /**
  * 遍历 日志表
  *
  * @param $startId
  * @param $limit
  * @param $extend
  * @return array
  */
 public static function scanCeilingLog($startId, $limit, $extend = array())
 {
     try {
         $oModel = Model_Ppc_CeilingLog::data_access();
         $oModel->filter_by_op('id', APF_DB_MysqlAccessor::OP_GREATER_THAN, $startId);
         if (!empty($extend)) {
             foreach ($extend as $field => $value) {
                 $oModel->filter($field, $value);
             }
         }
         return $oModel->sort('id', 'ASC')->limit($limit)->get_all();
     } catch (Exception $e) {
         return array();
     }
 }
 private function getBrokerPPCCeilingLogList($startId, $limit = self::BATCH_LIMIT)
 {
     $condition = array('ceilingDay' => date('Ymd', strtotime('-1 day')), 'siteType' => Model_Ppc_CeilingLog::SITE_TYPE_AJK);
     return Model_Ppc_CeilingLog::scanCeilingLog($startId, $limit, $condition);
 }