<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="f" %>
<%@taglib prefix="tags" tagdir="/WEB-INF/tags" %>
<div class="starter-template">
<tags:errorCheck />
<h1>Group Management</h1>
<div class="row">
<div class="col-md-6">
<div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-title">My Groups</h3>
</div>
<div class="panel-body">
<form data-toggle="validator" role="form" method="POST" action="${context}/user/groupManagement.htm">
<div class="form-group">
<select name="myGroups" class="form-control" style="font-size: 17.5px" multiple size="5">
<c:forEach var="group" varStatus="status" items="${myGroups}">
<option value="${group}">${group}</option>
</c:forEach>
</select>
</div>
<div class="form-group">
<button type="submit" name="groupRequest" value="remove" class="btn btn-primary">Remove Selected Groups</button>
</div>
</form>
</div>
</div>
</div>
<div class="col-md-6">
<div class="panel panel-info">
<div class="panel-heading">
<h3 class="panel-title">Available Groups (approval required unless marked 'auto')</h3>
</div>
<div class="panel-body">
<form data-toggle="validator" role="form" method="POST" action="${context}/user/groupManagement.htm">
<div class="form-group">
<select name="availableGroups" class="form-control" style="font-size: 17.5px" multiple>
<c:forEach var="group" varStatus="status" items="${availableGroups}">
<option value="${group}">${group}<c:if test="${f:contains(autosubscribeGroups, group)}"> (auto)</c:if></option>
</c:forEach>
</select>
</div>
<div class="form-group">
<button type="submit" name="groupRequest" value="add" class="btn btn-primary">Add Selected Groups</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>