Open slamer59 opened 3 years ago
@slamer59 thanks for this! Did you want to submit this as a PR? If not I can update it :)
I agree with you, some more detailed docs for the memory CrudRouter would be useful.
@awtkns i can do !
What would be great is that we include exemple with get and post accessing with in Memory backend.
What do you think ?
Unfortunately I don't know how to do. If you give the exemple, I write the full doc.
Thanks !
I don't know if it a good practice but we can access router models with:
@router.get('')
def overloaded_get_all():
return router.models
@router.get('/{item_id}')
def overloaded_get_one(item_id: int):
return router.models[item_id]
is working.
@awtkns tell me if I add it like that in the documentation or not ?
Thanks :)
Sorry for taking awhile to reply. I think that would be add good thing to also add, it could definitely be useful :)
Is it ok to close this now @slamer59 ?
Yes me too. Do you have time to provide me some snippet for it ? Not much time on my side but I can try.
https://fastapi-crudrouter.awtkns.com/routing
"Working"
Is it possible to provide an exemple to show what to do with MemoryCRUDRouter instead of a string ? Regards