<s> from . models import * <EOL> PARTNER_TYPE_CUSTOMER = <NUM_LIT:1> <EOL> PARTNER_TYPE_PROVIDER = <NUM_LIT:2> <EOL> class TypedPartners ( Partners ) : <EOL> partner_type_pk = None <EOL> @ classmethod <EOL> def get_request_queryset ( cls , ar ) : <EOL> qs = super ( TypedPartners , cls ) . get_request_queryset ( ar ) <EOL> return qs . filter ( type__id = cls . partner_type_pk ) <EOL> @ classmethod <EOL> def get_actor_label ( cls ) : <EOL> if cls . partner_type_pk is None : <EOL> return super ( TypedPartners , cls ) . get_actor_label ( ) <EOL> pt = PartnerType . objects . get ( pk = cls . partner_type_pk ) <EOL> return pt . name <EOL> class Customers ( TypedPartners ) : <EOL> partner_type_pk = PARTNER_TYPE_CUSTOMER <EOL> class Providers ( TypedPartners ) : <EOL> partner_type_pk = PARTNER_TYPE_PROVIDER </s>
