Empty numeric input elements in a form send some data to my collection, while I'd like numeric fields to remain empty is nothing was entered

Hi everybody!
I’m having an issue. I have a dataset connected to a collection and I have a big form made of sections that expand depending on the user choise.
The problem is that when a section is collapsed, some numeric type input elements are not shown, so they remain empty and when I click the save button they send 0 or an error value to my numeric fields collection while I’d like that fields to be empty without any kind of data, just empty.
I don’t have this issue with text type input elements as when thay are empty they don’t send any data at all and text fields remain empty as I desire.

As you can see, the only thing I was able to get in the numeric field “price” are 2 types of values (zero and something like undefined) but I want nothing but an empty field value, as the text field “valuta” shows.
Thank you in advance.

Hello, I think to help you problem solve this it would be useful to show your code that is not working as expected so anyone who sees this post can understand the issue more clearly.

Here it is the code behind my input elements.

Even if #priceInput is hiden and the user doesn’t enter any data, you’ll find something in the price field in my collection. This happen only to numeric fields. If the field were text type as the valuta field then it would be empty as you can see. And I need numeric fileds to remain empty when nothing is entered.

So, the final result is the following:

Somebody help me. How to deal with hidden numeric fields?