Workorder stuff

Added foundation for workorders