-
-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(data-modeling):create Financial.CurrencyConversion type #33
feat(data-modeling):create Financial.CurrencyConversion type #33
Conversation
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.
Looks good overall, just a few minor things.
@ll-zerr see the commit I just pushed up! I was able to update the name by recreating the content type and copying over the attributes. In general using the Strapi generate API seems more powerful than the admin panel, at least to create the base api / content type which you can then add attributes to via the admin panel. Want to try it out to create the next content type in the existing Steps I followed for the rename:
|
}, | ||
"attributes": { | ||
"year": { | ||
"type": "biginteger", |
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.
@ll-zerr don't love using biginteger
for this, as that will increase the database storage requirements.
Maybe it'd make sense to have year
as a string with custom regex validation? Something like ^20\d{2}$
would require it to be a year in the 2000s. You could make this more complex with something like ^2019|202[0-9]$
to allow it to be "2019" or a year in the "2020s".
Feel free to play around here: https://regex101.com/r/oxiBhf/1
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.
Ack @ll-zerr so sorry! I didn't realize I hadn't submitted this review two weeks ago when I made 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.
@jtfairbank, I made the changes suggested and modified the regex to include a year in the "2030s" to allow for a larger year span past five years.
…rrency conversion type
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.
praise: looks great @ll-zerr! thanks for your patience with the review, merging into saga
now
Resolves #32
Creates
Financial.CurrencyConversion
collection type.Note: Needed to create the year field type as short text to avoid a comma in the value.