Skip to content

Fixes per_page - #4608

Merged
ildyria merged 3 commits into
masterfrom
fixes
Aug 13, 2026
Merged

Fixes per_page#4608
ildyria merged 3 commits into
masterfrom
fixes

Conversation

@ildyria

@ildyria ildyria commented Aug 13, 2026

Copy link
Copy Markdown
Member

Summary by CodeRabbit

  • Improvements

    • Album management now displays up to 100 albums per page by default.
    • Moderation photo listings now display 100 items per page by default, with configurable pagination up to 500 items.
    • Bulk album pagination options are now 100, 200, or 500 items per page.
  • Style

    • The basket menu clearly indicates processing orders with a danger state and uses a neutral state otherwise.

@ildyria
ildyria requested a review from a team as a code owner August 13, 2026 19:55
@coderabbitai

coderabbitai Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 9b37ac65-5eec-4ce9-af4e-2246d4896da5

📥 Commits

Reviewing files that changed from the base of the PR and between f8af7f3 and 5f4b005.

📒 Files selected for processing (1)
  • tests/Feature_v2/BulkAlbumEdit/IndexTest.php
🚧 Files skipped from review as they are similar to previous changes (1)
  • tests/Feature_v2/BulkAlbumEdit/IndexTest.php

📝 Walkthrough

Walkthrough

The change updates admin album and moderation pagination defaults and validation. It also changes the basket menu severity based on order processing status. The bulk album pagination test now expects 100.

Changes

Admin pagination

Layer / File(s) Summary
Moderation pagination flow
app/Http/Requests/Moderation/ListModerationRequest.php, app/Http/Controllers/Admin/ModerationController.php
The request validates optional per_page values from 1 to 500 and defaults to 100. The controller passes the validated value directly to pagination.
Bulk album pagination settings and validation
app/Http/Requests/Admin/BulkAlbumEdit/IndexBulkAlbumRequest.php, app/Http/Controllers/Admin/BulkAlbumController.php, tests/Feature_v2/BulkAlbumEdit/IndexTest.php
Bulk album requests accept 100, 200, or 500 items. The endpoint defaults to 100. The pagination test sends 100 and expects 100.

Basket menu severity

Layer / File(s) Summary
Basket menu severity
resources/js/v8/components/headers/AlbumsHeader.vue
The basket menu uses danger for processing orders and neutral otherwise.

Estimated code review effort: 2 (Simple) | ~10 minutes

Mergeability Score: 🟡 Moderate · up to 5f4b0

The pagination change currently leaves a feature test requesting 100 items while expecting 25, causing the test to fail, and the request documentation does not match the supported maximum of 500. Merge should wait until the test and documented contract are aligned.

Poem

A rabbit checks the pages with care,
One hundred records gather there.
Processing baskets flash danger bright,
Resting baskets stay neutral and light.
The updated tests confirm the fare.

🚥 Pre-merge checks | ✅ 1
✅ Passed checks (1 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 2


ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: bfcb518e-e4d3-48fa-8a6c-b63bb64c0e18

📥 Commits

Reviewing files that changed from the base of the PR and between 763d13b and bca0ca1.

📒 Files selected for processing (4)
  • app/Http/Controllers/Admin/BulkAlbumController.php
  • app/Http/Controllers/Admin/ModerationController.php
  • app/Http/Requests/Admin/BulkAlbumEdit/IndexBulkAlbumRequest.php
  • resources/js/v8/components/headers/AlbumsHeader.vue

Comment thread app/Http/Controllers/Admin/ModerationController.php Outdated
Comment thread app/Http/Requests/Admin/BulkAlbumEdit/IndexBulkAlbumRequest.php

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
tests/Feature_v2/BulkAlbumEdit/IndexTest.php (1)

174-180: 🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win

Update the expected pagination value.

Line 174 requests per_page 100. The request validator accepts 100, and the controller passes it to the paginator. Line 180 still expects 25, so this test fails against the updated contract.

Proposed fix
-		$this->assertSame(25, $data['per_page']);
+		$this->assertSame(100, $data['per_page']);

ℹ️ Review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: fe8520b1-d0ad-43ca-b348-4487d9ecbd32

📥 Commits

Reviewing files that changed from the base of the PR and between bca0ca1 and f8af7f3.

📒 Files selected for processing (3)
  • app/Http/Controllers/Admin/ModerationController.php
  • app/Http/Requests/Moderation/ListModerationRequest.php
  • tests/Feature_v2/BulkAlbumEdit/IndexTest.php

Comment thread app/Http/Requests/Moderation/ListModerationRequest.php
@codecov

codecov Bot commented Aug 13, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.02%. Comparing base (763d13b) to head (5f4b005).
⚠️ Report is 2 commits behind head on master.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@ildyria
ildyria merged commit 142c330 into master Aug 13, 2026
86 of 95 checks passed
@ildyria
ildyria deleted the fixes branch August 13, 2026 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant