This document gives an overview of how Kimai works. It is intended for developers (core and extensions).
Please read our CONTRIBUTING GUIDELINES directly at Github.
First lets talk about the wording used in Kimai to describe things:
Those are the dragable “windows” which open as an overlay in the page. For example the preferences dialog or the dialog to add new timerecords.
The lists in the lower part which show users, customers, projects and tasks.
PHP files which handle AJAX calls.
Every tab you see in Kimai (like timesheet, export, admin panel) is an extension.
styles.cssis mandatory. For the sake of readability you should split your stylesheets up into several files.
Login happens at the /index.php file. This is where you land when you open the kimai folder in your browser. Both, customers and users can login through the same login mask. For conflicting names (user and customer have the same name) the customer account takes precedence.
After a successfull login the user is redirected to
/core/kimai.php. Here all extensions are loaded and the main user interface is being build.
For example the timesheet, export and expenses screen (which you get by clicking the corresponding tab) is called an extension. To disable an extension, just add a hash (#) symbol in front of the folder name. To re-enable it, remove the hash.
Floaters get their seperate folder under the templates folders. The folder css is obviously for CSS files which are needed by the extension.
_init.js and a
The first should contain code to setup the extension.
Only after an extension/tab is selected its content is being loaded. This is handled by the init.php file in the extensions folder. The processor.php file handles AJAX calls and floater.php creates those dragable windows.
From time to time we will release ZIP archives. These are most often beta versions, to be tested by our user base for problems and bugs. Production ready releases will be linked specifically in the download section at our website.
You can download the current developer-version as ZIP from our master branch at GitHub.
To get the developer version use the repository. Please keep in mind, that this version is NOT stable! We like to receive bug reports to be faster with fixing them, but we can not guarantee support for these versions.
We recommend using a fork, so any changes made can be pushed back and then submitted back via pull-requests:
git clone https://github.com/YOUR-USERNAME/kimai.git
Then, if you want to make changes and submit them, use a feature branch:
git checkout -b my-feature
git commit -am "Added my feature"
git push origin my_kimai
Create a pull request from your GitHub repo page.