0001-backoffice-display-correct-method-for-webservice-cal.patch
tests/admin_pages/test_wscall.py | ||
---|---|---|
88 | 88 |
app = login(get_app(pub)) |
89 | 89 |
resp = app.get('/backoffice/settings/wscalls/%s/' % wscall.id) |
90 | 90 |
assert 'http://remote.example.net/json' in resp.text |
91 |
assert 'Method: POST' in resp.text |
|
92 | ||
93 |
wscall.request['method'] = 'PATCH' |
|
94 |
wscall.store() |
|
95 |
resp = app.get('/backoffice/settings/wscalls/%s/' % wscall.id) |
|
96 |
assert 'Method: PATCH' in resp.text |
|
91 | 97 | |
92 | 98 | |
93 | 99 |
def test_wscalls_edit(pub, wscall): |
wcs/templates/wcs/backoffice/wscall.html | ||
---|---|---|
17 | 17 |
<div class="bo-block"> |
18 | 18 |
<h3>{% trans "Parameters" %}</h3> |
19 | 19 |
<ul> |
20 |
<li>{% trans "Method:" %} {% if wscall.request.method == 'POST' %}POST{% else %}GET{% endif %}</li>
|
|
20 |
<li>{% trans "Method:" %} {{ wscall.request.method|default:"GET" }}</li>
|
|
21 | 21 |
{% if wscall.request.url %}<li>{% trans "URL:" %} {{ wscall.request.url }}</li>{% endif %} |
22 | 22 |
{% if wscall.request.qs_data %} |
23 | 23 |
<li>{% trans "Query string data:" %} |
24 |
- |