pub struct ActiveModelEx {
pub id: ActiveValue<ShowId>,
pub title: ActiveValue<String>,
pub tagline: ActiveValue<String>,
pub overview: ActiveValue<String>,
pub date: ActiveValue<NaiveDate>,
pub sort_title: ActiveValue<String>,
pub fs_slug: ActiveValue<String>,
pub web_slug: ActiveValue<String>,
pub seasons: ActiveHasMany<Entity>,
pub episodes: ActiveHasMany<Entity>,
pub content: ActiveHasOne<Entity>,
}Expand description
Generated by sea-orm-macros
Fields§
§id: ActiveValue<ShowId>Generated by sea-orm-macros
title: ActiveValue<String>Generated by sea-orm-macros
tagline: ActiveValue<String>Generated by sea-orm-macros
overview: ActiveValue<String>Generated by sea-orm-macros
date: ActiveValue<NaiveDate>Generated by sea-orm-macros
sort_title: ActiveValue<String>Generated by sea-orm-macros
fs_slug: ActiveValue<String>Generated by sea-orm-macros
web_slug: ActiveValue<String>Generated by sea-orm-macros
seasons: ActiveHasMany<Entity>Generated by sea-orm-macros
episodes: ActiveHasMany<Entity>Generated by sea-orm-macros
content: ActiveHasOne<Entity>Generated by sea-orm-macros
Implementations§
Source§impl ActiveModelEx
impl ActiveModelEx
Sourcepub async fn insert<'a, C>(self, db: &'a C) -> Result<ModelEx, DbErr>where
C: TransactionTrait,
pub async fn insert<'a, C>(self, db: &'a C) -> Result<ModelEx, DbErr>where
C: TransactionTrait,
Generated by sea-orm-macros
Sourcepub async fn update<'a, C>(self, db: &'a C) -> Result<ModelEx, DbErr>where
C: TransactionTrait,
pub async fn update<'a, C>(self, db: &'a C) -> Result<ModelEx, DbErr>where
C: TransactionTrait,
Generated by sea-orm-macros
Sourcepub async fn save<'a, C>(self, db: &'a C) -> Result<Self, DbErr>where
C: TransactionTrait,
pub async fn save<'a, C>(self, db: &'a C) -> Result<Self, DbErr>where
C: TransactionTrait,
Generated by sea-orm-macros
Sourcepub async fn delete<'a, C>(self, db: &'a C) -> Result<DeleteResult, DbErr>where
C: TransactionTrait,
pub async fn delete<'a, C>(self, db: &'a C) -> Result<DeleteResult, DbErr>where
C: TransactionTrait,
Generated by sea-orm-macros
Sourcepub async fn action<'a, C>(
self,
action: ActiveModelAction,
db: &'a C,
) -> Result<Self, DbErr>where
C: TransactionTrait,
pub async fn action<'a, C>(
self,
action: ActiveModelAction,
db: &'a C,
) -> Result<Self, DbErr>where
C: TransactionTrait,
Generated by sea-orm-macros
Sourcepub fn set_tagline(self, v: impl Into<String>) -> Self
pub fn set_tagline(self, v: impl Into<String>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_overview(self, v: impl Into<String>) -> Self
pub fn set_overview(self, v: impl Into<String>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_sort_title(self, v: impl Into<String>) -> Self
pub fn set_sort_title(self, v: impl Into<String>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_fs_slug(self, v: impl Into<String>) -> Self
pub fn set_fs_slug(self, v: impl Into<String>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_web_slug(self, v: impl Into<String>) -> Self
pub fn set_web_slug(self, v: impl Into<String>) -> Self
Generated by sea-orm-macros
Sourcepub fn add_season(self, v: impl Into<ActiveModelEx>) -> Self
pub fn add_season(self, v: impl Into<ActiveModelEx>) -> Self
Generated by sea-orm-macros
Sourcepub fn add_episode(self, v: impl Into<ActiveModelEx>) -> Self
pub fn add_episode(self, v: impl Into<ActiveModelEx>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_content(self, v: impl Into<ActiveModelEx>) -> Self
pub fn set_content(self, v: impl Into<ActiveModelEx>) -> Self
Generated by sea-orm-macros
Sourcepub fn set_content_option(self, v: Option<impl Into<ActiveModelEx>>) -> Self
pub fn set_content_option(self, v: Option<impl Into<ActiveModelEx>>) -> Self
Generated by sea-orm-macros
Sourcepub fn clear_content(self) -> Self
pub fn clear_content(self) -> Self
Generated by sea-orm-macros
Trait Implementations§
Source§impl ActiveModelTrait for ActiveModelEx
impl ActiveModelTrait for ActiveModelEx
Source§fn is_changed(&self) -> bool
fn is_changed(&self) -> bool
Returns true if any field is set or changed. This is recursive.
Source§type Entity = Entity
type Entity = Entity
EntityTrait this ActiveModel belongs to.Source§fn take(
&mut self,
c: <Self::Entity as EntityTrait>::Column,
) -> ActiveValue<Value>
fn take( &mut self, c: <Self::Entity as EntityTrait>::Column, ) -> ActiveValue<Value>
ActiveValue of a column, leaving it as NotSet.Source§fn get(&self, c: <Self::Entity as EntityTrait>::Column) -> ActiveValue<Value>
fn get(&self, c: <Self::Entity as EntityTrait>::Column) -> ActiveValue<Value>
ActiveValue of a column.Source§fn set_if_not_equals(
&mut self,
c: <Self::Entity as EntityTrait>::Column,
v: Value,
)
fn set_if_not_equals( &mut self, c: <Self::Entity as EntityTrait>::Column, v: Value, )
Set(v) only if v differs from the current value,
avoiding spurious UPDATE rewrites. Panics on type mismatch.Source§fn try_set(
&mut self,
c: <Self::Entity as EntityTrait>::Column,
v: Value,
) -> Result<(), DbErr>
fn try_set( &mut self, c: <Self::Entity as EntityTrait>::Column, v: Value, ) -> Result<(), DbErr>
Set(v), returning an error on type mismatch.Source§fn not_set(&mut self, c: <Self::Entity as EntityTrait>::Column)
fn not_set(&mut self, c: <Self::Entity as EntityTrait>::Column)
NotSet so it is omitted from the next INSERT or
UPDATE.Source§fn is_not_set(&self, c: <Self::Entity as EntityTrait>::Column) -> bool
fn is_not_set(&self, c: <Self::Entity as EntityTrait>::Column) -> bool
true if the column is currently in the NotSet state.Source§fn default_values() -> Self
fn default_values() -> Self
Set(default_value) for each
column that has a Default impl; other columns remain NotSet.Source§fn set(&mut self, c: <Self::Entity as EntityTrait>::Column, v: Value)
fn set(&mut self, c: <Self::Entity as EntityTrait>::Column, v: Value)
Set(v). Panics on type mismatch; prefer
try_set when the value comes from untrusted input.Source§fn get_primary_key_value(&self) -> Option<ValueTuple>
fn get_primary_key_value(&self) -> Option<ValueTuple>
ValueTuple, or None if any primary-key
column is still NotSet.Source§impl Clone for ActiveModelEx
impl Clone for ActiveModelEx
Source§fn clone(&self) -> ActiveModelEx
fn clone(&self) -> ActiveModelEx
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ActiveModelEx
impl Debug for ActiveModelEx
Source§impl Default for ActiveModelEx
impl Default for ActiveModelEx
Source§impl From<ActiveModel> for ActiveModelEx
impl From<ActiveModel> for ActiveModelEx
Source§fn from(m: ActiveModel) -> Self
fn from(m: ActiveModel) -> Self
Source§impl From<ActiveModelEx> for ActiveModel
impl From<ActiveModelEx> for ActiveModel
Source§fn from(m: ActiveModelEx) -> Self
fn from(m: ActiveModelEx) -> Self
Source§impl From<ModelEx> for ActiveModelEx
impl From<ModelEx> for ActiveModelEx
Source§impl IntoActiveModel<ActiveModelEx> for ModelEx
impl IntoActiveModel<ActiveModelEx> for ModelEx
Source§fn into_active_model(self) -> ActiveModelEx
fn into_active_model(self) -> ActiveModelEx
Source§impl PartialEq for ActiveModelEx
impl PartialEq for ActiveModelEx
impl StructuralPartialEq for ActiveModelEx
Source§impl TryFrom<ActiveModelEx> for ModelEx
impl TryFrom<ActiveModelEx> for ModelEx
Source§impl TryIntoModel<ModelEx> for ActiveModelEx
impl TryIntoModel<ModelEx> for ActiveModelEx
Auto Trait Implementations§
impl Freeze for ActiveModelEx
impl RefUnwindSafe for ActiveModelEx
impl Send for ActiveModelEx
impl Sync for ActiveModelEx
impl Unpin for ActiveModelEx
impl UnsafeUnpin for ActiveModelEx
impl UnwindSafe for ActiveModelEx
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<A> IntoActiveModel<A> for Awhere
A: ActiveModelTrait,
impl<A> IntoActiveModel<A> for Awhere
A: ActiveModelTrait,
Source§fn into_active_model(self) -> A
fn into_active_model(self) -> A
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more