hanzo-client 8.5.156

Generated client for the Hanzo API — every service, one crate.
Documentation
/*
 * Hanzo Cloud API
 *
 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
 *
 * The version of the OpenAPI document: v1
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct GlRow {
    /// Account is the chart-of-accounts number this leg posts to.
    #[serde(rename = "account", skip_serializing_if = "Option::is_none")]
    pub account: Option<String>,
    /// Against names the OTHER accounts in the same voucher — the contra side of this leg — so a single row reads as an entry rather than as half of one.
    #[serde(rename = "against", skip_serializing_if = "Option::is_none")]
    pub against: Option<String>,
    /// Credit is the amount credited to that account, in whole cents.
    #[serde(rename = "credit", skip_serializing_if = "Option::is_none")]
    pub credit: Option<i32>,
    /// Debit is the amount debited to that account, in whole cents. Exactly one of debit and credit is non-zero on a leg; a negative amount is never used to mean the other side.
    #[serde(rename = "debit", skip_serializing_if = "Option::is_none")]
    pub debit: Option<i32>,
    /// ID is the entry's position in the ledger. The ledger is append-only, so ids ascend with posting order and a higher id is a later entry.
    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
    pub id: Option<i32>,
    /// PostingAt is the accounting date this entry belongs to — what the reports window on, which need not be when the row was written.
    #[serde(rename = "postingAt", skip_serializing_if = "Option::is_none")]
    pub posting_at: Option<String>,
    /// Remarks is the memo carried onto the entry, for a human reading the ledger.
    #[serde(rename = "remarks", skip_serializing_if = "Option::is_none")]
    pub remarks: Option<String>,
    /// SourceID identifies that originating record within its kind.
    #[serde(rename = "sourceId", skip_serializing_if = "Option::is_none")]
    pub source_id: Option<String>,
    /// SourceKind is what caused the posting: a bank line, a scanned document, a commerce sale. With sourceId it traces the entry back to the thing that produced it.
    #[serde(rename = "sourceKind", skip_serializing_if = "Option::is_none")]
    pub source_kind: Option<String>,
}

impl GlRow {
    pub fn new() -> GlRow {
        GlRow {
            account: None,
            against: None,
            credit: None,
            debit: None,
            id: None,
            posting_at: None,
            remarks: None,
            source_id: None,
            source_kind: None,
        }
    }
}