mirror of
https://gitlab.com/msrd0/gotham-restful.git
synced 2025-04-20 06:54:46 +00:00
add more schema titles
This commit is contained in:
parent
84ff8acc68
commit
0619e69925
2 changed files with 24 additions and 2 deletions
|
@ -45,7 +45,18 @@ macro_rules! rest_struct {
|
|||
properties.insert(
|
||||
stringify!($field_id).to_string(),
|
||||
ReferenceOr::Item(Box::new(Schema {
|
||||
schema_data: SchemaData::default(),
|
||||
schema_data: SchemaData {
|
||||
nullable: false,
|
||||
read_only: false,
|
||||
write_only: false,
|
||||
deprecated: false,
|
||||
external_docs: None,
|
||||
example: None,
|
||||
title: <$field_ty>::schema_name(),
|
||||
description: None,
|
||||
discriminator: None,
|
||||
default: None
|
||||
},
|
||||
schema_kind: <$field_ty>::to_schema()
|
||||
}))
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue