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

📄 index.php

📁 极限网络智能办公系统 - Office Automation 2008 官方100% 源码
💻 PHP
📖 第 1 页 / 共 2 页
字号:
<?php
 

function GETALLDATE( $CODE )
{
	global $connection;
	$query = "SELECT * from SYS_CODE where PARENT_NO='".$CODE."'";
	$connection = openconnection( );
	$cursor = exequery( $connection, $query );
	echo "<option value= ></option>";
	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" );
$PAGE_SIZE = 10;
echo "<html>\r\n<head>\r\n<title>客户投诉记录查询</title>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=gb2312\">\r\n<script Language=\"JavaScript\">\r\nfunction td_calendar(fieldname)\r\n{\r\n  myleft=document.body.scrollLeft+event.clientX-event.offsetX-80;\r\n  mytop=document.body.scrollTop+event.clientY-event.offsetY+140;\r\n\r\n  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\");\r\n}\r\nfunction chk(input,KC,KT,count)\r\n{\r\n  var lstr=\"\";\r\n  if(count==1)\r\n  {\r\n  \tif(document.all(KC).checked)\r\n  \t{\r\n  \t\tdocument.all(KT).value=document.all(KC).value;\r\n  \t}\r\n   else\r\n    {\r\n   \t document.all(KT).value=\"\";\r\n    }\r\n  }\r\n  else\r\n  {\r\n    for(i=0;i<document.all(KC).length;i++)\r\n    {\r\n       el=document.all(KC).item(i);\r\n       if(el.checked)\r\n       {\r\n       \t val=el.value;\r\n          lstr+=val+\",\";\r\n\r\n       }\r\n     }\r\n     document.all(KT).value=lstr;\r\n  }\r\n}\r\n</script>\r\n</head>\r\n<div align=\"left\">\r\n<fieldset style=\"width:95%;padding-bottom:5px;\">\r\n\t <legend class=\"small\" align=left>\r\n      <b>客户投诉</b>\r\n  </legend>\r\n<table cellspacing=\"1\" class=\"small\" align=\"left\" cellpadding=\"3\">\r\n  <form action=\"list.php\"  method=\"post\" name=\"form1\">\r\n  <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;投诉类型: </td>\r\n    <td nowrap class=\"TableData\">\r\n     <select name=\"COMPLAINT_TYPE\" class=\"SmallSelect\">\r\n";
getalldate( "COMPLAINT_TYPE" );
echo "     </select>\r\n    </td>\r\n   <td nowrap class=\"TableData\">投诉日期: </td>\r\n    <td nowrap class=\"TableData\" colspan=\"3\">\r\n        <input type=\"text\" name=\"COMPLAINT_DATE1\" class=\"SmallStatic\"  readonly size=\"15\" maxlength=\"100\">&nbsp;\r\n        <img src=\"/images/menu/calendar.gif\" border=\"0\" style=\"cursor:hand\" onclick=\"td_calendar('form1.COMPLAINT_DATE1');\">\r\n        至\r\n        <input type=\"text\" name=\"COMPLAINT_DATE2\" class=\"SmallStatic\" size=\"15\" readonly maxlength=\"100\" >&nbsp;\r\n        <img src=\"/images/menu/calendar.gif\" border=\"0\" style=\"cursor:hand\" onclick=\"td_calendar('form1.COMPLAINT_DATE2');\">\r\n    </td>\r\n   </tr>\r\n  <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;投诉内容: </td>\r\n    <td nowrap class=\"TableData\" colspan=\"3\">\r\n         <textarea cols=37 rows=1 name=\"COMPLAINT_CONTENT\" class=\"BigInput\" wrap=\"yes\"></textarea>\r\n    </td>\r\n  </tr>\r\n ";
$count = 0;
$connection = openconnection( );
$query = "select count(*) from FIELDSETTING where TABLENAME='COMPLAINT' and ISQUERY='1'";
$cursor = exequery( $connection, $query );
if ( $ROW = mysql_fetch_array( $cursor ) )
{
	$count = $ROW[0];
}
if ( 0 < $count )
{
	echo "   <tr>\r\n    <td nowrap  class=\"TableHeader\" colspan=\"6\" align=\"left\">\r\n     &nbsp;&nbsp;用户自定义字段:\r\n    </td>\r\n   </tr>\r\n";
	$query = "select * from FIELDSETTING where TABLENAME='COMPLAINT' AND ISQUERY='1' ORDER BY ORDERNO ASC  ";
	$cursor = exequery( $connection, $query );
	while ( $ROW = mysql_fetch_array( $cursor ) )
	{
		$FIELDNAME = $ROW['FIELDNAME'];
		$ORDERNO = $ROW['ORDERNO'];
		$STYPE = $ROW['STYPE'];
		$TYPENAME = $ROW['TYPENAME'];
		$TYPEVALUE = $ROW['TYPEVALUE'];
		$TYPECODE = $ROW['TYPECODE'];
		$ISQUERY = $ROW['ISQUERY'];
		$ISGROUY = $ROW['ISGROUY'];
		$FIELDNAME = $ROW['FIELDNAME'];
		$FIELDNO = $ROW['FIELDNO'];
		echo "   <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;";
		echo $FIELDNAME;
		echo ":</td>\r\n    <td nowrap class=\"TableData\" colspan=\"5\">\r\n";
		if ( $STYPE == "T" )
		{
			echo "     <input type=\"text\" name='COMPLAINT";
			echo $FIELDNO;
			echo "' class=\"SmallInput\" size=\"33\" maxlength=\"25\" value=\"\">\r\n";
		}
		if ( $STYPE == "MT" )
		{
			echo "     <textarea cols=37 rows=1 name='COMPLAINT";
			echo $FIELDNO;
			echo "' class=\"SmallInput\" wrap=\"yes\"></textarea>\r\n\r\n";
		}
		if ( $STYPE == "D" )
		{
			$TYPEVALUE = str_replace( ",", ",", $TYPEVALUE );
			$TYPEVALUE_ARRAY = explode( ",", $TYPEVALUE );
			$TYPENAME = str_replace( ",", ",", $TYPENAME );
			$TYPENAME_ARRAY = explode( ",", $TYPENAME );
			$TYPENAME_COUNT = sizeof( $TYPENAME_ARRAY );
			if ( $TYPENAME_ARRAY[$TYPENAME_COUNT - 1] == "" )
			{
				--$TYPENAME_COUNT;
			}
			echo "       <select name='COMPLAINT";
			echo $FIELDNO;
			echo "' class=\"SmallSelect\">\r\n       <option value=\"\"></option>\r\n";
			$I = 0;
			for ( ;	$I < $TYPENAME_COUNT;	++$I	)
			{
				echo "\r\n       <option value=\"";
				echo $TYPEVALUE_ARRAY[$I];
				echo "\">";
				echo $TYPENAME_ARRAY[$I];
				echo "</option>\r\n\r\n";
			}
		}
		if ( $STYPE == "C" )
		{
			$TYPEVALUE = str_replace( ",", ",", $TYPEVALUE );
			$TYPEVALUE_ARRAY = explode( ",", $TYPEVALUE );
			$TYPENAME = str_replace( ",", ",", $TYPENAME );
			$TYPENAME_ARRAY = explode( ",", $TYPENAME );
			$TYPENAME_COUNT = sizeof( $TYPENAME_ARRAY );
			if ( $TYPENAME_ARRAY[$TYPENAME_COUNT - 1] == "" )
			{
				--$TYPENAME_COUNT;
			}
			echo "       <input type=\"hidden\" name='COMPLAINT";
			echo $FIELDNO;
			echo "'>\r\n";
			$I = 0;
			for ( ;	$I < $TYPENAME_COUNT;	++$I	)
			{
				echo "       <input type=\"checkbox\" name='CCOMPLAINT";
				echo $FIELDNO;
				echo "' id='CCOMPLAINT";
				echo $FIELDNO;
				echo $I;
				echo "' value=\"";
				echo $TYPEVALUE_ARRAY[$I];
				echo "\" onclick=\"return chk(this,'CCOMPLAINT";
				echo $FIELDNO;
				echo "','COMPLAINT";
				echo $FIELDNO;
				echo "','";
				echo $TYPENAME_COUNT;
				echo "');\"><label for=\"CCOMPLAINT";
				echo $FIELDNO;
				echo $I;
				echo "\">";
				echo $TYPENAME_ARRAY[$I];
				echo "</label>\r\n\r\n";
			}
		}
		if ( $STYPE == "R" )
		{
			$TYPEVALUE = str_replace( ",", ",", $TYPEVALUE );
			$TYPEVALUE_ARRAY = explode( ",", $TYPEVALUE );
			$TYPENAME = str_replace( ",", ",", $TYPENAME );
			$TYPENAME_ARRAY = explode( ",", $TYPENAME );
			$TYPENAME_COUNT = sizeof( $TYPENAME_ARRAY );
			if ( $TYPENAME_ARRAY[$TYPENAME_COUNT - 1] == "" )
			{
				--$TYPENAME_COUNT;
			}
			$I = 0;
			for ( ;	$I < $TYPENAME_COUNT;	++$I	)
			{
				echo "      <input type=\"radio\" name='COMPLAINT";
				echo $FIELDNO;
				echo "' id='COMPLAINT";
				echo $FIELDNO;
				echo $I;
				echo "' value=\"";
				echo $TYPEVALUE_ARRAY[$I];
				echo "\"><label for=\"COMPLAINT";
				echo $FIELDNO;
				echo $I;
				echo "\">";
				echo $TYPENAME_ARRAY[$I];
				echo "</label>\r\n";
			}
		}
		echo "\r\n    </td>\r\n </tr>\r\n";
	}
}
echo "\r\n <tr>\r\n \t\t<td nowrap class=\"TableData\"  colspan=\"6\" align=\"right\" width=\"650\">\r\n     &nbsp;&nbsp;&nbsp;<input value=\"查询\" type=\"submit\" class=\"SmallButton\" title=\"查询\" name=\"button\">\r\n     &nbsp;&nbsp;<input value=\"返回\" type=\"button\" class=\"SmallButton\" title=\"返回\" name=\"button\" onclick=\"location='../'\">\r\n    </td>\r\n </tr>\r\n</table>\r\n</fieldset>\r\n</div>\r\n<br>\r\n<div align=\"left\">\r\n<fieldset style=\"width:95%;padding-bottom:5px;\">\r\n\t <legend class=\"small\" align=left>\r\n      <b>客户信息</b>\r\n  </legend>\r\n<table cellspacing=\"1\" class=\"small\" align=\"left\" cellpadding=\"3\">\r\n  <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;客户名称: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <input type=\"text\" name=\"CUSTOMER_NAME\" class=\"SmallInput\" size=\"15\" maxlength=\"100\">\r\n    </td>\r\n   <td nowrap class=\"TableData\">客户编码: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <input type=\"text\" name=\"CUSTOMER_CODE\" class=\"SmallInput\" size=\"15\" maxlength=\"100\">\r\n    </td>\r\n\r\n     <td nowrap class=\"TableData\">客户简称: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <input type=\"text\" name=\"CUSTOMER_SHORT\" class=\"SmallInput\" size=\"15\" maxlength=\"100\">\r\n    </td>\r\n   </tr>\r\n\r\n   <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;地区: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <input type=\"text\" name=\"CUSTOMER_AREA\" class=\"SmallInput\" size=\"15\" maxlength=\"100\">\r\n    </td>\r\n   <td nowrap class=\"TableData\">地址: </td>\r\n    <td nowrap class=\"TableData\" colspan=\"3\">\r\n        <input type=\"text\" name=\"CUSTOMER_ADD\" class=\"SmallInput\" size=\"43\" maxlength=\"100\">\r\n    </td>\r\n   </tr>\r\n\r\n  <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;客户来源: </td>\r\n    <td nowrap class=\"TableData\" >\r\n        <select name=\"SOURCE\" class=\"SmallSelect\">\r\n";
getalldate( "CRM_SOURCE" );
echo "        </select>\r\n    </td>\r\n\r\n\r\n    <td nowrap class=\"TableData\">客户类别: </td>\r\n    <td nowrap class=\"TableData\" >\r\n        <select name=\"KIND\" class=\"SmallSelect\">\r\n";
getalldate( "CRM_KIND" );
echo "        </select>\r\n    </td>\r\n\r\n    <td nowrap class=\"TableData\">销售方式: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <select name=\"SELLMODE\" class=\"SmallSelect\">\r\n";
getalldate( "SELL_MODE" );
echo "        </select>\r\n    </td>\r\n  </tr>\r\n <tr>\r\n \t<td nowrap class=\"TableData\">&nbsp;&nbsp;行业属性: </td>\r\n    <td nowrap class=\"TableData\">\r\n        <select name=\"ATTRIBUTE\" class=\"SmallSelect\">\r\n";
getalldate( "CRM_ATTRIBUTE" );
echo "        </select>\r\n    </td>\r\n\r\n   <td nowrap class=\"TableData\">企业性质: </td>\r\n    <td nowrap class=\"TableData\" >\r\n        <select name=\"ENTERTYPE\" class=\"SmallSelect\">\r\n";
getalldate( "CRM_TYPE" );
echo "        </select>\r\n\r\n\r\n    </td>\r\n  <td nowrap class=\"TableData\">企业描述: </td>\r\n    <td nowrap class=\"TableData\"  colspan=\"2\">\r\n        <input type=\"text\" name=\"ENTERMEMO\" class=\"SmallInput\" size=\"15\" maxlength=\"100\">\r\n    </td>\r\n </tr>\r\n";
$count = 0;
$connection = openconnection( );
$query = "select count(*) from FIELDSETTING where TABLENAME='CUSTOMER' and ISQUERY='1'";
$cursor = exequery( $connection, $query );
if ( $ROW = mysql_fetch_array( $cursor ) )
{
	$count = $ROW[0];
}
if ( 0 < $count )
{
	echo "   <tr>\r\n    <td nowrap  class=\"TableHeader\" colspan=\"6\" align=\"left\">\r\n    &nbsp;&nbsp;用户自定义字段:\r\n    </td>\r\n   </tr>\r\n";
	$query = "select * from FIELDSETTING where TABLENAME='CUSTOMER' AND ISQUERY='1' ORDER BY ORDERNO ASC  ";
	$cursor = exequery( $connection, $query );
	while ( $ROW = mysql_fetch_array( $cursor ) )
	{
		$FIELDNAME = $ROW['FIELDNAME'];
		$ORDERNO = $ROW['ORDERNO'];
		$STYPE = $ROW['STYPE'];
		$TYPENAME = $ROW['TYPENAME'];
		$TYPEVALUE = $ROW['TYPEVALUE'];
		$TYPECODE = $ROW['TYPECODE'];
		$ISQUERY = $ROW['ISQUERY'];
		$ISGROUY = $ROW['ISGROUY'];
		$FIELDNAME = $ROW['FIELDNAME'];
		$FIELDNO = $ROW['FIELDNO'];
		echo "   <tr>\r\n    <td nowrap class=\"TableData\">&nbsp;&nbsp;";
		echo $FIELDNAME;
		echo ":</td>\r\n    <td nowrap class=\"TableData\" colspan=\"5\">\r\n";
		if ( $STYPE == "T" )
		{
			echo "     <input type=\"text\" name='CUSTOMER";
			echo $FIELDNO;
			echo "' class=\"SmallInput\" size=\"33\" maxlength=\"25\" value=\"\">\r\n";
		}
		if ( $STYPE == "MT" )
		{
			echo "     <textarea cols=37 rows=1 name='CUSTOMER";
			echo $FIELDNO;
			echo "' class=\"SmallInput\" wrap=\"yes\"></textarea>\r\n\r\n";
		}
		if ( $STYPE == "D" )
		{
			$TYPEVALUE = str_replace( ",", ",", $TYPEVALUE );
			$TYPEVALUE_ARRAY = explode( ",", $TYPEVALUE );
			$TYPENAME = str_replace( ",", ",", $TYPENAME );
			$TYPENAME_ARRAY = explode( ",", $TYPENAME );
			$TYPENAME_COUNT = sizeof( $TYPENAME_ARRAY );
			if ( $TYPENAME_ARRAY[$TYPENAME_COUNT - 1] == "" )
			{
				--$TYPENAME_COUNT;
			}
			echo "       <select name='CUSTOMER";

⌨️ 快捷键说明

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