details:   https://code.openbravo.com/erp/stable/2.50/rev/ca6ddcd6f1e3
changeset: 9691:ca6ddcd6f1e3
user:      Egoitz Castillo <egoitz.castillo <at> openbravo.com>
date:      Thu Oct 13 12:27:55 2011 +0200
summary:   Fixed Issue 18683. The trigger on alertrule not working properly

details:   https://code.openbravo.com/erp/stable/2.50/rev/0cf9c43e77d8
changeset: 9692:0cf9c43e77d8
user:      Egoitz Castillo <egoitz.castillo <at> openbravo.com>
date:      Thu Oct 13 12:29:27 2011 +0200
summary:   Fixed Issue 18681.  Alerts by mail work different defining role or 
user

details:   https://code.openbravo.com/erp/stable/2.50/rev/2827c629c5dc
changeset: 9693:2827c629c5dc
user:      Egoitz Castillo <egoitz.castillo <at> openbravo.com>
date:      Thu Oct 13 13:16:32 2011 +0200
summary:   Fixed Issue 18685. Avoid selecting roles for other clients as 
AlerRecipient

diffstat:

 src-db/database/model/triggers/AD_ALERTRULE_TRG.xml           |  2 +-
 src-db/database/sourcedata/AD_COLUMN.xml                      |  1 +
 src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql |  1 -
 3 files changed, 2 insertions(+), 2 deletions(-)

diffs (34 lines):

diff -r 1ea372403f86 -r 2827c629c5dc 
src-db/database/model/triggers/AD_ALERTRULE_TRG.xml
--- a/src-db/database/model/triggers/AD_ALERTRULE_TRG.xml       Thu Oct 13 
09:52:56 2011 +0200
+++ b/src-db/database/model/triggers/AD_ALERTRULE_TRG.xml       Thu Oct 13 
13:16:32 2011 +0200
@@ -55,7 +55,7 @@
       --insert permissions
       FOR Cur_Role in (SELECT DISTINCT AD_Role_ID, AD_CLIENT_ID, AD_ORG_ID
                         FROM AD_Role
-                       WHERE isManual='N') loop
+                       WHERE isManual='N' and 
ad_role.ad_client_id=:new.AD_Client_ID) loop
         Ad_Sequence_Next('AD_AlertRecipient', Cur_Role.AD_Org_Id, 
recipient_id) ;
         INSERT INTO AD_AlertRecipient
             (AD_AlertRule_ID, AD_Role_ID, AD_Client_ID,
diff -r 1ea372403f86 -r 2827c629c5dc src-db/database/sourcedata/AD_COLUMN.xml
--- a/src-db/database/sourcedata/AD_COLUMN.xml  Thu Oct 13 09:52:56 2011 +0200
+++ b/src-db/database/sourcedata/AD_COLUMN.xml  Thu Oct 13 13:16:32 2011 +0200
@@ -249683,6 +249683,7 @@
 <!--803851-->  <COLUMNNAME><![CDATA[AD_Role_ID]]></COLUMNNAME>
 <!--803851-->  <AD_TABLE_ID><![CDATA[592]]></AD_TABLE_ID>
 <!--803851-->  <AD_REFERENCE_ID><![CDATA[19]]></AD_REFERENCE_ID>
+<!--803851-->  <AD_VAL_RULE_ID><![CDATA[158]]></AD_VAL_RULE_ID>
 <!--803851-->  <FIELDLENGTH><![CDATA[12]]></FIELDLENGTH>
 <!--803851-->  <ISKEY><![CDATA[N]]></ISKEY>
 <!--803851-->  <ISPARENT><![CDATA[N]]></ISPARENT>
diff -r 1ea372403f86 -r 2827c629c5dc 
src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql
--- a/src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql     Thu Oct 
13 09:52:56 2011 +0200
+++ b/src/org/openbravo/erpCommon/ad_process/AlertProcess_data.xsql     Thu Oct 
13 13:16:32 2011 +0200
@@ -162,7 +162,6 @@
                u.email as mailto, c.ad_language, c.ad_client_id
           from ad_alertrecipient  ar, ad_user u, ad_client c
           where ar.ad_alertrule_id = ?
-            and ar.ad_client_id = u.ad_client_id
             and u.ad_client_id = c.ad_client_id
             and ar.ad_user_id = u.ad_user_id
             and c.requestuser is not null

------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2d-oct
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to