BusDeviceController.java 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. package com.coffee.bus.controller;
  2. import com.baomidou.mybatisplus.core.mapper.Mapper;
  3. import com.coffee.bus.entity.BusDeviceEntity;
  4. import com.coffee.bus.service.LocalBusDeviceService;
  5. import com.coffee.common.crud.BaseService;
  6. import com.coffee.common.crud.controller.BaseCrudController;
  7. import io.swagger.annotations.Api;
  8. import lombok.AllArgsConstructor;
  9. import org.springframework.web.bind.annotation.RequestMapping;
  10. import org.springframework.web.bind.annotation.RestController;
  11. /**
  12. * @author lifang
  13. * @version 1.0.0
  14. * @ClassName BusHospitalController.java
  15. * @Description TODO
  16. * @createTime 2022年03月19日 09:28:00
  17. */
  18. @RestController
  19. @AllArgsConstructor
  20. @RequestMapping("/bus/device/reg")
  21. @Api(tags = "经销商设备注册",description = "统一权限前缀(device:reg),device:reg:add")
  22. public class BusDeviceController extends BaseCrudController<BusDeviceEntity, String> {
  23. private final LocalBusDeviceService deviceRegisteredService;
  24. /**
  25. * 权限控制前缀
  26. * @return
  27. */
  28. @Override
  29. public String getPermissionPrefix() {
  30. return "device:reg";
  31. }
  32. @Override
  33. public BaseService<? extends Mapper<BusDeviceEntity>, BusDeviceEntity, String> getService() {
  34. return deviceRegisteredService;
  35. }
  36. }