本文整理汇总了PHP中Helper_Config::getFTTProcessResumenCamera方法的典型用法代码示例。如果您正苦于以下问题:PHP Helper_Config::getFTTProcessResumenCamera方法的具体用法?PHP Helper_Config::getFTTProcessResumenCamera怎么用?PHP Helper_Config::getFTTProcessResumenCamera使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Helper_Config
的用法示例。
在下文中一共展示了Helper_Config::getFTTProcessResumenCamera方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: loadResumenCamera
public static function loadResumenCamera($dateEnd, $dateBegin)
{
$oBus = new Response_Business();
$MY =& MY_Controller::get_instance();
/* @var $mT_Analytics T_Analytics_Model */
$mT_Analytics = $MY->mT_Analytics;
/* @var $mDateTime_Generate Datetime_Generate_Model */
$mDateTime_Generate =& $MY->mDateTime_Generate;
/* @var $mResumen_Camera Resumen_Camera_Model */
$mResumen_Camera = $MY->mResumen_Camera;
$MY->db->trans_begin();
try {
$eDatetimeGenerate = $mDateTime_Generate->load(Helper_Config::getFTTProcessResumenCamera(), 'process_name');
if (!$eDatetimeGenerate->isEmpty()) {
$dateBegin = $eDatetimeGenerate->update_datetime;
}
$eDatetimeGenerate->process_name = Helper_Config::getFTTProcessResumenCamera();
$eDatetimeGenerate->update_datetime = $dateEnd;
$mDateTime_Generate->save($eDatetimeGenerate);
$result = $mT_Analytics->loadResumenCamera($dateEnd, $dateBegin);
$eResumenCameras = array();
if (!empty($result)) {
foreach ($result as $row) {
$eResumenCamera = new eResumenCamera(FALSE);
$eResumenCamera->parseRow($row, '', true);
$eResumenCameras[] = $eResumenCamera;
}
}
if (!empty($eResumenCameras)) {
foreach ($eResumenCameras as $eResumenCamera) {
$mResumen_Camera->save($eResumenCamera);
}
}
$oBus->isSuccess(TRUE);
$oBus->message('Guardado exitosamente: Resumen de Camera');
$MY->db->trans_commit();
} catch (Exception $ex) {
$oBus->isSuccess(FALSE);
$oBus->message($ex->getMessage());
$MY->db->trans_rollback();
}
return $oBus;
}
示例2: _resumen_camera
public function _resumen_camera()
{
$dateBegin = NULL;
$dateEnd = date('Y-m-d') . ' 00:00:00';
$arrDataProcess = array();
/*
* Inicio del proceso de Resumen de Camaras
*/
$DateTime_ResumenCamera_Begin = date('Y-m-d H:i:s');
$cont_P_ResumenCamera = 0;
while ($cont_P_ResumenCamera < 2) {
$oRes = Business_Process_Generate::loadResumenCamera($dateEnd, $dateBegin);
if ($oRes->isSuccess()) {
break;
}
$cont_P_ResumenCamera++;
}
if (!$oRes->isSuccess()) {
Helper_Process_Log::write($oRes->message());
}
$arrDataProcess[Helper_Config::getFTTProcessResumenCamera()] = array('isSuccess' => $oRes->isSuccess(), 'message' => $oRes->message(), 'timestamp' => Helper_Fecha::getDiff_DateTime($DateTime_ResumenCamera_Begin));
/*-----------------------------------------------------------------*/
Helper_Log::write($arrDataProcess);
//print_r($arrDataProcess);
}