处理某些记录中可能存在的bug

This commit is contained in:
Li Jianxuan 2014-12-09 12:40:31 +00:00
parent 8058a8d812
commit 50d4af4106
1 changed files with 13 additions and 0 deletions

View File

@ -77,6 +77,19 @@ class Record extends Database
$this->timeFiled = $var_data['visual_timefield_model']; $this->timeFiled = $var_data['visual_timefield_model'];
}//custom }//custom
//时间字段为空的bug
if(empty($var_data['visual_timefield_model'])){
$this->timeFiled = "utctime";
}else{
if($var_data['visual_timefield_model'] == 'single' && empty($var_data['visual_timefield'])){
$this->timeFiled = "utctime";
}elseif($var_data['visual_timefield_model'] == 'multiple' && empty($var_data['visual_timefield_year'])){
$this->timeFiled = "utctime";
}elseif($var_data['visual_timefield_model'] == 'custom' && empty($var_data['visual_timefield_custom'])) {
$this->timeFiled = "utctime";
}
}
if(isset($var_data['data']) && !empty($var_data['data'])) if(isset($var_data['data']) && !empty($var_data['data']))
$this->sql = $this->makeSql($var_data['data'],$this->subdataset); $this->sql = $this->makeSql($var_data['data'],$this->subdataset);
else else