@property
    def project_media_data(self):
        return [{
            'license': m.license.type if m.license else 'public',
            'shared': self.domain in m.shared_by,
            'url': m.url(),
            'm_id': m._id,
            'tags': m.tags.get(self.domain, []),
            'type': m.doc_type,
        } for m in self.request.project.all_media()]
dataset/ETHPy150Open dimagi/commcare-hq/corehq/apps/domain/views.py/ManageProjectMediaView.project_media_data/original