BrandItem constructor

const BrandItem({
  1. @JsonKey(name: 'brandId') @Default(0) int brandid,
  2. @JsonKey(name: 'cid') @Default(0) int cid,
  3. @JsonKey(name: 'brandName') @Default('') String brandname,
  4. @JsonKey(name: 'brandFeatures') @Default('') String brandfeatures,
  5. @JsonKey(name: 'sales') @Default(0) int sales,
  6. @JsonKey(name: 'maxDiscountAmount') @Default(0) int maxdiscountamount,
  7. @JsonKey(name: 'maxDiscount') @Default(0.0) double maxdiscount,
  8. @JsonKey(name: 'brandDesc') @Default('') String branddesc,
  9. @JsonKey(name: 'sort') @Default(0) int sort,
  10. @JsonKey(name: 'goodsList') @Default(IListConst([])) IList<BrandGoodslist> goodslist,
})

Implementation

const factory BrandItem({
    @JsonKey(name: 'brandId') @Default(0)  int brandid,
    @JsonKey(name: 'cid') @Default(0)  int cid,
    @JsonKey(name: 'brandName') @Default('')  String brandname,
    @JsonKey(name: 'brandLogo') @Default('')  String brandlogo,
    @JsonKey(name: 'brandFeatures') @Default('')  String brandfeatures,
    @JsonKey(name: 'sales') @Default(0)  int sales,
    @JsonKey(name: 'maxDiscountAmount') @Default(0)  int maxdiscountamount,
    @JsonKey(name: 'maxDiscount') @Default(0.0)  double maxdiscount,
    @JsonKey(name: 'brandDesc') @Default('')  String branddesc,
    @JsonKey(name: 'sort') @Default(0)  int sort,
    @JsonKey(name: 'goodsList') @Default(IListConst([]))  IList<BrandGoodslist> goodslist,
  }) = _BrandItem;