added db request of rules to routes (auto added to segments), began work on Models for Segments