WIP 2024-12-12 ConstructionConsent
This commit is contained in:
@@ -0,0 +1,90 @@
|
||||
<?php include(realpath(dirname(__FILE__) . "/../../$mfLayoutPackage") . "/header.php"); ?>
|
||||
<!-- start page title -->
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div class="page-title-box">
|
||||
<div class="page-title-right">
|
||||
<ol class="breadcrumb m-0">
|
||||
<li class="breadcrumb-item"><a href="<?= self::getUrl("Dashboard") ?>"><?= MFAPPNAME_SLUG ?></a></li>
|
||||
<li class="breadcrumb-item"><a href="<?= self::getUrl("ConstructionConsentProject") ?>">Zustimmungserklärungsprojekte</a></li>
|
||||
<li class="breadcrumb-item active"><?= ($Action == "add") ? "neu" : "bearbeiten" ?></li>
|
||||
</ol>
|
||||
</div>
|
||||
<h4 class="page-title">Zustimmungserklärung</h4>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end page title -->
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
|
||||
<div class="card bg-light">
|
||||
<div class="card-body">
|
||||
<h4 class="header-title mb-2">
|
||||
<?= ($Action == "add") ? "Neues " : "" ?>Zustimmungserklärungsprojekt <?= ($Action == "edit") ? "bearbeiten " : "" ?>
|
||||
</h4>
|
||||
|
||||
<form class="form-horizontal" method="post" action="<?= self::getUrl("ConstructionConsentProject", "save") ?>">
|
||||
<input type="hidden" name="id" value="<?=isset($project) ? $project->id : ""?>"/>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="name">Projektname *</label>
|
||||
<div class="col-lg-10">
|
||||
<input type="text" class="form-control" name="name" id="name" value="<?=$project->name?>" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="adb_network_id">Netzgebiete *</label>
|
||||
<div class="col-lg-10">
|
||||
<select class="form-control select2" name="adb_netzgebiet_id[]" id="adb_netzgebiet_id" multiple="multiple">
|
||||
<?php foreach(ADBNetzgebietModel::getAll() as $net): ?>
|
||||
<option value="<?=$net->id?>" <?=(is_array($project->adb_networks) && array_key_exists($net->id, $project->adb_networks)) ? "selected='selected'" : ""?> ><?=$net->name?></option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row mt-3">
|
||||
<label class="col-lg-2 col-form-label" for="note">Interne Notiz</label>
|
||||
<div class="col-lg-10">
|
||||
<textarea id="note" class="form-control" name="note" rows="5"><?=$project->note?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2"></label>
|
||||
<div class="col-lg-10">
|
||||
<button type="submit" class="btn btn-primary">Speichern</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
$(".select2").select2({
|
||||
allowClear: true,
|
||||
placeholder: "",
|
||||
closeOnSelect: false
|
||||
});
|
||||
|
||||
$('#adb_hausnummer_id').on('select2:close', function(e) {
|
||||
if(!$('#adb_hausnummer_id').val()) {
|
||||
$('#new-address-toggle').show();
|
||||
}
|
||||
|
||||
});
|
||||
</script>
|
||||
|
||||
<?php include(realpath(dirname(__FILE__) . "/../../$mfLayoutPackage") . "/footer.php"); ?>
|
||||
@@ -0,0 +1,112 @@
|
||||
<?php
|
||||
$pagination_baseurl = $this->getUrl($Mod,"Index");
|
||||
$pagination_baseurl_params = ["filter" => $filter];
|
||||
$pagination_entity_name = "Zustimmungserklärungsprojekte";
|
||||
?>
|
||||
<?php include(realpath(dirname(__FILE__)."/../../$mfLayoutPackage")."/header.php"); ?>
|
||||
|
||||
|
||||
<!-- start page title -->
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div class="page-title-box">
|
||||
<div class="page-title-right">
|
||||
<ol class="breadcrumb m-0">
|
||||
<li class="breadcrumb-item"><a href="<?=self::getUrl("Dashboard")?>"><?=MFAPPNAME_SLUG?></a></li>
|
||||
<li class="breadcrumb-item"><a href="<?=self::getUrl("ConstructionConsent")?>">Zustimmmungserklärungen</a></li>
|
||||
<li class="breadcrumb-item active">Projekte</li>
|
||||
</ol>
|
||||
</div>
|
||||
<h4 class="page-title">Zustimmmungserklärungen</h4>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- end page title -->
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body mb-3">
|
||||
<a href="<?=self::getUrl("ConstructionConsent")?>" class="btn btn-outline-secondary"><i class="fas fa-fw fa-arrow-left"></i> Zurück zu Zustimmungserklärungen</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body mb-3">
|
||||
<h4 class="header-title mb-3"><i class="fad fa-filter fa-fw"></i> Filter</h4>
|
||||
|
||||
<form method="get" action="<?=self::getUrl("ConstructionConsent")?>">
|
||||
<div class="row">
|
||||
|
||||
<div class="col-1">
|
||||
<label class="form-label" for="filter_name">Name</label>
|
||||
<input type="text" class="form-control" name="filter[name]" id="filter_name" value="<?=(is_array($filter) && array_key_exists('name', $filter)) ? $filter['name'] : ""?>" />
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class="row mt-2">
|
||||
<div class="col">
|
||||
<button type="submit" class="btn btn-primary"><i class="far fa-search fa-fw"></i> Filter anwenden</button>
|
||||
<a class="btn btn-secondary" href="<?=self::getUrl("ConstructionConsent", "", ["resetFilter" => 1])?>"><i class="far fa-xmark fa-fw"></i> Filter zurücksetzen</a>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-body mb-3">
|
||||
<div class="row">
|
||||
<div class="col-12">
|
||||
<div class="float-left">
|
||||
<h4 class="header-title">Liste aller Zustimmmungserklärungsprojekte</h4>
|
||||
</div>
|
||||
<div class="float-right">
|
||||
<a class="btn btn-primary" href="<?=self::getUrl("ConstructionConsentProject", "add")?>"><i class="fas fa-plus"></i> Neue Zustimmungserklärungsprojekt erstellen</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php include(realpath(dirname(__FILE__)."/../")."/tpl/pagination.php"); ?>
|
||||
<?php include(realpath(dirname(__FILE__)."/../")."/tpl/pagination-summary.php"); ?>
|
||||
|
||||
<table class="table table-striped table-hover">
|
||||
<tr>
|
||||
<th>Projektname</th>
|
||||
<th>Netzgebiete</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
<?php foreach($projects as $project): ?>
|
||||
<tr>
|
||||
<td><?=$project->name?></td>
|
||||
<td>
|
||||
<?php if(is_array($project->networks) && count($project->networks)): ?>
|
||||
<ul>
|
||||
<?php foreach($project->networks as $network): ?>
|
||||
<li><?=$network->adb_netzgebiet->name?></li>
|
||||
<?php endforeach; ?>
|
||||
</ul>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
<td style="text-align: left; letter-spacing: 4px; font-size: 1.1em;">
|
||||
<a href="<?=self::getUrl("ConstructionConsentProject", "edit", ["id" => $project->id])?>"><i class="far fa-edit" title="Bearbeiten"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach; ?>
|
||||
</table>
|
||||
|
||||
<?php include(realpath(dirname(__FILE__)."/../")."/tpl/pagination.php"); ?>
|
||||
<?php include(realpath(dirname(__FILE__)."/../")."/tpl/pagination-summary.php"); ?>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<?php include(realpath(dirname(__FILE__)."/../../$mfLayoutPackage")."/footer.php"); ?>
|
||||
Reference in New Issue
Block a user