|
@@ -612,25 +612,26 @@ public class SnapshotOrderApplication : IOrderSnapshotApplication, IScopeDepende
|
|
|
if (_systemSettingCacheManager.Snapshot == false) return;
|
|
|
|
|
|
await _orderSnapshotRepository.Queryable()
|
|
|
- .LeftJoin<IndustryCase>((snapshot, industryCase) => snapshot.IndustryCase == industryCase.Id)
|
|
|
- .Where((snapshot, industryCase) => snapshot.Id == id)
|
|
|
- .Select((snapshot, industryCase) => new
|
|
|
+ .Where(snapshot => snapshot.Id == id)
|
|
|
+ .Select(snapshot => new
|
|
|
{
|
|
|
snapshot.IndustryId,
|
|
|
snapshot.IndustryName,
|
|
|
- industryCase.Name,
|
|
|
snapshot.IsRectifyDepartment,
|
|
|
snapshot.IsDangerDepartment,
|
|
|
snapshot.IsSafetyDepartment,
|
|
|
snapshot.SignRemark,
|
|
|
snapshot.SignUserId,
|
|
|
snapshot.SignUserName,
|
|
|
- snapshot.SignTime
|
|
|
+ snapshot.SignTime,
|
|
|
+ snapshot.IndustryCase
|
|
|
})
|
|
|
.FirstAsync(token)
|
|
|
.Then(async snapshot =>
|
|
|
{
|
|
|
- dto.IndustryName = snapshot.IndustryName + " " + snapshot.Name;
|
|
|
+ dto.IndustryName = snapshot.IndustryName;
|
|
|
+ if (snapshot.IndustryCase.NotNullOrEmpty())
|
|
|
+ dto.IndustryName = snapshot.IndustryName + " " + (await _industryCaseRepository.Queryable().Where(m => m.Id == snapshot.IndustryCase).FirstAsync())?.Name ?? string.Empty;
|
|
|
dto.IndustryId = snapshot.IndustryId;
|
|
|
dto.IsRectifyDepartment = snapshot.IsRectifyDepartment;
|
|
|
dto.IsDangerDepartment = snapshot.IsDangerDepartment;
|