X-Git-Url: https://git.hcoop.net/hcoop/zz_old/portal.git/blobdiff_plain/03577083182d383cee5372882331a17eb3b76bd1..7a02706f285799a9f20c8d085906dceec1facebf:/apps.mlt diff --git a/apps.mlt b/apps.mlt index c75781e..82dccaa 100644 --- a/apps.mlt +++ b/apps.mlt @@ -6,18 +6,48 @@ 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 %>
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) %>
Forward e-mail? <% if #forward appl then %>yes<% else %>no<% end %>
Proposed uses: <% Web.htmlNl (#uses appl) %>
Other information: <% Web.htmlNl (#other appl) %>
+<% elseif $"vote" <> "" then Group.requireGroupName "board"; App.vote (you, Web.stoi ($"vote")) - %>

Vote registered

<% + %>

Vote registered

<% elseif $"unvote" <> "" then Group.requireGroupName "board"; App.unvote (you, Web.stoi ($"unvote")) - %>

Unvote registered

<% + %>

Unvote registered

<% elseif $"deny" <> "" then showNormal := false; val appl = App.lookupApp (Web.stoi ($"deny")) - %>

Deny application for <% #name appl %>

+ %>

Deny application for <% #name appl %>

"> Reason:
@@ -27,37 +57,37 @@ elseif $"deny" <> "" then elseif $"deny2" <> "" then Group.requireGroupName "board"; if not (App.deny (Web.stoi ($"deny2"), $"msg")) then - %>

Error denying application

<% + %>

Error denying application

<% else - %>

Application denied

<% + %>

Application denied

<% end elseif $"approve" <> "" then showNormal := false; val appl = App.lookupApp (Web.stoi ($"approve")) - %>

Approve application for <% #name appl %>

+ %>

Approve application for <% #name appl %>

"> - Message:
+ Message (will be added at the end of ~hcoop/portal/welcome.txt, so you might want to include some introductory text):

<% elseif $"approve2" <> "" then Group.requireGroupName "board"; if not (App.approve (Web.stoi ($"approve2"), $"msg")) then - %>

Error approving application

<% + %>

Error approving application

<% else - %>

Application approved

<% + %>

Application approved

<% end elseif $"cmd" = "approved" then showNormal := false - %>

Pending applications

<% + %>

Pending applications

<% foreach appl in App.listApps App.ACCEPTED do %>


- - -
Received: <% #applied appl %>
Approved by: <% + + + - - - - - - + + + + <% switch #paypal appl of + SOME s => %> + <% end; + switch #checkout appl of + SOME s => %> + <% end %> + + +
Received: <% #applied appl %>
Approved by: <% ref first = true; ref found = false; foreach (id, name) in App.votes (#id appl) do @@ -68,12 +98,18 @@ elseif $"cmd" = "approved" then end %><% name %><% end %>
Username: <% #name appl %>
Real name: <% Web.html (#rname appl) %>
E-mail address: <% #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) %>
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) %>
<% if root then %> @@ -87,26 +123,24 @@ elseif $"add" <> "" then val appl = App.lookupApp id; App.add id %> -First, create this UNIX user: -
portal_adduser <% #name appl %> "<% #rname appl %>"<% if #forward appl then %> "<% #email appl %>"<% end %>
- -

You should then run visudo to add <% #name appl %> to the MEMBERS group. If you're not transmitting <% #name appl %>'s password to him by other means, run savepass <% #name appl %> <password> to save it in ~<% #name appl %>/.pass. If <% #name appl %> is bootstrapping with public-key ssh, don't forget to run savekey <% #name appl %> <authorized_keys file location>.

+First, run this on deleuze: +
new-user <% #name appl %> "<% #rname appl %>"<% if #forward appl then %> "<% #email appl %>"<% end %>
- - - -
Name:
Real name:
Funded by: + + + - - - - + + +
Name:
Real name:
Funded by:
Initial transaction amount:
Initial transaction description:
Subscribe to hcoop-announce
Groups:
Initial transaction amount:
Initial transaction description:
Groups: - -
Received: <% #applied appl %>
Approved by: <% + + + - - - - - - + + + + <% switch #paypal appl of + SOME s => %> + <% end; + switch #checkout appl of + SOME s => %> + <% end %> + + +
Received: <% #applied appl %>
Approved by: <% ref first = true; ref found = false; val votes = App.votes (#id appl); @@ -146,12 +180,18 @@ end %> %> [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 address: <% #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) %>
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) %>
<% if board then %> @@ -161,4 +201,4 @@ end %> <% end end %> -<% @footer[] %> \ No newline at end of file +<% @footer[] %>