diff options
author | Malf Furious <m@lfurio.us> | 2018-10-22 23:00:01 -0400 |
---|---|---|
committer | Malf Furious <m@lfurio.us> | 2018-10-22 23:00:01 -0400 |
commit | 81870ad1630e578b61ddcb4c06e9e7687fdd3673 (patch) | |
tree | 90daec095aa3ebf0c000c4227701d72ad755c7d5 | |
parent | 8bc6bb994607f919c08a8aa9181209260df23251 (diff) | |
download | scrott-81870ad1630e578b61ddcb4c06e9e7687fdd3673.tar.gz scrott-81870ad1630e578b61ddcb4c06e9e7687fdd3673.zip |
datamods: Add new issue modal
This datamods modal is accessable from pad views to open a new issue on
the pad in question. This is a simplistic version of this interface,
subject to improvements once I start on the v0.2-v0.3 development
iteration. Suffice it to say, any frills we will want to use in the
initial draft will be accessible from the issue view modal, as options
to modify the open issue.
Signed-off-by: Malf Furious <m@lfurio.us>
-rw-r--r-- | app/view/datamods.php | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/app/view/datamods.php b/app/view/datamods.php index e700043..921002c 100644 --- a/app/view/datamods.php +++ b/app/view/datamods.php @@ -119,3 +119,50 @@ require_once "class/user.class.php"; </div> <?php } ?> +<?php function newIssue() : void { ?> + + <?php $p = getPageObj(); ?> + + <div id="newIssueModal" class="modal fade" tabindex="-1" role="dialog"> + <div class="modal-dialog" role="document"> + <div class="modal-content"> + <div class="modal-header"> + <button type="button" class="close" data-dismiss="modal"> + <span aria-hidden="true">×</span> + </button> + + <h4 class="modal-title"> + <span class="glyphicon glyphicon-inbox"></span> Open new Issue + </h4> + </div> + + <div class="modal-body"> + <?php if (count($p->getStages()) == 0) { ?> + <div class="well well-sm text-center text-danger"> + <h3><?=$p->name?> doesn't have any stages</h3> + </div> + <?php } else { ?> + <h4> + <span class="glyphicon glyphicon-tasks"></span> + <?=$p->getStages()[0]->name?> + </h4> + + <form method="post" action="<?=ap()?>"> + <?=\formctrl\formname( "dm-issue-add" )?> + <?=\formctrl\hidden( "pad", $p->guid )?> + <?=\formctrl\text( "Subject", "name" )?> + <?=\formctrl\textarea( "Description", "mesg", 15 )?> + + <button type="submit" class="btn btn-success pull-right"> + <span class="glyphicon glyphicon-plus"></span> Open + </button> + + <p> </p> + </form> + <?php } ?> + </div> + </div> + </div> + </div> + +<?php } ?> |