UserBank.php 807 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. namespace app\api\controller\v1;
  3. use app\api\controller\Base;
  4. use app\hander\HelpHander;
  5. use think\Db;
  6. class UserBank extends Base
  7. {
  8. // 新增/编辑
  9. public function save(){
  10. model('UserBank')->add();
  11. HelpHander::success([],'操作成功');
  12. }
  13. // 列表
  14. public function list(){
  15. $page = input('page/d',1);
  16. $size = input('size/d',10);
  17. $name = input('name','','trim');
  18. $payType = input('payType/d',-1);
  19. $companyId = input('companyId/d',0);
  20. $ret = model('UserBank')->lists($page,$size,$name,$payType,$companyId,$this->orgId);
  21. HelpHander::success($ret);
  22. }
  23. public function export(){
  24. $id = input('id/d',0);
  25. $ret = model('UserBank')->export($id);
  26. HelpHander::success($ret);
  27. }
  28. }