|
@@ -37,9 +37,12 @@ public class TerminalPortController {
|
|
|
}
|
|
|
|
|
|
@PostMapping("/config")
|
|
|
- public Result config(@RequestBody TerminalPortConfigParam terminalPortConfigParam){
|
|
|
- TerminalPort terminalPort = portService.getById(terminalPortConfigParam.getPortId());
|
|
|
- terminalPort.setLocationId(terminalPortConfigParam.getLocationId());
|
|
|
+ public Result config(@RequestBody List<TerminalPort> list){
|
|
|
+ for (TerminalPort terminalPort : list) {
|
|
|
+ TerminalPort port = portService.getById(terminalPort.getId());
|
|
|
+ port.setLocationId(terminalPort.getLocationId());
|
|
|
+ portService.updateById(port);
|
|
|
+ }
|
|
|
return Result.SUCCESS();
|
|
|
}
|
|
|
|