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
Carlos Ramos Carreño
erp5
Commits
e4261ba1
Commit
e4261ba1
authored
Oct 28, 2014
by
Kazuhiko Shiozaki
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use '=' comparison operator explicitly in title search.
parent
7e7f6adb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
4 deletions
+5
-4
bt5/erp5_accounting_ui_test/SkinTemplateItem/portal_skins/erp5_accounting_ui_test/AccountingZuite_createAccountingTransactionList.xml
..._test/AccountingZuite_createAccountingTransactionList.xml
+5
-4
No files found.
bt5/erp5_accounting_ui_test/SkinTemplateItem/portal_skins/erp5_accounting_ui_test/AccountingZuite_createAccountingTransactionList.xml
View file @
e4261ba1
...
@@ -53,6 +53,7 @@
...
@@ -53,6 +53,7 @@
<value>
<string
encoding=
"cdata"
>
<![CDATA[
<value>
<string
encoding=
"cdata"
>
<![CDATA[
from DateTime import DateTime\n
from DateTime import DateTime\n
from Products.ZSQLCatalog.SQLCatalog import SimpleQuery\n
\n
\n
# params\n
# params\n
section_title = \'My Organisation\'\n
section_title = \'My Organisation\'\n
...
@@ -90,7 +91,7 @@ if 1:\n
...
@@ -90,7 +91,7 @@ if 1:\n
def getAccountByTitle(title):\n
def getAccountByTitle(title):\n
account_list = [x.getObject().getRelativeUrl() for x in\n
account_list = [x.getObject().getRelativeUrl() for x in\n
portal.portal_catalog(portal_type=\'Account\',\n
portal.portal_catalog(portal_type=\'Account\',\n
title=
title
)]\n
title=
SimpleQuery(title=title, comparison_operator=\'=\')
)]\n
assert len(account_list) == 1, \\\n
assert len(account_list) == 1, \\\n
\'%d account with title "%s"\' % (len(account_list), title)\n
\'%d account with title "%s"\' % (len(account_list), title)\n
return account_list[0]\n
return account_list[0]\n
...
@@ -98,7 +99,7 @@ def getAccountByTitle(title):\n
...
@@ -98,7 +99,7 @@ def getAccountByTitle(title):\n
def getOrganisationByTitle(title):\n
def getOrganisationByTitle(title):\n
document_list = [x.getObject().getRelativeUrl() for x in\n
document_list = [x.getObject().getRelativeUrl() for x in\n
portal.portal_catalog(portal_type=\'Organisation\',\n
portal.portal_catalog(portal_type=\'Organisation\',\n
title=
title
)]\n
title=
SimpleQuery(title=title, comparison_operator=\'=\')
)]\n
assert len(document_list) == 1, \\\n
assert len(document_list) == 1, \\\n
\'%d organisation with title "%s"\' % (len(document_list), title)\n
\'%d organisation with title "%s"\' % (len(document_list), title)\n
return document_list[0]\n
return document_list[0]\n
...
@@ -109,14 +110,14 @@ euro_resource = \'currency_module/euro\'\n
...
@@ -109,14 +110,14 @@ euro_resource = \'currency_module/euro\'\n
def getBankAccountByTitle(title):\n
def getBankAccountByTitle(title):\n
document_list = [x.getObject().getRelativeUrl() for x in\n
document_list = [x.getObject().getRelativeUrl() for x in\n
portal.portal_catalog(portal_type=\'Bank Account\',\n
portal.portal_catalog(portal_type=\'Bank Account\',\n
title=
title
)]\n
title=
SimpleQuery(title=title, comparison_operator=\'=\')
)]\n
assert len(document_list) == 1, \\\n
assert len(document_list) == 1, \\\n
\'%d Bank Account with title "%s"\' % (len(document_list), title)\n
\'%d Bank Account with title "%s"\' % (len(document_list), title)\n
return document_list[0]\n
return document_list[0]\n
\n
\n
product_list = [o.getObject() for o in portal.portal_catalog(\n
product_list = [o.getObject() for o in portal.portal_catalog(\n
portal_type=\'Product\',\n
portal_type=\'Product\',\n
title=
\'Dummy Product for testing\'
)]\n
title=
SimpleQuery(title=\'Dummy Product for testing\', comparison_operator=\'=\')
)]\n
if product_list:\n
if product_list:\n
product = product_list[0]\n
product = product_list[0]\n
else:\n
else:\n
...
...
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