@@ -33,6 +33,26 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
{ | { | ||||
return View(); | return View(); | ||||
} | } | ||||
/// <summary> | |||||
/// 管理省份 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult IndexProvince() | |||||
{ | |||||
return View(); | |||||
} | |||||
/// <summary> | |||||
/// 管理省份 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult FormProvince() | |||||
{ | |||||
return View(); | |||||
} | |||||
/// <summary> | /// <summary> | ||||
/// 表单页 | /// 表单页 | ||||
/// <summary> | /// <summary> | ||||
@@ -82,6 +102,19 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
}; | }; | ||||
return Success(jsonData); | return Success(jsonData); | ||||
} | } | ||||
/// <summary> | |||||
/// 获取专业省份关联数据 | |||||
/// <summary> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetListForProvince(string queryJson) | |||||
{ | |||||
var data = cdMajorIBLL.GetListForProvince(queryJson); | |||||
return Success(data); | |||||
} | |||||
[HttpGet] | [HttpGet] | ||||
[AjaxOnly] | [AjaxOnly] | ||||
public ActionResult GetElectivePageList(string queryJson) | public ActionResult GetElectivePageList(string queryJson) | ||||
@@ -213,6 +246,34 @@ namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
return Success("保存成功!"); | return Success("保存成功!"); | ||||
} | } | ||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[ValidateAntiForgeryToken] | |||||
[AjaxOnly] | |||||
public ActionResult SaveProvince(string keyValue, string strEntity,string MajorNo) | |||||
{ | |||||
List<DIC_PROVINCEEntity> list = strEntity.ToObject<List<DIC_PROVINCEEntity>>(); | |||||
cdMajorIBLL.SaveProvince(list, MajorNo); | |||||
return Success("保存成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 删除实体数据 | |||||
/// <param name="keyValue">主键</param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult DeleteProvince(string keyValue) | |||||
{ | |||||
cdMajorIBLL.DeleteProvince(keyValue); | |||||
return Success("删除成功!"); | |||||
} | |||||
#endregion | #endregion | ||||
} | } | ||||
@@ -0,0 +1,158 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using Learun.Application.TwoDevelopment.EducationalAdministration; | |||||
using System.Web.Mvc; | |||||
using Learun.Application.TwoDevelopment.LR_CodeDemo; | |||||
using System.Collections.Generic; | |||||
using Learun.Application.Base.SystemModule; | |||||
namespace Learun.Application.Web.Areas.EducationalAdministration.Controllers | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2023-02-23 10:34 | |||||
/// 描 述:一卡通流水 | |||||
/// </summary> | |||||
public class YKTStateMentController : MvcControllerBase | |||||
{ | |||||
private Acc_DormitoryChangeIBLL acc_DormitoryChangeIBLL = new Acc_DormitoryChangeBLL(); | |||||
private CodeRuleIBLL codeRuleIBLL = new CodeRuleBLL(); | |||||
#region 视图功能 | |||||
/// <summary> | |||||
/// 主页面 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult Index() | |||||
{ | |||||
return View(); | |||||
} | |||||
/// <summary> | |||||
/// 表单页 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult Form() | |||||
{ | |||||
return View(); | |||||
} | |||||
/// <summary> | |||||
/// 表单页 | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
public ActionResult FormView() | |||||
{ | |||||
return View(); | |||||
} | |||||
#endregion | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetPageList(string pagination, string queryJson) | |||||
{ | |||||
Pagination paginationobj = pagination.ToObject<Pagination>(); | |||||
var data = acc_DormitoryChangeIBLL.GetPageList(paginationobj, queryJson); | |||||
var jsonData = new | |||||
{ | |||||
rows = data, | |||||
total = paginationobj.total, | |||||
page = paginationobj.page, | |||||
records = paginationobj.records | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
/// <summary> | |||||
/// 获取表单数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetFormData(string keyValue) | |||||
{ | |||||
var Acc_DormitoryChangeData = acc_DormitoryChangeIBLL.GetAcc_DormitoryChangeEntity(keyValue); | |||||
var jsonData = new | |||||
{ | |||||
Acc_DormitoryChange = Acc_DormitoryChangeData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
/// <summary> | |||||
/// 获取表单数据 | |||||
/// </summary> | |||||
/// <param name="processId">流程实例主键</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetFormDataByProcessId(string processId) | |||||
{ | |||||
var Acc_DormitoryChangeData = acc_DormitoryChangeIBLL.GetEntityByProcessId(processId); | |||||
var jsonData = new | |||||
{ | |||||
Acc_DormitoryChange = Acc_DormitoryChangeData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
#endregion | |||||
#region 提交数据 | |||||
/// <summary> | |||||
/// 删除实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult DeleteForm(string keyValue) | |||||
{ | |||||
acc_DormitoryChangeIBLL.DeleteEntity(keyValue); | |||||
return Success("删除成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="strEntity">实体</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[ValidateAntiForgeryToken] | |||||
[AjaxOnly] | |||||
public ActionResult SaveForm(string keyValue, string strEntity) | |||||
{ | |||||
Acc_DormitoryChangeEntity entity = strEntity.ToObject<Acc_DormitoryChangeEntity>(); | |||||
if (entity.HisDormitory == entity.Dormitory && entity.HisUnit == entity.Unit && entity.HisFloor == entity.Floor | |||||
&& entity.HisRId == entity.RId) | |||||
{ | |||||
return Fail("新宿舍请勿选择与旧宿舍一致"); | |||||
} | |||||
acc_DormitoryChangeIBLL.SaveEntity(keyValue, entity); | |||||
return Success("保存成功!"); | |||||
} | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult SubmitForm(string status, string processId, string keyValue) | |||||
{ | |||||
acc_DormitoryChangeIBLL.SubmitEntity(status, processId, keyValue); | |||||
return Success("提交成功!"); | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,32 @@ | |||||
@{ | |||||
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="multiple_condition_query"> | |||||
<div class="lr-query-formcontent"> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">名称</div> | |||||
<input id="PNAME" 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> | |||||
</div> | |||||
<div class="lr-layout-body" id="gridtable"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/CdMajor/FormProvince.js") |
@@ -0,0 +1,72 @@ | |||||
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) | |||||
* Copyright (c) 2013-2018 北京泉江科技有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2019-01-22 16:32 | |||||
* 描 述:专业信息管理 | |||||
*/ | |||||
var refreshGirdData; | |||||
var acceptClick; | |||||
var MajorNo = request('MajorNo'); | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
page.initGird(); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 220, 400); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/EducationalAdministration/DIC_PROVINCE/GetPageList', | |||||
headData: [ | |||||
{ label: "省份编号", name: "PCODE", width: 100, align: "left" }, | |||||
{ label: "省份名称", name: "PNAME", width: 100, align: "left" }, | |||||
], | |||||
mainId: 'PID', | |||||
isMultiselect: true, | |||||
isPage: true, | |||||
sidx: 'PCODE', | |||||
sord: 'ASC' | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function () { | |||||
page.search(); | |||||
}; | |||||
// 保存数据 | |||||
acceptClick = function (callBack) { | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
var dataList = $('#gridtable').jfGridGet('rowdata'); | |||||
var strEntity = $('body').lrGetFormData(); | |||||
strEntity.MajorNo = MajorNo; | |||||
var postData = { | |||||
strEntity: JSON.stringify(dataList), | |||||
MajorNo: MajorNo | |||||
}; | |||||
$.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/CdMajor/SaveProvince?keyValue=', postData, function (res) { | |||||
// 保存成功后才回调 | |||||
if (!!callBack) { | |||||
callBack(); | |||||
} | |||||
}); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -36,6 +36,7 @@ | |||||
</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_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_province" 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> | ||||
<a id="lr_lock" class="btn btn-default"><i class="fa fa-lock"></i> 启用</a> | <a id="lr_lock" class="btn btn-default"><i class="fa fa-lock"></i> 启用</a> | ||||
@@ -24,6 +24,25 @@ var bootstrap = function ($, learun) { | |||||
$('#lr_refresh').on('click', function () { | $('#lr_refresh').on('click', function () { | ||||
location.reload(); | location.reload(); | ||||
}); | }); | ||||
//管理省份 | |||||
$('#lr_province').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
var MajorNo = $('#gridtable').jfGridValue('MajorNo'); | |||||
if (learun.checkrow(keyValue)) { | |||||
//var rowdata = $('#gridtable').jfGridGet('rowdata'); | |||||
learun.layerForm({ | |||||
id: 'formprovince', | |||||
title: '管理省份', | |||||
url: top.$.rootUrl + '/EducationalAdministration/CdMajor/IndexProvince?MajorNo=' + MajorNo, | |||||
width: 1000, | |||||
height: 600, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 新增 | // 新增 | ||||
$('#lr_add').on('click', function () { | $('#lr_add').on('click', function () { | ||||
learun.layerForm({ | learun.layerForm({ | ||||
@@ -225,19 +244,19 @@ var bootstrap = function ($, learun) { | |||||
// }); | // }); | ||||
// } | // } | ||||
//}, | //}, | ||||
{ | |||||
label: "省份", name: "Province", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_PROVINCE', | |||||
key: value, | |||||
keyId: 'pcode', | |||||
callback: function (_data) { | |||||
callback(_data['pname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
//{ | |||||
// label: "省份", name: "Province", width: 100, align: "left", | |||||
// formatterAsync: function (callback, value, row, op, $cell) { | |||||
// learun.clientdata.getAsync('custmerData', { | |||||
// url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_PROVINCE', | |||||
// key: value, | |||||
// keyId: 'pcode', | |||||
// callback: function (_data) { | |||||
// callback(_data['pname']); | |||||
// } | |||||
// }); | |||||
// } | |||||
//}, | |||||
//{ label: "年度", name: "Year", width: 100, align: "left" }, | //{ label: "年度", name: "Year", width: 100, align: "left" }, | ||||
//{ | //{ | ||||
// label: "地市", name: "City", width: 100, align: "left", | // label: "地市", name: "City", width: 100, align: "left", | ||||
@@ -0,0 +1,35 @@ | |||||
@{ | |||||
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="multiple_condition_query"> | |||||
<div class="lr-query-formcontent"> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">名称</div> | |||||
<input id="PNAME" 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" > | |||||
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i> 新增</a> | |||||
<a id="lr_delete" 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/EducationalAdministration/Views/CdMajor/IndexProvince.js") |
@@ -0,0 +1,101 @@ | |||||
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn) | |||||
* Copyright (c) 2013-2018 北京泉江科技有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2023-02-23 16:32 | |||||
* 描 述:专业省份关联 | |||||
*/ | |||||
var refreshGirdData; | |||||
var acceptClick; | |||||
var MajorNo = request('MajorNo'); | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
page.initGird(); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 220, 400); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
// 新增 | |||||
$('#lr_add').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'formadd', | |||||
title: '新增', | |||||
url: top.$.rootUrl + '/EducationalAdministration/CdMajor/FormProvince?MajorNo=' + MajorNo, | |||||
width: 1000, | |||||
height: 600, | |||||
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 + '/EducationalAdministration/CdMajor/DeleteProvince', { keyValue: keyValue }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/EducationalAdministration/CdMajor/GetListForProvince', | |||||
headData: [ | |||||
{ label: "省份编号", name: "Province", width: 100, align: "left" }, | |||||
{ | |||||
label: "省份名称", name: "Province1", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'DIC_PROVINCE', | |||||
key: row.Province, | |||||
keyId: 'pcode', | |||||
callback: function (_data) { | |||||
callback(_data['pname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
], | |||||
mainId: 'Id', | |||||
isPage: false, | |||||
isMultiselect: true, | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
if (MajorNo.indexOf(',') == -1) { | |||||
param.MajorNo = MajorNo; | |||||
} else { | |||||
param.MajorNo = 'no'; | |||||
} | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function () { | |||||
page.search(); | |||||
}; | |||||
page.init(); | |||||
acceptClick = function(callBack) { | |||||
if (!!callBack) { | |||||
learun.layerClose(window.name); | |||||
callBack(); | |||||
} | |||||
} | |||||
} |
@@ -27,10 +27,10 @@ var bootstrap = function ($, learun) { | |||||
$('#GraduateType').lrDataItemSelect({ code: 'StuGraduateType' }); | $('#GraduateType').lrDataItemSelect({ code: 'StuGraduateType' }); | ||||
$('#HomeProvince').lrDataSourceSelect({ | $('#HomeProvince').lrDataSourceSelect({ | ||||
code: 'DIC_PROVINCE', value: 'pcode', text: 'pname', | code: 'DIC_PROVINCE', value: 'pcode', text: 'pname', | ||||
select: function(item) { | |||||
select: function (item) { | |||||
if (!!item) { | if (!!item) { | ||||
var code = $("#HomeProvince").lrselectGet(); | var code = $("#HomeProvince").lrselectGet(); | ||||
$('#HomeCity').lrselectRefresh({ | $('#HomeCity').lrselectRefresh({ | ||||
allowSearch: true, | allowSearch: true, | ||||
//type: 'multiple', | //type: 'multiple', | ||||
@@ -378,6 +378,8 @@ var bootstrap = function ($, learun) { | |||||
} | } | ||||
}); | }); | ||||
} | } | ||||
}, { | |||||
label: "提交时间", name: "CreateTime", width: 150, align: "left" | |||||
}, | }, | ||||
], | ], | ||||
mainId: 'Id', | mainId: 'Id', | ||||
@@ -0,0 +1,54 @@ | |||||
@{ | |||||
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="multiple_condition_query"> | |||||
<div class="lr-query-formcontent"> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">学号</div> | |||||
<input id="StuNo" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item"> | |||||
<div class="lr-form-item-title">姓名</div> | |||||
<input id="StuName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-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> | |||||
</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_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_delete" class="btn btn-default"><i class="fa fa-trash-o"></i> 删除</a> | |||||
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i> 打印</a> | |||||
<a id="lr_submit" 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/EducationalAdministration/Views/Acc_DormitoryChange/Index.js") |
@@ -0,0 +1,389 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2022-07-11 14:34 | |||||
* 描 述:宿舍调换申请 | |||||
*/ | |||||
var refreshGirdData; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var processId = ''; | |||||
var page = { | |||||
init: function () { | |||||
page.initGird(); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
$('#multiple_condition_query').lrMultipleQuery(function (queryJson) { | |||||
page.search(queryJson); | |||||
}, 220, 400); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
$('#DeptNo').lrselect({ | |||||
value: "deptno", | |||||
text: "deptname", | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable?code=CdDeptInfo', | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: "CdMajorInfo", strWhere: "DeptNo='" + item.deptno + "'" } | |||||
}); | |||||
} | |||||
else { | |||||
$('#MajorNo').lrselectRefresh({ | |||||
url: "", | |||||
data: [] | |||||
}); | |||||
} | |||||
$('#ClassNo').lrselectRefresh({ | |||||
url: "", | |||||
data: [] | |||||
}); | |||||
} | |||||
}); | |||||
$('#MajorNo').lrselect({ | |||||
value: "majorno", | |||||
text: "majorname", | |||||
select: function (item) { | |||||
if (item) { | |||||
$('#ClassNo').lrselectRefresh({ | |||||
url: top.$.rootUrl + '/LR_SystemModule/DataSource/GetDataTable', | |||||
param: { code: "bjsj", strWhere: "DeptNo='" + item.deptno + "' and majorno='" + item.majorno + "'" } | |||||
}); | |||||
} | |||||
} | |||||
}); | |||||
$('#MajorNo').on("click", | |||||
function () { | |||||
var data = $('#DeptNo').lrselectGet(); | |||||
if (!data) { | |||||
learun.alert.error('请先选择系'); | |||||
} | |||||
}); | |||||
$('#ClassNo').on("click", | |||||
function () { | |||||
var data1 = $('#DeptNo').lrselectGet(); | |||||
var data2 = $('#MajorNo').lrselectGet(); | |||||
if (!data1 || !data2) { | |||||
learun.alert.error('请先选择系和专业'); | |||||
} | |||||
}); | |||||
$('#ClassNo').lrselect({ | |||||
value: "classno", | |||||
text: "classname" | |||||
}); | |||||
// 新增 | |||||
$('#lr_add').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '新增', | |||||
url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/Form', | |||||
width: 600, | |||||
height: 450, | |||||
callBack: function (id) { | |||||
var res = false; | |||||
// 验证数据 | |||||
res = top[id].validForm(); | |||||
// 保存数据 | |||||
if (res) { | |||||
res = top[id].save('', function () { | |||||
page.search(); | |||||
}); | |||||
} | |||||
return res; | |||||
} | |||||
}); | |||||
}); | |||||
// 编辑 | |||||
$('#lr_edit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (learun.checkrow(keyValue)) { | |||||
var CheckStatus = $('#gridtable').jfGridValue('Status'); | |||||
if (CheckStatus != "0") { | |||||
learun.alert.warning("当前项已提交!"); | |||||
return false; | |||||
} | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/Form?keyValue=' + keyValue, | |||||
width: 600, | |||||
height: 450, | |||||
callBack: function (id) { | |||||
var res = false; | |||||
// 验证数据 | |||||
res = top[id].validForm(); | |||||
// 保存数据 | |||||
if (res) { | |||||
res = top[id].save('', function () { | |||||
page.search(); | |||||
}); | |||||
} | |||||
return res; | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 删除 | |||||
$('#lr_delete').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (learun.checkrow(keyValue)) { | |||||
var CheckStatus = $('#gridtable').jfGridValue('Status'); | |||||
if (CheckStatus != "0") { | |||||
learun.alert.warning("当前项已提交!"); | |||||
return false; | |||||
} | |||||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||||
if (res) { | |||||
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/DeleteForm', { keyValue: keyValue }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 查看 | |||||
$('#lr_view').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('Id'); | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerForm({ | |||||
id: 'formview', | |||||
title: '查看', | |||||
url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/FormView?keyValue=' + keyValue, | |||||
width: 1000, | |||||
height: 800, | |||||
btn: null | |||||
}); | |||||
} | |||||
}); | |||||
// 提交 | |||||
$('#lr_submit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('ID'); | |||||
if (learun.checkrow(keyValue)) { | |||||
var CheckStatus = $('#gridtable').jfGridValue('Status'); | |||||
if (CheckStatus != "0") { | |||||
learun.alert.warning("当前项已提交!"); | |||||
return false; | |||||
} | |||||
learun.layerConfirm('是否确认提交该项!', function (res) { | |||||
if (res) { | |||||
processId = learun.newGuid(); | |||||
learun.postForm(top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/SubmitForm', { keyValue: keyValue, status: "1", processId: processId }, function (res) { | |||||
refreshGirdData(res, {}); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/EducationalAdministration/Acc_DormitoryChange/GetPageList', | |||||
headData: [ | |||||
{ label: "学号", name: "StuNo", width: 100, align: "left" }, | |||||
{ label: "姓名", name: "StuName", width: 100, align: "left" }, | |||||
{ | |||||
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: "Reason", width: 100, align: "left" }, | |||||
{ | |||||
label: "性别", name: "Sex", width: 100, align: "left", | |||||
formatter: function (cellvalue) { | |||||
return cellvalue == true ? "男" : "女"; | |||||
} | |||||
}, | |||||
{ | |||||
label: "原宿舍楼", name: "HisDormitory", 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: "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: "Status", width: 100, align: "center", | |||||
formatter: function (cellvalue, row) { | |||||
if (cellvalue == 0) { | |||||
return '<span class=\"label label-default\">草稿</span>'; | |||||
} if (cellvalue == 1) { | |||||
return '<span class=\"label label-warning\">审批中</span>'; | |||||
} else if (cellvalue == 2) { | |||||
return '<span class=\"label label-success\">同意</span>'; | |||||
} else if (cellvalue == 3) { | |||||
return '<span class=\"label label-primary\">不同意</span>'; | |||||
} | |||||
} | |||||
}, | |||||
{ label: "备注", name: "Remark", width: 100, align: "left" }, | |||||
], | |||||
mainId: 'ID', | |||||
sidx: 'CreateTime', | |||||
sord: 'desc', | |||||
isPage: true | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function (res, postData) { | |||||
if (!!res) { | |||||
if (res.code == 200) { | |||||
// 发起流程 | |||||
var postData = { | |||||
schemeCode: 'DorChange',// 填写流程对应模板编号 | |||||
processId: processId, | |||||
level: '1', | |||||
}; | |||||
learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) { | |||||
learun.loading(false); | |||||
}); | |||||
} | |||||
page.search(); | |||||
} | |||||
}; | |||||
page.init(); | |||||
} |
@@ -315,6 +315,7 @@ | |||||
<Compile Include="Areas\AssetManagementSystem\Controllers\Ass_SupplierController.cs" /> | <Compile Include="Areas\AssetManagementSystem\Controllers\Ass_SupplierController.cs" /> | ||||
<Compile Include="Areas\AssetManagementSystem\Controllers\Ass_UserChangeInfoController.cs" /> | <Compile Include="Areas\AssetManagementSystem\Controllers\Ass_UserChangeInfoController.cs" /> | ||||
<Compile Include="Areas\AssetManagementSystem\Controllers\Ass_WarningController.cs" /> | <Compile Include="Areas\AssetManagementSystem\Controllers\Ass_WarningController.cs" /> | ||||
<Compile Include="Areas\EducationalAdministration\Controllers\YKTStateMentController.cs" /> | |||||
<Compile Include="Areas\EducationalAdministration\Controllers\ArrangeLessonSyncController.cs" /> | <Compile Include="Areas\EducationalAdministration\Controllers\ArrangeLessonSyncController.cs" /> | ||||
<Compile Include="Areas\EducationalAdministration\Controllers\ArrangeLessonTermAttemperController.cs" /> | <Compile Include="Areas\EducationalAdministration\Controllers\ArrangeLessonTermAttemperController.cs" /> | ||||
<Compile Include="Areas\EducationalAdministration\Controllers\CertificateManageController.cs" /> | <Compile Include="Areas\EducationalAdministration\Controllers\CertificateManageController.cs" /> | ||||
@@ -961,6 +962,9 @@ | |||||
<Content Include="Areas\AssetManagementSystem\Views\Ass_UserChangeInfo\Index.js" /> | <Content Include="Areas\AssetManagementSystem\Views\Ass_UserChangeInfo\Index.js" /> | ||||
<Content Include="Areas\AssetManagementSystem\Views\Ass_Warning\Form.js" /> | <Content Include="Areas\AssetManagementSystem\Views\Ass_Warning\Form.js" /> | ||||
<Content Include="Areas\AssetManagementSystem\Views\Ass_Warning\Index.js" /> | <Content Include="Areas\AssetManagementSystem\Views\Ass_Warning\Index.js" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\CdMajor\FormProvince.js" /> | |||||
<Content Include="Areas\EducationalAdministration\Views\CdMajor\IndexProvince.js" /> | |||||
<Content Include="Areas\EducationalAdministration\Views\YKTStateMent\Index.js" /> | |||||
<Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexTeach.js" /> | <Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexTeach.js" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexForLesson.js" /> | <Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexForLesson.js" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexForClass.js" /> | <Content Include="Areas\EducationalAdministration\Views\ArrangeExamTermNew\IndexForClass.js" /> | ||||
@@ -8002,6 +8006,9 @@ | |||||
<Content Include="Areas\EducationalAdministration\Views\StuSubsidize\FormView.cshtml" /> | <Content Include="Areas\EducationalAdministration\Views\StuSubsidize\FormView.cshtml" /> | ||||
<Content Include="Areas\LR_NewWorkFlow\Views\NWFProcess\MonitorIndexStatistics.cshtml" /> | <Content Include="Areas\LR_NewWorkFlow\Views\NWFProcess\MonitorIndexStatistics.cshtml" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\StuScore\InputScoreIndexInTeacherImport.cshtml" /> | <Content Include="Areas\EducationalAdministration\Views\StuScore\InputScoreIndexInTeacherImport.cshtml" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\YKTStateMent\Index.cshtml" /> | |||||
<Content Include="Areas\EducationalAdministration\Views\CdMajor\IndexProvince.cshtml" /> | |||||
<Content Include="Areas\EducationalAdministration\Views\CdMajor\FormProvince.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" /> | ||||
@@ -42,4 +42,6 @@ | |||||
<add name="CollegeMIS" connectionString="Server=123.57.209.16;Initial Catalog=CollegeMIS_塔里木;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | <add name="CollegeMIS" connectionString="Server=123.57.209.16;Initial Catalog=CollegeMIS_塔里木;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | ||||
<add name="hangfireString" connectionString="Server=123.57.209.16;Initial Catalog=Hangfire;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | <add name="hangfireString" connectionString="Server=123.57.209.16;Initial Catalog=Hangfire;User ID=sa;Password=bjqjkj@2014~2015!" providerName="System.Data.SqlClient" /> | ||||
<add name="paikeDbString" connectionString="Data Source=10.30.0.11;Database=paike;User ID=root;Password=12345678;" providerName="MySql.Data.MySqlClient" /> | <add name="paikeDbString" connectionString="Data Source=10.30.0.11;Database=paike;User ID=root;Password=12345678;" providerName="MySql.Data.MySqlClient" /> | ||||
<!--塔里木中间库一卡通--> | |||||
<add name="TLMYKTDBString" connectionString="Data Source=orcl;Persist Security Info=True;User ID=ccense;Password=Newcapec123;Unicode=True" providerName="System.Data.OracleClient" /> | |||||
</connectionStrings> | </connectionStrings> |
@@ -169,6 +169,9 @@ | |||||
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | <None Include="Properties\PublishProfiles\FolderProfile.pubxml" /> | ||||
<None Include="Properties\PublishProfiles\FolderProfile1.pubxml" /> | <None Include="Properties\PublishProfiles\FolderProfile1.pubxml" /> | ||||
<None Include="Properties\PublishProfiles\FolderProfile2.pubxml" /> | <None Include="Properties\PublishProfiles\FolderProfile2.pubxml" /> | ||||
<None Include="Properties\PublishProfiles\FolderProfile3.pubxml" /> | |||||
<None Include="Properties\PublishProfiles\FolderProfile4.pubxml" /> | |||||
<None Include="Properties\PublishProfiles\FolderProfile5.pubxml" /> | |||||
<None Include="Web.Debug.config"> | <None Include="Web.Debug.config"> | ||||
<DependentUpon>Web.config</DependentUpon> | <DependentUpon>Web.config</DependentUpon> | ||||
</None> | </None> | ||||
@@ -17,8 +17,10 @@ namespace Learun.Application.WebApi.Modules | |||||
: base("/learun/nologin/adms/stuenrollofficial") | : base("/learun/nologin/adms/stuenrollofficial") | ||||
{ | { | ||||
Post["/save"] = SaveForm; | Post["/save"] = SaveForm; | ||||
Get["/getmajor"] = GetMajor; | |||||
} | } | ||||
private StuEnrollOfficialIBLL stuEnrollOfficialIBLL = new StuEnrollOfficialBLL(); | private StuEnrollOfficialIBLL stuEnrollOfficialIBLL = new StuEnrollOfficialBLL(); | ||||
private CdMajorIBLL cdMajorIBLL = new CdMajorBLL(); | |||||
/// <summary> | /// <summary> | ||||
/// 保存实体数据(新增、修改) | /// 保存实体数据(新增、修改) | ||||
/// <param name="_"></param> | /// <param name="_"></param> | ||||
@@ -32,7 +34,17 @@ namespace Learun.Application.WebApi.Modules | |||||
stuEnrollOfficialIBLL.SaveEntity(parameter.keyValue, entity); | stuEnrollOfficialIBLL.SaveEntity(parameter.keyValue, entity); | ||||
return Success("保存成功!"); | return Success("保存成功!"); | ||||
} | } | ||||
/// <summary> | |||||
/// 根据省份获取专业数据 | |||||
/// <param name="_"></param> | |||||
/// <summary> | |||||
/// <returns></returns> | |||||
public Response GetMajor(dynamic _) | |||||
{ | |||||
string str = this.GetReqData(); | |||||
var data= cdMajorIBLL.GetListByProvince(str); | |||||
return Success(data); | |||||
} | |||||
#region 私有类 | #region 私有类 | ||||
@@ -0,0 +1,22 @@ | |||||
using Learun.Application.TwoDevelopment.EducationalAdministration; | |||||
using System.Data.Entity.ModelConfiguration; | |||||
namespace Learun.Application.Mapping | |||||
{ | |||||
public class CdMajorProvinceMap : EntityTypeConfiguration<CdMajorProvince> | |||||
{ | |||||
public CdMajorProvinceMap() | |||||
{ | |||||
#region 表、主键 | |||||
//表 | |||||
this.ToTable("CdMajorProvince"); | |||||
//主键 | |||||
this.HasKey(t => t.Id); | |||||
#endregion | |||||
#region 配置关系 | |||||
#endregion | |||||
} | |||||
} | |||||
} | |||||
@@ -67,6 +67,7 @@ | |||||
<Compile Include="AssetManagementSystem\Ass_PurchaseItemApplyMap.cs" /> | <Compile Include="AssetManagementSystem\Ass_PurchaseItemApplyMap.cs" /> | ||||
<Compile Include="AssetManagementSystem\Ass_ScrapItemMap.cs" /> | <Compile Include="AssetManagementSystem\Ass_ScrapItemMap.cs" /> | ||||
<Compile Include="AssetManagementSystem\Ass_ScrapMap.cs" /> | <Compile Include="AssetManagementSystem\Ass_ScrapMap.cs" /> | ||||
<Compile Include="EducationalAdministration\CdMajorProvinceMap.cs" /> | |||||
<Compile Include="EducationalAdministration\Acc_DormitoryChangeMap.cs" /> | <Compile Include="EducationalAdministration\Acc_DormitoryChangeMap.cs" /> | ||||
<Compile Include="EducationalAdministration\ArrangeExamTermItemNewMap.cs" /> | <Compile Include="EducationalAdministration\ArrangeExamTermItemNewMap.cs" /> | ||||
<Compile Include="EducationalAdministration\ArrangeLessonSyncMap.cs" /> | <Compile Include="EducationalAdministration\ArrangeLessonSyncMap.cs" /> | ||||
@@ -59,6 +59,46 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
} | } | ||||
} | } | ||||
} | } | ||||
public IEnumerable<CdMajorProvince> GetListForProvince(string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
return cdMajorService.GetListForProvince(queryJson); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public IEnumerable<CdMajorEntity> GetListByProvince(string province) | |||||
{ | |||||
try | |||||
{ | |||||
return cdMajorService.GetListByProvince(province); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public IEnumerable<CdMajorEntity> GetListByDeptNo(string DeptNo) | public IEnumerable<CdMajorEntity> GetListByDeptNo(string DeptNo) | ||||
{ | { | ||||
try | try | ||||
@@ -233,6 +273,43 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
} | } | ||||
} | } | ||||
public void SaveProvince(List<DIC_PROVINCEEntity> list, string MajorNo) | |||||
{ | |||||
try | |||||
{ | |||||
cdMajorService.SaveProvince(list, MajorNo); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public void DeleteProvince(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
cdMajorService.DeleteProvince(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public IEnumerable<CdMajorEntity> GetAllList() | public IEnumerable<CdMajorEntity> GetAllList() | ||||
{ | { | ||||
try | try | ||||
@@ -133,11 +133,6 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
[Column("YEAR")] | [Column("YEAR")] | ||||
public string Year { get; set; } | public string Year { get; set; } | ||||
/// <summary> | /// <summary> | ||||
/// 省份 | |||||
/// </summary> | |||||
[Column("PROVINCE")] | |||||
public string Province { get; set; } | |||||
/// <summary> | |||||
/// 地市 | /// 地市 | ||||
/// </summary> | /// </summary> | ||||
[Column("CITY")] | [Column("CITY")] | ||||
@@ -197,7 +192,24 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
/// </summary> | /// </summary> | ||||
[NotMapped] | [NotMapped] | ||||
public string SubjectNo { get; set; } | public string SubjectNo { get; set; } | ||||
/// <summary> | |||||
/// 省份 | |||||
/// </summary> | |||||
[NotMapped] | |||||
public string Province { get; set; } | |||||
#endregion | #endregion | ||||
} | } | ||||
public class CdMajorProvince | |||||
{ | |||||
[Column("ID")] | |||||
public string Id { get; set; } | |||||
[Column("MAJORNO")] | |||||
public string MajorNo { get; set; } | |||||
[Column("PROVINCE")] | |||||
public string Province { get; set; } | |||||
[Column("CREATETIME")] | |||||
public DateTime? CreateTime { get; set; } | |||||
} | |||||
} | } | ||||
@@ -22,7 +22,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
/// <returns></returns> | /// <returns></returns> | ||||
IEnumerable<CdMajorEntity> GetPageList(Pagination pagination, string queryJson); | IEnumerable<CdMajorEntity> GetPageList(Pagination pagination, string queryJson); | ||||
IEnumerable<CdMajorEntity> GetElectivePageList(string queryJson); | IEnumerable<CdMajorEntity> GetElectivePageList(string queryJson); | ||||
IEnumerable<CdMajorProvince> GetListForProvince(string queryJson); | |||||
IEnumerable<CdMajorEntity> GetListByProvince(string province); | |||||
IEnumerable<CdMajorEntity> GetListByDeptNo(string DeptNo); | IEnumerable<CdMajorEntity> GetListByDeptNo(string DeptNo); | ||||
/// <summary> | /// <summary> | ||||
/// 获取CdMajor表实体数据 | /// 获取CdMajor表实体数据 | ||||
@@ -57,6 +58,8 @@ namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
/// <summary> | /// <summary> | ||||
/// <returns></returns> | /// <returns></returns> | ||||
void SaveEntity(string keyValue, CdMajorEntity entity); | void SaveEntity(string keyValue, CdMajorEntity entity); | ||||
void SaveProvince(List<DIC_PROVINCEEntity> list, string MajorNo); | |||||
void DeleteProvince(string keyValue); | |||||
#endregion | #endregion | ||||
IEnumerable<CdMajorEntity> GetAllList(); | IEnumerable<CdMajorEntity> GetAllList(); | ||||
@@ -151,6 +151,39 @@ t.Province | |||||
} | } | ||||
} | } | ||||
public IEnumerable<CdMajorProvince> GetListForProvince(string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append("SELECT "); | |||||
strSql.Append(@"t.* | |||||
"); | |||||
strSql.Append(" FROM CdMajorProvince t "); | |||||
strSql.Append(" WHERE 1=1 "); | |||||
var queryParam = queryJson.ToJObject(); | |||||
// 虚拟参数 | |||||
var dp = new DynamicParameters(new { }); | |||||
if (!queryParam["MajorNo"].IsEmpty()) | |||||
{ | |||||
dp.Add("MajorNo", "%" + queryParam["MajorNo"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.MajorNo Like @MajorNo "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<CdMajorProvince>(strSql.ToString(), dp); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
internal bool GetAny() | internal bool GetAny() | ||||
{ | { | ||||
try | try | ||||
@@ -198,7 +231,43 @@ t.Province | |||||
} | } | ||||
} | } | ||||
} | } | ||||
/// <summary> | |||||
/// 根据省份获取专业 | |||||
/// </summary> | |||||
/// <param name="province">省份</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<CdMajorEntity> GetListByProvince(string province) | |||||
{ | |||||
try | |||||
{ | |||||
var dp = new DynamicParameters(new { }); | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append(" select t.* from cdmajor t join CdMajorProvince b on t.majorno=b.majorno"); | |||||
strSql.Append(" WHERE CheckMark=1 "); | |||||
if (!string.IsNullOrEmpty(province)) | |||||
{ | |||||
strSql.Append($" AND b.province='{province}' "); | |||||
} | |||||
var res = this.BaseRepository("CollegeMIS").FindList<CdMajorEntity>(strSql.ToString()); | |||||
if (res == null || res.Count() <= 0) | |||||
{ | |||||
res = this.BaseRepository("CollegeMIS").FindList<CdMajorEntity>(x => x.CheckMark == true); | |||||
} | |||||
return res; | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | /// <summary> | ||||
/// 获取CdMajor表实体数据 | /// 获取CdMajor表实体数据 | ||||
/// <param name="keyValue">主键</param> | /// <param name="keyValue">主键</param> | ||||
@@ -384,13 +453,78 @@ t.Province | |||||
} | } | ||||
} | } | ||||
/// <summary> | |||||
/// 保存省份 | |||||
/// </summary> | |||||
/// <param name="entity"></param> | |||||
/// <param name="MajorNo"></param> | |||||
public void SaveProvince(List<DIC_PROVINCEEntity> list, string MajorNo) | |||||
{ | |||||
var db = this.BaseRepository("CollegeMIS").BeginTrans(); | |||||
try | |||||
{ | |||||
var data = db.FindList<CdMajorProvince>().ToList(); | |||||
var majorArr = MajorNo.Split(','); | |||||
foreach (var major in majorArr) | |||||
{ | |||||
foreach (var province in list) | |||||
{ | |||||
if (data.Find(x => x.MajorNo == major && x.Province == province.PCODE) == null) | |||||
{ | |||||
db.ExecuteBySql($"insert into CdMajorProvince values(newid(),'{major}','{province.PCODE}',getdate())"); | |||||
} | |||||
} | |||||
} | |||||
db.Commit(); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
db.Rollback(); | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 删除省份 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
public void DeleteProvince(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
if (keyValue.Contains(",")) | |||||
{ | |||||
keyValue = string.Join("','", keyValue.Split(',')); | |||||
} | |||||
this.BaseRepository("CollegeMIS").ExecuteBySql($"delete CdMajorProvince where Id in ('{keyValue}')"); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | #endregion | ||||
public IEnumerable<CdMajorEntity> GetAllList() | public IEnumerable<CdMajorEntity> GetAllList() | ||||
{ | { | ||||
try | try | ||||
{ | { | ||||
return BaseRepository("CollegeMIS").FindList<CdMajorEntity>(m=>m.CheckMark==true); | |||||
return BaseRepository("CollegeMIS").FindList<CdMajorEntity>(m => m.CheckMark == true); | |||||
} | } | ||||
catch (Exception ex) | catch (Exception ex) | ||||
{ | { | ||||
@@ -0,0 +1,50 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2022-07-11 14:34 | |||||
/// 描 述:宿舍调换申请 | |||||
/// </summary> | |||||
public class YKTStateMentBLL : YKTStateMentIBLL | |||||
{ | |||||
private YKTStateMentService yKTStateMentService = new YKTStateMentService(); | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<YKTStateMentEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
return yKTStateMentService.GetPageList(pagination, queryJson); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,49 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.ComponentModel.DataAnnotations.Schema; | |||||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2023-02-23 14:34 | |||||
/// 描 述:一卡通流水 | |||||
/// </summary> | |||||
public class YKTStateMentEntity | |||||
{ | |||||
#region 实体成员 | |||||
/// <summary> | |||||
/// 一卡通账号 | |||||
/// </summary> | |||||
public string CUSTOMERID { get; set; } | |||||
/// <summary> | |||||
/// 学生手机号 | |||||
/// </summary> | |||||
public string OUTID { get; set; } | |||||
/// <summary> | |||||
/// 消费金额 | |||||
/// </summary> | |||||
public string OPFARE { get; set; } | |||||
/// <summary> | |||||
/// 余额 | |||||
/// </summary> | |||||
public string ODDFARE { get; set; } | |||||
/// <summary> | |||||
/// 发生时间 | |||||
/// </summary> | |||||
public string OPDT { get; set; } | |||||
/// <summary> | |||||
/// 科目 | |||||
/// </summary> | |||||
public string DSCRP { get; set; } | |||||
/// <summary> | |||||
/// 终端名称 | |||||
/// </summary> | |||||
public string TERMNAME { get; set; } | |||||
#endregion | |||||
} | |||||
} | |||||
@@ -0,0 +1,30 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2023-02-23 14:34 | |||||
/// 描 述:一卡通流水 | |||||
/// </summary> | |||||
public interface YKTStateMentIBLL | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
IEnumerable<YKTStateMentEntity> GetPageList(Pagination pagination, string queryJson); | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,68 @@ | |||||
using Dapper; | |||||
using Learun.DataBase.Repository; | |||||
using Learun.Util; | |||||
using System; | |||||
using System.Collections.Generic; | |||||
using System.Data; | |||||
using System.Linq; | |||||
using System.Text; | |||||
namespace Learun.Application.TwoDevelopment.EducationalAdministration | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2022-07-11 14:34 | |||||
/// 描 述:宿舍调换申请 | |||||
/// </summary> | |||||
public class YKTStateMentService : RepositoryFactory | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<YKTStateMentEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
var stuInfoBasic = this.BaseRepository("CollegeMIS").FindList<StuInfoBasicEntity>(); | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append(@"select a.OUTID,a.CUSTOMERID,a.OPFARE,a.ODDFARE,a.OPDT,a.DSCRP,b.TERMNAME from M_REC_CONSUME a | |||||
left join M_Base_TERM b on a.TERMID = b.TERMID "); | |||||
strSql.Append(" where 1=1 "); | |||||
var queryParam = queryJson.ToJObject(); | |||||
// 虚拟参数 | |||||
var dp = new DynamicParameters(new { }); | |||||
if (!queryParam["CUSTOMERID"].IsEmpty()) | |||||
{ | |||||
strSql.Append($" AND a.CUSTOMERID like '{queryParam["CUSTOMERID"].ToString()}' "); | |||||
} | |||||
if (!queryParam["StuNo"].IsEmpty()) | |||||
{ | |||||
strSql.Append(" AND a.OUTID Like @StuName "); | |||||
} | |||||
return this.BaseRepository("TLMYKTDBString").FindList<YKTStateMentEntity>(strSql.ToString(), dp, pagination); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -91,6 +91,10 @@ | |||||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemEntity.cs" /> | <Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemEntity.cs" /> | ||||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemIBLL.cs" /> | <Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemIBLL.cs" /> | ||||
<Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemService.cs" /> | <Compile Include="AssetManagementSystem\Ass_ScrapItem\Ass_ScrapItemService.cs" /> | ||||
<Compile Include="EducationalAdministration\YKTStateMent\YKTStateMentBLL.cs" /> | |||||
<Compile Include="EducationalAdministration\YKTStateMent\YKTStateMentEntity.cs" /> | |||||
<Compile Include="EducationalAdministration\YKTStateMent\YKTStateMentIBLL.cs" /> | |||||
<Compile Include="EducationalAdministration\YKTStateMent\YKTStateMentService.cs" /> | |||||
<Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeBLL.cs" /> | <Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeBLL.cs" /> | ||||
<Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeEntity.cs" /> | <Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeEntity.cs" /> | ||||
<Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeIBLL.cs" /> | <Compile Include="EducationalAdministration\Acc_DormitoryChange\Acc_DormitoryChangeIBLL.cs" /> | ||||