Open mwinokan opened 6 months ago
@kaliif Backend work needed to add the "hidden" property, it will be a flag in the existing endpoint.
@boriskovar-m2ms @matej-vavrek the frontend work is more involved:
@mwinokan to sanity check the desired position for the new modal
@mwinokan , about mapping field values. Currently, tag comes with this info:
"id": 11,
"site_observations": [
68,
74,
11,
46,
15,
49,
94,
95
],
"tag": "A201",
"tag_prefix": "11",
"upload_name": "11 - A201",
"create_date": "2024-03-12T09:15:20.928318Z",
"colour": null,
"discourse_url": null,
"help_text": null,
"additional_info": null,
"category": 2,
"target": 1,
"user": null,
"mol_group": 11
These are pretty much straightforward:
"Type" => category,
"Display name" => tag,
"Colour" => colour,
"Hidden" => (future) hidden,
"#Observations" => site_observations count
However, these are less:
"Site number" => tag_prefix / mol_group
"Site name" => ? where to reference ?
"#Compounds" => ? go through all site observations and get from them unique compounds count ?
Please change the field names so there's not such a difference between the backend and what the user sees: so rename Site Name to Upload Name, etc
@boriskovar-m2ms will wait for @matej-vavrek to be back on the project (next week) to finish up this ticket
@matej-vavrek can complete most of this except the 'hidden' attribute which needs backend work from @kaliif
@matej-vavrek has a working version on his stack (except the creation of new tags is broken, likely a stack issue)
@mwinokan to spec out what should be done with the 'hidden' property of tags in the F/E
Thanks for your work @matej-vavrek. I have spoken to some data curators and Warren and we have agreed on the following behaviour for the 'hidden' tags in the frontend. @phraenquex, please do have a look as well:
Please let me know if you see any issues with this logic. Thanks
To accommodate more tag editing and hiding functionality a new modal seemed sensible:
I am confirming with data curators if this will fix their issues.