tijian_tieying/web/dccdc/Views/QueryStatistics/CYRYTJQuery.cshtml

75 lines
2.8 KiB
Plaintext
Raw Permalink Normal View History

2025-02-20 12:14:39 +08:00

@{
ViewBag.Title = "从业人员体检情况统计";
}
@section scripts{
<script type="text/javascript">
$(function () {
$("#start").ligerDateEditor();
$("#end").ligerDateEditor();
//$("#start").ligerGetDateEditorManager().setValue(fun_date(-14));
//$("#end").ligerGetDateEditorManager().setValue(fun_date(0));
$("#yyjg").ligerComboBox({
url: "@Url.Action("getjg","WeiXin")", valueField: "jgid", textField: "jgmc", onSuccess: function () {
liger.get("yyjg").setValue("0");
}
});
cx();
})
function cx() {
var data = $("#searchForm").serializeArray();
$.ajax({
url: "@Url.Action("getCYRYTJList")", data: data, type: "post", dataType: "json",
success: function (data) {
$("#grid1").ligerGrid({
height: '98%',
width: '98%',
isScroll: true,
dataAction: "local",
selectRowButtonOnly: true,
data: data.data,
columns: data.columns,
alternatingRow: false,
usePager: false
});
liger.get("grid1").reRender();
}
});
}
function fun_date(days) {
var date1 = new Date(),
time1 = date1.getFullYear() + "-" + (date1.getMonth() + 1) + "-" + date1.getDate();//time1表示当前时间
var date2 = new Date(date1);
date2.setDate(date1.getDate() + days);
var y = date2.getFullYear();
var m = date2.getMonth() + 1;
m = m < 10 ? '0' + m : m;
var d = date2.getDate();
d = d < 10 ? ('0' + d) : d;
var time2 = y + "-" + m + "-" + d;
return time2;
}
</script>
}
<form id="searchForm">
<table class="t1" >
<tr>
<td width="70" class="ltd">主检日期</td>
<td width="150" class="rtd"><input type="text" id="start" name="start"></td>
<td width="20" class="ltd">到</td>
<td width="150" class="rtd"><input type="text" id="end" name="end"></td>
<td class="ltd" style="width:100px">预约机构:</td>
<td class="rtd" width="width:160px"><input id="yyjg" /></td>
<td width="150" class="rtd">@Html.CheckBox("sort1",false)统计时不包括复查人员</td>
<td width="150" class="rtd">@Html.CheckBox("sort2", false)按性别和年龄分段统计</td>
<td width="100" class="rtd"><input type="button" value="查询" onclick="cx();" class="l-button" /></td>
</tr>
</table>
</form>
<div id="grid1"></div>