request->params([ ]); return success((new WeappVersionService())->getPage($data)); } /** * 详情 * @param int $id * @return Response */ public function info(int $id) { return success((new WeappVersionService())->getInfo($id)); } /** * 添加 * @return Response */ public function add() { $data = $this->request->params([ ['desc', ''] ]); return success(data:(new WeappVersionService())->add($data)); } /** * 获取预览码 * @param int $id * @return Response */ public function preview() { return success(data:(new WeappVersionService())->getPreviewImage()); } /** * 删除 * @param int $id * @return Response */ public function del(int $id) { (new WeappVersionService())->del($id); return success('DELETE_SUCCESS'); } /** * 获取小程序上传日志 * @param string $key * @return Response */ public function uploadLog(string $key) { return success(data: (new WeappVersionService())->getUploadLog($key)); } }