'Returns absolute url of the previous page if there\'s a previous page available
otherwise returns None'

def get_previous_link(self):

    previous_url = None
    if self.page.has_previous():
        previous_url = replace_query_param(self.base_url, 'page', self.page.previous_page_number())
    return previous_url
