return get_full_url(reverse('telemeta-collection-detail', kwargs={'public_id':self.pk}))
def to_dict_with_more(self):
- metadata = model_to_dict(self, fields=[], exclude=self.exclude)
+ # metadata = model_to_dict(self, fields=[], exclude=self.exclude)
+ metadata = self.to_dict()
+ for key in self.exclude:
+ metadata.remove(key)
metadata['url'] = get_full_url(reverse('telemeta-collection-detail', kwargs={'public_id':self.pk}))
metadata['doc_status'] = self.document_status()
metadata['countries'] = ';'.join([location.name for location in self.main_countries()])
return get_full_url(reverse('telemeta-item-detail', kwargs={'public_id':self.pk}))
def to_dict_with_more(self):
- metadata = model_to_dict(self, fields=[], exclude=self.exclude)
+ # metadata = model_to_dict(self, fields=[], exclude=self.exclude)
+ metadata = self.to_dict()
+ for key in self.exclude:
+ metadata.remove(key)
metadata['url'] = self.get_url()
metadata['last_modification_date'] = unicode(self.get_revision().time)
metadata['collection'] = self.collection.get_url()