rushfee/resource/html/tick/smsCount.html

234 lines
7.8 KiB
HTML

<html login="false">
<head>
<title>短信条数查询及导出</title>
<meta name="content-type" content="text/html; charset=UTF-8">
<style>
a {
cursor: pointer;
}
button {
border: 0;
width: 80px;
height: 25px;
outline: none;
cursor: pointer;
background: transparent;
vertical-align: middle;
border: 1px solid #e6e6e6;
}
button:hover {
color: #2579d1;
}
.button_active {
border: 1px solid #008fd7;
color: #2579d1;
}
.ui-tab {
overflow: hidden;
}
#li1,#li2 {
line-height: 40px;
font-size: 15px;
padding-left: 20px;
padding: 0 15px;
list-style-type: none;
float: left;
}
#li1,#li2:hover {
color: #2579d1;
}
li.active {
color: #008fd7;
border-bottom: 2px solid #008fd7;
}
</style>
</head>
<body>
<div class="f-fl" style="border-bottom: 1px solid #e6e6e6;">
<div class="ui-tab-line platform-tab">
<ul class="ui-tab">
<li id = "li1" data-field="invoice_status" data-value="0" onclick="original()"
class="active"><a>短信明细</a></li>
<li id = "li2"data-field="invoice_status" onclick="fgstj()" data-value="1">
<a>短信统计</a>
</li>
</ul>
</div>
</div>
<div id="detail_common"
style="border-bottom: 1px solid #e6e6e6; margin-top: 5px; margin-top: 5px;">
<div style="padding: 6px 0px 12px 0px; margin-left: 15px;">
<input name="current1_time" id ="current_time1" widget="datechooser" allowinput="f"
style="margin-top: 10px; margin-left: -10px;" label="当前日期">
<input name="operator" id="operator" widget="edit"
style="margin-top: 10px; margin-left: -10px;" label="催缴人">
</div>
</div>
<div id="count_common"
style="border-bottom: 1px solid #e6e6e6; margin-top: 5px;">
<div style="padding: 6px 0px 12px 0px; margin-left: 15px;">
<input name="current2_time" id ="current_time2" widget="datechooser" allowinput="f"
label="当前日期">
<input name="company_name" id ="company_name" widget="edit"
label="企业名称">
<input name="count" id="count" widget="edit"
label="短信发送条数">
</div>
</div>
<div class="search"
style="border-bottom: 1px solid #e6e6e6; margin-top: 5px;">
<div style="padding: 6px 0px 12px 0px; margin-left: 15px;">
<button type="button" style="margin-left:10px;" class= "bu_search" id="bu_search"
onclick="search()">查询</button>
<button type="button" style="margin-left:10px;" class="dc_button" id="dc_button"
onclick="exportsms()">导出</button>
<!-- <input widget="edit" name="ghfmc" id="ghfmc" class="ghfmc" label="购方名称"
style="margin-left:200px;margin-top:-25px;" /> -->
</div>
</div>
<div widget="autosize">
<div widget="datagrid" id="sms_detail" name="grid_detail"
style="width: 100%; height: 100%;"
url="rush/sms/count" onrowdblclick="smsdetail()">
<div type="indexcolumn" width="10" align="center" header="序号"></div>
<div field="operator" width="15" align="center" header="催缴人"></div>
<div field="operate_date" width="30" align="center" header="操作时间"></div>
<div field="tel" width="20" align="center" header="电话"></div>
<div field="company" width="35" align="center" header="企业名称"></div>
<div field="remark" width="120" align="center" header="短信内容"></div>
<div field="sms_count" visible ="false" align="center" header="统计条数" ></div>
</div>
<div widget="datagrid" id ="sms_count" name="grid_count" style="width: 100%; height: 100%;" url="rush/sms/count" onrowdblclick="smsdetail()">
<div type="indexcolumn" width="10" align="center" header="序号"></div>
<div field="operator" width="20" align="center" header="催缴人"></div>
<div field="tel" width="20" align="center" header="电话"></div>
<div field="company" width="40" align="center" header="企业名称"></div>
<div field="sms_count" width="20" align="center" header="统计条数" ></div>
</div>
</div>
</body>
<script type="text/javascript">
var type = "1";
var ui1 = document.getElementById("sms_detail");
var ui2 = document.getElementById("sms_count");
var ui3 = document.getElementById("detail_common");
var ui4 = document.getElementById("count_common");
var grid_detail = aos.get('grid_detail');
var grid_count = aos.get('grid_count');
$(document).ready(function(){
ui1.style.display="block";
ui2.style.display="none";
ui3.style.display="block";
ui4.style.display="none";
$(" div ul li").click(function() {
$(this).addClass("active").siblings().removeClass("active");
});//用于显示border为2 点击时出现下底线及颜色。siblings(匹配集合中每个元素的同胞)
});
//原始页面初始化
function original(){
type = "1";
ui1.style.display="block";
ui2.style.display="none";
ui3.style.display="block";
ui4.style.display="none";
}
//分公司统计初始化
function fgstj(){
type = "2" ;
ui1.style.display="none";
ui2.style.display="block";
ui4.style.display="block";
ui3.style.display="none";
}
function search(){
var params ={};
var current_time;
if(type==1){
current_time = aos.get("current_time1").getValue();
}else if (type==2){
current_time = aos.get("current_time2").getValue();
}
var current_time_start = current_time+ " 00:00:00";
var current_time_end = current_time+ " 23:59:59";
if(type==1){
params={
'current_time_start' : current_time_start,
'current_time_end' : current_time_end,
'operator' : aos.get("operator").getValue(),
'type' : type
}
grid_detail.load(params);
}else if(type==2){
params={
'current_time_start' : current_time_start,
'current_time_end' : current_time_end,
'company_name' : aos.get("company_name").getValue(),
'count' : aos.get("count").getValue(),
'type' : type
}
grid_count.load(params);
}
}
function exportsms(){
var params ={};
var current_time;
if(type==1){
current_time = aos.get("current_time1").getValue();
}else if (type==2){
current_time = aos.get("current_time2").getValue();
}
var current_time_start = current_time+ " 00:00:00";
var current_time_end = current_time+ " 23:59:59";
var base = document.getElementsByTagName("base")[0].href;
if(type==1){
var operator = aos.get("operator").getValue();
window.location.href=base+"rush/sms/exportsms?current_time_start="+current_time_start+"&current_time_end="+current_time_end+"&operator="+operator+"&type="+type;
}else if(type==2){
var count= aos.get("count").getValue();
var company_name = aos.get("company_name").getValue();
window.location.href=base+"rush/sms/exportsms?current_time_start="
+current_time_start+"&current_time_end="+current_time_end
+"&count="+count+"&company_name="+company_name+"&type="+type;
}
}
function smsdetail(){
var current_time;
if(type==1){
var data = grid_detail.getSelected();
current_time = aos.get("current_time1").getValue();
}else if(type==2){
var data = grid_count.getSelected();
current_time = aos.get("current_time2").getValue();
}
//console.log("1:"+JSON.stringify(data));
var operator = data.operator;
var company = data.company;
var tel = data.tel;
//var count = data.sms_count;
//var current_time = aos.get("current_time").getValue();
var current_time_start = current_time+ " 00:00:00";
var current_time_end = current_time+ " 23:59:59";
var params ={};
params={
'current_time_start' : current_time_start,
'current_time_end' : current_time_end,
'operator' : operator,
'company' : company,
'tel' : tel
}
aos.showWindow('canvas/tick/smsdetail', params, '950px', '350px', '短信详细信息', function(rtnValue){
});
}
</script>
</html>