WIP
This commit is contained in:
parent
cf79bff8e4
commit
3ed50939d0
|
@ -281,6 +281,34 @@ class PreferencesPageModel with ChangeNotifier {
|
||||||
cliID: FFAppState().cliUUID,
|
cliID: FFAppState().cliUUID,
|
||||||
tarefa: 'I',
|
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
|
// ignore: body_might_complete_normally_catch_error
|
||||||
.catchError((err, stack) {
|
.catchError((err, stack) {
|
||||||
log(err.toString());
|
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();
|
notifyListeners();
|
||||||
} catch (err, stack) {
|
} catch (err, stack) {
|
||||||
log(err.toString());
|
log(err.toString());
|
||||||
|
|
Loading…
Reference in New Issue