diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuEncourgement/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuEncourgement/Index.js
index 8b5acb4bb..d34ee22bd 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuEncourgement/Index.js
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuEncourgement/Index.js
@@ -7,15 +7,44 @@
var refreshGirdData;
var bootstrap = function ($, learun) {
"use strict";
+ var startTime;
+ var endTime;
var page = {
init: function () {
page.initGird();
page.bind();
},
bind: function () {
+ // 时间搜索框
+ $('#datesearch').lrdate({
+ dfdata: [
+ { name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }
+ ],
+ // 月
+ mShow: false,
+ premShow: false,
+ // 季度
+ jShow: false,
+ prejShow: false,
+ // 年
+ ysShow: false,
+ yxShow: false,
+ preyShow: false,
+ yShow: false,
+ // 默认
+ dfvalue: '1',
+ selectfn: function (begin, end) {
+ startTime = begin;
+ endTime = end;
+ page.search();
+ }
+ });
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
- }, 300, 400);
+ }, 200, 400);
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
@@ -68,12 +97,12 @@ var bootstrap = function ($, learun) {
$('#gridtable').lrAuthorizeJfGrid({
url: top.$.rootUrl + '/EducationalAdministration/StuEncourgement/GetPageList',
headData: [
- { label: "学号", name: "StuNo", width: 100, align: "left"},
- { label: "姓名", name: "StuName", width: 100, align: "left"},
- { label: "奖励名称", name: "EncourgeName", width: 100, align: "left"},
- { label: "奖励原因", name: "Reason", width: 100, align: "left"},
- { label: "奖励金额", name: "Fee", width: 100, align: "left"},
- { label: "奖励日期", name: "EncourgeDate", width: 100, align: "left"},
+ { label: "学号", name: "StuNo", width: 200, align: "left"},
+ { label: "姓名", name: "StuName", width: 200, align: "left"},
+ { label: "奖励名称", name: "EncourgeName", width: 200, align: "left"},
+ { label: "奖励原因", name: "Reason", width: 200, align: "left"},
+ { label: "奖励金额", name: "Fee", width: 200, align: "left"},
+ { label: "奖励日期", name: "EncourgeDate", width: 200, align: "left"},
],
mainId:'ID',
isPage: true
@@ -82,6 +111,8 @@ var bootstrap = function ($, learun) {
},
search: function (param) {
param = param || {};
+ param.StartTime = startTime;
+ param.EndTime = endTime;
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) });
}
};
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.cshtml
index 67c53874f..bc90ff2f4 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.cshtml
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.cshtml
@@ -7,6 +7,9 @@
diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.js
index 9562bac1f..bfd3fa9f5 100644
--- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.js
+++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/StuPunishment/Index.js
@@ -7,15 +7,44 @@
var refreshGirdData;
var bootstrap = function ($, learun) {
"use strict";
+ var startTime;
+ var endTime;
var page = {
init: function () {
page.initGird();
page.bind();
},
bind: function () {
+ // 时间搜索框
+ $('#datesearch').lrdate({
+ dfdata: [
+ { name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } },
+ { name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }
+ ],
+ // 月
+ mShow: false,
+ premShow: false,
+ // 季度
+ jShow: false,
+ prejShow: false,
+ // 年
+ ysShow: false,
+ yxShow: false,
+ preyShow: false,
+ yShow: false,
+ // 默认
+ dfvalue: '1',
+ selectfn: function (begin, end) {
+ startTime = begin;
+ endTime = end;
+ page.search();
+ }
+ });
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) {
page.search(queryJson);
- }, 300, 400);
+ }, 200, 400);
$('#PunishNo').lrDataItemSelect({ code: 'Punishment' });
// 刷新
@@ -137,6 +166,8 @@ var bootstrap = function ($, learun) {
},
search: function (param) {
param = param || {};
+ param.StartTime = startTime;
+ param.EndTime = endTime;
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
}
};
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/MealCardRunTab/MealCardRunTabService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/MealCardRunTab/MealCardRunTabService.cs
index f4447cc5e..c274f584c 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/MealCardRunTab/MealCardRunTabService.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/MealCardRunTab/MealCardRunTabService.cs
@@ -220,7 +220,9 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime);
strSql.Append(" AND ( t.occurTime >= @startTime AND t.occurTime <= @endTime ) ");
}
- return this.BaseRepository("CollegeMIS").FindList
(strSql.ToString(), dp, pagination);
+ var data = this.BaseRepository("CollegeMIS").FindList(strSql.ToString(), dp, pagination);
+ data = data.OrderByDescending(x => x.centralTm);
+ return data;
}
catch (Exception ex)
{
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuEncourgement/StuEncourgementService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuEncourgement/StuEncourgementService.cs
index 3f3de8b01..b45777feb 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuEncourgement/StuEncourgementService.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuEncourgement/StuEncourgementService.cs
@@ -82,12 +82,12 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
dp.Add("EncourgeName", "%" + queryParam["EncourgeName"].ToString() + "%", DbType.String);
strSql.Append(" AND t.EncourgeName Like @EncourgeName ");
}
- if (!queryParam["EncourgeDate"].IsEmpty())
+ if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty())
{
- dp.Add("EncourgeDate", queryParam["EncourgeDate"].ToString(), DbType.String);
- strSql.Append(" AND t.EncourgeDate = @EncourgeDate ");
+ dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime);
+ dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime);
+ strSql.Append(" AND ( t.EncourgeDate >= @startTime AND t.EncourgeDate <= @endTime ) ");
}
-
return this.BaseRepository("CollegeMIS").FindList(strSql.ToString(), dp, pagination);
}
catch (Exception ex)
diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuPunishment/StuPunishmentService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuPunishment/StuPunishmentService.cs
index 2ec5e0fa2..65e555839 100644
--- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuPunishment/StuPunishmentService.cs
+++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/StuPunishment/StuPunishmentService.cs
@@ -77,10 +77,11 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration
dp.Add("PunishNo", queryParam["PunishNo"].ToString(), DbType.String);
strSql.Append(" AND t.PunishNo = @PunishNo ");
}
- if (!queryParam["PunishDate"].IsEmpty())
+ if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty())
{
- dp.Add("PunishDate", queryParam["PunishDate"].ToString(), DbType.String);
- strSql.Append(" AND t.PunishDate = @PunishDate ");
+ dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime);
+ dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime);
+ strSql.Append(" AND ( t.PunishDate >= @startTime AND t.PunishDate <= @endTime ) ");
}
return this.BaseRepository("CollegeMIS").FindList(strSql.ToString(), dp, pagination);
}