mirror of
https://github.com/wallabag/wallabag.git
synced 2025-07-22 17:18:37 +00:00
Set a starred_at field when an entry is starred.
This date is used to sort starred entries. Can not use Entry::timestamps method otherwise starred_at will be updated each time entry is updated. Add an updateStar method into Entry class A migration script has been added in order to set starred_at field.
This commit is contained in:
parent
2490f61dca
commit
a991c46eed
6 changed files with 124 additions and 7 deletions
|
@ -333,6 +333,7 @@ class EntryController extends Controller
|
|||
$this->checkUserAction($entry);
|
||||
|
||||
$entry->toggleStar();
|
||||
$entry->updateStar($entry->isStarred());
|
||||
$this->getDoctrine()->getManager()->flush();
|
||||
|
||||
$message = 'flashes.entry.notice.entry_unstarred';
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue