Beispiel #1
0
def extract_link(links):
    """
    This function extract elements in a string according to the $$ delimiter
    :param links: Links to extract data from
    :return: list of strings
    """
    return to_list(links)[0].split('$$')[1][1:]
Beispiel #2
0
def extract_link(links):
    """
    This function extract elements in a string according to the $$ delimiter
    :param links: Links to extract data from
    :return: list of strings
    """
    return to_list(links)[0].split("$$")[1][1:]
Beispiel #3
0
 def _get_results(self):
     search = self._search()
     if search.get('DOC'):
         return [
             item['PrimoNMBib']['record'] for item in to_list(search['DOC'])
             if item.get('PrimoNMBib') and item['PrimoNMBib'].get('record')
         ]
     return []
Beispiel #4
0
def generate_thumb_link(rosetta_links):
    """
    This function returns a thumbnail link
    :param rosetta_links: links that contain IE PID in them
    :return: the IE PID
    """
    ies = [find_ie(link).group(1) for link in to_list(rosetta_links) if find_ie(link)]
    if ies:
        return ies
    return ""
Beispiel #5
0
def generate_thumb_link(rosetta_links):
    """
    This function returns a thumbnail link
    :param rosetta_links: links that contain IE PID in them
    :return: the IE PID
    """
    ies = [
        find_ie(link).group(1) for link in to_list(rosetta_links)
        if find_ie(link)
    ]
    if ies:
        return ies
    return ''
 def _get_results(self):
     search = self._search()
     if search.get('DOC'):
         return [item['PrimoNMBib']['record'] for item in to_list(search['DOC']) if
                 item.get('PrimoNMBib') and item['PrimoNMBib'].get('record')]
     return []