Skip to content
This repository has been archived by the owner on May 25, 2020. It is now read-only.

speed up recycle bin and sort by timestamp #763

Merged
merged 5 commits into from
Oct 25, 2018
Merged

Conversation

Knorrke
Copy link
Member

@Knorrke Knorrke commented Oct 9, 2018

Use paginator, so fewer elements get normalized (speeding up page load time) - closes #756

Also sorting by timestamp for more convenient access to currently deleted elements.

@Knorrke Knorrke requested review from aeneasr and inyono October 9, 2018 14:54
@Knorrke
Copy link
Member Author

Knorrke commented Oct 11, 2018

also fixes #727 and fixes #766

Copy link
Member

@inyono inyono left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, looks mostly good to me :)

@@ -1,20 +1,24 @@
<?php echo $this->pageHeader('Uuid recycle bin')->render(); ?>
<?php echo $this->pageHeader('Uuid recycle bin')->setSubtitle($this->translate('Page') . $this->elements->getCurrentPageNumber())->render(); ?>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing space between Page and current page number :)

* <code>
* $uuids = $um->findByTrashed(true);
* foreach($uuids as $uuid)
* $elements = $um->findTrashed();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Missing $page argument

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* $elements = $um->findTrashed();
* $elements = $um->findTrashed($page);

@@ -1,20 +1,24 @@
<?php echo $this->pageHeader('Uuid recycle bin')->render(); ?>
<?php echo $this->pageHeader('Uuid recycle bin')->setSubtitle($this->translate('Page') . $this->elements->getCurrentPageNumber())->render(); ?>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<?php echo $this->pageHeader('Uuid recycle bin')->setSubtitle($this->translate('Page') . $this->elements->getCurrentPageNumber())->render(); ?>
<?php echo $this->pageHeader('Uuid recycle bin')->setSubtitle($this->translate('Page') . ' ' . $this->elements->getCurrentPageNumber())->render(); ?>

Copy link
Member

@inyono inyono left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@inyono inyono merged commit 40033af into serlo:master Oct 25, 2018
@Knorrke Knorrke deleted the trash branch October 25, 2018 08:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

recycle bin is very slow
2 participants