SceneEditController.java 27 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907
  1. package com.fdkankan.scene.controller;
  2. import com.fdkankan.common.constant.SceneInfoReqType;
  3. import com.fdkankan.scene.annotation.CheckToken;
  4. import com.fdkankan.scene.annotation.InitEditInfo;
  5. import com.fdkankan.scene.bean.ResultData;
  6. import com.fdkankan.scene.service.*;
  7. import com.fdkankan.scene.vo.*;
  8. import lombok.extern.log4j.Log4j2;
  9. import org.springframework.beans.factory.annotation.Autowired;
  10. import org.springframework.validation.annotation.Validated;
  11. import org.springframework.web.bind.annotation.*;
  12. import org.springframework.web.multipart.MultipartFile;
  13. import java.io.IOException;
  14. /**
  15. * 场景编辑管理
  16. */
  17. @Log4j2
  18. @RestController
  19. @RequestMapping("/service/scene/edit")
  20. public class SceneEditController extends BaseController{
  21. // @Value("${spring.profiles.active}")
  22. // private String env;
  23. //
  24. @Autowired
  25. private ISceneProService sceneProService;
  26. @Autowired
  27. private SceneEditInfoService sceneEditInfoService;
  28. @Autowired
  29. private ISceneUploadService sceneUploadService;
  30. @Autowired
  31. private ISceneEditService sceneEditService;
  32. // @Autowired
  33. // private IDownloadTourVideoService downloadTourVideoService;
  34. // @Autowired
  35. // private ISurveillanceService surveillanceService;
  36. @Autowired
  37. private IBoxModelService boxModelService;
  38. // @Autowired
  39. // private IScenePlusService scenePlusService;
  40. // @Autowired
  41. // private ISceneAsynOperLogService sceneAsynOperLogService;
  42. @Autowired
  43. private SceneEditInfoExtService sceneEditInfoExtService;
  44. // @Autowired
  45. // private ICutModelService cutModelService;
  46. /**
  47. * <p>
  48. 保存场景编辑数据
  49. * </p>
  50. * @author dengsixing
  51. * @date 2022/1/12
  52. * @param param
  53. * @return com.fdkankan.web.response.ResultData
  54. **/
  55. // @CheckPermit
  56. @PostMapping(value = "/base/save")
  57. public ResultData saveScene(@RequestBody @Validated SceneEditInfoParamVO param){
  58. param.setSubgroup(this.getSubgroup());
  59. return ResultData.ok(sceneEditInfoService.saveScene(param));
  60. }
  61. //
  62. // /**
  63. // * <p>
  64. // 发布场景数据
  65. // * </p>
  66. // * @author dengsixing
  67. // * @date 2022/1/12
  68. // * @param param
  69. // * @return com.fdkankan.web.response.ResultData
  70. // **/
  71. // @CheckPermit
  72. // @PostMapping(value = "/publicScene")
  73. // public ResultData publicScene(@RequestBody @Validated SceneEditInfoParamVO param) throws Exception {
  74. // return sceneEditInfoService.publicScene(param);
  75. // }
  76. /**
  77. * <p>
  78. 保存初始页面
  79. * </p>
  80. * @author dengsixing
  81. * @date 2022/1/12
  82. * @param param
  83. * @return com.fdkankan.web.response.ResultData
  84. **/
  85. @PostMapping(value = "/saveInitialPage")
  86. public ResultData saveInitialPage(@RequestBody @Validated FileNameAndDataParamVO param) throws Exception {
  87. param.setSubgroup(this.getSubgroup());
  88. return sceneProService.saveInitialPage(param);
  89. }
  90. /**
  91. * <p>
  92. 新增或修改场景热点
  93. * </p>
  94. * @author dengsixing
  95. * @date 2022/1/12
  96. * @return com.fdkankan.web.response.ResultData
  97. **/
  98. @PostMapping(value = "/tag/save")
  99. public ResultData saveTag(@RequestBody @Validated SaveTagsParamVO param) throws Exception {
  100. param.setSubgroup(this.getSubgroup());
  101. return sceneProService.addOrUpdateTag(param);
  102. }
  103. /**
  104. * <p>
  105. 删除热点
  106. * </p>
  107. * @author dengsixing
  108. * @date 2022/2/16
  109. * @return com.fdkankan.web.response.ResultData
  110. **/
  111. @PostMapping(value = "/tag/delete")
  112. public ResultData deleteTag(@RequestBody @Validated DeleteHotParamVO param) throws Exception {
  113. param.setSubgroup(this.getSubgroup());
  114. return sceneProService.deleteTag(param);
  115. }
  116. /**
  117. * <p>
  118. 热点列表
  119. * </p>
  120. * @author dengsixing
  121. * @date 2022/8/1
  122. * @param num
  123. * @return com.fdkankan.web.response.ResultData
  124. **/
  125. @PostMapping(value = "/tag/list")
  126. public ResultData listTags(@RequestParam(value = "num") String num) throws Exception {
  127. Integer subgroup = this.getSubgroup();
  128. return sceneProService.listTags(num, subgroup);
  129. }
  130. /**
  131. * <p>
  132. 删除热点
  133. * </p>
  134. * @author dengsixing
  135. * @date 2022/2/16
  136. * @param param
  137. * @return com.fdkankan.web.response.ResultData
  138. **/
  139. @PostMapping(value = "/icons/delete")
  140. public ResultData deleteIcons(@RequestBody @Validated DeleteHotIconParamVO param) throws Exception {
  141. param.setSubgroup(this.getSubgroup());
  142. return sceneProService.deleteIcons(param);
  143. }
  144. /**
  145. * <p>
  146. 保存漫游可行
  147. * </p>
  148. * @author dengsixing
  149. * @date 2022/1/12
  150. * @param param
  151. * @return com.fdkankan.web.response.ResultData
  152. **/
  153. @PostMapping(value = "/saveRoam")
  154. public ResultData saveRoam(@RequestBody @Validated BaseDataParamVO param) throws Exception {
  155. param.setSubgroup(this.getSubgroup());
  156. return sceneProService.saveRoam(param);
  157. }
  158. /**
  159. * <p>
  160. 保存热点可见性的数据
  161. * </p>
  162. * @author dengsixing
  163. * @date 2022/8/1
  164. * @return com.fdkankan.web.response.ResultData
  165. **/
  166. @PostMapping(value = "/saveTagsVisible")
  167. public ResultData saveTagsVisible(@RequestBody @Validated SaveTagsVisibleParamVO param) throws Exception {
  168. param.setSubgroup(this.getSubgroup());
  169. return sceneProService.saveTagsVisible(param);
  170. }
  171. //
  172. // /**
  173. // * <p>
  174. // 下载模型
  175. // * </p>
  176. // * @author dengsixing
  177. // * @date 2022/8/1
  178. // * @param num
  179. // * @return com.fdkankan.web.response.ResultData
  180. // **/
  181. // @CheckPermit
  182. // @PostMapping(value = "/downloadModel")
  183. // public ResultData downloadModel(@RequestParam("num") String num) throws Exception {
  184. // return sceneProService.downloadModel(num);
  185. // }
  186. //
  187. // /**
  188. // * <p>
  189. // 上传模型
  190. // * </p>
  191. // * @author dengsixing
  192. // * @date 2022/8/1
  193. // * @param num
  194. // * @param file
  195. // * @return com.fdkankan.web.response.ResultData
  196. // **/
  197. // @CheckPermit
  198. // @PostMapping(value = "/uploadModel")
  199. // public ResultData uploadModel(@RequestParam("num") String num, @RequestParam("file") MultipartFile file) throws Exception {
  200. // return sceneProService.uploadModel(num, file);
  201. // }
  202. //
  203. // /**
  204. // * <p>
  205. // 保存关联全景图
  206. // * </p>
  207. // * @author dengsixing
  208. // * @date 2022/8/1
  209. // * @param num
  210. // * @param sid
  211. // * @param fileName
  212. // * @param file
  213. // * @return com.fdkankan.web.response.ResultData
  214. // **/
  215. // @CheckPermit
  216. // @PostMapping(value = "/linkPan/upload")
  217. // public ResultData uploadLinkPan(
  218. // @RequestParam(value = "num") String num,
  219. // @RequestParam(value = "sid") String sid,
  220. // @RequestParam(value = "fileName") String fileName,
  221. // @RequestParam("file") MultipartFile file) throws Exception{
  222. // return sceneEditInfoService.uploadLinkPan(num, sid, fileName, file);
  223. // }
  224. //
  225. // /**
  226. // * <p>
  227. // 保存关联全景图
  228. // * </p>
  229. // * @author dengsixing
  230. // * @date 2022/8/1
  231. // * @param param
  232. // * @return com.fdkankan.web.response.ResultData
  233. // **/
  234. // @CheckPermit
  235. // @PostMapping(value = "/linkPan/save")
  236. // public ResultData saveLinkPan(@RequestBody @Validated SaveLinkPanParamVO param) throws Exception{
  237. // return sceneEditInfoService.saveLinkPan(param);
  238. // }
  239. //
  240. // /**
  241. // * <p>
  242. // 删除场景关联
  243. // * </p>
  244. // * @author dengsixing
  245. // * @date 2022/8/1
  246. // * @param param
  247. // * @return com.fdkankan.web.response.ResultData
  248. // **/
  249. // @CheckPermit
  250. // @PostMapping(value = "/linkPan/delete")
  251. // public ResultData deleteLinkPan(@RequestBody @Validated DeleteLinkPanParamVO param) throws Exception {
  252. // return sceneEditInfoService.deleteLinkPan(param);
  253. // }
  254. //
  255. // /**
  256. // * <p>
  257. // 删除场景关联图标
  258. // * </p>
  259. // * @author dengsixing
  260. // * @date 2022/8/1
  261. // * @param param
  262. // * @return com.fdkankan.web.response.ResultData
  263. // **/
  264. // @CheckPermit
  265. // @PostMapping(value = "/styles/delete")
  266. // public ResultData deleteStyles(@RequestBody @Validated DeleteStylesParamVO param) throws Exception {
  267. // return sceneEditInfoService.deleteStyles(param);
  268. // }
  269. /**
  270. * <p>
  271. 场景关联列表
  272. * </p>
  273. * @author dengsixing
  274. * @date 2022/8/1
  275. * @param num
  276. * @return com.fdkankan.web.response.ResultData
  277. **/
  278. @PostMapping(value = "/linkPan/list")
  279. public ResultData listLinkPan(@RequestParam(value = "num") String num) throws Exception {
  280. Integer subgroup = this.getSubgroup();
  281. return sceneEditInfoService.listLinkPan(num, subgroup);
  282. }
  283. /**
  284. * <p>
  285. 保存户型图
  286. * </p>
  287. * @author dengsixing
  288. * @date 2022/1/20
  289. * @param param
  290. * @return com.fdkankan.web.response.ResultData
  291. **/
  292. @PostMapping(value = "/cad/save")
  293. public ResultData saveCad(@RequestBody @Validated BaseDataParamVO param) throws Exception{
  294. param.setSubgroup(this.getSubgroup());
  295. return sceneEditInfoService.saveCad(param);
  296. }
  297. //
  298. // /**
  299. // * <p>
  300. // 保存户型图
  301. // * </p>
  302. // * @author dengsixing
  303. // * @date 2022/1/20
  304. // * @param param
  305. // * @return com.fdkankan.web.response.ResultData
  306. // **/
  307. // @CheckPermit
  308. // @GetMapping(value = "/cad/dxf/download")
  309. // public ResultData saveCadDxf(@RequestParam String num) throws Exception{
  310. // return sceneEditInfoService.downloadDxf(num);
  311. // }
  312. //
  313. // /**
  314. // * <p>
  315. // 保存户型图
  316. // * </p>
  317. // * @author dengsixing
  318. // * @date 2022/1/20
  319. // * @param param
  320. // * @return com.fdkankan.web.response.ResultData
  321. // **/
  322. // @CheckPermit
  323. // @PostMapping(value = "/cad/dxf/upload")
  324. // public ResultData uploadDxf(@RequestParam MultipartFile file, @RequestParam String num) throws Exception{
  325. // return sceneEditInfoService.uploadDxf(file, num);
  326. // }
  327. /**
  328. * <p>
  329. 重置户型图
  330. * </p>
  331. * @author dengsixing
  332. * @date 2022/2/16
  333. * @param num
  334. * @return
  335. **/
  336. @PostMapping(value = "/cad/reset")
  337. public ResultData resetCad(@RequestParam(value = "num") String num) throws Exception {
  338. Integer subgroup = this.getSubgroup();
  339. return sceneEditInfoService.resetCad(num, subgroup);
  340. }
  341. /**
  342. * <p>
  343. 楼层户型重命名
  344. * </p>
  345. * @author dengsixing
  346. * @date 2022/2/16
  347. * @return
  348. **/
  349. @PostMapping(value = "/cad/rename")
  350. public ResultData renameCad(@RequestBody @Validated RenameCadParamVO param) throws IOException {
  351. param.setSubgroup(this.getSubgroup());
  352. return sceneEditInfoService.renameCad(param);
  353. }
  354. /**
  355. * <p>
  356. 获取场景详情
  357. * </p>
  358. * @author dengsixing
  359. * @date 2022/8/1
  360. * @param param
  361. * @return com.fdkankan.scene.vo.SceneInfoVO
  362. **/
  363. @CheckToken
  364. @InitEditInfo
  365. @GetMapping(value = "/getInfo")
  366. public SceneInfoVO getInfo(@Validated SceneInfoParamVO param) throws Exception{
  367. // param.setSubgroup(this.getSubgroup());
  368. param.setReqType(SceneInfoReqType.EDIT.code());
  369. return sceneEditInfoService.getSceneInfo(param);
  370. }
  371. //
  372. // /**
  373. // * <p>
  374. // 上传全景图
  375. // * </p>
  376. // * @author dengsixing
  377. // * @date 2022/2/16
  378. // * @param num
  379. // * @param file
  380. // * @return java.util.List<java.lang.String>
  381. // **/
  382. // @CheckPermit
  383. // @PostMapping(value = "/uploadPanorama")
  384. // public ResultData uploadPanorama(@RequestParam(value = "num") String num,
  385. // @RequestParam("file") MultipartFile file) throws Exception {
  386. // return sceneEditInfoService.uploadPanorama(num, file);
  387. // }
  388. //
  389. // /**
  390. // * <p>
  391. // 下载全景图
  392. // * </p>
  393. // * @author dengsixing
  394. // * @date 2022/2/16
  395. // * @return java.util.List<java.lang.String>
  396. // **/
  397. // @CheckPermit
  398. // @PostMapping(value = "/downloadPanorama")
  399. // public ResultData downloadPanorama(@RequestBody @Validated FileParamVO param) throws Exception {
  400. // return sceneEditInfoService.downloadPanorama(param);
  401. // }
  402. //
  403. // /**
  404. // * <p>
  405. // 保存视频盒子
  406. // * </p>
  407. // * @author dengsixing
  408. // * @date 2022/2/18
  409. // * @param param
  410. // * @return com.fdkankan.web.response.ResultData
  411. // **/
  412. // @CheckPermit
  413. // @PostMapping(value = "/video/box/save")
  414. // public ResultData saveVideoBox(@RequestBody @Validated FileNameAndDataParamVO param) throws Exception {
  415. // return sceneEditInfoService.saveVideoBox(param);
  416. // }
  417. //
  418. // /**
  419. // * <p>
  420. // 删除视频盒子
  421. // * </p>
  422. // * @author dengsixing
  423. // * @date 2022/2/18
  424. // * @param param
  425. // * @return com.fdkankan.web.response.ResultData
  426. // **/
  427. // @CheckPermit
  428. // @PostMapping(value = "/video/box/delete")
  429. // public ResultData deleteVideoBox(@RequestBody @Validated DeleteSidParamVO param) throws Exception {
  430. // return sceneEditInfoService.deleteVideoBox(param);
  431. // }
  432. //
  433. // /**
  434. // * <p>
  435. // 保存空间贴图
  436. // * </p>
  437. // * @author dengsixing
  438. // * @date 2022/2/18
  439. // * @param param
  440. // * @return com.fdkankan.web.response.ResultData
  441. // **/
  442. // @CheckPermit
  443. // @PostMapping(value = "/photo/box/save")
  444. // public ResultData savePhotoBox(@RequestBody @Validated BaseDataParamVO param) throws Exception {
  445. // return sceneEditInfoService.saveBoxPhoto(param);
  446. // }
  447. //
  448. // /**
  449. // * <p>
  450. // 删除空间贴图
  451. // * </p>
  452. // * @author dengsixing
  453. // * @date 2022/2/18
  454. // * @param param
  455. // * @return com.fdkankan.web.response.ResultData
  456. // **/
  457. // @CheckPermit
  458. // @PostMapping(value = "/photo/box/delete")
  459. // public ResultData deletePhotoBox(@RequestBody @Validated DeleteSidParamVO param) throws Exception {
  460. // return sceneEditInfoService.deleteBoxPhoto(param);
  461. // }
  462. //
  463. //
  464. // /**
  465. // * <p>
  466. // 下载视频
  467. // * </p>
  468. // * @author dengsixing
  469. // * @date 2022/2/23
  470. // * @param param
  471. // * @return com.fdkankan.scene.vo.DownloadVO
  472. // **/
  473. // @CheckPermit
  474. // @PostMapping(value = "/downloadBallScreenVideo")
  475. // public DownloadVO downloadBallScreenVideo(@RequestBody @Validated BallScreenVideoParamVO param){
  476. // return sceneEditInfoService.downloadBallScreenVideo(param);
  477. // }
  478. //
  479. // /**
  480. // * <p>
  481. // 上传视频
  482. // * </p>
  483. // * @author dengsixing
  484. // * @date 2022/2/23
  485. // * @param num
  486. // * @param fileName
  487. // * @param file
  488. // * @return com.fdkankan.web.response.ResultData
  489. // **/
  490. // @CheckPermit
  491. // @PostMapping(value = "/uploadBallScreenVideo")
  492. // public ResultData uploadBallScreenVideo(
  493. // @RequestParam("num") String num,
  494. // @RequestParam("fileName") String fileName,
  495. // @RequestParam("file") MultipartFile file) throws Exception {
  496. // return sceneEditInfoService.uploadBallScreenVideo(num, fileName, file);
  497. // }
  498. // @CheckPermit
  499. @RequestMapping(value = "/upload/files", method = RequestMethod.POST)
  500. public String uploads(@RequestParam(value = "base64",required = false) String base64,
  501. @RequestParam(value = "fileName",required = false) String fileName,
  502. @RequestParam(value = "bizType",required = false) String bizType,
  503. @RequestParam(value = "files",required = false) MultipartFile[] files,
  504. @RequestParam(value = "num",required = false) String num,
  505. @RequestParam(value = "type",required = false,defaultValue = "1") Integer type,
  506. @RequestParam(value = "uploadPath",required = false) String uploadPath) throws Exception {
  507. Integer subgroup = this.getSubgroup();
  508. return sceneUploadService.uploads(base64,fileName,bizType,files,num,type,uploadPath, subgroup);
  509. }
  510. // /**
  511. // * <p>
  512. // 用户自定义上传文本内容上传
  513. // * </p>
  514. // * @author dengsixing
  515. // * @date 2022/8/1
  516. // * @param param
  517. // * @return java.lang.String
  518. // **/
  519. // @RequestMapping(value = "/upload/content", method = RequestMethod.POST)
  520. // public String uploadContent(@RequestBody @Validated UploadContentParamVO param) throws Exception {
  521. // return sceneUploadService.uploadContent(param);
  522. // }
  523. //
  524. /**
  525. * <p>
  526. 删除文件
  527. * </p>
  528. * @author dengsixing
  529. * @date 2022/2/23
  530. * @param paramVO
  531. * @return com.fdkankan.web.response.ResultData
  532. **/
  533. @PostMapping("/delete/file")
  534. public ResultData delete(@RequestBody @Validated DeleteFileParamVO paramVO) throws Exception{
  535. paramVO.setSubgroup(this.getSubgroup());
  536. return sceneUploadService.delete(paramVO);
  537. }
  538. //
  539. // /**
  540. // * <p>
  541. // 场景同步
  542. // * </p>
  543. // * @author dengsixing
  544. // * @date 2022/8/1
  545. // * @param num
  546. // * @param type
  547. // * @param floorPlanJson
  548. // * @param ajkJson
  549. // * @param cameraJson
  550. // * @param files
  551. // * @return com.fdkankan.web.response.ResultData
  552. // **/
  553. // @CheckPermit
  554. // @PostMapping(value = "/sceneSync")
  555. // public ResultData sceneSync(
  556. // @RequestParam("num") String num,
  557. // @RequestParam(value = "type", defaultValue = "ajk") String type,
  558. // @RequestParam("floorPlanJson") String floorPlanJson,
  559. // @RequestParam("ajkJson") String ajkJson,
  560. // @RequestParam("cameraJson") String cameraJson,
  561. // @RequestParam("files") MultipartFile[] files) throws Exception{
  562. // return sceneEditInfoService.sceneSync(num, type, floorPlanJson, ajkJson, cameraJson, files);
  563. // }
  564. /**
  565. * <p>
  566. 获取场景权限
  567. * </p>
  568. * @author dengsixing
  569. * @date 2022/8/1
  570. * @param num
  571. * @return com.fdkankan.scene.vo.SceneAuthVO
  572. **/
  573. @PostMapping(value = "/getAuth")
  574. public SceneAuthVO getAuth(@RequestParam("num") String num) throws Exception{
  575. // Integer subgroup = this.getSubgroup();
  576. return sceneEditService.getAuth(num);
  577. }
  578. //
  579. // /**
  580. // * <p>
  581. // 上传国际化文件
  582. // * </p>
  583. // * @author dengsixing
  584. // * @date 2022/4/11
  585. // * @param param
  586. // * @return com.fdkankan.web.response.ResultData
  587. // **/
  588. // @PostMapping(value = "/locales")
  589. // public ResultData locales(@RequestBody @Validated LocalesParamVO param) throws Exception {
  590. // if("pro".equals(env)){
  591. // throw new BusinessException(ErrorCode.HAVE_NO_RIGHT);
  592. // }
  593. // return sceneEditService.locales(param);
  594. // }
  595. //
  596. /**
  597. * <p>
  598. 保存导览
  599. * </p>
  600. * @author dengsixing
  601. * @date 2022/8/1
  602. * @return com.fdkankan.web.response.ResultData
  603. **/
  604. @PostMapping(value = "/tour/save")
  605. public ResultData saveTour(@RequestBody @Validated BaseDataParamVO param) throws Exception{
  606. param.setSubgroup(this.getSubgroup());
  607. return sceneEditService.saveTour(param);
  608. }
  609. /**
  610. * <p>
  611. 删除导览
  612. * </p>
  613. * @author dengsixing
  614. * @date 2022/8/1
  615. * @param param
  616. * @return com.fdkankan.web.response.ResultData
  617. **/
  618. @PostMapping(value = "/tour/delete")
  619. public ResultData deleteTour(@RequestBody @Validated BaseSceneParamVO param) throws Exception{
  620. param.setSubgroup(this.getSubgroup());
  621. return sceneEditService.deleteTour(param);
  622. }
  623. // @PostMapping(value = "/tour/video/upload")
  624. // public ResultData uploadTourVideo(@RequestParam("num") String num, @RequestParam("file") MultipartFile file) throws Exception {
  625. // return downloadTourVideoService.uploadTourVideo(num, file);
  626. // }
  627. //
  628. // @PostMapping(value = "/tour/video/download")
  629. // public ResultData downloadTourVideo(@RequestParam("num") String num) throws Exception {
  630. // return downloadTourVideoService.downloadTourVideo(num);
  631. // }
  632. /**
  633. * <p>
  634. 添加马赛克
  635. * </p>
  636. * @author dengsixing
  637. * @date 2022/8/1
  638. * @param param
  639. * @return com.fdkankan.web.response.ResultData
  640. **/
  641. @PostMapping(value = "/mosaics/add")
  642. public ResultData addMosaics(@RequestBody @Validated BaseDataParamVO param) throws Exception{
  643. param.setSubgroup(this.getSubgroup());
  644. return sceneEditInfoService.addMosaics(param);
  645. }
  646. /**
  647. * <p>
  648. 删除马赛克
  649. * </p>
  650. * @author dengsixing
  651. * @date 2022/8/1
  652. * @param param
  653. * @return com.fdkankan.web.response.ResultData
  654. **/
  655. @PostMapping(value = "/mosaics/delete")
  656. public ResultData deleteMosaics(@RequestBody @Validated DeleteMosaicParamVO param) throws Exception{
  657. param.setSubgroup(this.getSubgroup());
  658. return sceneEditInfoService.deleteMosaics(param);
  659. }
  660. /**
  661. * <p>
  662. 马赛克列表
  663. * </p>
  664. * @author dengsixing
  665. * @date 2022/8/1
  666. * @param param
  667. * @return com.fdkankan.web.response.ResultData
  668. **/
  669. @PostMapping(value = "/mosaics/list")
  670. public ResultData getMosaicList(@RequestBody @Validated BaseSceneParamVO param) throws Exception{
  671. param.setSubgroup(this.getSubgroup());
  672. return ResultData.ok(sceneEditInfoService.getMosaicList(param.getNum(), param.getSubgroup()));
  673. }
  674. /**
  675. * <p>
  676. 添加水印
  677. * </p>
  678. * @author dengsixing
  679. * @date 2022/8/1
  680. * @param param
  681. * @return com.fdkankan.web.response.ResultData
  682. **/
  683. @PostMapping(value = "/waterMark/add")
  684. public ResultData addWaterMark(@RequestBody @Validated BaseFileParamVO param) throws Exception{
  685. param.setSubgroup(this.getSubgroup());
  686. return sceneEditInfoService.addWaterMark(param);
  687. }
  688. /**
  689. * <p>
  690. 删除水印
  691. * </p>
  692. * @author dengsixing
  693. * @date 2022/8/1
  694. * @param param
  695. * @return com.fdkankan.web.response.ResultData
  696. **/
  697. @PostMapping(value = "/waterMark/delete")
  698. public ResultData deleteWaterMark(@RequestBody @Validated BaseFileParamVO param) throws Exception{
  699. param.setSubgroup(this.getSubgroup());
  700. return sceneEditInfoService.deleteWaterMark(param);
  701. }
  702. /**
  703. * 删除水印
  704. * @param param
  705. * @return
  706. * @throws Exception
  707. */
  708. @PostMapping(value = "/filter/save")
  709. public ResultData saveFilter(@RequestBody @Validated SaveFiltersParamVO param) throws Exception{
  710. param.setSubgroup(this.getSubgroup());
  711. return sceneEditInfoService.saveFilter(param);
  712. }
  713. /**
  714. * 删除水印
  715. * @param param
  716. * @return
  717. * @throws Exception
  718. */
  719. @PostMapping(value = "/filter/list")
  720. public ResultData listFilter(@RequestBody @Validated BaseSceneParamVO param) throws Exception{
  721. param.setSubgroup(this.getSubgroup());
  722. return sceneEditInfoService.listFilter(param);
  723. }
  724. //
  725. // /**
  726. // * <p>
  727. // 添加监控
  728. // * </p>
  729. // * @author dengsixing
  730. // * @date 2022/9/20
  731. // * @param param
  732. // * @return com.fdkankan.common.response.ResultData
  733. // **/
  734. // @CheckPermit
  735. // @PostMapping("/surveillance/save")
  736. // ResultData saveSurveillance(@RequestBody @Validated SurveillanceParamVO param) throws Exception {
  737. // return surveillanceService.saveSurveillance(param);
  738. // }
  739. //
  740. // @CheckPermit
  741. // @PostMapping("/surveillance/delete")
  742. // public ResultData deleteSurveillance(@RequestBody @Validated BaseSidParamVO param) throws IOException {
  743. // return surveillanceService.deleteSurveillance(param);
  744. // }
  745. //
  746. // @CheckPermit
  747. // @PostMapping("/surveillance/list")
  748. // public ResultData listSurveillance(@RequestBody @Validated BaseSceneParamVO param){
  749. // return ResultData.ok(surveillanceService.listSurveillance(param.getNum()));
  750. // }
  751. //
  752. /**
  753. * <p>
  754. 上传空间模型
  755. * </p>
  756. * @author dengsixing
  757. * @param num
  758. * @param sid
  759. * @param file
  760. * @return com.fdkankan.common.response.ResultData
  761. **/
  762. @PostMapping("/model/box/upload")
  763. public ResultData uploadBoxModel(
  764. @RequestParam(value = "num") String num,
  765. @RequestParam(value = "sid") String sid,
  766. @RequestParam(value = "file") MultipartFile file) throws Exception {
  767. return boxModelService.uploadBoxModel(num, this.getSubgroup(), sid, file);
  768. }
  769. /**
  770. * <p>
  771. 保存空间模型
  772. * </p>
  773. * @author dengsixing
  774. * @return com.fdkankan.common.response.ResultData
  775. **/
  776. @PostMapping("/model/box/save")
  777. public ResultData saveBoxModel(@RequestBody @Validated BaseJsonDataParamVO param) throws Exception {
  778. param.setSubgroup(this.getSubgroup());
  779. return boxModelService.saveBoxModel(param);
  780. }
  781. /**
  782. * <p>
  783. 删除空间模型
  784. * </p>
  785. * @author dengsixing
  786. * @return com.fdkankan.common.response.ResultData
  787. **/
  788. @PostMapping("/model/box/delete")
  789. public ResultData delBoxModel(@RequestBody @Validated DeleteSidParamVO param) throws Exception {
  790. return boxModelService.deleteBoxModel(param);
  791. }
  792. //
  793. // /**
  794. // * 上传二维码和分享的logo
  795. // * @return
  796. // */
  797. // @PostMapping(value = "/uploadShareLogo")
  798. // public ResultData uploadShareLogo(@RequestParam("num") String num, @RequestParam("file") MultipartFile file) throws Exception {
  799. // return scenePlusService.uploadShareLogo(num, file);
  800. // }
  801. //
  802. // /**
  803. // * 获取编辑器版本信息
  804. // * @return
  805. // */
  806. // @GetMapping("/getServiceUpTip")
  807. // public ResultData getServiceUpTip(){
  808. // return sceneEditService.getServiceUpTip();
  809. // }
  810. /**
  811. * 保存或者修改指示牌
  812. * @return
  813. * @throws Exception
  814. */
  815. @PostMapping("/billboards/save")
  816. public ResultData saveBillboards(@RequestBody @Validated BaseJsonArrayParamVO param) throws Exception {
  817. param.setSubgroup(this.getSubgroup());
  818. return sceneEditInfoExtService.saveBillboards(param);
  819. }
  820. /**
  821. * 删除指示牌
  822. * @return
  823. * @throws Exception
  824. */
  825. @PostMapping("/billboards/delete")
  826. public ResultData deleteBillboards(@RequestBody @Validated DeleteSidListParamVO param) throws Exception {
  827. param.setSubgroup(this.getSubgroup());
  828. return sceneEditInfoExtService.deleteBillboards(param);
  829. }
  830. /**
  831. * 获取指示牌列表
  832. * @return
  833. * @throws Exception
  834. */
  835. @PostMapping("/billboards/list")
  836. public ResultData deleteBillboards(@RequestBody @Validated BaseSceneParamVO param) throws Exception {
  837. param.setSubgroup(this.getSubgroup());
  838. return ResultData.ok(sceneEditInfoExtService.listBillboards(param));
  839. }
  840. /**
  841. * 获取指示牌列表
  842. * @param param
  843. * @return
  844. * @throws Exception
  845. */
  846. @PostMapping("/billboards/styles/delete")
  847. public ResultData deleteBillboards(@RequestBody @Validated DeleteStylesParamVO param) throws Exception {
  848. param.setSubgroup(this.getSubgroup());
  849. return ResultData.ok(sceneEditInfoExtService.deleteBillboardsStyles(param));
  850. }
  851. //
  852. // @CheckPermit
  853. // @PostMapping(value = "/cutModel/save")
  854. // public ResultData saveCutModel(@RequestBody @Validated BaseJsonArrayParamVO param) throws Exception {
  855. // return cutModelService.saveCutModel(param);
  856. // }
  857. //
  858. // @CheckPermit
  859. // @PostMapping(value = "/cutModel/list")
  860. // public ResultData listCutModel(@RequestBody @Validated BaseSceneParamVO param) throws Exception {
  861. // return ResultData.ok(cutModelService.listCutModel(param));
  862. // }
  863. //
  864. // @CheckPermit
  865. // @PostMapping(value = "/cutModel/delete")
  866. // public ResultData deleteCutModel(@RequestBody @Validated DeleteSidListParamVO param) throws Exception {
  867. // return cutModelService.deleteCutModel(param);
  868. // }
  869. }