Browse Source

publish muk_web_utils - 12.0

pull/115/head
MuK IT GmbH 5 years ago
parent
commit
63d4e3d62f
  1. 2
      muk_web_utils/__manifest__.py
  2. 1
      muk_web_utils/controllers/attachment.py

2
muk_web_utils/__manifest__.py

@ -20,7 +20,7 @@
{
"name": "MuK Web Utils",
"summary": """Utility Features""",
"version": "12.0.2.9.1",
"version": "12.0.2.9.2",
"category": "Extra Tools",
"license": "AGPL-3",
"author": "MuK IT",

1
muk_web_utils/controllers/attachment.py

@ -32,6 +32,7 @@ class AttachmentController(http.Controller):
@http.route('/utils/attachment/add', type='http', auth="user", methods=['POST'])
def add_attachment(self, ufile, temporary=False, **kw):
tmp = temporary and str2bool(temporary) or False
name = "Access Attachment: %s" % ufile.filename
attachment = request.env['ir.attachment'].create({
'name': tmp and "%s (Temporary)" % name or name,
'datas': base64.b64encode(ufile.read()),

Loading…
Cancel
Save