@@ -16,10 +16,37 @@ | |||||
</div> | </div> | ||||
<div class="lr-layout-tool"> | <div class="lr-layout-tool"> | ||||
<div class="lr-layout-tool-left"> | <div class="lr-layout-tool-left"> | ||||
<div class="lr-layout-tool-item"> | |||||
<div id="multiple_condition_query"> | |||||
<div class="lr-query-formcontent"> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">学号</div> | |||||
<input id="StuNo" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">姓名</div> | |||||
<input id="StuName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">性别</div> | |||||
<div id="GenderNo"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">民族</div> | |||||
<div id="NationalityNo"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">身份证号</div> | |||||
<input id="IdentityCardNo" type="text" class="form-control"/> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</div> | </div> | ||||
<div class="lr-layout-tool-right"> | <div class="lr-layout-tool-right"> | ||||
<div class=" btn-group btn-group-sm"> | <div class=" btn-group btn-group-sm"> | ||||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | <a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | ||||
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i> 打印</a> | |||||
</div> | </div> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -1,6 +1,7 @@ | |||||
var refreshGirdData; | var refreshGirdData; | ||||
var bootstrap = function ($, learun) { | var bootstrap = function ($, learun) { | ||||
"use strict"; | "use strict"; | ||||
var Class; | |||||
var page = { | var page = { | ||||
init: function () { | init: function () { | ||||
page.initGird(); | page.initGird(); | ||||
@@ -11,13 +12,23 @@ var bootstrap = function ($, learun) { | |||||
$('#dataTree').lrtree({ | $('#dataTree').lrtree({ | ||||
url: top.$.rootUrl + '/EducationalAdministration/StuInfoBasic/GetTree', | url: top.$.rootUrl + '/EducationalAdministration/StuInfoBasic/GetTree', | ||||
nodeClick: function (item) { | nodeClick: function (item) { | ||||
Class = item.value; | |||||
page.search({ ClassNo: item.value }); | page.search({ ClassNo: item.value }); | ||||
} | } | ||||
}); | }); | ||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 200, 400); | |||||
$('#GenderNo').lrDataItemSelect({ code: 'usersexbit' }); | |||||
$('#NationalityNo').lrDataSourceSelect({ code: 'BCdNationality', value: 'nationalityno', text: 'nationality' }); | |||||
// 刷新 | // 刷新 | ||||
$('#lr_refresh').on('click', function () { | $('#lr_refresh').on('click', function () { | ||||
location.reload(); | location.reload(); | ||||
}); | }); | ||||
// 打印 | |||||
$('#lr_print').on('click', function () { | |||||
$('#gridtable').jqprintTable(); | |||||
}); | |||||
}, | }, | ||||
// 初始化列表 | // 初始化列表 | ||||
initGird: function () { | initGird: function () { | ||||
@@ -146,6 +157,7 @@ var bootstrap = function ($, learun) { | |||||
}, | }, | ||||
search: function (param) { | search: function (param) { | ||||
param = param || {}; | param = param || {}; | ||||
param.ClassNo = Class; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | ||||
} | } | ||||
}; | }; | ||||
@@ -43,8 +43,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
var dp = new DynamicParameters(new { }); | var dp = new DynamicParameters(new { }); | ||||
if (!queryParam["StuNo"].IsEmpty()) | if (!queryParam["StuNo"].IsEmpty()) | ||||
{ | { | ||||
dp.Add("StuNo", queryParam["StuNo"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.StuNo = @StuNo "); | |||||
dp.Add("StuNo", "%" + queryParam["StuNo"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.StuNo Like @StuNo "); | |||||
} | } | ||||
if (!queryParam["StuName"].IsEmpty()) | if (!queryParam["StuName"].IsEmpty()) | ||||
{ | { | ||||