Merge pull request #4894 from MrPetovan/task/4513-show-events-reminders-attendence
Only show event reminders of events attendyes or attendmaybe
This commit is contained in:
commit
6e9ed3f01b
1 changed files with 14 additions and 14 deletions
|
@ -644,26 +644,26 @@ class Profile
|
||||||
$classtoday = '';
|
$classtoday = '';
|
||||||
|
|
||||||
$s = dba::p(
|
$s = dba::p(
|
||||||
"SELECT *
|
"SELECT `event`.*
|
||||||
FROM `event`
|
FROM `event`
|
||||||
WHERE `event`.`uid` = ?
|
INNER JOIN `item`
|
||||||
AND `event`.`type` != 'birthday'
|
ON `item`.`uid` = `event`.`uid`
|
||||||
AND `event`.`start` < ?
|
|
||||||
AND `event`.`start` >= ?
|
|
||||||
AND NOT EXISTS (
|
|
||||||
SELECT `id`
|
|
||||||
FROM `item`
|
|
||||||
WHERE `item`.`uid` = `event`.`uid`
|
|
||||||
AND `item`.`parent-uri` = `event`.`uri`
|
AND `item`.`parent-uri` = `event`.`uri`
|
||||||
AND `item`.`verb` = ?
|
WHERE `event`.`uid` = ?
|
||||||
AND `item`.`visible`
|
AND `event`.`type` != 'birthday'
|
||||||
AND NOT `item`.`deleted`
|
AND `event`.`start` < ?
|
||||||
)
|
AND `event`.`start` >= ?
|
||||||
|
AND `item`.`author-id` = ?
|
||||||
|
AND (`item`.`verb` = ? OR `item`.`verb` = ?)
|
||||||
|
AND `item`.`visible`
|
||||||
|
AND NOT `item`.`deleted`
|
||||||
ORDER BY `event`.`start` ASC",
|
ORDER BY `event`.`start` ASC",
|
||||||
local_user(),
|
local_user(),
|
||||||
DateTimeFormat::utc('now + 7 days'),
|
DateTimeFormat::utc('now + 7 days'),
|
||||||
DateTimeFormat::utc('now - 1 days'),
|
DateTimeFormat::utc('now - 1 days'),
|
||||||
ACTIVITY_ATTENDNO
|
public_contact(),
|
||||||
|
ACTIVITY_ATTEND,
|
||||||
|
ACTIVITY_ATTENDMAYBE
|
||||||
);
|
);
|
||||||
|
|
||||||
$r = [];
|
$r = [];
|
||||||
|
|
Loading…
Reference in a new issue