@@ -38,6 +38,25 @@ namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers | |||||
{ | { | ||||
return View(); | return View(); | ||||
} | } | ||||
/// <summary> | |||||
/// 表单页 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult IndexDorm() | |||||
{ | |||||
return View(); | |||||
} | |||||
/// <summary> | |||||
/// 全部 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult IndexAll() | |||||
{ | |||||
return View(); | |||||
} | |||||
#endregion | #endregion | ||||
#region 获取数据 | #region 获取数据 | ||||
@@ -256,6 +256,19 @@ namespace Learun.Application.Web.Areas.LogisticsManagement.Controllers | |||||
return Success(jsonData); | return Success(jsonData); | ||||
} | } | ||||
/// <summary> | |||||
/// 获取床位数据 | |||||
/// <summary> | |||||
/// <param name="RoomId">查询参数</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetDormStu(string keyValue) | |||||
{ | |||||
var data = accommodationIBLL.GetDromStu(keyValue).OrderBy(x => x.Class); | |||||
return Success(data); | |||||
} | |||||
/// <summary> | /// <summary> | ||||
/// 获取床位数据 | /// 获取床位数据 | ||||
/// <summary> | /// <summary> | ||||
@@ -4,43 +4,55 @@ | |||||
} | } | ||||
<div class="lr-form-wrap"> | <div class="lr-form-wrap"> | ||||
<div id="form"> | <div id="form"> | ||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">宿舍楼</div> | |||||
<div id="Dormitory"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">单元</div> | |||||
<div id="Unit"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">楼层</div> | |||||
<div id="Floor"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">宿舍<font face="宋体">*</font></div> | |||||
<div id="RId" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">专业部<font face="宋体">*</font></div> | |||||
<div id="DeptNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">专业<font face="宋体">*</font></div> | |||||
<div id="MajorNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
@*<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">宿舍楼</div> | |||||
<div id="Dormitory"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">单元</div> | |||||
<div id="Unit"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">楼层</div> | |||||
<div id="Floor"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">宿舍<font face="宋体">*</font></div> | |||||
<div id="RId" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">专业部<font face="宋体">*</font></div> | |||||
<div id="DeptNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">专业<font face="宋体">*</font></div> | |||||
<div id="MajorNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">班级<font face="宋体">*</font></div> | |||||
<div id="ClassNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
</div>*@ | |||||
<div class="col-xs-12 lr-form-item" data-table="Acc_DailyAssess"> | |||||
<div class="lr-form-item-title">选择学生<font face="宋体">*</font></div> | |||||
<div id="NewStuNo"></div> | |||||
</div> | </div> | ||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | <div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | ||||
<div class="lr-form-item-title">班级<font face="宋体">*</font></div> | |||||
<div id="ClassNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
<div class="lr-form-item-title">学号<font face="宋体">*</font></div> | |||||
<input id="StuNo" type="text" class="form-control" readonly="readonly" isvalid="yes" checkexpession="NotNull" /> | |||||
</div> | </div> | ||||
<div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | <div class="col-xs-6 lr-form-item" data-table="Acc_DailyAssess"> | ||||
<div class="lr-form-item-title">学生<font face="宋体">*</font></div> | |||||
<div id="StuNo" isvalid="yes" checkexpession="NotNull"></div> | |||||
<div class="lr-form-item-title">姓名<font face="宋体">*</font></div> | |||||
<input id="StuName" type="text" class="form-control" readonly="readonly" isvalid="yes" checkexpession="NotNull" /> | |||||
<input id="Dormitory" hidden="Dormitory" /> | |||||
<input id="Unit" hidden="Unit" /> | |||||
<input id="Floor" hidden="Floor" /> | |||||
<input id="RId" hidden="RId" /> | |||||
<input id="BuildId" hidden="hidden" /> | |||||
</div> | </div> | ||||
</div> | </div> | ||||
<div class="col-xs-12 lr-form-item" data-table="Acc_DailyAssess"> | <div class="col-xs-12 lr-form-item" data-table="Acc_DailyAssess"> | ||||
<div class="lr-form-item-title">日期<font face="宋体">*</font></div> | <div class="lr-form-item-title">日期<font face="宋体">*</font></div> | ||||
<input id="Date" type="text" isvalid="yes" checkexpession="NotNull" class="form-control lr-input-wdatepicker" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm:ss' })" /> | |||||
<input id="Date" type="text" isvalid="yes" checkexpession="NotNull" class="form-control lr-input-wdatepicker" isvalid="yes" checkexpession="NotNull" data-dateFmt="yyyy-MM-dd HH:mm:ss" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm:ss',onpicked: function () { $('#Date').trigger('change'); } })" /> | |||||
</div> | </div> | ||||
<div class="col-xs-12 lr-form-item" data-table="Acc_DailyAssess"> | <div class="col-xs-12 lr-form-item" data-table="Acc_DailyAssess"> | ||||
<div class="lr-form-item-title">卫生奖分</div> | <div class="lr-form-item-title">卫生奖分</div> | ||||
@@ -6,6 +6,11 @@ | |||||
*/ | */ | ||||
var acceptClick; | var acceptClick; | ||||
var keyValue = request('keyValue'); | var keyValue = request('keyValue'); | ||||
var HkeyValue = request('HkeyValue'); | |||||
var Dormitory = request('Dormitory'); | |||||
var Unit = request('Unit'); | |||||
var Floor = request('Floor'); | |||||
var RId = request('RId'); | |||||
var bootstrap = function ($, learun) { | var bootstrap = function ($, learun) { | ||||
"use strict"; | "use strict"; | ||||
var selectedRow = learun.frameTab.currentIframe().selectedRow; | var selectedRow = learun.frameTab.currentIframe().selectedRow; | ||||
@@ -16,113 +21,127 @@ var bootstrap = function ($, learun) { | |||||
page.initData(); | page.initData(); | ||||
}, | }, | ||||
bind: function () { | bind: function () { | ||||
$('#Dormitory').lrDataSourceSelect({ | |||||
code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { | |||||
if (item) { | |||||
$('#Unit').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Unit').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#Floor').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Floor').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#RId').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#RId').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
allowSearch: true | |||||
}); | |||||
$('#DeptNo').lrselect({ | |||||
//$('#Dormitory').lrDataSourceSelect({ | |||||
// code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { | |||||
// if (item) { | |||||
// $('#Unit').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#Unit').lrselect({ | |||||
// text: 'name', | |||||
// value: 'id', | |||||
// select: function (item) { | |||||
// if (item) { | |||||
// $('#Floor').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#Floor').lrselect({ | |||||
// text: 'name', | |||||
// value: 'id', | |||||
// select: function (item) { | |||||
// if (item) { | |||||
// $('#RId').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#RId').lrselect({ | |||||
// text: 'name', | |||||
// value: 'id', | |||||
// allowSearch: true | |||||
//}); | |||||
//$('#DeptNo').lrselect({ | |||||
// allowSearch: true, | |||||
// value: "deptno", | |||||
// text: "deptname", | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', | |||||
// select: function (item) { | |||||
// if (item) { | |||||
// $('#MajorNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
// param: { strWhere: "DeptNo='" + item.deptno + "' AND CheckMark=1" } | |||||
// }); | |||||
// } else { | |||||
// $('#MajorNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
// param: { strWhere: "1=1 AND CheckMark=1" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#MajorNo').lrselect({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
// value: "majorno", | |||||
// text: "majorname", | |||||
// param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
// select: function (item) { | |||||
// if (item) { | |||||
// $('#ClassNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
// param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1" } | |||||
// }); | |||||
// } else { | |||||
// $('#ClassNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
// param: { strWhere: "1=1 AND CheckMark=1" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#ClassNo').lrselect({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
// param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
// value: "classno", | |||||
// text: "classname", | |||||
// select: function (item) { | |||||
// if (item) { | |||||
// $('#StuNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||||
// param: { strWhere: "classno='" + item.classno + "'" } | |||||
// }); | |||||
// } else { | |||||
// $('#StuNo').lrselectRefresh({ | |||||
// allowSearch: true, | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||||
// param: { strWhere: "1=1" } | |||||
// }); | |||||
// } | |||||
// } | |||||
//}); | |||||
//$('#StuNo').lrDataSourceSelect({ code: 'StuInfoBasic', value: 'stuno', text: 'stuname' }); | |||||
$('#NewStuNo').lrselect({ | |||||
placeholder: "请选择学生", | |||||
allowSearch: true, | allowSearch: true, | ||||
value: "deptno", | |||||
text: "deptname", | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Accommodation/GetDormStu?keyValue=' + HkeyValue, | |||||
value: 'StuNo', | |||||
text: 'StuName', | |||||
select: function (item) { | select: function (item) { | ||||
if (item) { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
param: { strWhere: "DeptNo='" + item.deptno + "' AND CheckMark=1" } | |||||
}); | |||||
} else { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
param: { strWhere: "1=1 AND CheckMark=1" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#MajorNo').lrselect({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
value: "majorno", | |||||
text: "majorname", | |||||
param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#ClassNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1" } | |||||
}); | |||||
} else { | |||||
$('#ClassNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "1=1 AND CheckMark=1" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#ClassNo').lrselect({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
value: "classno", | |||||
text: "classname", | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#StuNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||||
param: { strWhere: "classno='" + item.classno + "'" } | |||||
}); | |||||
} else { | |||||
$('#StuNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=StuInfoBasic', | |||||
param: { strWhere: "1=1" } | |||||
}); | |||||
} | |||||
$("#StuName").val(item.StuName); | |||||
$("#StuNo").val(item.StudentID); | |||||
$("#BuildId").val(HkeyValue); | |||||
$("#Dormitory").val(Dormitory); | |||||
$("#Unit").val(Unit); | |||||
$("#Floor").val(Floor); | |||||
$("#RId").val(RId); | |||||
} | } | ||||
}); | }); | ||||
$('#StuNo').lrDataSourceSelect({ code: 'StuInfoBasic', value: 'stuno', text: 'stuname' }); | |||||
$('#Files').lrUploader(); | $('#Files').lrUploader(); | ||||
}, | }, | ||||
initData: function () { | initData: function () { | ||||
@@ -13,7 +13,7 @@ | |||||
<div class="lr-layout-tool-item"> | <div class="lr-layout-tool-item"> | ||||
<div id="multiple_condition_query"> | <div id="multiple_condition_query"> | ||||
<div class="lr-query-formcontent"> | <div class="lr-query-formcontent"> | ||||
<div class="col-xs-6 lr-form-item"> | |||||
@*<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">宿舍楼</div> | <div class="lr-form-item-title">宿舍楼</div> | ||||
<div id="Dormitory"></div> | <div id="Dormitory"></div> | ||||
</div> | </div> | ||||
@@ -28,7 +28,7 @@ | |||||
<div class="col-xs-6 lr-form-item"> | <div class="col-xs-6 lr-form-item"> | ||||
<div class="lr-form-item-title">宿舍</div> | <div class="lr-form-item-title">宿舍</div> | ||||
<div id="RId" ></div> | <div id="RId" ></div> | ||||
</div> | |||||
</div>*@ | |||||
<div class="col-xs-12 lr-form-item"> | <div class="col-xs-12 lr-form-item"> | ||||
<div class="lr-form-item-title">专业部</div> | <div class="lr-form-item-title">专业部</div> | ||||
<div id="DeptNo"></div> | <div id="DeptNo"></div> | ||||
@@ -51,16 +51,14 @@ | |||||
</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> | |||||
</div> | |||||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i>刷新</a> | |||||
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i> 新增</a> | <a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i> 新增</a> | ||||
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 编辑</a> | <a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i> 编辑</a> | ||||
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除</a> | <a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></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_addQuickly" class="btn btn-default"><i class="fa fa-plus"></i> 快速新增</a> | <a id="lr_addQuickly" class="btn btn-default"><i class="fa fa-plus"></i> 快速新增</a> | ||||
</div> | |||||
</div>*@ | |||||
</div> | </div> | ||||
</div> | </div> | ||||
<div class="lr-layout-body" id="gridtable"></div> | <div class="lr-layout-body" id="gridtable"></div> | ||||
@@ -6,6 +6,11 @@ | |||||
*/ | */ | ||||
var selectedRow; | var selectedRow; | ||||
var refreshGirdData; | var refreshGirdData; | ||||
var HkeyValue = request('keyValue'); | |||||
var Dormitory = request('Dormitory'); | |||||
var Unit = request('Unit'); | |||||
var Floor = request('Floor'); | |||||
var RId = request('RId'); | |||||
var bootstrap = function ($, learun) { | var bootstrap = function ($, learun) { | ||||
"use strict"; | "use strict"; | ||||
var startTime; | var startTime; | ||||
@@ -50,45 +55,45 @@ var bootstrap = function ($, learun) { | |||||
$('#lr_refresh').on('click', function () { | $('#lr_refresh').on('click', function () { | ||||
location.reload(); | location.reload(); | ||||
}); | }); | ||||
$('#Dormitory').lrDataSourceSelect({ | |||||
code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { | |||||
if (item) { | |||||
$('#Unit').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Unit').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#Floor').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Floor').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#RId').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#RId').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
allowSearch: true | |||||
}); | |||||
//$('#Dormitory').lrDataSourceSelect({ | |||||
// code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { | |||||
// if (item) { | |||||
// $('#Unit').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
//}); | |||||
//} | |||||
//} | |||||
//}); | |||||
//$('#Unit').lrselect({ | |||||
// text: 'name', | |||||
//value: 'id', | |||||
//select: function (item) { | |||||
// if (item) { | |||||
// $('#Floor').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
//}); | |||||
//} | |||||
//} | |||||
//}); | |||||
//$('#Floor').lrselect({ | |||||
// text: 'name', | |||||
//value: 'id', | |||||
//select: function (item) { | |||||
// if (item) { | |||||
// $('#RId').lrselectRefresh({ | |||||
// url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
// param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
//}); | |||||
//} | |||||
//} | |||||
//}); | |||||
//$('#RId').lrselect({ | |||||
// text: 'name', | |||||
//value: 'id', | |||||
//allowSearch: true | |||||
//}); | |||||
$('#DeptNo').lrselect({ | $('#DeptNo').lrselect({ | ||||
allowSearch: true, | allowSearch: true, | ||||
value: "deptno", | value: "deptno", | ||||
@@ -147,7 +152,7 @@ var bootstrap = function ($, learun) { | |||||
learun.layerForm({ | learun.layerForm({ | ||||
id: 'form', | id: 'form', | ||||
title: '新增', | title: '新增', | ||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Form', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Form?HkeyValue=' + HkeyValue + '&Dormitory=' + Dormitory + '&Unit=' + Unit + '&Floor=' + Floor + '&RId=' + RId, | |||||
width: 800, | width: 800, | ||||
height: 600, | height: 600, | ||||
callBack: function (id) { | callBack: function (id) { | ||||
@@ -163,7 +168,7 @@ var bootstrap = function ($, learun) { | |||||
learun.layerForm({ | learun.layerForm({ | ||||
id: 'form', | id: 'form', | ||||
title: '编辑', | title: '编辑', | ||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Form?keyValue=' + keyValue, | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Form?keyValue=' + keyValue + '&HkeyValue=' + HkeyValue + '&Dormitory=' + Dormitory + '&Unit=' + Unit + '&Floor=' + Floor + '&RId=' + RId, | |||||
width: 800, | width: 800, | ||||
height: 600, | height: 600, | ||||
callBack: function (id) { | callBack: function (id) { | ||||
@@ -322,7 +327,8 @@ var bootstrap = function ($, learun) { | |||||
{ label: "奖扣分原因", name: "Reason", width: 200, align: "left" }, | { label: "奖扣分原因", name: "Reason", width: 200, align: "left" }, | ||||
], | ], | ||||
mainId: 'Id', | mainId: 'Id', | ||||
isPage: true | |||||
isPage: true, | |||||
sidx: 'Date desc' | |||||
}); | }); | ||||
page.search(); | page.search(); | ||||
}, | }, | ||||
@@ -330,6 +336,7 @@ var bootstrap = function ($, learun) { | |||||
param = param || {}; | param = param || {}; | ||||
param.StartTime = startTime; | param.StartTime = startTime; | ||||
param.EndTime = endTime; | param.EndTime = endTime; | ||||
param.SqlParameter = "and BuildId ='" + HkeyValue + "'"; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | $('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | ||||
} | } | ||||
}; | }; | ||||
@@ -0,0 +1,65 @@ | |||||
@{ | |||||
ViewBag.Title = "寝室日常考核管理"; | |||||
Layout = "~/Views/Shared/_Index.cshtml"; | |||||
} | |||||
<div class="lr-layout "> | |||||
<div class="lr-layout-center"> | |||||
<div class="lr-layout-wrap lr-layout-wrap-notitle "> | |||||
<div class="lr-layout-tool"> | |||||
<div class="lr-layout-tool-left"> | |||||
<div class="lr-layout-tool-item"> | |||||
<div id="datesearch"></div> | |||||
</div> | |||||
<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> | |||||
<div id="Dormitory"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">单元</div> | |||||
<div id="Unit"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">楼层</div> | |||||
<div id="Floor"></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">宿舍</div> | |||||
<div id="RId" ></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">专业部</div> | |||||
<div id="DeptNo"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">专业</div> | |||||
<div id="MajorNo"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">班级</div> | |||||
<div id="ClassNo"></div> | |||||
</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> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-tool-right"> | |||||
<div class=" btn-group btn-group-sm"> | |||||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||||
</div> | |||||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||||
<a id="lr_addQuickly" class="btn btn-default"><i class="fa fa-plus"></i> 快速新增</a> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-body" id="gridtable"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/Acc_DailyAssess/IndexAll.js") |
@@ -0,0 +1,295 @@ | |||||
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) | |||||
* Copyright (c) 2013-2018 北京泉江科技有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2020-08-11 16:55 | |||||
* 描 述:寝室日常考核管理 | |||||
*/ | |||||
var selectedRow; | |||||
var refreshGirdData; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var startTime; | |||||
var endTime; | |||||
var page = { | |||||
init: function () { | |||||
page.initGird(); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 300, 400); | |||||
// 时间搜索框 | |||||
$('#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(); | |||||
} | |||||
}); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
$('#Dormitory').lrDataSourceSelect({ | |||||
code: 'Acc_DormitoryData', value: 'id', text: 'name', select: function (item) { | |||||
if (item) { | |||||
$('#Unit').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_UnitData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Unit').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#Floor').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_FloorData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Floor').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#RId').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: 'Acc_RoomData', strWhere: "ParentID='" + item.id + "' order by name" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#RId').lrselect({ | |||||
text: 'name', | |||||
value: 'id', | |||||
allowSearch: true | |||||
}); | |||||
$('#DeptNo').lrselect({ | |||||
allowSearch: true, | |||||
value: "deptno", | |||||
text: "deptname", | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
param: { strWhere: "DeptNo='" + item.deptno + "' AND CheckMark=1" } | |||||
}); | |||||
} else { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
param: { strWhere: "1=1 AND CheckMark=1" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#MajorNo').lrselect({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdMajorInfo', | |||||
value: "majorno", | |||||
text: "majorname", | |||||
param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#ClassNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "majorno='" + item.majorno + "' AND CheckMark=1" } | |||||
}); | |||||
} else { | |||||
$('#ClassNo').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "1=1 AND CheckMark=1" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#ClassNo').lrselect({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=bjsj', | |||||
param: { strWhere: "1=1 AND CheckMark=1" }, | |||||
value: "classno", | |||||
text: "classname" | |||||
}); | |||||
// 快速新增 | |||||
$('#lr_addQuickly').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||||
if (learun.checkrow(keyValue)) { | |||||
selectedRow = $('#gridtable').jfGridGet('rowdata'); | |||||
//console.log(selectedRow); | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '快速新增', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Form', | |||||
width: 800, | |||||
height: 600, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/GetPageList', | |||||
headData: [ | |||||
{ | |||||
label: "专业部", name: "DeptNo", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdDeptInfo', | |||||
key: value, | |||||
keyId: 'deptno', | |||||
callback: function (_data) { | |||||
callback(_data['deptname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "专业", name: "MajorNo", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo', | |||||
key: value, | |||||
keyId: 'majorno', | |||||
callback: function (_data) { | |||||
callback(_data['majorname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "班级", name: "ClassNo", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', | |||||
key: value, | |||||
keyId: 'classno', | |||||
callback: function (_data) { | |||||
callback(_data['classname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "宿舍楼", name: "Dormitory", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_DormitoryData', | |||||
key: value, | |||||
keyId: 'id', | |||||
callback: function (_data) { | |||||
callback(_data['name']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "单元", name: "Unit", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_UnitData', | |||||
key: value, | |||||
keyId: 'id', | |||||
callback: function (_data) { | |||||
callback(_data['name']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "楼层", name: "Floor", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_FloorData', | |||||
key: value, | |||||
keyId: 'id', | |||||
callback: function (_data) { | |||||
callback(_data['name']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "寝室号", name: "RId", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'Acc_RoomData', | |||||
key: value, | |||||
keyId: 'id', | |||||
callback: function (_data) { | |||||
callback(_data['name']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "学生姓名", name: "StuNo", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'StuInfoBasic', | |||||
key: value, | |||||
keyId: 'stuno', | |||||
callback: function (_data) { | |||||
callback(_data['stuname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ label: "日期", name: "Date", width: 130, align: "left" }, | |||||
{ label: "卫生奖分", name: "AddScoreHealth", width: 100, align: "left" }, | |||||
{ label: "卫生扣分", name: "MinusScoreHealth", width: 100, align: "left" }, | |||||
{ label: "纪律奖分", name: "AddScore", width: 100, align: "left" }, | |||||
{ label: "纪律扣分", name: "MinusScore", width: 100, align: "left" }, | |||||
{ label: "奖扣分原因", name: "Reason", width: 200, align: "left" }, | |||||
], | |||||
mainId: 'Id', | |||||
isPage: true, | |||||
sidx: 'Date desc' | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
param.StartTime = startTime; | |||||
param.EndTime = endTime; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function () { | |||||
page.search(); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,80 @@ | |||||
@{ | |||||
ViewBag.Title = "寝室日常"; | |||||
Layout = "~/Views/Shared/_Index.cshtml"; | |||||
} | |||||
<div class="lr-layout lr-layout-left-center" id="lr_layout"> | |||||
<div class="lr-layout-left"> | |||||
<div class="lr-layout-wrap"> | |||||
<div class="lr-layout-title lrlt "> | |||||
树形列表 | |||||
<a id="tree_refresh" onmouseover="this.style.cursor='hand'">刷新</a> | |||||
</div> | |||||
<div id="dataTree" class="lr-layout-body"></div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-center"> | |||||
<div class="lr-layout-wrap "> | |||||
<div class="lr-layout-title"> | |||||
<span id="titleinfo" class="lrlt">列表信息</span> | |||||
</div> | |||||
<div class="lr-layout-tool"> | |||||
<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="Name" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">宿舍楼</div> | |||||
<div id="ApartmentId"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">单元</div> | |||||
<div id="UnitId"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">楼层</div> | |||||
<div id="FloorId"></div> | |||||
</div> | |||||
@*<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">类别</div> | |||||
<input id="BuildType" type="text" class="form-control" /> | |||||
</div>*@ | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">系</div> | |||||
<div id="Dept"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">专业</div> | |||||
<div id="Major"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">班级</div> | |||||
<div id="Class"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">性别</div> | |||||
<div id="Sex"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-tool-right"> | |||||
<div class=" btn-group btn-group-sm"> | |||||
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a> | |||||
</div> | |||||
<div class=" btn-group btn-group-sm" learun-authorize="yes"> | |||||
<a id="lr_view" class="btn btn-default"><i class="fa fa-plus"></i> 查看</a> | |||||
<a id="lr_viewall" class="btn btn-default"><i class="fa fa-plus"></i> 查看全部</a> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-body" id="gridtable"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/LogisticsManagement/Views/Acc_DailyAssess/IndexDorm.js") |
@@ -0,0 +1,374 @@ | |||||
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) | |||||
* Copyright (c) 2013-2018 北京泉江科技有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2019-04-26 15:02 | |||||
* 描 述:学生宿舍管理 | |||||
*/ | |||||
var refreshGirdData; | |||||
var selectedParent = {}; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
page.initTree(); | |||||
page.initGird(); | |||||
page.search({ ParentID: '' }); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 420, 400); | |||||
//宿舍楼 | |||||
$('#ApartmentId').lrselect({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=DormitoryInfo', | |||||
param: { strWhere: " BuildType='1' order by Name asc" }, | |||||
value: "id", | |||||
text: "name", | |||||
select: function (item) { | |||||
if (!!item) { | |||||
//单元 | |||||
$('#UnitId').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=DormitoryInfo', | |||||
param: { strWhere: " BuildType='2' and ApartmentId='" + item.id + "'" }, | |||||
value: "id", | |||||
text: "name", | |||||
select: function (item) { | |||||
if (!!item) { | |||||
//楼层 | |||||
$('#FloorId').lrselectRefresh({ | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=DormitoryInfo', | |||||
param: { strWhere: " BuildType='3' and UnitId='" + item.id + "'" }, | |||||
value: "id", | |||||
text: "name" | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#UnitId').lrselect({ allowSearch: true }); | |||||
$('#FloorId').lrselect({ allowSearch: true }); | |||||
$('#Sex').lrDataItemSelect({ code: 'usersex' }); | |||||
//.lrRadioCheckbox({ | |||||
// type: 'radio', | |||||
// code: 'usersex', | |||||
//}); | |||||
$('#Class').lrselect({ | |||||
value: "classno", | |||||
text: "classname" | |||||
}); | |||||
$('#Dept').lrselect({ | |||||
value: "deptno", | |||||
text: "deptname", | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#Major').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: "CdMajorInfo", strWhere: "DeptNo='" + item.deptno + "'" } | |||||
}); | |||||
} | |||||
else { | |||||
$('#Major').lrselectRefresh({ | |||||
url: "", | |||||
data: [] | |||||
}); | |||||
} | |||||
$('#Class').lrselectRefresh({ | |||||
url: "", | |||||
data: [] | |||||
}); | |||||
} | |||||
}); | |||||
$('#Major').lrselect({ | |||||
value: "majorno", | |||||
text: "majorname", | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#Class').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: "bjsj", strWhere: "DeptNo='" + item.deptno + "' and majorno='" + item.majorno + "'" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#Major').on("click", | |||||
function () { | |||||
var data = $('#Dept').lrselectGet(); | |||||
if (!data) { | |||||
learun.alert.error('请先选择系'); | |||||
} | |||||
}); | |||||
$('#Class').on("click", | |||||
function () { | |||||
var data1 = $('#Dept').lrselectGet(); | |||||
var data2 = $('#Major').lrselectGet(); | |||||
if (!data1 || !data2) { | |||||
learun.alert.error('请先选择系和专业'); | |||||
} | |||||
}); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
// 查看 | |||||
$('#lr_view').on('click', function () { | |||||
var BuildType = $('#gridtable').jfGridValue('BuildType'); | |||||
var Dormitory = $('#gridtable').jfGridValue('ApartmentId'); | |||||
var Unit = $('#gridtable').jfGridValue('UnitId'); | |||||
var Floor = $('#gridtable').jfGridValue('FloorId'); | |||||
var RId = $('#gridtable').jfGridValue('ID'); | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (BuildType != '4') { | |||||
return learun.alert.warning("请选择宿舍!"); | |||||
} | |||||
learun.layerForm({ | |||||
id: 'index', | |||||
title: '查看', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/Index?keyValue=' + keyValue + '&Dormitory=' + Dormitory + '&Unit=' + Unit + '&Floor=' + Floor + '&RId=' + RId, | |||||
width: 1200, | |||||
height: 800, | |||||
btn: null, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
}); | |||||
// 查看 | |||||
$('#lr_viewall').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'indexall', | |||||
title: '查看全部', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Acc_DailyAssess/IndexAll', | |||||
width: 1200, | |||||
height: 800, | |||||
btn: null, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
}); | |||||
// 编辑 | |||||
$('#lr_edit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (learun.checkrow(keyValue)) { | |||||
if (keyValue.indexOf(',') != -1) { | |||||
learun.alert.warning("只能选择一条记录进行编辑!"); | |||||
return false; | |||||
} | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/LogisticsManagement/Accommodation/Form?keyValue=' + keyValue, | |||||
width: 900, | |||||
height: 550, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 删除 | |||||
$('#lr_delete').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||||
if (res) { | |||||
learun.deleteForm(top.$.rootUrl + '/LogisticsManagement/Accommodation/DeleteForm', { keyValue: keyValue }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
//刷新左侧的树 | |||||
$("#tree_refresh").on("click", function () { | |||||
page.initTree(); | |||||
}); | |||||
}, | |||||
//初始化左侧树 | |||||
initTree: function () { | |||||
// 初始化左侧树形数据 | |||||
$('#dataTree').lrtree({ | |||||
url: top.$.rootUrl + '/LogisticsManagement/Accommodation/GetTree', | |||||
nodeClick: function (item) { | |||||
selectedParent.ID = item.value; | |||||
selectedParent.Name = item.text; | |||||
selectedParent.BuildType = item.title; | |||||
if (item.parent) { | |||||
if (!item.parent.parentId) { | |||||
selectedParent.ChildType = "2"; | |||||
} else { | |||||
selectedParent.ChildType = "0"; | |||||
} | |||||
} | |||||
else { | |||||
selectedParent.ChildType = "1"; | |||||
} | |||||
if (item.text.indexOf("室") > -1) { | |||||
selectedParent.ChildType = "5"; | |||||
} | |||||
var param = {}; | |||||
if (item.title == '1') | |||||
param.ApartmentId = item.value; | |||||
else if (item.title == '2') | |||||
param.UnitId = item.value; | |||||
else if (item.title == '3') | |||||
param.FloorId = item.value; | |||||
//page.initGird(); | |||||
//page.search({ ParentID: item.value }); | |||||
page.search(param); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
//宿舍数据 | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/LogisticsManagement/Accommodation/GetPageList', | |||||
headData: [ | |||||
{ label: "名称", name: "Name", width: 100, align: "left" }, | |||||
{ | |||||
label: "宿舍楼", name: "ApartmentName", width: 100, align: "left" | |||||
}, | |||||
{ | |||||
label: "单元", name: "UnitName", width: 100, align: "left" | |||||
}, | |||||
{ | |||||
label: "楼层", name: "FloorName", width: 100, align: "left" | |||||
}, | |||||
//{ | |||||
// label: "学生", name: "StudentID", width: 100, align: "left", | |||||
// formatterAsync: function (callback, value, row, op, $cell) { | |||||
// learun.clientdata.getAsync('custmerData', { | |||||
// url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'StuInfoBasic', | |||||
// key: value, | |||||
// keyId: 'stuid', | |||||
// callback: function (_data) { | |||||
// callback(_data['stuname']); | |||||
// } | |||||
// }); | |||||
// } | |||||
//}, | |||||
{ label: "位置", name: "Address", width: 100, align: "left" }, | |||||
{ | |||||
label: "校区", name: "Campus", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'company', | |||||
key: value, | |||||
keyId: 'f_companyid', | |||||
callback: function (_data) { | |||||
callback(_data['f_fullname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "系", name: "Dept", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdDeptInfo', | |||||
key: value, | |||||
keyId: 'deptno', | |||||
callback: function (_data) { | |||||
callback(_data['deptname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "专业", name: "Major", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdMajorInfo', | |||||
key: value, | |||||
keyId: 'majorno', | |||||
callback: function (_data) { | |||||
callback(_data['majorname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "班级", name: "Class", width: 100, align: "left", formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'bjsj', | |||||
key: value, | |||||
keyId: 'classno', | |||||
callback: function (_data) { | |||||
callback(_data['classname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "寝室类型", name: "RoomType", width: 100, align: "left", | |||||
formatter: function (value, row) { | |||||
if (value) { | |||||
return value + '人寝'; | |||||
} else { | |||||
return ''; | |||||
} | |||||
} | |||||
}, | |||||
{ label: "入住人数", name: "CheckInStu", width: 100, align: "left" }, | |||||
{ | |||||
label: "性别", name: "Sex", width: 100, align: "left", | |||||
formatter: function (value, row) { | |||||
if (value == '0') | |||||
return '女'; | |||||
else if (value == '1') | |||||
return '男'; | |||||
else | |||||
return ''; | |||||
} | |||||
}, | |||||
{ label: "负责人", name: "Functionary", width: 100, align: "left" }, | |||||
{ label: "负责人电话", name: "Phone", width: 100, align: "left" }, | |||||
{ label: "备注", name: "Remark", width: 100, align: "left" }, | |||||
], | |||||
mainId: 'ID', | |||||
isPage: true, | |||||
sidx: 'ApartmentId asc,UnitId asc ,FloorId asc ', | |||||
}); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
param.SqlParameter = " AND t.BuildType ='4' "; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function () { | |||||
if (!!selectedParent.ID) { | |||||
//var param = { ParentID: selectedParent.ID }; | |||||
//$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
page.initTree(); | |||||
page.search({ ParentID: selectedParent.ID }); | |||||
} else { | |||||
page.initTree(); | |||||
page.search(); | |||||
} | |||||
}; | |||||
page.init(); | |||||
} |
@@ -1494,7 +1494,9 @@ | |||||
<Content Include="Areas\LogisticsManagement\Views\Accommodation\IndexClassify.js" /> | <Content Include="Areas\LogisticsManagement\Views\Accommodation\IndexClassify.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Accommodation\IndexDistribution.js" /> | <Content Include="Areas\LogisticsManagement\Views\Accommodation\IndexDistribution.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Form.js" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Form.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\IndexAll.js" /> | |||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Index.js" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Index.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\IndexDorm.js" /> | |||||
<Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Form.js" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Form.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Index.js" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Index.js" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_StuDayRoutine\Form.js" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_StuDayRoutine\Form.js" /> | ||||
@@ -7890,6 +7892,8 @@ | |||||
<Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Index.cshtml" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_PublicAreaHealth\Index.cshtml" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Form.cshtml" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Form.cshtml" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Index.cshtml" /> | <Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\Index.cshtml" /> | ||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\IndexDorm.cshtml" /> | |||||
<Content Include="Areas\LogisticsManagement\Views\Acc_DailyAssess\IndexAll.cshtml" /> | |||||
<None Include="Properties\PublishProfiles\CustomProfile.pubxml" /> | <None Include="Properties\PublishProfiles\CustomProfile.pubxml" /> | ||||
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | <None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | ||||
<Content Include="Views\Login\Default-beifen.cshtml" /> | <Content Include="Views\Login\Default-beifen.cshtml" /> | ||||
@@ -2,6 +2,7 @@ | |||||
using Learun.Util; | using Learun.Util; | ||||
using System.Collections.Generic; | using System.Collections.Generic; | ||||
using System; | using System; | ||||
using System.Linq; | |||||
using Learun.Application.TwoDevelopment.LogisticsManagement; | using Learun.Application.TwoDevelopment.LogisticsManagement; | ||||
namespace Learun.Application.WebApi | namespace Learun.Application.WebApi | ||||
@@ -16,6 +17,7 @@ namespace Learun.Application.WebApi | |||||
public class Acc_DailyAssessApi : BaseApi | public class Acc_DailyAssessApi : BaseApi | ||||
{ | { | ||||
private Acc_DailyAssessIBLL acc_DailyAssessIBLL = new Acc_DailyAssessBLL(); | private Acc_DailyAssessIBLL acc_DailyAssessIBLL = new Acc_DailyAssessBLL(); | ||||
private AccommodationIBLL accommodationIBLL = new AccommodationBLL(); | |||||
/// <summary> | /// <summary> | ||||
/// 注册接口 | /// 注册接口 | ||||
@@ -27,6 +29,8 @@ namespace Learun.Application.WebApi | |||||
Get["/form"] = GetForm; | Get["/form"] = GetForm; | ||||
Post["/delete"] = DeleteForm; | Post["/delete"] = DeleteForm; | ||||
Post["/save"] = SaveForm; | Post["/save"] = SaveForm; | ||||
Get["/getdormstu"] = GetDormStu; | |||||
} | } | ||||
#region 获取数据 | #region 获取数据 | ||||
@@ -63,6 +67,18 @@ namespace Learun.Application.WebApi | |||||
}; | }; | ||||
return Success(jsonData); | return Success(jsonData); | ||||
} | } | ||||
/// <summary> | |||||
/// 获取页面显示列表分页数据 | |||||
/// <summary> | |||||
/// <param name="_"></param> | |||||
/// <returns></returns> | |||||
public Response GetDormStu(dynamic _) | |||||
{ | |||||
ReqFormEntity parameter = this.GetReqData<ReqFormEntity>(); | |||||
var data = accommodationIBLL.GetDromStu(parameter.keyValue).OrderBy(x => x.Class); | |||||
return Success(data); | |||||
} | |||||
#endregion | #endregion | ||||
#region 提交数据 | #region 提交数据 | ||||
@@ -20,6 +20,12 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
[Column("ID")] | [Column("ID")] | ||||
public string Id { get; set; } | public string Id { get; set; } | ||||
/// <summary> | /// <summary> | ||||
/// 关联宿舍主键 | |||||
/// </summary> | |||||
[Column("BUILDID")] | |||||
public string BuildId { get; set; } | |||||
/// <summary> | |||||
/// <summary> | |||||
/// 宿舍楼 | /// 宿舍楼 | ||||
/// </summary> | /// </summary> | ||||
[Column("DORMITORY")] | [Column("DORMITORY")] | ||||
@@ -60,6 +66,11 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
[Column("STUNO")] | [Column("STUNO")] | ||||
public string StuNo { get; set; } | public string StuNo { get; set; } | ||||
/// <summary> | /// <summary> | ||||
/// 学号 | |||||
/// </summary> | |||||
[Column("STUNAME")] | |||||
public string StuName { get; set; } | |||||
/// <summary> | |||||
/// 日期 | /// 日期 | ||||
/// </summary> | /// </summary> | ||||
[Column("DATE")] | [Column("DATE")] | ||||
@@ -5,6 +5,7 @@ using System; | |||||
using System.Collections.Generic; | using System.Collections.Generic; | ||||
using System.Data; | using System.Data; | ||||
using System.Text; | using System.Text; | ||||
using Learun.Application.TwoDevelopment.EducationalAdministration; | |||||
namespace Learun.Application.TwoDevelopment.LogisticsManagement | namespace Learun.Application.TwoDevelopment.LogisticsManagement | ||||
{ | { | ||||
@@ -79,10 +80,15 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
} | } | ||||
if (!queryParam["StuName"].IsEmpty()) | if (!queryParam["StuName"].IsEmpty()) | ||||
{ | { | ||||
dp.Add("StuName", "%"+queryParam["StuName"].ToString()+"%", DbType.String); | |||||
dp.Add("StuName", "%" + queryParam["StuName"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND s.StuName like @StuName "); | strSql.Append(" AND s.StuName like @StuName "); | ||||
} | } | ||||
return this.BaseRepository("CollegeMIS").FindList<Acc_DailyAssessEntity>(strSql.ToString(),dp, pagination); | |||||
//添加sql条件 | |||||
if (!queryParam["SqlParameter"].IsEmpty()) | |||||
{ | |||||
strSql.Append(queryParam["SqlParameter"].ToString()); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<Acc_DailyAssessEntity>(strSql.ToString(), dp, pagination); | |||||
} | } | ||||
catch (Exception ex) | catch (Exception ex) | ||||
{ | { | ||||
@@ -134,7 +140,7 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
{ | { | ||||
try | try | ||||
{ | { | ||||
this.BaseRepository("CollegeMIS").Delete<Acc_DailyAssessEntity>(t=>t.Id == keyValue); | |||||
this.BaseRepository("CollegeMIS").Delete<Acc_DailyAssessEntity>(t => t.Id == keyValue); | |||||
} | } | ||||
catch (Exception ex) | catch (Exception ex) | ||||
{ | { | ||||
@@ -158,6 +164,13 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
{ | { | ||||
try | try | ||||
{ | { | ||||
var Stulist = this.BaseRepository("CollegeMIS").FindEntity<StuInfoBasicEntity>(x => x.StuNo == entity.StuNo); | |||||
if (Stulist != null) | |||||
{ | |||||
entity.ClassNo = Stulist.ClassNo; | |||||
entity.MajorNo = Stulist.MajorNo; | |||||
entity.DeptNo = Stulist.DeptNo; | |||||
} | |||||
if (!string.IsNullOrEmpty(keyValue)) | if (!string.IsNullOrEmpty(keyValue)) | ||||
{ | { | ||||
entity.Modify(keyValue); | entity.Modify(keyValue); | ||||
@@ -44,6 +44,25 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
} | } | ||||
} | } | ||||
public IEnumerable<Acc_DormitoryBuildEntity> GetDromStu(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return accommodationService.GetDromStu(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId) | public IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId) | ||||
{ | { | ||||
try | try | ||||
@@ -22,6 +22,7 @@ namespace Learun.Application.TwoDevelopment.LogisticsManagement | |||||
/// <param name="queryJson">查询参数</param> | /// <param name="queryJson">查询参数</param> | ||||
/// <returns></returns> | /// <returns></returns> | ||||
IEnumerable<Acc_DormitoryBuildEntity> GetPageList(Pagination pagination, string queryJson); | IEnumerable<Acc_DormitoryBuildEntity> GetPageList(Pagination pagination, string queryJson); | ||||
IEnumerable<Acc_DormitoryBuildEntity> GetDromStu(string kevValue); | |||||
IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId); | IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId); | ||||
IEnumerable<Acc_DormitoryBuildEntity> GetAllList(); | IEnumerable<Acc_DormitoryBuildEntity> GetAllList(); | ||||
IEnumerable<Acc_DormitoryBuildEntity> GetClassifyList(Pagination paginationobj,string queryJson); | IEnumerable<Acc_DormitoryBuildEntity> GetClassifyList(Pagination paginationobj,string queryJson); | ||||
@@ -206,6 +206,28 @@ a.name as ApartmentName,b.name as UnitName,c.Name as FloorName | |||||
} | } | ||||
} | } | ||||
public IEnumerable<Acc_DormitoryBuildEntity> GetDromStu(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
string sql = @"select ID,Name,DNo,StudentID,fb.stuNo,fb.stuname,fb.classno,fb.majorno,fb.deptno from Acc_DormitoryBuild zb | |||||
left join StuInfoBasic fb on fb.Stuno = zb.StudentID | |||||
where zb.BuildType = '5' and zb.ParentID = '" + keyValue + "'"; | |||||
return this.BaseRepository("CollegeMIS").FindList<Acc_DormitoryBuildEntity>(sql); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
public IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId) | public IEnumerable<Acc_DormitoryBuildEntity> GetBedListByRoomId(string RoomId) | ||||
{ | { | ||||
try | try | ||||