|
|
@@ -4,7 +4,7 @@
|
|
|
</style>
|
|
|
|
|
|
<script>
|
|
|
- function checkDomain (domain, pid) {
|
|
|
+ function checkInput (domain, pid) {
|
|
|
var xhttp = new XMLHttpRequest();
|
|
|
var success = false;
|
|
|
xhttp.onreadystatechange = function() {
|
|
|
@@ -14,6 +14,13 @@
|
|
|
$(customFields[0]).addClass('has-success');
|
|
|
$(customFields[0]).removeClass('has-error');
|
|
|
$("#hint").text('');
|
|
|
+ if ($(checkBox[0]).hasClass('checked')) {
|
|
|
+ $("#btnCompleteProductConfig").prop("disabled",false);
|
|
|
+ } else {
|
|
|
+ $("#btnCompleteProductConfig").prop("disabled",true);
|
|
|
+ $("#hint").text('Bitte akzeptieren Sie die erweiterten Nutzungsbedingungen!');
|
|
|
+
|
|
|
+ }
|
|
|
} else {
|
|
|
console.log(this.responseText);
|
|
|
$(customFields[0]).addClass('has-error');
|
|
|
@@ -34,11 +41,14 @@
|
|
|
$(customFields[0]).val(''); // domain
|
|
|
$(checkBox[0]).removeClass('checked'); // checkbox
|
|
|
$(customFields[0]).blur(function () {
|
|
|
- checkDomain( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
+ checkInput( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
+ });
|
|
|
+ $(customFields[0]).paste(function () {
|
|
|
+ checkInput( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
});
|
|
|
$(customFields[0]).on('input', function () {
|
|
|
setTimeout(function () {
|
|
|
- checkDomain( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
+ checkInput( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
}, 1);
|
|
|
});
|
|
|
$(customFields[0]).focus(function () {
|
|
|
@@ -48,12 +58,7 @@
|
|
|
});
|
|
|
$(checkBoxHelper[0]).click(function () {
|
|
|
setTimeout(function () {
|
|
|
- if ($(checkBox[0]).hasClass('checked')) {
|
|
|
- $("#btnCompleteProductConfig").prop("disabled",false);
|
|
|
- } else {
|
|
|
- $("#btnCompleteProductConfig").prop("disabled",true);
|
|
|
- }
|
|
|
- checkDomain( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
+ checkInput( $(customFields[0]).val().trim(), {$productinfo['pid']});
|
|
|
}, 1);
|
|
|
});
|
|
|
});
|