You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.7 KiB

1 month ago
1 month ago
  1. package com.example.demo.controller;
  2. import com.example.demo.domain.vo.Result;
  3. import com.example.demo.service.GeneralService;
  4. import lombok.RequiredArgsConstructor;
  5. import lombok.extern.slf4j.Slf4j;
  6. import org.springframework.beans.factory.annotation.Autowired;
  7. import org.springframework.web.bind.annotation.CrossOrigin;
  8. import org.springframework.web.bind.annotation.PostMapping;
  9. import org.springframework.web.bind.annotation.RequestMapping;
  10. import org.springframework.web.bind.annotation.RestController;
  11. import java.util.Date;
  12. import java.util.List;
  13. /**
  14. * @program: GOLD
  15. * @ClassName GeneralController
  16. * @description:
  17. * @author: huangqizhen
  18. * @create: 202506-22 10:54
  19. * @Version 1.0
  20. **/
  21. @RestController
  22. @RequestMapping("/general")
  23. @RequiredArgsConstructor
  24. @Slf4j
  25. @CrossOrigin
  26. public class GeneralController {
  27. @Autowired
  28. private GeneralService generalService;
  29. @PostMapping("/market")
  30. public Result getMarket()
  31. {
  32. List<String> list = generalService.getMarket();
  33. return Result.success(list);
  34. }
  35. @PostMapping("/platform")
  36. public Result getPlatform()
  37. {
  38. List<String> list = generalService.getPlatform();
  39. return Result.success(list);
  40. }
  41. @PostMapping("/goods")
  42. public Result getGoods()
  43. {
  44. List<String> list = generalService.getGoods();
  45. return Result.success(list);
  46. }
  47. @PostMapping("/activity")
  48. public Result getActivity()
  49. {
  50. List<String> list = generalService.getActivity();
  51. return Result.success(list);
  52. }
  53. //获取用户权限地区
  54. @PostMapping("/getFilterMarket")
  55. public Result getFilterMarket() {
  56. List<String> list = generalService.getFilterMarket();
  57. return Result.success(list);
  58. }
  59. }