mirror of
https://github.com/humhub/humhub.git
synced 2025-01-17 14:18:27 +01:00
Merge pull request #4582 from humhub/fix/4581
Fix #4581: Users see content of archived spaces on dashboard
This commit is contained in:
commit
156f906df7
@ -17,7 +17,9 @@ HumHub Changelog
|
||||
- Fix #4554: Code blocks in comments uses same background color
|
||||
- Fix #4574: Different style between clickable and non clickable space/user counter
|
||||
- Fix #4575: Increased text size of "Read more" link on short-text post
|
||||
- Fix #4575: Increased text size of "Read more" link on short-text post
|
||||
- Fix #4559: Don’t check platform php extensions by composer v2
|
||||
- Fix #4581: Users see content of archived spaces on dashboard
|
||||
|
||||
|
||||
1.7.0-beta.1 (October 16, 2020)
|
||||
|
@ -66,7 +66,9 @@ class DashboardStreamAction extends ActivityStreamAction
|
||||
->select(["contentcontainer.id"])
|
||||
->from('space')
|
||||
->leftJoin('contentcontainer', 'space.id=contentcontainer.pk AND contentcontainer.class=:spaceClass')
|
||||
->where('space.visibility=' . Space::VISIBILITY_ALL);
|
||||
->where('space.visibility=' . Space::VISIBILITY_ALL)
|
||||
->andWhere('space.status='. Space::STATUS_ENABLED);
|
||||
|
||||
$union = Yii::$app->db->getQueryBuilder()->build($publicSpacesSql)[0];
|
||||
|
||||
$publicProfilesSql = (new Query())
|
||||
@ -101,7 +103,7 @@ class DashboardStreamAction extends ActivityStreamAction
|
||||
$spaceMemberships = (new Query())
|
||||
->select("contentcontainer.id")
|
||||
->from('space_membership')
|
||||
->leftJoin('space sm', 'sm.id=space_membership.space_id')
|
||||
->leftJoin('space sm', 'sm.id=space_membership.space_id AND sm.status='.Space::STATUS_ENABLED)
|
||||
->leftJoin('contentcontainer', 'contentcontainer.pk=sm.id AND contentcontainer.class = :spaceClass')
|
||||
->where('space_membership.user_id=' . $this->user->id . ' AND space_membership.show_at_dashboard = 1');
|
||||
$union .= " UNION " . Yii::$app->db->getQueryBuilder()->build($spaceMemberships)[0];
|
||||
|
Loading…
x
Reference in New Issue
Block a user