WIP
This commit is contained in:
parent
cf79bff8e4
commit
3ed50939d0
|
@ -281,6 +281,34 @@ class PreferencesPageModel with ChangeNotifier {
|
|||
cliID: FFAppState().cliUUID,
|
||||
tarefa: 'I',
|
||||
)
|
||||
.then((value) {
|
||||
FFAppState().deleteCliUUID();
|
||||
FFAppState().deleteLocal();
|
||||
FFAppState().deleteOwnerUUID();
|
||||
Navigator.pop(context);
|
||||
Navigator.pop(context);
|
||||
|
||||
ScaffoldMessenger.of(context).showSnackBar(
|
||||
SnackBar(
|
||||
content: Text(
|
||||
FFLocalizations.of(context).getVariableText(
|
||||
enText: 'Device unlinked successfully',
|
||||
ptText:
|
||||
'Dispositivo desvinculado com sucesso',
|
||||
),
|
||||
style: TextStyle(
|
||||
color:
|
||||
FlutterFlowTheme.of(context).info)),
|
||||
backgroundColor:
|
||||
FlutterFlowTheme.of(context).success,
|
||||
duration: const Duration(seconds: 3),
|
||||
behavior: SnackBarBehavior.floating,
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(30),
|
||||
),
|
||||
),
|
||||
);
|
||||
})
|
||||
// ignore: body_might_complete_normally_catch_error
|
||||
.catchError((err, stack) {
|
||||
log(err.toString());
|
||||
|
@ -303,15 +331,7 @@ class PreferencesPageModel with ChangeNotifier {
|
|||
),
|
||||
),
|
||||
);
|
||||
}).then(
|
||||
(value) {
|
||||
FFAppState().deleteCliUUID();
|
||||
FFAppState().deleteLocal();
|
||||
FFAppState().deleteOwnerUUID();
|
||||
Navigator.pop(context);
|
||||
Navigator.pop(context);
|
||||
},
|
||||
);
|
||||
});
|
||||
notifyListeners();
|
||||
} catch (err, stack) {
|
||||
log(err.toString());
|
||||
|
|
Loading…
Reference in New Issue