Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0018681Openbravo ERP01. General setuppublic2011-10-04 09:262011-10-18 10:26
jecharri 
egoitz 
urgentmajoralways
closedfixed 
5
2.50MP33.1 
2.50MP352.50MP35 
Google Chrome
Core
No
0018681: Alert recipient work different when you put only the role or user
Alert recipient work different when you put only the role or user.
When you put the role with the same client to the alert, all the user with this role receive an email (with the check of Send Email checked obiusly), it doesn't matter if the users are from different client.
But if you put an user and this user is from different client to the alert definition, this user doesn't receive any mail.
Create an alert:
-SQL:select c_invoice_id as referencekey_id,
       '0' as ad_role_id,
       null as ad_user_id,
       'esto es una prueba' as description,
       'Y' as isActive,
        ad_org_id,
        ad_client_id,
        now() as created,
        '0' as createdBy,
        now() as updated,
        '0' as updatedBy,
        ad_column_identifier('C_invoice', C_invoice_id, 'es_ES') AS RECORD_ID, posted
   FROM C_invoice
GROUP BY C_invoice_id, posted, ad_client_id, ad_org_id
order by c_invoice_id desc limit 2

Go to tab alert recipient and select Openbravo Admin.
Check the checkbox Send Email.
Execute the alert background porcess
See that all user of this role receive an email.
Now put Openbravo user like end user.
Run alert Process
You will not receive any mail.
In file AlertProcess_data.xsql delete the line:

and ar.ad_client_id = u.ad_client_id
No tags attached.
blocks defect 00186803.0MP5 closed egoitz Alert recipient work different when you put only the role or user 
Issue History
2011-10-04 09:28jecharriTypedefect => backport
2011-10-04 09:28jecharrifix_in_branch => 2.50
2011-10-04 09:28jecharriWeb browserGoogle Chrome => Google Chrome
2011-10-04 09:28jecharriversionpi => 2.50MP33.1
2011-10-04 09:28jecharriTarget Version3.0MP5 => 2.50MP35
2011-10-04 10:43jonalegriaesarteAssigned Tojonalegriaesarte => ioritzCia
2011-10-13 12:38egoitzWeb browserGoogle Chrome => Google Chrome
2011-10-13 12:38egoitzAssigned ToioritzCia => egoitz
2011-10-13 13:22hgbotCheckin
2011-10-13 13:22hgbotNote Added: 0041798
2011-10-13 13:22hgbotStatusscheduled => resolved
2011-10-13 13:22hgbotResolutionopen => fixed
2011-10-13 13:22hgbotFixed in SCM revision => http://code.openbravo.com/erp/stable/2.50/rev/0cf9c43e77d8a4c782b5312d78b66e3caf184f4f [^]
2011-10-18 10:26jecharriNote Added: 0041875
2011-10-18 10:26jecharriStatusresolved => closed
2011-10-18 10:26jecharriFixed in Version => 2.50MP35

Notes
(0041798)
hgbot   
2011-10-13 13:22   
Repository: erp/stable/2.50
Changeset: 0cf9c43e77d8a4c782b5312d78b66e3caf184f4f
Author: Egoitz Castillo <egoitz.castillo <at> openbravo.com>
Date: Thu Oct 13 12:29:27 2011 +0200
URL: http://code.openbravo.com/erp/stable/2.50/rev/0cf9c43e77d8a4c782b5312d78b66e3caf184f4f [^]

Fixed Issue 18681. Alerts by mail work different defining role or user

---
M src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql
---
(0041875)
jecharri   
2011-10-18 10:26   
verified