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

Method get_options

fastapi_admin/widgets/inputs.py:127–130  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

125 self.model = model
126
127 async def get_options(self):
128 ret = await self.get_queryset()
129 options = [dict(label=str(x), value=x.pk) for x in ret]
130 return options
131
132 async def get_queryset(self):
133 return await self.model.all()

Callers 1

renderMethod · 0.95

Calls 1

get_querysetMethod · 0.95

Tested by

no test coverage detected