<!--#INCLUDE FILE="../HXINCLUDE/HXINCLUDEHEAD.ASP"--><!--#INCLUDE FILE="../HXINCLUDE/SelectDate.ASP"-->
<%if WS_S.MemberPriv("WS_SaleManageCustomConnectManage")<>1 then HX_GoBack "对不起,您的权限不够!",""
ColumnName="":Tablename="HX_CustomConnect":Tablename1="HX_CustomInfo":Orderby="":action=request("action")
set rs=WS_S.HX_SetRSD(ColumnName,Tablename,Orderby)
if action="saveinfo" then
 CIID=WS_s.HX_Replace(request("CIID")): ConnectContent=WS_s.HX_Replace(request("ConnectContent")): ConnectMan=WS_s.HX_Replace(request("ConnectMan")): ConnectMobile=WS_s.HX_Replace(request("ConnectMobile")): ConnectDate=WS_s.HX_Replace(request("ConnectDate")): ConnectDescribe=WS_s.HX_Replace(request("ConnectDescribe"))
  rs.addnew :rs("WS_CIID")=CIID:rs("WS_CustomConnectContent")=ConnectContent:rs("WS_CustomConnectMan")=ConnectMan
   if isdate(ConnectDate) then rs("WS_CustomConnectDate")=ConnectDate
   rs("WS_CustomConnectDescribe")=ConnectDescribe:rs("WS_CustomConnectCreateMan")=loginuid:rs.update
 response.write "<script>if(confirm('添加成功！是否继续添加？')) {location.href='CustomConnectCreate.asp';}else {location.href='CustomConnectManage.asp';}</script>"
 response.end
end if
response.Write "<html><head><meta http-equiv='Content-Type' content='text/html; charset=gb2312'><title>交往信息管理</title><link rel=stylesheet type=text/css href='../HXinclude/HX_Style.css'><script src='../HXinclude/HX_Function.js'></script></head><body topmargin='20' leftmargin='0' bottommargin='0'><table width='596'  border='0' cellspacing='1' cellpadding='0' align=center bgcolor='#613c25'><tr><td colspan='2' bgcolor=FFFBE8><table width='100%'  border='0' cellspacing='0' cellpadding='0'><tr><td height='25' background='../hximages/titleline.gif'><font class='fontmenu'>新建交往信息</font>　　　　　<a href='CustomConnectManage.asp' class='menu'>交往信息管理(交往信息总数 "&rs.recordcount&" )</a></td></tr></table><table width='100%'  border='0' cellspacing='1' cellpadding='3' bgcolor=FFFBE8><form name='form1' method='post' action='?action=saveinfo'><tr bgcolor='#FFFBE8'><td width='23%' align='right'>客户名称：</td><td width='77%'><select name='CIID' id='CIID'>"
Orderby=" where WS_CustomInfoSaleMan="&loginuid&" or WS_CustomInfoMan="&loginuid&" or WS_CustomInfoCreateMan="&loginuid&" or WS_CustomInfoMan=0 or WS_CustomInfoCreateMan=0 order by WS_CIID desc"
set urs=WS_S.HX_SetRSD(ColumnName,Tablename1,Orderby)
if urs.recordcount>0 then
do until urs.eof
  response.write "<option value='"&urs("WS_CIID")&"'>"&urs("WS_CustomInfoName")&"</option>"
  urs.movenext
loop
end if
WS_S.HX_RSClose urs  
response.write "</select></td></tr><tr bgcolor='#FFFBE8'><td align='right'>交往日期：</td><td><input name='ConnectDate' type='text' value='"&date&"' size='28' readonly>  <input name='button' type='button' title='选择开始时间' onClick=""popUpcalendar(this, form1.ConnectDate, 'yyyy/mm/dd')"" value='选择'></td></tr><tr bgcolor='#FFFBE8'><td align='right'>交往内容：</td><td><textarea name='ConnectContent' cols='36' rows='6' class='bgLine'></textarea></td></tr><tr bgcolor='#FFFBE8'><td align='right'>联 系 人：</td><td><input type='text' size='36' name='ConnectMan'></td></tr><tr bgcolor='#FFFBE8'><td align='right'>备　　注：</td><td><input type='text' size='36' name='ConnectDescribe'></td></tr><tr bgcolor='#FFFBE8'><td align='right' valign=top>&nbsp;</td><td><input type='submit' name='Submit' value=' 创 建 '> <input type='reset' name='Submit2' value=' 重 置 '></td></tr></form></table></td></tr></table>"
WS_S.HX_RSClose rs%>
