|
|
@ -58,26 +58,32 @@ class SettingsExportHelper { |
|
|
|
Map<String, dynamic> toJsonExport() => { |
|
|
|
Map<String, dynamic> toJsonExport() => { |
|
|
|
'global': { |
|
|
|
'global': { |
|
|
|
for (final option in globalOptions.options) ...{ |
|
|
|
for (final option in globalOptions.options) ...{ |
|
|
|
|
|
|
|
if (option.enabled.value) ...{ |
|
|
|
option.key: option.serialize(), |
|
|
|
option.key: option.serialize(), |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
}, |
|
|
|
'apps': { |
|
|
|
'apps': { |
|
|
|
for (final appImplementation in appImplementations) ...{ |
|
|
|
for (final appImplementation in appImplementations) ...{ |
|
|
|
appImplementation.id: { |
|
|
|
appImplementation.id: { |
|
|
|
for (final option in appImplementation.options.options) ...{ |
|
|
|
for (final option in appImplementation.options.options) ...{ |
|
|
|
|
|
|
|
if (option.enabled.value) ...{ |
|
|
|
option.key: option.serialize(), |
|
|
|
option.key: option.serialize(), |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
}, |
|
|
|
'accounts': { |
|
|
|
'accounts': { |
|
|
|
for (final account in accountSpecificOptions.keys) ...{ |
|
|
|
for (final account in accountSpecificOptions.keys) ...{ |
|
|
|
account.id: { |
|
|
|
account.id: { |
|
|
|
for (final option in accountSpecificOptions[account]!) ...{ |
|
|
|
for (final option in accountSpecificOptions[account]!) ...{ |
|
|
|
|
|
|
|
if (option.enabled.value) ...{ |
|
|
|
option.key: option.serialize(), |
|
|
|
option.key: option.serialize(), |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
|
|
|
|
}, |
|
|
|
}; |
|
|
|
}; |
|
|
|
} |
|
|
|
} |
|
|
|