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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Tristan Cavelier
erp5
Commits
26187d69
Commit
26187d69
authored
Jun 28, 2012
by
Kazuhiko Shiozaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
escape '_' in like expression, that means '.' in regexp.
parent
237e7381
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
5 additions
and
5 deletions
+5
-5
product/ERP5/Document/SimulationMovement.py
product/ERP5/Document/SimulationMovement.py
+1
-1
product/ERP5/ExplanationCache.py
product/ERP5/ExplanationCache.py
+2
-2
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getRelatedDocumentList.xml
...em/portal_skins/erp5_core/Base_getRelatedDocumentList.xml
+1
-1
product/ERP5/bootstrap/erp5_core/bt/revision
product/ERP5/bootstrap/erp5_core/bt/revision
+1
-1
No files found.
product/ERP5/Document/SimulationMovement.py
View file @
26187d69
...
@@ -716,7 +716,7 @@ class SimulationMovement(PropertyRecordableMixin, Movement, ExplainableMixin):
...
@@ -716,7 +716,7 @@ class SimulationMovement(PropertyRecordableMixin, Movement, ExplainableMixin):
catalog_simulation_movement_list
=
portal_catalog
(
catalog_simulation_movement_list
=
portal_catalog
(
portal_type
=
'Simulation Movement'
,
portal_type
=
'Simulation Movement'
,
causality_uid
=
[
p
.
getUid
()
for
p
in
remaining_path_set
],
causality_uid
=
[
p
.
getUid
()
for
p
in
remaining_path_set
],
path
=
'%s/%%'
%
self
.
getPath
())
path
=
'%s/%%'
%
self
.
getPath
()
.
replace
(
'_'
,
r'\
_
')
)
for movement in catalog_simulation_movement_list:
for movement in catalog_simulation_movement_list:
path = movement.getCausalityValue()
path = movement.getCausalityValue()
...
...
product/ERP5/ExplanationCache.py
View file @
26187d69
...
@@ -137,7 +137,7 @@ class ExplanationCache:
...
@@ -137,7 +137,7 @@ class ExplanationCache:
if
not
isinstance
(
value
,
dict
):
if
not
isinstance
(
value
,
dict
):
# We have a real root
# We have a real root
result
.
append
(
'%s/%s'
%
(
prefix
,
key
))
result
.
append
(
'%s/%s'
%
(
prefix
,
key
))
result
.
append
(
'%s/%s/%%'
%
(
prefix
,
key
))
result
.
append
(
(
'%s/%s/%%'
%
(
prefix
,
key
)).
replace
(
'_'
,
r'\
_
'
))
# XXX-JPS here we must add all parent movements XXX-JPS
# XXX-JPS here we must add all parent movements XXX-JPS
else:
else:
browsePathDict('
%
s
/%
s
' % (prefix, key), value) # Recursing with string append is slow XXX-JPS
browsePathDict('
%
s
/%
s
' % (prefix, key), value) # Recursing with string append is slow XXX-JPS
...
@@ -262,7 +262,7 @@ class ExplanationCache:
...
@@ -262,7 +262,7 @@ class ExplanationCache:
if simulation_path.startswith(path):
if simulation_path.startswith(path):
# Only keep a path pattern which matches current simulation movement
# Only keep a path pattern which matches current simulation movement
path_set.add(path)
path_set.add(path)
path_set
.
add
(
"%s/%%"
%
path
)
path_set.add("%s/%%" % path
.replace('
_
', r'
\
_
')
)
# Lookup in cache based on path_tuple
# Lookup in cache based on path_tuple
path_tuple = tuple(path_set) # XXX-JPS is the order guaranteed here ?
path_tuple = tuple(path_set) # XXX-JPS is the order guaranteed here ?
...
...
product/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_getRelatedDocumentList.xml
View file @
26187d69
...
@@ -58,7 +58,7 @@ follow_up_related_document_list = portal_catalog(\n
...
@@ -58,7 +58,7 @@ follow_up_related_document_list = portal_catalog(\n
portal_type=portal_type,\n
portal_type=portal_type,\n
follow_up_uid=context.getUid(), **kw)\n
follow_up_uid=context.getUid(), **kw)\n
\n
\n
kw[\'query\'] = Query(relative_url=\'%s/%%\' % context.getRelativeUrl())\n
kw[\'query\'] = Query(relative_url=\'%s/%%\' % context.getRelativeUrl()
.replace(\'_\', r\'\\_\')
)\n
if follow_up_related_document_list:\n
if follow_up_related_document_list:\n
kw[\'query\'] = ComplexQuery(\n
kw[\'query\'] = ComplexQuery(\n
kw[\'query\'],\n
kw[\'query\'],\n
...
...
product/ERP5/bootstrap/erp5_core/bt/revision
View file @
26187d69
41041
41042
\ No newline at end of file
\ No newline at end of file
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