pub struct FormField {
pub id: String,
pub label: String,
pub field_type: FieldType,
pub required: bool,
pub description: Option<String>,
pub value: Option<Value>,
pub choices: Vec<String>,
pub choice_values: Vec<Value>,
pub constraints: BTreeMap<String, Value>,
}Fields§
§id: String§label: String§field_type: FieldType§required: bool§description: Option<String>§value: Option<Value>§choices: Vec<String>§choice_values: Vec<Value>Exact JSON values represented by choices. The legacy display labels
remain strings for renderer compatibility; this parallel vector keeps
booleans and integers from being coerced through presentation text.
constraints: BTreeMap<String, Value>Trait Implementations§
Source§impl<'de> Deserialize<'de> for FormField
impl<'de> Deserialize<'de> for FormField
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for FormField
Auto Trait Implementations§
impl Freeze for FormField
impl RefUnwindSafe for FormField
impl Send for FormField
impl Sync for FormField
impl Unpin for FormField
impl UnsafeUnpin for FormField
impl UnwindSafe for FormField
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more