Structure of Google Docs Based Volunteer Management System -
here's able do. point of manage various volunteers necessary create our church run every sunday.
have google docs spreadsheet names of volunteers , roles willing staff (for example, tim volunteers usher; ana volunteers lector).
have separate sheet listing every volunteer position needs filled next 6 months (for example, need 2 ushers , 1 lector on sunday).
write google apps script go through list of positions need filled , take next volunteer asked fill position (probably based on has filled role fewest number of times in past). script send e-mail volunteer , inquire if available position. ideally, e-mail html based , include 2 links in it: 1 them click take position , 1 them click decline position.
if volunteer accepts position, script adds name position. if volunteer declines position, script moves on next volunteer , sends same e-mail.
the script continues process until either of slots filled or volunteers have declined.
i can conceptualize of need on except links in e-mail.
does have suggestions ways dynamically generate links this?
any other thoughts how can construction script want?
obviously, i'm still in thinking-it-through phase, i'm open suggestions.
thanks in advance. (and members of our little church give thanks you, too!)
generating links of course of study possible! i wrote reply recently. don't need parts of answer. maybe should look @ reply instead.
anyways, bit of sample/psuedo-code.
var scripturl = scriptapp.getservice().geturl(); //url invoke script var message = "blah blah event details blah blah" +" <a href=\""+scripturl+"?user="+user+"&accept=no\">decline</a>" +" or <a href=\""+scripturl+"?user="+user+"&accept=yes\">accept</a>"; mailapp.sendemail(recipent,subject,"",{htmlbody:message});
then handle using doget(e) parameters explained in answers above.
function doget(e) { var user = e.parameter.user; var take = e.parameter.accept; if (accept=="yes") { //he/she accepted!! } else { //he/she declined. =( } }
google-apps-script
No comments:
Post a Comment