sort by priority and due_date, fitering commplited tasks