|
|
@@ -20,14 +20,25 @@ namespace HKLib.Interfaces |
|
|
|
/// </summary> |
|
|
|
public static bool SetTime(TimeSpilte input) |
|
|
|
{ |
|
|
|
return IHttpMultiClient.HttpMulti |
|
|
|
TimeSpilteDto dto = new TimeSpilteDto |
|
|
|
{ |
|
|
|
AMEndTime = input.AMEndTime.ToShortTimeString(), |
|
|
|
AMStartTime = input.AMStartTime.ToShortTimeString(), |
|
|
|
PMEndTime = input.PMEndTime.ToShortTimeString(), |
|
|
|
PMStartTime = input.PMStartTime.ToShortTimeString(), |
|
|
|
ATEndTime = input.ATEndTime.ToShortTimeString(), |
|
|
|
ATStartTime = input.ATStartTime.ToShortTimeString(), |
|
|
|
}; |
|
|
|
|
|
|
|
var data = IHttpMultiClient.HttpMulti |
|
|
|
.AddHeader(t => t.Headers = Header) |
|
|
|
.AddNode(t => |
|
|
|
{ |
|
|
|
t.NodePath = $"{Configer.SaasRoute}"; |
|
|
|
t.JsonParam = input.ToJson(); |
|
|
|
t.ReqType = MultiType.POST; |
|
|
|
}).Build().RunStringFirst().ToModel<JObject>()["isSuccess"].ToString().AsBool(); |
|
|
|
t.NodePath = $"{Configer.SaasRoute}api/one-card/eat-time-interval"; |
|
|
|
t.JsonParam = dto.ToJson(); |
|
|
|
t.ReqType = MultiType.PUT; |
|
|
|
}).Build().RunStringFirst(); |
|
|
|
return data.ToModel<JObject>()["data"]["isSuccess"].ToString().AsBool(); |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary> |
|
|
@@ -165,9 +176,9 @@ namespace HKLib.Interfaces |
|
|
|
{ |
|
|
|
t.NodePath = Route; |
|
|
|
t.ReqType = MultiType.POST; |
|
|
|
t.JsonParam = input.ToJson(); |
|
|
|
}).Build().RunStringFirst().ToModel<JObject>()["data"]["data"].ToJson().ToModel<List<ReportCountDto>>(); |
|
|
|
return data; |
|
|
|
t.JsonParam = (new { StartTime =input.StartTime.ToShortDateString(), EndTime=input.EndTime.ToShortDateString() }).ToJson(); |
|
|
|
}).Build().RunStringFirst(); |
|
|
|
return data.ToModel<JObject>()["data"]["data"].ToJson().ToModel<List<ReportCountDto>>(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |