Merge lp:~fabien-morin/unifield-web/fm-us-1174 into lp:unifield-web

Proposed by jftempo
Status: Merged
Merged at revision: 4788
Proposed branch: lp:~fabien-morin/unifield-web/fm-us-1174
Merge into: lp:unifield-web
Diff against target: 27 lines (+3/-2)
2 files modified
addons/openerp/controllers/attachment.py (+1/-0)
addons/openerp/widgets/form/templates/binary.mako (+2/-2)
To merge this branch: bzr merge lp:~fabien-morin/unifield-web/fm-us-1174
Reviewer Review Type Date Requested Status
UniField Reviewer Team Pending
Review via email: mp+295164@code.launchpad.net
To post a comment you must log in.
4787. By jftempo

US-1052 [FIX] PO Simulation Screen: "Loading..." does not stop to be displayed

lp:~fabien-morin/unifield-web/fm-us-1052

4788. By jftempo

US-1174 [IMP] Disable button to download attachment in not editable mode

lp:~fabien-morin/unifield-web/fm-us-1174

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'addons/openerp/controllers/attachment.py'
2--- addons/openerp/controllers/attachment.py 2011-01-17 11:57:11 +0000
3+++ addons/openerp/controllers/attachment.py 2016-05-19 07:09:16 +0000
4@@ -74,6 +74,7 @@
5
6 attachment_id = rpc.RPCProxy('ir.attachment').create({
7 'name': datas.filename,
8+ 'datas_fname': datas.filename,
9 'datas': base64.encodestring(datas.file.read()),
10 }, ctx)
11 return {'id': attachment_id, 'name': datas.filename}
12
13=== modified file 'addons/openerp/widgets/form/templates/binary.mako'
14--- addons/openerp/widgets/form/templates/binary.mako 2015-03-19 10:57:09 +0000
15+++ addons/openerp/widgets/form/templates/binary.mako 2016-05-19 07:09:16 +0000
16@@ -25,9 +25,9 @@
17 %if value:
18 <input type="hidden" name="${name}" value="${value}"></input>
19 % endif
20- % if text and model == 'ir.attachment' and ctx != 'usb_synchronization':
21+ % if text and model == 'ir.attachment' and ctx != 'usb_synchronization' and editable:
22 <a class="button-a" href="javascript: void(0)" onclick="save_binary_data('${name}', '${filename}')">${_("Open donation certificate")}</a>
23- % elif text:
24+ % elif text and editable:
25 <a class="button-a" href="javascript: void(0)" onclick="save_binary_data('${name}', '${filename}')">${_("Save As")}</a>
26 % endif
27 % if editable and not readonly:

Subscribers

People subscribed via source and target branches