Merge pull request #13515 from homer8173/patch-19
FIX : twice call in a page
This commit is contained in:
commit
1719647036
@ -7779,10 +7779,11 @@ class Form
|
|||||||
global $conf, $langs;
|
global $conf, $langs;
|
||||||
|
|
||||||
$out = '';
|
$out = '';
|
||||||
if (!empty($conf->use_javascript_ajax)) $out .= '<div class="inline-block checkallactions"><input type="checkbox" id="checkallactions" name="checkallactions" class="checkallactions"></div>';
|
$id=uniqid();
|
||||||
|
if (!empty($conf->use_javascript_ajax)) $out .= '<div class="inline-block checkallactions"><input type="checkbox" id="checkallactions'.$id.'" name="checkallactions" class="checkallactions"></div>';
|
||||||
$out .= '<script>
|
$out .= '<script>
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
$("#checkallactions").click(function() {
|
$("#checkallactions'.$id.'").click(function() {
|
||||||
if($(this).is(\':checked\')){
|
if($(this).is(\':checked\')){
|
||||||
console.log("We check all");
|
console.log("We check all");
|
||||||
$(".'.$cssclass.'").prop(\'checked\', true).trigger(\'change\');
|
$(".'.$cssclass.'").prop(\'checked\', true).trigger(\'change\');
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user