• Welcome to KonaKart Community Forum. Please login or sign up.
 
January 13, 2026, 01:14:11 pm

Show posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - BoJo

1
I am getting a null result when calling AdminOrder.getFormattedTotalIncTax() using the JasperReports scriptlet below. I can see proper values in the orders_totals table.

The parameter and field values have been verified. For example, I passed an incorrect sessionId at one point and received a stack trace (as expected).

Any help is appreciated,

Bob

---------------------- JasperReports scriptlet method ----------------------------
    public String getFormattedTotals() throws JRScriptletException {
        String formattedTotals = null;
       
        KKAdminIf kkEngine = (KKAdminIf)this.getParameterValue("kkAdminEng.class");
        String sessionId = (String) this.getParameterValue("sessionId");
        Integer orderId = (Integer)this.getFieldValue("orders_orders_id");
        AdminOrder adminOrder;
        try {
            adminOrder = kkEngine.getOrderForOrderId(sessionId, orderId.intValue());
        } catch (KKAdminException e) {
            throw new RuntimeException(e);
        }
        formattedTotals = adminOrder.getFormattedTotalIncTax();
   
        return formattedTotals;
    }
2
These are instructions for manually installing KonaKart.
The FAQ contains general KonaKart installation instructions:

http://www.konakart.com/installationfaq.php

However, these are geared for using the "set-up program" that is provided for Windows and Linux platforms. These executables do not run under Mac OS (or at least I don't know how to get them to run under Mac OS). Also, I figured it would be generally useful to provide a consolidated list of steps for performing a manual instruction.

In general, you want to follow all the documented installation instructions  EXCEPT for the "INSTALL KONAKART" section (http://www.konakart.com/installationfaq.php#Install_KonaKart) because this section assumes you are using a "set-up program" ( KonaKart-2.2.2.0-Windows-Setup.exe  or  KonaKart-2.2.2.0-Linux-Install ).

Perform all the documented installation instructions for:
* Java
* The RDBMS of your choice (MySQL in this case)

In my case, I am using MySQL and a database named "konakart". I am using Tomcat as the servlet container.

I) Populate the database

Make sure you have created an empty database instance in the RDBMS of choice as per the FAQ instructions:

In my case;
mysql> create database konakart

What is not clear from the FAQ instruction is what SQL script file to run to populate the database for a manual installation.

From http://www.konakart.com/forum/index.php/topic,302.0.html:
--------------------
To create the database run konakart_demo.sql for the database you have chosen.
---------------------


In my case:

mysql -u root -p konakart < /Users/bob/Documents/workspace/konakart/database/MySQL/konakart_demo.sql

II) Build the WAR files

1) download the zip file for manual installation as instructed here:
http://www.konakart.com/downloads.php

2) Unzip to the file to the directory of your choice.
We'll refer to this directory as <konakart>.

3) set DB name in konapart.properties
Change the string "dbname" to the name of your database (in my case "konakart") in the following file:

<konakart>/webapps/konakart/WEB-INF/classes/konakart.properties

This is documented in the "DEFINING THE DATABASE PARAMETERS" section of the installation FAQ.

4) run ant to generate the war files.

<konakart>/custom>ant
<konakart>/cusotm>ant make_wars

Detailed instruction for building the war files can be found at:
http://www.konakart.com/customizationfaq.php#How_do_I_build_the_customisable_java

III) Deploy & Test

1) deploy the WAR files
In my case I copied the .war files in <konkart>/custom/war to my tomcat "webapps" directory.

2) restart the servlet container (if necessary)
Restart Tomcat in my case.

3) test KonaKart:
Try http://localhost:8080/konakart in your browser.

;)