Differences

This shows you the differences between two versions of the page.

documentation:latest:notifications [2012/05/24 17:07]
fxdeltombe
documentation:latest:notifications [2012/10/04 09:15] (current)
kharec We activate notification by default in 1.2.2
Line 14: Line 14:
notification = 1 notification = 1
</file> </file>
 +
 +Since the 1.2.2 version, notifications are enable by default.
 +
==== Storage ==== ==== Storage ====
Line 52: Line 55:
  xml longblob NOT NULL,   xml longblob NOT NULL,
  done datetime DEFAULT NULL,   done datetime DEFAULT NULL,
-  PRIMARY KEY (uid,ref, date)+  PRIMARY KEY (date, uid,ref)
) )
</code> </code>
Line 129: Line 132:
When all is ok, click on ''Create''. When all is ok, click on ''Create''.
-==== Create new notifications trough SOAP ====+==== Notifications trough SOAP ====
New notifications can be insert using SOAP request (described in the WSDL file generated by buildPortalWSDL tool). To activate SOAP on the portal: New notifications can be insert using SOAP request (described in the WSDL file generated by buildPortalWSDL tool). To activate SOAP on the portal:
Line 176: Line 179:
} }
</code> </code>
 +
 +You can also delete some notifications with SOAP, once SOAP is activated:
 +
 +=== Deletion example in Perl ===
 +
 +<code perl>
 +#!/usr/bin/perl
 +
 +use SOAP::Lite;
 +use utf8;
 +
 +my $lite = SOAP::Lite
 +        ->uri('urn:Lemonldap::NG::Common::CGI::SOAPService')
 +        ->proxy('http://auth.example.com/index.pl/notification');
 +
 +
 +$r = $lite->deleteNotification('foo.bar', 'ABC');
 +
 +if ( $r->fault ) {
 +    print STDERR "SOAP Error: " . $r->fault->{faultstring};
 +}
 +else {
 +    my $res = $r->result();
 +    print "$res notification(s) have been deleted\n";
 +}
 +</code>
 +
==== Test notification ==== ==== Test notification ====
Line 184: Line 214:
Try also to create a global notification (to the uid "allusers"), and connect with any user, the message will be prompted. Try also to create a global notification (to the uid "allusers"), and connect with any user, the message will be prompted.
 +