Disable the new fields if editing JO form. #324

This commit is contained in:
Korina Cordero 2020-02-10 08:35:31 +00:00
parent 716f263e6b
commit e202fb650c

View file

@ -1066,6 +1066,14 @@ $(function() {
{% endfor %}
{% endif %}
// disable the enabled customer fields
{% if mode != 'create' %}
$("#customer-email").prop("disabled", true);
$("#flag-dpa-consent").prop("disabled", true);
$("#flag-promo-sms").prop("disabled", true);
$("#flag-promo-email").prop("disabled", true);
{% endif %}
$("#row-form").submit(function(e) {
if (form_in_process) {
alert("Cannot submit form twice. First submission still in progress.");