作者 耿培杰

修改接口

... ... @@ -136,6 +136,7 @@ class Sundry extends Api
if (!empty($params['county_id'])) $where['county_id'] = $params['county_id'];
$data = $model->where($where)->field('is_special,starttime1,endtime1,starttime2,endtime2')->find();
if (!$data) $data = $model->where(['province_id'=>$params['province_id']])->field('is_special,starttime1,endtime1,starttime2,endtime2')->find();
$startDate = date("Y-m-d", strtotime('+' . $data['starttime1'] . ' days', time()));
$endDate = date("Y-m-d", strtotime('+' . $data['endtime1'] . ' days', time()));
$data['date'] = period_date($startDate, $endDate);
... ...