rechnungsanhang handlign

charts bugfix only empty database
This commit is contained in:
Markus
2026-06-08 15:58:11 +02:00
parent aedd66202a
commit 6457f38f01
7 changed files with 117 additions and 96 deletions

View File

@@ -1,6 +1,7 @@
<?= $this->extend('layouts/smarthome'); ?>
<?= $this->extend('layout'); ?>
<?= $this->section('menu'); ?>
<?= $this->include('menu/dashboard_menu') ?>
<?= $this->include('sidebar') ?>
<?= $this->endSection(); ?>
<?= $this->section('content'); ?>
<div class="container">

View File

@@ -14,7 +14,12 @@
<div class="col-md-8 col-12">
<div class="card">
<div class="card-header pb-0">
<h4 class="card-title"><?= ($transfer?'Neuer Transfer':($isScheduled?'Neue Terminbuchung':'Neue Rechnung'))?></h4>
<?php if ($id) : ?>
<h4 class="card-title"><?= ($transfer?'Transfer bearbeiten':($isScheduled?'Terminbuchung bearbeiten':'Rechnung bearbeiten'))?></h4>
<?php else: ?>
<h4 class="card-title"><?= ($transfer?'Neuer Transfer':($isScheduled?'Neue Terminbuchung':'Neue Rechnung'))?></h4>
<?php endif; ?>
<?php if (! empty($validation)) : ?>
<div class='alert alert-danger mt-2'>
<div class="errors" role="alert">
@@ -42,11 +47,11 @@
</div>
</div>
<div class="col-12 <?= ($transfer?' d-none':($isScheduled?' d-none':'')) ?>">
<label for="billfile">Rechnung</label>
<?php if (!isset($billfile)): ?>
<input type="file" id="billfile" name="billfile" class="form-control" capture="environment" accept="image/*, application/pdf">
<?php else: ?>
<input type="text" disabled="disabled" name="temp" id="billfile1" class="form-control" value="<?= set_value('billfile1', $billfile??'') ?>">
<label for="billfile">Rechnung:</label>
<input type="file" id="billfile" name="billfile" class="form-control <?= (!isset($billfile))?'':'d-none' ?>" capture="environment" accept="image/*, application/pdf">
<?php if (isset($billfile)): ?>
<a href="/viewBill/<?= $billfile ?>" id="billfileRef"><?= $billfile ?></a>
<a class="" onclick="removeBillFile(this);"><i class="fa fa-trash"></i></a>
<?php endif; ?>
</div>
<div class="col-12 <?= ($transfer?' d-none':'d-none') ?>">
@@ -124,8 +129,11 @@
<a class="btn btn-info multi" onclick="addLine();" role="button">+ Zeile</a>
<input type="checkbox" id="validate" name="validate" value="1" class='btn-check' autocomplete="off" <?= set_checkbox('validate', '1', (($validate??"f")=="t")?true:false) ?>>
<label class="btn btn-outline-danger" for="validate">Entwurf</label>
<?php if ($id) : ?>
<a class="btn btn-danger" data-bs-toggle="modal" data-bs-id="<?= $id ?>" data-bs-target="#mymodal"><i class="fa fa-trash"></i></a>
<?php endif; ?>
<button type="submit" class="btn btn-primary">Submit</button>
<a class="btn btn-secondary" onclick="history.back();" role="button">Zurück</a>
<a class="btn btn-secondary" onclick="history.back();" role="button"><i class="fa-solid fa-rotate-left"></i></a>
</div>
</div>
</div>

View File

@@ -0,0 +1 @@
<img src="<?=$filename?>" alt="Rechnung <?=$filename?>">