mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
fix js bulkemail
This commit is contained in:
parent
7f90c88d6a
commit
2be924d5d8
|
|
@ -1044,15 +1044,21 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action))
|
|||
if ($conf->use_javascript_ajax && $conf->global->MAILING_CONTACT_DEFAULT_BULK_STATUS==-1)
|
||||
{
|
||||
print "\n".'<script type="text/javascript" language="javascript">'."\n";
|
||||
print 'jQuery(document).ready(function () {
|
||||
jQuery("#email").keyup(function() {
|
||||
if ($(this).val()!="") {
|
||||
$(".noemail").addClass("fieldrequired");
|
||||
} else {
|
||||
$(".noemail").removeClass("fieldrequired");
|
||||
}
|
||||
})
|
||||
})'."\n";
|
||||
|
||||
print '
|
||||
jQuery(document).ready(function () {
|
||||
function init_check_no_email(input) {
|
||||
if (input.val()!="") {
|
||||
$(".noemail").addClass("fieldrequired");
|
||||
} else {
|
||||
$(".noemail").removeClass("fieldrequired");
|
||||
}
|
||||
}
|
||||
$("#email").keyup(function() {
|
||||
init_check_no_email($(this));
|
||||
});
|
||||
init_check_no_email($("#email"));
|
||||
})'."\n";
|
||||
print '</script>'."\n";
|
||||
}
|
||||
if (!GETPOSTISSET("no_email") && !empty($object->email))
|
||||
|
|
|
|||
|
|
@ -1155,7 +1155,6 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action))
|
|||
document.formsoc.submit();
|
||||
});';
|
||||
if ($conf->global->MAILING_CONTACT_DEFAULT_BULK_STATUS==-1) {
|
||||
|
||||
print '
|
||||
function init_check_no_email(input) {
|
||||
if (input.val()!="") {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user