📄 custinfolist.jsp
字号:
<%@ page language="java" pageEncoding="gbk"%>
<jsp:directive.page import="java.util.Date"/>
<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>
<jsp:directive.page import="com.crm.common.CommUtil"/>
<jsp:directive.page import="java.text.SimpleDateFormat"/>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<base href="<%=basePath %>"/>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>所有客户列表</title>
<link href="<%=basePath %>skin/default/default.css" rel="stylesheet" type="text/css" />
<script src="<%=basePath %>js/util.js" language="javascript" type="text/javascript"></script>
<script>
function updateState(state,id){
var str = "";
if(state == '1'){
str = "确定要恢复该客户的服务吗?";
}else if(state == '2'){
str = "确定要停止该客户的服务吗?";
}else if(state == '0'){
str = "确定要将该客户加入到黑名单中?";
}
if(confirm(str)){
location.href='<%=basePath %>manage/custinfo.do?paramtype=updateState&state=' + state + '&id=' + id;
}
}
function obj_MouseUp(obj,index){
try{
if (event.button==2) {
clearMenu();
x=document.body.scrollLeft+event.clientX
y=document.body.scrollTop+event.clientY
var oMenu = document.getElementById('menu'+index);
oMenu.style.left=x;//event.x;
oMenu.style.top=y;//event.y;
oMenu.style.display="";
}else{
clearMenu();
}
}catch(err){
}
}
function clearMenu(){
try{
var ArryMenu = document.getElementsByTagName("SPAN");
for(var i=0;i<ArryMenu.length;i++){
ArryMenu[i].style.display="none";
}
} catch(err){
}
}
function onbodyclick(){
if (event.button==1) {
clearMenu();
}
}
</script>
</head>
<body class="mainbody" oncontextmenu="return false" onmouseup="onbodyclick()">
<%
SimpleDateFormat sd = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String strnow = sd.format(new Date());
request.setAttribute("now",strnow);
%>
<table width="90%" border="0" cellspacing="2" cellpadding="0">
<tr>
<td class="tdgriud">首页 >> 客户管理 >> 客户列表</td>
<td class="tdgriud" align="right">
<html:link action="/manage/custinfo?paramtype=initinsert" target="mainframe">新增客户信息</html:link></td>
</tr>
</table>
<fieldset width="90%">
<table width="90%" border="0" cellspacing="0" cellpadding="0" class="querytable">
<html:form action="manage/custinfo">
<html:hidden property="paramtype" value="list"/>
<tr>
<td align="right">客户姓名:</td>
<td><html:text property="cust_name"/></td>
<td align="right">客户电话号码:</td>
<td> <html:text property="telephone"/></td>
</tr>
<tr>
<td align="right">性别:</td>
<td>
<html:select property="sex">
<html:option value="">全部</html:option>
<html:option value="0">女</html:option>
<html:option value="1">男</html:option>
</html:select>
</td>
<td align="right">日期:</td>
<td ><html:text property="start_date"></html:text>
<a href="javascript:void(0)" onclick="if(self.gfPop)gfPop.fPopCalendar(document.all.item('start_date'));return false;">
<html:img align="absmiddle" page="/include/calendar/calbtn.gif" width="34" height="22" border="0" alt=""/>
</a>
</tr>
<tr>
<td align="right">客户状态:</td>
<td>
<html:select property="state">
<html:option value="">全部</html:option>
<html:options collection="custstatelist" labelProperty="fieldname" property="fieldcode"/>
</html:select>
</td>
<td align="right">客户类别:</td>
<td>
<html:select property="type">
<html:option value="">全部</html:option>
<html:options collection="custtypelist" labelProperty="fieldname" property="fieldcode"/>
</html:select>
</td>
</tr>
<tr>
<td align="right">资金范围:</td>
<td>
<html:text property="minFunds"/>
--<html:text property="maxFunds"/>
</td>
<td align="right">定价范围:</td>
<td>
<html:text property="minPay"/>
--<html:text property="maxPay"/>
</td>
</tr>
<tr>
<td align="right">客服人员:</td>
<td>
<html:select property="employee_id">
<html:option value="">全部</html:option>
<html:options collection="userlist" property="id" labelProperty="employee_name"/>
</html:select>
</td>
<td align="right">排序字段:</td>
<td>
<html:select property="orderbycolumn">
<html:option value="">创建日期</html:option>
<html:option value="funds desc">资金</html:option>
<html:option value="pay desc">定价</html:option>
<html:option value="state">状态</html:option>
</html:select>
</td>
</tr>
<tr>
<td colspan="4" align="center">
<input type="submit" name="Submit" class="btn_save" value="查 询" />
<font color="blue">友情提示:右键下列各行客户信息进行客户管理 红色表示客户已经被停止服务,黄色表示服务已经到期</font>
</td>
</tr>
</html:form>
</table>
</fieldset>
<table width="98%" border="0" cellspacing="0" cellpadding="0" class="tdborder"><!-- onSelectStart="return false" -->
<tr>
<td width="4%" class="tdtitle">编号</td>
<td width="6%" class="tdtitle">客户姓名</td>
<td width="4%" class="tdtitle">性别</td>
<td width="8%" class="tdtitle">客户资金</td>
<td width="8%" class="tdtitle">定价</td>
<td width="10%" class="tdtitle">服务开始日期</td>
<td width="10%" class="tdtitle">服务结束日期</td>
<td width="8%" class="tdtitle">客户类型</td>
<td width="4%" class="tdtitle">状态</td>
<td width="19%" class="tdtitle">联系电话</td>
<td width="6%" class="tdtitle">客服人员</td>
<!-- <td width="7%" class="tdtitle">管理选项</td> -->
</tr>
<logic:notEmpty name="custinfolist">
<logic:iterate id="custinfo" name="custinfolist" indexId="index">
<tr onmouseover="TdMouseOver(this);" onmouseout="TdMouseOver(this);" onmouseup="obj_MouseUp(this,${index})")
ondblclick="window.open('<%=basePath %>manage/custinfo.do?paramtype=detail&id=<bean:write property="id" name="custinfo"/>','_new')"
<logic:equal name="custinfo" property="state" value="2">
bgcolor="red"
</logic:equal>
<logic:lessThan name="custinfo" property="end_date" value="${now}">
bgcolor="yellow"
</logic:lessThan>
>
<td align="center" class="tdbg">
<bean:write name="custinfo" property="id"/>
</td>
<td class="tdbg" style="cursor:hand;" onclick="window.open('<%=basePath %>manage/custinfo.do?paramtype=detail&id=<bean:write property="id" name="custinfo"/>','_new')">
<u><bean:write name="custinfo" property="cust_name" /></u>
</td>
<td class="tdbg"><bean:write name="custinfo" property="sex_name" /></td>
<td class="tdbg"><bean:write name="custinfo" property="funds" /></td>
<td class="tdbg"><bean:write name="custinfo" property="pay" /></td>
<td class="tdbg"><bean:write name="custinfo" property="start_date"/></td>
<td class="tdbg">
<bean:write name="custinfo" property="end_date" />
</td>
<td class="tdbg"><bean:write name="custinfo" property="type_name" /></td>
<td class="tdbg"><bean:write name="custinfo" property="state_name" /></td>
<td class="tdbg"><bean:write name="custinfo" property="telephone" />
,<bean:write name="custinfo" property="mobile" />
,<bean:write name="custinfo" property="elesephone" /></td>
<td class="tdbg">
<logic:empty name="custinfo" property="employee_name">
</logic:empty>
<bean:write name="custinfo" property="employee_name" />
</td>
<span style="position:absolute;z-index:2000;display:none" id="menu${index}"> <!--弹出菜单-->
<%
if(CommUtil.hasRight(session,"10201")){
%>
<input type="button" class="bon2" name="popItem2" value="修改客户信息" onclick="location.href='<%=basePath %>manage/custinfo.do?paramtype=initupdate&id=<bean:write property="id" name="custinfo"/>'" ><br>
<%} %>
<%
if(CommUtil.hasRight(session,"10202")){
%>
<logic:equal name="custinfo" property="state" value="1">
<input type="button" class="bon2" name="popItem2" value="停止客户服务" onclick="updateState('2','<bean:write property="id" name="custinfo"/>')" ><br>
</logic:equal>
<%} %>
<%
if(CommUtil.hasRight(session,"10203")){
%>
<logic:equal name="custinfo" property="state" value="2">
<input type="button" class="bon2" name="popItem2" value="恢复客户服务" onclick="updateState('1','<bean:write property="id" name="custinfo"/>')" ><br>
</logic:equal>
<%} %>
<%
if(CommUtil.hasRight(session,"10204")){
%>
<input type="button" class="bon2" name="popItem2" value="列 入 黑名单" onclick="updateState('0','<bean:write property="id" name="custinfo"/>')" ><br>
<%} %>
<input type="button" class="bon2" value="查看客户信息" onclick="window.open('<%=basePath %>manage/custinfo.do?paramtype=detail&id=<bean:write property="id" name="custinfo"/>','_new')"/>
<input type="button" class="bon2" value="关闭右键菜单" onclick="menu${index}.style.display='none';">
</span>
</tr>
</logic:iterate>
</logic:notEmpty>
</table>
<logic:present name="pagetool">
<bean:write name="pagetool" filter="false"/>
</logic:present>
<iframe width="174" height="189" name="gToday:normal:agenda.js" id="gToday:normal:agenda.js" src="<%=path%>/include/calendar/ipopeng.htm" scrolling="no" frameborder="0" style="visibility:visible; z-index:999; position:absolute; top:-500px; left:-500px;">
</iframe>
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -