Genesys Website issueshttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues2022-11-19T12:09:28+01:00https://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/944Ingest: Remapping source values2022-11-19T12:09:28+01:00Matija ObrezaIngest: Remapping source valuesThe data may have typos or might be coded differently. In this ticket we implement a mechanism for the user to "map" the values as found in the source file to their "better" counterparts. The UI needs to be tabular:
|Original value|Repl...The data may have typos or might be coded differently. In this ticket we implement a mechanism for the user to "map" the values as found in the source file to their "better" counterparts. The UI needs to be tabular:
|Original value|Replace with|
|--|--|
|`1`|`1`|
|`0`||
|`a`|`1`|
|`2`|`2`|
|`-`||
UI needs to display the terms of the selected `Descriptor` next to this form so the user can refer to the available terms.
Needs #948Matija ObrezaMatija Obrezahttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/943Show ES cluster status in Admin2022-11-17T15:03:47+01:00Matija ObrezaShow ES cluster status in AdminUpdate ES page in Admin to include ES cluster status (`green`, `yellow`, `red` from */_cluster/health*). Needs new API endpoint.
Also please add a "Reload" icon or button to fetch the latest data for that page from the API.Update ES page in Admin to include ES cluster status (`green`, `yellow`, `red` from */_cluster/health*). Needs new API endpoint.
Also please add a "Reload" icon or button to fetch the latest data for that page from the API.2022.6Vladyslava MokliakVladyslava Mokliakhttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/942UI: Sandbox and Production dashboard for users with no admin permissions2022-11-10T16:37:14+01:00Christelle RabilUI: Sandbox and Production dashboard for users with no admin permissionsA few users flagged that their dashboard in Sandbox and Production is showing a spinning wheel with "Loading data" text in their dashboard and both do not have any permissions. Instead of this, there shouldn't be anything showing:
![Mi...A few users flagged that their dashboard in Sandbox and Production is showing a spinning wheel with "Loading data" text in their dashboard and both do not have any permissions. Instead of this, there shouldn't be anything showing:
![MicrosoftTeams-image__6_](/uploads/99386ee9e6dfdbf21d3887b24a5bec37/MicrosoftTeams-image__6_.png)Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/941SSR Helmet2022-11-11T17:03:04+01:00Matija ObrezaSSR HelmetIt seems that we lost Helmet data in SSR-rendered HTML and the metatags are not included.
Please see if Helmet API changed and why the `<meta` tags are missing.It seems that we lost Helmet data in SSR-rendered HTML and the metatags are not included.
Please see if Helmet API changed and why the `<meta` tags are missing.2022.6Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/940SSR resource loading2022-11-17T14:51:45+01:00Matija ObrezaSSR resource loadingLooking at the HTML generated by SSR, we have:
```html
<head>
<link rel="shortcut icon" href="favicon.ico"/>
<link href="vendors-genesys.328a74870335bd915333.css" rel="stylesheet"/>
<link href="genesys.328a74870335bd915333.css" rel="...Looking at the HTML generated by SSR, we have:
```html
<head>
<link rel="shortcut icon" href="favicon.ico"/>
<link href="vendors-genesys.328a74870335bd915333.css" rel="stylesheet"/>
<link href="genesys.328a74870335bd915333.css" rel="stylesheet"/></head>
<body>
...
<!-- before end of body -->
<script src="121.328a74870335bd915333.js"></script>
<script src="vendors-genesys.328a74870335bd915333.js" async="async"></script>
<script src="genesys.328a74870335bd915333.js" async="async"></script></body>
</body>
```
Ideally, the scripts, CSS and maybe even fonts would be loaded with `<link rel="preload" ...`. See https://www.smashingmagazine.com/2016/02/preload-what-is-it-good-for/
In this ticket we improve resource loading in SSR (with some webpack plugin from https://github.com/jantimon/html-webpack-plugin. Maybe https://github.com/vuejs/preload-webpack-plugin ? ).2022.6Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/939Sync action button2022-11-14T09:23:09+01:00Matija ObrezaSync action buttonWe now have `<Button ...` for API actions to load **similar** accessions and to load **audit logs**.
Use our implementation of `<ActionButton sync ...` instead.
Example https://staging.genesys-pgr.org/a/4b6e18c7-3e18-4fd4-a3bd-1ee3c1b0...We now have `<Button ...` for API actions to load **similar** accessions and to load **audit logs**.
Use our implementation of `<ActionButton sync ...` instead.
Example https://staging.genesys-pgr.org/a/4b6e18c7-3e18-4fd4-a3bd-1ee3c1b06f3a2022.6Oleksii PlotnykovOleksii Plotnykovhttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/938AccessionFilters with taxonomy.lastModifiedDate2022-11-07T08:19:18+01:00Matija ObrezaAccessionFilters with taxonomy.lastModifiedDateAdd a new `DateFilter` to the **Date Search** section of `AccessionFilters` for `taxonomy.lastModifiedDate`.
Example query: https://sandbox.genesys-pgr.org/a/v2xKkY7d01OAdd a new `DateFilter` to the **Date Search** section of `AccessionFilters` for `taxonomy.lastModifiedDate`.
Example query: https://sandbox.genesys-pgr.org/a/v2xKkY7d01O2022.6Oleksii PlotnykovOleksii Plotnykovhttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/937Dashboard taxonomy filters2022-11-03T17:13:52+01:00Matija ObrezaDashboard taxonomy filtershttps://sandbox.genesys-pgr.org/dashboard/t does not remember the filter code and makes management of `Taxonomy2` records a bit of a pain.
Please add `filterCode` support.https://sandbox.genesys-pgr.org/dashboard/t does not remember the filter code and makes management of `Taxonomy2` records a bit of a pain.
Please add `filterCode` support.2022.6Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/936Multiple entrypoints2022-11-07T08:16:46+01:00Matija ObrezaMultiple entrypointsWe now use a single app entrypoint `client.tsx` that handles `/admin`, `/dashboard` and `/` routes. This is not ideal for code splitting.
In this ticket we introduce separate entrypoints, one for each part of the Genesys UI.We now use a single app entrypoint `client.tsx` that handles `/admin`, `/dashboard` and `/` routes. This is not ideal for code splitting.
In this ticket we introduce separate entrypoints, one for each part of the Genesys UI.Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/934Admin users and OAuth clients in a table2022-10-17T17:44:37+02:00Matija ObrezaAdmin users and OAuth clients in a tableUpdate display of users and oauth clients from `Card` to `Table`.Update display of users and oauth clients from `Card` to `Table`.2022.5Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/933User profile: Delete my account2022-11-16T09:32:48+01:00Matija ObrezaUser profile: Delete my accountIn this ticket we add a tool for any user to "Delete my account" from Genesys.
## Dashboard
Add a button "Delete my account" that opens a dialog with:
- description: "After you submit this form we will send you an email with the <i>Ac...In this ticket we add a tool for any user to "Delete my account" from Genesys.
## Dashboard
Add a button "Delete my account" that opens a dialog with:
- description: "After you submit this form we will send you an email with the <i>Account removal link</i>. Clicking that link will bring you back to this website and you will have the final opportunity to change your mind."
- a challenge: the message "To delete your account please type {randomWord} in the text box:" + `<input type="text"`
- Buttons **Cancel** and **Send the link**.
## Account removal
That *Account removal link* opens a form (similar to *Forgot password*) with a form for:
- the `key` that was sent in the email
- captcha
- Button **Remove account**
**Remove account** then makes the final API call with the `uuid` + `key`. The endpoint checks if these match and will call `archiveUserByToken()`. It will also clear the current security context, reset the session, clear cookies, etc.
When the API call returns `200 OK`, the UI will also log the user out and redirect to the entry page.
## API
The API needs to generate a token + key (like we do for forgot password) and use a email templates (from CMS `Article`).2022.6Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/932Admin - Users - sending emails2022-10-18T09:20:24+02:00Matija ObrezaAdmin - Users - sending emailsThe Administrator is able to select (filtered) `Users` in the table and in the FAB click the "Send email".
## "Send email" dialog
The dialog title says `Send email to {users.length} users`. The main part of the template is a `textarea`...The Administrator is able to select (filtered) `Users` in the table and in the FAB click the "Send email".
## "Send email" dialog
The dialog title says `Send email to {users.length} users`. The main part of the template is a `textarea` where I can modify the email message template.
There are three buttons **Cancel**, **Send to me only** and **Send {users.length} emails**.
**Send to me only** puts my current `user.uuid` as the only element of the new API call implemented in genesys-pgr/genesys-server#646.
## Default template
```
<p>Hello ${user.fullName},</p>
<p>Greetings from Genesys! You are receiving this message because you are a registered user at ${frontendUrl}.</p>
<p></p>
<p>
Best regards,<br />
Genesys team
</p>
```
## Use case
```
<p>Hello ${user.fullName},</p>
<p>Greetings from Genesys!
You are receiving this message because you are a registered user at ${frontendUrl}.</p>
<p>You have not used this account since ${user.lastLogin|'ever'}.
We would like to confirm that you are not using this user
account anymore and that it can be removed from our system.
We will remove this user account on 1 December 2022.</p>
<p>If you wish to continue using this account, then please log in to ${frontendUrl} before December.
You are using a <b>${user.accountType}</b> login with <b>${user.email}</b> as username.</p>
<p>It is likely that your account already expired.
In that case please use the password reset function available on
the login form.</p>
<p>Note that even if this user account gets removed,
you will still be able to create a new account on ${frontendUrl}
using the same email address.</p>
<p></p>
<p>
Best regards,<br />
Genesys team
</p>
```2022.5Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/931UI: Add a checkbox in the registration form2022-09-30T22:25:05+02:00Christelle RabilUI: Add a checkbox in the registration formIn the registration page of an account in Genesys: https://www.genesys-pgr.org/registration
Please add a checkbox that is required to enable the `Register` button. The text next to it is:
> - [ ] By submitting the request for materia...In the registration page of an account in Genesys: https://www.genesys-pgr.org/registration
Please add a checkbox that is required to enable the `Register` button. The text next to it is:
> - [ ] By submitting the request for material to Genesys, you consent to the Crop Trust processing your personal data in accordance with the [Crop Trust Data Protection Policy](https://www.croptrust.org/fileadmin/uploads/croptrust/Documents/Policy_Documents/Crop-Trust-Data-Protection-Policy.pdf). You can contact [dataprotection@croptrust.org](mailto:dataprotection@croptrust.org) for any data protection related questions or inquiries.Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/930Admin archiving user accounts2022-10-25T07:53:49+02:00Christelle RabilAdmin archiving user accountsAfter discussing with Zeynep GDPR compliance and the aspect of deleting unnecessary data, we discussed automating the archiving of accounts that have been inactive for some time (two years +). We first can send an email to users saying "...After discussing with Zeynep GDPR compliance and the aspect of deleting unnecessary data, we discussed automating the archiving of accounts that have been inactive for some time (two years +). We first can send an email to users saying "if you do not login in to Genesys within the next 30 days, your account will be deleted + link to login". To be based on https://gitlab.croptrust.org/genesys-pgr/genesys-support/-/issues/151
We'll do this in steps:
- [x] genesys-pgr/genesys-ui#934: Change display of users from <Card to <Table (so we get select function and better sorting)
- [x] genesys-server#646: Add endpoint to send emails to selected users, with a configurable message template
- [x] #932: Add FAB with "Send email" that prompts for the template and then makes the API call to send messages
This will allow us to send official-(sandbox)-looking emails to users and then after a month we can go in and archive the old accounts:
- [ ] #930 (this issue): Add to FAB a "Archive users" that calls API and archives the selected users
## Archive users
Add to FAB a "Archive users" that calls API and archives the users selected in the table. I figure we have a multi-op API call for that already.2022.5Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/929Cookies consent dialog2022-10-18T14:06:10+02:00Christelle RabilCookies consent dialogWe need to include a cookie consent dialog that says we need essential cookies and an “accept” box that they need to accept in order to proceed to Genesys, otherwise they can just close the page.
Sample dialog:
![image](/uploads/27271a...We need to include a cookie consent dialog that says we need essential cookies and an “accept” box that they need to accept in order to proceed to Genesys, otherwise they can just close the page.
Sample dialog:
![image](/uploads/27271ab3725548e80e40a72b5bc2d444/image.png)
**Note:** Just use our regular styles and buttons :smile:
"Privacy statement" should link to */content/legal/privacy* page.
## Implementation
Add a (functional) `<CookiePolicy` component to the main `<App`.
The component will check if there is a cookie named `COOKIECOOKIE`.
`COOKIECOOKIE` cookie is an essential cookie that identifies that a user accepted the essential cookies.
If such cookie exists, then return `null` (also in SSR). Any suggestions how we can identify robots?
If there is no such cookie, then the component returns a container `div`. We will use `setTimeout` on the client (with a timeout of `XXXms`) and toggle the visibility of the dialog.
The dialog is centered in the page, displayed at the bottom of the page.
## On **I agree**
Add the `COOKIECOOKIE` cookie with value of `new Date()` and set it to expire in 3 months.2022.5Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/928Requesting: Country code2022-09-23T13:49:03+02:00Matija ObrezaRequesting: Country codeThe autocompleter for country code in the form is not working (sometimes):
![image](/uploads/5345ee13d0446376c2193122337cbcae/image.png)
Can we change the validator to use regexp `/^[A-Z]{3}$/gi`? The autocompleter helper tool can stay...The autocompleter for country code in the form is not working (sometimes):
![image](/uploads/5345ee13d0446376c2193122337cbcae/image.png)
Can we change the validator to use regexp `/^[A-Z]{3}$/gi`? The autocompleter helper tool can stay, but if I type in a code manually then it should accept it.
The `helperText` for this field should say "Type the ISO3 country code, or type the country name to use the autocompleter function".2022.4Maksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/927UI: Clicking on the image is not opening the full-size version2022-09-22T20:01:02+02:00Christelle RabilUI: Clicking on the image is not opening the full-size versionThis is a bug in Genesys UI, Clicking on the image is supposed to open the full-size version but it is not, for example here: https://www.genesys-pgr.org/10.18730/FPYZUThis is a bug in Genesys UI, Clicking on the image is supposed to open the full-size version but it is not, for example here: https://www.genesys-pgr.org/10.18730/FPYZUMaksym TishchenkoMaksym Tishchenkohttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/926Requests for material not being submitted in Sandbox2022-09-22T10:01:48+02:00Christelle RabilRequests for material not being submitted in SandboxAfter passing the Captcha and pressing "Submit request", an error message is displayed "Unknown error". This bug was fixed by @mobreza in production between August 10-12 but we need to fix it in Sandbox as well.
https://sandbox.genesys-...After passing the Captcha and pressing "Submit request", an error message is displayed "Unknown error". This bug was fixed by @mobreza in production between August 10-12 but we need to fix it in Sandbox as well.
https://sandbox.genesys-pgr.org/requests/create/submit
![Screenshot_2022-09-01_at_11.47.43](/uploads/6d90e506d28047ca8432376f2ca65b64/Screenshot_2022-09-01_at_11.47.43.png)Vladyslava MokliakVladyslava Mokliakhttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/925"Last updated" date did not update for institue ETH013 after they uploaded im...2022-09-06T14:55:24+02:00Christelle Rabil"Last updated" date did not update for institue ETH013 after they uploaded images to many accessionsFor example this accession: https://www.genesys-pgr.org/10.18730/FPYZU had an image added to it yeserday, but the "Last updated" date on Metadata is still showing up in 2018.For example this accession: https://www.genesys-pgr.org/10.18730/FPYZU had an image added to it yeserday, but the "Last updated" date on Metadata is still showing up in 2018.Vladyslava MokliakVladyslava Mokliakhttps://gitlab.croptrust.org/genesys-pgr/genesys-ui/-/issues/924Data protection: Consent2022-09-30T10:43:11+02:00Christelle RabilData protection: ConsentAdd a required consent box to submitting requests, creating Genesys accounts, and any other applicable field (maybe also in GGCE and Community) saying "I consent to Crop Trust processing my data etc."Add a required consent box to submitting requests, creating Genesys accounts, and any other applicable field (maybe also in GGCE and Community) saying "I consent to Crop Trust processing my data etc."Matija ObrezaMatija Obreza