admin-api/app/controller/merchant/store/coupon/CouponSend.php

30 lines
730 B
PHP

<?php
namespace app\controller\merchant\store\coupon;
use app\common\repositories\store\coupon\StoreCouponSendRepository;
use crmeb\basic\BaseController;
use think\App;
class CouponSend extends BaseController
{
protected $repository;
public function __construct(App $app, StoreCouponSendRepository $repository)
{
parent::__construct($app);
$this->repository = $repository;
}
public function lst()
{
[$page, $limit] = $this->getPage();
$where = $this->request->params(['date', 'coupon_type', 'coupon_name', 'status']);
$where['mer_id'] = $this->request->merId();
return app('json')->success($this->repository->getList($where, $page, $limit));
}
}