pub struct APInvoiceLine {Show 18 fields
pub line_number: u32,
pub material_id: Option<String>,
pub description: String,
pub quantity: Decimal,
pub unit: String,
pub unit_price: Decimal,
pub net_amount: Decimal,
pub tax_code: Option<String>,
pub tax_rate: Decimal,
pub tax_amount: Decimal,
pub gross_amount: Decimal,
pub gl_account: String,
pub cost_center: Option<String>,
pub internal_order: Option<String>,
pub wbs_element: Option<String>,
pub asset_number: Option<String>,
pub po_line: Option<u32>,
pub gr_line: Option<u32>,
}Expand description
AP invoice line item.
Fields§
§line_number: u32Line number.
material_id: Option<String>Material/service ID.
description: StringDescription.
quantity: DecimalQuantity.
unit: StringUnit of measure.
unit_price: DecimalUnit price.
net_amount: DecimalNet amount.
tax_code: Option<String>Tax code.
tax_rate: DecimalTax rate.
tax_amount: DecimalTax amount.
gross_amount: DecimalGross amount.
gl_account: StringGL account.
cost_center: Option<String>Cost center.
internal_order: Option<String>Internal order.
wbs_element: Option<String>WBS element (project).
asset_number: Option<String>Asset number (for asset acquisitions).
po_line: Option<u32>Reference PO line.
gr_line: Option<u32>Reference GR line.
Implementations§
Source§impl APInvoiceLine
impl APInvoiceLine
Sourcepub fn new(
line_number: u32,
description: String,
quantity: Decimal,
unit: String,
unit_price: Decimal,
gl_account: String,
) -> Self
pub fn new( line_number: u32, description: String, quantity: Decimal, unit: String, unit_price: Decimal, gl_account: String, ) -> Self
Creates a new invoice line.
Sourcepub fn with_cost_center(self, cost_center: String) -> Self
pub fn with_cost_center(self, cost_center: String) -> Self
Sets cost center.
Sourcepub fn with_po_reference(self, po_line: u32) -> Self
pub fn with_po_reference(self, po_line: u32) -> Self
Sets PO reference.
Sourcepub fn with_asset(self, asset_number: String) -> Self
pub fn with_asset(self, asset_number: String) -> Self
Sets asset number.
Trait Implementations§
Source§impl Clone for APInvoiceLine
impl Clone for APInvoiceLine
Source§fn clone(&self) -> APInvoiceLine
fn clone(&self) -> APInvoiceLine
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for APInvoiceLine
impl Debug for APInvoiceLine
Source§impl<'de> Deserialize<'de> for APInvoiceLine
impl<'de> Deserialize<'de> for APInvoiceLine
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>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for APInvoiceLine
impl RefUnwindSafe for APInvoiceLine
impl Send for APInvoiceLine
impl Sync for APInvoiceLine
impl Unpin for APInvoiceLine
impl UnwindSafe for APInvoiceLine
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
Mutably borrows from an owned value. Read more