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 wrap: on
line diff
--- a/examples/common/default/invite.m4.html	Tue Apr 21 12:26:17 2020 +0900
+++ b/examples/common/default/invite.m4.html	Tue Apr 21 12:27:02 2020 +0900
@@ -1,4 +1,6 @@
 <h1>招待メイル送信</h1>
+<p>_INVITE_POLICY_</p>
+
 <p>_REPORT_</p>
 
 <form method="POST" action="_ACTION_">
--- a/s4-funcs.sh	Tue Apr 21 12:26:17 2020 +0900
+++ b/s4-funcs.sh	Tue Apr 21 12:27:02 2020 +0900
@@ -18,6 +18,7 @@
 admin=${ADMIN:-hostmaster@example.org}
 noreply=${NOREPLY:-noreply@example.org}
 noreply_from="${S4NAME:-s4} message notification <$noreply>"
+invite_policy=${INVITE_POLICY:-"このコミュニティに関りのあるあなたの信頼できる人を招きます。"}
 templ=${TEMPL:-templ}
 layout=${LAYOUT:-$templ/default}
 formdir=${FORMDIR:-$templ/form}
@@ -1525,8 +1526,14 @@
   if [ -n "$addr" ]; then
     susp="<h2>招待済みで加入待ちのアドレス</h2><pre>$addr</pre>"
   fi
+  if [ -f $invite_policy ]; then
+    pol="spaste(\`$invite_policy')"
+  else
+    pol="$invite_policy"
+  fi
   _m4 -D_TITLE_="招待" -D_REPORT_="\`$repo'" -D_ACTION_="?invite" \
       -D_BODYCLASS_="default" -D_SUSPENDED_="$susp" \
+      -D_INVITE_POLICY_="$pol" \
       $layout/html.m4.html $layout/invite.m4.html
 }
 regist() {

yatex.org