Showing posts with label updates. Show all posts
Showing posts with label updates. Show all posts

Wednesday 25 September 2013

New installer for KwaMoja

The final bit of the new +KwaMoja version is now complete and just needs testing. This is the brand new installer. 

Firstly it should be said that this builds on the excellent work of +Exson Qu and +iced lava. After downloading +KwaMoja and placing the code in the web root, point your browser to the code.

You should be taken automatically to the installer screen.

This is the wizard that will guide you through the entire installation process.

The first selection you must make is the language that you want to use for the installation, and for the admin user.
 
Changing this language setting will immediately refresh the screen, and you should now see it in your chosen language.


This language setting will remain constant through the rest of the installation process.

NB You must have the correct language setup on your server.

The final step on this first page is to choose the database management system that you want to use in +KwaMoja

Currently only MariaDB, MySQL, and MySQLi are supported, although +Fahad Hatib has nearly completed his work to have PostgreSQL  supported in +KwaMoja. However it was decided to leave this till after this release to give maximum testing time for his work. Clicking on "Next Step" takes you to the second screen of the installer.


This screen will make all the necessary checks on your system to ensure that
+KwaMoja can be installed and run on your server.

If you get any failures here then you will be presented with a button to "Check Again". Just correct the problem and then click this button, until all problems are resolved, and you get a screen like the one on the right. Then move on to the next step.


This screen is for details of the database connection that we are going to use.

The first field is for the host machine that the database is on, relative to the web server, not to the client machine. So if the web server and the database server are on the same machine this can be left as "localhost". An IP address can also be used.

The last two fields are for the login details to your database. This shouldn't be confused with the login details to +KwaMoja. The second field is for the name of the database that you will use. This should only contains alphanumeric characters, and no spaces. If the database login that you supply doesn't have permissions to create a database (a lot of shared hosting companies do not allow this) then this database must be created manually before the installation process begins.


Clicking on "Next Step" takes us to the final screen of the installer. The first field is for the name of your company. This should be the full name that you want to appear on all paper work. Next we select a chart of accounts to be used for our company. Currently we have 27 charts kindly donated from all around the world - Many thanks to all those who have donated. Next is the timezone that the server is located in +KwaMoja should choose the correct for you. Finally you can upload your company logo which appears throughout +KwaMoja If you don't upload a logo the default +KwaMoja logo will be used instead.

Next we have the option to install some random test data.
Choose this if you are just evaluating +KwaMoja otherwise leave this unchecked.
Finally you need to enter the details for the +KwaMoja system administrator account. Default is a userid of admin, and a password of "kwamoja", but you can decide your own.

Once done click on the install button, and the installation process will start.

This will firstly create a config.php file based on the settings you give. Then create a database for you (this process is quite slow as it performs many checks along the way to ensure the database is correct). Finally if you have elected to load the random demonstration data, this will then be loaded.

Once this is done, a button will be shown to start +KwaMoja. You will need to login using the system administrator login that you provided.

Once logged in, you will be taken to some of the configuration screens to setup your +KwaMoja. It is important you read these screens properly, and give the correct information. If in doubt consult the manual.

You can download this version of +KwaMoja for free from here

All feedback is appreciated. Please log any issues you find here.

Tuesday 25 June 2013

Lot's of great new functionality

KwaMoja has just gained lots of new functionality.

We now have a maintenance module for fixed assets. This allows you to set specific maintenance tasks for individual fixed assets, set up a schedule for these tasks to be done, and to email the person responsible with reminders when the tasks are becoming due.

Electronic bank statements in the MT940 format can now be imported and analysed directly into the KwaMoja general ledger.

Many thanks must go to Phil Daintree for this excellent contribution.

Phil has also setup a demo mode, which will stop whoever it is with an IP address in Wellington, New Zealand that has too much time on their hands and too little to occupy themselves. This person keeps trying to come up with new ways to wreck our demo. Thanks Phil for helping to stop them.

Also KwaMoja now links to Phil's new web shop, and it can be administered directly through KwaMoja. This web shop is commercial software, and not open source, so it is hard for us to test and verify, so caution  needs to be observed on the security side of this as it stores information about your customers payment methods. Nevertheless a great contribution, thanks Phil.

We now also have the ability to import general ledger journals, payments, and receipts directly from a csv file.

Also there is now a flag setting in the user setup that can restrict a user to only access their default location. Thanks Jerry for sponsoring this work.

All this new functionality can be tried out at the KwaMoja demo.




Wednesday 5 June 2013

How to keep a stable KwaMoja/webERP installation updated

There has been a lot of discussion recently on the webERP forums about how to keep a stable version of your implementation, so I thought it might be a good moment to write an article on how to do this.

Firstly Web ERP Africa Ltd keeps a stable branch of the webERP code. This takes the last release (4.10.1 at the moment I write this) and then just adds in any bug fixes that have been applied to the main line. Obviously this does not include any bug fix to any new functionality, as that functionality does not exist in the stable branch. We also apply our regression tests to these fixes, to ensure that they are not re-introducing any previous bugs. This branch should then get progressively more stable, but anybody  who wants the latest features can use the main trunk. I have made this stable branch publicly available from my github repository and can be found here. You can download a zip file containing this code from here. This zip file is automatically updated when a new bug fix is applied.

Exactly the same is true for KwaMoja, it's stable branch can be found by using the master branch here.

So if you are using a KwaMoja/webERP that has no customisations in it then all you have to do, is to keep an eye on this repository, and download new versions as and when it is updated.

However there are potential problems when you have customised scripts in your installation. I will assume that if the user has the knowledge to change the files then they will have a small knowledge of IT, and you will need the application Git installed.
 
What we wish is to avoid the code being over written when updating from the stable branch. I have created a small git repository here to represent the stable branch, and have uploaded the following script to it, calling it HelloWorld.php:

<?php
include('includes/session.inc');
$Title = _('Hello World');
include('includes/header.inc');
echo '<p class="page_title_text noPrint" ><img src="'.$RootPath.'/css/'.$Theme.'/images/user.png" width="24px" title="' . _('Hello World') . '" alt="" />' . _('Hello World') . '</p>';
if (isset($_POST['Submit'])) {
    /* Get clients IP address */
    $IPAddress = $_SERVER['REMOTE_ADDR'];

    /* Has user been here before? */
    $SQL = "SELECT count(name) as names
                FROM helloworld
                WHERE name='" . $_POST['Name'] . "'
                    AND ipaddress='" . $IPAddress . "'";
    $Result = DB_query($SQL, $db);
    $MyRow = DB_fetch_array($Result);
    if ($MyRow['names'] > 0) {
        prnMsg( _('Welcome back') . ' ' . $_POST['Name'], 'info');
    } else {
        $SQL = "INSERT INTO helloworld (ipaddress,
                                        name)
                                    VALUES (
                                        '" . $IPAddress . "',
                                        '" . $_POST['Name'] . "'
                                    )";
        $Result = DB_query($SQL, $db);
        prnMsg( _('Hi') . ' ' . $_POST['Name'], 'info');
    }
} else {
    echo '<div class="page_help_text noPrint">' . _('Enter your name in the box below.') . '</div>';
    echo '<form enctype="multipart/form-data" action="' . htmlspecialchars($_SERVER['PHP_SELF'],ENT_QUOTES,'UTF-8') . '" method="post" class="noPrint">';
    echo '<input type="hidden" name="FormID" value="' . $_SESSION['FormID'] . '" />';
    echo '<div class="centre">
            <input type="text" name="Name" />
        </div>
        <div class="centre">
            <input type="submit" name="Submit" value="Submit" />
        </div>';
    echo '</form>';
}
include('includes/footer.inc');

?>

Now you can pull this code to your own machine by issuing the command:

git clone git@github.com:timschofield/Example1.git

Now we make a local change to our code. We will change the word 'Hi' to 'Hello'. Now if we wish to update our code to the latest from the repository we would issue the command:

git pull git@github.com:timschofield/Example1.git

and this will update any changes - if there were any new bug fixes applied for instance. However you will notice that Git is smart enough not to try and overwrite your code that you changed locally.

So by using Git we can update our code to the latest stable branch, whilst keeping our local changes in place.