diff options
author | Malf Furious <m@lfurio.us> | 2016-09-15 19:46:45 -0400 |
---|---|---|
committer | Malf Furious <m@lfurio.us> | 2016-09-15 19:46:45 -0400 |
commit | 0e00677199347f296426b77f48c8423602c56d66 (patch) | |
tree | 3810967175135bd4bec537c400ce007d2874b00c /app/view/common/group.setting.modal.view.php | |
parent | fa01eb6b8432b1700a393042bbf6626e420001eb (diff) | |
download | scrott-0e00677199347f296426b77f48c8423602c56d66.tar.gz scrott-0e00677199347f296426b77f48c8423602c56d66.zip |
Commit work on setting modal groups tab
I am committing this change incomplete. I'm stopping work on this
particular piece to save some work overall and explore view templating
using PHP features. The idea is to define this markup once in just one
file, rather than having to duplicate it for each object type.
Diffstat (limited to 'app/view/common/group.setting.modal.view.php')
-rw-r--r-- | app/view/common/group.setting.modal.view.php | 53 |
1 files changed, 52 insertions, 1 deletions
diff --git a/app/view/common/group.setting.modal.view.php b/app/view/common/group.setting.modal.view.php index e5c096c..e2a73e0 100644 --- a/app/view/common/group.setting.modal.view.php +++ b/app/view/common/group.setting.modal.view.php @@ -17,5 +17,56 @@ ?> <div class="tab-pane fade <?=$mod->getSettingModalTabDispClasses()?>" id="settGroupTab"> - TODO -- Design this tab. + <p> </p> + + <form method="post" action="<?=$mod->ap()?>" enctype="multipart/form-data"> + <input type="hidden" name="input[action]" value="common-setting-group" /> + <input type="hidden" name="input[guid]" value="<?=$mod->group->guid?>" /> + + <div class="row"> + <div class="col-md-8"> + <div class="form-group"> + <label>Group name</label> + <input type="text" name="input[name]" class="form-control" value="<?=$mod->group->name?>" required="true" maxlength="50" <?=($mod->group->canModify($mod->getCurrentUser()) ? "" : "disabled")?> /> + </div> + </div> + + <div class="col-md-4 text-center"> + <img src="<?=$mod->group->getHeadImage()?>" alt="<?=$mod->group->name?>" class="img-circle" height="100" /> + + <?php if ($mod->group->canModify($mod->getCurrentUser())) { ?> + <br /> + <br /> + <button type="button" class="btn btn-default btn-xs" data-toggle="collapse" data-target="#inputGroupImageCollapse"> + <span class="glyphicon glyphicon-camera"></span> Upload new image + </button> + <br /> + <button type="submit" name="input[rmImage]" class="btn btn-danger btn-xs" onclick="return assertConfirm()"> + <span class="glyphicon glyphicon-remove"></span> Remove image + </button> + <?php } ?> + </div> + </div> + + <div class="collapse" id="inputGroupImageCollapse"> + <div class="form-group"> + <label>Group Image</label> + <input type="file" name="attachment" /> + </div> + </div> + + <?php include "view/common/permissions.setting.modal.view.php"; ?> + <?php include "view/common/ownership.setting.modal.view.php"; ?> + + <button type="submit" class="btn btn-success pull-right">Save</button> + + <p> </p> + <p> </p> + + <button type="submit" name="input[rmGroup]" class="btn btn-danger btn-xs pull-right"> + <span class="glyphicon glyphicon-trash"></span> Delete Group + </button> + </form> + + <p> </p> </div> |