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
Léo-Paul Géneau
erp5
Commits
241f7b53
Commit
241f7b53
authored
Jan 16, 2023
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
BusinessTemplate: don't try to fix connection_id on ZSQL Method
This is just hiding problem and does not seem needed.
parent
d3b8c503
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
13 deletions
+0
-13
product/ERP5/Document/BusinessTemplate.py
product/ERP5/Document/BusinessTemplate.py
+0
-13
No files found.
product/ERP5/Document/BusinessTemplate.py
View file @
241f7b53
...
...
@@ -223,19 +223,6 @@ def removeAll(entry):
shutil
.
rmtree
(
entry
,
True
)
def
fixZSQLMethod
(
portal
,
method
):
"""Make sure the ZSQLMethod uses a valid connection.
"""
if
not
isinstance
(
getattr
(
portal
,
method
.
connection_id
,
None
),
RDBConnection
):
# if not valid, we assign to the first valid connection found
sql_connection_list
=
portal
.
objectIds
(
spec
=
(
'Z MySQL Database Connection'
,))
if
(
method
.
connection_id
not
in
sql_connection_list
)
and
\
(
len
(
sql_connection_list
)
!=
0
):
LOG
(
'BusinessTemplate'
,
WARNING
,
'connection_id for Z SQL Method %s is invalid, using %s'
%
(
method
.
getId
(),
sql_connection_list
[
0
]))
method
.
connection_id
=
sql_connection_list
[
0
]
# recompile the method
method
.
_arg
=
Aqueduct
.
parse
(
method
.
arguments_src
)
method
.
template
=
method
.
template_class
(
method
.
src
)
...
...
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