def get_model_label(model):
 if isinstance(model, six.string_types):
  return model
 else:
  return ('%s.%s' % (model._meta.app_label, model.__name__))

def get_model_label ( model ) : if isinstance ( model , six . string_types ) : return model else : return ( '%s.%s' % ( model . _meta . app_label , model . __name__ ) )
take a model class or model label and return its model label .