设备信息不存在

This commit is contained in:
tanglong 2026-01-16 16:56:06 +08:00
parent 1bce08db4e
commit d29d2ec6ee

View File

@ -48,12 +48,12 @@ namespace VOL.WebApi.Filter
}
// 查询设备信息是否存在
var res = await _deviceAssocSchoolRepository.FindAsyncFirst(x => x.SchoolCode == schoolCode && x.Code == code);
if (res == null)
{
context.Result = new NotFoundObjectResult("设备信息不存在");
return;
}
//var res = await _deviceAssocSchoolRepository.FindAsyncFirst(x => x.SchoolCode == schoolCode && x.Code == code);
//if (res == null)
//{
// context.Result = new NotFoundObjectResult("设备信息不存在");
// return;
//}
// 执行下一个过滤器或操作
await next();