macro_rules! register_model_admin {
($ty:ty, $slug:expr, $label:expr $(,)?) => { ... };
}Expand description
Register a generic admin for a #[derive(Model)] type.
ⓘ
rustango_cms::register_model_admin!(crate::Author, "author", "Authors");
// → a chrome'd index at /cms-admin/model/author, columns from the
// model's admin(list_display = …).The model must derive serde::Serialize (rows are serialized to
JSON for the generic index).