<# start list for members; sort by username; save to members.options; #> <# start row #> <option value="<# id #>"><# username as html #></option> <# end row #> <# end list #> <# start list for groups; sort by name; save to groups.options; #> <# start row #> <# if "<# name as uppercase #>"=="ADMINS" #> <# delete record for "groups.<# id #>"; #> <# else #> <option value="<# id #>"><# name as html #></option> <# end if #> <# end row #> <# end list #> <# start form for group_memberships <#[url.edit]#>; set form.class to "form-horizontal"; when deleting call confirm('Delete Membership?'); when done redirect to "/members/group-memberships?index=<# form.id #>"; #> <div class="form-group"> <label for="member_id" class="col-sm-2 control-label">Member</label> <div class="col-sm-4"> <select <# member_id #> required class="form-control" id="member_id"> <option value="">Choose a Member</option> <#[members.options]#> </select> </div> </div> <div class="form-group"> <label for="group_id" class="col-sm-2 control-label">Group</label> <div class="col-sm-4"> <select <# group_id #> required class="form-control" id="group_id"> <option value="">Choose a Group</option> <#[groups.options]#> </select> </div> </div> <div class="form-group"> <div class="col-sm-offset-2 col-sm-4"> <input type="button" <# Create button #> class="btn btn-primary"> <input type="button" <# Update button #> class="btn btn-primary"> <input type="button" <# Delete button #> class="btn btn-primary"> </div> </div> <# end form #>
The Members Mini-App uses the Hashtag Markup Language to demonstrate a user authentication process for #WebApps.
Member, Group, and Group Membership records are all stored in an SQL Database. Methods are provided to create, update, and delete all of these records.
Members Only pages restrict access based on group membership.