[vhffs-dev] [790] You can now fill the area of members to subscribe with the members of the current projet |
[ Thread Index |
Date Index
| More vhffs.org/vhffs-dev Archives
]
- To: vhffs-dev@xxxxxxxxx
- Subject: [vhffs-dev] [790] You can now fill the area of members to subscribe with the members of the current projet
- From: subversion@xxxxxxxxx
- Date: Tue, 28 Aug 2007 22:47:26 +0200
Revision: 790
Author: gradator
Date: 2007-08-28 20:47:25 +0000 (Tue, 28 Aug 2007)
Log Message:
-----------
You can now fill the area of members to subscribe with the members of the current projet
Modified Paths:
--------------
trunk/vhffs-panel/mailinglist/prefs.pl
trunk/vhffs-panel/templates/mailinglist/prefs.tmpl
Modified: trunk/vhffs-panel/mailinglist/prefs.pl
===================================================================
--- trunk/vhffs-panel/mailinglist/prefs.pl 2007-08-28 19:23:57 UTC (rev 789)
+++ trunk/vhffs-panel/mailinglist/prefs.pl 2007-08-28 20:47:25 UTC (rev 790)
@@ -154,6 +154,13 @@
$template->param( TITLE_ADD_MEMBERS => gettext("Add members") );
$template->param( TEXT_ADD_MEMBERS => gettext("Addresses (one per line)") );
$template->param( BUTTON_ADD_MEMBERS => gettext("Add them !") );
+
+ my $emaillist = "";
+ foreach ( @{$group->get_users} ) {
+ $emaillist .= $_->{'mail'}."\n";
+ }
+ $template->param( PROJECT_MEMBERS_LIST => $emaillist );
+ $template->param( FILL_MEMBERS_TEXT => gettext("Fill with project's members emails") );
$template->param( CHECK_OPENARCHIVE => "checked" ) if( $list->get_open_archive == 1 );
$template->param( CHECK_REPLYTO => "checked" ) if( $list->get_replyto == 1 );
Modified: trunk/vhffs-panel/templates/mailinglist/prefs.tmpl
===================================================================
--- trunk/vhffs-panel/templates/mailinglist/prefs.tmpl 2007-08-28 19:23:57 UTC (rev 789)
+++ trunk/vhffs-panel/templates/mailinglist/prefs.tmpl 2007-08-28 20:47:25 UTC (rev 790)
@@ -90,16 +90,34 @@
<form method="post" action="add_sub.pl">
+ <div style="z-index: 666; position: absolute; visibility: hidden;">
+ <textarea name="projectmembers" id="projectmembers"><tmpl_var name="PROJECT_MEMBERS_LIST"></textarea>
+ </div>
+
+<script language="JavaScript"><!--
+
+function fill_with_project_members() {
+ if (document.getElementById("fill_members").checked == true) {
+ document.getElementById("MEMBERS").value = document.getElementById("projectmembers").value;
+ }
+ else {
+ document.getElementById("MEMBERS").value = "";
+ };
+};
+
+// --></script>
+
<p>
<label for="USERNAME">
<tmpl_var name="TEXT_ADD_MEMBERS">
</label>
- <textarea name="MEMBERS" rows="7" cols="50"></textarea>
+ <textarea name="MEMBERS" id="MEMBERS" rows="7" cols="50"></textarea>
</p>
<p class="button">
<input type="hidden" name="DOMAIN" value="<tmpl_var name="VALUE_DOMAIN">" />
<input type="hidden" name="LOCALPART" value="<tmpl_var name="VALUE_LOCALPART">" />
<input type="submit" value="<tmpl_var name="BUTTON_ADD_MEMBERS">" />
+ <input type="checkbox" name="fill_members" id="fill_members" value="yes" label="" onClick="javascript:fill_with_project_members();"> <tmpl_var name="FILL_MEMBERS_TEXT">
</p>
</form>
@@ -108,7 +126,7 @@
<form method="post" action="../acl/view.pl">
<p><tmpl_var name="EXPLAIN_ADMIN_ACL"></p>
- <input type="hidden" name="target_oid" value="<tmpl_var name="VALUE_OID">" /
+ <input type="hidden" name="target_oid" value="<tmpl_var name="VALUE_OID">" />
<p class="button" id="buttonAclAdmin">
<input type="submit" value="<tmpl_var name="ADMIN_ACL">" />
</p>