diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php
index 67a8dab7845..880c450f798 100644
--- a/htdocs/core/class/html.form.class.php
+++ b/htdocs/core/class/html.form.class.php
@@ -4332,7 +4332,7 @@ class Form
if (depositPercent.length > 0) {
$("#' . $htmlname . '_deposit_percent_container").show().find("#' . $htmlname . '_deposit_percent").val(depositPercent);
} else {
- $("#' . $htmlname . '_deposit_percent_container").hide();
+ $("#' . $htmlname . '_deposit_percent_container").hide().find("#' . $htmlname . '_deposit_percent").val(0);
}
return true;