You've already forked qlg.tsgz.moe
Init Repo
This commit is contained in:
76
hyhproject/app/controller/Shopping.php
Executable file
76
hyhproject/app/controller/Shopping.php
Executable file
@ -0,0 +1,76 @@
|
||||
<?php
|
||||
namespace wstmart\app\controller;
|
||||
use wstmart\common\model\Shopping as M;
|
||||
/**
|
||||
* ============================================================================
|
||||
* 逛商铺处理类
|
||||
*/
|
||||
class Shopping extends Base{
|
||||
|
||||
/**
|
||||
* 获取助微吧轮播
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getHelpCarousel(){
|
||||
$m = new M();
|
||||
exit(json_encode($m->getHelpCarousel()));
|
||||
}
|
||||
/**
|
||||
* 搜索助微吧商品列表
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getHelpShops(){
|
||||
$m = new M();
|
||||
exit(json_encode($m->getHelpShops()));
|
||||
}
|
||||
public function searchHelpGoods(){
|
||||
$m = new M();
|
||||
exit(jsonReturn($m->searchHelpGoods()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取逛商都/助微吧推荐商品
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getGoods(){
|
||||
$m = new M();
|
||||
exit(json_encode($m->getGoods()));
|
||||
// $m = Model('common/Table');
|
||||
// $m->setTable('shops');
|
||||
}
|
||||
/**
|
||||
* 获取逛商铺轮播
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getCarousel(){
|
||||
$m = new M();
|
||||
exit(json_encode($m->getCarousel()));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取逛商铺列表
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getShops(){
|
||||
$m = new M();
|
||||
exit(json_encode($m->getShops()));
|
||||
}
|
||||
/**
|
||||
* 获取商铺首页
|
||||
* @return [type] [description]
|
||||
*/
|
||||
public function getShopInfo(){
|
||||
$m = Model('shops');
|
||||
exit(json_encode($m->getShopIndex()));
|
||||
// $m = Model('common/Table');
|
||||
// $m->setTable('shops');
|
||||
}
|
||||
/**
|
||||
* 获取店铺首页商品列表
|
||||
*/
|
||||
public function getShopIndexGoodsList(){
|
||||
$m = Model('common/Shops');
|
||||
$rs = $m->getShopIndexGoodsList(0,'goodsId,goodsImg,goodsName,shopPrice,saleNum,discountRate','goodsOrder DESC,saleNum DESC,goodsId DESC');
|
||||
exit(json_encode($rs));
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user