mirror of
https://git.imnavajas.es/jjimenez/safekat.git
synced 2025-07-25 22:52:08 +00:00
Creating modalDialog functionality
This commit is contained in:
@ -99,7 +99,8 @@
|
||||
</div>
|
||||
</div> <!-- //.accordion -->
|
||||
<?php endif; ?>
|
||||
|
||||
|
||||
|
||||
|
||||
<?= $this->endSection() ?>
|
||||
|
||||
@ -140,8 +141,10 @@
|
||||
});
|
||||
|
||||
$('#isRotativa').on("click",function(el){
|
||||
|
||||
AsyncConfirmYesNo('title', 'msg', MyYesFunction, MyNoFunction);
|
||||
|
||||
Swal.fire({
|
||||
/*Swal.fire({
|
||||
title: '<?= lang('MaquinasPapelImpresion.sureToChangeRotativaTitle') ?>',
|
||||
text: '<?= lang('MaquinasPapelImpresion.sureToChangeRotativaText') ?>',
|
||||
icon: 'warning',
|
||||
@ -172,8 +175,33 @@
|
||||
yeniden(response.<?= csrf_token() ?>);
|
||||
}
|
||||
});
|
||||
*/
|
||||
});
|
||||
|
||||
function AsyncConfirmYesNo(title, msg, yesFn, noFn) {
|
||||
var $confirm = $("#modalConfirmYesNo");
|
||||
$confirm.modal('show');
|
||||
$("#lblTitleConfirmYesNo").html(title);
|
||||
$("#lblMsgConfirmYesNo").html(msg);
|
||||
$("#btnYesConfirmYesNo").off('click').click(function () {
|
||||
yesFn();
|
||||
$confirm.modal("hide");
|
||||
});
|
||||
$("#btnNoConfirmYesNo").off('click').click(function () {
|
||||
noFn();
|
||||
$confirm.modal("hide");
|
||||
});
|
||||
}
|
||||
|
||||
function MyYesFunction() {
|
||||
alert("Time to get off your workstation!");
|
||||
$("#lblTestResult").html("You are hungry");
|
||||
}
|
||||
function MyNoFunction() {
|
||||
alert("Well... just continue working.");
|
||||
$("#lblTestResult").html("You are not hungry");
|
||||
}
|
||||
|
||||
$('#isPadre').on("click",function(el){
|
||||
if($(this).is(':checked')){
|
||||
|
||||
|
||||
Reference in New Issue
Block a user