Controllo su generazione fattura elettronica
This commit is contained in:
parent
850cb3550f
commit
f041345860
|
@ -88,13 +88,13 @@ echo '
|
||||||
|
|
||||||
echo '
|
echo '
|
||||||
<div class="text-center">
|
<div class="text-center">
|
||||||
<form action="" method="post" role="form" style="display:inline-block">
|
<form action="" method="post" role="form" style="display:inline-block" id="form-xml">
|
||||||
<input type="hidden" name="id_plugin" value="'.$id_plugin.'">
|
<input type="hidden" name="id_plugin" value="'.$id_plugin.'">
|
||||||
<input type="hidden" name="id_record" value="'.$id_record.'">
|
<input type="hidden" name="id_record" value="'.$id_record.'">
|
||||||
<input type="hidden" name="backto" value="record-edit">
|
<input type="hidden" name="backto" value="record-edit">
|
||||||
<input type="hidden" name="op" value="generate">
|
<input type="hidden" name="op" value="generate">
|
||||||
|
|
||||||
<button type="submit" class="btn btn-primary btn-lg '.($disabled ? 'disabled' : '').'" '.($disabled ? ' disabled' : null).'>
|
<button id="genera" type="submit" class="btn btn-primary btn-lg '.($disabled ? 'disabled' : '').'" '.($disabled ? ' disabled' : null).'>
|
||||||
<i class="fa fa-file"></i> '.tr('Genera').'
|
<i class="fa fa-file"></i> '.tr('Genera').'
|
||||||
</button>
|
</button>
|
||||||
</form>';
|
</form>';
|
||||||
|
@ -115,3 +115,25 @@ echo '
|
||||||
</a>
|
</a>
|
||||||
|
|
||||||
</div>';
|
</div>';
|
||||||
|
|
||||||
|
if($generated){
|
||||||
|
echo '
|
||||||
|
<script>
|
||||||
|
$("#genera").click(function(event){
|
||||||
|
event.preventDefault();
|
||||||
|
swal({
|
||||||
|
title: "Sei sicuro?",
|
||||||
|
text: "Sarà generata nuovamente la fattura elettronica",
|
||||||
|
type: "warning",
|
||||||
|
showCancelButton: true,
|
||||||
|
confirmButtonColor: "#30d64b",
|
||||||
|
cancelButtonColor: "#d33",
|
||||||
|
confirmButtonText: "Genera"
|
||||||
|
}).then((result) => {
|
||||||
|
if (result) {
|
||||||
|
$("#form-xml").submit();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>';
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue