Hi,
Sometimes, the develorpers needs to make some many calculation with date variables. Now, what we can do is create a variable as Datetime type and work with it. In this case, it helps if you need to save records with localize, but, that most of the times makes a mess if you objective are just dates calculation.
For example, one part of our application calculates forecast for factories, so what we are going to do is import the historical data from and external database, keep it on the app and then calculate. Think now that the record for the 'Date' is 29/10/2024 and I'm importing from an account configurate it in Spain (Timezone +1h).
In this case, to don't take count the localize, we will implement this configuration on the model domain.
Okay, but with this configuration, if you are not implementing right de dbConnector (is easy to not do it well), it will be imported as 28/10/2024 23:00, so at the beginning, the calculation are gonna be wrong.
Also, when we start to program the different algorithm, we are always to take care if it's localize or UTC function to work with it.
In my opinion, will be much easier to have a variable type call 'Date', which only can use date function (like addDays, etc.) and not hour function (addHours, etc.) will be so much helpful to don't make mistakes and be faster developing.
Also, for example, to convert a DateTime to a Date, just keeping out the ours is much easier.