Struct square_api_client::models::CatalogTax
source · [−]pub struct CatalogTax {
pub name: Option<String>,
pub calculation_phase: Option<TaxCalculationPhase>,
pub inclusion_type: Option<TaxInclusionType>,
pub percentage: Option<String>,
pub applies_to_custom_amounts: Option<bool>,
pub enabled: Option<bool>,
}
Expand description
A tax applicable to an item.
Fields
name: Option<String>
The tax’s name. This is a searchable attribute for use in applicable query filters, and its value length is of Unicode code points.
Max Length 255
calculation_phase: Option<TaxCalculationPhase>
Whether the tax is calculated based on a payment’s subtotal or total.
inclusion_type: Option<TaxInclusionType>
Whether the tax is ADDITIVE
or INCLUSIVE
.
percentage: Option<String>
The percentage of the tax in decimal form, using a '.'
as the decimal separator and
without a '%'
sign. A value of 7.5
corresponds to 7.5%.
applies_to_custom_amounts: Option<bool>
If true
, the fee applies to custom amounts entered into the Square Point of Sale app that
are not associated with a particular CatalogItem
.
enabled: Option<bool>
A Boolean flag to indicate whether the tax is displayed as enabled (true
) in the Square
Point of Sale app or not (false
).
Trait Implementations
sourceimpl Clone for CatalogTax
impl Clone for CatalogTax
sourcefn clone(&self) -> CatalogTax
fn clone(&self) -> CatalogTax
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresourceimpl Debug for CatalogTax
impl Debug for CatalogTax
sourceimpl Default for CatalogTax
impl Default for CatalogTax
sourcefn default() -> CatalogTax
fn default() -> CatalogTax
Returns the “default value” for a type. Read more
sourceimpl<'de> Deserialize<'de> for CatalogTax
impl<'de> Deserialize<'de> for CatalogTax
sourcefn 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>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl PartialEq<CatalogTax> for CatalogTax
impl PartialEq<CatalogTax> for CatalogTax
sourcefn eq(&self, other: &CatalogTax) -> bool
fn eq(&self, other: &CatalogTax) -> bool
sourceimpl Serialize for CatalogTax
impl Serialize for CatalogTax
impl Eq for CatalogTax
impl StructuralEq for CatalogTax
impl StructuralPartialEq for CatalogTax
Auto Trait Implementations
impl RefUnwindSafe for CatalogTax
impl Send for CatalogTax
impl Sync for CatalogTax
impl Unpin for CatalogTax
impl UnwindSafe for CatalogTax
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.