/*
 * Orvanta API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.2.0
 * Contact: contact@orvanta.cloud
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct OperatorSettings {
    /// Whether operators can view runs
    #[serde(rename = "runs")]
    pub runs: bool,
    /// Whether operators can view schedules
    #[serde(rename = "schedules")]
    pub schedules: bool,
    /// Whether operators can view resources
    #[serde(rename = "resources")]
    pub resources: bool,
    /// Whether operators can view variables
    #[serde(rename = "variables")]
    pub variables: bool,
    /// Whether operators can view assets
    #[serde(rename = "assets")]
    pub assets: bool,
    /// Whether operators can view audit logs
    #[serde(rename = "audit_logs")]
    pub audit_logs: bool,
    /// Whether operators can view triggers
    #[serde(rename = "triggers")]
    pub triggers: bool,
    /// Whether operators can view groups page
    #[serde(rename = "groups")]
    pub groups: bool,
    /// Whether operators can view folders page
    #[serde(rename = "folders")]
    pub folders: bool,
    /// Whether operators can view workers page
    #[serde(rename = "workers")]
    pub workers: bool,
}

impl OperatorSettings {
    pub fn new(runs: bool, schedules: bool, resources: bool, variables: bool, assets: bool, audit_logs: bool, triggers: bool, groups: bool, folders: bool, workers: bool) -> OperatorSettings {
        OperatorSettings {
            runs,
            schedules,
            resources,
            variables,
            assets,
            audit_logs,
            triggers,
            groups,
            folders,
            workers,
        }
    }
}

