More redux work in fires page
This commit is contained in:
parent
5d947f9577
commit
7dddf03e32
13 changed files with 210 additions and 54 deletions
|
|
@ -91,7 +91,7 @@ class _ActiveFiresPageState extends State<ActiveFiresPage> {
|
|||
: Icons.notifications_off),
|
||||
onPressed: () {
|
||||
loc.subscribed = !loc.subscribed;
|
||||
onToggle(loc.id);
|
||||
onToggle(loc);
|
||||
/* FIXME int i = globals.yourLocations.indexOf(loc);
|
||||
globals.yourLocations.removeAt(i);
|
||||
globals.yourLocations.insert(i, loc);
|
||||
|
|
@ -189,8 +189,8 @@ class _ActiveFiresPageState extends State<ActiveFiresPage> {
|
|||
onDelete: (id) {
|
||||
store.dispatch(new DeleteYourLocationAction(id));
|
||||
},
|
||||
onToggleSubs: (id) {
|
||||
store.dispatch(new ToggleSubscriptionAction(id));
|
||||
onToggleSubs: (loc) {
|
||||
store.dispatch(new ToggleSubscriptionAction(loc));
|
||||
},
|
||||
yourLocations: store.state.yourLocations);
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue