Nikrad Enterprise Gateway
Operation and Development
Software Requirements
- Windows or Linux operating system
- Apache Tomcat (5, 6, 7 or later versions)
- JDK (Java Development Kit) or JRE (5, 6, 7 or later versions)
- MySQL or MS SQL Server (based on the platform edition that you are licensed for)
Automated Installation
If you wish to have an automated installation for Windows based systems you may download the Nikrad Framework from the download center on www.nikrad.com and Install it into a convenient location e.g. "d:\". It is recommended not to install the framework into the same partition which windows o/s has been installed. Nikrad Framework is a set of structured directories and useful utilities bundled with JDK and Apache Tomcat that simplifies the installation process and enhances maintenance of information and files. Please refer to "{Nikrad Framework}\readme.html" for more information.
Manual Installation
This type of installation is useful when we tend to install the Nikrad platform and/or gateway on a remote host on the web or a local linux based machine. Manual installation of web application for nikrad enterprise gateway is similar to nikrad enterprise platform.
To establish a web application (context) for the gateway (e.g. "nepw"), create a folder with the same name ("nepw") in the tomcat "webapps" directory (or "domains/{domain name}" if the domain is mapped) and extract contents of the Nikrad Enterprise Gateway distribution package of base and other licensed gateway packs into that web application folder (e.g. "{tomcat}/webapps/nepw" or "{tomcat}/domains/mydomain.com/nepw"). You also should open "{web application}/WEB-INF/web.xml" in the gateway context with a standard text editor and set context parameters of the gateway with appropriate values.
* Please refer to "readme.html" inside of the package "nep-en-fundaments.zip" for more information.
Operation and Development
To get started with Nikrad Enterprise Gateway, a web browser must be used. Type "http://{Server:Port}/{Gateway Context}" in the address bar. Server and Context refer to the name of the service-providing computer and the gateway web application respectively (e.g. "http://localhost:8080/nepw"). We may also enter the service-providing computer's IP address (e.g. "http://192.168.0.1:8080/nepw") instead of its name. As a whole the address should either begin with "//" or "http://", and ":8080" refers to the port number that corresponds to the application server (tomcat).
Nikrad Enterprise Gateway could be run as an independent web application beside the Nikrad Enterprise Platform web application or on a remote web server. Platform and Gateway both connect to the same database on database server. Gateway presents the information that are directly fetched from platform database and registers information related to requests of visitors (Tickets and Invoices) directly to the platform database.
The best way to get familiar with nikrad enterprise gateway is reviewing its interface objects and source codes. If you wish to develop and extend features of your installed gateway, you need to have enough knowledge and experience about Java language programming and "JSP" (JavaServer Pages) technology.
Note: Some of JSP files are compiled and mapped as servlet class. Therefore you can not have access to related source codes. You may refer to "web.xml" to view the list of mapped servlets.
Gateway reads information of GUI contents and language packs from html and ini files that are placed in "templates/{lang}" directory, then replaces variables that are specified by "%" characters with appropriate values and finally sends processed template contents to the screen.
Nikrad gateway achieves value of parameters from "WEB-INF/properties.ini" to set its configuration options. You can review contents of this file and change values of parameters to define gateway behaviors based on your needs.
If you wish to let gateway visitors change language state of their sessions on nikrad gateway you should prepare links to some of major pages with the additive parameter "lang=xx" (e.g. "index.jsp?lang=en", "neg.serve.content.jsp?subject=about&lang=fr"). The default lang is "en". When you use the "lang" parameter while calling a page that has included the "includes/config.jsp", that page will set the default "lang" attribute of the visitor session for further needs automatically.
Nikrad gateway uses a routine mechanism to validate email addresses of new registered users. This feature will be enabled if the parameter "accounts.activation" on the gateway properties ("properties.ini") is set to "1". In this mode all accounts will have the text "{NOT-ACTIVATED}" on their "CID" field on the database once they are created (registered). Nikrad gateway will not allow its users to log into the system while they have the mentioned text on their CID field.
While a new account is created, gateway will send confirmation email to the email address that is provided by the user to inform him that his account is created and needs to be activated by him. User must click on the provided URL inside of the confirmation email to activate his account. After that user can log on to the gateway system and take advantage of his membership. If a user does not receive the confirmation email within a day, he can send an activation request from the registered email address to us. On the platform side, we can activate account profile of the user by removing the mentioned text from the CID field manually.
Please refer to "Mail Servers" section on the gateway properties file to control system units that the gateway will use to send emails to its users for different purposes.
- Content Management System
Nikrad enterprise gateway reads contents of text documents from the platform archive system and represents them by using "neg.serve.content.jsp" as server page. This page passes information of required content from query string parameters to the included server page "core/neg.load.content.jsp" to fetch and show (e.g. "neg.serve.content.jsp?subject=privacy&deskbar=1").
To fetch text documents from the platform archive system, they must exist
in categories that their names start with "Gateway / Resources / {lang}" as prefix. For example categories such as "Gateway / Resources / en / Webpages" or "Gateway / Resources / en / FAQ" has valid names and grants documents the required privilege that they need to be present on gateway.
We can use "neg.serve.template.jsp" to fetch contents of resource files that are placed in "templates/{lang}" directory. This page calls server page "core/neg.load.template.jsp" to fetch contents of resource files based on query string parameters that will be passed automatically (e.g. "neg.serve.template.jsp?item=x.page.home&simple=1").
You can analyze "neg.knowledge.base.jsp" to get familiar with other technics.
This page is used to serve Knowledge Base articles from text documents based on a specified category or not limited to (if category is not defined). This example shows us how to use it to play as a FAQ resource: "neg.knowledge.base.jsp?category=6&caption=knowledge.faq.title&description=knowledge.faq.text". Please refer to the "Desk Modules" section of the gateway properties file and review its related parameters.
If you are going to extend gateway to support additional languages, it is better to add the "lang" parameter on the default links that are placed on resource files in the "templates/{lang}" folder.
- Issue Tracking System
Gateway visitors that are registered as valid users
can submit their issues as tickets by selecting the relevant department. They also can track and reply submitted tickets. We can customize "templates/{lang}/category.ticket.departments.html" to define departments that should be used for gateway users while creating tickets. Tickets will be registered as Activities that are assigned to the relevant System Unit on the platform. Content of a ticket will be attached to the related activity as a Paraph. We also can define Data Forms to enhance quality of collected information from gateway users. If we specify a workflow Process for a ticket department, the related activity will be automatically linked to an auto-created Case.
These examples shows us how to define direct links to accept tickets from gateway users:
"neg.desk.ticket.submit.jsp?department=Contact Center"
"neg.desk.ticket.submit.jsp?department=Support&form=Support"
"neg.desk.ticket.submit.jsp?department=Sales&form=Sales&process=37"
Platform users can review ticket type activities that are assigned to their departments considering attached paraphs. Finally platform users
can add their response to ticket activities by appending new paraphs with checked "Declarable" option. While users do select the Declarable option of ticket type activities, platform will change the status of corresponding activities to "Completed" and send contents of "{Platform web application}/resources/email.ticket.done.html" as notification to email address of gateway users to inform them about the status of handled tickets. Gateway users are able to reopen tickets and assign them to platform users by replying tickets. All paraphs with checked "Declarable" option are accessible (visible) for gateway users.
Platform users can insert contents of text documents from archive system as predefined templates into
their paraphs while they change the paraph state to html mode by clicking on the "Notes" link.
Enterprise platform will use information of the Notifications mail server that is defined on Settings / System Settings section.
Platform users are able to create tickets
for gateway users manually. For this purpose they could register ticket type activities and link them to corresponding Account profiles. They must add their message as Paraph with checked Declarable option. While users do select the Declarable option of manual ticket type activities, platform will send contents of "{Platform web application}/resources/email.ticket.new.html" as notification to email address of gateway users to inform them about new tickets that are opened and waiting for their response.
Note: You should review the "properties.ini"
related to the Nikrad Enterprise Platform and set the parameter "gateway.context" which is required by the platform in order to create the direct link for returning users to the ticket information page on the gateway. The direct returning link is used by platform to set the variable "%TicketURL%" that is included in the emails which are going to be sent to the gateway users.
- Online Shopping System
Online shopping is a form of electronic commerce whereby gateway users directly buy goods or services over the Internet without an intermediary service. If Gateway eCommerce module is appended to the Gateway Base module then we can present our products on the gateway Store by editing information of Goods and Services on the platform Settings and selecting the option "Present on eShop " on the "Item Properties on eShop" section.
If you wish to enable control feature for quantity
on hand of good items, set value of the parameter "store.items.quantity.control" on "properties.ini" to "1" and set value of the field "Store ID" to the corresponding store number on the "Goods and Services / Item Properties on eShop" section. You can enter 0 if you wish to disregard controlling the quantity on hand.
We can limit the range of order quantity by using minimum and/or maximum Order Limitation fields. The maximum order quantity will be changed automatically when quantity of available goods in the warehouse is not adequate.
We are able to set the shipping cost for every single item. If you use shipping costs, it is required to set the parameter "store.shipping.item.id" in "properties.ini" to the appropriate Good ID of the Freight that you have defined as a service item. Good ID is a query string parameter that can be achieved from the web browser address bar while reviewing information of Goods and Services items.
If you wish to calculate shipping cost of ordered items online while users finalize the purchase, you can add your programming codes to files such as "modules/shipping.rate.fedex.jsp" that are included by "core/neg.store.checkout.initialize.jsp" to be applied on "neg.store.checkout.summary.jsp".
When a gateway user finalizes the purchase process, the quantity of sold items will be reduced in inventory system and a Sales Invoice dynamic activity will be created and assigned to the specified department that is defined by parameter "store.invoice.assign.to" on gateway properties file. Gateway also sends the Invoice to the user email address
automatically if the value of parameter "store.invoice.send.email" is set to "1".
After finalizing the purchase user will be redirected to the payment form (e.g. "neg.payment.jsp?format=purchase&hideamount=1&invoice=1300004") in case the parameter "payment.enable" on gateway properties equals to "1". You can add your information of bank accounts on "templates/{lang}/purchase.payment.offline.html" to show on offline payment page. If the PayPal as a payment method is specified on "payment.methods" parameter of the gateway properties, other parameters for the paypal section will be used by "core/neg.payment.paypal.jsp" to redirect gateway user to the PayPal payment gateway if the paypal method of payment has been selected.
You can use Instant Payment Notification ("IPN") service of the PayPal to automatically mark the invoice activity as Paid when PayPal system confirms the payment. In this case you should define the url "http://[YourServer:Port]/[Gateway Context]/api/neg.payment.paypal.ipn.jsp" on the IPN section of your PayPal account. This page as an api interface utilizes the paypal confirmation data packet, validates related invoice information and finally stores the payment transaction ID on the Payment ID field of the invoice activity, Marks the Paid option on Documentation section and changes the State of the activity to "Completed" (The properties parameter "payment.invoice.completion" must be equal to "1" for the last one).
- Automated Distribution System
Nikrad Enterprise Gateway includes an automated software distribution system to provide downloadable products such as softwares, documents, and etc according to purchased (licensed) items.
Nikrad gateway offers "Download Center" to analyze invoices which are paid and provide expirable links to download electronic products and resources. Please analyze the source code of "neg.download.center.jsp" for better understanding of the mechanism.
We can also use "Knowledge Base" (neg.knowledge.base.jsp)
to provide gateway users with resources based on purchased or licensed items. Knowledge base uses the same method that is placed in the Download Center to analyze invoices and provide links to documents and resources.
One of the most useful
methods to provide gateway users with classified documents and resources is organizing Accounts into Groups and analyzing their access privileges based on information of the "Groups" field (Rule based classification). An account can be associated with one or several groups on the platform side. Information of Groups field can be achieved from the specified session variable that is set when the user logs into the system or by fetching fresh and updated information from the database.
We can analyze the source code that are related to Download Center and Knowledge Base to find the mechanism of the automated distribution system. Parameters related to "desk.download.center.*" and "desk.knowledge.base.*" on the gateway properties are defined to empower capabilities of the resource center and automated distribution system.
Please review all parameters on the gateway properties file ("properties.ini") and set appropriate values to customize behavior of the system as your needs.
Warning!
You may not copy, reproduce, distribute, lease or sell this software. Only Licensed and Registered users can use this program and customize it as their needs.
Copyright © 2012 Nikrad Hypersystems.
All rights reserved.