pub struct BulkWritableJobButtonRequest {
pub id: Uuid,
pub content_types: Vec<String>,
pub name: String,
pub enabled: Option<bool>,
pub text: String,
pub weight: Option<i32>,
pub group_name: Option<String>,
pub button_class: Option<ButtonClassEnum>,
pub confirmation: Option<bool>,
pub job: Box<BulkWritableJobButtonRequestJob>,
}Expand description
BulkWritableJobButtonRequest : Extends the built-in ModelSerializer to enforce calling full_clean() on a copy of the associated instance during validation. (DRF does not do this by default; see https://github.com/encode/django-rest-framework/issues/3144)
Fields§
§id: Uuid§content_types: Vec<String>§name: String§enabled: Option<bool>§text: StringJinja2 template code for button text. Reference the object as {{ obj }} such as {{ obj.platform.name }}. Buttons which render as empty text will not be displayed.
weight: Option<i32>§group_name: Option<String>Buttons with the same group will appear as a dropdown menu. Group dropdown buttons will inherit the button class from the button with the lowest weight in the group.
confirmation: Option<bool>Enable confirmation pop-up box. WARNING: unselecting this option will allow the Job to run (and commit changes) with a single click!
job: Box<BulkWritableJobButtonRequestJob>Implementations§
Source§impl BulkWritableJobButtonRequest
impl BulkWritableJobButtonRequest
Sourcepub fn new(
id: Uuid,
content_types: Vec<String>,
name: String,
text: String,
job: BulkWritableJobButtonRequestJob,
) -> BulkWritableJobButtonRequest
pub fn new( id: Uuid, content_types: Vec<String>, name: String, text: String, job: BulkWritableJobButtonRequestJob, ) -> BulkWritableJobButtonRequest
Extends the built-in ModelSerializer to enforce calling full_clean() on a copy of the associated instance during validation. (DRF does not do this by default; see https://github.com/encode/django-rest-framework/issues/3144)
Trait Implementations§
Source§impl Clone for BulkWritableJobButtonRequest
impl Clone for BulkWritableJobButtonRequest
Source§fn clone(&self) -> BulkWritableJobButtonRequest
fn clone(&self) -> BulkWritableJobButtonRequest
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BulkWritableJobButtonRequest
impl Debug for BulkWritableJobButtonRequest
Source§impl Default for BulkWritableJobButtonRequest
impl Default for BulkWritableJobButtonRequest
Source§fn default() -> BulkWritableJobButtonRequest
fn default() -> BulkWritableJobButtonRequest
Source§impl<'de> Deserialize<'de> for BulkWritableJobButtonRequest
impl<'de> Deserialize<'de> for BulkWritableJobButtonRequest
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for BulkWritableJobButtonRequest
impl PartialEq for BulkWritableJobButtonRequest
Source§fn eq(&self, other: &BulkWritableJobButtonRequest) -> bool
fn eq(&self, other: &BulkWritableJobButtonRequest) -> bool
self and other values to be equal, and is used by ==.