Products.fromJson constructor

Products.fromJson(
  1. Map<String, dynamic> json
)

Implementation

Products.fromJson(Map<String, dynamic> json) {
  id = json['id'];
  name = json['name'];
  description = json['description'];
  pogId = json['pogId'];
  productOfferGroupId = json['productOfferGroupId'];
  pogName = json['pogName'];
  poImage = json['poImage'];
  productFamilyId = json['productFamilyId'];
  productFamilyName = json['productFamilyName'];
  productId = json['productId'];
  assetId = json['assetId'];
  startAssetRange = json['startAssetRange'];
  endAssetRange = json['endAssetRange'];
  creditGl = json['credit_gl'];
  debitGl = json['debit_gl'];
  productType = json['productType'];
  armProductId = json['armProductId'];
  mainProductType = json['mainProductType'];
  serialNumber = json['serialNumber'];
  subProducts = json['subProducts'];
  contactNumber = json['contactNumber'];
  rateCartId = json['rateCartId'];
  isTopUp = json['isTopUp'];
  isEvc = json['isEvc'];
  replaceWarranty = json['replaceWarranty'];
  productSubType = json['productSubType'];
  senderContactNumber = json['senderContactNumber'];
  pinCodeValue = json['pinCodeValue'];
  imei = json['imei'];
  recommended = json['recommended'];
  if (json['errors'] != null) {
    errors = <Errors>[];
    json['errors'].forEach((v) {
      errors!.add(new Errors.fromJson(v));
    });
  }
  materialCode = json['materialCode'];
  materialCodeDescription = json['materialCodeDescription'];
  taxClassificationName = json['taxClassificationName'];
  taxClassificationDetails = json['taxClassificationDetails'] != null
      ? new TaxClassificationDetails.fromJson(
      json['taxClassificationDetails'])
      : null;
  currency = json['currency'];
  insuranceInfo = json['insuranceInfo'];
  repairWarranty = json['repairWarranty'];
  returnAssetStatus = json['returnAssetStatus'];
  eloadDetails = json['eloadDetails'];
  partnerId = json['partnerId'];
  quantity = json['quantity'];
  priceOverrideApplicable = json['priceOverrideApplicable'];
  priceOverridden = json['priceOverridden'];
  minValue = json['minValue'];
  maxValue = json['maxValue'];
  productOfferingPriceId = json['productOfferingPriceId'];
  bundleMainProductId = json['bundleMainProductId'];
  cpsRate = json['cpsRate'];
  showTaxes = json['showTaxes'];
  if (json['taxes'] != null) {
    taxes = <Taxes>[];
    json['taxes'].forEach((v) {
      taxes!.add(new Taxes.fromJson(v));
    });
  }
  if (json['discounts'] != null) {
    discounts = <Discounts>[];
    json['discounts'].forEach((v) {
      discounts!.add(new Discounts.fromJson(v));
    });
  }
  price = json['price'];
  priceWithoutTax = json['priceWithoutTax'];
  priceWithTax = json['priceWithTax'];
  priceWithoutDiscount = json['priceWithoutDiscount'];
  priceWithDiscount = json['priceWithDiscount'];
  totalDiscount = json['totalDiscount'];
  discountPercentage = json['discountPercentage'];
  dutyFreeAmount = json['dutyFreeAmount'];
  unitPrice = json['unitPrice'];
  unitPriceWithoutTax = json['unitPriceWithoutTax'];
  unitTax = json['unitTax'];
  unitDiscount = json['unitDiscount'];
  sellingPrice = json['sellingPrice'];
  sellingUnitPrice = json['sellingUnitPrice'];
  priceWithoutTaxAndDiscount = json['priceWithoutTaxAndDiscount'];
  priceWithoutTaxAndWithDiscount = json['priceWithoutTaxAndWithDiscount'];
  unitNetAmount = json['unitNetAmount'];
  totalNetAmount = json['totalNetAmount'];
  wht = json['wht'];
  unitWht = json['unitWht'];
  taxAmount = json['taxAmount'];
  taxRate = json['taxRate'];
  whtPercentage = json['whtPercentage'];
  totalDiscountAmount = json['totalDiscountAmount'];
  cpsAmount = json['cpsAmount'];
  originalPrice = json['originalPrice'];
  subTotal = json['subTotal'];
  brandName = json['brandName'];
  brandId = json['brandId'];
  brandNameDescription = json['brandNameDescription'];
  transTypeName = json['transTypeName'];
  transTypeId = json['transTypeId'];
  transTypeDescription = json['transTypeDescription'];
  payableAmount = json['payableAmount'];
  totalDiscountAmountWithOutTax = json['totalDiscountAmountWithOutTax'];
  totalPriceWithOutTaxAndDiscountWithOutTax =
  json['totalPriceWithOutTaxAndDiscountWithOutTax'];
  bundleOffer = json['bundleOffer'];
  subOffers = json['subOffers'];
  transactionType = json['transactionType'];
  groupQuantity = json['groupQuantity'];
  plantName = json['plantName'];
  plantId = json['plantId'];
  plantDescription = json['plantDescription'];
  storageLocationName = json['storageLocationName'];
  storageLocationId = json['storageLocationId'];
  storageLocationDescription = json['storageLocationDescription'];
  autoRefill = json['autoRefill'];
  startPrice = json['startPrice'];
  endPrice = json['endPrice'];
  mPin = json['mPin'];
  senderUserId = json['senderUserId'];
}