Filestore Fertiggestellt
Cpeprovisioning Performance Update
This commit is contained in:
@@ -25,6 +25,9 @@ if (!$me->permissions->isAdmin) {
|
||||
}
|
||||
}
|
||||
|
||||
if (empty($mode) && $filestorehistory) {
|
||||
$mode = "edit-history";
|
||||
}
|
||||
?>
|
||||
|
||||
<div class="row">
|
||||
@@ -34,7 +37,7 @@ if (!$me->permissions->isAdmin) {
|
||||
<div class="card-body">
|
||||
<h4 class="header-title mb-2"><?= ($file->id) ? "Datei bearbeiten" : "Neue Datei" ?></h4>
|
||||
<form class="form-horizontal" method="post" enctype="multipart/form-data"
|
||||
action="<?= self::getUrl("Filestore", "save") ?>">
|
||||
action="<?= self::getUrl("Filestore", "save", ["mode" => $mode]) ?>">
|
||||
<div class="card">
|
||||
<div class="card-body">
|
||||
|
||||
@@ -44,10 +47,11 @@ if (!$me->permissions->isAdmin) {
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="name">Name *</label>
|
||||
<div class="col-lg-10">
|
||||
<?php if (empty($mode)) : ?>
|
||||
<input value="<?= $file->name ?>" class="form-control" name="name"
|
||||
<?php if (empty($mode) && !$filestorehistory) : ?>
|
||||
<input value="<?= $file->name ?>" class="form-control"
|
||||
name="name"
|
||||
id="name">
|
||||
<?php elseif ($mode == "add-version") : ?>
|
||||
<?php else : ?>
|
||||
<span><?= $file->name ?></span>
|
||||
<?php endif; ?>
|
||||
</div>
|
||||
@@ -55,9 +59,10 @@ if (!$me->permissions->isAdmin) {
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="network_id">Netzgebiet *</label>
|
||||
<div class="col-lg-10">
|
||||
<?php if (empty($mode)) : ?>
|
||||
<select class="select2 form-control " name="network_id" id="network_id">
|
||||
<option> </option>
|
||||
<?php if (empty($mode) && !$filestorehistory) : ?>
|
||||
<select class="select2 form-control "
|
||||
name="network_id" id="network_id">
|
||||
<option value=""> </option>
|
||||
<?php foreach ($networks as $key => $network):
|
||||
if (!$me->permissions->isAdmin) {
|
||||
if (!array_key_exists($network->id, $allowedNetworks)) {
|
||||
@@ -68,7 +73,7 @@ if (!$me->permissions->isAdmin) {
|
||||
<option value="<?= $network->id ?>" <?= ($file->network_id == $network->id) ? "selected='selected'" : "" ?>><?= ($network->name) ?></option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
<?php elseif ($mode == "add-version") :
|
||||
<?php else :
|
||||
foreach ($networks as $key => $network):
|
||||
if (($file->network_id == $network->id)) :
|
||||
$networkName = $network->name;
|
||||
@@ -86,12 +91,15 @@ if (!$me->permissions->isAdmin) {
|
||||
id="description"><?= htmlentities($file->description) ?></textarea>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="filestore">Datei</label>
|
||||
<div class="col-lg-10">
|
||||
<input type="file" class="form-control-file" id="filestore" name="filestore">
|
||||
<?php if (empty($mode) || $mode=="add-version") : ?>
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2 col-form-label" for="filestore">Datei</label>
|
||||
<div class="col-lg-10">
|
||||
<input type="file" class="form-control-file" id="filestore"
|
||||
name="filestore">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
<div class="form-group row">
|
||||
<label class="col-lg-2"></label>
|
||||
<div class="col-lg-10">
|
||||
|
||||
Reference in New Issue
Block a user