Adding a "OutOfTheOffice" report in Agent

Hello, I need to add a "Who's out of the office" report on the right side under the "Settings" box in the AdminDashboard.dtl. (See picture) http://0x31337.org/images/OTRS-out-of-office.png However, after getting hung up in the typos errors and other problems with just the "HelloWorld" module example, and constantly getting server errors while simply trying to browse through http://source.otrs.org/viewvc.cgi/ - I'm asking for help. Can anyone direct me to a **working** custom-module example? Thanks! Drago

Hi, On 11.03.2010, at 19:17, John Drago wrote:
However, after getting hung up in the typos errors and other problems with just the "HelloWorld" module example, and constantly getting server errors while simply trying to browse through http://source.otrs.org/viewvc.cgi/ - I'm asking for help.
Can anyone direct me to a **working** custom-module example?
Just created the HelloWorld Module without any problems ... what are your errors? The CVS viewer is currently not that stable, you are right ... this will be changed soon !!! Nils Leideck -- Nils Leideck Senior Consultant nils.leideck@leidex.net nils.leideck@otrs.com http://webint.cryptonode.de / a Fractal project

Can anyone direct me to a **working** custom-module example? Just created the HelloWorld Module without any problems ... what are your errors? The CVS viewer is currently not that stable, you are right ... this will be changed soon !!!
Nils Leideck
Thanks for your quick reply! Looking at the example starting on http://doc.otrs.org/developer/2.4/en/html/x1200.html Are you **sure** that the filenames in the example are correct? Also, the example doesn't mention permissions or ownership of those files. Do they have to be set to any special value? 1) Kernel/System/Config/Files/HelloWorld.xml 2) Kernel/Modules/AgentHelloWorld.pm 3) Kernel/System/HelloWorld.pm 4) Kernel/Output/HTML/Standard/AgentHelloWorld.dtl 5) HelloWorld/Kernel/Language/de_AgentHelloWorld.pm That last one looks real fishy. ** Also - how do I get the new module to start showing up in the list of checkboxes in the "Settings" checkbox area (top-right)? Do I have to "enable" the module or add it to another config file or something like that? What am I missing? Best regards, Drago

On Thu, 2010-03-11 at 12:29 -0800, John Drago wrote:
Looking at the example starting on http://doc.otrs.org/developer/2.4/en/html/x1200.html
Are you **sure** that the filenames in the example are correct? Also, the example doesn't mention permissions or ownership of those files. Do they have to be set to any special value?
Basically, just check the permissions on the already existing files...
1) Kernel/System/Config/Files/HelloWorld.xml 2) Kernel/Modules/AgentHelloWorld.pm 3) Kernel/System/HelloWorld.pm 4) Kernel/Output/HTML/Standard/AgentHelloWorld.dtl 5) HelloWorld/Kernel/Language/de_AgentHelloWorld.pm
That last one looks real fishy.
Obviously, that needs to be Kernel/Language/de_AgentHelloWorld.pm - but usually it's best to develop the module in a separate sub directory and then use symlinks to link the file in your OTRS dir, using the module-linker.pl script, as described here: http://doc.otrs.org/developer/2.4/en/html/x1173.html
** Also - how do I get the new module to start showing up in the list of checkboxes in the "Settings" checkbox area (top-right)? Do I have to "enable" the module or add it to another config file or something like that?
Sure, that is done via a small snippet in Sysconfig. Basically, you should create a file called OutOfTheOffice.xml and put it in Kernel/Config/Files - it should contain something like the snippet that's currently in Framework.xml for DashboardBackend###0400-UserOnline - just add your own values. Also, for the Dashboard, as AgentDashboard.pm is already the front end module, you actually don't need to add another file to Kernel/Modules but to Kernel/Modules/HTML instead. You'll probably see the file DashboardUserOnline.pm that already exists there, just copy that one over and use it as a starting point. You would also need to have a file to generate the HTML from, look at AgentDashboardUserOnline.dtl for an example. Hope this helps, -- Mike.
participants (3)
-
John Drago
-
Michiel Beijen
-
Nils Leideck - ITSM