修改 在线离线的判断逻辑
This commit is contained in:
@@ -772,6 +772,12 @@ namespace Common
|
||||
long current_timestamp = Convert.ToInt64(ts.TotalSeconds);
|
||||
return current_timestamp;
|
||||
}
|
||||
public static long GetCurrentTimeStamp_MS(DateTime dt)
|
||||
{
|
||||
TimeSpan ts = dt - new DateTime(1970, 1, 1, 0, 0, 0, 0, DateTimeKind.Local);
|
||||
long current_timestamp = Convert.ToInt64(ts.TotalMilliseconds);
|
||||
return current_timestamp;
|
||||
}
|
||||
public static DateTime GetCurrentDateTime(long timestampMilliseconds)
|
||||
{
|
||||
DateTime epoch = new DateTime(1970, 1, 1, 0, 0, 0, DateTimeKind.Local);
|
||||
|
||||
Reference in New Issue
Block a user