|
@@ -0,0 +1,35 @@
|
|
|
+package com.fdkankan.ucenter.controller.api;
|
|
|
+
|
|
|
+import com.fdkankan.common.exception.BusinessException;
|
|
|
+import com.fdkankan.ucenter.common.Result;
|
|
|
+import com.fdkankan.ucenter.constant.LoginConstant;
|
|
|
+import com.fdkankan.ucenter.service.ISceneProService;
|
|
|
+import com.fdkankan.ucenter.vo.request.SceneParam;
|
|
|
+import org.apache.commons.lang3.StringUtils;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.web.bind.annotation.PostMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestBody;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+@RestController
|
|
|
+@RequestMapping("/inner")
|
|
|
+public class LaserApiController {
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ ISceneProService sceneProService;
|
|
|
+
|
|
|
+ /**
|
|
|
+ *
|
|
|
+ * 激光场景生成obj文件
|
|
|
+ */
|
|
|
+ @PostMapping(value = "/generateObjFile")
|
|
|
+ public Result generateObjFile(@RequestBody SceneParam requestScene) throws Exception{
|
|
|
+ String num = requestScene.getSceneNum();
|
|
|
+ if (StringUtils.isEmpty(num)) {
|
|
|
+ throw new BusinessException(LoginConstant.FAILURE_CODE_3001, LoginConstant.FAILURE_MSG_3001);
|
|
|
+ }
|
|
|
+ sceneProService.generateObjFile(num);
|
|
|
+ return Result.success();
|
|
|
+ }
|
|
|
+}
|