Returns all outlets that are currently active and have sales.
764746
def active(self):
        """"""
        qs = self.get_queryset()
        return qs.filter(
            models.Q(
                models.Q(start_date__isnull=True) |
                models.Q(start_date__lte=now().date())
            ) &
            models.Q(
                models.Q(end_date__isnull=True) |
                models.Q(end_date__gte=now().date())
            )
        ).distinct()
197504
@Override
	public List<CommerceDiscount> findByLtE_S(Date expirationDate, int status) {
		return findByLtE_S(expirationDate, status, QueryUtil.ALL_POS,
			QueryUtil.ALL_POS, null);
	}
264973
@Override
	public List<CommerceWarehouseItem> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
875571
@Override
	public List<CommerceCountry> findByG_B_A(long groupId,
		boolean billingAllowed, boolean active) {
		return findByG_B_A(groupId, billingAllowed, active, QueryUtil.ALL_POS,
			QueryUtil.ALL_POS, null);
	}
218152
def fetch_remaining_instances(self):
        """"""
        if self.remaining_items:
            self.remaining_items = ContentItem.objects.get_real_instances(self.remaining_items)
1369757
function _get_all_items(){
	var ret_filters = [];
	var complete_filters = bbop.core.get_keys(anchor.current_data);
	for( var cfi = 0; cfi < complete_filters.length; cfi++ ){
	    var test_filter = complete_filters[cfi];
	    if( test_filter != '_nil_' ){
		ret_filters.push(test_filter);
	    }
	}
	return ret_filters;
    }
84252
def relatedItems(self):
        '''
        
        '''
        if self.registration:
            return self.registration.revenueitem_set.exclude(pk=self.pk)
608967
def items(self):
        ''''''
        if hasattr(self, '_items'):
            return self.filter_items(self._items)
        self._items = self.get_items()
        return self.filter_items(self._items)
1311014
public List<AggregationDistinctSelectItem> getAggregationDistinctSelectItems() {
        List<AggregationDistinctSelectItem> result = new LinkedList<>();
        for (SelectItem each : items) {
            if (each instanceof AggregationDistinctSelectItem) {
                result.add((AggregationDistinctSelectItem) each);
            }
        }
        return result;
    }
945345
@Override
	public List<CommerceUserSegmentCriterion> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
694959
def get_active_entry(user, select_for_update=False):
    """"""
    entries = apps.get_model('entries', 'Entry').no_join
    if select_for_update:
        entries = entries.select_for_update()
    entries = entries.filter(user=user, end_time__isnull=True)

    if not entries.exists():
        return None
    if entries.count() > 1:
        raise ActiveEntryError('Only one active entry is allowed.')
    return entries[0]
1027073
@Override
	public List<CommerceCurrency> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
144471
@Override
	public List<CommerceAddressRestriction> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}
1374762
def active(self):
        
        qset = super(StaffMemberManager, self).get_queryset()
        return qset.filter(is_active=True)
39787
def active_brokers(self):
        """"""
        return {
            broker
            for broker in self._brokers
            if not broker.inactive and not broker.decommissioned
        }
872111
public static List<CommerceCountry> findByG_B_A(long groupId,
		boolean billingAllowed, boolean active) {
		return getPersistence().findByG_B_A(groupId, billingAllowed, active);
	}
659977
@Override
	public List<CommerceDiscountRel> findAll() {
		return findAll(QueryUtil.ALL_POS, QueryUtil.ALL_POS, null);
	}