| @@ 61-73 (lines=13) @@ | ||
| 58 | return self.getInstrument().absolute_url_path() |
|
| 59 | return None |
|
| 60 | ||
| 61 | def getObjectWorkflowStates(self): |
|
| 62 | """ |
|
| 63 | This method is used as a metacolumn. |
|
| 64 | Returns a dictionary with the workflow id as key and workflow state as |
|
| 65 | value. |
|
| 66 | :returns: {'review_state':'active',...} |
|
| 67 | """ |
|
| 68 | workflow = getToolByName(self, 'portal_workflow') |
|
| 69 | states = {} |
|
| 70 | for w in workflow.getWorkflowsFor(self): |
|
| 71 | state = w._getWorkflowStateOf(self).id |
|
| 72 | states[w.state_var] = state |
|
| 73 | return states |
|
| 74 | ||
| 75 | ||
| 76 | # Activating the content type in Archetypes' internal types registry |
|
| @@ 232-243 (lines=12) @@ | ||
| 229 | return self.portal_membership.getMemberById( |
|
| 230 | self.getUsername()) is not None |
|
| 231 | ||
| 232 | def getObjectWorkflowStates(self): |
|
| 233 | """ |
|
| 234 | Returns a dictionary with the workflow id as key and workflow state as |
|
| 235 | value. |
|
| 236 | :returns: {'review_state':'active',...} |
|
| 237 | """ |
|
| 238 | workflow = getToolByName(self, 'portal_workflow') |
|
| 239 | states = {} |
|
| 240 | for w in workflow.getWorkflowsFor(self): |
|
| 241 | state = w._getWorkflowStateOf(self).id |
|
| 242 | states[w.state_var] = state |
|
| 243 | return states |
|
| 244 | ||
| 245 | ### Removed these accessors to prevent confusion when LDAP is used |
|
| 246 | # def getEmailAddress(self, **kw): |
|
| @@ 1299-1312 (lines=14) @@ | ||
| 1296 | return analyst_member.getProperty('fullname') |
|
| 1297 | return analyst |
|
| 1298 | ||
| 1299 | def getObjectWorkflowStates(self): |
|
| 1300 | """ |
|
| 1301 | This method is used as a metacolumn. |
|
| 1302 | Returns a dictionary with the workflow id as key and workflow state as |
|
| 1303 | value. |
|
| 1304 | :returns: {'review_state':'active',...} |
|
| 1305 | :rtype: dict |
|
| 1306 | """ |
|
| 1307 | workflow = getToolByName(self, 'portal_workflow') |
|
| 1308 | states = {} |
|
| 1309 | for w in workflow.getWorkflowsFor(self): |
|
| 1310 | state = w._getWorkflowStateOf(self).id |
|
| 1311 | states[w.state_var] = state |
|
| 1312 | return states |
|
| 1313 | ||
| 1314 | # TODO Workflow - Worksheet - Move to workflow.worksheet.events |
|
| 1315 | def workflow_script_reject(self): |
|
| @@ 2141-2153 (lines=13) @@ | ||
| 2138 | """ |
|
| 2139 | return user_email(self, self.Creator()) |
|
| 2140 | ||
| 2141 | def getObjectWorkflowStates(self): |
|
| 2142 | """ |
|
| 2143 | This method is used as a metacolumn. |
|
| 2144 | Returns a dictionary with the workflow id as key and workflow state as |
|
| 2145 | value. |
|
| 2146 | :returns: {'review_state':'active',...} |
|
| 2147 | """ |
|
| 2148 | workflow = getToolByName(self, 'portal_workflow') |
|
| 2149 | states = {} |
|
| 2150 | for w in workflow.getWorkflowsFor(self): |
|
| 2151 | state = w._getWorkflowStateOf(self).id |
|
| 2152 | states[w.state_var] = state |
|
| 2153 | return states |
|
| 2154 | ||
| 2155 | def SearchableText(self): |
|
| 2156 | """ |
|