11.0 qr payments#1109
Closed
KolushovAlexandr wants to merge 69 commits into
Closed
Conversation
added 24 commits
July 3, 2018 16:11
i.e. use wechat as dependency, without pos_payment. pos_payment_wechat will work only with invoices
| data['body'] = message['data']['order_short'] | ||
|
|
||
| data['out_trade_no'] = (str(time.time()).replace('.', '') \ | ||
| + '{0:010}'.format(random.randint(1, 9999999999)) \ |
There was a problem hiding this comment.
continuation line under-indented for visual indent
the backslash is redundant between brackets
| data['mch_id'] = request.env['ir.config_parameter'].get_param('wechat.mchId') | ||
| data['body'] = message['data']['order_short'] | ||
|
|
||
| data['out_trade_no'] = (str(time.time()).replace('.', '') \ |
There was a problem hiding this comment.
the backslash is redundant between brackets
| import logging | ||
| import requests | ||
| import odoo | ||
| import json |
cb24c13 to
26e8a69
Compare
itpp-bot
reviewed
Dec 6, 2019
Contributor
itpp-bot
left a comment
There was a problem hiding this comment.
5 installable modules are updated:
├─ payment_wechat/
| ├─ README.rst
| ├─ __init__.py
| ├─ __manifest__.py
| ├─ controllers/
| | ├─ __init__.py
| | └─ p_w_controllers.py
| ├─ demo/
| | └─ w_p_demo.xml
| ├─ doc/
| | ├─ changelog.rst
| | └─ index.rst
| ├─ models/
| | ├─ __init__.py
| | └─ wechat_models.py
| ├─ static/
| | └─ description/
| | └─ icon.png
| └─ views/
| └─ views.xml
├─ pos_payment/
| ├─ README.rst
| ├─ __init__.py
| ├─ __manifest__.py
| ├─ doc/
| | ├─ changelog.rst
| | └─ index.rst
| └─ static/
| └─ description/
| └─ icon.png
├─ pos_qr_scan/
| ├─ README.rst
| ├─ __init__.py
| ├─ __manifest__.py
| ├─ doc/
| | ├─ changelog.rst
| | └─ index.rst
| ├─ static/
| | ├─ lib/
| | | └─ jsqrcode/
| | | ├─ COPYING
| | | ├─ README
| | | ├─ alignpat.js
| | | ├─ bitmat.js
| | | ├─ bmparser.js
| | | ├─ datablock.js
| | | ├─ databr.js
| | | ├─ datamask.js
| | | ├─ decoder.js
| | | ├─ detector.js
| | | ├─ errorlevel.js
| | | ├─ findpat.js
| | | ├─ formatinf.js
| | | ├─ gf256.js
| | | ├─ gf256poly.js
| | | ├─ grid.js
| | | ├─ qrcode.js
| | | ├─ rsdecoder.js
| | | └─ version.js
| | └─ src/
| | ├─ css/
| | | └─ pos.css
| | ├─ description/
| | | └─ icon.png
| | ├─ js/
| | | └─ qr_scan.js
| | └─ xml/
| | └─ templates.xml
| └─ views/
| └─ assets.xml
├─ pos_wechat/
| ├─ README.rst
| ├─ __init__.py
| ├─ __manifest__.py
| ├─ data/
| | └─ account_journal_data.xml
| ├─ doc/
| | ├─ changelog.rst
| | └─ index.rst
| ├─ models/
| | ├─ __init__.py
| | ├─ account_journal.py
| | └─ wechat_micropay.py
| ├─ static/
| | ├─ description/
| | | └─ icon.png
| | └─ src/
| | └─ js/
| | ├─ tour.js
| | └─ wechat_pay.js
| ├─ tests/
| | ├─ __init__.py
| | └─ test_micropay.py
| └─ views/
| └─ assets.xml
└─ wechat/
├─ README.rst
├─ __init__.py
├─ __manifest__.py
├─ controllers/
| ├─ __init__.py
| └─ wechat_controllers.py
├─ doc/
| ├─ changelog.rst
| └─ index.rst
├─ models/
| ├─ __init__.py
| ├─ ir_config_parameter.py
| ├─ wechat_micropay.py
| └─ wechat_order.py
├─ tests/
| ├─ __init__.py
| └─ test_wechat_order.py
├─ tools/
| ├─ __init__.py
| └─ async.py
└─ views/
└─ wechat_micropay_views.xml
Not installable modules remain unchanged.
sent by ✌️ Odoo Review Bot
| `1.0.0` | ||
| ------- | ||
|
|
||
| - Init version |
| `1.0.0` | ||
| ------- | ||
|
|
||
| - Init version |
| `1.0.0` | ||
| ------- | ||
|
|
||
| - Init version |
| `1.0.0` | ||
| ------- | ||
|
|
||
| - Init version |
| `1.0.0` | ||
| ------- | ||
|
|
||
| - Init version |
| try: | ||
| # python 3 | ||
| return method.__self__ | ||
| except: |
| import threading | ||
|
|
||
|
|
||
| from odoo import api, tools |
| ] | ||
|
|
||
|
|
||
| def _patch_post(self, post_result): |
| 'result_code': 'SUCCESS', | ||
| 'openid': '123', | ||
| 'total_fee': total_fee, | ||
| 'order_ref': order_ref, |
| # Try to compute url automatically | ||
| try: | ||
| scheme = request.httprequest.scheme | ||
| except: |
|
|
||
| from odoo.tests.common import HttpCase, HOST, PORT, get_db_name | ||
| from odoo import api, SUPERUSER_ID | ||
| from odoo.addons.bus.models.bus import dispatch |
There was a problem hiding this comment.
'odoo.addons.bus.models.bus.dispatch' imported but unused
| # Copyright 2018 Ivan Yelizariev <https://it-projects.info/team/yelizariev> | ||
| # License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl.html). | ||
| import logging | ||
| import json |
| 'terminal_ref': terminal_ref, | ||
| 'pos_id': pos_id, | ||
| }, | ||
| }) |
| // TODO: do we need to extend init_from_JSON too ? | ||
| export_as_JSON: function(){ | ||
| var res = PaymentlineSuper.prototype.export_as_JSON.apply(this, arguments); | ||
| res['micropay_id'] = this.micropay_id; |
There was a problem hiding this comment.
['micropay_id'] is better written in dot notation.
| micropay_id: msg['micropay_id'], | ||
| cashregister: this.wechat_cashregister, | ||
| pos: this}); | ||
| newPaymentline.set_amount( msg['total_fee'] / 100.0 ); |
There was a problem hiding this comment.
['total_fee'] is better written in dot notation.
Contributor
Author
|
superseded by https://github.com/it-projects-llc/pos-addons/pull/1181 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.