backbone-mail 0.2.32

Odoo mail core port — message/notification/followers/activity/alias/sms queue (schema: messaging)
//! Validator for MailFollowers entity
//!
//! Generated by metaphor-schema. Do not edit manually.
//!
//! Returns an `EntityValidator<MailFollowers>` pre-loaded with schema-derived
//! field rules. Extend in the `// <<< CUSTOM` zone.

use backbone_core::{EntityValidator, ValidationErrors, ValidationError};
use backbone_core::{RequiredString};
use crate::domain::entity::MailFollowers;

/// Validator type alias for MailFollowers entities.
pub type MailFollowersValidator = EntityValidator<MailFollowers>;

/// Build a validator for MailFollowers with all schema-defined field rules.
pub fn mail_followers_validator() -> MailFollowersValidator {
    EntityValidator::new()
        .rule(RequiredString::new("res_model", |e: &MailFollowers| &e.res_model))
    // <<< CUSTOM RULES
    // hook rule: G-MAIL-1 (implement in CUSTOM zone)
    // END CUSTOM RULES
}

// <<< CUSTOM
// END CUSTOM