fix 逻辑增加判断
This commit is contained in:
@@ -1,5 +1,4 @@
|
|||||||
using Dlhis.ScheduledTask.DeviceUploadLog.Services.Implements;
|
using Kurisu.AspNetCore.Utils.Extensions;
|
||||||
using Kurisu.AspNetCore.Utils.Extensions;
|
|
||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
|
|
||||||
namespace Dlhis.ScheduledTask.DeviceUploadLog.Response;
|
namespace Dlhis.ScheduledTask.DeviceUploadLog.Response;
|
||||||
@@ -77,8 +76,8 @@ public class DeviceUploadLogResponse
|
|||||||
/// 是否有效
|
/// 是否有效
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool Status { get; set; }
|
public bool Status { get; set; }
|
||||||
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 是否是异常记录
|
/// 是否是异常记录
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -86,7 +85,7 @@ public class DeviceUploadLogResponse
|
|||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
if (WorkGridInfo.IsEmpty())
|
if (NeedUpload || WorkGridInfo.IsEmpty())
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@@ -99,12 +98,12 @@ public class DeviceUploadLogResponse
|
|||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public string WorkGridInfo { get; set; }
|
public string WorkGridInfo { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
public class WorkGridInfo2
|
public class WorkGridInfo2
|
||||||
{
|
{
|
||||||
public bool IsError { get; set; }
|
public bool IsError { get; set; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public class DeviceUploadLogUserResponse
|
public class DeviceUploadLogUserResponse
|
||||||
{
|
{
|
||||||
public long Id { get; set; }
|
public long Id { get; set; }
|
||||||
@@ -168,7 +167,7 @@ public class DeviceUploadLogUserResponse
|
|||||||
/// 是否有效
|
/// 是否有效
|
||||||
/// </summary>
|
/// </summary>
|
||||||
public bool Status { get; set; }
|
public bool Status { get; set; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 是否是异常记录
|
/// 是否是异常记录
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -176,7 +175,7 @@ public class DeviceUploadLogUserResponse
|
|||||||
{
|
{
|
||||||
get
|
get
|
||||||
{
|
{
|
||||||
if (WorkGridInfo.IsEmpty())
|
if (NeedUpload || WorkGridInfo.IsEmpty())
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -487,7 +487,7 @@ public class DeviceUploadLogService : IDeviceUploadLogService
|
|||||||
|
|
||||||
public class WorkGridInfo
|
public class WorkGridInfo
|
||||||
{
|
{
|
||||||
public bool IsError => !PeriodType.HasValue;
|
public bool IsError => TimeSetting != null && PeriodType.HasValue == false;
|
||||||
public WorkGridInfoDetail WorkGrid { get; set; }
|
public WorkGridInfoDetail WorkGrid { get; set; }
|
||||||
public WorkGridTimePeriodEnumType? PeriodType { get; set; }
|
public WorkGridTimePeriodEnumType? PeriodType { get; set; }
|
||||||
public object TimeSetting { get; set; }
|
public object TimeSetting { get; set; }
|
||||||
|
|||||||
Reference in New Issue
Block a user