修复了后台运行数据地图时引发消息崩溃的问题
This commit is contained in:
@@ -2413,4 +2413,20 @@ function timeStamp2String() {
|
||||
var minute = datetime.getMinutes() < 10 ? "0" + datetime.getMinutes() : datetime.getMinutes();
|
||||
var second = datetime.getSeconds() < 10 ? "0" + datetime.getSeconds() : datetime.getSeconds();
|
||||
return year + "-" + month + "-" + date + " " + hour + ":" + minute + ":" + second;
|
||||
}
|
||||
|
||||
function isJSON(str) {
|
||||
if (typeof str == 'string') {
|
||||
try {
|
||||
var obj = JSON.parse(str);
|
||||
if (typeof obj == 'object' && obj) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
|
||||
} catch (e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user