Tablet layout
This commit is contained in:
parent
49d4b3c9d2
commit
8ac5642c06
|
|
@ -70,10 +70,18 @@ Middleware<AppState> _viewExpense() {
|
|||
NextDispatcher next) async {
|
||||
final action = dynamicAction as ViewExpense;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(ExpenseViewScreen.route));
|
||||
Navigator.of(action.context).pushNamed(ExpenseViewScreen.route);
|
||||
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamed(ExpenseViewScreen.route);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -81,12 +89,19 @@ Middleware<AppState> _viewExpenseList() {
|
|||
return (Store<AppState> store, dynamic dynamicAction, NextDispatcher next) {
|
||||
final action = dynamicAction as ViewExpenseList;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(ExpenseScreen.route));
|
||||
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
ExpenseScreen.route, (Route<dynamic> route) => false);
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
ExpenseScreen.route, (Route<dynamic> route) => false);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -69,10 +69,18 @@ Middleware<AppState> _viewTask() {
|
|||
NextDispatcher next) async {
|
||||
final action = dynamicAction as ViewTask;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(TaskViewScreen.route));
|
||||
Navigator.of(action.context).pushNamed(TaskViewScreen.route);
|
||||
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamed(TaskViewScreen.route);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -80,12 +88,19 @@ Middleware<AppState> _viewTaskList() {
|
|||
return (Store<AppState> store, dynamic dynamicAction, NextDispatcher next) {
|
||||
final action = dynamicAction as ViewTaskList;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(TaskScreen.route));
|
||||
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
TaskScreen.route, (Route<dynamic> route) => false);
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
TaskScreen.route, (Route<dynamic> route) => false);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -70,10 +70,18 @@ Middleware<AppState> _viewVendor() {
|
|||
NextDispatcher next) async {
|
||||
final action = dynamicAction as ViewVendor;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(VendorViewScreen.route));
|
||||
Navigator.of(action.context).pushNamed(VendorViewScreen.route);
|
||||
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamed(VendorViewScreen.route);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -81,12 +89,19 @@ Middleware<AppState> _viewVendorList() {
|
|||
return (Store<AppState> store, dynamic dynamicAction, NextDispatcher next) {
|
||||
final action = dynamicAction as ViewVendorList;
|
||||
|
||||
if (hasChanges(
|
||||
store: store, context: action.context, force: action.force)) {
|
||||
return;
|
||||
}
|
||||
|
||||
next(action);
|
||||
|
||||
store.dispatch(UpdateCurrentRoute(VendorScreen.route));
|
||||
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
VendorScreen.route, (Route<dynamic> route) => false);
|
||||
if (isMobile(action.context)) {
|
||||
Navigator.of(action.context).pushNamedAndRemoveUntil(
|
||||
VendorScreen.route, (Route<dynamic> route) => false);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue