You've already forked qlg.tsgz.moe
Init Repo
This commit is contained in:
64
hyhproject/app/controller/Articles.php
Executable file
64
hyhproject/app/controller/Articles.php
Executable file
@ -0,0 +1,64 @@
|
||||
<?php
|
||||
namespace wstmart\app\controller;
|
||||
use wstmart\app\model\Tags as M;
|
||||
/**
|
||||
* ============================================================================
|
||||
* 地区控制器
|
||||
*/
|
||||
class Articles extends Base{
|
||||
/**
|
||||
* 获取首页惠员快报
|
||||
*/
|
||||
public function getIndexNews(){
|
||||
$m = new M();
|
||||
$rs = $m->listArticle('new',10,86400);
|
||||
exit(jsonReturn('', 1,$rs));
|
||||
}
|
||||
/**
|
||||
* 获取惠员快报列表
|
||||
*/
|
||||
public function getNewsList(){
|
||||
$m = new M();
|
||||
$rs = $m->newArticle();
|
||||
exit(jsonReturn('', 1,$rs));
|
||||
}
|
||||
//添加显示会员快报 make cheng 20180227
|
||||
public function showArticle(){
|
||||
$m = new M();
|
||||
$article = $m->showArticle();
|
||||
exit(jsonReturn('', 1,$article));
|
||||
}
|
||||
|
||||
/**
|
||||
*桔子头条分类
|
||||
*/
|
||||
public function orange(){
|
||||
$m = new M();
|
||||
$orange = $m->orangeType();
|
||||
// print_r($orange);die;
|
||||
exit(json_encode(WSTReturn('ok',1,$orange)));
|
||||
}
|
||||
/**
|
||||
* 桔子头条文章
|
||||
*/
|
||||
public function headLine(){
|
||||
$catId = (int)input('catId');
|
||||
// $catId = 61;
|
||||
$m = new M();
|
||||
$clog = $m->clog($catId);
|
||||
// print_r($clog);die;
|
||||
exit(json_encode(WSTReturn('ok',1,$clog)));
|
||||
}
|
||||
|
||||
/**
|
||||
* 桔子头条文章详情
|
||||
*/
|
||||
public function detail(){
|
||||
$articleId = (int)input('articleId');
|
||||
// $articleId = '113';
|
||||
$m = new M();
|
||||
$detail = $m->detail($articleId);
|
||||
// print_r($detail);die;
|
||||
exit(json_encode(WSTReturn('ok',1,$detail)));
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user