chore: cleanup warnings and unused code
This commit is contained in:
1 parent
9925e753d8
commit
75a8f2d6d4
13 files changed
+6
-187
No files matched your search
@@ -1,35 +0,0 @@
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::collections::HashMap;
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
struct FormDefinition {
|
||||
sections: Vec<Section>,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
struct Section {
|
||||
questions: Vec<QuestionType>,
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
enum QuestionType {
|
||||
Text,
|
||||
Email,
|
||||
Number,
|
||||
Dropdown,
|
||||
Checkbox,
|
||||
Radio,
|
||||
Multi,
|
||||
}
|
||||
|
||||
struct TextInput {}
|
||||
|
||||
#[derive(Serialize, Deserialize)]
|
||||
struct QuestionComponent {
|
||||
question_type: QuestionType,
|
||||
label: Option<String>,
|
||||
placeholder: Option<String>,
|
||||
|
||||
// Used in <select> and <checkbox> elements
|
||||
options: Option<HashMap<String, String>>,
|
||||
}
|
||||
@@ -1,18 +0,0 @@
|
||||
#[derive(Clone)]
|
||||
pub struct LoanerUser {
|
||||
pub first_name: String,
|
||||
pub last_name: String,
|
||||
pub email: String,
|
||||
pub has_loan: bool,
|
||||
}
|
||||
|
||||
impl LoanerUser {
|
||||
pub fn new() -> Self {
|
||||
LoanerUser {
|
||||
first_name: "".to_string(),
|
||||
last_name: "".to_string(),
|
||||
email: "".to_string(),
|
||||
has_loan: false,
|
||||
}
|
||||
}
|
||||
}
|
||||
+1
-3
@@ -1,6 +1,4 @@
|
||||
mod form_definition;
|
||||
mod loaner_user;
|
||||
mod student_info;
|
||||
mod user;
|
||||
|
||||
pub use self::{loaner_user::*, student_info::*, user::*};
|
||||
pub use self::{student_info::*, user::*};
|
||||
Reference in new issue
Block a user