control-see
Version:
Control Util Documentos Electronicos SUNAT
169 lines • 7.11 kB
JavaScript
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
import { XMLElement, XMLChild, XMLAttribute } from 'xml-serializer-ts';
import { Namespaces, prefix } from '@fe/common/constants';
import { UblExtensions, SignatureCac, AccountingSupplierParty, LegalMonetaryTotal, InvoiceTypeCode, Note, DocumentCurrencyCode, PrepaidPayment, OrderReference, AllowanceCharge, ProfileID } from '@fe/structures';
const { INVOICE, EXT, CAC, CBC } = prefix;
let Invoice = class Invoice {
constructor() {
this.xmlns = Namespaces.xmlnsInvoice;
this.cac = Namespaces.cac;
this.cbc = Namespaces.cbc;
this.ccts = Namespaces.ccts;
this.ds = Namespaces.ds;
this.ext = Namespaces.ext;
this.qdt = Namespaces.qdt;
this.sac = Namespaces.sac;
this.udt = Namespaces.udt;
this.xsi = Namespaces.xsi;
this.additionalDocumentReferences = new Array();
this.taxTotals = new Array();
this.invoiceLine = new Array();
this.despatchDocumentReferences = new Array();
}
};
__decorate([
XMLAttribute({ name: '' }),
__metadata("design:type", String)
], Invoice.prototype, "xmlns", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "cac", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "cbc", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "ccts", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "ds", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "ext", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "qdt", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "sac", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "udt", void 0);
__decorate([
XMLAttribute({ namespace: 'xmlns' }),
__metadata("design:type", String)
], Invoice.prototype, "xsi", void 0);
__decorate([
XMLChild({ namespace: EXT, name: 'UBLExtensions' }),
__metadata("design:type", UblExtensions)
], Invoice.prototype, "ublExtensions", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'UBLVersionID' }),
__metadata("design:type", String)
], Invoice.prototype, "ublVersionID", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'CustomizationID' }),
__metadata("design:type", String)
], Invoice.prototype, "customizationID", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'ProfileID' }),
__metadata("design:type", ProfileID)
], Invoice.prototype, "profileID", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'ID' }),
__metadata("design:type", String)
], Invoice.prototype, "id", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'IssueDate' }),
__metadata("design:type", String)
], Invoice.prototype, "issueDate", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'IssueTime' }),
__metadata("design:type", String)
], Invoice.prototype, "issueTime", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'DueDate' }),
__metadata("design:type", String)
], Invoice.prototype, "dueDate", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'InvoiceTypeCode' }),
__metadata("design:type", InvoiceTypeCode)
], Invoice.prototype, "invoiceTypeCode", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'Note' }),
__metadata("design:type", Note)
], Invoice.prototype, "note", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'DocumentCurrencyCode' }),
__metadata("design:type", DocumentCurrencyCode)
], Invoice.prototype, "documentCurrencyCode", void 0);
__decorate([
XMLChild({ namespace: CBC, name: 'LineCountNumeric' }),
__metadata("design:type", String)
], Invoice.prototype, "lineCountNumeric", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'AdditionalDocumentReference' }),
__metadata("design:type", Array)
], Invoice.prototype, "additionalDocumentReferences", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'Signature' }),
__metadata("design:type", SignatureCac)
], Invoice.prototype, "signature", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'AccountingSupplierParty' }),
__metadata("design:type", AccountingSupplierParty)
], Invoice.prototype, "accountingSupplierParty", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'AccountingCustomerParty' }),
__metadata("design:type", AccountingSupplierParty)
], Invoice.prototype, "accountingCustomerParty", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'PrepaidPayment' }),
__metadata("design:type", PrepaidPayment)
], Invoice.prototype, "prepaidPayment", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'AllowanceCharge' }),
__metadata("design:type", AllowanceCharge)
], Invoice.prototype, "allowanceCharge", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'TaxTotal' }),
__metadata("design:type", Array)
], Invoice.prototype, "taxTotals", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'OrderReference' }),
__metadata("design:type", OrderReference)
], Invoice.prototype, "orderReference", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'DespatchDocumentReference' }),
__metadata("design:type", Array)
], Invoice.prototype, "despatchDocumentReferences", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'LegalMonetaryTotal' }),
__metadata("design:type", LegalMonetaryTotal)
], Invoice.prototype, "legalMonetaryTotal", void 0);
__decorate([
XMLChild({ namespace: CAC, name: 'InvoiceLine' }),
__metadata("design:type", Array)
], Invoice.prototype, "invoiceLine", void 0);
Invoice = __decorate([
XMLElement({ root: INVOICE }),
__metadata("design:paramtypes", [])
], Invoice);
export { Invoice };
//# sourceMappingURL=invoice.js.map