chore: 移除Welds库依赖并简化项目结构

- 移除对Welds库的依赖及相关数据模型定义以简化项目结构。
This commit is contained in:
2025-08-19 22:46:52 +08:00
parent 6e2b811373
commit 9131358716

View File

@@ -7,23 +7,10 @@ use axum::{
use chrono::{prelude::*, Duration, ParseError}; use chrono::{prelude::*, Duration, ParseError};
use serde::{Deserialize, Serialize}; use serde::{Deserialize, Serialize};
use std::{env, ops::Deref, sync::Arc}; use std::{env, ops::Deref, sync::Arc};
use welds::prelude::*;
mod db; mod db;
mod generate; mod generate;
#[derive(WeldsModel)]
#[welds(table = "authorize")]
pub struct Authorize {
#[welds(primary_key)]
pub id: i32,
pub project: String,
pub key: String,
pub device_id: String,
pub expire: String,
pub insert_time: String,
}
#[tokio::main] #[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> { async fn main() -> Result<(), Box<dyn std::error::Error>> {
// 根据操作系统选择数据库路径 // 根据操作系统选择数据库路径