news-ai / tabulae

API for media list management
https://tabulae.newsai.org/
0 stars 0 forks source link

includes design #165

Open AbhiAgarwal opened 7 years ago

AbhiAgarwal commented 7 years ago

?includes=field_name,field_name

func get_includes

find right field in struct for field_name if field is int64: get all the includes for 1 object in db

if field is []int64: loop through each id get all the includes for 1 object in db

func get_all_includes look at the fields in the database and model they represent for the ids get the data from the database for that model