vs
This commit is contained in:
@@ -213,14 +213,15 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
CollectRescueSprechwuensche() {
|
CollectRescueSprechwuensche() {
|
||||||
let self = this;
|
let self = this;
|
||||||
new Promise((resolve, reject) => {
|
new Dexie.Promise((resolve, reject) => {
|
||||||
return self.ADisDB.ADisSprechwunsch.where({
|
self.ADisDB.ADisSprechwunsch.where({
|
||||||
done: 'false'
|
done: 'false'
|
||||||
}).each((myWunsch) => {
|
}).each((myWunsch) => {
|
||||||
if ($("#vehicle_list_" + myWunsch.vehicleID).find(".building_list_fms").text() != "5") {
|
if ($("#vehicle_list_" + myWunsch.vehicleID).find(".building_list_fms").text() != "5") {
|
||||||
self.RemoveRescueSprechwunschFromQueue(myWunsch.vehicleID);
|
self.RemoveRescueSprechwunschFromQueue(myWunsch.vehicleID);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
return resolve();
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
$("#building_list").find(".building_list_vehicle_element").each((_, elem) => {
|
$("#building_list").find(".building_list_vehicle_element").each((_, elem) => {
|
||||||
var VehicleStatus = $(elem).find(".building_list_fms").text();
|
var VehicleStatus = $(elem).find(".building_list_fms").text();
|
||||||
@@ -386,8 +387,8 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
CollectPoliceSprechwuensche() {
|
CollectPoliceSprechwuensche() {
|
||||||
let self = this;
|
let self = this;
|
||||||
new Promise((resolve, reject) => {
|
new Dexie.Promise((resolve, reject) => {
|
||||||
return self.ADisDB.ADisSprechwunschPolice.where({
|
self.ADisDB.ADisSprechwunschPolice.where({
|
||||||
done: 'false'
|
done: 'false'
|
||||||
}).each((myWunsch) => {
|
}).each((myWunsch) => {
|
||||||
if (!$("#mission_" + myWunsch.missionID).text().match(/Gefangene sollen abtransportiert werden/g)) {
|
if (!$("#mission_" + myWunsch.missionID).text().match(/Gefangene sollen abtransportiert werden/g)) {
|
||||||
@@ -395,6 +396,7 @@ class AutomaticDispose {
|
|||||||
return self.RemovePoliceSprechwunschFromQueue(myWunsch.missionID);
|
return self.RemovePoliceSprechwunschFromQueue(myWunsch.missionID);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
return resolve();
|
||||||
}).then(() => {
|
}).then(() => {
|
||||||
var MOIODOS = $('div#mission_list div.missionSideBarEntry:visible');
|
var MOIODOS = $('div#mission_list div.missionSideBarEntry:visible');
|
||||||
return MOIODOS.each((_, elem) => {
|
return MOIODOS.each((_, elem) => {
|
||||||
@@ -1427,6 +1429,7 @@ class AutomaticDispose {
|
|||||||
var $div = $("#mission-form > div:nth-child(7) > a");
|
var $div = $("#mission-form > div:nth-child(7) > a");
|
||||||
var isShow = $div.is(':hidden');
|
var isShow = $div.is(':hidden');
|
||||||
//console.log($div, isShow);
|
//console.log($div, isShow);
|
||||||
|
/*
|
||||||
if ($div.length && isShow && 1 == 0) {
|
if ($div.length && isShow && 1 == 0) {
|
||||||
var observer = new MutationObserver(function (mutations) {
|
var observer = new MutationObserver(function (mutations) {
|
||||||
mutations.forEach(function (mutation) {
|
mutations.forEach(function (mutation) {
|
||||||
@@ -1444,8 +1447,9 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
$div.click();
|
$div.click();
|
||||||
} else {
|
} else {
|
||||||
|
*/
|
||||||
self.StartAlarmProcessProc()
|
self.StartAlarmProcessProc()
|
||||||
}
|
//}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -2402,10 +2406,13 @@ class AutomaticDispose {
|
|||||||
$(document).ready(function () {
|
$(document).ready(function () {
|
||||||
var $div = $("a:contains('Fahrzeuganzeige begrenzt! Fehlende Fahrzeuge laden!')");
|
var $div = $("a:contains('Fahrzeuganzeige begrenzt! Fehlende Fahrzeuge laden!')");
|
||||||
var isShow = $div.is(':hidden');
|
var isShow = $div.is(':hidden');
|
||||||
|
var MissionID = document.location.pathname.substr(document.location.pathname.lastIndexOf("/") + 1);
|
||||||
//console.log($div, isShow);
|
//console.log($div, isShow);
|
||||||
if ($div.length && isShow && 1 == 0) {
|
if ($div.length && isShow) {
|
||||||
var observer = new MutationObserver(function (mutations) {
|
var observer = new MutationObserver(function (mutations) {
|
||||||
mutations.forEach(function (mutation) {
|
mutations.forEach(function (mutation) {
|
||||||
|
console.log(mutation.type, MissionID);
|
||||||
|
console.table(mutation, MissionID);
|
||||||
if (mutation.attributeName === "style") {
|
if (mutation.attributeName === "style") {
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
window.AutomaticDisposeCall = new AutomaticDispose();
|
window.AutomaticDisposeCall = new AutomaticDispose();
|
||||||
@@ -2414,13 +2421,12 @@ $(document).ready(function () {
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
observer.observe($div[0], {
|
observer.observe($div[0], {
|
||||||
attributes: true
|
attributes: true,
|
||||||
|
characterData: true
|
||||||
});
|
});
|
||||||
|
|
||||||
$div.click();
|
$div.click();
|
||||||
} else {
|
} else {
|
||||||
setTimeout(function () {
|
|
||||||
window.AutomaticDisposeCall = new AutomaticDispose();
|
window.AutomaticDisposeCall = new AutomaticDispose();
|
||||||
}, 500);
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
Reference in New Issue
Block a user