...
|
...
|
@@ -17,8 +17,8 @@ class Litestoreorder extends Backend |
|
|
* @var \app\admin\model\Litestoreorder
|
|
|
*/
|
|
|
protected $model = null;
|
|
|
protected $dataLimit = true;
|
|
|
protected $dataLimitField = 'store_id';
|
|
|
// protected $dataLimit = true;
|
|
|
// protected $dataLimitField = 'store_id';
|
|
|
|
|
|
public function _initialize()
|
|
|
{
|
...
|
...
|
@@ -54,13 +54,19 @@ class Litestoreorder extends Backend |
|
|
return $this->selectpage();
|
|
|
}
|
|
|
list($where, $sort, $order, $offset, $limit) = $this->buildparams();
|
|
|
|
|
|
$store = \app\admin\model\store\Store::where('admin_id',$this->auth->id)->field('id')->find();
|
|
|
$store_id = $store ? $store['id'] : 0;
|
|
|
|
|
|
$total = $this->model
|
|
|
->where($where)
|
|
|
->where('store_id',$store_id)
|
|
|
->order($sort, $order)
|
|
|
->count();
|
|
|
|
|
|
$list = $this->model
|
|
|
->where($where)
|
|
|
->where('store_id',$store_id)
|
|
|
->order($sort, $order)
|
|
|
->limit($offset, $limit)
|
|
|
->select();
|
...
|
...
|
|