mirror of
https://github.com/OCA/pms.git
synced 2025-01-29 00:17:45 +02:00
[FIX] pms_api_rest: fix date format
This commit is contained in:
committed by
Darío Lodeiros
parent
1f808d6a43
commit
55e258abf7
@@ -206,10 +206,7 @@ class PmsTransactionService(Component):
|
||||
auth="jwt_api_pms",
|
||||
)
|
||||
def create_transaction(self, pms_transaction_info):
|
||||
# TODO: FIX fron send data format ('%Y-%m-%d')
|
||||
# use fields.Date.from_string(pms_transaction_info.date)
|
||||
pay_date_wrong_format = pms_transaction_info.date
|
||||
pay_date = datetime.strptime(pay_date_wrong_format, "%m/%d/%Y")
|
||||
pay_date = fields.Date.from_string(pms_transaction_info.date)
|
||||
payment_type, partner_type = self._get_mapper_transaction_type(
|
||||
pms_transaction_info.transactionType
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user