Thursday, 8 September 2016

Using KwaMoja for Not For Profit (NPO) Accounting - Part 1


Using KwaMoja for not for profit accounting - Part 1

After recent discussions on the mailing list of http://npoacct.sfconservancy.org/ regarding how to do accounting for non profit organisations (NPOs) I thought it would be helpful to write some articles on how to go about it using KwaMoja ERP.

I am going to assume that the organisation already has a suitable chart of accounts and that they have loaded it into KwaMoja.

The company preferences page has a setting to denote whether the organisation is an NPO:


This should be set to Yes as above.

The first of these articles will be regarding the treatment of donations. For the sake of the accounting, these can take 3 forms,

1 Monetary donations
2 Donations of stock items used in the running of the organisation (for instance pharmaceuticals in the case of a hospital)
3 Donations of fixed assets (for instance a CT scanner for a hospital)

Monetary Donations

Monetary donations are easily dealt with as a bank account receipt, accessible from the general ledger module. 


This is fully multi currency so that if the organisation accounts in Kenyan shillings, donations in GBP can be received into a USD bank account. As can be seen above each donation can have zero to many tags attached to it. In the above example the donation has been tagged to a Malaria research project, and also to the KwaMoja foundation.

This enables us to produce reports on all transactions for the Malaria research project, but also for tracking donations received from the KwaMoja foundation. The double entry record for the above would be:



Dr Bank Account
          Cr Monetary donations received account

Donations of stock items


In order to correctly deal with donated stock items we must receive the goods through the usual process. Firstly we create a zero value purchase order as below:



The items are then received in the same way, with the value still being zero



The final step is to enter an invoice for this supplier against this GRN. If the organisation is setup as an NPO (see top of this article) then a further column is created to contain the “Fair price by unit”. This is needed as the current accounting standards require donated articles to be valued at a “Fair value” - as defined in Statement of Financial Accounting Standards (SFAS) 157.


Each line can be given a tag on which it can later be reported.


Every stock item is associated with a stock category and this assigns GL codes for various aspects of those stock items. If the organisation was setup as an NPO (see top of article) then one of these options is a GL code for donations of those items:


Now when the supplier invoice above is posted the inventory will increase by the fair value of that item. The double entry for this will be the donations account for the category that item is associated with. The full journal will be:

Dr Stock of pharmaceuticals
      Cr Donations of pharmaceuticals

Once the original setup is in place any donation is done as easily as any other acquisition of materials.

Donations of fixed assets


The final method of donations is for receipt of donated fixed assets. Like stock items, all Fixed assets are members of a fixed asset category, and this category is used to assign various GL codes to a fixed asset. If the organisation is flagged as a NPO then one option is for a GL code for donated assets of this type.


Now as we proceed to enter the fixed asset in the normal way via a suppliers invoice we will be prompted for a “Fair value” of the asset - as defined in Statement of Financial Accounting Standards (SFAS) 157.


As can be seen any number of tags can be selected against this donation. When the invoice is posted an asset gets created with an initial value of the “Fair Value” and the credit instead of being the bank/cash accounts will be the account chosen as the “Donations” account in the Fixed asset categories screen.




This deals with all the methods the organisation could receive a donation. In the next article I will deal with the process by which the organisation deals with expenses, and associates them with different projects, and categories.

Friday, 29 July 2016

A call for developers, translators, documenters and medical professionals

Care2x (http://www.care2x.org) is a fully featured open source hospital information system (HIS). It is used in many hospitals all around the world. However in recent years for various reasons activity on the project has slowed and has practically come to a standstill. Another problem is that there are a number of different versions of Care2x around.

However the code did not run at all on PHP 7.0 and as more and more server operating systems are distributed with PHP 7.0 the project was in danger of dying. This would have been a major shame as it is a great application, and the developers have done amazing job in the past.

A few of us decided we didn't want this to happen so have been working on bringing the code base up to date. Our work so far can be seen here (https://care2x.kwamoja.org/) The user name/password is admin/kwamoja. This server is running PHP 7.0 and the code should now work on both PHP 5.x and 7.x versions. The very latest code can be downloaded from here (https://github.com/care2x/care2x/archive/master.zip). Please note this is still being updated very regularly and is for testing purposes.

I have been working on integrating this code with the medical branch of the KwaMoja open source ERP (https://medical.kwamoja.org). If this integration is not required then both will run fine as standalone applications.

We have now reached the point where we need help. In no particular order we need:

1. Developers: Care2x is written using PHP/MySQL/Javascript. If you know any of these, or just want to learn, then go to github, clone the repository and get coding. There is a mailing list for developers that you can subscribe to here (https://lists.sourceforge.net/lists/listinfo/care2002-developers) where you can ask questions and get any advice you need to get going.

2. Translators: Translation files are stored under the language/ subdirectory. Each language is then stored under a two letter sub-directory denoting the language. So language/en for English, language/de for German etc. Each of these files contains variable assignments such as this from language/en/lang_en_departments.php:
 $LDHeadlines='Headlines'; 
Then there should be a corresponding entry
$LDHeadlines='Nachrichten';    
in language/de/lang_de_departments.php and in each of the other translations. What is required is that people check that the files contain the same variables (at the moment they don't) for each translation, and where they don't new variables with appropriate translations are done. If somebody wishes to create a new language translation they just need to create a new subdirectory under the language and get translating.

3.Documenters: Like most open source projects Care2x could always do with improved documentation. There is an old wiki here (http://wiki.care2x.org/index.php?title=Main_Page). We need people to read this documentation, update with regard to the new code, and add new documentation.

4. Medical Professionals: Care2x is intended to be used by medical professionals. It would be great if such people can use care2x, especially with regard to the work flow, and make any suggestions (though we don't make any promises on implementation!). Any suggestions can be logged on github here (https://github.com/care2x/care2x/issues). This includes any bugs that are found. As said previously this code is still being developed so will contain bugs. Please try to put an appropriate label to each issue to help us resolve them.

Tuesday, 11 November 2014

Introducing Colin

Announcement

I am pleased to announce the first release of Colin, our integrated testing suite for KwaMoja. This software automatically controls KwaMoja using the libcurl libraries, and compares the results against expected results, outputting the results in a nice web viewable format. The tests can be batch run, so hundreds of tests can be automatically run and their results viewed.

Technical Details

The suite contains a a library of functions for automating a complete KwaMoja session. There is a function to login, to choose an appropriate module, to choose an appropriate menu item, to run any number of options within that option, and to logout. Each step of the way, various tests are run for PHP errors/warnings/notices etc and any of these are recorded. All links in a page are verified to make sure they are not broken. When a page carries out some action against the database the result is verified. More verifications will be put in, software of this kind is never complete.

Output

The output from a Colin session can be viewed through your web browser, and looks like this:
If there are any details clicking on the "Details" link will bring up a new page showing these:
 
This will include any screenshots automatically saved by Colin:

Can I get a Colin of my own?

Yes. Colin is released under the GPL v2.0 license and is obtainable from my github site https://github.com/timschofield/colin

Why Colin?

Why not? It just seemed like a good name to me!

Monday, 3 November 2014

Plagiarism

This page is written in response to the lies that +Phil Daintree has written about me, and spread on the internet. Despite years of searching he has been unable to find anything I have written that is untrue, and he has had to resort to vague generalities, faked emails, and badly fabricated screenshots (you can see the joins if you zoom in using any bit mapped image editor). +Phil Daintree is welcome to make any comments to these pages, as he has done in the past. If I agree with what he says I will amend my writings, if I do not agree I have allowed his comments to stand next to mine so that people can make their own judgements. I have every confidence in the intelligence of readers to make a sensible judgement based on the facts. +Phil Daintree will not allow me the right of reply to any of the lies he has told about me. It seems to me significant that he realises that if people see both sides of the argument they will see through his lies.

In the world of open source software a lot of emphasis must be placed on honesty and trust. You have to be able to trust that when you submit code to the administrator of a project that the code is released under the correct license and that is correctly accredited to you. This accreditation is not a question of ego but of common decency and of honesty.

Whenever code gets added to KwaMoja I go to great lengths to attribute the code to the correct author as can be seen here

All the work we do in KwaMoja is made available to the webERP project, however recently the project admin +Phil Daintree has been consistently attributing the work to himself rather than to the actual author.

For instance +Fahad Hatib did some considerable work to remove the $db variable throughout the code base, and I personally made that available to +Phil Daintree.

This work was committed to webERP here. Instead of correctly attributing that work to +Fahad Hatib Phil decided to claim the credit for this work to himself:


Unfortunately this seems to be typical of the recent dishonest behaviour of the leadership of the webERP project.

Tuesday, 14 October 2014

New demo for KwaMoja-Medical

Following on from this post regarding our hospital extensions for KwaMoja I have created an online demo for the KwaMoja-Medical branch. This demo can be found here.

This demo has a separate module called "Hospitals" (maybe this should say Medical??) and includes facilities for registering patients, dispensing and billing for pharmaceuticals, billing for Radiology and Laboratory tests any other medical services a hospital needs.

It also now has the facilities write notes on a particular patient, and to review a patients entire history, including notes in one screen.

At the moment the intended audience for this is smaller clinics and hospitals where a fully fledged HIS is not really applicable. However as time goes on and more functionality gets added then who knows......

Monday, 13 October 2014

Upgrading from webERP to KwaMoja

With the still unfixed $AllowAnyone security issue and the recent buggy release of webERP a number of people have asked me how to upgrade from webERP to KwaMoja.

Well it really couldn't be more easy! Thanks in no small part to the hard work of Fahad we have kept an easy upgrade path, despite the numerous improvements and enhancements we have done in KwaMoja.

So if you want to take advantage of the stability, security, and additional features of KwaMoja here is what you do:

1 Backup everything. This includes all your webERP databases, and all of your webERP code.
2 Download the latest KwaMoja code from here: https://github.com/KwaMoja/KwaMoja/archive/develop.zip
3 Extract the files from here and copy them over your current webERP implementation.
4 Make sure that the webserver user has read and write permissions on everything under the companies directory.
5 Login to your new KwaMoja implementation using the same url and the same login credentials that you used for webERP
6 You should now be greeted with a screen telling you that there are database updates to do. Click Continue to do these updates. You may get some error messages telling you that some of these have failed. Do not worry about these, it just means that the data was already there.
7 Once this is completed, log out of KwaMoja.
8 In each of your companies directories you should now have a file called Companies.php. This should contain a line some thing like this:

$CompanyName['weberpdemo'] = 'weberpdemo';

Change this to be the name of your database and the full name of your company/organisation. eg.

$CompanyName['kwamoja'] = 'KwaMoja Demonstration Company';

Once you have done this refresh the login screen and the full company names should appear.
9 Log back in to KwaMoja. Some themes work better than others in KwaMoja. We recommend that you use the "aguapop" theme for the best interface.

And thats it, you have now upgraded. Any problems log them onto the kwamoja.com forums!!

Saturday, 11 October 2014

New KwaMoja demo site

There is a new demo for KwaMoja here: http://demo.kwamoja.com
The demo includes a lot of new features such as a new Quality Assurance module, updated Order acknowledgements/Picking Lists functionality, a bridge to synchronise data with OpenCart, the facility to import bank transactions in many formats, a job scheduler to run certain KwaMoja scripts automatically, new levels of security for bank accounts and locations, many speed improvements to the code, and much much more