Huge Plinn Folder est le type de dossier pour « Members ».
[Plinn.git] / profiles / photo / workflows / member_workflow / definition.xml
1 <?xml version="1.0"?>
2 <dc-workflow workflow_id="member_workflow"
3 title="Plinn member registration workflow"
4 description="" state_variable="review_state"
5 initial_state="m_initial" manager_bypass="0">
6
7 <state state_id="m_initial" title="">
8 <exit-transition transition_id="create"/>
9 <exit-transition transition_id="silent_register"/>
10 </state>
11 <state state_id="m_pending" title="">
12 <exit-transition transition_id="register"/>
13 <exit-transition transition_id="reject"/>
14 </state>
15 <state state_id="m_registered" title="">
16 </state>
17 <state state_id="m_rejected" title="">
18 </state>
19 <transition transition_id="create" title=""
20 new_state="m_pending" trigger="AUTOMATIC"
21 before_script="" after_script="">
22
23 <guard>
24 <guard-expression>python:state_change.getPortal().portal_membership.isAnonymousUser()</guard-expression>
25 </guard>
26 </transition>
27 <transition transition_id="register"
28 title="Register member"
29 new_state="m_registered" trigger="USER"
30 before_script="before_register"
31 after_script="sendNotificationEmail">
32
33 <guard>
34 <guard-permission>Manage Groups</guard-permission>
35 <guard-permission>Set Member Properties</guard-permission>
36 </guard>
37 </transition>
38 <transition transition_id="reject"
39 title="Reviewer rejects registration"
40 new_state="" trigger="USER" before_script=""
41 after_script="after_reject">
42
43 <guard>
44 <guard-permission>Manage Groups</guard-permission>
45 <guard-permission>Set Member Properties</guard-permission>
46 <guard-permission>Remove member</guard-permission>
47 </guard>
48 </transition>
49 <transition transition_id="silent_register" title=""
50 new_state="m_registered" trigger="AUTOMATIC"
51 before_script="before_register" after_script="">
52
53 <guard>
54 <guard-permission>Manage Groups</guard-permission>
55 <guard-permission>Set Member Properties</guard-permission>
56 </guard>
57 </transition>
58 <worklist worklist_id="reviewer_queue" title="">
59 <description>Reviewer tasks</description>
60 <action url="%(portal_url)s/pending_members"
61 category="global">Membres en attente (%(count)d)</action>
62 <guard>
63 <guard-permission>Set Member Properties</guard-permission>
64 </guard>
65 <match name="review_state" values="m_pending"/>
66 </worklist>
67 <variable variable_id="action" for_catalog="False"
68 for_status="True" update_always="True">
69 <description>The last transition</description>
70 <default>
71
72 <expression>transition/getId|nothing</expression>
73 </default>
74 <guard>
75 </guard>
76 </variable>
77 <variable variable_id="actor" for_catalog="False"
78 for_status="True" update_always="True">
79 <description>The ID of the user who performed the last transition</description>
80 <default>
81
82 <expression>user/getId</expression>
83 </default>
84 <guard>
85 </guard>
86 </variable>
87 <variable variable_id="comments" for_catalog="False"
88 for_status="True" update_always="True">
89 <description>Comments about the last transition</description>
90 <default>
91
92 <expression>python:state_change.kwargs.get('comment', '')</expression>
93 </default>
94 <guard>
95 </guard>
96 </variable>
97 <variable variable_id="review_history" for_catalog="False"
98 for_status="False" update_always="False">
99 <description>Provides access to workflow history</description>
100 <default>
101
102 <expression>state_change/getHistory</expression>
103 </default>
104 <guard>
105 <guard-permission>Request review</guard-permission>
106 <guard-permission>Review portal content</guard-permission>
107 </guard>
108 </variable>
109 <variable variable_id="time" for_catalog="False"
110 for_status="True" update_always="True">
111 <description>Time of the last transition</description>
112 <default>
113
114 <expression>state_change/getDateTime</expression>
115 </default>
116 <guard>
117 </guard>
118 </variable>
119 <script script_id="after_reject" type="Script (Python)"
120 filename="workflows/member_workflow/scripts/after_reject.py"
121 module="" function=""/>
122 <script script_id="before_register" type="Script (Python)"
123 filename="workflows/member_workflow/scripts/before_register.py"
124 module="" function=""/>
125 <script script_id="sendNotificationEmail"
126 type="Script (Python)"
127 filename="workflows/member_workflow/scripts/sendNotificationEmail.py"
128 module="" function=""/>
129 </dc-workflow>