Пример #1
0
 def get(self, request, *arg):
     """Gather the user's trips and return the homepage"""
     markers = trip_marker_set(request)
     invited_markers = markers['invited']
     upcoming_markers = markers['upcoming']
     past_markers = markers['past']
     context = {'camper': request.user.camper,
                'invited_locations': mark_safe(invited_markers),
                'upcoming_locations': mark_safe(upcoming_markers),
                'past_locations': mark_safe(past_markers),
                }
     return render(request, 'user/home.html', context)
Пример #2
0
 def get(self, request, *arg):
     """Gather the user's trips and return the homepage"""
     markers = trip_marker_set(request)
     invited_markers = markers['invited']
     upcoming_markers = markers['upcoming']
     past_markers = markers['past']
     context = {
         'camper': request.user.camper,
         'invited_locations': mark_safe(invited_markers),
         'upcoming_locations': mark_safe(upcoming_markers),
         'past_locations': mark_safe(past_markers),
     }
     return render(request, 'user/home.html', context)
Пример #3
0
    def get(self, request, *arg):
        """Gather the user's trips and return the all locations page"""

        markers = trip_marker_set(request)
        invited_markers = markers['invited']
        upcoming_markers = markers['upcoming']
        past_markers = markers['past']
        context = {'camper': request.user.camper,
                   'invited_locations': mark_safe(invited_markers),
                   'upcoming_locations': mark_safe(upcoming_markers),
                   'past_locations': mark_safe(past_markers),
                   }
        return render_to_response(template_name='location/all.html',
                                  context=context,
                                  context_instance=RequestContext(request))
Пример #4
0
    def get(self, request, *arg):
        """Gather the user's trips and return the all locations page"""

        markers = trip_marker_set(request)
        invited_markers = markers['invited']
        upcoming_markers = markers['upcoming']
        past_markers = markers['past']
        context = {
            'camper': request.user.camper,
            'invited_locations': mark_safe(invited_markers),
            'upcoming_locations': mark_safe(upcoming_markers),
            'past_locations': mark_safe(past_markers),
        }
        return render_to_response(template_name='location/all.html',
                                  context=context,
                                  context_instance=RequestContext(request))