forked from dyf/fys-Multi-tenant
提交
This commit is contained in:
@ -7,6 +7,8 @@ import com.fuyuanshen.app.domain.vo.AppDeviceDetailVo;
|
||||
import com.fuyuanshen.app.service.device.AppDeviceBJQBizService;
|
||||
import com.fuyuanshen.common.core.domain.R;
|
||||
import com.fuyuanshen.common.core.validate.AddGroup;
|
||||
import com.fuyuanshen.common.ratelimiter.annotation.FunctionAccessAnnotation;
|
||||
import com.fuyuanshen.common.ratelimiter.annotation.FunctionAccessBatcAnnotation;
|
||||
import com.fuyuanshen.common.web.core.BaseController;
|
||||
import com.fuyuanshen.equipment.domain.dto.AppDeviceSendMsgBo;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
@ -41,6 +43,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 人员信息登记
|
||||
*/
|
||||
@PostMapping(value = "/registerPersonInfo")
|
||||
@FunctionAccessAnnotation("registerPersonInfo")
|
||||
public R<Void> registerPersonInfo(@Validated(AddGroup.class) @RequestBody AppPersonnelInfoBo bo) {
|
||||
return toAjax(appDeviceService.registerPersonInfo(bo));
|
||||
}
|
||||
@ -49,6 +52,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 发送信息
|
||||
*/
|
||||
@PostMapping(value = "/sendMessage")
|
||||
@FunctionAccessBatcAnnotation("sendMessage")
|
||||
public R<Void> sendMessage(@RequestBody AppDeviceSendMsgBo bo) {
|
||||
return toAjax(appDeviceService.sendMessage(bo));
|
||||
}
|
||||
@ -57,6 +61,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 发送报警信息
|
||||
*/
|
||||
@PostMapping(value = "/sendAlarmMessage")
|
||||
@FunctionAccessBatcAnnotation("sendAlarmMessage")
|
||||
public R<Void> sendAlarmMessage(@RequestBody AppDeviceSendMsgBo bo) {
|
||||
return toAjax(appDeviceService.sendAlarmMessage(bo));
|
||||
}
|
||||
@ -65,6 +70,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 上传设备logo图片
|
||||
*/
|
||||
@PostMapping("/uploadLogo")
|
||||
@FunctionAccessAnnotation("uploadLogo")
|
||||
public R<Void> upload(@Validated @ModelAttribute AppDeviceLogoUploadDto bo) {
|
||||
|
||||
MultipartFile file = bo.getFile();
|
||||
@ -80,6 +86,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 灯光模式
|
||||
* 0(关灯),1(强光模式),2(弱光模式), 3(爆闪模式), 4(泛光模式)
|
||||
*/
|
||||
@FunctionAccessAnnotation("lightModeSettings")
|
||||
@PostMapping("/lightModeSettings")
|
||||
public R<Void> lightModeSettings(@RequestBody DeviceInstructDto params) {
|
||||
// params 转 JSONObject
|
||||
@ -91,6 +98,7 @@ public class AppDeviceBJQController extends BaseController {
|
||||
* 灯光亮度设置
|
||||
*
|
||||
*/
|
||||
@FunctionAccessAnnotation("lightBrightnessSettings")
|
||||
@PostMapping("/lightBrightnessSettings")
|
||||
public R<Void> lightBrightnessSettings(@RequestBody DeviceInstructDto params) {
|
||||
appDeviceService.lightBrightnessSettings(params);
|
||||
@ -102,18 +110,10 @@ public class AppDeviceBJQController extends BaseController {
|
||||
*
|
||||
*/
|
||||
@PostMapping("/laserModeSettings")
|
||||
@FunctionAccessAnnotation("laserModeSettings")
|
||||
public R<Void> laserModeSettings(@RequestBody DeviceInstructDto params) {
|
||||
appDeviceService.laserModeSettings(params);
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图逆解析
|
||||
*
|
||||
*/
|
||||
@PostMapping("/mapReverseGeocoding")
|
||||
public R<Void> mapReverseGeocoding(@RequestBody DeviceInstructDto params) {
|
||||
String mapJson = appDeviceService.mapReverseGeocoding(params);
|
||||
return R.ok(mapJson);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user