refactor(api): split Axum handlers into handler/service/repo modules
Keep the REST contract; move domain logic out of route files so checkout, fulfillment, and identity can be reused across customer, shop, and admin surfaces. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
co-authored by
Cursor
parent
e457339847
commit
5e866d08f4
@@ -0,0 +1,30 @@
|
||||
pub mod address;
|
||||
pub mod billing;
|
||||
pub mod cart;
|
||||
pub mod catalog;
|
||||
pub mod content;
|
||||
pub mod currency;
|
||||
pub mod fulfillment;
|
||||
pub mod health;
|
||||
pub mod identity;
|
||||
pub mod order;
|
||||
pub mod shop;
|
||||
|
||||
use axum::Router;
|
||||
|
||||
use crate::state::AppState;
|
||||
|
||||
pub fn api_router() -> Router<AppState> {
|
||||
Router::new()
|
||||
.merge(health::router())
|
||||
.merge(address::router())
|
||||
.merge(identity::router())
|
||||
.merge(currency::router())
|
||||
.merge(catalog::router())
|
||||
.merge(content::router())
|
||||
.merge(cart::router())
|
||||
.merge(order::router())
|
||||
.merge(shop::router())
|
||||
.merge(fulfillment::router())
|
||||
.merge(billing::router())
|
||||
}
|
||||
Reference in New Issue
Block a user