mirror of
https://gitlab.com/comunic/comunicmobile
synced 2024-11-26 14:59:22 +00:00
Finish data conservation policy screen
This commit is contained in:
parent
3a39387365
commit
1d0bd45632
@ -62,7 +62,7 @@ class _AccountPrivacySettingsState extends State<AccountPrivacySettings> {
|
|||||||
List<SettingsTile> get _dataConservationPolicyTiles => [
|
List<SettingsTile> get _dataConservationPolicyTiles => [
|
||||||
DataConservationPolicyTile(
|
DataConservationPolicyTile(
|
||||||
value: _userSettings.notificationLifetime,
|
value: _userSettings.notificationLifetime,
|
||||||
title: tr("Automatically delete unread notification after"),
|
title: tr("Automatically delete unread notifications after"),
|
||||||
onChange: (val) {
|
onChange: (val) {
|
||||||
_userSettings.notificationLifetime = val;
|
_userSettings.notificationLifetime = val;
|
||||||
_updateDataConservationPolicy();
|
_updateDataConservationPolicy();
|
||||||
@ -70,6 +70,54 @@ class _AccountPrivacySettingsState extends State<AccountPrivacySettings> {
|
|||||||
minValue:
|
minValue:
|
||||||
_serverConfig.dataConservationPolicy.minNotificationLifetime,
|
_serverConfig.dataConservationPolicy.minNotificationLifetime,
|
||||||
),
|
),
|
||||||
|
DataConservationPolicyTile(
|
||||||
|
value: _userSettings.commentsLifetime,
|
||||||
|
title: tr("Automatically delete your comments after"),
|
||||||
|
onChange: (val) {
|
||||||
|
_userSettings.commentsLifetime = val;
|
||||||
|
_updateDataConservationPolicy();
|
||||||
|
},
|
||||||
|
minValue: _serverConfig.dataConservationPolicy.minCommentsLifetime,
|
||||||
|
),
|
||||||
|
DataConservationPolicyTile(
|
||||||
|
value: _userSettings.postsLifetime,
|
||||||
|
title: tr("Automatically delete your posts after"),
|
||||||
|
onChange: (val) {
|
||||||
|
_userSettings.postsLifetime = val;
|
||||||
|
_updateDataConservationPolicy();
|
||||||
|
},
|
||||||
|
minValue: _serverConfig.dataConservationPolicy.minPostsLifetime,
|
||||||
|
),
|
||||||
|
DataConservationPolicyTile(
|
||||||
|
value: _userSettings.conversationMessagesLifetime,
|
||||||
|
title: tr("Automatically delete your conversation messages after"),
|
||||||
|
onChange: (val) {
|
||||||
|
_userSettings.conversationMessagesLifetime = val;
|
||||||
|
_updateDataConservationPolicy();
|
||||||
|
},
|
||||||
|
minValue: _serverConfig
|
||||||
|
.dataConservationPolicy.minConversationMessagesLifetime,
|
||||||
|
),
|
||||||
|
DataConservationPolicyTile(
|
||||||
|
value: _userSettings.likesLifetime,
|
||||||
|
title: tr("Automatically delete your likes after"),
|
||||||
|
onChange: (val) {
|
||||||
|
_userSettings.likesLifetime = val;
|
||||||
|
_updateDataConservationPolicy();
|
||||||
|
},
|
||||||
|
minValue: _serverConfig.dataConservationPolicy.minLikesLifetime,
|
||||||
|
),
|
||||||
|
DataConservationPolicyTile(
|
||||||
|
value: _userSettings.inactiveAccountLifeTime,
|
||||||
|
title: tr(
|
||||||
|
"Automatically delete your account if you have been inactive for"),
|
||||||
|
onChange: (val) {
|
||||||
|
_userSettings.inactiveAccountLifeTime = val;
|
||||||
|
_updateDataConservationPolicy();
|
||||||
|
},
|
||||||
|
minValue:
|
||||||
|
_serverConfig.dataConservationPolicy.minInactiveAccountLifetime,
|
||||||
|
),
|
||||||
];
|
];
|
||||||
|
|
||||||
void _updateDataConservationPolicy() async {
|
void _updateDataConservationPolicy() async {
|
||||||
|
Loading…
Reference in New Issue
Block a user