X-Git-Url: https://git.hcoop.net/hcoop/portal.git/blobdiff_plain/6f91863c2a28a8590a6763580062c1d31b43dbec..ac5cb613b0f0a143eaeed801979bfc56e7c88e40:/apps.mlt diff --git a/apps.mlt b/apps.mlt index adec3b6..e3ac4b2 100644 --- a/apps.mlt +++ b/apps.mlt @@ -1,23 +1,54 @@ <% @header [("title", ["Membership applications"])]; val you = Init.getUserId (); -val board = Group.inGroupName "board"; +val board = Group.reallyInGroupName "board"; val root = Group.inGroupNum 0; ref showNormal = true; -if $"vote" <> "" then +if $"show" <> "" then + showNormal := false; + val usr = Web.stoi ($"show"); + val user = Init.lookupUser usr; + val appl = App.lookupApp (#app user) %> + +
Received: | <% #applied appl %> (<% Util.diffFromNow (#applied appl) %> ago) |
Approved by: | <% + ref first = true; + ref found = false; + val votes = App.votes (#id appl); + foreach (id, name) in votes do + if first then + first := false + else + %>, <% + end + %><% name %><% + if id = you then + found := true + %> [Unvote]<% + end + end %> <% if (iff board then not found else false) then %>[Vote]<% end %> |
Username: | <% #name appl %> |
Real name: | <% Web.html (#rname appl) %> |
E-mail: | <% #email appl %> |
Forward e-mail? | <% if #forward appl then %>yes<% else %>no<% end %> |
Proposed uses: | <% Web.htmlNl (#uses appl) %> |
Other information: | <% Web.htmlNl (#other appl) %> |
Received: | <% #applied appl %> (<% Util.diffFromNow (#applied appl) %> ago) |
Approved by: | <% + ref first = true; + ref found = false; + foreach (id, name) in App.votes (#id appl) do + if first then + first := false + else + %>, <% + end + %><% name %><% + end %> |
Username: | <% #name appl %> |
Real name: | <% Web.html (#rname appl) %> |
E-mail address: | <% #email appl %> |
PayPal: | <% s %> |
Google Checkout: | <% s %> |
Forward e-mail? | <% if #forward appl then %>yes<% else %>no<% end %> |
Proposed uses: | <% Web.htmlNl (#uses appl) %> |
Other information: | <% Web.htmlNl (#other appl) %> |
WARNING: Someone already followed the add link for this application. Maybe he forgot to finish. |
new-user <% #name appl %> "<% #rname appl %>"<% if #forward appl then %> "<% #email appl %>"<% end %>+ + + +Abort adding this member + +<% elseif $"abort" <> "" then + App.abortAdd (Web.stoi ($"abort")) + %>
Received: | <% #applied appl %> | ||||||||||||||||||||||||||||||||
Approved by: | <%
+
+ <% if length votes >= 3 then %>Approve this member. <% end %> Deny this application. <% end %> -<% end +<% end end %> -<% @footer[] %> \ No newline at end of file +<% @footer[] %> |