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
82115e56
Commit
82115e56
authored
Oct 25, 2011
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not convert dates.
In case of navigate the caller is responsible for providing date as text string.
parent
d09f5528
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
6 deletions
+4
-6
bt5/erp5_payzen_secure_payment/DocumentTemplateItem/PayzenService.py
...yzen_secure_payment/DocumentTemplateItem/PayzenService.py
+3
-5
bt5/erp5_payzen_secure_payment/bt/revision
bt5/erp5_payzen_secure_payment/bt/revision
+1
-1
No files found.
bt5/erp5_payzen_secure_payment/DocumentTemplateItem/PayzenService.py
View file @
82115e56
...
@@ -186,8 +186,7 @@ class PayzenService(XMLObject, PayzenSOAP):
...
@@ -186,8 +186,7 @@ class PayzenService(XMLObject, PayzenSOAP):
"""See Payment Service Interface Documentation"""
"""See Payment Service Interface Documentation"""
pass
pass
def
_getSignature
(
self
,
ob
,
sorted_key_list
,
def
_getSignature
(
self
,
ob
,
sorted_key_list
):
output_date_format
=
'%Y-%m-%dT%H:%M:%S'
,
signature_date_format
=
'%Y%m%d'
):
"""Calculates signature from ob
"""Calculates signature from ob
ob can be dict or getattr capable object
ob can be dict or getattr capable object
...
@@ -211,7 +210,7 @@ class PayzenService(XMLObject, PayzenSOAP):
...
@@ -211,7 +210,7 @@ class PayzenService(XMLObject, PayzenSOAP):
v
=
''
v
=
''
elif
isinstance
(
v
,
datetime
.
datetime
):
elif
isinstance
(
v
,
datetime
.
datetime
):
# for sure date
# for sure date
v
=
v
.
strftime
(
signature_date_format
)
v
=
v
.
strftime
(
'%Y%m%d'
)
else
:
else
:
# anything else cast to string
# anything else cast to string
v
=
str
(
v
)
v
=
str
(
v
)
...
@@ -230,8 +229,7 @@ class PayzenService(XMLObject, PayzenSOAP):
...
@@ -230,8 +229,7 @@ class PayzenService(XMLObject, PayzenSOAP):
vads_version
=
self
.
getPayzenVadsVersion
()
vads_version
=
self
.
getPayzenVadsVersion
()
)
)
# fetch all prepared vads_ values and remove them from dict
# fetch all prepared vads_ values and remove them from dict
signature
=
self
.
_getSignature
(
payzen_dict
,
signature
=
self
.
_getSignature
(
payzen_dict
,
sorted
(
payzen_dict
.
keys
()))
sorted
(
payzen_dict
.
keys
()),
'%Y%m%d%H%M%S'
,
'%Y%m%d%H%M%S'
)
payzen_dict
[
'signature'
]
=
signature
payzen_dict
[
'signature'
]
=
signature
field_list
=
[]
field_list
=
[]
for
k
,
v
in
payzen_dict
.
iteritems
():
for
k
,
v
in
payzen_dict
.
iteritems
():
...
...
bt5/erp5_payzen_secure_payment/bt/revision
View file @
82115e56
42
43
\ 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