mstenta / farm_crop_plan

Crop plan type and related features for farmOS. (ALPHA 3.x IN DEVELOPMENT)
https://drupal.org/project/farm_crop_plan
GNU General Public License v2.0
5 stars 1 forks source link

Multiple transplantings #20

Closed mstenta closed 4 months ago

mstenta commented 3 years ago

Feedback from Cora at Wolfe's Neck:

Often, for a single seeding, we will plant them in two different locations. I am not quite sure the best way to do this with different logs associated with them.

  • Maybe adding an option to check to add another transplanting
  • Perhaps the name of the planting asset could then default to something like “2020 location 1, location 2 cucumber” and the name of the transplanting and harvest log would be the single location that it is currently in. Not sure if it works to diverge multiple transplantings and harvests like that though.
mstenta commented 3 years ago

Another case where this is useful is (for example) tomatoes that are started in plug trays and then "up-potted" to 4 inch pots, before finally being transplanted into their final location in the field or greenhouse. In that case, you have 1 seeding (into the plug trays), and 2 transplantings.

Currently, the planting form only allows creating a single transplanting. It is possible to add additional transplanting logs OUTSIDE of the crop plan UI but they will not show in the crop plan (related: https://github.com/mstenta/farm_crop_plan/issues/6). Also notably: when you "add an existing planting" to a plan, if that planting already has multiple transplantings, only the first one will be linked.

mstenta commented 3 years ago

Also notably: when you "add an existing planting" to a plan, if that planting already has multiple transplantings, only the first one will be linked.

Correction: only the LAST transplanting is linked.

https://github.com/mstenta/farm_crop_plan/blob/a4114bd80a4bfd3fab784726726550c1e8a00eee/farm_crop_plan.module#L1786

The assumption being that the LAST transplanting is the one that puts the planting into it's final location in the field, and that's what we want to represent in the crop plan visualization.

mstenta commented 4 months ago

The new 3.x version no longer creates a direct link between the plan and the logs. Instead, it creates a link to the plant asset, and loads in all of the asset's logs to visualize them as dots on the timeline. So if a plant asset has multiple transplanting logs they will all be displayed.

This module no longer provides it's own form for creating plant assets, and instead relies on farmOS core for those features (for example: the core Planting quick form). So any additional UI/UX features during the creation of assets should happen there I think. That said, I'd like to see some generic shortcuts for adding logs to plant assets from the plan UI in this module too.

I think we can close this issue and pursue those ideas separately...