⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 f_fkjd.asp

📁 一个很好的在线购物系统
💻 ASP
📖 第 1 页 / 共 3 页
字号:


<!--#include file="../include/Pubconn.asp"-->
<!--#include file="../include/PubCode.asp"-->
<!--#include file="../include/PubFun.asp"--> 

<%
'以下为传过来的值
hth=request("hth")
zcbj=request("zcbj")
'由合同号找出对应的费用
set rsht=server.Createobject("adodb.Recordset")
mysql="select *  from F_tblcontract2 where contractnum='"&hth&"'"
rsht.open mysql,pubconn,1
htzj=rsht("totalprice")
fkdw=rsht("fkdw")
yfd=rsht("PrevGive")
fhqd=rsht("BeforeSendGood")
azqd=rsht("BeforeInstall")
tsqd=rsht("BeforeDegbut")
ysqd=rsht("BeforeCheck")
if fkdw="金额"   then
  yshd=htzj-yfd-fhqd-azqd-tsqd-ysqd  
else
  yshd=rsht("AfterCheck")
end if 
'以下为日期拆分处理
if rsht("yfrq")<>"" then
   year1=left(rsht("yfrq"),4)                  
   month1=mid(rsht("yfrq"),6,2)                  
   date1=right(rsht("yfrq"),2)   
end if 

if rsht("fhqrq")<>"" then
   year2=left(rsht("fhqrq"),4)                  
   month2=mid(rsht("fhqrq"),6,2)                  
   date2=right(rsht("fhqrq"),2)   
end if 

if rsht("azqrq")<>"" then
   year3=left(rsht("azqrq"),4)                  
   month3=mid(rsht("azqrq"),6,2)                  
   date3=right(rsht("azqrq"),2)   
end if 
if rsht("tsqrq")<>"" then
   year4=left(rsht("tsqrq"),4)                  
   month4=mid(rsht("tsqrq"),6,2)                  
   date4=right(rsht("tsqrq"),2)   
end if 
if rsht("ysqrq")<>"" then
   year5=left(rsht("ysqrq"),4)                  
   month5=mid(rsht("ysqrq"),6,2)                  
   date5=right(rsht("ysqrq"),2)   
end if 

if rsht("yshrq")<>"" then
   year6=left(rsht("yshrq"),4)                  
   month6=mid(rsht("yshrq"),6,2)                  
   date6=right(rsht("yshrq"),2)   
end if 
rsht.close
set rsht=nothing
'以下为本表单取得的值
fkdw1=request("fkdw")
yfd1=request("yfd")
'预付日期
year11=request("year1")
month11=request("month1")
date11=request("date1")
if year11<>"" and month11<>"" and date11<>"" then
   total11=year11+"-"+month11+"-"+date11
end if 
fhqd1=request("fhqd")
'发货前日期
year21=request("year2")
month21=request("month2")
date21=request("date2")
if year21<>"" and month21<>"" and date21<>"" then
   total21=year21+"-"+month21+"-"+date21
end if 
azqd1=request("azqd")
'安装前日期
year31=request("year3")
month31=request("month3")
date31=request("date3")
if year31<>"" and month31<>"" and date31<>"" then
   total31=year31+"-"+month31+"-"+date31
end if 
tsqd1=request("tsqd")
'调试前日期
year41=request("year4")
month41=request("month4")
date41=request("date4")
if year41<>"" and month41<>"" and date41<>"" then
   total41=year41+"-"+month41+"-"+date41
end if 
ysqd1=request("ysqd")
'验收前日期
year51=request("year5")
month51=request("month5")
date51=request("date5")
if year51<>"" and month51<>"" and date51<>"" then
   total51=year51+"-"+month51+"-"+date51
end if 
yshd1=request("yshd") 
'验收后日期
year61=request("year6")
month61=request("month6")
date61=request("date6")
if year61<>"" and month61<>"" and date61<>"" then
   total61=year61+"-"+month61+"-"+date61
end if 
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>单据查询</title><link href="../cread.css" rel="stylesheet" type="text/css">
</head>
<script language="vbscript">
sub yfd_onkeypress
		window.event.keyCode=PublicKeyAscii(document.form1.yfd.value,"Num",window.event.keyCode)
end sub
sub fhqd_onkeypress
		window.event.keyCode=PublicKeyAscii(document.form1.fhqd.value,"Num",window.event.keyCode)
end sub
sub azqd_onkeypress
		window.event.keyCode=PublicKeyAscii(document.form1.azqd.value,"Num",window.event.keyCode)
end sub
sub tsqd_onkeypress
		window.event.keyCode=PublicKeyAscii(document.form1.tsqd.value,"Num",window.event.keyCode)
end sub
sub ysqd_onkeypress
		window.event.keyCode=PublicKeyAscii(document.form1.ysqd.value,"Num",window.event.keyCode)
end sub

sub yfd_onkeyup
if document.form1.htzj.value="" then
   htzj=0
else
   htzj=eval(document.form1.htzj.value)
end if 
yfd=eval(document.form1.yfd.value)
fhqd=eval(document.form1.fhqd.value)
azqd=eval(document.form1.azqd.value)
tsqd=eval(document.form1.tsqd.value)
ysqd=eval(document.form1.ysqd.value)
fkdw=document.form1.fkdw.value

if fkdw="百分比" then
   document.form1.yshd.value=100-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.yfd.value="0"
      document.form1.yshd.value=100-fhqd-azqd-tsqd-ysqd
      exit sub
   end if 
end if 
if fkdw="金额" then
   document.form1.yshd.value=htzj-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.yfd.value="0"
      document.form1.yshd.value=htzj-fhqd-azqd-tsqd-ysqd
      exit sub
   end if 
end if 
end sub

sub fhqd_onkeyup
htzj=eval(document.form1.htzj.value)
yfd=eval(document.form1.yfd.value)
fhqd=eval(document.form1.fhqd.value)
azqd=eval(document.form1.azqd.value)
tsqd=eval(document.form1.tsqd.value)
ysqd=eval(document.form1.ysqd.value)
fkdw=document.form1.fkdw.value

if fkdw="百分比" then
   document.form1.yshd.value=100-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.fhqd.value="0"
      document.form1.yshd.value=100-yfd-azqd-tsqd-ysqd
      exit sub
   end if 
end if 
if fkdw="金额" then
   document.form1.yshd.value=htzj-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.fhqd.value="0"
      document.form1.yshd.value=htzj-yfd-azqd-tsqd-ysqd
      exit sub
   end if 
end if 
end sub
'
sub azqd_onkeyup

htzj=eval(document.form1.htzj.value)
yfd=eval(document.form1.yfd.value)
fhqd=eval(document.form1.fhqd.value)
azqd=eval(document.form1.azqd.value)
tsqd=eval(document.form1.tsqd.value)
ysqd=eval(document.form1.ysqd.value)
fkdw=document.form1.fkdw.value

if fkdw="百分比" then
   document.form1.yshd.value=100-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.azqd.value="0"
      document.form1.yshd.value=100-yfd-fhqd-tsqd-ysqd
      exit sub
   end if 
end if 
if fkdw="金额" then
   document.form1.yshd.value=htzj-yfd-fhqd-azqd-tsqd-ysqd
   if form1.yshd.value<0 then
      alert("数据输入有误!")
      document.form1.azqd.value="0"
      document.form1.yshd.value=htzj-yfd-fhqd-tsqd-ysqd
      exit sub
   end if 
end if 
end sub
'

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -