[6.0] CRM - Cannot send multiple times the same attachment through email

Bug #730632 reported by Jacques-Etienne Baudoux
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Fix Released
Low
OpenERP R&D Addons Team 1

Bug Description

Hi,
In Sales->CRM->Leads->Communication&History->Send New Email, you cannot send twice the same attachment because the attachment name (by default filename) must be unique. Moreover, the error message in OpenERP is empty. You need to modify the name of the attachment to something not existing yet.
The attachment name is unique and it should not be the filename but something more complicate that will be unique.

  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/netsvc.py(489)dispatch()
-> result = ExportService.getService(service_name).dispatch(method, auth, params)
  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/service/web_services.py(599)dispatch()
-> res = fn(db, uid, *params)
  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/osv/osv.py(128)wrapper()
-> self.abortResponse(1, inst.name, inst.exc_type, inst.value)
  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/osv/osv.py(122)wrapper()
-> return f(self, dbname, *args, **kwargs)
  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/osv/osv.py(176)execute()
-> res = self.execute_cr(cr, uid, obj, method, *args, **kw)
  /home/jbaudoux/OpenERP/preview/src/6.0/server-727263/bin/osv/osv.py(167)execute_cr()
-> return getattr(object, method)(cr, uid, *args, **kw)
  /home/jbaudoux/OpenERP/preview/src/6.0/addons/crm/wizard/crm_send_email.py(148)action_send()
-> references=ref_id or message_id, attach=attach)
  /home/jbaudoux/OpenERP/preview/src/6.0/addons/mail_gateway/mail_gateway.py(131)history()
-> attachments.append(att_obj.create(cr, uid, {'res_model':case._name,'res_id':case.id,'name': att[0], 'datas': base64.encodestring(att[1])}))
> /home/jbaudoux/OpenERP/preview/src/6.0/addons/document/document.py(283)create()
-> raise osv.except_osv(_('ValidateError'), _('File name must be unique!'))

Tags: profserv

Related branches

tags: added: profserv
Revision history for this message
Azazahmed Saiyed (OpenERP) (saz-openerp) wrote :

Hello,

I am confirming the issue as one is able to send the mail with same attachment name despite the osv exception and we did get the traceback on client side every time when exception raised.

If we have to allow the user to send the email with same attachment name, then there should not be any exception like "File name must be unique".

Thanks.

Changed in openobject-addons:
assignee: nobody → OpenERP R&D Addons Team 1 (openerp-dev-addons1)
importance: Undecided → Low
status: New → Confirmed
Changed in openobject-addons:
status: Confirmed → In Progress
Revision history for this message
Ujjvala Collins (uco-openerp) wrote :

Hello,

The fix has been committed on: lp:~openerp-dev/openobject-addons/trunk-bug-730632-uco with revision: 4488.

Soon, it'll be merged into trunk-addons.

Thanks.

Changed in openobject-addons:
status: In Progress → Fix Committed
tfr (Openerp) (tfr)
Changed in openobject-addons:
status: Fix Committed → Fix Released
Revision history for this message
Eric Caudal - www.elico-corp.com (elicoidal) wrote :

Is this patch already available?
Could you tell me where is it so I can update main branch while new minor release is available?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.