AssetRepair.php 590 B

123456789101112131415161718192021222324252627282930
  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 AssetRepair extends Base
  7. {
  8. // 新增
  9. public function save(){
  10. model('AssetRepair')->add();
  11. HelpHander::success([],'操作成功');
  12. }
  13. // 完成维修
  14. public function finish(){
  15. model('AssetRepair')->finish();
  16. HelpHander::success([],'操作成功');
  17. }
  18. // 详情
  19. public function detail(){
  20. $id = input('id/d',0);
  21. $ret = model('AssetRepair')->info($id);
  22. HelpHander::success($ret);
  23. }
  24. }