Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Levin Zimmermann
erp5
Commits
0eed9896
Commit
0eed9896
authored
Oct 27, 2016
by
Kazuhiko Shiozaki
Committed by
Vincent Pelletier
Dec 23, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use getId() instead of __str__.
parent
58e85421
Changes
14
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
15 additions
and
15 deletions
+15
-15
bt5/erp5_accounting_ui_test/SkinTemplateItem/portal_skins/erp5_accounting_ui_test/AccountingZuite_reset.py
...al_skins/erp5_accounting_ui_test/AccountingZuite_reset.py
+1
-1
bt5/erp5_crm/SkinTemplateItem/portal_skins/erp5_crm/AcknowledgementTool_getUserUnreadAcknowledgementList.py
...m/AcknowledgementTool_getUserUnreadAcknowledgementList.py
+1
-1
bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/Base_getAdvancedSearchResultList.py
...portal_skins/erp5_dms/Base_getAdvancedSearchResultList.py
+1
-1
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/Base_contribute.py
...mplateItem/portal_skins/erp5_ingestion/Base_contribute.py
+1
-1
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/ContributionTool_countMyContentList.py
...ins/erp5_ingestion/ContributionTool_countMyContentList.py
+1
-1
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/ContributionTool_getMyContentList.py
...skins/erp5_ingestion/ContributionTool_getMyContentList.py
+1
-1
bt5/erp5_km/SkinTemplateItem/portal_skins/erp5_km_widget_library/PersonModule_viewMyContactListGadget/listbox.xml
..._library/PersonModule_viewMyContactListGadget/listbox.xml
+1
-1
bt5/erp5_run_my_doc/SkinTemplateItem/portal_skins/erp5_run_my_doc/Review_editAnnotationList.py
...portal_skins/erp5_run_my_doc/Review_editAnnotationList.py
+1
-1
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.SearchUtility.py
...ateItem/portal_components/extension.erp5.SearchUtility.py
+1
-1
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/template_erp5_xhtml_style.zpt
...rtal_skins/erp5_xhtml_style/template_erp5_xhtml_style.zpt
+1
-1
product/ERP5Form/Tool/SelectionTool.py
product/ERP5Form/Tool/SelectionTool.py
+1
-1
product/ERP5OOo/tests/testDms.py
product/ERP5OOo/tests/testDms.py
+1
-1
product/ERP5Type/tests/testCookieCrumbler.py
product/ERP5Type/tests/testCookieCrumbler.py
+1
-1
product/ERP5VCS/Subversion.py
product/ERP5VCS/Subversion.py
+2
-2
No files found.
bt5/erp5_accounting_ui_test/SkinTemplateItem/portal_skins/erp5_accounting_ui_test/AccountingZuite_reset.py
View file @
0eed9896
...
...
@@ -30,7 +30,7 @@ for entity in ( portal.organisation_module.objectValues() +
# enable preference
ptool
=
portal
.
portal_preferences
pref
=
ptool
.
accounting_zuite_preference
if
pref
.
owner_info
()[
'id'
]
!=
str
(
context
.
REQUEST
.
AUTHENTICATED_USER
):
if
pref
.
owner_info
()[
'id'
]
!=
context
.
REQUEST
.
AUTHENTICATED_USER
.
getId
(
):
# we have to 'own' the preference for the test
ptool
=
portal
.
portal_preferences
# pref.setId('old_accounting_zuite_preference')
...
...
bt5/erp5_crm/SkinTemplateItem/portal_skins/erp5_crm/AcknowledgementTool_getUserUnreadAcknowledgementList.py
View file @
0eed9896
...
...
@@ -5,7 +5,7 @@ down as less a possible the user interface
"""
from
DateTime
import
DateTime
user_name
=
str
(
context
.
portal_membership
.
getAuthenticatedMember
()
)
user_name
=
context
.
portal_membership
.
getAuthenticatedMember
().
getId
(
)
def
getUnreadAcknowledgementListForUser
(
user_name
=
None
):
# We give the portal type "Mass Notification" for now, we can
...
...
bt5/erp5_dms/SkinTemplateItem/portal_skins/erp5_dms/Base_getAdvancedSearchResultList.py
View file @
0eed9896
...
...
@@ -71,7 +71,7 @@ if len(where_expression_list):
if
parsed_search_string
.
get
(
'mine'
,
None
)
is
not
None
:
# user wants only his documents
query_kw
[
'owner'
]
=
str
(
portal
.
portal_membership
.
getAuthenticatedMember
()
)
query_kw
[
'owner'
]
=
portal
.
portal_membership
.
getAuthenticatedMember
().
getId
(
)
# add contributor title
contributor_title
=
parsed_search_string
.
get
(
'contributor_title'
,
None
)
...
...
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/Base_contribute.py
View file @
0eed9896
...
...
@@ -18,7 +18,7 @@ if redirect_to_document is None:
redirect_to_document
=
portal
.
portal_preferences
.
isPreferredRedirectToDocument
(
False
)
if
user_login
is
None
:
# get current authenticated user
user_login
=
str
(
portal
.
portal_membership
.
getAuthenticatedMember
()
)
user_login
=
portal
.
portal_membership
.
getAuthenticatedMember
().
getId
(
)
document_kw
=
{
'user_login'
:
user_login
,
'group'
:
group
,
...
...
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/ContributionTool_countMyContentList.py
View file @
0eed9896
...
...
@@ -7,7 +7,7 @@
that owner is being indexed.
"""
if
user
is
None
:
user
=
context
.
portal_membership
.
getAuthenticatedMember
()
user
=
context
.
portal_membership
.
getAuthenticatedMember
()
.
getId
()
kw
[
'owner'
]
=
user
kw
[
'portal_type'
]
=
context
.
getPortalMyDocumentTypeList
()
...
...
bt5/erp5_ingestion/SkinTemplateItem/portal_skins/erp5_ingestion/ContributionTool_getMyContentList.py
View file @
0eed9896
...
...
@@ -7,7 +7,7 @@
that owner is being indexed.
"""
if
user
is
None
:
user
=
context
.
portal_membership
.
getAuthenticatedMember
()
user
=
context
.
portal_membership
.
getAuthenticatedMember
()
.
getId
()
kw
[
'portal_type'
]
=
context
.
getPortalMyDocumentTypeList
()
kw
[
'owner'
]
=
user
...
...
bt5/erp5_km/SkinTemplateItem/portal_skins/erp5_km_widget_library/PersonModule_viewMyContactListGadget/listbox.xml
View file @
0eed9896
...
...
@@ -248,7 +248,7 @@
<dictionary>
<item>
<key>
<string>
_text
</string>
</key>
<value>
<string>
python: [[\'owner\',
str(context.portal_membership.getAuthenticatedMember()
)]]
</string>
</value>
<value>
<string>
python: [[\'owner\',
context.portal_membership.getAuthenticatedMember().getId(
)]]
</string>
</value>
</item>
</dictionary>
</pickle>
...
...
bt5/erp5_run_my_doc/SkinTemplateItem/portal_skins/erp5_run_my_doc/Review_editAnnotationList.py
View file @
0eed9896
annotation_list
=
context
.
getAnnotation
().
split
(
'
\
n
'
);
user_name
=
context
.
getPortalObject
().
portal_membership
.
getAuthenticatedMember
()
user_name
=
context
.
getPortalObject
().
portal_membership
.
getAuthenticatedMember
()
.
getId
()
for
uid
in
listbox_uid
:
i
=
int
(
uid
)
old_comment
,
locator
,
context_url
,
author
,
color
=
annotation_list
[
i
][
1
:
-
1
].
split
(
"},{"
);
...
...
product/ERP5/bootstrap/erp5_core/ExtensionTemplateItem/portal_components/extension.erp5.SearchUtility.py
View file @
0eed9896
...
...
@@ -48,7 +48,7 @@ def recurseUpdateSyntaxNode(self, node):
elif node.isColumn():
if node.column_name == '
mine
':
node.column_name = '
owner
'
node.node.value = s
tr(self.portal_membership.getAuthenticatedMember()
)
node.node.value = s
elf.portal_membership.getAuthenticatedMember().getId(
)
elif node.column_name == '
state
' and node.node.value != '
all
':
node.column_name = '
simulation_state
'
elif node.column_name == '
type
' and node.node.value != '
all
':
...
...
product/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/template_erp5_xhtml_style.zpt
View file @
0eed9896
...
...
@@ -56,7 +56,7 @@ DEPRECATION:
<div
id=
"logged_in_as"
class=
"logged_in_as"
>
<tal:block
tal:condition=
"not: portal/portal_membership/isAnonymousUser"
>
<span
class=
"logged_txt"
i18n:translate=
""
i18n:domain=
"ui"
>
Logged In as :
</span>
<tal:block
tal:replace=
"python:portal.portal_membership.getAuthenticatedMember().get
UserName
()"
/>
<tal:block
tal:replace=
"python:portal.portal_membership.getAuthenticatedMember().get
Id
()"
/>
</tal:block>
</div>
<p
class=
"clear"
></p>
...
...
product/ERP5Form/Tool/SelectionTool.py
View file @
0eed9896
...
...
@@ -1425,7 +1425,7 @@ class SelectionTool( BaseTool, SimpleItem ):
user_id
=
tv
.
get
(
'_user_id'
,
None
)
if
user_id
is
not
None
:
return
user_id
user_id
=
self
.
portal_membership
.
getAuthenticatedMember
().
get
UserName
()
user_id
=
self
.
portal_membership
.
getAuthenticatedMember
().
get
Id
()
tv
[
'_user_id'
]
=
user_id
return
user_id
...
...
product/ERP5OOo/tests/testDms.py
View file @
0eed9896
...
...
@@ -2478,7 +2478,7 @@ return 1
document
.
publish
()
document
.
reject
()
document
.
share
()
logged_in_user
=
s
tr
(
self
.
portal
.
portal_membership
.
getAuthenticatedMember
()
)
logged_in_user
=
s
elf
.
portal
.
portal_membership
.
getAuthenticatedMember
().
getId
(
)
event_list
=
document
.
Base_getWorkflowEventInfoList
()
event_list
.
reverse
()
# all actions by logged in user
...
...
product/ERP5Type/tests/testCookieCrumbler.py
View file @
0eed9896
...
...
@@ -81,7 +81,7 @@ class ERP5CookieCrumblerTests (CookieCrumblerTests):
self
.
req
.
traverse
(
'/'
)
self
.
assert_
(
self
.
req
.
has_key
(
'AUTHENTICATED_USER'
))
self
.
assertEqual
(
self
.
req
[
'AUTHENTICATED_USER'
].
get
UserName
(),
self
.
assertEqual
(
self
.
req
[
'AUTHENTICATED_USER'
].
get
Id
(),
'abrahammmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm'
)
resp
=
self
.
req
.
response
self
.
assert_
(
resp
.
cookies
.
has_key
(
'__ac'
))
...
...
product/ERP5VCS/Subversion.py
View file @
0eed9896
...
...
@@ -112,8 +112,8 @@ class Subversion(WorkingCopy):
if
username
:
username
=
username
.
strip
()
return
(
username
or
# not set in preferences, then we get the current user
name
in zope
portal
.
portal_membership
.
getAuthenticatedMember
().
get
UserName
())
# not set in preferences, then we get the current user
id
in zope
portal
.
portal_membership
.
getAuthenticatedMember
().
get
Id
())
def
_getClient
(
self
,
**
kw
):
return
newSubversionClient
(
self
,
**
kw
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment