Generator-jhipster: Support java.time.Duration in entity creation

Created on 18 Jan 2019  路  6Comments  路  Source: jhipster/generator-jhipster

Overview of the feature request

Add support for the java.time.Duration type as a field of an entity.

Motivation for or Use Case

Hibernate 5 natively supports this type, and little effort is necessary for supporting it in Mongo (a couple of converters are already defined in a companion JHipster project).

Related issues or PR

I did the homework but didn't find anything.

I am working on a PR for this. Help wanted for React! And feedback is welcome!

  • [x] Checking this box is mandatory (this is just to show you read everything)
area

All 6 comments

Hi,
let me give an update.
This PR is necessary for adding this feature to the generator:
https://github.com/jhipster/jhipster/pull/159

Moreover, if anyone would like to help me on a PR for the generator, here's the forked repository, there's some work on the backend and on the Angular part done:
https://github.com/massimosiani/generator-jhipster
branch: support-for-duration
Here's the diff with the master branch:
https://github.com/jhipster/generator-jhipster/compare/master...massimosiani:support-for-duration

Please upvote :)
Thank you!

@massimosiani The PR https://github.com/jhipster/jhipster/pull/159 has been merged in the bom project.
Do you plan to make the PR in generator soon?

Hi @DanielFran sorry for the delay.
I hadn't much time to complete the work on the generator, but I will make progress this week.
Thank you!

@massimosiani Do you have news? It is just to understand if it can be included in v6 on time...

Hi @DanielFran, I was facing an issue with a couple of tests.
A PR is on its way!

@massimosiani : for your information, I encountered some issue:

  • Angular: updating an existing entity -> the field is empty
  • React: can't create an entity with Duration

Did you add the support for React too ? I'll try to confirm these issue and open a ticket for that if needed

Was this page helpful?
0 / 5 - 0 ratings

Related issues

edvjacek picture edvjacek  路  3Comments

chegola picture chegola  路  4Comments

frantzynicolas picture frantzynicolas  路  3Comments

sdoxsee picture sdoxsee  路  4Comments

ahmedeldeeb25 picture ahmedeldeeb25  路  3Comments