Compare commits
33 Commits
master
...
nonworking2
| Author | SHA1 | Date | |
|---|---|---|---|
| 46efccd53a | |||
| 77fe05fc4b | |||
| 966d1ad67b | |||
| 61357300e3 | |||
| 17c33e5bb3 | |||
| 59b95b1807 | |||
| b5cbdc236f | |||
| c7d1157a1a | |||
| f020ae8000 | |||
| f4b04e11da | |||
| d8ecc4672e | |||
| 7fd6705513 | |||
| bb0db92ef9 | |||
| 537f48db96 | |||
| df13fc3598 | |||
| 1d50a3a2c9 | |||
| a7354d622d | |||
| b9b7e70d87 | |||
| 1c53ed7e19 | |||
| 944e3798d4 | |||
| b12b4c21e1 | |||
| 2b3782d787 | |||
| ea290015ef | |||
| ec01dfbec1 | |||
| 9a2bf77b50 | |||
| 00bbae0989 | |||
| 451c3a3568 | |||
| a51f7e4b76 | |||
| d02114b3f3 | |||
| 87f56daf15 | |||
| 0a661e44b1 | |||
| 7f146d2c41 | |||
| cf89b1178b |
+551
-61
File diff suppressed because it is too large
Load Diff
+1
-1
File diff suppressed because one or more lines are too long
Vendored
+552
-62
File diff suppressed because it is too large
Load Diff
Vendored
+728
-127
File diff suppressed because it is too large
Load Diff
@@ -131,11 +131,11 @@ function emsDepartment($data)
|
|||||||
}
|
}
|
||||||
if ($key == "Benötigte GW-San") {
|
if ($key == "Benötigte GW-San") {
|
||||||
$pd["use_SEG_FULL"] = true;
|
$pd["use_SEG_FULL"] = true;
|
||||||
} elseif ($key == "Benötigte RTW" || ($key == "Wahrscheinlichkeit, dass ein Patient transportiert werden muss" && $value > 40)) {
|
} elseif ($key == "Benötigte RTW" || $key == "Wahrscheinlichkeit, dass ein Patient transportiert werden muss") {
|
||||||
$pd["use_RTW"] = true;
|
$pd["use_RTW"] = true;
|
||||||
} elseif ($key == "NEF Anforderungswahrscheinlichkeit" && $value > 40) {
|
} elseif ($key == "NEF Anforderungswahrscheinlichkeit") {
|
||||||
$pd["use_NEF"] = true;
|
$pd["use_NEF"] = true;
|
||||||
} elseif ($key == "RTH Anforderungswahrscheinlichkeit" && $value > 30) {
|
} elseif ($key == "RTH Anforderungswahrscheinlichkeit") {
|
||||||
$pd["use_RTH"] = true;
|
$pd["use_RTH"] = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -295,6 +295,14 @@ foreach (glob("*.json") as $filename) {
|
|||||||
$mission['id'] = $mission_id;
|
$mission['id'] = $mission_id;
|
||||||
$mission['type'] = $mission_id;
|
$mission['type'] = $mission_id;
|
||||||
$mission['name'] = $data['Name'];
|
$mission['name'] = $data['Name'];
|
||||||
|
|
||||||
|
//$mission['share'] = isset($data['Tritt nur ab dem Datum auf']) ? true : false;
|
||||||
|
$mission['share'] = false;
|
||||||
|
|
||||||
|
if (isset($data['Credits im Durchschnitt']) && intval($data['Credits im Durchschnitt']) >= 7000 && $mission['share'] == false) {
|
||||||
|
$mission['share'] = true;
|
||||||
|
}
|
||||||
|
|
||||||
$fd = fireDepartment($data);
|
$fd = fireDepartment($data);
|
||||||
if (array_sum($fd) > 0) {
|
if (array_sum($fd) > 0) {
|
||||||
$mission['fire_department'] = $fd;
|
$mission['fire_department'] = $fd;
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
for i in $(seq 0 421); do
|
for i in $(seq 421 423); do
|
||||||
curl -s -o "./missions/$i.html" "https://www.leitstellenspiel.de/einsaetze/$i"
|
curl -s -o "./missions/$i.html" "https://www.leitstellenspiel.de/einsaetze/$i"
|
||||||
html2text -utf8 -style pretty -width 100 -o "./missions/$i.text" "./missions/$i.html"
|
html2text -utf8 -style pretty -width 100 -o "./missions/$i.text" "./missions/$i.html"
|
||||||
lynx --dump "./missions/$i.html" > "./missions/$i.txt"
|
lynx --dump "./missions/$i.html" > "./missions/$i.txt"
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
|
|
||||||
<title>LEITSTELLENSPIEL.DE - baue deine eigene Leitstelle, in deiner Stadt!</title>
|
<title>LEITSTELLENSPIEL.DE - baue deine eigene Leitstelle, in deiner Stadt!</title>
|
||||||
<meta content="authenticity_token" name="csrf-param" />
|
<meta content="authenticity_token" name="csrf-param" />
|
||||||
<meta content="BdGPJqNrxq+PqX5AkGSqL90dMTtC06dmXplZP5exEwk=" name="csrf-token" />
|
<meta content="cvOny8TDgPA/eJthVo45f8+Vh/ExGdKnenC3q0Fr0sk=" name="csrf-token" />
|
||||||
|
|
||||||
<script src="/assets/application-a789289a71061d030b76a864e1d16075.js" type="text/javascript"></script>
|
<script src="/assets/application-a789289a71061d030b76a864e1d16075.js" type="text/javascript"></script>
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,242 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="de">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
|
||||||
|
|
||||||
|
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
|
||||||
|
|
||||||
|
|
||||||
|
<title>LEITSTELLENSPIEL.DE - baue deine eigene Leitstelle, in deiner Stadt!</title>
|
||||||
|
<meta content="authenticity_token" name="csrf-param" />
|
||||||
|
<meta content="/1vfZbjIof1sP0Gy1juDZhzIKL3GHnKnAPVcFhmrmLU=" name="csrf-token" />
|
||||||
|
|
||||||
|
<script src="/assets/application-a789289a71061d030b76a864e1d16075.js" type="text/javascript"></script>
|
||||||
|
|
||||||
|
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
|
||||||
|
<!--[if lt IE 9]>
|
||||||
|
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.6.1/html5shiv.js" type="text/javascript"></script>
|
||||||
|
<![endif]-->
|
||||||
|
|
||||||
|
<link href="/assets/application-028394b6ea814be350e95b1aa7bb4711.css" media="all" rel="stylesheet" type="text/css" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script type="text/javascript"> //Set language
|
||||||
|
I18n.defaultLocale = "de";
|
||||||
|
I18n.locale = "de";
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
</head>
|
||||||
|
<body class="
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
">
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$(function(){
|
||||||
|
tellParent("lightboxAdjust();");
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<img src="/images/ajax-loader.gif" class="ajax-loader" id="ajax-loader">
|
||||||
|
|
||||||
|
|
||||||
|
<div class="container-fluid" id="iframe-inside-container">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<ol class="breadcrumb">
|
||||||
|
|
||||||
|
<li><a href="/einsaetze">Mögliche Einsätze</a></li>
|
||||||
|
|
||||||
|
|
||||||
|
<li class="active">Sachbeschädigung an PKW</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<h1>
|
||||||
|
<img src="/images/caraccident_gruen.png">
|
||||||
|
<img src="/images/caraccident_gelb.png">
|
||||||
|
<img src="/images/caraccident_rot.png">
|
||||||
|
Sachbeschädigung an PKW
|
||||||
|
</h1>
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
<div class="col-md-4">
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Credits im Durchschnitt
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
400
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Vorraussetzung an Polizeiwachen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4">
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte Streifenwagen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4">
|
||||||
|
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="javascript:history.back()">Zurück</a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Facebook Pixel Code -->
|
||||||
|
<script>
|
||||||
|
!function(f,b,e,v,n,t,s)
|
||||||
|
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||||
|
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
|
||||||
|
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
|
||||||
|
n.queue=[];t=b.createElement(e);t.async=!0;
|
||||||
|
t.src=v;s=b.getElementsByTagName(e)[0];
|
||||||
|
s.parentNode.insertBefore(t,s)}(window, document,'script',
|
||||||
|
'https://connect.facebook.net/en_US/fbevents.js');
|
||||||
|
fbq('init', '2182797941993258');
|
||||||
|
fbq('track', 'PageView');
|
||||||
|
</script>
|
||||||
|
<noscript><img height="1" width="1" style="display:none"
|
||||||
|
src="https://www.facebook.com/tr?id=2182797941993258&ev=PageView&noscript=1"
|
||||||
|
/></noscript>
|
||||||
|
<!-- End Facebook Pixel Code -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
if(window.top !== window.self) {
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
$("#iframe-inside-container").css("width", "auto");
|
||||||
|
$("#iframe-inside-container").css("height", "auto");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
window.addEventListener("keydown",
|
||||||
|
function(e){
|
||||||
|
|
||||||
|
if (!$("input:text").is(":focus"))
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
if (e.keyCode == 27)
|
||||||
|
{
|
||||||
|
|
||||||
|
tellParent("lightboxClose();");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
false);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"Credits im Durchschnitt":"400","Vorraussetzung an Polizeiwachen":"1","Benötigte Streifenwagen":"1","Name":"Sachbeschädigung an PKW"}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
1. Mögliche_Einsätze
|
||||||
|
2. Sachbeschädigung an PKW
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Sachbeschädigung an PKW
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Credits im Durchschnitt 400
|
||||||
|
Vorraussetzung an Polizeiwachen 1
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Benötigte Streifenwagen1
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
|
||||||
|
Zurück
|
||||||
|
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
[ajax-loader.gif]
|
||||||
|
|
||||||
|
1. [1]Mögliche Einsätze
|
||||||
|
2. Sachbeschädigung an PKW
|
||||||
|
|
||||||
|
[caraccident_gruen.png] [caraccident_gelb.png] [caraccident_rot.png]
|
||||||
|
Sachbeschädigung an PKW
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Credits im Durchschnitt 400
|
||||||
|
Vorraussetzung an Polizeiwachen 1
|
||||||
|
Beschreibung Wert
|
||||||
|
Benötigte Streifenwagen 1
|
||||||
|
Beschreibung Wert
|
||||||
|
[2]Zurück
|
||||||
|
|
||||||
|
[tr?id=2182797941993258&ev=PageView&noscript=1]
|
||||||
|
|
||||||
|
Verweise
|
||||||
|
|
||||||
|
1. file:///einsaetze
|
||||||
|
2. javascript:history.back()
|
||||||
@@ -0,0 +1,415 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="de">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1">
|
||||||
|
|
||||||
|
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
|
||||||
|
|
||||||
|
|
||||||
|
<title>LEITSTELLENSPIEL.DE - baue deine eigene Leitstelle, in deiner Stadt!</title>
|
||||||
|
<meta content="authenticity_token" name="csrf-param" />
|
||||||
|
<meta content="ftiiGYcaqxTBxvpRVtzy+XpuEqIE9is8LacbnV7bmNo=" name="csrf-token" />
|
||||||
|
|
||||||
|
<script src="/assets/application-a789289a71061d030b76a864e1d16075.js" type="text/javascript"></script>
|
||||||
|
|
||||||
|
<!-- Le HTML5 shim, for IE6-8 support of HTML elements -->
|
||||||
|
<!--[if lt IE 9]>
|
||||||
|
<script src="//cdnjs.cloudflare.com/ajax/libs/html5shiv/3.6.1/html5shiv.js" type="text/javascript"></script>
|
||||||
|
<![endif]-->
|
||||||
|
|
||||||
|
<link href="/assets/application-028394b6ea814be350e95b1aa7bb4711.css" media="all" rel="stylesheet" type="text/css" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script type="text/javascript"> //Set language
|
||||||
|
I18n.defaultLocale = "de";
|
||||||
|
I18n.locale = "de";
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
</head>
|
||||||
|
<body class="
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
">
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
$(function(){
|
||||||
|
tellParent("lightboxAdjust();");
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
<img src="/images/ajax-loader.gif" class="ajax-loader" id="ajax-loader">
|
||||||
|
|
||||||
|
|
||||||
|
<div class="container-fluid" id="iframe-inside-container">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<ol class="breadcrumb">
|
||||||
|
|
||||||
|
<li><a href="/einsaetze">Mögliche Einsätze</a></li>
|
||||||
|
|
||||||
|
|
||||||
|
<li class="active">Brand in Klassenraum</li>
|
||||||
|
</ol>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<h1>
|
||||||
|
<img src="/images/fire_gruen.png">
|
||||||
|
<img src="/images/fire_gelb.png">
|
||||||
|
<img src="/images/fire_rot.png">
|
||||||
|
Brand in Klassenraum
|
||||||
|
</h1>
|
||||||
|
<div class="row">
|
||||||
|
|
||||||
|
<div class="col-md-4">
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Credits im Durchschnitt
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
3100
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Vorraussetzung an Polizeiwachen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
3
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Vorraussetzung an Feuerwachen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
11
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Vorraussetzung an Rettungswachen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
10
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Ort
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
Schule
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4">
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte Löschfahrzeuge
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
6
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte Drehleitern
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte Rüstwagen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte ELW 1
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
2
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte ELW 2
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte Streifenwagen
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
3
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte GW L 2 Wasser
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
GW-L2-Wasser Anforderungswahrscheinlichkeit
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
10
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Benötigte GW-A
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
1
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
GW-A Anforderungswahrscheinlichkeit
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
5
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4">
|
||||||
|
|
||||||
|
<table class="table table-striped">
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<th>Beschreibung</th>
|
||||||
|
<th>Wert</th>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
<tbody>
|
||||||
|
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Maximale Patientenanzahl
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
20
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Wahrscheinlichkeit, dass ein Patient transportiert werden muss
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
50
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
NEF Anforderungswahrscheinlichkeit
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
|
||||||
|
10
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Fachrichtung für Patienten
|
||||||
|
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
|
||||||
|
Allgemeine Innere
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<a href="javascript:history.back()">Zurück</a>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- Facebook Pixel Code -->
|
||||||
|
<script>
|
||||||
|
!function(f,b,e,v,n,t,s)
|
||||||
|
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
|
||||||
|
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
|
||||||
|
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
|
||||||
|
n.queue=[];t=b.createElement(e);t.async=!0;
|
||||||
|
t.src=v;s=b.getElementsByTagName(e)[0];
|
||||||
|
s.parentNode.insertBefore(t,s)}(window, document,'script',
|
||||||
|
'https://connect.facebook.net/en_US/fbevents.js');
|
||||||
|
fbq('init', '2182797941993258');
|
||||||
|
fbq('track', 'PageView');
|
||||||
|
</script>
|
||||||
|
<noscript><img height="1" width="1" style="display:none"
|
||||||
|
src="https://www.facebook.com/tr?id=2182797941993258&ev=PageView&noscript=1"
|
||||||
|
/></noscript>
|
||||||
|
<!-- End Facebook Pixel Code -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<script>
|
||||||
|
if(window.top !== window.self) {
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
|
||||||
|
$("#iframe-inside-container").css("width", "auto");
|
||||||
|
$("#iframe-inside-container").css("height", "auto");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
window.addEventListener("keydown",
|
||||||
|
function(e){
|
||||||
|
|
||||||
|
if (!$("input:text").is(":focus"))
|
||||||
|
{
|
||||||
|
|
||||||
|
|
||||||
|
if (e.keyCode == 27)
|
||||||
|
{
|
||||||
|
|
||||||
|
tellParent("lightboxClose();");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
false);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"Credits im Durchschnitt":"3100","Vorraussetzung an Polizeiwachen":"3","Vorraussetzung an Feuerwachen":"11","Vorraussetzung an Rettungswachen":"10","Ort":"Schule","Benötigte Löschfahrzeuge":"6","Benötigte Drehleitern":"1","Benötigte Rüstwagen":"1","Benötigte ELW 1":"2","Benötigte ELW 2":"1","Benötigte Streifenwagen":"3","Benötigte GW L 2 Wasser":"1","GW-L2-Wasser Anforderungswahrscheinlichkeit":"10","Benötigte GW-A":"1","GW-A Anforderungswahrscheinlichkeit":"5","Maximale Patientenanzahl":"20","Wahrscheinlichkeit, dass ein Patient transportiert werden muss":"50","NEF Anforderungswahrscheinlichkeit":"10","Fachrichtung für Patienten":"Allgemeine Innere","Name":"Brand in Klassenraum"}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
1. Mögliche_Einsätze
|
||||||
|
2. Brand in Klassenraum
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Brand in Klassenraum
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Credits im Durchschnitt 3100
|
||||||
|
Vorraussetzung an Polizeiwachen 3
|
||||||
|
Vorraussetzung an Feuerwachen 11
|
||||||
|
Vorraussetzung an Rettungswachen 10
|
||||||
|
Ort Schule
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Benötigte Löschfahrzeuge 6
|
||||||
|
Benötigte Drehleitern 1
|
||||||
|
Benötigte Rüstwagen 1
|
||||||
|
Benötigte ELW 1 2
|
||||||
|
Benötigte ELW 2 1
|
||||||
|
Benötigte Streifenwagen 3
|
||||||
|
Benötigte GW L 2 Wasser 1
|
||||||
|
GW-L2-Wasser Anforderungswahrscheinlichkeit 10
|
||||||
|
Benötigte GW-A 1
|
||||||
|
GW-A Anforderungswahrscheinlichkeit 5
|
||||||
|
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Maximale Patientenanzahl 20
|
||||||
|
Wahrscheinlichkeit, dass ein Patient transportiert werden muss 50
|
||||||
|
NEF Anforderungswahrscheinlichkeit 10
|
||||||
|
Fachrichtung für Patienten Allgemeine Innere
|
||||||
|
|
||||||
|
Zurück
|
||||||
|
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
[ajax-loader.gif]
|
||||||
|
|
||||||
|
1. [1]Mögliche Einsätze
|
||||||
|
2. Brand in Klassenraum
|
||||||
|
|
||||||
|
[fire_gruen.png] [fire_gelb.png] [fire_rot.png] Brand in Klassenraum
|
||||||
|
|
||||||
|
Beschreibung Wert
|
||||||
|
Credits im Durchschnitt 3100
|
||||||
|
Vorraussetzung an Polizeiwachen 3
|
||||||
|
Vorraussetzung an Feuerwachen 11
|
||||||
|
Vorraussetzung an Rettungswachen 10
|
||||||
|
Ort Schule
|
||||||
|
Beschreibung Wert
|
||||||
|
Benötigte Löschfahrzeuge 6
|
||||||
|
Benötigte Drehleitern 1
|
||||||
|
Benötigte Rüstwagen 1
|
||||||
|
Benötigte ELW 1 2
|
||||||
|
Benötigte ELW 2 1
|
||||||
|
Benötigte Streifenwagen 3
|
||||||
|
Benötigte GW L 2 Wasser 1
|
||||||
|
GW-L2-Wasser Anforderungswahrscheinlichkeit 10
|
||||||
|
Benötigte GW-A 1
|
||||||
|
GW-A Anforderungswahrscheinlichkeit 5
|
||||||
|
Beschreibung Wert
|
||||||
|
Maximale Patientenanzahl 20
|
||||||
|
Wahrscheinlichkeit, dass ein Patient transportiert werden muss 50
|
||||||
|
NEF Anforderungswahrscheinlichkeit 10
|
||||||
|
Fachrichtung für Patienten Allgemeine Innere
|
||||||
|
[2]Zurück
|
||||||
|
|
||||||
|
[tr?id=2182797941993258&ev=PageView&noscript=1]
|
||||||
|
|
||||||
|
Verweise
|
||||||
|
|
||||||
|
1. file:///einsaetze
|
||||||
|
2. javascript:history.back()
|
||||||
@@ -63,7 +63,7 @@ RTW();
|
|||||||
//alertFhz(rtw, 1, 'RTW', false);
|
//alertFhz(rtw, 1, 'RTW', false);
|
||||||
} else if ([116,276,322,370].indexOf(help) != -1 && !(isVerband)) {
|
} else if ([116,276,322,370].indexOf(help) != -1 && !(isVerband)) {
|
||||||
alertFhz(fustw, 4, 'FuStW', false);
|
alertFhz(fustw, 4, 'FuStW', false);
|
||||||
} else if ([117,119,145,148,149,150,153,188,189,190,202,209,241,267,269,270,284,285,292,372,418,60,61,62,63,64,65,66,67,68,69,70,71,81,82,85,90].indexOf(help) != -1 && !(isVerband)) {
|
} else if ([117,119,145,148,149,150,153,188,189,190,202,209,241,267,269,270,284,285,292,372,418,422,60,61,62,63,64,65,66,67,68,69,70,71,81,82,85,90].indexOf(help) != -1 && !(isVerband)) {
|
||||||
alertFhz(fustw, 1, 'FuStW', false);
|
alertFhz(fustw, 1, 'FuStW', false);
|
||||||
} else if ([118,151].indexOf(help) != -1 && !(isVerband)) {
|
} else if ([118,151].indexOf(help) != -1 && !(isVerband)) {
|
||||||
alertFhz(fustw, 3, 'FuStW', false);
|
alertFhz(fustw, 3, 'FuStW', false);
|
||||||
@@ -1364,7 +1364,25 @@ alertFhz(gwg, 1, 'GW-G', false);
|
|||||||
alertFhz(elw2, 1, 'ELW2', false);
|
alertFhz(elw2, 1, 'ELW2', false);
|
||||||
alertFhz(dl, 1, 'DL', false);
|
alertFhz(dl, 1, 'DL', false);
|
||||||
} else if ([421].indexOf(help) != -1 && !(isVerband)) {
|
} else if ([421].indexOf(help) != -1 && !(isVerband)) {
|
||||||
} else if ([43].indexOf(help) != -1 && !(isVerband)) {
|
alertFhz(ruest, 1, 'RÜST', false);
|
||||||
|
alertFhz(nef, 1, 'NEF', false);
|
||||||
|
alertFhz(lf, 3, 'LF', false);
|
||||||
|
alertFhz(fustw, 2, 'FuStW', false);
|
||||||
|
alertFhz(elw1, 1, 'ELW1', false);
|
||||||
|
RTW();
|
||||||
|
//alertFhz(rtw, 1, 'RTW', false);
|
||||||
|
} else if ([423].indexOf(help) != -1 && !(isVerband)) {
|
||||||
|
alertFhz(ruest, 1, 'RÜST', false);
|
||||||
|
alertFhz(nef, 1, 'NEF', false);
|
||||||
|
alertFhz(lf, 6, 'LF', false);
|
||||||
|
alertFhz(gws, 1, 'GW-S', false);
|
||||||
|
alertFhz(gwa, 1, 'GW-A', false);
|
||||||
|
alertFhz(fustw, 3, 'FuStW', false);
|
||||||
|
alertFhz(elw2, 1, 'ELW2', false);
|
||||||
|
alertFhz(dl, 1, 'DL', false);
|
||||||
|
RTW();
|
||||||
|
//alertFhz(rtw, 20, 'RTW', false);
|
||||||
|
} else if ([43].indexOf(help) != -1 && !(isVerband)) {
|
||||||
alertFhz(ruest, 5, 'RÜST', false);
|
alertFhz(ruest, 5, 'RÜST', false);
|
||||||
alertFhz(oel, 2, 'GW-ÖL', false);
|
alertFhz(oel, 2, 'GW-ÖL', false);
|
||||||
alertFhz(lf, 10, 'LF', false);
|
alertFhz(lf, 10, 'LF', false);
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
{"00080":["189"],"00100":["117","119","148","149","153","154","188","284","349","60","61"],"00110":["0","288","37","38","39","40","403","404","410"],"00120":["159","62","63","67","68","69","70","71"],"00130":["78"],"00150":["145","150","160","190","209","267","285","64","65","66"],"00170":["1"],"00200":["241","269","270","318","4","415","85"],"00210":["7"],"00220":["260","8"],"00240":["11"],"00250":["9","90"],"00300":["202","287","292","371","372","375","98"],"00310":["12","191","52"],"00340":["17","3","338"],"00350":["111","277"],"00370":["158","2","259","337","91"],"00400":["143","144","265","266","289","31","402","408","418","81","82","94"],"00500":["216","217","218","219","220","301","336","357","360","361","362","363","364","365","74","77","88"],"00550":["118","366"],"00600":["10","122","130","168","169","170","172","376","383","6"],"00610":["203"],"00650":["19"],"00700":["128","173","18","27","303","329","73"],"00750":["152","199"],"00800":["129","290","421","76"],"00850":["112"],"00870":["55"],"00900":["100","114","161","175","24","263","313","379","380","381","382"],"00980":["13","405","406","409"],"01000":["14","194","195","196","230","244","25","250","261","282","308","309","310","319","370","390"],"01010":["15","344"],"01020":["174","286"],"01100":["123","16","295","311","384"],"01200":["151","166","23","243","245","251","328","33","345"],"01310":["32"],"01400":["162","163","167","246","247","252","253","28","5"],"01410":["53"],"01500":["101","113","138","142","235","264","280","298","300","317","323"],"01600":["116","124","140","272","273","401"],"01700":["125","237","355","356"],"01800":["106","107","321","369","79","84"],"01900":["192","30","314","392"],"02000":["102","104","126","131","193","197","228","236","238","248","254","276","330","72","80"],"02020":["296"],"02100":["176","242"],"02200":["103","105","120","127"],"02230":["187"],"02400":["21"],"02470":["29"],"02500":["121","198","20","240","257","262","278","299","322","342","343","388","413","83","89","97"],"02700":["22","399"],"02800":["258","279","367"],"02900":["178","96"],"03000":["214","239","249","255","331","393","394","395","396","412","414","86","87","93"],"03200":["398"],"03310":["36"],"03500":["139","204","232","327"],"03510":["26"],"03600":["141"],"03620":["51"],"03700":["407"],"03710":["34"],"03720":["42"],"03810":["35"],"04000":["134","171","208","215","224","229","231","234","283","351","358","95"],"04100":["135"],"04200":["146","268"],"04400":["223","315","378"],"04500":["233","353","419"],"04600":["177"],"05000":["132","226","227"],"05050":["400"],"05100":["133","205","385"],"05400":["316"],"05500":["200","386"],"05630":["186"],"05900":["411"],"06000":["302","307","334","335","347"],"06050":["271"],"06500":["304","346","387"],"07000":["225","275","291","325"],"07500":["352","368"],"08000":["136","306"],"08100":["137"],"08500":["389"],"09000":["201","359"],"10000":["324","332","333","348"],"10010":["256","41","43"],"10020":["75"],"10200":["206"],"11200":["213"],"11500":["320"],"12000":["294"],"13000":["305"],"14000":["222"],"14010":["59"],"16010":["207"],"17000":["221","350","99"]}
|
{"00080":["189"],"00100":["117","119","148","149","153","154","188","284","349","60","61"],"00110":["0","288","37","38","39","40","403","404","410"],"00120":["159","62","63","67","68","69","70","71"],"00130":["78"],"00150":["145","150","160","190","209","267","285","64","65","66"],"00170":["1"],"00200":["241","269","270","318","4","415","85"],"00210":["7"],"00220":["260","8"],"00240":["11"],"00250":["9","90"],"00300":["202","287","292","371","372","375","98"],"00310":["12","191","52"],"00340":["17","3","338"],"00350":["111","277"],"00370":["158","2","259","337","91"],"00400":["143","144","265","266","289","31","402","408","418","422","81","82","94"],"00500":["216","217","218","219","220","301","336","357","360","361","362","363","364","365","74","77","88"],"00550":["118","366"],"00600":["10","122","130","168","169","170","172","376","383","6"],"00610":["203"],"00650":["19"],"00700":["128","173","18","27","303","329","73"],"00750":["152","199"],"00800":["129","290","421","76"],"00850":["112"],"00870":["55"],"00900":["100","114","161","175","24","263","313","379","380","381","382"],"00980":["13","405","406","409"],"01000":["14","194","195","196","230","244","25","250","261","282","308","309","310","319","370","390"],"01010":["15","344"],"01020":["174","286"],"01100":["123","16","295","311","384"],"01200":["151","166","23","243","245","251","328","33","345"],"01310":["32"],"01400":["162","163","167","246","247","252","253","28","5"],"01410":["53"],"01500":["101","113","138","142","235","264","280","298","300","317","323"],"01600":["116","124","140","272","273","401"],"01700":["125","237","355","356"],"01800":["106","107","321","369","79","84"],"01900":["192","30","314","392"],"02000":["102","104","126","131","193","197","228","236","238","248","254","276","330","72","80"],"02020":["296"],"02100":["176","242"],"02200":["103","105","120","127"],"02230":["187"],"02400":["21"],"02470":["29"],"02500":["121","198","20","240","257","262","278","299","322","342","343","388","413","83","89","97"],"02700":["22","399"],"02800":["258","279","367"],"02900":["178","96"],"03000":["214","239","249","255","331","393","394","395","396","412","414","86","87","93"],"03100":["423"],"03200":["398"],"03310":["36"],"03500":["139","204","232","327"],"03510":["26"],"03600":["141"],"03620":["51"],"03700":["407"],"03710":["34"],"03720":["42"],"03810":["35"],"04000":["134","171","208","215","224","229","231","234","283","351","358","95"],"04100":["135"],"04200":["146","268"],"04400":["223","315","378"],"04500":["233","353","419"],"04600":["177"],"05000":["132","226","227"],"05050":["400"],"05100":["133","205","385"],"05400":["316"],"05500":["200","386"],"05630":["186"],"05900":["411"],"06000":["302","307","334","335","347"],"06050":["271"],"06500":["304","346","387"],"07000":["225","275","291","325"],"07500":["352","368"],"08000":["136","306"],"08100":["137"],"08500":["389"],"09000":["201","359"],"10000":["324","332","333","348"],"10010":["256","41","43"],"10020":["75"],"10200":["206"],"11200":["213"],"11500":["320"],"12000":["294"],"13000":["305"],"14000":["222"],"14010":["59"],"16010":["207"],"17000":["221","350","99"]}
|
||||||
+176
-65
@@ -125,7 +125,7 @@ class AutomaticDispose {
|
|||||||
await self.genSettings()
|
await self.genSettings()
|
||||||
setInterval(self.genSettings.bind(self), 1000);
|
setInterval(self.genSettings.bind(self), 1000);
|
||||||
|
|
||||||
if (window.location.pathname === "/" || window.location.pathname === "/#") {
|
if (window.location.pathname === "/" || window.location.pathname === "/#" || window.location.pathname === "/#_=_") {
|
||||||
self.GetAvailableMissions()
|
self.GetAvailableMissions()
|
||||||
self.IndexPage()
|
self.IndexPage()
|
||||||
setInterval(self.CollectRescueSprechwuensche.bind(self), 2500);
|
setInterval(self.CollectRescueSprechwuensche.bind(self), 2500);
|
||||||
@@ -133,9 +133,9 @@ class AutomaticDispose {
|
|||||||
self.CollectRescueSprechwuensche();
|
self.CollectRescueSprechwuensche();
|
||||||
setInterval(self.CollectPoliceSprechwuensche.bind(self), 2500);
|
setInterval(self.CollectPoliceSprechwuensche.bind(self), 2500);
|
||||||
setInterval(self.OpenNextPoliceSprechwunsch.bind(self), 5000);
|
setInterval(self.OpenNextPoliceSprechwunsch.bind(self), 5000);
|
||||||
|
self.CollectPoliceSprechwuensche();
|
||||||
|
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
self.CollectPoliceSprechwuensche();
|
|
||||||
self.CollectMissions();
|
self.CollectMissions();
|
||||||
self.ReadAndAddMissions();
|
self.ReadAndAddMissions();
|
||||||
}, 500);
|
}, 500);
|
||||||
@@ -473,7 +473,6 @@ class AutomaticDispose {
|
|||||||
this.Collect_Jails();
|
this.Collect_Jails();
|
||||||
} else {
|
} else {
|
||||||
let MissionID = document.location.pathname.substr(document.location.pathname.lastIndexOf("/") + 1);
|
let MissionID = document.location.pathname.substr(document.location.pathname.lastIndexOf("/") + 1);
|
||||||
console.log('Check_Call_Police_Active', MissionID)
|
|
||||||
this.RemovePoliceSprechwunschFromQueue(MissionID).then((deleteCount) => {
|
this.RemovePoliceSprechwunschFromQueue(MissionID).then((deleteCount) => {
|
||||||
$("#adis-sprechwunsch-police-frame").attr("src", "");
|
$("#adis-sprechwunsch-police-frame").attr("src", "");
|
||||||
$("#adis-sprechwunsch-police-frame").attr("mission_id", "empty");
|
$("#adis-sprechwunsch-police-frame").attr("mission_id", "empty");
|
||||||
@@ -857,6 +856,29 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
CollectMissions() {
|
CollectMissions() {
|
||||||
const self = this;
|
const self = this;
|
||||||
|
|
||||||
|
self.ADisDB.transaction('rw', [self.ADisDB.ADisMissions, self.ADisDB.ADisAvailabelMissions], async () => {
|
||||||
|
self.ADSettings().then((setting) => {
|
||||||
|
return self.ADisDB.ADisMissions.toCollection()
|
||||||
|
}).then((Missions) => {
|
||||||
|
if (typeof Missions !== "undefined") {
|
||||||
|
|
||||||
|
return Missions.count((count) => {
|
||||||
|
if (count > 0) {
|
||||||
|
return Missions.each((MyMission) => {
|
||||||
|
var MissionElement = $("#mission_" + MyMission.missionID);
|
||||||
|
if (MissionElement.length == 0 || $('#mission_panel_' + MyMission.missionID).hasClass('mission_panel_green')) {
|
||||||
|
// remove
|
||||||
|
console.log("Remove :", MyMission)
|
||||||
|
self.RemoveMissionsFromQueue(MyMission.missionID)
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
const MyOwnObserver = new MutationObserver((mutations) => {
|
const MyOwnObserver = new MutationObserver((mutations) => {
|
||||||
mutations.forEach((mutation) => {
|
mutations.forEach((mutation) => {
|
||||||
// console.log(mutation.target.id);
|
// console.log(mutation.target.id);
|
||||||
@@ -1017,7 +1039,7 @@ class AutomaticDispose {
|
|||||||
const self = this;
|
const self = this;
|
||||||
return self.ADisDB.ADisMissions.update(MissionID, {
|
return self.ADisDB.ADisMissions.update(MissionID, {
|
||||||
last_check: Math.floor(new Date().getTime() / 1000),
|
last_check: Math.floor(new Date().getTime() / 1000),
|
||||||
next_check: Math.floor(new Date().getTime() / 1000) + 120
|
next_check: Math.floor(new Date().getTime() / 1000) + 60
|
||||||
}).catch((err) => {
|
}).catch((err) => {
|
||||||
console.error(err)
|
console.error(err)
|
||||||
})
|
})
|
||||||
@@ -1049,6 +1071,21 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
return self.ADisDB.transaction('rw', [self.ADisDB.ADisMissions, self.ADisDB.ADisAvailabelMissions], () => {
|
return self.ADisDB.transaction('rw', [self.ADisDB.ADisMissions, self.ADisDB.ADisAvailabelMissions], () => {
|
||||||
self.ADSettings().then((setting) => {
|
self.ADSettings().then((setting) => {
|
||||||
|
if (setting[runnerSettings] == 'true') {
|
||||||
|
let where = {
|
||||||
|
runner: Runner,
|
||||||
|
available: 'true',
|
||||||
|
done: 'false'
|
||||||
|
}
|
||||||
|
var coll = self.ADisDB.ADisMissions.where(where)
|
||||||
|
if (self.MyRunner != "kt") {
|
||||||
|
coll = coll.and(function (item) {
|
||||||
|
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
||||||
|
});
|
||||||
|
}
|
||||||
|
return coll.toArray()
|
||||||
|
}
|
||||||
|
/*
|
||||||
if (setting[runnerSettings] == 'true') {
|
if (setting[runnerSettings] == 'true') {
|
||||||
return self.ADisDB.ADisMissions.where({
|
return self.ADisDB.ADisMissions.where({
|
||||||
runner: Runner,
|
runner: Runner,
|
||||||
@@ -1056,14 +1093,18 @@ class AutomaticDispose {
|
|||||||
done: 'false'
|
done: 'false'
|
||||||
}).and(function (item) {
|
}).and(function (item) {
|
||||||
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
||||||
}).limit(1)
|
}).toArray()
|
||||||
|
}*/
|
||||||
|
}).then((Wunsche) => {
|
||||||
|
if (typeof Wunsche === "undefined") {
|
||||||
|
return setTimeout(self.OpenNextMission.bind(self), 1000, Runner);
|
||||||
}
|
}
|
||||||
}).then((Wunsch) => {
|
Wunsche.sort((a, b) => {
|
||||||
// console.table(Wunsch);
|
return a.next_check - b.next_check;
|
||||||
if (Wunsch !== undefined) {
|
});
|
||||||
return Wunsch.count(function (count) {
|
// console.table(Wunsche);
|
||||||
if (count > 0) {
|
if (Wunsche.length > 0) {
|
||||||
return Wunsch.each((myWunsch) => {
|
let myWunsch = Wunsche[0];
|
||||||
// console.log("MYWUNSCH:")
|
// console.log("MYWUNSCH:")
|
||||||
// console.table(myWunsch);
|
// console.table(myWunsch);
|
||||||
let MissionID = myWunsch.missionID;
|
let MissionID = myWunsch.missionID;
|
||||||
@@ -1080,13 +1121,8 @@ class AutomaticDispose {
|
|||||||
// only while
|
// only while
|
||||||
// setTimeout(self.OpenNextMission.bind(self), 5000, Runner);
|
// setTimeout(self.OpenNextMission.bind(self), 5000, Runner);
|
||||||
}
|
}
|
||||||
});
|
|
||||||
} else {
|
|
||||||
return setTimeout(self.OpenNextMission.bind(self), 5000, Runner);
|
|
||||||
}
|
}
|
||||||
});
|
return setTimeout(self.OpenNextMission.bind(self), 1000, Runner);
|
||||||
}
|
|
||||||
return setTimeout(self.OpenNextMission.bind(self), 5000, Runner);
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -1105,7 +1141,7 @@ class AutomaticDispose {
|
|||||||
const runnerID = self.ADisSettings.runner_iframesName.indexOf(window.name);
|
const runnerID = self.ADisSettings.runner_iframesName.indexOf(window.name);
|
||||||
self.MyRunner = self.ADisSettings.runner[runnerID];
|
self.MyRunner = self.ADisSettings.runner[runnerID];
|
||||||
self.MyRunnerSettings = self.ADisSettings.runner_settings[runnerID];
|
self.MyRunnerSettings = self.ADisSettings.runner_settings[runnerID];
|
||||||
setTimeout(function () {
|
|
||||||
self.MissionID = document.location.pathname.substr(document.location.pathname.lastIndexOf("/") + 1);
|
self.MissionID = document.location.pathname.substr(document.location.pathname.lastIndexOf("/") + 1);
|
||||||
var help_el = $('a#mission_help');
|
var help_el = $('a#mission_help');
|
||||||
if (help_el.length > 0) {
|
if (help_el.length > 0) {
|
||||||
@@ -1116,21 +1152,26 @@ class AutomaticDispose {
|
|||||||
} else {
|
} else {
|
||||||
self.MissionType = null;
|
self.MissionType = null;
|
||||||
}
|
}
|
||||||
console.log("MissionID", self.MissionID);
|
// console.log("MissionID", self.MissionID);
|
||||||
console.log("MissionType", self.MissionType);
|
// console.log("MissionType", self.MissionType);
|
||||||
console.log("Window", window.name);
|
// console.log("Window", window.name);
|
||||||
console.log("self.MyRunner", self.MyRunner);
|
// console.log("self.MyRunner", self.MyRunner);
|
||||||
console.log("self.MyRunnerSettings", self.MyRunnerSettings);
|
// console.log("self.MyRunnerSettings", self.MyRunnerSettings);
|
||||||
|
if (self.includesString($('#iframe-inside-container > div.missionNotFound > div.missionNotFoundText').text(), 'Der Einsatz wurde erfolgreich abgeschlossen.')) {
|
||||||
|
console.log("DONE: " + self.MissionID);
|
||||||
|
return self.RemoveMissionsFromQueue(self.MissionID).then(() => {
|
||||||
|
return tellParent(`console.log('handler:1000:done:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');`); // delete Mission here as completed
|
||||||
|
})
|
||||||
|
} else {
|
||||||
return self.ADisDB.transaction('rw', [self.ADisDB.ADisMissions], () => {
|
return self.ADisDB.transaction('rw', [self.ADisDB.ADisMissions], () => {
|
||||||
self.ADSettings().then((setting) => {
|
self.ADSettings().then((setting) => {
|
||||||
if (setting[self.MyRunnerSettings] === 'true') {
|
if (setting[self.MyRunnerSettings] === 'true') {
|
||||||
|
|
||||||
let where = {
|
let where = {
|
||||||
missionID: self.MissionID,
|
missionID: self.MissionID,
|
||||||
runner: self.MyRunner,
|
runner: self.MyRunner,
|
||||||
done: 'false'
|
done: 'false'
|
||||||
}
|
}
|
||||||
console.log(where);
|
// console.log(where);
|
||||||
return self.ADisDB.ADisMissions.where(where).and(function (item) {
|
return self.ADisDB.ADisMissions.where(where).and(function (item) {
|
||||||
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
||||||
}).limit(1)
|
}).limit(1)
|
||||||
@@ -1155,29 +1196,26 @@ class AutomaticDispose {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
}, 1500);
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
MainHandler() {
|
MainHandler() {
|
||||||
const self = this;
|
const self = this;
|
||||||
if (self.includesString($('#iframe-inside-container > div.missionNotFound > div.missionNotFoundText').text(), 'Der Einsatz wurde erfolgreich abgeschlossen.')) {
|
if (self.includesString($('#iframe-inside-container > div.missionNotFound > div.missionNotFoundText').text(), 'Der Einsatz wurde erfolgreich abgeschlossen.')) {
|
||||||
console.log("DONE!");
|
|
||||||
console.log("DONE: " + self.MissionID);
|
console.log("DONE: " + self.MissionID);
|
||||||
return self.RemoveMissionsFromQueue(self.MissionID).then(() => {
|
return self.RemoveMissionsFromQueue(self.MissionID).then(() => {
|
||||||
return tellParent(`console.log('handler:1000:done:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');`); // delete Mission here as completed
|
return tellParent(`console.log('handler:1000:done:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');`); // delete Mission here as completed
|
||||||
})
|
})
|
||||||
}
|
} else if (self.includesString($('#iframe-inside-container > div.alert.fade.in.alert-success').text(), "wurde erfolgreich informiert") /*|| $('#vehicle_show_table_all input[type="checkbox"]:checked').size() > 0*/ ) {
|
||||||
if (self.includesString($('#iframe-inside-container > div.alert.fade.in.alert-success').text(), "wurde erfolgreich informiert") /*|| $('#vehicle_show_table_all input[type="checkbox"]:checked').size() > 0*/ ) {
|
|
||||||
console.log("SEND");
|
|
||||||
console.log("SEND: " + self.MissionID);
|
console.log("SEND: " + self.MissionID);
|
||||||
return self.UpdateMissionsToDone(self.MissionID).then(() => {
|
return self.UpdateMissionsToDone(self.MissionID).then(() => {
|
||||||
return tellParent(`console.log('handler:2000:update:${window.name}:${self.MissionID}');`); // update Mission here as updated or full
|
return tellParent(`console.log('handler:2000:update:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');`); // update Mission here as updated or full
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
setTimeout(function () {
|
setTimeout(function () {
|
||||||
if (['adis-ownmissions', 'adis-plannedeventss', 'adis-krankentransporte'].indexOf(window.name) != -1) {
|
if (['adis-ownmissions', 'adis-plannedeventss', 'adis-krankentransporte'].indexOf(window.name) != -1) {
|
||||||
console.log("WILL SEND?")
|
|
||||||
self.CheckMissionAutomatic();
|
self.CheckMissionAutomatic();
|
||||||
} else if (['adis-verbandmission', 'adis-verbandmission-event'].indexOf(window.name) != -1) {
|
} else if (['adis-verbandmission', 'adis-verbandmission-event'].indexOf(window.name) != -1) {
|
||||||
self.WorkVerbandMission();
|
self.WorkVerbandMission();
|
||||||
@@ -1192,12 +1230,15 @@ class AutomaticDispose {
|
|||||||
// -
|
// -
|
||||||
// - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
|
// - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
|
||||||
|
|
||||||
WorkVerbandMission() {
|
WorkVerbandMission(myself) {
|
||||||
|
if (typeof myself === 'undefined') {
|
||||||
|
myself = false
|
||||||
|
}
|
||||||
const self = this;
|
const self = this;
|
||||||
self.ADSettings().then((setting) => {
|
return self.ADSettings().then((setting) => {
|
||||||
var title = document.getElementById('missionH1');
|
var title = document.getElementById('missionH1');
|
||||||
var isVerband = title.innerText.toLowerCase().includes("[verband]");
|
var isVerband = title.innerText.toLowerCase().includes("[verband]");
|
||||||
if (setting['Alliance-Automatic'] == 'true' && isVerband) {
|
if ((setting['Alliance-Automatic'] == 'true' && isVerband) || myself) {
|
||||||
if ([52, 55, 129, 203].indexOf(self.MissionType) !== -1 && $('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]').size() > 0) {
|
if ([52, 55, 129, 203].indexOf(self.MissionType) !== -1 && $('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]').size() > 0) {
|
||||||
$('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]')[0].click();
|
$('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]')[0].click();
|
||||||
} else if ([53, 130, 202].indexOf(self.MissionType) !== -1) {
|
} else if ([53, 130, 202].indexOf(self.MissionType) !== -1) {
|
||||||
@@ -1236,7 +1277,7 @@ class AutomaticDispose {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// Todo add alternative cars, please no LF because of Mülltonne....
|
// Todo add alternative cars, please no LF because of Mülltonne....
|
||||||
if ($('#vehicle_show_table_all input[type="checkbox"]:checked').size() > 0) {
|
if ($('#vehicle_show_table_all input[type="checkbox"]:checked').size() > 0 && myself == false) {
|
||||||
$('#mission_alarm_btn').click();
|
$('#mission_alarm_btn').click();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -1279,7 +1320,7 @@ class AutomaticDispose {
|
|||||||
if (self.MyRunner == 'os') {
|
if (self.MyRunner == 'os') {
|
||||||
self.OweSecure = true;
|
self.OweSecure = true;
|
||||||
}
|
}
|
||||||
self.GetMissionConfiguration(self.MyRunner == 'kt' ? 147 : Mission.type);
|
self.GetMissionConfiguration(Mission.type);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -1295,7 +1336,7 @@ class AutomaticDispose {
|
|||||||
}).then((availableMission) => {
|
}).then((availableMission) => {
|
||||||
if (availableMission != undefined && availableMission.jsondata) {
|
if (availableMission != undefined && availableMission.jsondata) {
|
||||||
self.MissionConfig = availableMission.jsondata;
|
self.MissionConfig = availableMission.jsondata;
|
||||||
console.log('MissionConfig: ', MissionType.toString(), JSON.stringify(self.MissionConfig, null, 2))
|
// console.log('MissionConfig: ', MissionType.toString(), JSON.stringify(self.MissionConfig, null, 2))
|
||||||
self.StartAlarmProcess();
|
self.StartAlarmProcess();
|
||||||
} else {
|
} else {
|
||||||
var updateData = {
|
var updateData = {
|
||||||
@@ -1312,7 +1353,8 @@ class AutomaticDispose {
|
|||||||
|
|
||||||
StartAlarmProcess() {
|
StartAlarmProcess() {
|
||||||
const self = this;
|
const self = this;
|
||||||
setTimeout(function () {
|
|
||||||
|
const alarming = function alarming(self) {
|
||||||
Promise.resolve().then(async () => {
|
Promise.resolve().then(async () => {
|
||||||
return await self.PrepareVehicleNeedList();
|
return await self.PrepareVehicleNeedList();
|
||||||
}).then(async () => {
|
}).then(async () => {
|
||||||
@@ -1337,24 +1379,82 @@ class AutomaticDispose {
|
|||||||
}).then(() => {
|
}).then(() => {
|
||||||
|
|
||||||
if (self.OweSecure) {
|
if (self.OweSecure) {
|
||||||
if ($('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]:not(:checked)').size() > 0) {
|
if ($('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]:not(:checked)').length > 0) {
|
||||||
$('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]:not(:checked)')[0].click();
|
$('#vehicle_show_table_all tr[vehicle_type="FuStW"] input[type="checkbox"]:not(:checked)')[0].click();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log("Clicked Vehicles: ", $('#vehicle_show_table_all input[type="checkbox"]:checked').size(), $('#vehicle_show_table_all input[type="checkbox"]:checked'));
|
// TODO check cars driving or already there
|
||||||
console.log("WILL KLICK SEND")
|
if (self.MissionConfig.share) {
|
||||||
setTimeout(() => {
|
// console.log('self.MissionConfig.share',self.MissionConfig.share)
|
||||||
|
const elems = $('#vehicle_show_table_all tr input[type="checkbox"]:checked')
|
||||||
|
// console.log('elems', elems)
|
||||||
|
for (let i = 0; i < elems.length; i++) {
|
||||||
|
if (i === 0) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
$(elems[i]).click();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
self.UpdateMissionsToDone(self.MissionID).then(() => {
|
console.log("Clicked Vehicles:" + self.MissionID + ":" + self.MissionConfig.type + " ", $('#vehicle_show_table_all input[type="checkbox"]:checked').length, $('#vehicle_show_table_all input[type="checkbox"]:checked'));
|
||||||
tellParent(`setTimeout(function(){console.log('ok:${window.name}:${self.MissionID}');},500);`);
|
console.table(self.MissionData)
|
||||||
|
|
||||||
|
self.UpdateMissionsToDone(self.MissionID).then(async () => {
|
||||||
|
//tellParent(`setTimeout(function(){console.log('ok:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');},2500);`);
|
||||||
|
//if (window.$("a.btn.btn-success.btn-sm.alert_notify_alliance").length > 0 && self.MissionConfig.share) {
|
||||||
|
// window.$('input[type=checkbox]').prop('checked', false);
|
||||||
|
// await self.WorkVerbandMission(true);
|
||||||
|
// window.$('#allianceShareText').val('Kein RD, die Patiernten gehören mir! Anonsten kann nach 2h geschlossen werden. Danke für die Aufmerksamkeit!')
|
||||||
|
// window.$("a.btn.btn-success.btn-sm.alert_notify_alliance").click();
|
||||||
|
//} else {
|
||||||
|
if ($('#vehicle_show_table_all input[type="checkbox"]:checked').length) {
|
||||||
|
console.log('send now')
|
||||||
|
if (window.$("a[title='Alarmieren, im Verband freigeben und nächsten Einsatz aufrufen']").length > 0 && self.MissionConfig.share) {
|
||||||
|
window.$('input[type=checkbox]').prop('checked', false);
|
||||||
|
await self.WorkVerbandMission(true);
|
||||||
|
window.$("a[title='Alarmieren, im Verband freigeben und nächsten Einsatz aufrufen']")[0].click();
|
||||||
|
} else {
|
||||||
window.$('#mission_alarm_btn').click();
|
window.$('#mission_alarm_btn').click();
|
||||||
|
}
|
||||||
|
tellParent(`setTimeout(function(){console.log('ok:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');},500);`);
|
||||||
|
} else {
|
||||||
|
tellParent(`setTimeout(function(){console.log('ok:${window.name}:${self.MissionID}');window.AutomaticDisposeCall.FreeIframe('${self.MyRunner}');},500);`);
|
||||||
|
}
|
||||||
|
//}
|
||||||
});
|
});
|
||||||
}, 250);
|
|
||||||
|
|
||||||
})
|
})
|
||||||
}, 500);
|
|
||||||
}
|
}
|
||||||
|
setTimeout(function () {
|
||||||
|
var $div = $("#mission-form > div:nth-child(7) > a");
|
||||||
|
var isShow = $div.is(':hidden');
|
||||||
|
//console.log($div, isShow);
|
||||||
|
if ($div.length && isShow) {
|
||||||
|
var observer = new MutationObserver(function (mutations) {
|
||||||
|
mutations.forEach(function (mutation) {
|
||||||
|
if (mutation.attributeName === "style") {
|
||||||
|
setTimeout(function () {
|
||||||
|
alarming(self)
|
||||||
|
}, 750);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
observer.observe($div[0], {
|
||||||
|
attributes: true
|
||||||
|
});
|
||||||
|
|
||||||
|
$div.click();
|
||||||
|
} else {
|
||||||
|
setTimeout(function () {
|
||||||
|
alarming(self)
|
||||||
|
}, 250);
|
||||||
|
}
|
||||||
|
}, 150);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
// - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
|
// - -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
|
||||||
// -
|
// -
|
||||||
@@ -1408,8 +1508,7 @@ class AutomaticDispose {
|
|||||||
// Wir benötigen einen RTW oder KTW Typ B.
|
// Wir benötigen einen RTW oder KTW Typ B.
|
||||||
if ($(elem).find(".alert-danger").length > 0 && $(elem).find(".alert-danger").text().indexOf("Wir benötigen einen RTW oder KTW Typ B") != -1) {
|
if ($(elem).find(".alert-danger").length > 0 && $(elem).find(".alert-danger").text().indexOf("Wir benötigen einen RTW oder KTW Typ B") != -1) {
|
||||||
PatientNeedSEGKTWB = true;
|
PatientNeedSEGKTWB = true;
|
||||||
}
|
} else
|
||||||
|
|
||||||
// Wir benötigen einen RTW.
|
// Wir benötigen einen RTW.
|
||||||
if ($(elem).find(".alert-danger").length > 0 && $(elem).find(".alert-danger").text().indexOf("Wir benötigen ein RTW") != -1) {
|
if ($(elem).find(".alert-danger").length > 0 && $(elem).find(".alert-danger").text().indexOf("Wir benötigen ein RTW") != -1) {
|
||||||
PatientNeedRTW = true;
|
PatientNeedRTW = true;
|
||||||
@@ -1497,37 +1596,49 @@ class AutomaticDispose {
|
|||||||
self._ADisVehiclesNeed["56"] = 1;
|
self._ADisVehiclesNeed["56"] = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
//$.each(Patients, function (Key, Patient) {
|
if (Object.keys(self.Patients).length == 0) {
|
||||||
|
if (self.MissionConfig.emergency_medical_service.use_RTW == true) {
|
||||||
|
self._ADisVehiclesNeed["28"]++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (self.MissionConfig.emergency_medical_service.use_NEF == true) {
|
||||||
|
self._ADisVehiclesNeed["29"]++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (self.MissionConfig.emergency_medical_service.use_RTH == true) {
|
||||||
|
self._ADisVehiclesNeed["31"]++;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
for (var Key in self.Patients) {
|
for (var Key in self.Patients) {
|
||||||
var Patient = self.Patients[Key];
|
var Patient = self.Patients[Key];
|
||||||
if (self.MissionConfig.emergency_medical_service.use_KTW == true) {
|
if (self.MissionConfig.emergency_medical_service.use_KTW == true) {
|
||||||
if (!Patient.need_RTW && !Patient.need_NEF && !Patient.need_RTH)
|
if (!Patient.need_RTW && !Patient.need_NEF && !Patient.need_RTH) {
|
||||||
self._ADisVehiclesNeed["38"]++;
|
self._ADisVehiclesNeed["38"]++;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (Patient.need_LNA && self._ADisVehiclesNeed["55"] < 1)
|
if (Patient.need_LNA && self._ADisVehiclesNeed["55"] < 1) {
|
||||||
self._ADisVehiclesNeed["55"]++;
|
self._ADisVehiclesNeed["55"]++;
|
||||||
|
}
|
||||||
|
|
||||||
if (Patient.need_OrgL && self._ADisVehiclesNeed["56"] < 1)
|
if (Patient.need_OrgL && self._ADisVehiclesNeed["56"] < 1) {
|
||||||
self._ADisVehiclesNeed["56"]++;
|
self._ADisVehiclesNeed["56"]++;
|
||||||
|
}
|
||||||
if (Patient.need_Tragehilfe == true)
|
if (Patient.need_Tragehilfe == true) {
|
||||||
self._ADisVehiclesNeed["0"]++;
|
self._ADisVehiclesNeed["0"]++;
|
||||||
|
}
|
||||||
if (Patient.need_Tragehilfe == true)
|
if (self.MissionConfig.emergency_medical_service.use_RTW == true || Patient.need_RTW == true) {
|
||||||
self._ADisVehiclesNeed["0"]++;
|
|
||||||
|
|
||||||
if (self.MissionConfig.emergency_medical_service.use_RTW == true || Patient.need_RTW == true)
|
|
||||||
self._ADisVehiclesNeed["28"]++;
|
self._ADisVehiclesNeed["28"]++;
|
||||||
|
}
|
||||||
if ((self.MissionConfig.emergency_medical_service.use_NEF == true && Patient.need_NEF == true) || Patient.need_NEF == true)
|
if (self.MissionConfig.emergency_medical_service.use_NEF == true || Patient.need_NEF == true) {
|
||||||
self._ADisVehiclesNeed["29"]++;
|
self._ADisVehiclesNeed["29"]++;
|
||||||
|
}
|
||||||
if ((self.MissionConfig.emergency_medical_service.use_RTH == true && Patient.need_RTH == true) || Patient.need_RTH == true)
|
if (self.MissionConfig.emergency_medical_service.use_RTH == true || Patient.need_RTH == true) {
|
||||||
self._ADisVehiclesNeed["31"]++;
|
self._ADisVehiclesNeed["31"]++;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
// TODO: need to be refactored to make sure first KTW Typ B before RTW.
|
// TODO: need to be refactored to make sure first KTW Typ B before RTW.
|
||||||
if (self.MissionConfig.emergency_medical_service.use_SEG_ELW1_Only == "true") {
|
if (self.MissionConfig.emergency_medical_service.use_SEG_ELW1_Only == "true") {
|
||||||
|
|||||||
+19
@@ -0,0 +1,19 @@
|
|||||||
|
(() => {
|
||||||
|
let msis = (async () => {
|
||||||
|
return await AutomaticDisposeCall.ADisDB.ADisMissions.where({
|
||||||
|
runner: 'om',
|
||||||
|
available: 'true',
|
||||||
|
done: 'false'
|
||||||
|
}).and(function (item) {
|
||||||
|
return item.next_check <= Math.floor(new Date().getTime() / 1000)
|
||||||
|
}).toArray()
|
||||||
|
})();
|
||||||
|
msis.then((result) => {
|
||||||
|
result.sort((a, b) => {
|
||||||
|
return a.next_check > b.next_check;
|
||||||
|
});
|
||||||
|
return result;
|
||||||
|
}).then((sortedResult) => {
|
||||||
|
console.table(sortedResult);
|
||||||
|
});
|
||||||
|
})();
|
||||||
@@ -0,0 +1,61 @@
|
|||||||
|
// ==UserScript==
|
||||||
|
// @name Mission Watcher
|
||||||
|
// @version 1.0.0
|
||||||
|
// @run-at document-end
|
||||||
|
// @require https://cdnjs.cloudflare.com/ajax/libs/dexie/2.0.4/dexie.min.js
|
||||||
|
// ==/UserScript==
|
||||||
|
|
||||||
|
|
||||||
|
class WatchMissions {
|
||||||
|
|
||||||
|
constructor(){
|
||||||
|
let self = this;
|
||||||
|
self.DB = new Dexie('LSS_AutomaticDispo');
|
||||||
|
|
||||||
|
|
||||||
|
self.DB.version(1).stores({
|
||||||
|
/**
|
||||||
|
* Missions to Watch
|
||||||
|
* - missionID - Mission ID that should be watched.
|
||||||
|
* - limit - If the Mission turns green more than 6 times, no more requests will be sent.
|
||||||
|
*/
|
||||||
|
Missions: "++missionID"
|
||||||
|
});
|
||||||
|
self.DB.open().catch((err) => {
|
||||||
|
console.error(err.stack || err);
|
||||||
|
});
|
||||||
|
self.DB.on("ready", async () => {
|
||||||
|
// index page
|
||||||
|
if (window.location.pathname === "/" || window.location.pathname === "/#" || window.location.pathname === "/#_=_") {
|
||||||
|
self.RegisterIndexPage();
|
||||||
|
}
|
||||||
|
// mission page
|
||||||
|
else if (window.location.pathname.indexOf("/missions/") !== -1 && window.name == 'watchMission') {
|
||||||
|
self.RegisterMissionPage();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
get RandomTime() {
|
||||||
|
const max = 6;
|
||||||
|
const min = 1;
|
||||||
|
return Math.floor((Math.random()*(max-min+1)+min)*1000);
|
||||||
|
}
|
||||||
|
|
||||||
|
RegisterIndexPage() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
RegisterMissionPage() {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
(() => {
|
||||||
|
'use strict';
|
||||||
|
|
||||||
|
new WatchMissions();
|
||||||
|
|
||||||
|
})()
|
||||||
Reference in New Issue
Block a user