An ERP based on Symfony and AngularDart
The project's purpose is tracking working Expenses Writing Offers and Sending Invoices
An API and open architecture will serve additional purposes:
- accounting and invoicing (generate invoices, add non-time related items)
- manage customers (CRM)
- project management
See the Vagrant VM in env Folder
Download and install VirtualBox:
https://www.virtualbox.org/
Download and install Cygwin:
https://cygwin.com/
In the package selection of the setup, search rsync and add it
Modify the hosts file:
In C:\Windows\System32\drivers\etc\hosts add the line
192.168.122.10 dime.test.local
Download and install a Git client:
e.g. https://www.sourcetreeapp.com/
Check out the current version
Fix vagrant rsync bug:
Find file: C:\HashiCorp\Vagrant\embedded\gems\gems\vagrant-1.7.4\plugins\synced_folders\rsync\helper.rb
Find code snippet and change third line to:
if Vagrant::Util::Platform.windows?
# rsync for Windows expects cygwin style paths, always.
hostpath = "/cygdrive" + Vagrant::Util::Platform.cygwin_path(hostpath)
end
Start the virtual machine via the cygwin terminal:
cd /cygdrive/c/Users/YourName/Dime/env
vagrant up
Download e.g. Dartium which is a Google Chrome for developpers:
https://www.dartlang.org/tools/dartium/
Start it by unzipping and executing the file chrome.exe
Go to the page http://dime.test.local (-> this page does not work in a normal browser!)
Generally the same steps as for Windows:
- Install VirtualBox, Vagrant and Dartium
- run "vagrant up" in the env/ folder
- Open in Dartium: http://dime.test.local
Default Vagrant File Sync on OSX is very slow, you may want to use rsync or nfs to speed things up
Update to last version
git pull
git submodule update
php composer.phar self-update
php composer.phar update -v
app/console assetic:dump
app/console assets:install --symlink
If you have any problem remove vendor and install again
rm -fR vendor
Update database
app/console doctrine:migrations:migrate
There are Multiple Bundle Seperated by features: TimetrackerBundle Base Entities and RestAPI for them OfferBundle Offer Entities ans RestAPI InvoiceBundle Invoice Entities and RestAPI PrintingBundle Service for Printing PDF's FrontendBundle The Javascript GUI SwoCommonsBundle Some Entities and Resources used by all our Applications
Please feel free to contribute issues, improvements and feedback.
For code contributions, Symfony2 Coding Standards are the way we want to go.
Please write in English and use the doc
folders for documentation and proposals rather than Github wiki.
The branches API and Frontend are gone. We switch now to feature branches. Every feature branch will be created from master. Here the steps to go.
Create remote feature branch:
git pull origin master
git push origin ISSUENO-and-a-short-description
git checkout -t ISSUENO-and-a-short-description
or for short bugfixing create only a local branch:
git pull origin master
git checkout -b ISSUENO-and-a-short-description
keep up to date with the master (not sure with this - have to test it):
git fetch origin master
git rebase orgin/master
if your work is done, merge back to master:
git checkout master
git fetch
git rebase
git merge ISSUENO-and-a-short-description
Finally remove remote feature branch:
git push origin :ISSUENO-and-a-short-description
and the local branch too:
git branch -d ISSUENO-and-a-short-description
Run tests:
phpunit -c app/
Run a single test:
phpunit -c app/ --filter ActivitiesControllerTest::testGetActivitiesAction
To build the JS & HTML files for deployment, run these commands inside the VM:
cd /vagrant/env && ./pub.sh build
Always build the frontend before merging into master!
Update Database Schema to the latest version:
php app/console doctrine:migrations:migrate
Migrate Database Schema to a specific version:
php app/console doctrine:migrations:migrate <version>
Generate new Empty Migration Class:
php app/console doctrine:migrations:generate
The fixtures are an example dataset that can be used while developing. But more important: the tests run against this database.
Load fixtures into the database:
/vagrant/env/fixtures/load_fixtures.sh
When the database schema changed, you need to regenerate the fixtures. You can do this with the following command:
cd /vagrant/env/fixtures/ && ./regenerate_fixtures.sh
Then export the changes again and check in the new dime.sql into git
cd /vagrant/env/fixtures/ && ./export_fixtures.sh