fromMap static method
Implementation
static InvoiceLine? fromMap(Object? body) {
final source = readRecord(body);
if (source == null) return null;
return InvoiceLine(
object: readText(source['object']),
id: readText(source['id']),
item: InvoiceLineItem.fromMap(source['item']),
tax: InvoiceLineTax.fromMap(source['tax']),
accountingCode:
InvoiceLineAccountingCode.fromMap(source['accounting_code']),
itemUuid: readText(source['item_uuid']),
itemId: readText(source['item_id']),
itemName: readText(source['item_name']),
itemChargeType: readText(source['item_charge_type']),
itemOrderQuantity: readInteger(source['item_order_quantity']),
itemUom: readAny(source['item_uom']),
itemWarehouse: readText(source['item_warehouse']),
pricingSnapshotUuid: readText(source['pricing_snapshot_uuid']),
pricingSnapshotPrice: readDecimal(source['pricing_snapshot_price']),
subtotal: readText(source['subtotal']),
total: readText(source['total']),
itemCustomAttributes:
readList<Object>(source['item_custom_attributes'], readAny),
version: readInteger(source['version']),
itemSerialOrBatchNumber: readText(source['item_serial_or_batch_number']),
chargingStartDate: readText(source['charging_start_date']),
alternateChargingStartDate:
readText(source['alternate_charging_start_date']),
chargingEndDate: readText(source['charging_end_date']),
alternateChargingEndDate: readText(source['alternate_charging_end_date']),
);
}