diff --git a/src/SJZY.Track.Application/Services/TrackStatus/TrackStatusService.cs b/src/SJZY.Track.Application/Services/TrackStatus/TrackStatusService.cs index 686854db..b742ae81 100644 --- a/src/SJZY.Track.Application/Services/TrackStatus/TrackStatusService.cs +++ b/src/SJZY.Track.Application/Services/TrackStatus/TrackStatusService.cs @@ -92,7 +92,8 @@ public class TrackStatusService : ApplicationService, ITransientDependency a.Status == input.TrackStatus || a.EnStatus == input.EntrackStatus)); if (trackStatusEntity != null) { - throw new BusinessException(message: _stringLocalizer["TrackStatusExist"]); + //throw new BusinessException(message: _stringLocalizer["TrackStatusExist"]); + throw new BusinessException("当前子系统下,轨迹状态代码或轨迹状态或轨迹状态英文存在"); } #endregion @@ -112,7 +113,8 @@ public class TrackStatusService : ApplicationService, ITransientDependency a.Status == input.TrackStatus || a.EnStatus == input.EntrackStatus)); if (trackStatusEntity != null) { - throw new BusinessException(message: _stringLocalizer["TrackStatusExist"]); + //throw new BusinessException(message: _stringLocalizer["TrackStatusExist"]); + throw new BusinessException("当前子系统下,轨迹状态代码或轨迹状态或轨迹状态英文存在"); } #endregion @@ -130,7 +132,8 @@ public class TrackStatusService : ApplicationService, ITransientDependency var isExistStatus = await _trackContentRepository.GetFirstAsync(a => a.TrackStatusId==input.Id); if (isExistStatus!=null) { - throw new BusinessException(message: _stringLocalizer["IsExistTrackStatus"]); + //throw new BusinessException(message: _stringLocalizer["IsExistTrackStatus"]); + throw new BusinessException("轨迹内容已经绑定了该轨迹状态,请先删除轨迹内容后再删除该轨迹状态"); } #endregion var isTrue = await _trackStatusRepository.SoftDeleteAsync(x => x.Id == input.Id);