create a dedicated method for count loop function
Added a way to create orders outside of the front-office context.
Merge branch 'optim' of https://github.com/thelia/thelia into optim

Conflicts:
	core/lib/Thelia/Action/Order.php
	core/lib/Thelia/Core/Template/Element/BaseLoop.php