-
Notifications
You must be signed in to change notification settings - Fork 13
Autofill harvest year to current year #114
Autofill harvest year to current year #114
Conversation
@@ -1,6 +1,6 @@ | |||
import { FieldValues, Path, UseFormRegister } from 'react-hook-form'; | |||
|
|||
import { HTMLInputTypeAttribute } from 'react'; | |||
import { useState, HTMLInputTypeAttribute } from 'react'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is useState
needed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, its not. I was initially going to use it, but I forgot to remove it in the end.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hm surprised this goes through the pre-commit hook. We have a linter setup that should execute when committing, I'll have to take a look at it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
left 1 comment but lgtm
Great to see the continuation of the work for the seed milestone. We are so much looking forward to it! 🚀 @buenaflor thank you so much for reviewing! ❤️ Is this rebased to current master? The deployment does seem not work? (According to Jenkins log and also https://pr.permaplant.net/seeds/new doesn't seem to have the auto-fill feature?) |
I think so.... |
LGTM, on dev.permaplant.net it now shows the current year. @badnames please don't self-merge unless there is an emergency etc. It is better if someone else merges. We also want two reviews per PR, so that everyone learns most parts of PermaplanT. @buenaflor thank you for looking into it, please write your finding about linter in #98. |
The aim of this commit is to prefill the year input field in the seed creation dialog with the current year (As requested in #35).
This is accomplished by adding a new defaultValue prop to SimpleFormInput.
Basics
(first line should have
module: short statement
syntax)close #X
, are in the commit messages.Checklist
(not in the PR description)
Review