src/hdalab/views/ajax.py
changeset 702 2a6e667b1610
parent 620 f45d7494332e
equal deleted inserted replaced
691:8454f9cda0ca 702:2a6e667b1610
   122                 'id': datasheet.id,
   122                 'id': datasheet.id,
   123                 'title': datasheet.title,
   123                 'title': datasheet.title,
   124                 'url': datasheet.url,
   124                 'url': datasheet.url,
   125                 'description': datasheet.description,
   125                 'description': datasheet.description,
   126                 'hda_id': datasheet.hda_id,
   126                 'hda_id': datasheet.hda_id,
   127                 'organization': datasheet.organisation.name,
   127                 'organization': datasheet.organisation.name if datasheet.organisation else "",
   128                 'organization_url': datasheet.organisation.website,
   128                 'organization_url': datasheet.organisation.website if datasheet.organisation else "",
   129                 'score': max(dsscore, rootscore)
   129                 'score': max(dsscore, rootscore)
   130             })
   130             })
   131     if resobj:
   131     if resobj:
   132         cleantags(resobj)
   132         cleantags(resobj)
   133     elif len(master_category):
   133     elif len(master_category):