added sorting to calendar models, related to #387