<html>
<head>
<title>.: PrimaNota OnLine by Initweb :.</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<script language="JavaScript">
function WinPers(url,name,w,h)
{
lt = (screen.width - w)/2;
tp = (screen.height - h)/2 - 50;
popupWin = window.open(url,name,'left='+lt+', top='+tp+', scrollbars=yes, titlebar=yes, menubar=yes, status=yes , resizable=yes, width='+w+',height='+h)
}
function onlynum(e)
{
if(e.which){
if(e.which!=46 && e.which!=8 && (e.which<48 || e.which>57))
return false;
}
else if(e.keyCode){
if(e.keyCode!=46 && e.keyCode!=8 && (e.keyCode<48 || e.keyCode>57))
return false;
}
return true;
}
function PopUP(pagina,valore,variabile)
{
if (valore != '')
{
window.open( pagina+'?'+variabile+'='+valore+'&CodDit=0001&DBNA ME=PrimaNota', 'miaPop', 'scrollbars=yes, titlebar=yes, menubar=yes, status=yes , resizable=yes, width=400, height=300');
}
}
function PopUPFinte(pagina,valore,variabile, obbli, nomecampo, nomeform)
{
if ((obbli == 'S') && (valore == ''))
{
alert('Campo Obbligatorio');
documents.forms[nomeform].elements[nomecampo].focus();
}
if (valore != '')
{
lt = screen.width;
tp = screen.height;
window.open( pagina+'?'+variabile+'='+valore+'&CodDit=0001&DBNA ME=PrimaNota', 'miaPop', 'scrollbars=no, titlebar=no, menubar=no, status=no , resizable=no, width=1, height=1, left=lt;, top=tp');
}
}
var isNav=false
if (parseInt(navigator.appVersion)>=4){
if (navigator.appName == "Netscape"){
window.captureEvents(Event.ONKEYPRESS)
window.onkeypress = tasti
isNav = true
}
else
document.onkeydown = tasti
}
var pos=null
var variabili=null
function tasti(e){
nome = pos;
if (nome != null){
if (isNav){
if (e.keyCode == 120){
WinPers(nome+'.php?Form=Testata&DBNAME=PrimaNota&C l=cl_kekko'+variabili,'new_win',625,375)
}
}
else{
if (window.event.keyCode == 120){
WinPers(nome+'.php?Form=Testata&DBNAME=PrimaNota&C l=cl_kekko'+variabili,'new_win',625,375)
}
}
pos = null;
}
}
function ControlloAnno(Valore,ValChk){
if (ValChk != Valore){
Flag = confirm('Data di registrazione non compresa nel periodo contabile !!!\r\nConferma?');
if (Flag!=true){
document.Testata.AaDatReg.value=ValChk;
}
}
else
{
if (document.Testata.AaDatDoc.value.length == 0){
document.Testata.AaDatDoc.value = document.Testata.AaDatReg.value;
}
if (document.Testata.MmDatDoc.value.length == 0){
document.Testata.MmDatDoc.value = document.Testata.MmDatReg.value;
}
if (document.Testata.GgDatDoc.value.length == 0){
document.Testata.GgDatDoc.value = document.Testata.GgDatReg.value;
}
}
}
function ControlloDoc(AA, MM, GG, Anno){
DataDoc = AA+MM+GG;
DataReg = document.Testata.AaDatReg.value+document.Testata.M mDatReg.value+document.Testata.GgDatReg.value
if (DataDoc > DataReg){
alert('Data documento superiore a quella di registrazione !!!');
document.Testata.AaDatDoc.value = document.Testata.AaDatReg.value;
document.Testata.MmDatDoc.value = document.Testata.MmDatReg.value;
document.Testata.GgDatDoc.value = document.Testata.GgDatReg.value;
document.Testata.GgDatDoc.focus();
}
if (Anno != AA){
Flag = confirm('Data documento non compresa nel periodo contabile !!!\r\nConferma?');
if (Flag!=true){
document.Testata.AaDatDoc.value=Anno;
}
}
}
</script>
</script>
<style>
body {font-family:verdana; font-size: 12pt; background-color: #D0D0D0; }
hr {color:#FF9900}
td {font-family:verdana; font-size: 10pt}
input {font-family:verdana; font-size: 10pt}
</style>
</head>
<body OnLoad="document.Testata.codcaus.focus()">
<table align = "center" width = "100%">
<tr>
<td valign="top">
[img]img/home.png[/img]
</td>
<td colspan="3" align="right">
[img]img/logo_pn.png[/img]
</td>
</tr>
<tr>
<td colspan="4" valign="top">
<hr>
</td>
</tr></TABLE>
<FORM ACTION="testata.php" METHOD="POST" NAME="Testata">
<TABLE WIDTH="95%" ALIGN="center">
<TR>
<TD align = "right">
Causale :
</TD>
<TD>
<INPUT TYPE="Text" NAME="codcaus" MAXLENGTH="3" SIZE="3" VALUE = "" onfocus = "pos=this.name;" onBlur="PopUPFinte('descau.php',this.value,'CodCau s','S','codcaus');">
<INPUT TYPE="Text" NAME="descaus" MAXLENGTH="40" SIZE="42">
</TD>
</TR>
<TR>
<TD align = "right">
Data registrazione :
</TD>
<TD>
<INPUT TYPE="Text" NAME="GgDatReg" MAXLENGTH="2" SIZE="2" VALUE="01" onKeyPress="return onlynum(event)">
<INPUT TYPE="Text" NAME="MmDatReg" MAXLENGTH="2" SIZE="2" VALUE="01" onKeyPress="return onlynum(event)">
<INPUT TYPE="Text" NAME="AaDatReg" MAXLENGTH="4" SIZE="4" VALUE="2004" onKeyPress="return onlynum(event)" OnBlur="ControlloAnno(this.value, '2004')">
</TD>
</TR>
<TR>
<TD align = "right">
Data documento :
</TD>
<TD>
<INPUT TYPE="Text" NAME="GgDatDoc" MAXLENGTH="2" SIZE="2" VALUE="" onKeyPress="return onlynum(event)">
<INPUT TYPE="Text" NAME="MmDatDoc" MAXLENGTH="2" SIZE="2" VALUE="" onKeyPress="return onlynum(event)">
<INPUT TYPE="Text" NAME="AaDatDoc" MAXLENGTH="4" SIZE="4" VALUE="" onKeyPress="return onlynum(event)" OnBlur="ControlloDoc(this.value, MmDatDoc.value, GgDatDoc.value, '2004')">
</TD>
</TR>
<TR>
<TD align="right">
Num. doc. originale :
</TD>
<TD>
<INPUT TYPE="Text" NAME="NumDoc" MAXLENGTH="30" SIZE="10" VALUE="">
Nr. serie/protocollo :
<INPUT TYPE="Text" NAME="codserie" MAXLENGTH="2" SIZE="2" VALUE="" onKeyPress="return onlynum(event)" onfocus = "pos=this.name;variabili='&CodDit=0001&Anno=2004&C odAtt=01413'" onBlur="PopUPFinte('desserie.php',this.value,'CodD it=0001&Anno=2004&CodAtt=01413&CodCaus='+document. Testata.codcaus.value+'&Serie','S','codserie');">
<INPUT TYPE="Text" NAME="Prot" MAXLENGTH="5" SIZE="5" VALUE="" onKeyPress="return onlynum(event)">
</TD>