def derive_filename(self):
        filename = getattr(self, 'filename', None)
        if not filename:
            filename = "%s.xls" % self.model._meta.verbose_name.lower()
        return filename
dataset/ETHPy150Open nyaruka/smartmin/smartmin/views.py/SmartXlsView.derive_filename/original