fix crash app
parent
8c0ae9939a
commit
e1301e7340
|
|
@ -17,8 +17,8 @@ class SettingState {
|
|||
return SettingState(
|
||||
mode: payload?.mode ?? SettingModeKassa,
|
||||
tradeType: payload?.tradeType ?? SettingTradeTypeGood,
|
||||
pinCode: payload.pinCode ?? null,
|
||||
pinLocked: payload.pinLocked ?? false,
|
||||
pinCode: payload?.pinCode ?? null,
|
||||
pinLocked: payload?.pinLocked ?? false,
|
||||
pinSkip: false,
|
||||
);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -93,6 +93,7 @@ class _HomeViewState extends State<HomeView> with WidgetsBindingObserver {
|
|||
|
||||
_checkLockPin () async {
|
||||
if ( Redux.store.state.settingState.pinLocked == true) {
|
||||
await Future.delayed(Duration(milliseconds: 200));
|
||||
Navigator.of(context).push(MaterialPageRoute(
|
||||
builder: (_) =>
|
||||
WillPopScope(
|
||||
|
|
@ -108,11 +109,11 @@ class _HomeViewState extends State<HomeView> with WidgetsBindingObserver {
|
|||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
WidgetsBinding.instance.addObserver(this);
|
||||
selectedTabIndex = 0;
|
||||
pageController = new PageController(initialPage: selectedTabIndex);
|
||||
Redux.store.dispatch(checkSmena);
|
||||
_dataService.checkDbFill(Redux.store.state.userState.user);
|
||||
WidgetsBinding.instance.addObserver(this);
|
||||
_checkLockPin();
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ class _SettingViewState extends State<SettingView> {
|
|||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
centerTitle: true,
|
||||
title: Text('Настройка HalykPos'),
|
||||
title: Text('Настройка приложения'),
|
||||
),
|
||||
body: SingleChildScrollView(
|
||||
child: Container(
|
||||
|
|
|
|||
Loading…
Reference in New Issue