Commit 55e85600 authored by Jérome Perrin's avatar Jérome Perrin

delete Bug_getUserPersonValue and use ERP5Site_getAuthenticatedMemberPersonValue instead

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@36435 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 1492bec7
...@@ -60,7 +60,7 @@ edit_kw = {\'content_type\': portal.portal_preferences.getPreferredTextFormat(), ...@@ -60,7 +60,7 @@ edit_kw = {\'content_type\': portal.portal_preferences.getPreferredTextFormat(),
\'destination_value_list\': context.BugLine_getRecipientValueList()}\n \'destination_value_list\': context.BugLine_getRecipientValueList()}\n
\n \n
# Define a Reporter as Source Trade\n # Define a Reporter as Source Trade\n
person = context.Bug_getUserPersonValue()\n person = context.ERP5Site_getAuthenticatedMemberPersonValue()\n
if person is not None:\n if person is not None:\n
edit_kw[\'source_value\'] = person\n edit_kw[\'source_value\'] = person\n
\n \n
......
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>sender = context.Bug_getUserPersonValue()\n <value> <string>sender = context.ERP5Site_getAuthenticatedMemberPersonValue()\n
\n \n
if sender is None:\n if sender is None:\n
sender = context.getDestinationValue()\n sender = context.getDestinationValue()\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<tuple>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
<tuple/>
</tuple>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_body</string> </key>
<value> <string encoding="cdata"><![CDATA[
# Define a Reporter as Source Trade\n
user = context.portal_membership.getAuthenticatedMember().getUserName()\n
person_list = context.acl_users.erp5_users.getUserByLogin(user)\n
\n
if len(person_list) > 0:\n
return person_list[0]\n
\n
return None\n
]]></string> </value>
</item>
<item>
<key> <string>_code</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>errors</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>func_code</string> </key>
<value>
<object>
<klass>
<global name="FuncCode" module="Shared.DC.Scripts.Signature"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>co_argcount</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>co_varnames</string> </key>
<value>
<tuple>
<string>_getattr_</string>
<string>context</string>
<string>user</string>
<string>person_list</string>
<string>len</string>
<string>_getitem_</string>
<string>None</string>
</tuple>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>func_defaults</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>Bug_getUserPersonValue</string> </value>
</item>
<item>
<key> <string>warnings</string> </key>
<value>
<tuple/>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
...@@ -54,7 +54,7 @@ ...@@ -54,7 +54,7 @@
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string># Define a Reporter as Source Trade\n <value> <string># Define a Reporter as Source Trade\n
person = context.Bug_getUserPersonValue()\n person = context.ERP5Site_getAuthenticatedMemberPersonValue()\n
\n \n
if person is not None:\n if person is not None:\n
context.setSourceTradeValue(person)\n context.setSourceTradeValue(person)\n
......
601 602
\ No newline at end of file \ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment