def find_view_name(request):
    """find the view name
    TODO: I believe this is not completely generic.
    """
    name = None
    if request.matchdict and 'method' in request.matchdict:
        name = request.matchdict['method']
    else:
        name = request.path_info
    if name.startswith('/'):
        name = name[1:]
    if hasattr(request, 'matched_route') and request.matched_route:
        if name in request.matched_route.name:
            if request.method == 'POST':
                name = 'edit'
            elif request.method == 'GET':
                name = 'get'
    return name
