zugferd_code_lists/zugferd_2_3_3/
enum1001.rs

1#![allow(non_camel_case_types)]
2
3#[cfg_attr(feature = "serde", derive(serde::Serialize, serde::Deserialize))]
4#[derive(Debug, PartialEq, Eq, PartialOrd, Ord, Clone, Copy, Hash)]
5pub enum Enum1001 {
6    /// Request for payment
7    ///
8    /// Invoice
9    RequestForPayment,
10    /// Debit note related to goods or services
11    ///
12    /// Invoice
13    DebitNoteRelatedToGoodsOrServices,
14    /// Credit note related to goods or services
15    ///
16    /// Credit Note
17    CreditNoteRelatedToGoodsOrServices,
18    /// Metered services invoice
19    ///
20    /// Invoice
21    MeteredServicesInvoice,
22    /// Credit note related to financial adjustments
23    ///
24    /// Credit Note
25    CreditNoteRelatedToFinancialAdjustments,
26    /// Debit note related to financial adjustments
27    ///
28    /// Invoice
29    DebitNoteRelatedToFinancialAdjustments,
30    /// Tax notification
31    ///
32    /// Invoice
33    TaxNotification,
34    /// Invoicing data sheet
35    ///
36    /// Invoice
37    InvoicingDataSheet,
38    /// Direct payment valuation
39    ///
40    /// Invoice
41    DirectPaymentValuation,
42    /// Provisional payment valuation
43    ///
44    /// Invoice
45    ProvisionalPaymentValuation,
46    /// Payment valuation
47    ///
48    /// Invoice
49    PaymentValuation,
50    /// Interim application for payment
51    ///
52    /// Invoice
53    InterimApplicationForPayment,
54    /// Final payment request based on completion of work
55    ///
56    /// Invoice
57    FinalPaymentRequestBasedOnCompletionWork,
58    /// Payment request for completed units
59    ///
60    /// Invoice
61    PaymentRequestForCompletedUnits,
62    /// Self billed credit note
63    ///
64    /// Credit Note
65    SelfBilledCreditNote,
66    /// Consolidated credit note - goods and services
67    ///
68    /// Credit Note
69    ConsolidatedCreditNoteGoodsAndServices,
70    /// Price variation invoice
71    ///
72    /// Invoice
73    PriceVariationInvoice,
74    /// Credit note for price variation
75    ///
76    /// Credit Note
77    CreditNoteForPriceVariation,
78    /// Delcredere credit note
79    ///
80    /// Credit Note
81    DelcredereCreditNote,
82    /// Proforma invoice
83    ///
84    /// Invoice
85    ProformaInvoice,
86    /// Partial invoice
87    ///
88    /// Invoice
89    PartialInvoice,
90    /// Commercial invoice which includes a packing list
91    ///
92    /// Invoice
93    CommercialInvoiceWhichIncludesAPackingList,
94    /// Commercial invoice
95    ///
96    /// Invoice
97    CommercialInvoice,
98    /// Credit note
99    ///
100    /// Credit Note
101    CreditNote,
102    /// Commission note
103    ///
104    /// Invoice
105    CommissionNote,
106    /// Debit note
107    ///
108    /// Invoice
109    DebitNote,
110    /// Corrected invoice
111    ///
112    /// Invoice
113    CorrectedInvoice,
114    /// Consolidated invoice
115    ///
116    /// Invoice
117    ConsolidatedInvoice,
118    /// Prepayment invoice
119    ///
120    /// Invoice
121    PrepaymentInvoice,
122    /// Hire invoice
123    ///
124    /// Invoice
125    HireInvoice,
126    /// Tax invoice
127    ///
128    /// Invoice
129    TaxInvoice,
130    /// Self-billed invoice
131    ///
132    /// Invoice
133    SelfBilledInvoice,
134    /// Delcredere invoice
135    ///
136    /// Invoice
137    DelcredereInvoice,
138    /// Factored invoice
139    ///
140    /// Invoice
141    FactoredInvoice,
142    /// Lease invoice
143    ///
144    /// Invoice
145    LeaseInvoice,
146    /// Consignment invoice
147    ///
148    /// Invoice
149    ConsignmentInvoice,
150    /// Factored credit note
151    ///
152    /// Credit Note
153    FactoredCreditNote,
154    /// Optical Character Reading (OCR) payment credit note
155    ///
156    /// Credit Note
157    OpticalCharacterReadingOcrPaymentCreditNote,
158    /// Debit advice
159    ///
160    /// Invoice
161    DebitAdvice,
162    /// Reversal of debit
163    ///
164    /// Invoice
165    ReversalDebit,
166    /// Reversal of credit
167    ///
168    /// Credit Note
169    ReversalCredit,
170    ///  Self-billed corrective invoice, invoice type, Corrected
171    ///
172    /// Invoice
173    SelfBilledCorrectiveInvoiceInvoiceTypeCorrected,
174    ///  Factored Corrective Invoice, invoice type, Corrected
175    ///
176    /// Invoice
177    FactoredCorrectiveInvoiceInvoiceTypeCorrected,
178    ///  Self billed Factored corrective invoice, invoice type, Corrected
179    ///
180    /// Invoice
181    SelfBilledFactoredCorrectiveInvoiceInvoiceTypeCorrected,
182    ///  Self Prepayment invoice, invoice type, Original
183    ///
184    /// Invoice
185    SelfPrepaymentInvoiceInvoiceTypeOriginal,
186    ///  Self billed factored invoice, invoice type, Original
187    ///
188    /// Invoice
189    SelfBilledFactoredInvoiceInvoiceTypeOriginal,
190    ///  Self billet factored Credit Note, Credit note type, Corrected
191    ///
192    /// Credit Note
193    SelfBilletFactoredCreditNoteCreditNoteTypeCorrected,
194    ///  Prepayment credit note, credit note type, Corrected
195    ///
196    /// Credit Note
197    PrepaymentCreditNoteCreditNoteTypeCorrected,
198    /// Self billed debit note
199    ///
200    /// Invoice
201    SelfBilledDebitNote,
202    /// Forwarder's credit note
203    ///
204    /// Credit Note
205    ForwardersCreditNote,
206    /// Forwarder's invoice discrepancy report
207    ///
208    /// Invoice
209    ForwardersInvoiceDiscrepancyReport,
210    /// Insurer's invoice
211    ///
212    /// Invoice
213    InsurersInvoice,
214    /// Forwarder's invoice
215    ///
216    /// Invoice
217    ForwardersInvoice,
218    /// Port charges documents
219    ///
220    /// Invoice
221    PortChargesDocuments,
222    /// Invoice information for accounting purposes
223    ///
224    /// Invoice
225    InvoiceInformationForAccountingPurposes,
226    /// Freight invoice
227    ///
228    /// Invoice
229    FreightInvoice,
230    /// Claim notification
231    ///
232    /// Invoice
233    ClaimNotification,
234    /// Consular invoice
235    ///
236    /// Invoice
237    ConsularInvoice,
238    /// Partial construction invoice
239    ///
240    /// Invoice
241    PartialConstructionInvoice,
242    /// Partial final construction invoice
243    ///
244    /// Invoice
245    PartialFinalConstructionInvoice,
246    /// Final construction invoice
247    ///
248    /// Invoice
249    FinalConstructionInvoice,
250    /// Customs invoice
251    ///
252    /// Invoice
253    CustomsInvoice,
254}
255
256impl crate::Code for Enum1001 {
257    fn code(self) -> &'static str {
258        match self {
259            Enum1001::RequestForPayment => "71",
260            Enum1001::DebitNoteRelatedToGoodsOrServices => "80",
261            Enum1001::CreditNoteRelatedToGoodsOrServices => "81",
262            Enum1001::MeteredServicesInvoice => "82",
263            Enum1001::CreditNoteRelatedToFinancialAdjustments => "83",
264            Enum1001::DebitNoteRelatedToFinancialAdjustments => "84",
265            Enum1001::TaxNotification => "102",
266            Enum1001::InvoicingDataSheet => "130",
267            Enum1001::DirectPaymentValuation => "202",
268            Enum1001::ProvisionalPaymentValuation => "203",
269            Enum1001::PaymentValuation => "204",
270            Enum1001::InterimApplicationForPayment => "211",
271            Enum1001::FinalPaymentRequestBasedOnCompletionWork => "218",
272            Enum1001::PaymentRequestForCompletedUnits => "219",
273            Enum1001::SelfBilledCreditNote => "261",
274            Enum1001::ConsolidatedCreditNoteGoodsAndServices => "262",
275            Enum1001::PriceVariationInvoice => "295",
276            Enum1001::CreditNoteForPriceVariation => "296",
277            Enum1001::DelcredereCreditNote => "308",
278            Enum1001::ProformaInvoice => "325",
279            Enum1001::PartialInvoice => "326",
280            Enum1001::CommercialInvoiceWhichIncludesAPackingList => "331",
281            Enum1001::CommercialInvoice => "380",
282            Enum1001::CreditNote => "381",
283            Enum1001::CommissionNote => "382",
284            Enum1001::DebitNote => "383",
285            Enum1001::CorrectedInvoice => "384",
286            Enum1001::ConsolidatedInvoice => "385",
287            Enum1001::PrepaymentInvoice => "386",
288            Enum1001::HireInvoice => "387",
289            Enum1001::TaxInvoice => "388",
290            Enum1001::SelfBilledInvoice => "389",
291            Enum1001::DelcredereInvoice => "390",
292            Enum1001::FactoredInvoice => "393",
293            Enum1001::LeaseInvoice => "394",
294            Enum1001::ConsignmentInvoice => "395",
295            Enum1001::FactoredCreditNote => "396",
296            Enum1001::OpticalCharacterReadingOcrPaymentCreditNote => "420",
297            Enum1001::DebitAdvice => "456",
298            Enum1001::ReversalDebit => "457",
299            Enum1001::ReversalCredit => "458",
300            Enum1001::SelfBilledCorrectiveInvoiceInvoiceTypeCorrected => "471",
301            Enum1001::FactoredCorrectiveInvoiceInvoiceTypeCorrected => "472",
302            Enum1001::SelfBilledFactoredCorrectiveInvoiceInvoiceTypeCorrected => "473",
303            Enum1001::SelfPrepaymentInvoiceInvoiceTypeOriginal => "500",
304            Enum1001::SelfBilledFactoredInvoiceInvoiceTypeOriginal => "501",
305            Enum1001::SelfBilletFactoredCreditNoteCreditNoteTypeCorrected => "502",
306            Enum1001::PrepaymentCreditNoteCreditNoteTypeCorrected => "503",
307            Enum1001::SelfBilledDebitNote => "527",
308            Enum1001::ForwardersCreditNote => "532",
309            Enum1001::ForwardersInvoiceDiscrepancyReport => "553",
310            Enum1001::InsurersInvoice => "575",
311            Enum1001::ForwardersInvoice => "623",
312            Enum1001::PortChargesDocuments => "633",
313            Enum1001::InvoiceInformationForAccountingPurposes => "751",
314            Enum1001::FreightInvoice => "780",
315            Enum1001::ClaimNotification => "817",
316            Enum1001::ConsularInvoice => "870",
317            Enum1001::PartialConstructionInvoice => "875",
318            Enum1001::PartialFinalConstructionInvoice => "876",
319            Enum1001::FinalConstructionInvoice => "877",
320            Enum1001::CustomsInvoice => "935",
321        }
322    }
323}
324
325impl crate::Description for Enum1001 {
326    fn description(self) -> &'static str {
327        match self {
328            Enum1001::RequestForPayment => "Request for payment",
329            Enum1001::DebitNoteRelatedToGoodsOrServices => {
330                "Debit note related to goods or services"
331            }
332            Enum1001::CreditNoteRelatedToGoodsOrServices => {
333                "Credit note related to goods or services"
334            }
335            Enum1001::MeteredServicesInvoice => "Metered services invoice",
336            Enum1001::CreditNoteRelatedToFinancialAdjustments => {
337                "Credit note related to financial adjustments"
338            }
339            Enum1001::DebitNoteRelatedToFinancialAdjustments => {
340                "Debit note related to financial adjustments"
341            }
342            Enum1001::TaxNotification => "Tax notification",
343            Enum1001::InvoicingDataSheet => "Invoicing data sheet",
344            Enum1001::DirectPaymentValuation => "Direct payment valuation",
345            Enum1001::ProvisionalPaymentValuation => "Provisional payment valuation",
346            Enum1001::PaymentValuation => "Payment valuation",
347            Enum1001::InterimApplicationForPayment => "Interim application for payment",
348            Enum1001::FinalPaymentRequestBasedOnCompletionWork => {
349                "Final payment request based on completion of work"
350            }
351            Enum1001::PaymentRequestForCompletedUnits => "Payment request for completed units",
352            Enum1001::SelfBilledCreditNote => "Self billed credit note",
353            Enum1001::ConsolidatedCreditNoteGoodsAndServices => {
354                "Consolidated credit note - goods and services"
355            }
356            Enum1001::PriceVariationInvoice => "Price variation invoice",
357            Enum1001::CreditNoteForPriceVariation => "Credit note for price variation",
358            Enum1001::DelcredereCreditNote => "Delcredere credit note",
359            Enum1001::ProformaInvoice => "Proforma invoice",
360            Enum1001::PartialInvoice => "Partial invoice",
361            Enum1001::CommercialInvoiceWhichIncludesAPackingList => {
362                "Commercial invoice which includes a packing list"
363            }
364            Enum1001::CommercialInvoice => "Commercial invoice",
365            Enum1001::CreditNote => "Credit note",
366            Enum1001::CommissionNote => "Commission note",
367            Enum1001::DebitNote => "Debit note",
368            Enum1001::CorrectedInvoice => "Corrected invoice",
369            Enum1001::ConsolidatedInvoice => "Consolidated invoice",
370            Enum1001::PrepaymentInvoice => "Prepayment invoice",
371            Enum1001::HireInvoice => "Hire invoice",
372            Enum1001::TaxInvoice => "Tax invoice",
373            Enum1001::SelfBilledInvoice => "Self-billed invoice",
374            Enum1001::DelcredereInvoice => "Delcredere invoice",
375            Enum1001::FactoredInvoice => "Factored invoice",
376            Enum1001::LeaseInvoice => "Lease invoice",
377            Enum1001::ConsignmentInvoice => "Consignment invoice",
378            Enum1001::FactoredCreditNote => "Factored credit note",
379            Enum1001::OpticalCharacterReadingOcrPaymentCreditNote => {
380                "Optical Character Reading (OCR) payment credit note"
381            }
382            Enum1001::DebitAdvice => "Debit advice",
383            Enum1001::ReversalDebit => "Reversal of debit",
384            Enum1001::ReversalCredit => "Reversal of credit",
385            Enum1001::SelfBilledCorrectiveInvoiceInvoiceTypeCorrected => {
386                " Self-billed corrective invoice, invoice type, Corrected"
387            }
388            Enum1001::FactoredCorrectiveInvoiceInvoiceTypeCorrected => {
389                " Factored Corrective Invoice, invoice type, Corrected"
390            }
391            Enum1001::SelfBilledFactoredCorrectiveInvoiceInvoiceTypeCorrected => {
392                " Self billed Factored corrective invoice, invoice type, Corrected"
393            }
394            Enum1001::SelfPrepaymentInvoiceInvoiceTypeOriginal => {
395                " Self Prepayment invoice, invoice type, Original"
396            }
397            Enum1001::SelfBilledFactoredInvoiceInvoiceTypeOriginal => {
398                " Self billed factored invoice, invoice type, Original"
399            }
400            Enum1001::SelfBilletFactoredCreditNoteCreditNoteTypeCorrected => {
401                " Self billet factored Credit Note, Credit note type, Corrected"
402            }
403            Enum1001::PrepaymentCreditNoteCreditNoteTypeCorrected => {
404                " Prepayment credit note, credit note type, Corrected"
405            }
406            Enum1001::SelfBilledDebitNote => "Self billed debit note",
407            Enum1001::ForwardersCreditNote => "Forwarder's credit note",
408            Enum1001::ForwardersInvoiceDiscrepancyReport => {
409                "Forwarder's invoice discrepancy report"
410            }
411            Enum1001::InsurersInvoice => "Insurer's invoice",
412            Enum1001::ForwardersInvoice => "Forwarder's invoice",
413            Enum1001::PortChargesDocuments => "Port charges documents",
414            Enum1001::InvoiceInformationForAccountingPurposes => {
415                "Invoice information for accounting purposes"
416            }
417            Enum1001::FreightInvoice => "Freight invoice",
418            Enum1001::ClaimNotification => "Claim notification",
419            Enum1001::ConsularInvoice => "Consular invoice",
420            Enum1001::PartialConstructionInvoice => "Partial construction invoice",
421            Enum1001::PartialFinalConstructionInvoice => "Partial final construction invoice",
422            Enum1001::FinalConstructionInvoice => "Final construction invoice",
423            Enum1001::CustomsInvoice => "Customs invoice",
424        }
425    }
426}
427
428impl crate::FromCode for Enum1001 {
429    fn from_code(code: &str) -> Option<Self>
430    where
431        Self: Sized,
432    {
433        match code {
434            "71" => Some(Enum1001::RequestForPayment),
435            "80" => Some(Enum1001::DebitNoteRelatedToGoodsOrServices),
436            "81" => Some(Enum1001::CreditNoteRelatedToGoodsOrServices),
437            "82" => Some(Enum1001::MeteredServicesInvoice),
438            "83" => Some(Enum1001::CreditNoteRelatedToFinancialAdjustments),
439            "84" => Some(Enum1001::DebitNoteRelatedToFinancialAdjustments),
440            "102" => Some(Enum1001::TaxNotification),
441            "130" => Some(Enum1001::InvoicingDataSheet),
442            "202" => Some(Enum1001::DirectPaymentValuation),
443            "203" => Some(Enum1001::ProvisionalPaymentValuation),
444            "204" => Some(Enum1001::PaymentValuation),
445            "211" => Some(Enum1001::InterimApplicationForPayment),
446            "218" => Some(Enum1001::FinalPaymentRequestBasedOnCompletionWork),
447            "219" => Some(Enum1001::PaymentRequestForCompletedUnits),
448            "261" => Some(Enum1001::SelfBilledCreditNote),
449            "262" => Some(Enum1001::ConsolidatedCreditNoteGoodsAndServices),
450            "295" => Some(Enum1001::PriceVariationInvoice),
451            "296" => Some(Enum1001::CreditNoteForPriceVariation),
452            "308" => Some(Enum1001::DelcredereCreditNote),
453            "325" => Some(Enum1001::ProformaInvoice),
454            "326" => Some(Enum1001::PartialInvoice),
455            "331" => Some(Enum1001::CommercialInvoiceWhichIncludesAPackingList),
456            "380" => Some(Enum1001::CommercialInvoice),
457            "381" => Some(Enum1001::CreditNote),
458            "382" => Some(Enum1001::CommissionNote),
459            "383" => Some(Enum1001::DebitNote),
460            "384" => Some(Enum1001::CorrectedInvoice),
461            "385" => Some(Enum1001::ConsolidatedInvoice),
462            "386" => Some(Enum1001::PrepaymentInvoice),
463            "387" => Some(Enum1001::HireInvoice),
464            "388" => Some(Enum1001::TaxInvoice),
465            "389" => Some(Enum1001::SelfBilledInvoice),
466            "390" => Some(Enum1001::DelcredereInvoice),
467            "393" => Some(Enum1001::FactoredInvoice),
468            "394" => Some(Enum1001::LeaseInvoice),
469            "395" => Some(Enum1001::ConsignmentInvoice),
470            "396" => Some(Enum1001::FactoredCreditNote),
471            "420" => Some(Enum1001::OpticalCharacterReadingOcrPaymentCreditNote),
472            "456" => Some(Enum1001::DebitAdvice),
473            "457" => Some(Enum1001::ReversalDebit),
474            "458" => Some(Enum1001::ReversalCredit),
475            "471" => Some(Enum1001::SelfBilledCorrectiveInvoiceInvoiceTypeCorrected),
476            "472" => Some(Enum1001::FactoredCorrectiveInvoiceInvoiceTypeCorrected),
477            "473" => Some(Enum1001::SelfBilledFactoredCorrectiveInvoiceInvoiceTypeCorrected),
478            "500" => Some(Enum1001::SelfPrepaymentInvoiceInvoiceTypeOriginal),
479            "501" => Some(Enum1001::SelfBilledFactoredInvoiceInvoiceTypeOriginal),
480            "502" => Some(Enum1001::SelfBilletFactoredCreditNoteCreditNoteTypeCorrected),
481            "503" => Some(Enum1001::PrepaymentCreditNoteCreditNoteTypeCorrected),
482            "527" => Some(Enum1001::SelfBilledDebitNote),
483            "532" => Some(Enum1001::ForwardersCreditNote),
484            "553" => Some(Enum1001::ForwardersInvoiceDiscrepancyReport),
485            "575" => Some(Enum1001::InsurersInvoice),
486            "623" => Some(Enum1001::ForwardersInvoice),
487            "633" => Some(Enum1001::PortChargesDocuments),
488            "751" => Some(Enum1001::InvoiceInformationForAccountingPurposes),
489            "780" => Some(Enum1001::FreightInvoice),
490            "817" => Some(Enum1001::ClaimNotification),
491            "870" => Some(Enum1001::ConsularInvoice),
492            "875" => Some(Enum1001::PartialConstructionInvoice),
493            "876" => Some(Enum1001::PartialFinalConstructionInvoice),
494            "877" => Some(Enum1001::FinalConstructionInvoice),
495            "935" => Some(Enum1001::CustomsInvoice),
496            _ => None,
497        }
498    }
499}