MCPcopy Create free account
hub / github.com/SeaQL/sea-orm / new

Function new

examples/poem_example/api/src/lib.rs:68–75  ·  view source on GitHub ↗
(state: Data<&AppState>)

Source from the content-addressed store, hash-verified

66
67#[handler]
68async fn new(state: Data<&AppState>) -> Result<impl IntoResponse> {
69 let ctx = tera::Context::new();
70 let body = state
71 .templates
72 .render("new.html.tera", &ctx)
73 .map_err(InternalServerError)?;
74 Ok(Html(body))
75}
76
77#[handler]
78async fn edit(state: Data<&AppState>, Path(id): Path<i32>) -> Result<impl IntoResponse> {

Callers 15

listFunction · 0.70
editFunction · 0.70
startFunction · 0.70
run_migrate_commandFunction · 0.50
run_migrate_generateFunction · 0.50
get_full_migration_dirFunction · 0.50
update_migratorFunction · 0.50
test_update_migratorFunction · 0.50
run_generate_commandFunction · 0.50
sqlx_connectFunction · 0.50
expand_derive_relationFunction · 0.50

Calls

no outgoing calls

Tested by 15

test_update_migratorFunction · 0.40
test_convert_caseFunction · 0.40
test_load_macro_input_1Function · 0.40
test_load_macro_input_2Function · 0.40
test_convert_caseFunction · 0.40
test_transaction_1Function · 0.40
test_transaction_2Function · 0.40
test_stream_1Function · 0.40
test_stream_2Function · 0.40