mirror of
http://git.frickel.earth/Tysox/BOS-Pinneberg.git
synced 2025-05-20 21:04:31 +02:00
[+] fixed Bugs ins FrontEnd
This commit is contained in:
parent
b4569550f0
commit
a1ed1d6c80
@ -107,7 +107,7 @@ $header->showHeader("Feuerwehr"); ?>
|
||||
$.ajax({
|
||||
url: "../scripts/vehicle.php",
|
||||
type: "POST",
|
||||
data: "org=ff&ort" + ort + "&name=" + name + "&number=" + number + "&type=" + type,
|
||||
data: "org=ff&ort=" + ort + "&name=" + name + "&number=" + number + "&type=" + type,
|
||||
success: function (resp) {
|
||||
$("#feedback").html(resp);
|
||||
}
|
||||
|
@ -36,26 +36,29 @@ if ($_POST) {
|
||||
if (isset($_POST['org'])) {
|
||||
|
||||
if(strcmp($_POST['org'], "ff")) {
|
||||
if (isset($_POST['ort']) && isset($_POST['name']) && isset($_POST['number']) && isset($_POST['type'])) {
|
||||
if ($_POST['ort'] AND $_POST['name'] AND $_POST['number'] AND $_POST['type']) {
|
||||
$insert = $pdo->prepare("INSERT INTO feuerwehr (id, OrtID, Organistationskennung, Fahrzeugkennung, Fahrzeugtyp) VALUES (?,?,?,?,?)");
|
||||
|
||||
$select = $pdo->prepare("SELECT COUNT(OrtID) FROM feuerwehr WHERE OrtID = ?");
|
||||
if ($select->execute(array($_POST ['ort']))) {
|
||||
$count = $select->fetch();
|
||||
while ($row = $select->fetch()) {
|
||||
|
||||
if ($count <= 9) {
|
||||
$count = $_POST['ort'] . "0" . $count;
|
||||
} else {
|
||||
$count = $_POST['ort'] . $count;
|
||||
if ($row <= 9) {
|
||||
$row = $_POST['ort'] . "0" . $row;
|
||||
} else {
|
||||
$row = $_POST['ort'] . $row;
|
||||
}
|
||||
}
|
||||
}
|
||||
$insert->bindParam(1, $count);
|
||||
$insert->bindParam(2, $_POST['ort']);
|
||||
$insert->bindParam(3, $_POST['name']);
|
||||
$insert->bindParam(4, $_POST['number']);
|
||||
$insert->bindParam(5, $_POST['type']);
|
||||
$insert->execute();
|
||||
echo "Eintrag vom Fahrzeug erfolgreich";
|
||||
$insert->bindParam(1, $row);
|
||||
$insert->bindParam(2, $_POST['ort']);
|
||||
$insert->bindParam(3, $_POST['name']);
|
||||
$insert->bindParam(4, $_POST['number']);
|
||||
$insert->bindParam(5, $_POST['type']);
|
||||
$insert->execute();
|
||||
echo "Eintrag vom Fahrzeug erfolgreich";
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -1,5 +1,4 @@
|
||||
<?php
|
||||
include 'admin/config/config.inc.php';
|
||||
$data = new Config();
|
||||
|
||||
|
||||
@ -43,8 +42,7 @@ if ($result->num_rows > 0) {
|
||||
}
|
||||
?>
|
||||
<section class="section--center mdl-grid mdl-grid--no-spacing mdl-shadow--2dp">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col">
|
||||
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col mdl-card--border mdl-card__supporting-text">
|
||||
<h4 style="text-align: center"><?php echo $row['Ort'] . " [" . $row['id']; ?>]</h4>
|
||||
<table style="margin-left: auto; margin-right: auto"
|
||||
class="mdl-data-table mdl-js-data-table mdl-shadow--2dp">
|
||||
@ -62,16 +60,26 @@ if ($result->num_rows > 0) {
|
||||
while ($frow = $fahrzeuge->fetch_assoc()) {
|
||||
?>
|
||||
<tr>
|
||||
<td class="mdl-data-table__cell--non-numeric"><?php echo $frow['Fahrzeugtyp'] ?></td>
|
||||
<td class="mdl-data-table__cell--non-numeric"><?php echo $frow['Fahrzeugtyp'] ?></td>
|
||||
<?php if ($frow['Fahrzeugkennung'] == 0) {
|
||||
?>
|
||||
<td class="mdl-data-table__cell--non-numeric"><?php echo $frow['Organistationskennung'] ?></td>
|
||||
<?php } else if ($frow['Fahrzeugkennung'] > 0) { ?>
|
||||
<td class="mdl-data-table__cell--non-numeric"><?php echo $frow['Organistationskennung'] . " " . $row['id'] . "-" . $frow['Fahrzeugkennung'] ?></td>
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
<?php }
|
||||
} ?>
|
||||
|
||||
|
||||
</tr>
|
||||
<?php
|
||||
}
|
||||
?>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
</div>
|
||||
</section>
|
||||
<?php }
|
||||
<?php
|
||||
|
||||
}
|
||||
|
||||
} ?>
|
@ -6,7 +6,7 @@
|
||||
* Time: 18:09
|
||||
*/
|
||||
?>
|
||||
<?php include("../config/config.php");?>
|
||||
<?php include("admin/config/config.inc.php");?>
|
||||
<!doctype html>
|
||||
<!--
|
||||
Material Design Lite
|
||||
@ -62,6 +62,7 @@
|
||||
</div>
|
||||
<div class="mdl-layout--large-screen-only mdl-layout__header-row">
|
||||
<h3>BOS Funk Pinneberg</h3>
|
||||
|
||||
</div>
|
||||
<div class="mdl-layout--large-screen-only mdl-layout__header-row">
|
||||
</div>
|
||||
@ -71,5 +72,9 @@
|
||||
<a href="#polizei" class="mdl-layout__tab">Polizei</a>
|
||||
<a href="#thw" class="mdl-layout__tab">THW</a>
|
||||
<a href="#bos" class="mdl-layout__tab">BOS Funk</a>
|
||||
<div class="mdl-layout-spacer"></div>
|
||||
<button onclick="window.location.href='admin/login.php'" class="mdl-button mdl-js-button mdl-js-ripple-effect mdl-button--icon mdl--right" id="hdrbtn">
|
||||
<i class="material-icons">exit_to_app</i>
|
||||
</button>
|
||||
</div>
|
||||
</header>
|
@ -21,8 +21,7 @@ if ($result->num_rows > 0) {
|
||||
while($row = $result->fetch_assoc()) {
|
||||
?>
|
||||
<section class="section--center mdl-grid mdl-grid--no-spacing mdl-shadow--2dp">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col">
|
||||
<div class="mdl-card__supporting-text">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col mdl-card__supporting-text">
|
||||
<h4 style="text-align: center"><?php echo $row['Ort'] ." [". $row['id'];?>]</h4>
|
||||
<table style="margin-left: auto; margin-right: auto" class="mdl-data-table mdl-js-data-table mdl-shadow--2dp">
|
||||
<thead>
|
||||
|
@ -21,8 +21,7 @@ if ($result->num_rows > 0) {
|
||||
while($row = $result->fetch_assoc()) {
|
||||
?>
|
||||
<section class="section--center mdl-grid mdl-grid--no-spacing mdl-shadow--2dp">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col">
|
||||
<div class="mdl-card__supporting-text">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col mdl-card__supporting-text">
|
||||
<h4 style="text-align: center"><?php echo $row['Ort'] ." [". $row['id'];?>]</h4>
|
||||
<table style="margin-left: auto; margin-right: auto" class="mdl-data-table mdl-js-data-table mdl-shadow--2dp">
|
||||
<thead>
|
||||
|
@ -18,8 +18,7 @@ if ($result->num_rows > 0) {
|
||||
while($row = $result->fetch_assoc()) {
|
||||
?>
|
||||
<section class="section--center mdl-grid mdl-grid--no-spacing mdl-shadow--2dp">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col">
|
||||
<div class="mdl-card__supporting-text">
|
||||
<div class="mdl-card mdl-cell mdl-cell--12-col mdl-card__supporting-text">
|
||||
<h4 style="text-align: center"><?php echo $row['Ort'] ." [". $row['id'];?></h4>
|
||||
<table style="margin-left: auto; margin-right: auto" class="mdl-data-table mdl-js-data-table mdl-shadow--2dp">
|
||||
<thead>
|
||||
|
55
index.php
55
index.php
@ -86,59 +86,14 @@ include("include/header.php");
|
||||
|
||||
</section>
|
||||
</div>
|
||||
<footer class="mdl-mega-footer">
|
||||
<div class="mdl-mega-footer--middle-section">
|
||||
<div class="mdl-mega-footer--drop-down-section">
|
||||
<input class="mdl-mega-footer--heading-checkbox" type="checkbox" checked>
|
||||
<h1 class="mdl-mega-footer--heading">Features</h1>
|
||||
<ul class="mdl-mega-footer--link-list">
|
||||
<li><a href="#">About</a></li>
|
||||
<li><a href="#">Terms</a></li>
|
||||
<li><a href="#">Partners</a></li>
|
||||
<li><a href="#">Updates</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="mdl-mega-footer--drop-down-section">
|
||||
<input class="mdl-mega-footer--heading-checkbox" type="checkbox" checked>
|
||||
<h1 class="mdl-mega-footer--heading">Details</h1>
|
||||
<ul class="mdl-mega-footer--link-list">
|
||||
<li><a href="#">Spec</a></li>
|
||||
<li><a href="#">Tools</a></li>
|
||||
<li><a href="#">Resources</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="mdl-mega-footer--drop-down-section">
|
||||
<input class="mdl-mega-footer--heading-checkbox" type="checkbox" checked>
|
||||
<h1 class="mdl-mega-footer--heading">Technology</h1>
|
||||
<ul class="mdl-mega-footer--link-list">
|
||||
<li><a href="#">How it works</a></li>
|
||||
<li><a href="#">Patterns</a></li>
|
||||
<li><a href="#">Usage</a></li>
|
||||
<li><a href="#">Products</a></li>
|
||||
<li><a href="#">Contracts</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
<div class="mdl-mega-footer--drop-down-section">
|
||||
<input class="mdl-mega-footer--heading-checkbox" type="checkbox" checked>
|
||||
<h1 class="mdl-mega-footer--heading">FAQ</h1>
|
||||
<ul class="mdl-mega-footer--link-list">
|
||||
<li><a href="#">Questions</a></li>
|
||||
<li><a href="#">Answers</a></li>
|
||||
<li><a href="#">Contact us</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mdl-mega-footer--bottom-section">
|
||||
<div class="mdl-logo">
|
||||
More Information
|
||||
</div>
|
||||
<ul class="mdl-mega-footer--link-list">
|
||||
<li><a href="https://developers.google.com/web/starter-kit/">Web Starter Kit</a></li>
|
||||
<footer class="mdl-mini-footer">
|
||||
<div class="mdl-mini-footer__left-section">
|
||||
<div class="mdl-logo">Title</div>
|
||||
<ul class="mdl-mini-footer__link-list">
|
||||
<li><a href="#">Help</a></li>
|
||||
<li><a href="#">Privacy and Terms</a></li>
|
||||
<li><a href="#">Privacy & Terms</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</footer>
|
||||
</main>
|
||||
</div>
|
||||
|
Loading…
x
Reference in New Issue
Block a user