|
@@ -12,6 +12,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
import org.springframework.web.bind.annotation.RestController;
|
|
|
|
|
|
import javax.servlet.http.HttpServletRequest;
|
|
|
+import java.util.List;
|
|
|
import java.util.Map;
|
|
|
|
|
|
/**
|
|
@@ -34,9 +35,12 @@ public class DeviceFarmConfigController {
|
|
|
return deviceFarmConfigService.list(paramsMap);
|
|
|
}
|
|
|
@RequestMapping("/updateByFarmId")
|
|
|
- public Result updateByFarmId(HttpServletRequest httpServletRequest, @RequestBody DeviceFarmConfig deviceFarmConfig) {
|
|
|
+ public Result updateByFarmId(HttpServletRequest httpServletRequest, @RequestBody List<DeviceFarmConfig> deviceFarmConfig) {
|
|
|
+ for (DeviceFarmConfig farmConfig : deviceFarmConfig) {
|
|
|
+ deviceFarmConfigService.updateById(farmConfig);
|
|
|
|
|
|
- return new Result(ResultCode.SUCCESS,deviceFarmConfigService.updateById(deviceFarmConfig));
|
|
|
+ }
|
|
|
+ return new Result(10000,"修改成功",true);
|
|
|
}
|
|
|
|
|
|
}
|