@@ -577,6 +577,28 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
return Success("操作成功"); | return Success("操作成功"); | ||||
} | } | ||||
/// <summary> | /// <summary> | ||||
///领取军训服装 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult IsGetMiliClothes(string keyValue, string status) | |||||
{ | |||||
stuInfoFreshIBLL.IsGetMiliClothes(keyValue, status); | |||||
return Success("操作成功"); | |||||
} | |||||
/// <summary> | |||||
///领取床上用品 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult IsGetBedding(string keyValue, string status) | |||||
{ | |||||
stuInfoFreshIBLL.IsGetBedding(keyValue, status); | |||||
return Success("操作成功"); | |||||
} | |||||
/// <summary> | |||||
///缴费 | ///缴费 | ||||
/// </summary> | /// </summary> | ||||
/// <returns></returns> | /// <returns></returns> | ||||
@@ -37,10 +37,19 @@ | |||||
</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_view" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 查看</a> | <a id="lr_view" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 查看</a> | ||||
<a id="lr_get" class="btn btn-default"><i class="fa fa-plus"></i> 领取钥匙</a> | |||||
<a id="lr_cancelGet" class="btn btn-default"><i class="fa fa-trash-o"></i> 设置未领取钥匙</a> | |||||
<a id="lr_getCard" class="btn btn-default"><i class="fa fa-plus"></i> 领取校园卡</a> | |||||
<a id="lr_cancelGetCard" class="btn btn-default"><i class="fa fa-trash-o"></i> 设置未领取校园卡</a> | |||||
<a id="lr_more" class="btn btn-default dropdown-toggle" data-toggle="dropdown" aria-expanded="false"> | |||||
<i class="fa fa-reorder"></i> <span class="lrlt">更多</span><span class="caret"></span> | |||||
</a> | |||||
<ul class="dropdown-menu pull-right"> | |||||
<li id="lr_get"><a><i></i> <span class="lrlt">领取钥匙</span></a></li> | |||||
<li id="lr_cancelGet"><a><i></i> <span class="lrlt">设置未领取钥匙</span></a></li> | |||||
<li id="lr_getCard"><a><i></i> <span class="lrlt">领取校园卡</span></a></li> | |||||
<li id="lr_cancelGetCard"><a><i></i> <span class="lrlt">设置未领取校园卡</span></a></li> | |||||
<li id="lr_getMiliClothes"><a><i></i> <span class="lrlt">领军训服装</span></a></li> | |||||
<li id="lr_cancelGetMiliClothes"><a><i></i> <span class="lrlt">设置未领军训服装</span></a></li> | |||||
<li id="lr_getBedding"><a><i></i> <span class="lrlt">领床上用品</span></a></li> | |||||
<li id="lr_cancelGetBedding"><a><i></i> <span class="lrlt">设置未领床上用品</span></a></li> | |||||
</ul> | |||||
</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_deleteBed" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除宿舍信息</a> | <a id="lr_deleteBed" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除宿舍信息</a> | ||||
@@ -153,6 +153,79 @@ var bootstrap = function ($, learun) { | |||||
}); | }); | ||||
} | } | ||||
}); | }); | ||||
// 领军训服装 | |||||
$('#lr_getMiliClothes').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
selectedRow = $('#gridtable').jfGridGet('rowdata'); | |||||
if (learun.checkrow(keyValue)) { | |||||
if (selectedRow.GetMiliClothesStatus == "1") { | |||||
learun.alert.warning("当前新生已领取军训服装!"); | |||||
return; | |||||
} | |||||
learun.layerConfirm('是否确认领取军训服装!', function (res) { | |||||
if (res) { | |||||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetMiliClothes', { keyValue: keyValue, status: 1 }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 设置未领军训服装 | |||||
$('#lr_cancelGetMiliClothes').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
selectedRow = $('#gridtable').jfGridGet('rowdata'); | |||||
if (learun.checkrow(keyValue)) { | |||||
if (selectedRow.GetMiliClothesStatus != "1") { | |||||
learun.alert.warning("当前新生暂未领取军训服装!"); | |||||
return; | |||||
} | |||||
learun.layerConfirm('是否设置新生未领取军训服装!', function (res) { | |||||
if (res) { | |||||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetMiliClothes', { keyValue: keyValue, status: 0 }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 领床上用品 | |||||
$('#lr_getBedding').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
selectedRow = $('#gridtable').jfGridGet('rowdata'); | |||||
if (learun.checkrow(keyValue)) { | |||||
if (selectedRow.GetBeddingStatus == "1") { | |||||
learun.alert.warning("当前新生已领取床上用品!"); | |||||
return; | |||||
} | |||||
learun.layerConfirm('是否确认领取床上用品!', function (res) { | |||||
if (res) { | |||||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetBedding', { keyValue: keyValue, status: 1 }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 设置未领床上用品 | |||||
$('#lr_cancelGetBedding').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
selectedRow = $('#gridtable').jfGridGet('rowdata'); | |||||
if (learun.checkrow(keyValue)) { | |||||
if (selectedRow.GetBeddingStatus != "1") { | |||||
learun.alert.warning("当前新生暂未领取床上用品!"); | |||||
return; | |||||
} | |||||
learun.layerConfirm('是否设置新生未领取床上用品!', function (res) { | |||||
if (res) { | |||||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/StuInfoFresh/IsGetBedding', { keyValue: keyValue, status: 0 }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | }, | ||||
initGird: function () { | initGird: function () { | ||||
$('#gridtable').lrAuthorizeJfGrid({ | $('#gridtable').lrAuthorizeJfGrid({ | ||||
@@ -209,6 +282,20 @@ var bootstrap = function ($, learun) { | |||||
} | } | ||||
}, | }, | ||||
{ label: '领取校园卡时间', name: 'GetCardDate', width: 130, align: "left" }, | { label: '领取校园卡时间', name: 'GetCardDate', width: 130, align: "left" }, | ||||
{ | |||||
label: '领军训服装状态', name: 'GetMiliClothesStatus', width: 100, align: "left", formatter: function (value) { | |||||
return value == 1 ? "<span class=\"label label-success\">已领取</span>" : "<span class=\"label label-warning\">未领取</span>"; | |||||
} | |||||
}, | |||||
{ label: '领军训服装时间', name: 'GetMiliClothesDate', width: 130, align: "left" }, | |||||
{ | |||||
label: '领床上用品状态', name: 'GetBeddingStatus', width: 100, align: "left", formatter: function (value) { | |||||
return value == 1 ? "<span class=\"label label-success\">已领取</span>" : "<span class=\"label label-warning\">未领取</span>"; | |||||
} | |||||
}, | |||||
{ label: '领床上用品时间', name: 'GetBeddingDate', width: 130, align: "left" }, | |||||
{ | { | ||||
label: '系', name: 'DeptNo', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | label: '系', name: 'DeptNo', width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | ||||
learun.clientdata.getAsync('custmerData', { | learun.clientdata.getAsync('custmerData', { | ||||
@@ -600,6 +600,54 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
} | } | ||||
} | } | ||||
/// <summary> | |||||
/// 领取军训服装 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
public void IsGetMiliClothes(string keyValue, string status) | |||||
{ | |||||
try | |||||
{ | |||||
stuInfoFreshService.IsGetMiliClothes(keyValue, status); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 领取床上用品 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
public void IsGetBedding(string keyValue, string status) | |||||
{ | |||||
try | |||||
{ | |||||
stuInfoFreshService.IsGetBedding(keyValue, status); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | /// <summary> | ||||
/// 缴费 | /// 缴费 | ||||
/// <param name="keyValue">主键</param> | /// <param name="keyValue">主键</param> | ||||
@@ -644,6 +644,32 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
/// </summary> | /// </summary> | ||||
[Column("BANKNO")] | [Column("BANKNO")] | ||||
public string BankNo { get; set; } | public string BankNo { get; set; } | ||||
/// <summary> | |||||
/// 领军训服装时间 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[Column("GETMILICLOTHESDATE")] | |||||
public DateTime? GetMiliClothesDate { get; set; } | |||||
/// <summary> | |||||
/// 领军训服装状态 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[Column("GETMILICLOTHESSTATUS")] | |||||
public string GetMiliClothesStatus { get; set; } | |||||
/// <summary> | |||||
/// 领床上用品时间 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[Column("GETBEDDINGDATE")] | |||||
public DateTime? GetBeddingDate { get; set; } | |||||
/// <summary> | |||||
/// 领床上用品状态 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
[Column("GETBEDDINGSTATUS")] | |||||
public string GetBeddingStatus { get; set; } | |||||
#endregion | #endregion | ||||
#region 扩展操作 | #region 扩展操作 | ||||
@@ -166,6 +166,20 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
/// <returns></returns> | /// <returns></returns> | ||||
void IsGetCard(string keyValue, string status); | void IsGetCard(string keyValue, string status); | ||||
/// <summary> | |||||
/// 领取军训服装 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
void IsGetMiliClothes(string keyValue, string status); | |||||
/// <summary> | |||||
/// 领取床上用品 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
void IsGetBedding(string keyValue, string status); | |||||
/// <summary> | /// <summary> | ||||
/// 缴费 | /// 缴费 | ||||
/// <param name="keyValue">主键</param> | /// <param name="keyValue">主键</param> | ||||
@@ -1104,6 +1104,66 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
} | } | ||||
} | } | ||||
/// <summary> | |||||
/// 领取军训服装 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
public void IsGetMiliClothes(string keyValue, string status) | |||||
{ | |||||
try | |||||
{ | |||||
if (status == "1")//领取 | |||||
{ | |||||
this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetMiliClothesStatus='1',GetMiliClothesDate='" + DateTime.Now + "' where ID='" + keyValue + "' "); | |||||
} | |||||
else | |||||
{ | |||||
this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetMiliClothesStatus='0',GetMiliClothesDate=null where ID='" + keyValue + "' "); | |||||
} | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 领取床上用品 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
public void IsGetBedding(string keyValue, string status) | |||||
{ | |||||
try | |||||
{ | |||||
if (status == "1")//领取 | |||||
{ | |||||
this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetBeddingStatus='1',GetBeddingDate='" + DateTime.Now + "' where ID='" + keyValue + "' "); | |||||
} | |||||
else | |||||
{ | |||||
this.BaseRepository("CollegeMIS").ExecuteBySql("update StuInfoFresh set GetBeddingStatus='0',GetBeddingDate=null where ID='" + keyValue + "' "); | |||||
} | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | /// <summary> | ||||
/// 缴费 | /// 缴费 | ||||
/// <param name="keyValue">主键</param> | /// <param name="keyValue">主键</param> | ||||