243 Commits

Author SHA1 Message Date
google-labs-jules[bot]
ba6ec689c5 Merge pull request #4150 from Growstuff/feature/failed-plantings
Add failed status to plantings
2025-08-27 23:42:53 +09:30
google-labs-jules[bot]
a98990ccd2 Add transplant feature for plantings (#4133)
* Add ability to transplant a planting

* Fix view tests

* Transplantable gardens

* Add spec

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Daniel O'Connor <daniel.oconnor@gmail.com>
2025-08-24 22:31:14 +09:30
google-labs-jules[bot]
ac1463e2cf Add international alternate names for crops (#4132)
* I will add the international alternate names for the crops.

* Mark required

* Update factory

* Add placeholder

* Fix seeds

* Add language, though hardcoded to EN in most places

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Daniel O'Connor <daniel.oconnor@gmail.com>
2025-08-24 21:44:41 +09:30
google-labs-jules[bot]
8564ec7a7c Add comments to photos (#4130)
* Add comments to photos

Extend the photo show page to support comments by logged in users.

- Make the Comment model polymorphic.
- Update the Photo and Post models to have comments.
- Update the comments controller to handle the polymorphic association.
- Update the photo show page to display comments and a comment form.
- Create a reusable comments partial.

* Add migration

* Fix tests

* Fix tests

* Slightly fix tests

* Fix variables

* Add field

* Refactor slightly

* Refactor slightly

* Refactor slightly

* Refactor

* Photos respond to this as well

* Refactor to polymorphic_url

* Rename

* Wrong relationship

* Refactor and fix tests

* Fix relationships

* Fix rendering

* Fix tests

* Fix model tests

* Fix test

* Fix test

* Fix test

* Fix test

* Fix controller spec

* Fix view tests

---------

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
Co-authored-by: Daniel O'Connor <daniel.oconnor@gmail.com>
2025-08-24 21:10:16 +09:30
google-labs-jules[bot]
76a6c1d849 Merge pull request #4131 from Growstuff/feature/add-social-media-links
feat: Add social media links to user profiles
2025-08-24 16:21:05 +09:30
Daniel O'Connor
1c97ba1495 Garden collaboration (small part of community gardens) (#3862)
* Add collaboration model

* Permissions and garden show

* List by owner, or where I am a collaborator

* Add index

* Add permissions

* Typo

* Typo

* Add route

* Update schema

* Update schema

* Add CRUD

* Add CRUD

* Add CRUD

* Factory

* Add validations

* Rubocop

* Rubocop

* Rubocop

* Unique index

* Fix

* Make CI more fine grained for faster feedback

* Swap order

* Fix path, fail-fast

* Fix spec

* Remove 'significant drop in coverage' as not everything runs in one giant run

* Fix tests?
2024-09-29 18:28:52 +09:30
Daniel O'Connor
c28b2c0c38 Likes: Add capability to Activities, Plantings, Harvests (#3805)
* Ability to like activities

* Ability to like activities

* Add likeable everywhere

* Refactor

* Remove extra newline

* Typo

* Use classes, not IDs

* Explicitly wait for ajax

* Fix tests

* Move likes under owner

* Add separation

* Move harvest likes near actions

* Rearrange harvests

* Render likes under owner

* Make harvest consistent with other views

* Move planting detail into header

* Move detail into header

* Move detail into header

* Revert

* Fix header

* Move likes into jumotrons

* Fix name

* Change all actions to be after likes and a span

* Cleanup

* Cleanup

* Cleanup

* Cleanup

* i18n and accessibility

* Fix name

* Temporarily make ack into a div

* Update app/views/photos/_actions.html.haml
2024-07-24 17:07:56 +09:30
Daniel O'Connor
5be0153c74 Activities (#3646)
* Implement activities

* Add activities to timeline

* Add factory

* Add coverage

* Fix misc issues

* Activities display

* Add activities to garden and plantings

* Add activities to garden and plantings

* Add planting

* Add to planting, harvest show

* More CRUD

* More CRUD

* index

* index

* Extract card view

* Permissions

* Add edit

* Remove workaround fro vs code

* Fix title

* CSV

* CSV

* Add RSS, ical

* Extend ical slightly

* Cleanup

* Rubocop

* Remove doubled form

* Change icon

* Fix short description

* Add menus

* Put homepage widget in

* Add activity icon - MIT licenced - https://www.svgrepo.com/svg/336823/plan

* Naming

* Missing files

* Revert VS Code lag induced change

* Update app/views/home/_harvests.html.haml

* Update activities_controller.rb

* Update activities_controller.rb

* Update app/controllers/activities_controller.rb

* Update index.html.haml

* Apply suggestions from code review

* Apply suggestions from code review

* Typo

* Translation

* Apply suggestions from code review

* Update app/views/plantings/index.ics.erb

* Update app/models/activity.rb

* Update plantings_spec.rb

* Update plantings_spec.rb

* We are now rendering an extra event, so check the next one for the old behaviour
2024-03-10 11:36:24 +10:30
Daniel O'Connor
196b8078e6 Posts - Ensure responsive (#3584)
* Fix model validations and responsiveness

* Fix model validations and responsiveness

* Update app/models/post.rb
2024-01-21 16:05:14 +10:30
Daniel O'Connor
1f0cfa9b6c Add GBIF to our scientific names, so that our crops can associate creative commons photos (#3559)
* Add GBIF cient

* Add lookup

* Add autocomplete for GBIF lookup

* Add extra detail to scientific names

* Autocomplete

* Add routes

* Rmeove mapping

* Add autocomplete

* Update GBIF data on save

* db/schema

* Style

* Extract service

* Add concern

* Add concern

* Save photos

* Initial coverage

* Coverage

* Add coverage

* Shut up, codeclimate

* Shut up, codeclimate

* Unused

* Shut up, codeclimate

* Apply suggestions from code review

* Remove localhost

* Fix rubocop

* Fix rubocop

* Add UI links

* Add rake

* Indent

* Update Gemfile.lock

* Update lib/tasks/gbif.rake

* Update app/views/crops/_scientific_names.html.haml

* Rubocop

* Expand edit photo form

* Fix error

* Add model validations

* Skip photos without backlinks

* Fix tests

* Add photo words

* Allow blank

* Rubocop and handle invalid legacy data

* Apply suggestions from code review

* Update lib/tasks/gbif.rake
2024-01-21 13:22:25 +10:30
Daniel O'Connor
18161cf6d4 Update schema 2023-04-13 16:50:23 +01:00
Brenda Wallace
ec778394ab Upgrade to activemedian 0.2.0 2020-08-26 12:36:58 +12:00
Brenda
16895d2ddb Added missing unique constraint to garden_types 2020-08-26 12:36:58 +12:00
Brenda Wallace
59efe92648 Upgrade to rails 6 2020-08-26 12:36:58 +12:00
Brenda Wallace
38c7bdd7c2 likes count and sorted es search data config 2019-12-30 09:51:10 +13:00
Brenda Wallace
9e6d659093 Merge branch 'dev' into cache/harvests 2019-12-28 00:29:34 +13:00
Brenda
460ff43a4e Adding more counter caches 2019-12-26 23:42:11 +00:00
Brenda Wallace
bef7f5b26d Merge branch 'counter-caches' into cache/harvests
Conflicts:
	db/schema.rb
2019-12-26 18:14:33 +13:00
Brenda
a7e915621e Index into elastic during db migration 2019-12-26 18:12:15 +13:00
Brenda
17fa995a17 Adding more counter caches 2019-12-26 16:05:30 +13:00
Brenda Wallace
eab10eaf7c many to many counter caches weren't working
and causing errors.
2019-12-26 12:54:36 +13:00
Brenda Wallace
f42328f85e harvests#index using model-like varaibles 2019-12-25 14:52:15 +13:00
Brenda Wallace
b0d55ad064 Counter cache for posts 2019-12-10 20:30:57 +13:00
Brenda Wallace
5afe3e1c1e Pulling plantings from elastic search too 2019-12-10 13:36:23 +13:00
Brenda Wallace
e4b1a2f221 Add counter caches 2019-12-10 09:27:44 +13:00
Brenda Wallace
a92710eab7 Update schema 2019-11-19 21:08:47 +13:00
Brenda Wallace
0958a134ed Finish the CMS upgrade and fix #2098 2019-11-19 15:14:08 +13:00
Brenda Wallace
b214f7ad8d linking existing plantings to their parent seeds 2019-11-01 02:23:14 +00:00
Brenda Wallace
7b5698f977 👩‍🌾 Import openfarm data (#2177)
* Pull in openfarm icons, photos, info
* Truncating member location
* tidying up harvest display, and reducing duplication in css styles
* Tiny crop chip
* only show crop charts if there is data to show
* Make the styles more Growstuff
* Fixed links to openfarm
* Updating specs to cope with new photo sources
fix broken garden timeline on some pages
* Update homepage blurb
* Import crop companions
* More fluid page
* use thumbnail unless the source is flickr
* Messing with homepage
* Added crop growing_degree_days
* expect full size url on photos helper spec
* formatted dates from seeds#show
* tidy up places#show
* Move progress bar
* Quicker buttons for approve/reject crops
* Remove kaminari gem
* use crop cards on hierarchy page
* more crops on crops#index
* Wrap photo creation in transaction
* Wrap crop companions in a transaction
2019-09-28 17:23:25 +12:00
Brenda Wallace
6a4158ae04 👭 Crop companions (#2176)
* Crop companions
* Use a nil license to mean no licence
* dependent for crop->crop_companions relationship
* Fix crop detail spec
2019-09-28 10:38:01 +12:00
Brenda Wallace
7acdc6c96f Merge remote-tracking branch 'upstream/dev' into post-comments
Conflicts:
	db/schema.rb
2019-09-26 21:14:12 +12:00
Brenda Wallace
90035e79b8 Crop to post relationship made more rails standard 2019-09-22 10:07:50 +12:00
Brenda Wallace
87e1a7571b Photo source in the schema 2019-09-21 09:45:34 +12:00
Brenda Wallace
105c2639e4 Adding timestamps to tables 2019-08-11 14:23:27 +12:00
Brenda Wallace
67ce5265b4 Migrate from paranoia to discard
closes #1995
2019-07-21 16:59:06 +12:00
Brenda Wallace
629352ef4f Merge remote-tracking branch 'upstream/dev' into mailbox
Conflicts:
	Gemfile.lock
	app/assets/stylesheets/application.scss
	db/schema.rb
2019-07-20 13:20:10 +12:00
Brenda Wallace
548bbf5e57 Merge remote-tracking branch 'upstream/dev' into renamed-photographings-associations
Conflicts:
	db/schema.rb
2019-07-16 12:12:16 +12:00
Brenda Wallace
acf58fc5e2 Choose crop photos by most liked 2019-07-15 11:58:46 +00:00
Brenda Wallace
e0e10c29dc Renaming photographings to photo associations
now it matches the name of its controller, and it is clearer to understand
2019-07-13 16:13:37 +12:00
Brenda Wallace
c50556221c TRying to get mailboxxer working 2019-07-11 22:28:51 +12:00
Brenda Wallace
e7b0b6f18e Remove table display on plantings#show, replace with boxes 2019-03-27 21:04:56 +13:00
Brenda Wallace
5395aefa66 Rename containers to garden types 2019-03-26 20:56:11 +13:00
Brenda Wallace
02e0dd091a Merge remote-tracking branch 'upstream/dev' into bb-track-types-of-gardens 2019-03-26 19:35:16 +13:00
Brenda Wallace
db5bdab055 Set planting.finished as a boolean 2019-03-20 09:43:01 +13:00
Brenda Wallace
0759ca9039 Schema update for crops added to photogaphings table 2019-02-04 20:53:04 +13:00
Brenda Wallace
f7d989bb61 Squashed migrations and set as Rails4.2 2019-01-18 14:31:35 +13:00
Brandon Baker
a00ed5a176 Merge branch 'dev' into bb-track-types-of-gardens 2019-01-08 12:03:39 -05:00
Brenda Wallace
de8eba738e Fix modified schema deploy error 2019-01-05 19:44:40 +13:00
Brandon Baker
178c6cd944 fixes bug in setting slug on container 2018-12-06 15:51:00 -07:00
Brandon Baker
bb97082868 adds friendly_id to containers 2018-12-01 19:46:49 -07:00