mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
fix: change rcmd type
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -6,7 +6,7 @@ import 'package:PiliPlus/utils/storage.dart';
|
|||||||
class RcmdController extends CommonListController {
|
class RcmdController extends CommonListController {
|
||||||
late bool enableSaveLastData = GStorage.setting
|
late bool enableSaveLastData = GStorage.setting
|
||||||
.get(SettingBoxKey.enableSaveLastData, defaultValue: false);
|
.get(SettingBoxKey.enableSaveLastData, defaultValue: false);
|
||||||
late bool appRcmd = true;
|
final bool appRcmd = GStorage.appRcmd;
|
||||||
|
|
||||||
int? lastRefreshAt;
|
int? lastRefreshAt;
|
||||||
late bool savedRcmdTip = GStorage.savedRcmdTip;
|
late bool savedRcmdTip = GStorage.savedRcmdTip;
|
||||||
@@ -14,8 +14,6 @@ class RcmdController extends CommonListController {
|
|||||||
@override
|
@override
|
||||||
void onInit() {
|
void onInit() {
|
||||||
super.onInit();
|
super.onInit();
|
||||||
appRcmd = GStorage.appRcmd;
|
|
||||||
|
|
||||||
currentPage = 0;
|
currentPage = 0;
|
||||||
queryData();
|
queryData();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1327,19 +1327,14 @@ List<SettingsModel> get videoSettings => [
|
|||||||
|
|
||||||
List<SettingsModel> get recommendSettings => [
|
List<SettingsModel> get recommendSettings => [
|
||||||
SettingsModel(
|
SettingsModel(
|
||||||
settingsType: SettingsType.sw1tch,
|
settingsType: SettingsType.sw1tch,
|
||||||
title: '首页使用app端推荐',
|
title: '首页使用app端推荐',
|
||||||
subtitle: '若web端推荐不太符合预期,可尝试切换至app端推荐',
|
subtitle: '若web端推荐不太符合预期,可尝试切换至app端推荐',
|
||||||
leading: const Icon(Icons.model_training_outlined),
|
leading: const Icon(Icons.model_training_outlined),
|
||||||
setKey: SettingBoxKey.appRcmd,
|
setKey: SettingBoxKey.appRcmd,
|
||||||
defaultVal: true,
|
defaultVal: true,
|
||||||
onChanged: (value) {
|
needReboot: true,
|
||||||
try {
|
),
|
||||||
Get.find<RcmdController>().appRcmd = value;
|
|
||||||
} catch (e) {
|
|
||||||
debugPrint('$e');
|
|
||||||
}
|
|
||||||
}),
|
|
||||||
SettingsModel(
|
SettingsModel(
|
||||||
settingsType: SettingsType.sw1tch,
|
settingsType: SettingsType.sw1tch,
|
||||||
title: '推荐动态',
|
title: '推荐动态',
|
||||||
|
|||||||
Reference in New Issue
Block a user