mirror of
https://github.com/jlengrand/engine.git
synced 2026-03-10 08:11:21 +00:00
Allow router to be deleted
This commit is contained in:
committed by
Erèbe - Romain Gerard
parent
9a0d659f19
commit
642e53de4c
@@ -18,6 +18,7 @@ pub struct Router {
|
||||
context: Context,
|
||||
id: String,
|
||||
name: String,
|
||||
action: Action,
|
||||
default_domain: String,
|
||||
custom_domains: Vec<CustomDomain>,
|
||||
routes: Vec<Route>,
|
||||
@@ -29,6 +30,7 @@ impl Router {
|
||||
context: Context,
|
||||
id: &str,
|
||||
name: &str,
|
||||
action: Action,
|
||||
default_domain: &str,
|
||||
custom_domains: Vec<CustomDomain>,
|
||||
routes: Vec<Route>,
|
||||
@@ -38,6 +40,7 @@ impl Router {
|
||||
context,
|
||||
id: id.to_string(),
|
||||
name: name.to_string(),
|
||||
action,
|
||||
default_domain: default_domain.to_string(),
|
||||
custom_domains,
|
||||
routes,
|
||||
@@ -72,7 +75,7 @@ impl Service for Router {
|
||||
}
|
||||
|
||||
fn action(&self) -> &Action {
|
||||
&Action::Create
|
||||
&self.action
|
||||
}
|
||||
|
||||
fn private_port(&self) -> Option<u16> {
|
||||
|
||||
@@ -21,6 +21,7 @@ use crate::models::{Context, Listen, Listener, Listeners};
|
||||
pub struct Router {
|
||||
context: Context,
|
||||
id: String,
|
||||
action: Action,
|
||||
name: String,
|
||||
default_domain: String,
|
||||
custom_domains: Vec<CustomDomain>,
|
||||
@@ -33,6 +34,7 @@ impl Router {
|
||||
context: Context,
|
||||
id: &str,
|
||||
name: &str,
|
||||
action: Action,
|
||||
default_domain: &str,
|
||||
custom_domains: Vec<CustomDomain>,
|
||||
routes: Vec<Route>,
|
||||
@@ -42,6 +44,7 @@ impl Router {
|
||||
context,
|
||||
id: id.to_string(),
|
||||
name: name.to_string(),
|
||||
action,
|
||||
default_domain: default_domain.to_string(),
|
||||
custom_domains,
|
||||
routes,
|
||||
@@ -76,7 +79,7 @@ impl Service for Router {
|
||||
}
|
||||
|
||||
fn action(&self) -> &Action {
|
||||
&Action::Create
|
||||
&self.action
|
||||
}
|
||||
|
||||
fn private_port(&self) -> Option<u16> {
|
||||
|
||||
@@ -430,6 +430,7 @@ impl Router {
|
||||
context.clone(),
|
||||
self.id.as_str(),
|
||||
self.name.as_str(),
|
||||
self.action.to_service_action(),
|
||||
self.default_domain.as_str(),
|
||||
custom_domains,
|
||||
routes,
|
||||
@@ -443,6 +444,7 @@ impl Router {
|
||||
context.clone(),
|
||||
self.id.as_str(),
|
||||
self.name.as_str(),
|
||||
self.action.to_service_action(),
|
||||
self.default_domain.as_str(),
|
||||
custom_domains,
|
||||
routes,
|
||||
|
||||
Reference in New Issue
Block a user