summaryrefslogtreecommitdiff
path: root/addons/web
diff options
context:
space:
mode:
authorxmo-odoo <xmo-odoo@users.noreply.github.com>2014-06-17 15:56:53 +0200
committerxmo-odoo <xmo-odoo@users.noreply.github.com>2014-06-17 15:56:53 +0200
commit02677579d2171f38b228e13b0edbef09d4e4e4bb (patch)
tree009589d10618159101590b867092e3dd4674f20a /addons/web
parentc949509b5ee9f81f80bc5a55eaecad48f1923e48 (diff)
parent25ca967b9785eca27777c8a2577669ce1f6e0d79 (diff)
Merge pull request #590 from xmo-odoo/master-public-binary-xmo
Make attachment data available under public by default
Diffstat (limited to 'addons/web')
-rw-r--r--addons/web/controllers/main.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/addons/web/controllers/main.py b/addons/web/controllers/main.py
index 5b2c7a5e91a..98f65075922 100644
--- a/addons/web/controllers/main.py
+++ b/addons/web/controllers/main.py
@@ -1114,7 +1114,7 @@ class TreeView(View):
class Binary(http.Controller):
- @http.route('/web/binary/image', type='http', auth="user")
+ @http.route('/web/binary/image', type='http', auth="public")
def image(self, model, id, field, **kw):
last_update = '__last_update'
Model = request.session.model(model)
@@ -1169,7 +1169,7 @@ class Binary(http.Controller):
addons_path = http.addons_manifest['web']['addons_path']
return open(os.path.join(addons_path, 'web', 'static', 'src', 'img', image), 'rb').read()
- @http.route('/web/binary/saveas', type='http', auth="user")
+ @http.route('/web/binary/saveas', type='http', auth="public")
@serialize_exception
def saveas(self, model, field, id=None, filename_field=None, **kw):
""" Download link for files stored as binary fields.
@@ -1203,7 +1203,7 @@ class Binary(http.Controller):
[('Content-Type', 'application/octet-stream'),
('Content-Disposition', content_disposition(filename))])
- @http.route('/web/binary/saveas_ajax', type='http', auth="user")
+ @http.route('/web/binary/saveas_ajax', type='http', auth="public")
@serialize_exception
def saveas_ajax(self, data, token):
jdata = simplejson.loads(data)