(State(ctx): State<AppContext>)
| 27 | |
| 28 | #[debug_handler] |
| 29 | pub async fn list(State(ctx): State<AppContext>) -> Result<Response> { |
| 30 | format::json(Entity::find().all(&ctx.db).await?) |
| 31 | } |
| 32 | |
| 33 | #[debug_handler] |
| 34 | pub async fn add(State(ctx): State<AppContext>, Json(params): Json<Params>) -> Result<Response> { |