Adding model for mapping
This commit is contained in:
parent
64d27a2edc
commit
7e1a773984
@ -1,12 +1,10 @@
|
||||
|
||||
|
||||
import 'package:candystore/models/card_data.dart';
|
||||
|
||||
class HomeData {
|
||||
class CandyData {
|
||||
final List<CardData>? data;
|
||||
final int? nextPage;
|
||||
final int? currentPage;
|
||||
final int? totalPages;
|
||||
|
||||
HomeData({this.data, this.nextPage, this.currentPage, this.totalPages});
|
||||
}
|
||||
CandyData({this.data, this.nextPage, this.currentPage, this.totalPages});
|
||||
}
|
@ -2,9 +2,13 @@ class CardData {
|
||||
final String flavorName;
|
||||
final String imageUrl;
|
||||
final String description;
|
||||
final String groupName;
|
||||
final List<String> groupName;
|
||||
final int? beanId;
|
||||
|
||||
const CardData(
|
||||
{ required this.flavorName, required this.imageUrl, required this.description, required this.groupName, required this.beanId });
|
||||
}
|
||||
const CardData(
|
||||
{required this.flavorName,
|
||||
required this.imageUrl,
|
||||
required this.description,
|
||||
required this.groupName,
|
||||
required this.beanId});
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user