Skip to content

Add approved boolean field to Source model#15

Draft
Copilot wants to merge 3 commits into
masterfrom
copilot/add-approved-status-to-sources
Draft

Add approved boolean field to Source model#15
Copilot wants to merge 3 commits into
masterfrom
copilot/add-approved-status-to-sources

Conversation

Copilot AI commented Dec 31, 2025

Copy link
Copy Markdown

Sources (review platforms like Yelp, TripAdvisor, etc.) are automatically matched and created via find_or_create_by_name!. This adds an approved boolean field to track approval status.

Database Changes

  • Migration adds approved boolean column (default: false)
  • Seeds updated to set approved: true for automatically matched sources

Model & Interface

  • Added approved to attr_accessible in Source model
  • ActiveAdmin sources index now displays approval status
  • Test factory updated to include approved field

Example

# New sources default to unapproved
Source.create!(name: 'new_platform', ...) # approved: false

# Seeded sources are pre-approved
Source.find_or_create_by_name!(name: 'yelp', ..., approved: true)

After migration, existing sources will have approved: false and need manual review.

Original prompt

This section details on the original issue you should resolve

<issue_title>Every new automatically matched source should now have an 'approved' boolean status</issue_title>
<issue_description></issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI and others added 2 commits December 31, 2025 14:47
Co-authored-by: richardjortega <1143885+richardjortega@users.noreply.github.com>
Co-authored-by: richardjortega <1143885+richardjortega@users.noreply.github.com>
Copilot AI changed the title [WIP] Add approved boolean status to automatically matched sources Add approved boolean field to Source model Dec 31, 2025
Copilot AI requested a review from richardjortega December 31, 2025 14:50
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.

Every new automatically matched source should now have an 'approved' boolean status

2 participants