forked from science-ation/science-ation
Add the warnings back in! eeek!
This commit is contained in:
parent
d0d9fe4d60
commit
c098354179
@ -40,16 +40,23 @@ function draw_body(){
|
|||||||
?>
|
?>
|
||||||
|
|
||||||
<script language="javascript" type="text/javascript">
|
<script language="javascript" type="text/javascript">
|
||||||
|
|
||||||
function confirmYearRollover(){
|
function confirmYearRollover(){
|
||||||
var currentyear = <?=$config['FISCALYEAR']?>;
|
var currentyear = <?=$config['FISCALYEAR']?>;
|
||||||
var nextyear = document.forms.rollover.nextfiscalyear.value;
|
var nextyear = document.forms.rollover.nextfiscalyear.value;
|
||||||
|
|
||||||
// var okay=confirm('Are you sure you want to roll the FISCALYEAR from '+currentyear+' to '+nextyear+'? This can not be undone and should only be done if you are absolutely sure!');
|
if(nextyear<currentyear)
|
||||||
// if(okay){
|
alert('You cannot roll backwards in years!');
|
||||||
$.post('rolloverfiscal.php', {'action':'rollover', 'year':$('#nextfiscalyear').val()}, function(result){
|
else if(nextyear==currentyear)
|
||||||
$('#results').html(result);
|
alert('You cannot roll to the same year!');
|
||||||
});
|
else {
|
||||||
// }
|
var okay=confirm('Are you sure you want to roll the FISCALYEAR from '+currentyear+' to '+nextyear+'? This can not be undone and should only be done if you are absolutely sure!');
|
||||||
|
if(okay){
|
||||||
|
$.post('rolloverfiscal.php', {'action':'rollover', 'year':$('#nextfiscalyear').val()}, function(result){
|
||||||
|
$('#results').html(result);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
Loading…
Reference in New Issue
Block a user