28,390
社区成员
发帖
与我相关
我的任务
分享
<script type="text/javascript" charset="utf-8">
$(function(){
datagrid_Monthkaohe=$('#jixiaokaohe').datagrid({
url:'MonthkaoheSearch.asp',
title:'',
iconCls:'',
fit:true,
fitColumns:true,
nowrap : false,//一行显示所有数据,容不下时,会自动换行显示
rownumbers : true,//显示行号
columns:[[{
field:'Year',
title:'考核年度',
width:100,align:'centre',halign:'center',
rowStyler: function(index,row){
return 'background-color:#6293BB;color:#fff;';
}
},{
field:'jixiao_shijian',
title:'考核月份',
width:100,align:'centre',halign:'center'
},{
field:'jixiao_defen',
title:'考核得分',
width:100,align:'centre',halign:'center',
sortable:true
},{
field:'jixiao_jiafenyuanyin',
title:'加分原因',
width:300,align:'centre',halign:'center'
},{
field:'jixiao_koufenyuanyin',
title:'扣分原因',
width:300,
sortable:true ,align:'centre',halign:'center'
},{
field:'jixiao_beizhu',
title:'备注',
width:100,align:'centre',halign:'center'
}]],
});
});
searchData=function(){
xingming_id="<%=requestid%>"
datagrid_Monthkaohe.datagrid('load',{
KSMonth:$('#form1').find('[name=KSMonth]').val(),
JSMonth:$('#form1').find('[name=JSMonth]').val(),
xm_id:$('#form1').find('[name=requestid]').val()
})
alert("<%=requestid%>");
alert($('#form1').find('[name=KSMonth]').val())
alert(xingming_id);
}
</script>
<table class="datagrid-toolbar" style="width:100%; height:=100%" border="0" align="center" cellpadding="2" cellspacing="1" bgcolor="#009966">
<tr>
<td> 开始日期:<input name="KSMonth" id="KSMonth" type="text" class="Wdate" size="155px" onclick="WdatePicker({maxDate:'#F{$dp.$D(\'JSMonth\',{d:0})}'})" value="<%if request("KSMonth")<>"" then%><%=request("KSMonth")%><%else%><%=DateAdd("m",-1,date())%><% end if%>"></td>
<td>结束日期<input input name="JSMonth" id="JSMonth" type="text" size="155px" onClick="WdatePicker({minDate:'#F{$dp.$D(\'KSMonth\',{d:0})}'})" class="Wdate" value="<%if request("JSMonth")<>"" then%><%=request("JSMonth")%><%else%><%=year(now())%>-<%=month(now())%>-<%=day(now())%><%end if%>"></td>
<td align="center"><a href="javascript:void(0);" class="easyui-linkbutton" onClick="searchData();">查询</a>
<a id="btn" href="MonthkaoheSearch.asp" class="easyui-linkbutton" data-options="iconCls:'icon-search'">easyui</a> <input type="text" name="requestid" id="requestid" value="<%=request("requestid")%>"></td>
</tr>
</table>
<%
DIM r,rs,jObj,sqlstr,rows1
xingming_id=CInt(request("xm_id"))'姓名编号
KSMonth=request("KSMonth") '开始时间
JSMonth=request("JSMonth") '结束时间
'xingming_id=229
'拼WHERE条件
whereSql=" where 1=1 and xingming_id="&xingming_id&" "
if KSMonth<>"" then whereSql=whereSql&" and jixiao_shijian>=#" & KSMonth & "#"
if JSMonth<>"" then whereSql=whereSql&" and jixiao_shijian<=#" & JSMonth & "#"
rowCount=null
set rs=server.CreateObject("adodb.recordset")
sqlstr="select * from jixiao "&whereSql
'Response.Write sqlstr
rs.open sqlstr,conn,0,1
SET jObj=NEW simpleJson
SET r=jObj.DataBind(rs,rowCount)
Response.Write(KSMonth)
Response.Write(xingming_id)
Response.Write r.parseString()
%>