toJson method

Map<String, dynamic> toJson()

Zurück in die Drahtform, aus der PosArticle.fromJson wieder liest (für Zwischenspeicher, nicht fürs Backend).

Implementation

Map<String, dynamic> toJson() => {
      'id': id,
      'name': name,
      'unitPriceCents': unitPriceCents,
      'vatRate': vatRate,
      'unit': unit,
      'groupId': groupId,
      'revenueGroupId': revenueGroupId,
      'tile': {'visible': visible, 'sort': sort},
      'active': active,
      'quantityRule': quantityRule?.name,
      'askQuantity': askQuantity,
      'maxQuantity': maxQuantity,
      'stockLocationIds': stockLocationIds,
      'number': number,
      'ean': ean,
      'internalCode': internalCode,
      'stockTracked': stockTracked,
    };