Browse Source

仪器设备

master
wxd 12 months ago
parent
commit
192b888c3e
  1. 2
      src/Shentun.Peis.Domain/Devices/DeviceManager.cs

2
src/Shentun.Peis.Domain/Devices/DeviceManager.cs

@ -75,7 +75,7 @@ namespace Shentun.Peis.Devices
DataHelper.CheckEntityIsNull(sourceEntity);
Verify(targetEntity);
var existEntity = await _deviceRepository.FirstOrDefaultAsync(o => o.DeviceCode == sourceEntity.DeviceCode && o.Id != sourceEntity.Id);
var existEntity = await _deviceRepository.FirstOrDefaultAsync(o => o.DeviceCode == sourceEntity.DeviceCode && o.Id != targetEntity.Id);
if (existEntity != null)
{
throw new UserFriendlyException("编码已存在");

Loading…
Cancel
Save