📄 index.php
字号:
<?
function getalldate ($CODE)
{
global $connection;
$query = (((''.'SELECT * from SYS_CODE where PARENT_NO=\'').$CODE).'\'');
$cursor = exequery ($connection, $query);
while ($ROW = mysql_fetch_array ($cursor))
{
$CODE_NO = $ROW['CODE_NO'];
$CODE_NAME = $ROW['CODE_NAME'];
echo (((('<option value='.$CODE_NO).'>').$CODE_NAME).'</option>');
}
}
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 CheckForm()
{
if(document.form1.CUSTOMER_ID.value=="")
{
alert("客户名称不能为空!");
return (false);
}
if(document.form1.CONTACT_DATE.value=="")
{
alert("客户服务日期不能为空!");
return (false);
}
}
function LoadWindow()
{
URL="/module/crm/customer_select";
loc_x=document.body.scrollLeft+event.clie';
echo 'ntX-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 LoadWindow1()
{
if(document.all("CUSTOMER_ID").value=="")
{
alert("客户名称不能空!");
}
else
{
URL="/mo';
echo 'dule/crm/linkman_select?CUSTOMER_ID="+document.all("CUSTOMER_ID").value;
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 td_ca';
echo 'lendar(fieldname)
{
myleft=document.body.scrollLeft+event.clientX-event.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 chk(input,KC,KT,count)
';
echo '
{
var lstr="";
if(count==1)
{
if(document.all(KC).checked)
{
document.all(KT).value=document.all(KC).value;
}
else
{
document.all(KT).value="";
}
}
else
{
for(i=0;i<document.all(KC).length;i++)
{
el=document.all(KC).item(i);
if(el.checked)
{
val=el.value;
lstr+=val+",";
}
';
echo ' }
document.all(KT).value=lstr;
}
}
function LoadWindow2(kname,codeid)
{
URL="/module/crm/codedefine.php?kname="+kname+"&codeid="+codeid;
myleft=(screen.availWidth-650)/2;
window.open(URL,"formul_edit","height=300,width=550,status=0,toolbar=no,menubar=no,location=no,scrollbars=yes,top=150,left="+myleft+",resizable=yes");
}
</script>
</head>
<body class="bodycolor" topmargin=';
echo '"5">
';
$query = 'select * from SALE_MANAGER where MANAGER_ID=1';
$cursor = exequery ($connection, $query);
if ($ROW = mysql_fetch_array ($cursor))
{
$MANAGER_ID = $ROW['MANAGER_ID'];
$MANAGERS = $ROW['MANAGERS'];
}
echo '<table border="0" width="100%" cellspacing="0" cellpadding="3" class="small">
<tr>
<td class="Big"><img src="/images/notify_new.gif" align="absmiddle">';
echo '<s';
echo 'pan class="big3"> 新建客户服务记录</span>
</td>
</tr>
</table>
<br>
<table border="0" cellspacing="1" width="450" class="small" bgcolor="#000000" cellpadding="3" align="center" >
<form action="add.php" method="post" name="form1" onsubmit="return CheckForm();">
<tr>
<td nowrap class="TableHeader" colspan="4" align="left">
客户服务基本信息:
</td>
</tr>
<tr>
<td';
echo ' nowrap class="TableData">服务类型: </td>
<td class="TableData">
';
echo '<s';
echo 'elect name="CONTACT_TYPE" class="BigSelect">
';
getalldate ('CONTACT_TYPE');
echo ' </select>
<a href="javascript:LoadWindow2(\'CONTACT_TYPE\',\'CONTACT_TYPE\');"><img src="/images/edit1.gif" align="absmiddle" border=0 title="客户来源定义"></a>
</td>
<td nowrap class="TableData">服务日期: </td>
<td nowrap class="TableData">
<input type="text" name="CONTACT_DATE" class="BigStatic" readonly size="15" maxlength="10" value="';
echo date ('Y-m-d', time ());
echo '">
<img src="/images/menu/calendar.gif" border="0" style="cursor:hand" onclick="td_calendar(\'form1.CONTACT_DATE\');">
</td>
</tr>
<tr>
<td nowrap class="TableData">客户名称: </td>
<td class="TableData">
<input type="hidden" name="CUSTOMER_ID" value="';
echo $CUSTOMER_ID;
echo '">
<input type="text" name="CUSTOMER_NAME" class="BigStatic" size="15" maxlength="100" readonly value="';
echo $CUSTOMER_NAME;
echo '">
<input type="button" value="选 择" class="SmallButton" onClick="LoadWindow()" title="选择客户" name="button">
</td>
<td nowrap class="TableData">联系人: </td>
<td nowrap class="TableData">
<input type="hidden" name="LINKMAN_ID" value="';
echo $LINKMAN_ID;
echo '">
<input type="text" name="LINKMAN_NAME" class="BigStatic" size="15" maxlength="100" value="';
echo $LINKMAN_NAME;
echo '">
<input type="button" value="选 择" class="SmallButton" onClick="LoadWindow1()" title="选择联系人" name="button">
</td>
</tr>
<tr>
<td nowrap class="TableData">服务预估成本: </td>
<td class="TableData">
<input type="text" name="MONEY_COST" class="BigInput" size="15" maxlength="100" style="text-align:right" value="';
echo $MONEY_COST;
echo '">元
</td>
<td nowrap class="TableData">时间成本: </td>
<td nowrap class="TableData">
<input type="text" name="TIME_COST" class="BigInput" size="15" style="text-align:right" maxlength="100" value="';
echo $LINKMAN_NAME;
echo '">小时
</td>
</tr>
<tr>
<td nowrap class="TableData">服务内容描述:</td>
<td nowrap class="TableData" colspan="3">
<textarea cols=57 rows=3 name="CONTACT_CONTENT" class="BigInput" wrap="yes">';
echo $CONTACT_CONTENT;
echo '</textarea>
</td>
</tr>
<tr>
<td nowrap class="TableHeader" colspan="4" align="left">
客户反馈:
</td>
</tr>
<tr>
<td nowrap class="TableData">客户满意度: </td>
<td nowrap class="TableData" colspan="3">
';
echo '<s';
echo 'elect name="SATISFY" class="BigSelect">
<option value=""></option>
<option value=01>很满意</option>
<option value=02>比较满意</option>
<option value=3>不满意</option>
<option value=05>很不满意</option>
</select>
</td>
</tr>
<tr>
<td nowrap class="TableData">客户反馈意见: </td>
<td nowrap class="TableData" colspan="3">
<textarea ';
echo 'cols=57 rows=3 name="FEEDBACK" class="BigInput" wrap="yes">';
echo $MEMO1;
echo '</textarea>
</td>
</tr>
<tr>
<td nowrap class="TableHeader" colspan="4" align="left">
描述:
</td>
</tr>
<tr>
<td nowrap class="TableData">备注1: </td>
<td nowrap class="TableData" colspan="3">
<textarea cols=57 rows=3 name="MEMO" class="BigInput" wrap="yes">';
echo $MEMO;
echo '</textarea>
</td>
</tr>
<tr>
<td nowrap class="TableData">备注2: </td>
<td nowrap class="TableData" colspan="3">
<textarea cols=57 rows=3 name="MEMO1" class="BigInput" wrap="yes">';
echo $MEMO1;
echo '</textarea>
</td>
</tr>
<tr>
<td class="TableData" colspan="4">
';
echo get_field_table (get_field_html ('CONTACT', $CONTACT_ID));
echo ' </td>
</tr>
<tr>
<td nowrap class="TableControl" colspan="4" align="center">
<input type="submit" value="确定" class="BigButton" title="新建客户服务记录" name="button">
<input type="button" value="清空" class="BigButton" onclick="location=\'index.php\'">
</td>
</tr>
</body>
</html>
';
?>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -