MCPcopy Index your code
hub / github.com/fastapi-admin/fastapi-admin / get_m2m_field

Method get_m2m_field

fastapi_admin/resources.py:283–290  ·  view source on GitHub ↗
(cls)

Source from the content-addressed store, hash-verified

281
282 @classmethod
283 def get_m2m_field(cls):
284 ret = []
285 for field in cls.fields or cls.model._meta.fields:
286 if isinstance(field, Field):
287 field = field.name
288 if field in cls.model._meta.m2m_fields:
289 ret.append(field)
290 return ret
291
292
293class Dropdown(Resource):

Callers 1

updateFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected