s4

changeset 624:64c84bc00700

Invatation policy displayed in invitation page
author HIROSE Yuuji <yuuji@gentei.org>
date Tue, 21 Apr 2020 12:27:02 +0900
parents 5d857faac912
children 74c0c2ed8ff5
files examples/common/default/invite.m4.html s4-funcs.sh
diffstat 2 files changed, 9 insertions(+), 0 deletions(-) [+]
line diff
     1.1 --- a/examples/common/default/invite.m4.html	Tue Apr 21 12:26:17 2020 +0900
     1.2 +++ b/examples/common/default/invite.m4.html	Tue Apr 21 12:27:02 2020 +0900
     1.3 @@ -1,4 +1,6 @@
     1.4  <h1>招待メイル送信</h1>
     1.5 +<p>_INVITE_POLICY_</p>
     1.6 +
     1.7  <p>_REPORT_</p>
     1.8  
     1.9  <form method="POST" action="_ACTION_">
     2.1 --- a/s4-funcs.sh	Tue Apr 21 12:26:17 2020 +0900
     2.2 +++ b/s4-funcs.sh	Tue Apr 21 12:27:02 2020 +0900
     2.3 @@ -18,6 +18,7 @@
     2.4  admin=${ADMIN:-hostmaster@example.org}
     2.5  noreply=${NOREPLY:-noreply@example.org}
     2.6  noreply_from="${S4NAME:-s4} message notification <$noreply>"
     2.7 +invite_policy=${INVITE_POLICY:-"このコミュニティに関りのあるあなたの信頼できる人を招きます。"}
     2.8  templ=${TEMPL:-templ}
     2.9  layout=${LAYOUT:-$templ/default}
    2.10  formdir=${FORMDIR:-$templ/form}
    2.11 @@ -1525,8 +1526,14 @@
    2.12    if [ -n "$addr" ]; then
    2.13      susp="<h2>招待済みで加入待ちのアドレス</h2><pre>$addr</pre>"
    2.14    fi
    2.15 +  if [ -f $invite_policy ]; then
    2.16 +    pol="spaste(\`$invite_policy')"
    2.17 +  else
    2.18 +    pol="$invite_policy"
    2.19 +  fi
    2.20    _m4 -D_TITLE_="招待" -D_REPORT_="\`$repo'" -D_ACTION_="?invite" \
    2.21        -D_BODYCLASS_="default" -D_SUSPENDED_="$susp" \
    2.22 +      -D_INVITE_POLICY_="$pol" \
    2.23        $layout/html.m4.html $layout/invite.m4.html
    2.24  }
    2.25  regist() {