1234567891011121314151617181920212223242526272829303132333435363738394041 |
- <?php
- namespace app\api\controller\v1;
- use app\api\controller\Base;
- use app\hander\HelpHander;
- use think\Db;
- class HouseLessee extends Base
- {
- // 新增
- public function save(){
- model('HouseLessee')->add();
- HelpHander::success([],'操作成功');
- }
- // 删除
- public function del(){
- $id = input('id/d',0);
- model('HouseLessee')->del($id);
- HelpHander::success([],'操作成功');
- }
- //列表
- public function list(){
- $page = input('page/d',1);
- $size = input('size/d',10);
- $title = input('title','','trim');
- $type = input('type/d',1);
- $ret = model('HouseLessee')->lists($page,$size,$title,$type,$this->orgId);
- HelpHander::success($ret);
- }
- //全部列表
- public function all(){
- $type = input('type/d',1);
- $ret = model('HouseLessee')->all($type,$this->orgId);
- HelpHander::success($ret);
- }
- }
|