2025-10-01 22:36:19 -07:00
|
|
|
use std::collections::HashMap;
|
|
|
|
|
|
2025-11-19 01:45:58 +00:00
|
|
|
use phono_models::{field::Field, language::Language};
|
2025-08-13 18:52:37 -07:00
|
|
|
use serde::Serialize;
|
|
|
|
|
|
|
|
|
|
#[derive(Clone, Debug, Serialize)]
|
2025-10-01 22:36:19 -07:00
|
|
|
pub(crate) struct TableFieldInfo {
|
|
|
|
|
pub(crate) field: Field,
|
|
|
|
|
pub(crate) column_present: bool,
|
|
|
|
|
pub(crate) has_default: bool,
|
|
|
|
|
pub(crate) not_null: bool,
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#[derive(Clone, Debug, Serialize)]
|
|
|
|
|
pub(crate) struct FormFieldInfo {
|
|
|
|
|
pub(crate) field: Field,
|
|
|
|
|
pub(crate) column_present: bool,
|
|
|
|
|
pub(crate) has_default: bool,
|
|
|
|
|
pub(crate) not_null: bool,
|
|
|
|
|
pub(crate) prompts: HashMap<Language, String>,
|
2025-08-13 18:52:37 -07:00
|
|
|
}
|