1.添加ws配置

DataMaintenance
陈伟 2025-04-01 10:14:19 +08:00
parent b6d88d442e
commit 94b38ad63d
2 changed files with 12 additions and 10 deletions

View File

@ -552,11 +552,12 @@ namespace OpenAuth.App.ServiceApp.FireManagement
userPoint.CreateTime = DateTime.Now; userPoint.CreateTime = DateTime.Now;
var userPointHistory = userPoint.MapTo<FmUserPointHistory>(); var userPointHistory = userPoint.MapTo<FmUserPointHistory>();
var oldinfo = await db.Queryable<FmUserPoint>().Where(r => r.CreateId == userPoint.CreateId) var oldInfo = await db.Queryable<FmUserPoint>()
.Where(r => r.CreateId == userPoint.CreateId)
.FirstAsync(); .FirstAsync();
//上线弹窗 //上线弹窗 第一次上报或者上线时间不超过2分钟
if (oldinfo == null || (oldinfo != null && oldinfo.CreateTime.AddMinutes(2) < DateTime.Now)) if (oldInfo == null || (oldInfo != null && oldInfo.CreateTime.AddMinutes(2) < DateTime.Now))
{ {
var user = await db.Queryable<SysUser>().Where(r => r.Id == userPoint.CreateId) var user = await db.Queryable<SysUser>().Where(r => r.Id == userPoint.CreateId)
.FirstAsync(); .FirstAsync();
@ -581,13 +582,13 @@ namespace OpenAuth.App.ServiceApp.FireManagement
} }
if (oldinfo != null) if (oldInfo != null)
{ {
oldinfo.Lat = userPoint.Lat; oldInfo.Lat = userPoint.Lat;
oldinfo.Lng = userPoint.Lng; oldInfo.Lng = userPoint.Lng;
oldinfo.CreateTime = userPoint.CreateTime; oldInfo.CreateTime = userPoint.CreateTime;
oldinfo.Intype = userPoint.Intype; oldInfo.Intype = userPoint.Intype;
await db.Updateable(oldinfo).ExecuteCommandAsync(); await db.Updateable(oldInfo).ExecuteCommandAsync();
} }
else else
{ {

View File

@ -67,5 +67,6 @@
"TiffStoreNamePrefix": "tiff_store", "TiffStoreNamePrefix": "tiff_store",
"TiffDir": "E:/tiff" "TiffDir": "E:/tiff"
}, },
"FlyImageDir": "e:/fly" "FlyImageDir": "e:/fly",
"WebSocket": "ws://192.168.10.106:5698/ws"
} }