Goods.php 377 B

12345678910111213141516171819202122
  1. <?php
  2. namespace app\api\controller;
  3. use app\common\controller\Api;
  4. use app\common\model\Goods as GoodsModel;
  5. class Goods extends Api
  6. {
  7. protected $noNeedLogin = ['*'];
  8. protected $noNeedRight = ['*'];
  9. /**
  10. * 产品列表
  11. *
  12. */
  13. public function goodslist(){
  14. $this->success('请求成功',GoodsModel::where('status',1)->select());
  15. }
  16. }