21 lines
528 B
Rust
21 lines
528 B
Rust
// src/company/struct.rs
|
|
use serde::{Deserialize, Serialize};
|
|
use sqlx::FromRow;
|
|
use chrono::NaiveDate;
|
|
|
|
#[derive(Debug, Serialize, Deserialize, FromRow)]
|
|
pub struct Company {
|
|
pub id: i32,
|
|
pub active: bool,
|
|
pub created: NaiveDate,
|
|
pub name: String,
|
|
pub address: Option<String>,
|
|
pub town: Option<String>,
|
|
pub state: Option<String>,
|
|
pub phone: Option<i64>,
|
|
pub owner_name: Option<String>,
|
|
pub owner_phone_number: Option<i64>,
|
|
pub email: Option<String>,
|
|
pub user_id: Option<i32>,
|
|
}
|
|
|