Commit ffc384cf authored by hujun's avatar hujun

商铺列表搜索修改

parent bb40014b
......@@ -150,18 +150,18 @@ class Houses extends Basic
}
/*开始时间*/
if ($this->params['start_date'] != NULL) {
if ($this->params['start_date'] != NULL && $this->params['end_date'] == NULL) {
$where['create_time'] = ['> time', $this->params['start_date'] . ' 00:00:00'];
}
/*结束时间*/
if ($this->params['end_date'] != NULL) {
if ($this->params['end_date'] != NULL && $this->params['start_date'] == NULL) {
$where['create_time'] = ['< time', $this->params['end_date'] . ' 23:59:59'];
}
/*开始结束时间*/
if ($this->params['start_date'] != NULL && $this->params['end_date'] != NULL) {
$where['create_time'] = ['between time', [$this->params['start_date'] . ' 00:00:00'], $this->params['end_date'] . ' 23:59:59'];
$where['create_time'] = ['between time', [$this->params['start_date'] . ' 00:00:00', $this->params['end_date'] . ' 23:59:59']];
}
/*根据库存判断是否已租*/
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment