index.php
来自「通达OA2007SE源代码 非常好的」· PHP 代码 · 共 221 行
PHP
221 行
<?
include_once 'inc/auth.php';
include_once 'inc/utility_all.php';
echo '
<html>
<head>
<title>新建销售记录</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
';
echo '<s';
echo 'cript Language="JavaScript">
function LoadWindow1()
{
URL="/module/crm/product_select";
loc_x=document.body.scrollLeft+event.clientX-event.offsetX-100;
loc_y=document.body.scrollTop+event.clientY-event.offsetY+170;
window.showModalDialog(URL,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:320px;dialogHeight:245px;dialogTop:"+loc_y+"px;dialogLeft:"+loc_x+"px");
}
';
echo 'function LoadWindow2()
{
URL="/module/crm/service_select";
loc_x=document.body.scrollLeft+event.clientX-event.offsetX-100;
loc_y=document.body.scrollTop+event.clientY-event.offsetY+170;
window.showModalDialog(URL,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:320px;dialogHeight:245px;dialogTop:"+loc_y+"px;dialogLeft:"+loc_x+"px");
}
function CheckForm()
{
';
echo ' protb_output();
sertb_output();
if(document.form1.PRO_CONTENT.value=="" || document.form1.SER_CONTENT.value=="")
{
alert("产品或服务不能为空!");
return false;
}
if(document.form1.CUSTOMER_ID.value=="")
{ alert("客户名称不能为空!");
return (false);
}
if(document.form1.CUSTOMER_NAME.value=="")
{ alert("客户名称不能为空!");
r';
echo 'eturn (false);
}
if(document.form1.CREATE_DATE.value=="")
{ alert("记录日期不能为空!");
return (false);
}
document.form1.submit();
}
function protb_output()
{
lv_tb_id="PRO_MYTABLE";
var data_str="";
for (i=1; i < document.all(lv_tb_id).rows.length; i++)
{
for (j=0; j < document.all(lv_tb_id).rows(i).cells.length-1; j++)
{
data_';
echo 'str+=document.all(lv_tb_id).rows(i).cells(j).innerHTML+"`";
}
data_str+="\\n";
}
document.form1.PRO_CONTENT.value=data_str;
}
function sertb_output()
{
lv_tb_id="SER_MYTABLE";
var data_str="";
for (i=1; i < document.all(lv_tb_id).rows.length; i++)
{
for (j=0; j < document.all(lv_tb_id).rows(i).cells.length-1; j++)
{
data_str+=document.all(lv_';
echo 'tb_id).rows(i).cells(j).innerHTML+"`";
}
data_str+="\\n";
}
document.form1.SER_CONTENT.value=data_str;
}
function LoadWindow3()
{
URL="/module/crm/customer_select";
loc_x=document.body.scrollLeft+event.clientX-event.offsetX-100;
loc_y=document.body.scrollTop+event.clientY-event.offsetY+170;
window.showModalDialog(URL,self,"edge:raised;scroll:0;status:0;help:0;resi';
echo 'zable:1;dialogWidth:320px;dialogHeight:245px;dialogTop:"+loc_y+"px;dialogLeft:"+loc_x+"px");
}
function clear_dept1()
{
document.form1.PRO_ID.value="";
document.form1.PRO_NAME.value="";
}
function clear_dept2()
{
document.form1.SER_ID.value="";
document.form1.SER_NAME.value="";
}
function td_calendar(fieldname)
{
myleft=document.body.scrollLeft+event.clientX-event';
echo '.offsetX-80;
mytop=document.body.scrollTop+event.clientY-event.offsetY+140;
window.showModalDialog("/inc/calendar.php?FIELDNAME="+fieldname,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:280px;dialogHeight:215px;dialogTop:"+mytop+"px;dialogLeft:"+myleft+"px");
}
function LoadWindow()
{
URL="/module/user_select_single";
loc_x=document.body.scrollLeft+event.clien';
echo 'tX-event.offsetX-100;
loc_y=document.body.scrollTop+event.clientY-event.offsetY+200;
window.showModalDialog(URL,self,"edge:raised;scroll:0;status:0;help:0;resizable:1;dialogWidth:350px;dialogHeight:350px;dialogTop:"+loc_y+"px;dialogLeft:"+loc_x+"px");
}
function sel_change()
{
for(i=0;i<document.all("SERVICE_TYPE").length;i++)
{
el=document.all("SERVICE_TYPE").item(i);
';
echo ' if(el.checked)
{
val=el.value;
}
}
if(val=="0")
{
document.all("TYPE").value="PRO";
document.all("SER").style.display="none";
document.all("TOTALPRICE").style.display="none";
document.all("SERLIST").style.display="none"
if(document.all("PRO").style.display=="none")
document.all("PRO").style.display=';
echo '"";
if(document.all("PRI").style.display=="none")
document.all("PRI").style.display="";
if(document.all("QTY").style.display=="none")
document.all("QTY").style.display="";
if(document.all("PROLIST").style.display=="none")
document.all("PROLIST").style.display="";
document.all("SER_ID").value="";
document.all("SER_NAME").value=""';
echo ';
document.all("TOTAL_PRICE").value="";
}
else
{
document.all("TYPE").value="SER";
if(document.all("SER").style.display=="none")
document.all("SER").style.display="";
if(document.all("TOTALPRICE").style.display=="none")
document.all("TOTALPRICE").style.display="";
if(document.all("SERLIST").style.display=="none")
doc';
echo 'ument.all("SERLIST").style.display="";
document.all("PRI").style.display="none";
document.all("QTY").style.display="none";
document.all("PRO").style.display="none";
document.all("PROLIST").style.display="none"
document.all("PRO_ID").value="";
document.all("PRO_NAME").value="";
document.all("PRICE").value="";
document.all("TRANS_QTY").value';
echo '="";
}
}
function pro_addnew()
{
if(document.form1.PRO_ID.value=="")
{ alert("产品名称不能为空!");
return (false);
}
if(document.form1.PRICE.value=="")
{ alert("单价不能为空!");
return (false);
}
if(document.form1.TRANS_QTY.value=="")
{ alert("数量不能为空!");
return (false);
}
var mytable=document.all("PRO_MYTABLE");
rownum=mytable.rows';
echo '.length;
mynewrow = mytable.insertRow();
mynewrow.className="TableData";
mynewcell=mynewrow.insertCell();
mynewcell.align="center";
cell_html=document.form1.PRO_NAME.value;
mynewcell.innerHTML=cell_html;
mynewcell=mynewrow.insertCell();
mynewcell.align="center";
mynewcell.style.display="none";
cell_html=document.form1.PRO_ID.value;
mynewcell.innerHTML=cell_';
echo 'html;
mynewcell=mynewrow.insertCell();
mynewcell.align="center";
cell_html=document.form1.PRICE.value;
mynewcell.innerHTML=cell_html;
mynewcell=mynewrow.insertCell();
mynewcell.align="center";
cell_html=document.form1.TRANS_QTY.value;
mynewcell.innerHTML=cell_html;
mynewcell=mynewrow.insertCell();
mynewcell.align="center";
cell_html="<a href=#this onclick=\\';
echo '"protb_delete(this);\\">清除</a>";
mynewcell.innerHTML=cell_html;
document.form1.PRO_NAME.value="";
document.form1.PRO_ID.value="";
document.form1.PRICE.value="";
document.form1.TRANS_QTY.value="";
}
function ser_addnew()
{
if(document.form1.SER_NAME.value=="")
{ alert("服务名称不能为空!");
return (false);
}
if(document.form1.SER_ID.value=="")
{ alert("服务
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?