pub struct P2pDocuments {
pub po_number: String,
pub po_id: Uuid,
pub gr_number: Option<String>,
pub gr_id: Option<Uuid>,
pub invoice_number: Option<String>,
pub invoice_id: Option<Uuid>,
pub payment_number: Option<String>,
pub payment_id: Option<Uuid>,
pub vendor_id: String,
pub company_code: String,
pub amount: Decimal,
pub currency: String,
}Expand description
P2P document references for event generation.
Fields§
§po_number: StringPurchase order number
po_id: UuidPurchase order UUID
gr_number: Option<String>Goods receipt number
gr_id: Option<Uuid>Goods receipt UUID
invoice_number: Option<String>Vendor invoice number
invoice_id: Option<Uuid>Invoice UUID
payment_number: Option<String>Payment number
payment_id: Option<Uuid>Payment UUID
vendor_id: StringVendor ID
company_code: StringCompany code
amount: DecimalTotal amount
currency: StringCurrency
Implementations§
Source§impl P2pDocuments
impl P2pDocuments
Sourcepub fn new(
po_number: &str,
vendor_id: &str,
company_code: &str,
amount: Decimal,
currency: &str,
) -> Self
pub fn new( po_number: &str, vendor_id: &str, company_code: &str, amount: Decimal, currency: &str, ) -> Self
Create new P2P documents.
Sourcepub fn with_goods_receipt(self, gr_number: &str) -> Self
pub fn with_goods_receipt(self, gr_number: &str) -> Self
Set goods receipt info.
Sourcepub fn with_invoice(self, invoice_number: &str) -> Self
pub fn with_invoice(self, invoice_number: &str) -> Self
Set invoice info.
Sourcepub fn with_payment(self, payment_number: &str) -> Self
pub fn with_payment(self, payment_number: &str) -> Self
Set payment info.
Trait Implementations§
Source§impl Clone for P2pDocuments
impl Clone for P2pDocuments
Source§fn clone(&self) -> P2pDocuments
fn clone(&self) -> P2pDocuments
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 moreAuto Trait Implementations§
impl Freeze for P2pDocuments
impl RefUnwindSafe for P2pDocuments
impl Send for P2pDocuments
impl Sync for P2pDocuments
impl Unpin for P2pDocuments
impl UnwindSafe for P2pDocuments
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