📄 acccharge.asp
字号:
{
if (!validateNumber(param)||(!validateNumber(n)))
{
alert("非法的参数!");
return 0;
}
else
{
var temp = Math.pow(10,n);
var rtn = Math.round(temp*param)/temp;
//alert("原值为:"+param+"\n\n保留"+n+"位小数后的值为:"+rtn);
return rtn;
}
}
function openwindow(isconfirm,LinkStr,confirmmessage,returnstr,oids)
{
if (isconfirm == "yes")
{
if (confirm(confirmmessage))
{
document.forms[0].isconfirm.value = "yes";
document.forms[0].action = LinkStr;
document.forms[0].method = "post";
document.forms[0].submit();
}
else
{
if (oids == "null")
{
window.location = "selectaccount.jsp";
return ;
}
if (returnstr == "0")
{
window.location = "acccharge.jsp?act=normal";
}
else
{
window.location = "hungacccharge.jsp?act=normal";
}
//history.back();
}
}
}
//更改付款方式时
function changePayType()
{
//如果为银行支票或信用卡
if ((document.forms[0].paytype.value == "Cheque")||(document.forms[0].paytype.value =="Card"))
{
document.forms[0].checkno.disabled = false;
document.forms[0].bankno.disabled = false;
}
else
{
document.forms[0].checkno.disabled = true;
document.forms[0].bankno.disabled = true;
}
}
function doEnter(obj)
{
if (event.keyCode == 13)
{
document.getElementById(obj).focus();
//document.getElementById(obj).select();
}
}
function doChangeValue(obj,num,orgFee)
{
if (!validateNumber(obj.value))
{
alert("数字不合法,请重新输入!");
return false;
}
var latefee = document.getElementById("latefee").innerText * 1.0;
if (obj.name == "grantpercent")
{
var percent = round(obj.value * 1.0,2);
if (num < percent)
{
alert("减免比率不合法,最大减免比率为:" + num);
document.forms[0].grantpercent.value = num;
document.forms[0].grantfee.value = round(num * latefee,2);
document.forms[0].grantpercent.focus();
document.forms[0].grantpercent.select();
document.forms[0].factpay.value = getFee(orgFee - round(num * latefee,2)*100); //恢复实缴金额值
ChangeTotalFee("nochange","0"); //计算总金额值
return false;
}
document.forms[0].grantfee.value = round(latefee * percent ,2);
document.forms[0].factpay.value = getFee(orgFee - round(latefee * percent ,2)*100);
//document.forms[0].grantpercent.value = num;
}
else if (obj.name == "grantfee")
{
var grantfee = obj.value * 1.0;
if (num < grantfee)
{
alert("减免金额不合法,最大减免金额为:" + num);
document.forms[0].grantfee.value = num;
document.forms[0].grantpercent.value = round(num / latefee,2);
document.forms[0].grantfee.focus();
document.forms[0].grantfee.select();
document.forms[0].factpay.value = getFee(orgFee - num * 100); //恢复实缴金额值
ChangeTotalFee("nochange","0"); //计算总金额值
return false;
}
document.forms[0].grantpercent.value = round(grantfee / latefee,2);
document.forms[0].factpay.value = getFee(orgFee - grantfee * 100);
//document.forms[0].grantfee.value = num;
}
else
{
alert("未注册的元素!");
return false;
}
ChangeTotalFee("nochange","0");
return true;
}
function ShowHiddenFrame(atype,rownum)
{
document.getElementById("billframeid").style.display = "none";
document.getElementById("balanceframeid").style.display = "none";
//document.getElementById("billimgname").src = "/webapp/../images/tree_../images/folderclosed.gif";
//document.getElementById("balanceimgname").src = "/webapp/../images/tree_../images/folderclosed.gif";
if (rownum > 0)
{
document.getElementById(atype + "frameid").height = 60 + rownum * 25;
document.getElementById(atype + "frameid").style.display = "";
//document.getElementById(atype + "imgname").src="/webapp/../images/tree_../images/folderopen.gif";
}
else
{
var str = (atype == "bill" ? "应结帐单" : "科目余额");
alert("无" + str + "信息!");
}
}
function querybill(atype)
{
if (document.getElementById(atype + "frameid").style.display == "")
{
//document.getElementById(atype + "imgname").src="/webapp/../images/tree_../images/folderclosed.gif";
document.getElementById(atype + "frameid").style.display = "none";
}
else
{
waiting.style.visibility = "visible";
document.forms[0].action = "chargeacc.do?act=query" + atype;
document.forms[0].target = atype + "frame";
document.forms[0].method = "post";
document.forms[0].submit();
}
return true;
}
function getFee(orgfee)
{
var ODD_AMT = null * 1;
var ODD_METHOD = "null";
var tmp = 0;
if (ODD_AMT != 0)
{
tmp = orgfee % ODD_AMT;
}
if (ODD_METHOD == "UP")
{
if (tmp != 0)
{
orgfee = orgfee - tmp + ODD_AMT;
}
}
else if (ODD_METHOD == "DOWN")
{
orgfee = orgfee - tmp;
}
else if (ODD_METHOD == "ROUND")
{
if (tmp > ODD_AMT/2)
{
orgfee = orgfee - tmp + ODD_AMT;
}
else
{
orgfee = orgfee - tmp;
}
}
return round(orgfee/100,2);
}
/*
if (isconfirm == "yes")
{
var url = "confirmiframe.jsp?message = " + confirmmessage;
alert(confirmmessage);
//var style = "dialogWidth:400px;dialogHeight:300px;dialogLeft:200px;dialogTop:150px;center:yes;help:yes;resizable:yes;status:yes";
var style = "dialogHeight:250px;center:yes;help:no;resizable:no;status:no";
var rtn = window.showModalDialog(url,"ConfirmWindow",style);
if (rtn == "ok")
{
document.forms[0].isconfirm.value = "yes";
document.forms[0].action = LinkStr;
document.forms[0].method = "post";
document.forms[0].submit();
}
else
{
window.location = "acccharge.jsp?act=normal";
//history.back();
}
}*/
//-->
</SCRIPT>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD class=TitleBg>
<TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR height=22>
<TD width="15%"> <INPUT
class=INPUT_Border0
onclick=javascript:document.forms[0].telnumber.focus();
type=radio CHECKED value=telnumber
name=chargetype> 按名字查询</TD>
<TD width="15%">
<INPUT
class=INPUT_Border0
onclick=javascript:document.forms[0].telnumber.focus();
type=radio CHECKED value=telnumber
name=chargetype> 按工号查询</TD>
<TD width="18%">
<INPUT class=INPUT_Border0
onclick=javascript:document.forms[0].telnumber.focus();
type=radio value=accountno
name=chargetype> 按金额查询</TD>
<TD width="20%"> <INPUT
onkeypress="return doMyCK()" maxLength=80
name=telnumber2></TD>
<TD width="32%"><INPUT class=button_small onclick="return doValid('queryaccount');" type=button value=" 查 询 " name=queryaccount></TD>
</TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD>
<TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD
onmouseup="with(findObj('TopArea'))if(style.display=='none'){style.display='';}else{style.display='none';}"
class=CrossbandBg align=middle><IMG height=8
src="../images/ArrowDisplay.gif" width=10
border=0></TD></TR></TBODY></TABLE></TD></TR>
<TR id=TopArea>
<TD class=TopArea><INPUT type=hidden value=0.0
name=nowfee> <INPUT type=hidden name=factfee>
<TABLE cellSpacing=0 cellPadding=0 width="100%"
border=0>
<TBODY>
<TR>
<TD align=middle width="3%" height=32><IMG
height=20
src="../images/Ico_CircleBlue1.gif"
width=20></TD>
<TD class=AreaName width="12%">收费==>客户信息</TD>
<TD class=AreaName align=right width="20%"><INPUT
class=INPUT_Border0 type=checkbox value=true
name=linkcharge> 连缴 <INPUT type=hidden
value=0.0 name=totalfee>
<TD class=AreaName align=middle width="40%">选择帐户
<SELECT onchange="return doValid('querycustomer')"
name=accountno></SELECT> </TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=0 width="96%"
align=center border=0>
<TBODY>
<TR>
<TD class=DashedFrame_Angle_1><IMG height=1
width=1></TD>
<TD class=DashedFrame_Top><IMG height=1
width=1></TD>
<TD class=DashedFrame_Angle_2><IMG height=1
width=1></TD></TR>
<TR>
<TD class=DashedFrame_Left><IMG height=1
width=1></TD>
<TD class=DashedFrame_Bg>
<TABLE cellSpacing=0 cellPadding=0 width="96%"
align=center border=0>
<TBODY>
<TR>
<TD height=20><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>客户名称:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>客户类型:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>产品类型:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>归属单位:</TD>
<TD class=blueTxt> </TD></TR>
<TR>
<TD height=20><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>用户积分:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>客户品牌:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>用户状态:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>状态时间:</TD>
<TD class=blueTxt> </TD></TR>
<TR>
<TD height=20><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>信誉度:</TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt>付费类型:</TD>
<TD class=blueTxt>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt> </TD>
<TD class=blueTxt> </TD>
<TD><IMG height=5
src="../images/Ico_Dot.gif" width=5></TD>
<TD class=grayTxt> </TD>
<TD
class=blueTxt> </TD></TR></TBODY></TABLE></TD>
<TD class=DashedFrame_Right><IMG height=1
width=1></TD></TR>
<TR>
<TD height="858" class=DashedFrame_Angle_3><IMG height=1
width=1></TD>
<TD class=DashedFrame_Bottom><IMG height=1
width=1></TD>
<TD class=DashedFrame_Angle_4><IMG height=1
width=1></TD></TR></TBODY></TABLE>
<TABLE cellSpacing=0 cellPadding=0 width=100 border=0>
<TBODY>
<TR>
<TD><IMG height=10
width=1></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD>
<TD class=Bg_RightShadow vAlign=top>
<TABLE cellSpacing=0 cellPadding=0 width=10 border=0>
<TBODY>
<TR>
<TD class=Bg_Angle_2><IMG height=1
width=1></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR>
<TR>
<TD>
<TABLE height=10 cellSpacing=0 cellPadding=0 width="100%" border=0>
<TBODY>
<TR>
<TD class=Bg_Angle_3><IMG height=1 width=1></TD>
<TD class=Bg_BottomShadow><IMG height=1 width=1></TD>
<TD class=Bg_Angle_4><IMG height=1
width=1></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
<SCRIPT>
var aa = document.forms[0].factpay;
if (aa != null)
{
var asdf = document.forms[0].factpay.value - getFee(aa.value * 1) * 100 ;
//alert(asdf);
//alert(document.forms[0].factpay.value);
//alert(document.forms[0].totalfee.value);
//alert(document.forms[0].nowfee.value);
document.forms[0].factpay.value = getFee(aa.value * 1);
document.forms[0].nowfee.value = getFee(document.forms[0].nowfee.value * 100);
document.forms[0].totalfee.value = round(((round(document.forms[0].totalfee.value * 100,2) - asdf) / 100),2);
//alert(document.forms[0].factpay.value);
//alert(document.forms[0].totalfee.value);
//alert(document.forms[0].nowfee.value);
}
</SCRIPT>
</BODY></HTML>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -