Fixed flows in route manager.
Improved flow helpers to make it more generic.