Commit e78036e3 authored by cuiweifeng's avatar cuiweifeng

Merge branch 'jielong' of https://gitlab.yidian-inc.com/bp/goods into jielong

parents 72cb8bf6 f452ad2d
......@@ -124,7 +124,6 @@ class TakePlaceService
$where = ['marketing_id' => $marketingId];
$where['is_delete'] = 0;
if($keywords) {
// $where['OR'] = [
// 'take_place_name[~]' => $keywords,
......@@ -144,8 +143,14 @@ class TakePlaceService
//获取自提点信息
$makePlaceIds = array_column($relations,'take_place_id');
$takePlaceWhere = ['take_place_id'=>$makePlaceIds];
if (!empty($params['is_delete']) && $params['is_delete'] == 1) {
$takePlaceWhere['is_delete'] = 0;
}
//本页按距离返回列表
$res['list'] = self::sortByDistance($latitude,$longitude,TakePlace::select('*', $takePlaceWhere));
unset($where['ORDER'],$where['LIMIT']);
$res['total'] = MarketingTakePlace::count('*', $where);
$res['total_page'] = ceil($res['total']/$limit);
......
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