Commit c2fc4ee1 authored by luhongguang's avatar luhongguang

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

parents 1ef06216 6da2f7f7
......@@ -43,8 +43,8 @@ class TakePlace extends MysqlBase
$where['ORDER'] = ['take_place_id' => 'DESC'];
$where['LIMIT'] = [$offset, $limit];
// $e = TakePlace::debug();
$res['list'] = self::select('*', $where);
unset($where['ORDER'],$where['LIMIT']);
$res['total'] = self::count('*', $where);
return $res;
......
......@@ -26,7 +26,7 @@ class OtaController extends Base
$limit = $this->params['limit'] ?? 20;
$res = OtaService::list($name, $printerSn, $printerKey, $offset, $limit);
$this->success(['data' => $res]);
$this->success(['result' => $res]);
}
/**
......
<?php
/**
* Author : Tengda
* Date : 2021/7/29
* Time : 17:59 下午
*/
use App\Base\Base;
//use App\Services\marketing\SpellService;
//use \Validate\Spell\detailValidate;
class SpellController extends Base {
public function detailAction()
{
// (new detailValidate())->validate();
//
// $name = $this->params['name'] ?? '';
// $printerSn = $this->params['printer_sn'] ?? '';
// $printerKey = $this->params['printer_key'] ?? '';
// $offset = $this->params['offset'] ?? 0;
// $limit = $this->params['limit'] ?? 20;
// $res = TakePlaceService::list($name,$printerSn,$printerKey,$offset,$limit);
$data = [
'detail'=>[],
];
$this->success(['data'=>$data]);
}
public function listAction()
{
$data = [
'list'=>[
[
'uid'=>123,
'username'=>'aaa',
'avator'=>'aaaaaa.jpg',
'id'=>1,
'name'=>'一起拼一定赢',
'desc'=>'吃喝玩乐',
'create_time'=>'2021-07-29 20:03:08',
'sold_num'=>123,
'min_price'=>15,
'max_price'=>89,
],
[
'uid'=>234,
'username'=>'bbbbb',
'avator'=>'aaaaaa1.jpg',
'id'=>1,
'name'=>'俺是打款就',
'desc'=>'吃喝玩乐',
'create_time'=>'2021-07-29 20:03:08',
'sold_num'=>345,
'min_price'=>13,
'max_price'=>99,
]
],
'total'=>2
];
$this->success(['data'=>$data]);
}
}
\ No newline at end of file
......@@ -25,7 +25,7 @@ class TakePlaceController extends Base {
$limit = $this->params['limit'] ?? 20;
$res = TakePlaceService::searchList($keywords,$offset,$limit);
$this->success(['data'=>$res]);
$this->success(['result'=>$res]);
}
/**
......@@ -68,7 +68,7 @@ class TakePlaceController extends Base {
$data = TakePlaceService::getPindanTakePlaceList($marketingPindanId,$offset,$limit);
$this->success(['data'=>$data]);
$this->success(['result'=>$data]);
}
}
\ No newline at end of file
......@@ -27,8 +27,8 @@ class OtaService
$where['ORDER'] = ['ota_id' => 'DESC'];
$where['LIMIT'] = [$offset, $limit];
// $e = Ota::debug();
$res['list'] = Ota::select(self::COLUMNS, $where);
unset($where['ORDER'],$where['LIMIT']);
$res['total'] = Ota::count('*', $where);
return $res;
......
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