Skip to content

Conversation

@google-labs-jules
Copy link
Contributor

@google-labs-jules google-labs-jules bot commented Sep 7, 2025

This change extends the Crop data model with new attributes and migrates existing data from the openfarm_data JSONB column.

The following changes are included:

  • A database migration to add row_spacing, spread, height, sowing_method, sun_requirements, and growing_degree_days to the crops table.
  • A data migration to populate these new columns from the openfarm_data column.
  • UI changes to allow editing these new attributes in the crop form.
  • Updates to the crop show page to display the new attributes.
  • Removal of the old methods for accessing these attributes from the OpenFarmData concern.
  • A new test to verify that the new attributes are saved correctly.
image

This commit extends the Crop model to have attributes for row_spacing,
spread, height, sowing_method, sun_requirements, and
growing_degree_days.

It also creates a migration to extract these values from the
openfarm_data column on the crops table.

Finally, it adds UI to edit these attributes for crop_wranglers or
users suggesting a new crop, and displays the new attributes on the
crop show page.
@google-labs-jules
Copy link
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll acknowledge your comments with a 👀 emoji and then get to work. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

I will automatically address your feedback. For any comments you don't want me to act on, just include (aside).



For security, I will only act on instructions from the user who triggered this task for this pull request.

google-labs-jules bot and others added 5 commits September 7, 2025 03:46
This commit extends the Crop model to have attributes for row_spacing,
spread, height, sowing_method, sun_requirements, and
growing_degree_days.

It also creates a migration to extract these values from the
openfarm_data column on the crops table.

Finally, it adds UI to edit these attributes for crop_wranglers or
users suggesting a new crop, and displays the new attributes on the
crop show page.
@CloCkWeRX CloCkWeRX marked this pull request as ready for review September 7, 2025 10:27
@CloCkWeRX CloCkWeRX merged commit bc11a1b into dev Sep 7, 2025
16 checks passed
@CloCkWeRX CloCkWeRX deleted the extend-crop-model branch September 7, 2025 10:33
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.

2 participants