2
0
mirror of https://github.com/inventree/inventree-app.git synced 2025-06-12 18:25:26 +00:00

Fixes for type casting

This commit is contained in:
Oliver
2021-09-28 17:53:14 +10:00
parent 9d95cae612
commit c1152ee286
18 changed files with 294 additions and 228 deletions

View File

@ -45,7 +45,7 @@ class _InvenTreeAppSettingsState extends State<InvenTreeAppSettingsWidget> {
void setBarcodeSounds(bool en) async {
await InvenTreeSettingsManager().setValue("barcodeSounds", en);
barcodeSounds = await InvenTreeSettingsManager().getValue("barcodeSounds", true);
barcodeSounds = await InvenTreeSettingsManager().getBool("barcodeSounds", true);
setState(() {
});
@ -54,7 +54,7 @@ class _InvenTreeAppSettingsState extends State<InvenTreeAppSettingsWidget> {
void setServerSounds(bool en) async {
await InvenTreeSettingsManager().setValue("serverSounds", en);
serverSounds = await InvenTreeSettingsManager().getValue("serverSounds", true);
serverSounds = await InvenTreeSettingsManager().getBool("serverSounds", true);
setState(() {
});
@ -62,7 +62,7 @@ class _InvenTreeAppSettingsState extends State<InvenTreeAppSettingsWidget> {
void setPartSubcategory(bool en) async {
await InvenTreeSettingsManager().setValue("partSubcategory", en);
partSubcategory = await InvenTreeSettingsManager().getValue("partSubcategory", true);
partSubcategory = await InvenTreeSettingsManager().getBool("partSubcategory", true);
setState(() {
});
@ -70,7 +70,7 @@ class _InvenTreeAppSettingsState extends State<InvenTreeAppSettingsWidget> {
void setStockSublocation(bool en) async {
await InvenTreeSettingsManager().setValue("stockSublocation", en);
stockSublocation = await InvenTreeSettingsManager().getValue("stockSublocation", true);
stockSublocation = await InvenTreeSettingsManager().getBool("stockSublocation", true);
setState(() {
});