Files
mayi-grade/application/keti/controller/Index.php
T
2019-02-19 11:34:55 +08:00

98 lines
1.6 KiB
PHP

<?php
namespace app\keti\controller;
// 引用控制器基类
use app\common\controller\Base;
// 引用课题数据模型
use app\keti\model\Keti as kt;
class Index extends Base
{
/**
* 显示资源列表
*
* @return \think\Response
*/
public function index()
{
// 设置数据总数
$list['count'] = kt::count();
// 设置页面标题
$list['title'] = '课题列表';
// 模板赋值
$this->assign('list', $list);
// 渲染模板
return $this->fetch();
}
/**
* 显示创建资源表单页.
*
* @return \think\Response
*/
public function create()
{
//
}
/**
* 保存新建的资源
*
* @param \think\Request $request
* @return \think\Response
*/
public function save(Request $request)
{
//
}
/**
* 显示指定的资源
*
* @param int $id
* @return \think\Response
*/
public function read($id)
{
//
}
/**
* 显示编辑资源表单页.
*
* @param int $id
* @return \think\Response
*/
public function edit($id)
{
//
}
/**
* 保存更新的资源
*
* @param \think\Request $request
* @param int $id
* @return \think\Response
*/
public function update(Request $request, $id)
{
//
}
/**
* 删除指定资源
*
* @param int $id
* @return \think\Response
*/
public function delete($id)
{
//
}
}