Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- mealsSubscription = MealsBloc.todayMealsStream.listen((todayMeals) {
- setState(() {
- if (todayMeals!= null && todayMeals.length>0){
- CircularLoadingBloc.stop();
- meals = todayMeals;
- }
- else{
- meals.clear();
- }
- });
- });
- MediaQuery.removePadding(
- context: context,
- child: ListView.builder(
- physics: NeverScrollableScrollPhysics(),
- shrinkWrap: true,
- itemCount: meals.length,
- itemBuilder: (context, index) {
- return MealItem(
- meal: meals.elementAt(index),
- showButton: true,
- redeemed: true,
- showDate:false,
- inSubscription: true,
- date: MealsBloc.currentVisibleDate,
- );
- },
- ),
- removeTop: true,
- ),
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement