@@ -32,8 +32,8 @@ | |||||
<input id="StuNum" type="text" class="form-control" readonly="readonly" /> | <input id="StuNum" type="text" class="form-control" readonly="readonly" /> | ||||
</div> | </div> | ||||
<div class="col-xs-6 lr-form-item" data-table="ClassInfo"> | <div class="col-xs-6 lr-form-item" data-table="ClassInfo"> | ||||
<div class="lr-form-item-title">班主任</div> | |||||
<div id="ClassDiredctorNo"></div> | |||||
<div class="lr-form-item-title">班主任<font face="宋体">*</font></div> | |||||
<div id="ClassDiredctorNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | </div> | ||||
<div class="col-xs-6 lr-form-item" data-table="ClassInfo"> | <div class="col-xs-6 lr-form-item" data-table="ClassInfo"> | ||||
<div class="lr-form-item-title">辅导员</div> | <div class="lr-form-item-title">辅导员</div> | ||||
@@ -47,7 +47,7 @@ | |||||
@*<a id="lr_classType" class="btn btn-default"><i class="fa fa-unlock"></i> 班级类型设定</a>*@ | @*<a id="lr_classType" class="btn btn-default"><i class="fa fa-unlock"></i> 班级类型设定</a>*@ | ||||
</div> | </div> | ||||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | <div class=" btn-group btn-group-sm" learun-authorize="yes"> | ||||
<a id="lr_stu" class="btn btn-default"><i class="fa fa-eye"></i> 查看学生</a> | |||||
@*<a id="lr_stu" class="btn btn-default"><i class="fa fa-eye"></i> 查看学生</a>*@ | |||||
<a id="lr_arrange" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 班主任/辅导员安排</a> | <a id="lr_arrange" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 班主任/辅导员安排</a> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
@@ -7,6 +7,28 @@ | |||||
<div class="lr-layout-wrap lr-layout-wrap-notitle "> | <div class="lr-layout-wrap lr-layout-wrap-notitle "> | ||||
<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-12 lr-form-item"> | |||||
<div class="lr-form-item-title">学号</div> | |||||
<input id="StuNo" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">姓名</div> | |||||
<input id="StuName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">奖励名称</div> | |||||
<input id="EncourgeName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">奖励日期</div> | |||||
<input id="EncourgeDate" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy/MM/dd' })" /> | |||||
</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"> | ||||
@@ -13,6 +13,9 @@ var bootstrap = function ($, learun) { | |||||
page.bind(); | page.bind(); | ||||
}, | }, | ||||
bind: function () { | bind: function () { | ||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 300, 400); | |||||
// 刷新 | // 刷新 | ||||
$('#lr_refresh').on('click', function () { | $('#lr_refresh').on('click', function () { | ||||
location.reload(); | location.reload(); | ||||
@@ -5,14 +5,14 @@ | |||||
<div class="lr-layout lr-layout-left-center" id="lr_layout"> | <div class="lr-layout lr-layout-left-center" id="lr_layout"> | ||||
<div class="lr-layout-left"> | <div class="lr-layout-left"> | ||||
<div class="lr-layout-wrap"> | <div class="lr-layout-wrap"> | ||||
<div class="lr-layout-title lrlt ">树形列表</div> | |||||
<div class="lr-layout-title lrlt ">班级列表</div> | |||||
<div id="dataTree" class="lr-layout-body"></div> | <div id="dataTree" class="lr-layout-body"></div> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
<div class="lr-layout-center"> | <div class="lr-layout-center"> | ||||
<div class="lr-layout-wrap "> | <div class="lr-layout-wrap "> | ||||
<div class="lr-layout-title"> | <div class="lr-layout-title"> | ||||
<span id="titleinfo" class="lrlt">列表信息</span> | |||||
<span id="titleinfo" class="lrlt">学生列表信息</span> | |||||
</div> | </div> | ||||
<div class="lr-layout-tool"> | <div class="lr-layout-tool"> | ||||
<div class="lr-layout-tool-left"> | <div class="lr-layout-tool-left"> | ||||
@@ -48,7 +48,8 @@ var bootstrap = function ($, learun) { | |||||
label: "出生日期", name: "Birthday", width: 100, align: "left", | label: "出生日期", name: "Birthday", width: 100, align: "left", | ||||
formatter: function (cellvalue) { | formatter: function (cellvalue) { | ||||
return learun.formatDate(cellvalue, 'yyyy-MM-dd'); | return learun.formatDate(cellvalue, 'yyyy-MM-dd'); | ||||
} }, | |||||
} | |||||
}, | |||||
{ label: "身份证号", name: "IdentityCardNo", width: 150, align: "left" }, | { label: "身份证号", name: "IdentityCardNo", width: 150, align: "left" }, | ||||
{ | { | ||||
label: "民族", name: "NationalityNo", width: 100, align: "left", | label: "民族", name: "NationalityNo", width: 100, align: "left", | ||||
@@ -170,6 +171,12 @@ var bootstrap = function ($, learun) { | |||||
page.search(); | page.search(); | ||||
}, | }, | ||||
search: function (param) { | search: function (param) { | ||||
if (learun.clientdata.get(['userinfo']).account.toLowerCase() != "system") {//登录用户是system时,列表展示所有学生;其他用户登录时,必须选择左侧班级才能查看学生; | |||||
if (Class == "" || Class == undefined || Class == null) { | |||||
learun.alert.warning("请选择左侧班级!"); | |||||
return false; | |||||
} | |||||
} | |||||
param = param || {}; | param = param || {}; | ||||
param.ClassNo = Class; | param.ClassNo = Class; | ||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | ||||
@@ -7,6 +7,28 @@ | |||||
<div class="lr-layout-wrap lr-layout-wrap-notitle "> | <div class="lr-layout-wrap lr-layout-wrap-notitle "> | ||||
<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-12 lr-form-item"> | |||||
<div class="lr-form-item-title">学号</div> | |||||
<input id="StuNo" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">姓名</div> | |||||
<input id="StuName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">处分名称</div> | |||||
<div id="PunishNo"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">处分日期</div> | |||||
<input id="PunishDate" type="text" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt: 'yyyy/MM/dd' })" /> | |||||
</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"> | ||||
@@ -13,6 +13,11 @@ var bootstrap = function ($, learun) { | |||||
page.bind(); | page.bind(); | ||||
}, | }, | ||||
bind: function () { | bind: function () { | ||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 300, 400); | |||||
$('#PunishNo').lrDataItemSelect({ code: 'Punishment' }); | |||||
// 刷新 | // 刷新 | ||||
$('#lr_refresh').on('click', function () { | $('#lr_refresh').on('click', function () { | ||||
location.reload(); | location.reload(); | ||||
@@ -48,6 +48,7 @@ namespace Learun.Application.WebApi | |||||
{ | { | ||||
ReqPageParam parameter = this.GetReqData<ReqPageParam>(); | ReqPageParam parameter = this.GetReqData<ReqPageParam>(); | ||||
var data = mealCardRunTabIBLL.GetPageList(parameter.pagination, parameter.queryJson); | var data = mealCardRunTabIBLL.GetPageList(parameter.pagination, parameter.queryJson); | ||||
data = data.OrderByDescending(x => x.centralTm); | |||||
var jsonData = new | var jsonData = new | ||||
{ | { | ||||
rows = data, | rows = data, | ||||
@@ -164,11 +164,19 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
} | } | ||||
if (!queryParam["accountName"].IsEmpty()) | if (!queryParam["accountName"].IsEmpty()) | ||||
{ | { | ||||
var IsPhone = queryParam["IsPhone"].ToString(); | |||||
if (IsPhone == "0") | |||||
var IsPhone = ""; | |||||
if (!queryParam["IsPhone"].IsEmpty()) | |||||
{ | { | ||||
dp.Add("accountName", queryParam["accountName"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.accountName = @accountName "); | |||||
IsPhone = queryParam["IsPhone"].ToString(); | |||||
if (IsPhone == "0") | |||||
{ | |||||
var accountName = queryParam["accountName"].ToString(); | |||||
if (accountName != "超级管理员") | |||||
{ | |||||
dp.Add("accountName", queryParam["accountName"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.accountName = @accountName "); | |||||
} | |||||
} | |||||
} | } | ||||
else | else | ||||
{ | { | ||||
@@ -77,6 +77,16 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
dp.Add("ClassNo", queryParam["ClassNo"].ToString(), DbType.String); | dp.Add("ClassNo", queryParam["ClassNo"].ToString(), DbType.String); | ||||
strSql.Append(" AND t.ClassNo = @ClassNo "); | strSql.Append(" AND t.ClassNo = @ClassNo "); | ||||
} | } | ||||
if (!queryParam["EncourgeName"].IsEmpty()) | |||||
{ | |||||
dp.Add("EncourgeName", "%" + queryParam["EncourgeName"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.EncourgeName Like @EncourgeName "); | |||||
} | |||||
if (!queryParam["EncourgeDate"].IsEmpty()) | |||||
{ | |||||
dp.Add("EncourgeDate", queryParam["EncourgeDate"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.EncourgeDate = @EncourgeDate "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<StuEncourgementEntity>(strSql.ToString(), dp, pagination); | return this.BaseRepository("CollegeMIS").FindList<StuEncourgementEntity>(strSql.ToString(), dp, pagination); | ||||
} | } | ||||
@@ -71,6 +71,17 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
dp.Add("ClassNo", queryParam["ClassNo"].ToString(), DbType.String); | dp.Add("ClassNo", queryParam["ClassNo"].ToString(), DbType.String); | ||||
strSql.Append(" AND t.ClassNo = @ClassNo "); | strSql.Append(" AND t.ClassNo = @ClassNo "); | ||||
} | } | ||||
if (!queryParam["PunishNo"].IsEmpty()) | |||||
{ | |||||
dp.Add("PunishNo", queryParam["PunishNo"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.PunishNo = @PunishNo "); | |||||
} | |||||
if (!queryParam["PunishDate"].IsEmpty()) | |||||
{ | |||||
dp.Add("PunishDate", queryParam["PunishDate"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.PunishDate = @PunishDate "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<StuPunishmentEntity>(strSql.ToString(), dp, pagination); | return this.BaseRepository("CollegeMIS").FindList<StuPunishmentEntity>(strSql.ToString(), dp, pagination); | ||||
} | } | ||||
catch (Exception ex) | catch (Exception ex) | ||||
@@ -44,8 +44,8 @@ namespace Learun.Application.TwoDevelopment.LR_Desktop | |||||
{ | { | ||||
try | try | ||||
{ | { | ||||
var refresh_token = _redis.Read<string>("refresh_token"); | |||||
var access_token = _redis.Read<string>("access_token"); | |||||
var refresh_token = _redis.Read<string>("refresh_token") == "null" ? "" : _redis.Read<string>("refresh_token"); | |||||
var access_token = _redis.Read<string>("access_token") == "null" ? "" : _redis.Read<string>("access_token"); | |||||
if (string.IsNullOrEmpty(refresh_token) || string.IsNullOrEmpty(_redis.Read<string>("access_token"))) | if (string.IsNullOrEmpty(refresh_token) || string.IsNullOrEmpty(_redis.Read<string>("access_token"))) | ||||
{ | { | ||||
//用户授权 | //用户授权 | ||||
@@ -75,12 +75,15 @@ namespace Learun.Application.TwoDevelopment.LR_Desktop | |||||
private void login() | private void login() | ||||
{ | { | ||||
var login_url = InsUrl + "/prod-api/api/web/collect/oauth2/login?grant_type=password&client_id=" + client_id + "&username=" + username + "&password=" + password; | var login_url = InsUrl + "/prod-api/api/web/collect/oauth2/login?grant_type=password&client_id=" + client_id + "&username=" + username + "&password=" + password; | ||||
var login_res_str = HttpMethods.Get(login_url); | |||||
var login_res_str = HttpMethods.Post(login_url); | |||||
var login_res = JsonConvert.DeserializeObject<InsResult>(login_res_str); | var login_res = JsonConvert.DeserializeObject<InsResult>(login_res_str); | ||||
var login_data = login_res.data; | var login_data = login_res.data; | ||||
_redis.Write($"access_token", ((dynamic)login_data)?.access_token, TimeSpan.FromSeconds(200)); | |||||
_redis.Write($"client_secret", ((dynamic)login_data)?.client_secret, TimeSpan.FromSeconds(160000)); | |||||
_redis.Write($"refresh_token", ((dynamic)login_data)?.refresh_token, TimeSpan.FromSeconds(250)); | |||||
string access_token = ((dynamic)login_data)?.access_token; | |||||
string client_secret = ((dynamic)login_data)?.client_secret; | |||||
string refresh_token = ((dynamic)login_data)?.refresh_token; | |||||
_redis.Write($"access_token", access_token, TimeSpan.FromSeconds(200)); | |||||
_redis.Write($"client_secret", client_secret, TimeSpan.FromSeconds(160000)); | |||||
_redis.Write($"refresh_token", refresh_token, TimeSpan.FromSeconds(250)); | |||||
} | } | ||||
/// <summary> | /// <summary> | ||||
/// 刷新token | /// 刷新token | ||||
@@ -92,7 +95,7 @@ namespace Learun.Application.TwoDevelopment.LR_Desktop | |||||
var refresh_url = | var refresh_url = | ||||
InsUrl + "/prod-api/api/web/collect/oauth2/refresh?grant_type=refresh_token&client_id=" + | InsUrl + "/prod-api/api/web/collect/oauth2/refresh?grant_type=refresh_token&client_id=" + | ||||
client_id + "&client_secret=" + client_secret + "&refresh_token=" + refresh_token; | client_id + "&client_secret=" + client_secret + "&refresh_token=" + refresh_token; | ||||
var refresh_res_str = HttpMethods.Get(refresh_url); | |||||
var refresh_res_str = HttpMethods.Post(refresh_url); | |||||
var refresh_res = JsonConvert.DeserializeObject<InsResult>(refresh_res_str); | var refresh_res = JsonConvert.DeserializeObject<InsResult>(refresh_res_str); | ||||
if (refresh_res == null || ((dynamic)refresh_res)?.code != 200) | if (refresh_res == null || ((dynamic)refresh_res)?.code != 200) | ||||
{ | { | ||||
@@ -101,8 +104,10 @@ namespace Learun.Application.TwoDevelopment.LR_Desktop | |||||
login(); | login(); | ||||
return; | return; | ||||
} | } | ||||
_redis.Write($"access_token", ((dynamic)refresh_res)?.access_token, TimeSpan.FromSeconds(200)); | |||||
_redis.Write($"refresh_token", ((dynamic)refresh_res)?.refresh_token, TimeSpan.FromSeconds(250)); | |||||
string atoken = ((dynamic)refresh_res)?.access_token; | |||||
string rtoken = ((dynamic)refresh_res)?.refresh_token; | |||||
_redis.Write($"access_token", atoken, TimeSpan.FromSeconds(200)); | |||||
_redis.Write($"refresh_token", rtoken, TimeSpan.FromSeconds(250)); | |||||
} | } | ||||
/// <summary> | /// <summary> | ||||
/// 校区基础数据 | /// 校区基础数据 | ||||