def published(self, for_user=None):
    '\n        For non-staff users, return items with a published status and\n        whose publish and expiry dates fall before and after the\n        current date when specified.\n        '
    from mezzanine.core.models import CONTENT_STATUS_PUBLISHED
    if ((for_user is not None) and for_user.is_staff):
        return self.all()
    return self.filter((Q(publish_date__lte=now()) | Q(publish_date__isnull=True)), (Q(expiry_date__gte=now()) | Q(expiry_date__isnull=True)), Q(status=CONTENT_STATUS_PUBLISHED))
For non-staff users, return items with a published status and
whose publish and expiry dates fall before and after the
current date when specified.
def published(self, for_user=None):
    '\n        For non-staff users, return items with a published status and\n        whose publish and expiry dates fall before and after the\n        current date when specified.\n        '
    from mezzanine.core.models import CONTENT_STATUS_PUBLISHED
    if ((for_user is not None) and for_user.is_staff):
        return self.all()
    return self.filter((Q(publish_date__lte=now()) | Q(publish_date__isnull=True)), (Q(expiry_date__gte=now()) | Q(expiry_date__isnull=True)), Q(status=CONTENT_STATUS_PUBLISHED))