blob: 649069df2c32904ebffeace7f5514effc9f80f5e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
<?php
use Digitigrade\Model\Note;
call_template('skeleton', [
'pageTitle' => "$actor->displayName - @" . $actor->getFullHandle(),
'renderTitleHeading' => false
], function () {
global $actor;
call_template('actor_profile', ['actor' => $actor]);
echo '<hr>';
$notes = Note::findAllWithAuthor($actor, 20);
if (count($notes) == 0) {
call_template('placeholder_text', ['message' => __('user.notes.placeholder')]);
} else {
foreach ($notes as $n) {
call_template('note', ['note' => $n]);
}
$countNotShown = Note::countWithAuthor($actor) - count($notes);
if ($countNotShown >= 0) {
call_template('placeholder_text', ['count' => $countNotShown]);
}
}
});
|