Error while adding a custom module in oTRS

English! place to talk about development, programming and coding
Post Reply
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Error while adding a custom module in oTRS

Post by malikKhan91 »

I have developed a custom module to to show for customer interface. I am etting this error. (see screenshot attached) Can anybody help please?
You do not have the required permissions to view the files attached to this post.
reneeb
Znuny guru
Posts: 5018
Joined: 13 Mar 2011, 09:54
Znuny Version: 6.0.x
Real Name: Renée Bäcker
Company: Perl-Services.de
Contact:

Re: Error while adding a custom module in oTRS

Post by reneeb »

You need to register the module in your sysconfig (see https://github.com/OTRS/otrs/blob/rel-3 ... .xml#L8025)
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Re: Error while adding a custom module in oTRS

Post by malikKhan91 »

By registration, if you mean to add a file in Kernel/Config/Files/
I have already done that, here is my file

Helloworld.xml

Code: Select all

<?xml version="1.0" encoding="UTF-8" ?>
<otrs_config version="1.0" init="Application">
<ConfigItem Name="CustomerFrontend::Module###HelloWorld" Required="1" Valid="1">
<Description Translatable="1">FrontendModuleRegistration for Docs module.</Description>
<Group>HelloWorld</Group>
<SubGroup>Frontend::Customer::ModuleRegistration</SubGroup>
<Setting>
<FrontendModuleReg>
<Title>HelloWorld</Title>
<Description>HelloWorld</Description>
<NavBarName>HelloWorld</NavBarName>
<NavBar>
<Description>HelloWorld</Description>
  <Name>HelloWorld</Name>
<Link>Action=CustomerHelloWorld</Link>
<NavBar></NavBar>
<Type></Type>
<Prio>8400</Prio>
<Block></Block>
</NavBar>
</FrontendModuleReg>
</Setting>
</ConfigItem>
</otrs_config>
reneeb
Znuny guru
Posts: 5018
Joined: 13 Mar 2011, 09:54
Znuny Version: 6.0.x
Real Name: Renée Bäcker
Company: Perl-Services.de
Contact:

Re: Error while adding a custom module in oTRS

Post by reneeb »

In the config, you say "HelloWorld"

Code: Select all

CustomerFrontend::Module###HelloWorld
, but use the action "CustomerHelloWorld" (see your screenshot)
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Re: Error while adding a custom module in oTRS

Post by malikKhan91 »

I think i mis'understood it, What i was thinking was, that this line defines the name of module

Code: Select all

CustomerFrontend::Module###HelloWorld
And it shoud be the same name as .XML file.

WHile this line

Code: Select all

Action=CustomerHelloWorld
, Here th name of Frontend module file (Kernel/Modules/AnyName.pm) should be written, mine is CusotmerHelloWorld.pm, that why i have written CustomerhelloWorld.
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Re: Error while adding a custom module in oTRS

Post by malikKhan91 »

And if i change the name, and set both lines with 'CustomerHelloWorld', following error arrives in GOOGLE CHROME:
Script failed to send data

And on INTERNET EXPLORER:, the error becomes:


The website cannot display the page
HTTP 500
Most likely causes:
•The website is under maintenance.
•The website has a programming error.
What you can try:

Refresh the page.
Go back to the previous page.

More information
This error (HTTP 500 Internal Server Error) means that the website you are visiting had a server problem which prevented the webpage from displaying.
For more information about HTTP errors, see Help.


reneeb
Znuny guru
Posts: 5018
Joined: 13 Mar 2011, 09:54
Znuny Version: 6.0.x
Real Name: Renée Bäcker
Company: Perl-Services.de
Contact:

Re: Error while adding a custom module in oTRS

Post by reneeb »

Then have a look at the webserver error log!
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Re: Error while adding a custom module in oTRS

Post by malikKhan91 »

Can you please share the path where i can find webserver log? I am searching for ot, but cannot find it/....
reneeb
Znuny guru
Posts: 5018
Joined: 13 Mar 2011, 09:54
Znuny Version: 6.0.x
Real Name: Renée Bäcker
Company: Perl-Services.de
Contact:

Re: Error while adding a custom module in oTRS

Post by reneeb »

This depends on the webserver (Apache, IIS, ...) and the operating system (Win, Debian, CentOS) you use.
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
malikKhan91
Znuny newbie
Posts: 15
Joined: 25 Jul 2014, 08:52
Znuny Version: 3.3.8
Real Name: malik
Company: M & GS

Re: Error while adding a custom module in oTRS

Post by malikKhan91 »

I am using windows 7, and i downloaded windows setup from the official website. I think it is apache, but i a not sure.
in c:\OTRS i have following folders:
1. CRONw
2. MySQL
3. OTRS
4. otrs4win
5. StrawberryPerl

Why I think it is apache? Because I searched the direcotry with the word apache and search results showed this: (file attached)
You do not have the required permissions to view the files attached to this post.
reneeb
Znuny guru
Posts: 5018
Joined: 13 Mar 2011, 09:54
Znuny Version: 6.0.x
Real Name: Renée Bäcker
Company: Perl-Services.de
Contact:

Re: Error while adding a custom module in oTRS

Post by reneeb »

As this doesn't show any directory that belongs to the webserver Apache, I guess you are using IIS. I'm not very familiar with IIS so I can't help you.
Perl / Znuny development: http://perl-services.de
Free Znuny add ons from the community: http://opar.perl-services.de
Commercial add ons: http://feature-addons.de
Post Reply