For all tickets:
--- notificationtargetticket.class.php.orig 2012-12-17 23:14:50.210300890
+0100
+++ notificationtargetticket.class.php 2012-12-21 11:04:35.035306071 +0100
@@ -247,6 +247,30 @@
// is ticket deleted
$datas['##ticket.isdeleted##'] =
Dropdown::getYesNo($item->getField('is_deleted'));
+ // Tickets status infos
+
+ $restrict = " `is_deleted` = '0' AND `status` != 'closed' AND `status` !=
'resolved' ";
+ $tickets = getAllDatasFromTable('glpi_tickets',$restrict);
+
+ $datas['tickets'] = array();
+ if (count($tickets)) {
+ $ticket = new Ticket();
+
+ foreach ($tickets as $ticket) {
+ $tmp = array();
+ $datas['tickets'][] = $tmp;
+ }
+ }
+
+ $datas['##ticket.number.of.unresolved.tickets##'] = 0;
+ if (!empty($datas['tickets'])) {
+ $datas['##ticket.number.of.unresolved.tickets##'] =
count($datas['tickets']);
+ }
+
+
//Tags associated with the object linked to the ticket
$datas['##ticket.itemtype##'] = '';
2012/12/18 Julien Dombre <[email protected]>
> Le 18/12/2012 13:37, Julien Dombre a écrit :
>
> Le 18/12/2012 13:31, wolvverine a écrit :
>
> No, it is not solution. In the new notification of ticket, I must add
> field: "Which is the ticket in a queue".
>
>
> Sorry I do not understand your request and aim.
>
>
> I forward a direct answer :
> J must add information in first notification about new ticket: "What is
> the position of the ticket in a queue"
> number of all open tickets in this moment
>
> My answer to this one :
> Trouble is to know for which entities we need to compute this value.
> We also could do it for the entity of the ticket but it may not be the
> right value you want.
>
> Regards
>
> Julien Dombre
>
>
> _______________________________________________
> Glpi-dev mailing list
> [email protected]
> https://mail.gna.org/listinfo/glpi-dev
>
>
_______________________________________________
Glpi-dev mailing list
[email protected]
https://mail.gna.org/listinfo/glpi-dev