~kosova/+junk/tuxfamily-twiki

« back to all changes in this revision

Viewing changes to foswiki/data/System/BulkRegistration.txt

  • Committer: James Michael DuPont
  • Date: 2009-07-18 19:58:49 UTC
  • Revision ID: jamesmikedupont@gmail.com-20090718195849-vgbmaht2ys791uo2
added foswiki

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
%META:TOPICINFO{author="ProjectContributor" date="1111929255" format="1.1" version="1"}%
 
2
%META:TOPICPARENT{name="ManagingUsers"}%
 
3
---+ Bulk Registration
 
4
 
 
5
Administrators can use this topic to register (i.e. create logins and user topics) for a group of people in one batch. 
 
6
 
 
7
Unlike normal registration the administrator is assumed to have correct e-mail addresses for the users, so *no verification is required.*
 
8
Note that the new users are not notified that they have an account. This is so you can prepare and verify the accounts before announcing them.
 
9
To announce them use the [[BulkResetPassword]] feature: this will assign a new random password and notify users. 
 
10
 
 
11
---++ Bulk Registration usage
 
12
Note: this is an administrator job - only admistrators can run this.
 
13
 
 
14
If you are administrator, you will take these actions:
 
15
   1 (First time use) Create new bulk registration topics (see [[#Settings][Settings]] below).
 
16
   1 In the REGISTERTOPIC topic: create a table of new users. An example table is provided below to copy.
 
17
   1 Return to this topic and press the button "Bulk Register" to create the new topics.
 
18
   1 Read %LOGTOPIC% to verify if all has gone well.
 
19
   1 When you are ready, use the [[BulkResetPassword]] page to assign passwords and notify the users of their new accounts.
 
20
 
 
21
Below are the details.
 
22
 
 
23
---++ Settings
 
24
   * Define where to pick up the table of users to register
 
25
      * Set REGISTERTOPIC = %USERSWEB%.UnprocessedRegistrations
 
26
   * Use this to define where to log the bulk registration process. It needs
 
27
     to be a topic name in this web.
 
28
      * Set LOGTOPIC = %REGISTERTOPIC%Log
 
29
   * Set this to 1 to make the bulk registration overwrite any existing user
 
30
     topics. By default, existing user topics are left alone.
 
31
      * Set OVERWRITEHOMETOPICS = 0
 
32
 
 
33
---++ The user table
 
34
This table is a template for user data that will be written to the new user topics. If you stick to these basic fields you can just use the first example below. If you want to write more data (like phone number or country) read the section [[#CustomizingUserData][Customizing user data]] as well.
 
35
 
 
36
---+++ Example format
 
37
The following should be inserted into your %REGISTERTOPIC% as a table. This is the most simple format:
 
38
<verbatim>
 
39
<noautolink>
 
40
%EDITTABLE{}%
 
41
| FirstName | LastName | Email | WikiName |
 
42
| Test | User | you@example.com | TestUser |
 
43
</noautolink>
 
44
</verbatim>
 
45
 
 
46
*Usage:*
 
47
   1 Copy this text to your clipboard
 
48
   1 Click through and paste this on %REGISTERTOPIC%. 
 
49
   1 Add and customize entries, save table. Note that the first row must not contain bolded entries, so don't apply any formatting.
 
50
   1 Return here
 
51
 
 
52
#CustomizingUserData
 
53
---+++ Customizing user data
 
54
 
 
55
You can write additional data to the new user topics. Do this by enhancing the user table with additional field names as table headers.
 
56
 
 
57
Any fields you define in this table will end up in the User's topic. If a form (such as %SYSTEMWEB%.UserForm) is attached to NewUserTemplate then the data will go in as META:FIELDS, meaning that you can use SEARCH formfield constructs to search. 
 
58
 
 
59
If you use the %SYSTEMWEB%.UserForm then ensure that it contains all the fields you define here. Otherwise they will disappear when the user edits their home topic!
 
60
 
 
61
---++++ Mandatory fields
 
62
   * !WikiName 
 
63
   * !FirstName
 
64
   * !LastName 
 
65
 
 
66
---++++ Optional fields
 
67
   * LoginName - if not set will register with WikiName
 
68
 
 
69
---++++ Customized table example
 
70
Make sure that the extra fields also appear on the %SYSTEMWEB%.UserForm.
 
71
<verbatim>
 
72
<noautolink>
 
73
%EDITTABLE{}%
 
74
| FirstName | LastName | Email | WikiName | CustomFieldThis | SomeOtherRandomField | WhateverYouLike |
 
75
| Test | User | you@example.com | TestUser | A | B | C |
 
76
</noautolink>
 
77
</verbatim>
 
78
 
 
79
---
 
80
%IF{
 
81
  "context passwords_modifyable"
 
82
  then=""
 
83
  else="<strong>%MAKETEXT{"Sorry, the password system is currently read only, please contact [_1]" args="%WIKIWEBMASTER%"}%</strong><br />"
 
84
}%
 
85
<!--
 
86
      * Set NOTMODIFYABLE = %IF{"context passwords_modifyable" then="" else="DISABLED"}%
 
87
-->
 
88
<form name="bulkRegister" action="%SCRIPTURLPATH{"manage"}%/%REGISTERTOPIC%" method="post">
 
89
<input type="hidden" name="action" value="bulkRegister" />&nbsp;
 
90
<input %NOTMODIFYABLE% type="submit" class="foswikiSubmit" value="Bulk Register these people" />
 
91
<input type="hidden" name="LogTopic" value="%LOGTOPIC%" />
 
92
<input type="hidden" name="OverwriteHomeTopics" value="%OVERWRITEHOMETOPICS%" />
 
93
</form>
 
94
 
 
95
---++ <nop>%REGISTERTOPIC%
 
96
 
 
97
%INCLUDE{"%REGISTERTOPIC%" warn="off"}%
 
98
 
 
99
 
 
100
---++ <nop>%LOGTOPIC%
 
101
 
 
102
%INCLUDE{"%LOGTOPIC%" warn="off"}%
 
103
 
 
104
---
 
105
*Related Topics:* AdminToolsCategory