1、聚合搜索关注

This commit is contained in:
cuiyouliang 2025-09-03 11:47:50 +08:00
parent 6fce441275
commit 7c5d51157a
2 changed files with 4 additions and 4 deletions

View File

@ -273,12 +273,12 @@ class _SearchResultPageState extends State<SearchResultPage> with SingleTickerPr
final doIFollowVloger = user['doIFollowVloger'];
print('是否关注此用户------------->$doIFollowVloger');
print('此用户UserId------------->$vlogerId');
if (doIFollowVloger == false) {
if (doIFollowVloger == false || doIFollowVloger == null) {
final res = await ImService.instance.followUser(userIDList: [vlogerId]);
print('关注结果------------->${res.success}');
if (res.success) {
setState(() {
_userResults[index]['doIFollowVloger'] = !_userResults[index]['doIFollowVloger'];
_userResults[index]['doIFollowVloger'] = true;
});
}
} else {
@ -286,7 +286,7 @@ class _SearchResultPageState extends State<SearchResultPage> with SingleTickerPr
print('取消关注结果------------->${res.success}');
if (res.success) {
setState(() {
_userResults[index]['doIFollowVloger'] = !_userResults[index]['doIFollowVloger'];
_userResults[index]['doIFollowVloger'] = false;
});
}
}

View File

@ -679,7 +679,7 @@ class _RecommendModuleState extends State<RecommendModule> {
if (data == null || (data is List && data.isEmpty)) {
return;
}
print('推荐视频列表------------------>${data['records']}');
if (data['records'] is List) {
List videos = data['records'];
for (var item in videos) {