fix: fetchTasks 开始时间往前 5 秒覆盖扫描操作
This commit is contained in:
parent
10f5193f23
commit
7903e34a9c
@ -17,8 +17,8 @@ class HikvisionService extends BaseService {
|
|||||||
const str = String(datetime).trim();
|
const str = String(datetime).trim();
|
||||||
// 按 UTC 解析
|
// 按 UTC 解析
|
||||||
const utc = new Date(str + 'Z');
|
const utc = new Date(str + 'Z');
|
||||||
// 转为北京时间
|
// 转为北京时间,往前 5 秒覆盖扫描操作
|
||||||
const cst = new Date(utc.getTime() + 8 * 3600000);
|
const cst = new Date(utc.getTime() + 8 * 3600000 - 5000);
|
||||||
return cst.toISOString().replace('Z', '+08:00');
|
return cst.toISOString().replace('Z', '+08:00');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user