|
|
|
|
@ -19,13 +19,13 @@ class ShoppingCart {
|
|
|
|
|
this.shoppingCarts,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
int itemCount;
|
|
|
|
|
int quantityCount;
|
|
|
|
|
double subtotal;
|
|
|
|
|
double subtotalWithVat;
|
|
|
|
|
double subtotalVatAmount;
|
|
|
|
|
int subtotalVatRate;
|
|
|
|
|
List<ShoppingCartElement> shoppingCarts;
|
|
|
|
|
int? itemCount;
|
|
|
|
|
int? quantityCount;
|
|
|
|
|
double? subtotal;
|
|
|
|
|
double? subtotalWithVat;
|
|
|
|
|
double? subtotalVatAmount;
|
|
|
|
|
int? subtotalVatRate;
|
|
|
|
|
List<ShoppingCartElement>? shoppingCarts;
|
|
|
|
|
|
|
|
|
|
factory ShoppingCart.fromJson(Map<String, dynamic> json) => ShoppingCart(
|
|
|
|
|
itemCount: json["item_count"],
|
|
|
|
|
@ -73,27 +73,27 @@ class ShoppingCartElement {
|
|
|
|
|
this.customer,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
int languageId;
|
|
|
|
|
String id;
|
|
|
|
|
List<dynamic> productAttributes;
|
|
|
|
|
int customerEnteredPrice;
|
|
|
|
|
int quantity;
|
|
|
|
|
int? languageId;
|
|
|
|
|
String ?id;
|
|
|
|
|
List<dynamic>? productAttributes;
|
|
|
|
|
int? customerEnteredPrice;
|
|
|
|
|
int? quantity;
|
|
|
|
|
dynamic discountAmountInclTax;
|
|
|
|
|
String subtotal;
|
|
|
|
|
String subtotalWithVat;
|
|
|
|
|
String subtotalVatAmount;
|
|
|
|
|
String subtotalVatRate;
|
|
|
|
|
String currency;
|
|
|
|
|
String currencyn;
|
|
|
|
|
String? subtotal;
|
|
|
|
|
String? subtotalWithVat;
|
|
|
|
|
String? subtotalVatAmount;
|
|
|
|
|
String? subtotalVatRate;
|
|
|
|
|
String? currency;
|
|
|
|
|
String? currencyn;
|
|
|
|
|
dynamic rentalStartDateUtc;
|
|
|
|
|
dynamic rentalEndDateUtc;
|
|
|
|
|
DateTime createdOnUtc;
|
|
|
|
|
DateTime updatedOnUtc;
|
|
|
|
|
String shoppingCartType;
|
|
|
|
|
int productId;
|
|
|
|
|
Product product;
|
|
|
|
|
int customerId;
|
|
|
|
|
Customer customer;
|
|
|
|
|
DateTime? createdOnUtc;
|
|
|
|
|
DateTime? updatedOnUtc;
|
|
|
|
|
String? shoppingCartType;
|
|
|
|
|
int? productId;
|
|
|
|
|
Product? product;
|
|
|
|
|
int? customerId;
|
|
|
|
|
Customer? customer;
|
|
|
|
|
|
|
|
|
|
factory ShoppingCartElement.fromJson(Map<String, dynamic> json) => ShoppingCartElement(
|
|
|
|
|
languageId: json["language_id"],
|
|
|
|
|
@ -122,7 +122,7 @@ class ShoppingCartElement {
|
|
|
|
|
Map<String, dynamic> toJson() => {
|
|
|
|
|
"language_id": languageId,
|
|
|
|
|
"id": id,
|
|
|
|
|
"product_attributes": List<dynamic>.from(productAttributes.map((x) => x)),
|
|
|
|
|
"product_attributes": List<dynamic>.from(productAttributes!.map((x) => x)),
|
|
|
|
|
"customer_entered_price": customerEnteredPrice,
|
|
|
|
|
"quantity": quantity,
|
|
|
|
|
"discount_amount_incl_tax": discountAmountInclTax,
|
|
|
|
|
@ -134,13 +134,13 @@ class ShoppingCartElement {
|
|
|
|
|
"currencyn": currencyn,
|
|
|
|
|
"rental_start_date_utc": rentalStartDateUtc,
|
|
|
|
|
"rental_end_date_utc": rentalEndDateUtc,
|
|
|
|
|
"created_on_utc": createdOnUtc.toIso8601String(),
|
|
|
|
|
"updated_on_utc": updatedOnUtc.toIso8601String(),
|
|
|
|
|
"created_on_utc": createdOnUtc!.toIso8601String(),
|
|
|
|
|
"updated_on_utc": updatedOnUtc!.toIso8601String(),
|
|
|
|
|
"shopping_cart_type": shoppingCartType,
|
|
|
|
|
"product_id": productId,
|
|
|
|
|
"product": product.toJson(),
|
|
|
|
|
"product": product!.toJson(),
|
|
|
|
|
"customer_id": customerId,
|
|
|
|
|
"customer": customer.toJson(),
|
|
|
|
|
"customer": customer!.toJson(),
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -170,28 +170,28 @@ class Customer {
|
|
|
|
|
this.roleIds,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
Address billingAddress;
|
|
|
|
|
Address shippingAddress;
|
|
|
|
|
List<Address> addresses;
|
|
|
|
|
String id;
|
|
|
|
|
String username;
|
|
|
|
|
String email;
|
|
|
|
|
Address? billingAddress;
|
|
|
|
|
Address? shippingAddress;
|
|
|
|
|
List<Address>? addresses;
|
|
|
|
|
String? id;
|
|
|
|
|
String? username;
|
|
|
|
|
String? email;
|
|
|
|
|
dynamic firstName;
|
|
|
|
|
dynamic lastName;
|
|
|
|
|
dynamic languageId;
|
|
|
|
|
dynamic adminComment;
|
|
|
|
|
bool isTaxExempt;
|
|
|
|
|
bool hasShoppingCartItems;
|
|
|
|
|
bool active;
|
|
|
|
|
bool deleted;
|
|
|
|
|
bool isSystemAccount;
|
|
|
|
|
bool? isTaxExempt;
|
|
|
|
|
bool? hasShoppingCartItems;
|
|
|
|
|
bool? active;
|
|
|
|
|
bool? deleted;
|
|
|
|
|
bool? isSystemAccount;
|
|
|
|
|
dynamic systemName;
|
|
|
|
|
String lastIpAddress;
|
|
|
|
|
DateTime createdOnUtc;
|
|
|
|
|
DateTime lastLoginDateUtc;
|
|
|
|
|
DateTime lastActivityDateUtc;
|
|
|
|
|
int registeredInStoreId;
|
|
|
|
|
List<dynamic> roleIds;
|
|
|
|
|
String?lastIpAddress;
|
|
|
|
|
DateTime? createdOnUtc;
|
|
|
|
|
DateTime? lastLoginDateUtc;
|
|
|
|
|
DateTime? lastActivityDateUtc;
|
|
|
|
|
int? registeredInStoreId;
|
|
|
|
|
List<dynamic>? roleIds;
|
|
|
|
|
|
|
|
|
|
factory Customer.fromJson(Map<String, dynamic> json) => Customer(
|
|
|
|
|
billingAddress: Address.fromJson(json["billing_address"]),
|
|
|
|
|
@ -219,9 +219,9 @@ class Customer {
|
|
|
|
|
);
|
|
|
|
|
|
|
|
|
|
Map<String, dynamic> toJson() => {
|
|
|
|
|
"billing_address": billingAddress.toJson(),
|
|
|
|
|
"shipping_address": shippingAddress.toJson(),
|
|
|
|
|
"addresses": List<dynamic>.from(addresses.map((x) => x.toJson())),
|
|
|
|
|
"billing_address": billingAddress!.toJson(),
|
|
|
|
|
"shipping_address": shippingAddress!.toJson(),
|
|
|
|
|
"addresses": List<dynamic>.from(addresses!.map((x) => x.toJson())),
|
|
|
|
|
"id": id,
|
|
|
|
|
"username": username,
|
|
|
|
|
"email": email,
|
|
|
|
|
@ -236,11 +236,11 @@ class Customer {
|
|
|
|
|
"is_system_account": isSystemAccount,
|
|
|
|
|
"system_name": systemName,
|
|
|
|
|
"last_ip_address": lastIpAddress,
|
|
|
|
|
"created_on_utc": createdOnUtc.toIso8601String(),
|
|
|
|
|
"last_login_date_utc": lastLoginDateUtc.toIso8601String(),
|
|
|
|
|
"last_activity_date_utc": lastActivityDateUtc.toIso8601String(),
|
|
|
|
|
"created_on_utc": createdOnUtc!.toIso8601String(),
|
|
|
|
|
"last_login_date_utc": lastLoginDateUtc!.toIso8601String(),
|
|
|
|
|
"last_activity_date_utc": lastActivityDateUtc!.toIso8601String(),
|
|
|
|
|
"registered_in_store_id": registeredInStoreId,
|
|
|
|
|
"role_ids": List<dynamic>.from(roleIds.map((x) => x)),
|
|
|
|
|
"role_ids": List<dynamic>.from(roleIds!.map((x) => x)),
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -266,24 +266,24 @@ class Address {
|
|
|
|
|
this.latLong,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
String id;
|
|
|
|
|
FirstName firstName;
|
|
|
|
|
LastName lastName;
|
|
|
|
|
Email email;
|
|
|
|
|
String? id;
|
|
|
|
|
FirstName? firstName;
|
|
|
|
|
LastName? lastName;
|
|
|
|
|
Email? email;
|
|
|
|
|
dynamic company;
|
|
|
|
|
int countryId;
|
|
|
|
|
Country country;
|
|
|
|
|
int? countryId;
|
|
|
|
|
Country? country;
|
|
|
|
|
dynamic stateProvinceId;
|
|
|
|
|
City city;
|
|
|
|
|
String address1;
|
|
|
|
|
String address2;
|
|
|
|
|
String zipPostalCode;
|
|
|
|
|
String phoneNumber;
|
|
|
|
|
City? city;
|
|
|
|
|
String? address1;
|
|
|
|
|
String? address2;
|
|
|
|
|
String? zipPostalCode;
|
|
|
|
|
String? phoneNumber;
|
|
|
|
|
dynamic faxNumber;
|
|
|
|
|
String customerAttributes;
|
|
|
|
|
DateTime createdOnUtc;
|
|
|
|
|
String? customerAttributes;
|
|
|
|
|
DateTime? createdOnUtc;
|
|
|
|
|
dynamic province;
|
|
|
|
|
String latLong;
|
|
|
|
|
String? latLong;
|
|
|
|
|
|
|
|
|
|
factory Address.fromJson(Map<String, dynamic> json) => Address(
|
|
|
|
|
id: json["id"],
|
|
|
|
|
@ -322,7 +322,7 @@ class Address {
|
|
|
|
|
"phone_number": phoneNumber,
|
|
|
|
|
"fax_number": faxNumber,
|
|
|
|
|
"customer_attributes": customerAttributes,
|
|
|
|
|
"created_on_utc": createdOnUtc.toIso8601String(),
|
|
|
|
|
"created_on_utc": createdOnUtc!.toIso8601String(),
|
|
|
|
|
"province": province,
|
|
|
|
|
"lat_long": latLong,
|
|
|
|
|
};
|
|
|
|
|
@ -480,117 +480,117 @@ class Product {
|
|
|
|
|
this.seName,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
String id;
|
|
|
|
|
bool visibleIndividually;
|
|
|
|
|
String name;
|
|
|
|
|
String namen;
|
|
|
|
|
List<LocalizedName> localizedNames;
|
|
|
|
|
String shortDescription;
|
|
|
|
|
String shortDescriptionn;
|
|
|
|
|
String fullDescription;
|
|
|
|
|
String fullDescriptionn;
|
|
|
|
|
bool markasNew;
|
|
|
|
|
bool showOnHomePage;
|
|
|
|
|
String metaKeywords;
|
|
|
|
|
String metaDescription;
|
|
|
|
|
String metaTitle;
|
|
|
|
|
bool allowCustomerReviews;
|
|
|
|
|
int approvedRatingSum;
|
|
|
|
|
int notApprovedRatingSum;
|
|
|
|
|
int approvedTotalReviews;
|
|
|
|
|
int notApprovedTotalReviews;
|
|
|
|
|
String sku;
|
|
|
|
|
bool isRx;
|
|
|
|
|
bool prescriptionRequired;
|
|
|
|
|
String? id;
|
|
|
|
|
bool? visibleIndividually;
|
|
|
|
|
String? name;
|
|
|
|
|
String? namen;
|
|
|
|
|
List<LocalizedName>? localizedNames;
|
|
|
|
|
String? shortDescription;
|
|
|
|
|
String? shortDescriptionn;
|
|
|
|
|
String? fullDescription;
|
|
|
|
|
String? fullDescriptionn;
|
|
|
|
|
bool? markasNew;
|
|
|
|
|
bool? showOnHomePage;
|
|
|
|
|
String? metaKeywords;
|
|
|
|
|
String? metaDescription;
|
|
|
|
|
String? metaTitle;
|
|
|
|
|
bool? allowCustomerReviews;
|
|
|
|
|
int? approvedRatingSum;
|
|
|
|
|
int? notApprovedRatingSum;
|
|
|
|
|
int? approvedTotalReviews;
|
|
|
|
|
int? notApprovedTotalReviews;
|
|
|
|
|
String? sku;
|
|
|
|
|
bool? isRx;
|
|
|
|
|
bool? prescriptionRequired;
|
|
|
|
|
dynamic rxMessage;
|
|
|
|
|
dynamic rxMessagen;
|
|
|
|
|
dynamic manufacturerPartNumber;
|
|
|
|
|
dynamic gtin;
|
|
|
|
|
bool isGiftCard;
|
|
|
|
|
bool requireOtherProducts;
|
|
|
|
|
bool automaticallyAddRequiredProducts;
|
|
|
|
|
bool isDownload;
|
|
|
|
|
bool unlimitedDownloads;
|
|
|
|
|
int maxNumberOfDownloads;
|
|
|
|
|
bool? isGiftCard;
|
|
|
|
|
bool? requireOtherProducts;
|
|
|
|
|
bool? automaticallyAddRequiredProducts;
|
|
|
|
|
bool? isDownload;
|
|
|
|
|
bool? unlimitedDownloads;
|
|
|
|
|
int? maxNumberOfDownloads;
|
|
|
|
|
dynamic downloadExpirationDays;
|
|
|
|
|
bool hasSampleDownload;
|
|
|
|
|
bool hasUserAgreement;
|
|
|
|
|
bool isRecurring;
|
|
|
|
|
int recurringCycleLength;
|
|
|
|
|
int recurringTotalCycles;
|
|
|
|
|
bool isRental;
|
|
|
|
|
int rentalPriceLength;
|
|
|
|
|
bool isShipEnabled;
|
|
|
|
|
bool isFreeShipping;
|
|
|
|
|
bool shipSeparately;
|
|
|
|
|
int additionalShippingCharge;
|
|
|
|
|
bool isTaxExempt;
|
|
|
|
|
bool isTelecommunicationsOrBroadcastingOrElectronicServices;
|
|
|
|
|
bool useMultipleWarehouses;
|
|
|
|
|
int manageInventoryMethodId;
|
|
|
|
|
int stockQuantity;
|
|
|
|
|
String stockAvailability;
|
|
|
|
|
String stockAvailabilityn;
|
|
|
|
|
bool displayStockAvailability;
|
|
|
|
|
bool displayStockQuantity;
|
|
|
|
|
int minStockQuantity;
|
|
|
|
|
int notifyAdminForQuantityBelow;
|
|
|
|
|
bool allowBackInStockSubscriptions;
|
|
|
|
|
int orderMinimumQuantity;
|
|
|
|
|
int orderMaximumQuantity;
|
|
|
|
|
bool? hasSampleDownload;
|
|
|
|
|
bool? hasUserAgreement;
|
|
|
|
|
bool? isRecurring;
|
|
|
|
|
int? recurringCycleLength;
|
|
|
|
|
int? recurringTotalCycles;
|
|
|
|
|
bool? isRental;
|
|
|
|
|
int? rentalPriceLength;
|
|
|
|
|
bool? isShipEnabled;
|
|
|
|
|
bool? isFreeShipping;
|
|
|
|
|
bool? shipSeparately;
|
|
|
|
|
int? additionalShippingCharge;
|
|
|
|
|
bool? isTaxExempt;
|
|
|
|
|
bool? isTelecommunicationsOrBroadcastingOrElectronicServices;
|
|
|
|
|
bool? useMultipleWarehouses;
|
|
|
|
|
int? manageInventoryMethodId;
|
|
|
|
|
int? stockQuantity;
|
|
|
|
|
String? stockAvailability;
|
|
|
|
|
String? stockAvailabilityn;
|
|
|
|
|
bool? displayStockAvailability;
|
|
|
|
|
bool? displayStockQuantity;
|
|
|
|
|
int? minStockQuantity;
|
|
|
|
|
int? notifyAdminForQuantityBelow;
|
|
|
|
|
bool? allowBackInStockSubscriptions;
|
|
|
|
|
int? orderMinimumQuantity;
|
|
|
|
|
int? orderMaximumQuantity;
|
|
|
|
|
dynamic allowedQuantities;
|
|
|
|
|
bool allowAddingOnlyExistingAttributeCombinations;
|
|
|
|
|
bool disableBuyButton;
|
|
|
|
|
bool disableWishlistButton;
|
|
|
|
|
bool availableForPreOrder;
|
|
|
|
|
bool? allowAddingOnlyExistingAttributeCombinations;
|
|
|
|
|
bool? disableBuyButton;
|
|
|
|
|
bool? disableWishlistButton;
|
|
|
|
|
bool? availableForPreOrder;
|
|
|
|
|
dynamic preOrderAvailabilityStartDateTimeUtc;
|
|
|
|
|
bool callForPrice;
|
|
|
|
|
double price;
|
|
|
|
|
int oldPrice;
|
|
|
|
|
double productCost;
|
|
|
|
|
bool? callForPrice;
|
|
|
|
|
double? price;
|
|
|
|
|
int? oldPrice;
|
|
|
|
|
double? productCost;
|
|
|
|
|
dynamic specialPrice;
|
|
|
|
|
dynamic specialPriceStartDateTimeUtc;
|
|
|
|
|
dynamic specialPriceEndDateTimeUtc;
|
|
|
|
|
bool customerEntersPrice;
|
|
|
|
|
int minimumCustomerEnteredPrice;
|
|
|
|
|
int maximumCustomerEnteredPrice;
|
|
|
|
|
bool basepriceEnabled;
|
|
|
|
|
int basepriceAmount;
|
|
|
|
|
int basepriceBaseAmount;
|
|
|
|
|
bool hasTierPrices;
|
|
|
|
|
bool hasDiscountsApplied;
|
|
|
|
|
bool? customerEntersPrice;
|
|
|
|
|
int? minimumCustomerEnteredPrice;
|
|
|
|
|
int? maximumCustomerEnteredPrice;
|
|
|
|
|
bool? basepriceEnabled;
|
|
|
|
|
int? basepriceAmount;
|
|
|
|
|
int? basepriceBaseAmount;
|
|
|
|
|
bool? hasTierPrices;
|
|
|
|
|
bool? hasDiscountsApplied;
|
|
|
|
|
dynamic discountName;
|
|
|
|
|
dynamic discountNamen;
|
|
|
|
|
dynamic discountDescription;
|
|
|
|
|
dynamic discountDescriptionn;
|
|
|
|
|
dynamic discountPercentage;
|
|
|
|
|
String currency;
|
|
|
|
|
String currencyn;
|
|
|
|
|
double weight;
|
|
|
|
|
int length;
|
|
|
|
|
int width;
|
|
|
|
|
int height;
|
|
|
|
|
String? currency;
|
|
|
|
|
String? currencyn;
|
|
|
|
|
double? weight;
|
|
|
|
|
int? length;
|
|
|
|
|
int? width;
|
|
|
|
|
int? height;
|
|
|
|
|
dynamic availableStartDateTimeUtc;
|
|
|
|
|
dynamic availableEndDateTimeUtc;
|
|
|
|
|
int displayOrder;
|
|
|
|
|
bool published;
|
|
|
|
|
bool deleted;
|
|
|
|
|
DateTime createdOnUtc;
|
|
|
|
|
DateTime updatedOnUtc;
|
|
|
|
|
String productType;
|
|
|
|
|
int parentGroupedProductId;
|
|
|
|
|
List<dynamic> roleIds;
|
|
|
|
|
List<dynamic> discountIds;
|
|
|
|
|
List<dynamic> storeIds;
|
|
|
|
|
List<int> manufacturerIds;
|
|
|
|
|
List<dynamic> reviews;
|
|
|
|
|
List<Image> images;
|
|
|
|
|
List<dynamic> attributes;
|
|
|
|
|
List<Specification> specifications;
|
|
|
|
|
List<dynamic> associatedProductIds;
|
|
|
|
|
List<dynamic> tags;
|
|
|
|
|
int vendorId;
|
|
|
|
|
String seName;
|
|
|
|
|
int? displayOrder;
|
|
|
|
|
bool? published;
|
|
|
|
|
bool? deleted;
|
|
|
|
|
DateTime? createdOnUtc;
|
|
|
|
|
DateTime? updatedOnUtc;
|
|
|
|
|
String? productType;
|
|
|
|
|
int? parentGroupedProductId;
|
|
|
|
|
List<dynamic>? roleIds;
|
|
|
|
|
List<dynamic>? discountIds;
|
|
|
|
|
List<dynamic>? storeIds;
|
|
|
|
|
List<int>? manufacturerIds;
|
|
|
|
|
List<dynamic>? reviews;
|
|
|
|
|
List<Image>? images;
|
|
|
|
|
List<dynamic>? attributes;
|
|
|
|
|
List<Specification>? specifications;
|
|
|
|
|
List<dynamic>? associatedProductIds;
|
|
|
|
|
List<dynamic>? tags;
|
|
|
|
|
int? vendorId;
|
|
|
|
|
String? seName;
|
|
|
|
|
|
|
|
|
|
factory Product.fromJson(Map<String, dynamic> json) => Product(
|
|
|
|
|
id: json["id"],
|
|
|
|
|
@ -711,7 +711,7 @@ class Product {
|
|
|
|
|
"visible_individually": visibleIndividually,
|
|
|
|
|
"name": name,
|
|
|
|
|
"namen": namen,
|
|
|
|
|
"localized_names": List<dynamic>.from(localizedNames.map((x) => x.toJson())),
|
|
|
|
|
"localized_names": List<dynamic>.from(localizedNames!.map((x) => x.toJson())),
|
|
|
|
|
"short_description": shortDescription,
|
|
|
|
|
"short_descriptionn": shortDescriptionn,
|
|
|
|
|
"full_description": fullDescription,
|
|
|
|
|
@ -802,20 +802,20 @@ class Product {
|
|
|
|
|
"display_order": displayOrder,
|
|
|
|
|
"published": published,
|
|
|
|
|
"deleted": deleted,
|
|
|
|
|
"created_on_utc": createdOnUtc.toIso8601String(),
|
|
|
|
|
"updated_on_utc": updatedOnUtc.toIso8601String(),
|
|
|
|
|
"created_on_utc": createdOnUtc!.toIso8601String(),
|
|
|
|
|
"updated_on_utc": updatedOnUtc!.toIso8601String(),
|
|
|
|
|
"product_type": productType,
|
|
|
|
|
"parent_grouped_product_id": parentGroupedProductId,
|
|
|
|
|
"role_ids": List<dynamic>.from(roleIds.map((x) => x)),
|
|
|
|
|
"discount_ids": List<dynamic>.from(discountIds.map((x) => x)),
|
|
|
|
|
"store_ids": List<dynamic>.from(storeIds.map((x) => x)),
|
|
|
|
|
"manufacturer_ids": List<dynamic>.from(manufacturerIds.map((x) => x)),
|
|
|
|
|
"reviews": List<dynamic>.from(reviews.map((x) => x)),
|
|
|
|
|
"images": List<dynamic>.from(images.map((x) => x.toJson())),
|
|
|
|
|
"attributes": List<dynamic>.from(attributes.map((x) => x)),
|
|
|
|
|
"specifications": List<dynamic>.from(specifications.map((x) => x.toJson())),
|
|
|
|
|
"associated_product_ids": List<dynamic>.from(associatedProductIds.map((x) => x)),
|
|
|
|
|
"tags": List<dynamic>.from(tags.map((x) => x)),
|
|
|
|
|
"role_ids": List<dynamic>.from(roleIds!.map((x) => x)),
|
|
|
|
|
"discount_ids": List<dynamic>.from(discountIds!.map((x) => x)),
|
|
|
|
|
"store_ids": List<dynamic>.from(storeIds!.map((x) => x)),
|
|
|
|
|
"manufacturer_ids": List<dynamic>.from(manufacturerIds!.map((x) => x)),
|
|
|
|
|
"reviews": List<dynamic>.from(reviews!.map((x) => x)),
|
|
|
|
|
"images": List<dynamic>.from(images!.map((x) => x.toJson())),
|
|
|
|
|
"attributes": List<dynamic>.from(attributes!.map((x) => x)),
|
|
|
|
|
"specifications": List<dynamic>.from(specifications!.map((x) => x.toJson())),
|
|
|
|
|
"associated_product_ids": List<dynamic>.from(associatedProductIds!.map((x) => x)),
|
|
|
|
|
"tags": List<dynamic>.from(tags!.map((x) => x)),
|
|
|
|
|
"vendor_id": vendorId,
|
|
|
|
|
"se_name": seName,
|
|
|
|
|
};
|
|
|
|
|
@ -830,11 +830,11 @@ class Image {
|
|
|
|
|
this.attachment,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
int id;
|
|
|
|
|
int position;
|
|
|
|
|
String src;
|
|
|
|
|
String thumb;
|
|
|
|
|
String attachment;
|
|
|
|
|
int? id;
|
|
|
|
|
int? position;
|
|
|
|
|
String? src;
|
|
|
|
|
String? thumb;
|
|
|
|
|
String? attachment;
|
|
|
|
|
|
|
|
|
|
factory Image.fromJson(Map<String, dynamic> json) => Image(
|
|
|
|
|
id: json["id"],
|
|
|
|
|
@ -859,8 +859,8 @@ class LocalizedName {
|
|
|
|
|
this.localizedName,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
int languageId;
|
|
|
|
|
String localizedName;
|
|
|
|
|
int? languageId;
|
|
|
|
|
String? localizedName;
|
|
|
|
|
|
|
|
|
|
factory LocalizedName.fromJson(Map<String, dynamic> json) => LocalizedName(
|
|
|
|
|
languageId: json["language_id"],
|
|
|
|
|
@ -883,12 +883,12 @@ class Specification {
|
|
|
|
|
this.nameN,
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
int id;
|
|
|
|
|
int displayOrder;
|
|
|
|
|
String defaultValue;
|
|
|
|
|
String defaultValuen;
|
|
|
|
|
String name;
|
|
|
|
|
String nameN;
|
|
|
|
|
int? id;
|
|
|
|
|
int? displayOrder;
|
|
|
|
|
String? defaultValue;
|
|
|
|
|
String? defaultValuen;
|
|
|
|
|
String? name;
|
|
|
|
|
String? nameN;
|
|
|
|
|
|
|
|
|
|
factory Specification.fromJson(Map<String, dynamic> json) => Specification(
|
|
|
|
|
id: json["id"],
|
|
|
|
|
@ -910,15 +910,15 @@ class Specification {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class EnumValues<T> {
|
|
|
|
|
Map<String, T> map;
|
|
|
|
|
Map<T, String> reverseMap;
|
|
|
|
|
Map<String, T>? map;
|
|
|
|
|
Map<T, String>? reverseMap;
|
|
|
|
|
|
|
|
|
|
EnumValues(this.map);
|
|
|
|
|
|
|
|
|
|
Map<T, String> get reverse {
|
|
|
|
|
if (reverseMap == null) {
|
|
|
|
|
reverseMap = map.map((k, v) => new MapEntry(v, k));
|
|
|
|
|
reverseMap = map!.map((k, v) => new MapEntry(v, k));
|
|
|
|
|
}
|
|
|
|
|
return reverseMap;
|
|
|
|
|
return reverseMap!;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|