Thread: [Arsperl-users] change status and write on diary
Brought to you by:
jeffmurphy
|
From: Paizo <pai...@gm...> - 2007-05-15 12:40:13
|
Hi Listeners, I would like to know how to modify a trouble ticket, for example change its status and write some lines on the diary field of the note. I didn't find examples about this, can you give some hints please? Thank you for your help, Paizo -- CFAH3 CUT-LASS |
|
From: Jeff M. <jcm...@je...> - 2007-05-15 14:02:18
|
Paizo wrote:
> Hi Listeners,
>
> I would like to know how to modify a trouble ticket, for example change
> its status and write some lines on the diary field of the note. I didn't
> find examples about this, can you give some hints please?
>
Off the top of my head..
$c = ars_Login(server, user, pass);
%t = ars_GetFieldTable($c, "Form Name");
ars_SetEntry($c, "Form Name", $t{'Status'}, "Closed",
$t{'Diary'}, "All fixed!")
|| die $ars_errstr;
ars_Logoff($c);
something fairly close to that. Combine the above with the
documentation, and you should be on your way!
jeff
|
|
From: Paizo <pai...@gm...> - 2007-05-16 10:06:42
|
thanks for your anwers.
I still don't understand how you choose a specific trouble ticket, you just
call getfieldtable by passing a form name and change the status and the
diary by ars_setentry but of which ticket?!
2007/5/15, Jeff Murphy <jcm...@je...>:
>
> Paizo wrote:
> > Hi Listeners,
> >
> > I would like to know how to modify a trouble ticket, for example change
> > its status and write some lines on the diary field of the note. I didn't
> > find examples about this, can you give some hints please?
> >
>
> Off the top of my head..
>
> $c = ars_Login(server, user, pass);
> %t = ars_GetFieldTable($c, "Form Name");
> ars_SetEntry($c, "Form Name", $t{'Status'}, "Closed",
> $t{'Diary'}, "All fixed!")
> || die $ars_errstr;
>
> ars_Logoff($c);
>
>
>
>
> something fairly close to that. Combine the above with the
> documentation, and you should be on your way!
>
>
> jeff
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Arsperl-users mailing list
> Ars...@ar...
> https://lists.sourceforge.net/lists/listinfo/arsperl-users
>
--
CFAH3 CUT-LASS
|
|
From: Thilo S. <thi...@ap...> - 2007-05-16 11:32:20
|
The ars_SetEntry call should rather look like this:
ars_SetEntry($c, "Form Name", $entryId, 0, $t{'Status'}, "Closed", ...
The "0" after $entryId is the "getTime" parameter. If it has a nonzero
value, it can be used to prevent the change if the entry has been
changed by another user after the "getTime" (seconds after Jan 1 1970).
Regards,
Thilo
Paizo wrote:
> thanks for your anwers.
> I still don't understand how you choose a specific trouble ticket, you
> just call getfieldtable by passing a form name and change the status and
> the diary by ars_setentry but of which ticket?!
>
>
> 2007/5/15, Jeff Murphy <jcm...@je...
> <mailto:jcm...@je...>>:
>
> Paizo wrote:
> > Hi Listeners,
> >
> > I would like to know how to modify a trouble ticket, for example
> change
> > its status and write some lines on the diary field of the note. I
> didn't
> > find examples about this, can you give some hints please?
> >
>
> Off the top of my head..
>
> $c = ars_Login(server, user, pass);
> %t = ars_GetFieldTable($c, "Form Name");
> ars_SetEntry($c, "Form Name", $t{'Status'}, "Closed",
> $t{'Diary'}, "All fixed!")
> || die $ars_errstr;
>
> ars_Logoff($c);
>
>
>
>
> something fairly close to that. Combine the above with the
> documentation, and you should be on your way!
>
>
> jeff
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Arsperl-users mailing list
> Ars...@ar... <mailto:Ars...@ar...>
> https://lists.sourceforge.net/lists/listinfo/arsperl-users
>
>
>
>
> --
> CFAH3 CUT-LASS
>
>
> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> Arsperl-users mailing list
> Ars...@ar...
> https://lists.sourceforge.net/lists/listinfo/arsperl-users
|
|
From: Jeff M. <jcm...@je...> - 2007-05-16 11:33:44
|
Paizo wrote:
> thanks for your anwers.
> I still don't understand how you choose a specific trouble ticket, you
> just call getfieldtable by passing a form name and change the status and
> the diary by ars_setentry but of which ticket?!
>
>
I messed up the SetEntry call :-)
One of the parameters is "entry-id" which is the ticket# you want to
operate on.
>
> $c = ars_Login(server, user, pass);
> %t = ars_GetFieldTable($c, "Form Name");
ars_SetEntry($c, "Form Name",
"000000000012345", 0,
$t{'Status'}, "Closed",
$t{'Diary'}, "All fixed!")
|| die $ars_errstr;
|
|
From: Paizo <pai...@gm...> - 2007-05-17 07:28:27
|
it works! :)
Thank you very much :)
2007/5/16, Jeff Murphy <jcm...@je...>:
>
> Paizo wrote:
> > thanks for your anwers.
> > I still don't understand how you choose a specific trouble ticket, you
> > just call getfieldtable by passing a form name and change the status and
> > the diary by ars_setentry but of which ticket?!
> >
> >
>
> I messed up the SetEntry call :-)
>
> One of the parameters is "entry-id" which is the ticket# you want to
> operate on.
>
>
>
>
>
> >
> > $c = ars_Login(server, user, pass);
> > %t = ars_GetFieldTable($c, "Form Name");
>
>
> ars_SetEntry($c, "Form Name",
> "000000000012345", 0,
> $t{'Status'}, "Closed",
> $t{'Diary'}, "All fixed!")
> || die $ars_errstr;
>
>
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> _______________________________________________
> Arsperl-users mailing list
> Ars...@ar...
> https://lists.sourceforge.net/lists/listinfo/arsperl-users
>
--
CFAH3 CUT-LASS
|