use bootstrap forms

This commit is contained in:
Uwe Steinmann 2017-07-31 11:29:24 +02:00
parent 2d2dd8f1bf
commit eb734ae755
2 changed files with 50 additions and 18 deletions

View File

@ -42,20 +42,25 @@ class SeedDMS_View_RemoveUser extends SeedDMS_Bootstrap_Style {
$this->contentStart(); $this->contentStart();
$this->pageNavigation(getMLText("admin_tools"), "admin_tools"); $this->pageNavigation(getMLText("admin_tools"), "admin_tools");
$this->contentHeading(getMLText("rm_user")); $this->contentHeading(getMLText("rm_user"));
$this->contentContainerStart();
?> ?>
<form action="../op/op.UsrMgr.php" name="form1" method="post"> <div class="alert">
<?php printMLText("confirm_rm_user", array ("username" => htmlspecialchars($rmuser->getFullName())));?>
</div>
<?php
$this->contentContainerStart();
?>
<form class="form-horizontal" action="../op/op.UsrMgr.php" name="form1" method="post">
<input type="hidden" name="userid" value="<?php print $rmuser->getID();?>"> <input type="hidden" name="userid" value="<?php print $rmuser->getID();?>">
<input type="hidden" name="action" value="removeuser"> <input type="hidden" name="action" value="removeuser">
<?php echo createHiddenFieldWithKey('removeuser'); ?> <?php echo createHiddenFieldWithKey('removeuser'); ?>
<p>
<?php printMLText("confirm_rm_user", array ("username" => htmlspecialchars($rmuser->getFullName())));?>
</p>
<p> <div class="control-group">
<label class="control-label" for="assignTo">
<?php printMLText("assign_user_property_to"); ?>: <?php printMLText("assign_user_property_to"); ?>:
<select name="assignTo"> </label>
<div class="controls">
<select name="assignTo" class="chzn-select">
<?php <?php
foreach ($allusers as $currUser) { foreach ($allusers as $currUser) {
if ($currUser->isGuest() || ($currUser->getID() == $rmuser->getID()) ) if ($currUser->isGuest() || ($currUser->getID() == $rmuser->getID()) )
@ -66,9 +71,14 @@ class SeedDMS_View_RemoveUser extends SeedDMS_Bootstrap_Style {
} }
?> ?>
</select> </select>
</p> </div>
</div>
<p><button type="submit" class="btn"><i class="icon-remove"></i> <?php printMLText("rm_user");?></button></p> <div class="control-group">
<div class="controls">
<button type="submit" class="btn"><i class="icon-remove"></i> <?php printMLText("rm_user");?></button>
</div>
</div>
</form> </form>
<?php <?php

View File

@ -36,17 +36,19 @@ class SeedDMS_View_RemoveUserFromProcesses extends SeedDMS_Bootstrap_Style {
$this->globalNavigation(); $this->globalNavigation();
$this->contentStart(); $this->contentStart();
$this->pageNavigation(getMLText("admin_tools"), "admin_tools"); $this->pageNavigation(getMLText("admin_tools"), "admin_tools");
$this->contentHeading(getMLText("rm_user")); $this->contentHeading(getMLText("rm_user_from_processes"));
?>
<div class="alert">
<?php printMLText("confirm_rm_user_from_processes", array ("username" => htmlspecialchars($rmuser->getFullName())));?>
</div>
<?php
$this->contentContainerStart(); $this->contentContainerStart();
?> ?>
<form action="../op/op.UsrMgr.php" name="form1" method="post"> <form class="form-horizontal" action="../op/op.UsrMgr.php" name="form1" method="post">
<input type="hidden" name="userid" value="<?php print $rmuser->getID();?>"> <input type="hidden" name="userid" value="<?php print $rmuser->getID();?>">
<input type="hidden" name="action" value="removefromprocesses"> <input type="hidden" name="action" value="removefromprocesses">
<?php echo createHiddenFieldWithKey('removefromprocesses'); ?> <?php echo createHiddenFieldWithKey('removefromprocesses'); ?>
<p>
<?php printMLText("confirm_rm_user_from_processes", array ("username" => htmlspecialchars($rmuser->getFullName())));?>
</p>
<?php <?php
$reviewStatus = $rmuser->getReviewStatus(); $reviewStatus = $rmuser->getReviewStatus();
@ -67,19 +69,39 @@ class SeedDMS_View_RemoveUserFromProcesses extends SeedDMS_Bootstrap_Style {
$tmpa[$ai['status']] = array($ai); $tmpa[$ai['status']] = array($ai);
} }
?> ?>
<p>
<?php if(isset($tmpa["0"]) || isset($tmpr["0"])) { ?> <?php if(isset($tmpa["0"]) || isset($tmpr["0"])) { ?>
<input type="checkbox" name="status[]" value="0" checked> <?php echo getMLText('approvals_and_reviews_not_touched', array('no_approvals' => count($tmpa["0"]), 'no_reviews' => count($tmpr["0"]))); ?><br /> <div class="control-group">
<div class="controls">
<label class="checkbox">
<input type="checkbox" name="status[]" value="0" checked> <?php echo getMLText('approvals_and_reviews_not_touched', array('no_approvals' => count($tmpa["0"]), 'no_reviews' => count($tmpr["0"]))); ?>
</label>
</div>
</div>
<?php } ?> <?php } ?>
<?php if(isset($tmpa["1"]) || isset($tmpr["1"])) { ?> <?php if(isset($tmpa["1"]) || isset($tmpr["1"])) { ?>
<div class="control-group">
<div class="controls">
<label class="checkbox">
<input type="checkbox" name="status[]" value="1" checked> <?php echo getMLText('approvals_and_reviews_accepted', array('no_approvals' => count($tmpa["1"]), 'no_reviews' => count($tmpr["1"]))); ?><br /> <input type="checkbox" name="status[]" value="1" checked> <?php echo getMLText('approvals_and_reviews_accepted', array('no_approvals' => count($tmpa["1"]), 'no_reviews' => count($tmpr["1"]))); ?><br />
</label>
</div>
</div>
<?php } ?> <?php } ?>
<?php if(isset($tmpa["-1"]) || isset($tmpr["-1"])) { ?> <?php if(isset($tmpa["-1"]) || isset($tmpr["-1"])) { ?>
<div class="control-group">
<div class="controls">
<label class="checkbox">
<input type="checkbox" name="status[]" value="-1" checked> <?php echo getMLText('approvals_and_reviews_rejected', array('no_approvals' => count($tmpa["-1"]), 'no_reviews' => count($tmpr["-1"]))); ?><br /> <input type="checkbox" name="status[]" value="-1" checked> <?php echo getMLText('approvals_and_reviews_rejected', array('no_approvals' => count($tmpa["-1"]), 'no_reviews' => count($tmpr["-1"]))); ?><br />
</label>
</div>
</div>
<?php } ?> <?php } ?>
</p> <div class="control-group">
<p><button type="submit" class="btn"><i class="icon-remove"></i> <?php printMLText("rm_user");?></button></p> <div class="controls">
<button type="submit" class="btn"><i class="icon-remove"></i> <?php printMLText("rm_user_from_processes");?></button>
</div>
</div>
</form> </form>
<?php <?php