zhangli il y a 3 ans
Parent
révision
9be4a4b046
13 fichiers modifiés avec 1169 ajouts et 12 suppressions
  1. +155
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/DtStuLeaveController.cs
  2. +51
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Form.cshtml
  3. +111
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Form.js
  4. +52
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Index.cshtml
  5. +217
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Index.js
  6. +1
    -12
      Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
  7. +29
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/DtStuLeaveMap.cs
  8. +1
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj
  9. +148
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveBLL.cs
  10. +140
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveEntity.cs
  11. +55
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveIBLL.cs
  12. +205
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveService.cs
  13. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj

+ 155
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Controllers/DtStuLeaveController.cs Voir le fichier

@@ -0,0 +1,155 @@
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 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public class DtStuLeaveController : MvcControllerBase
{
private DtStuLeaveIBLL dtStuLeaveIBLL = new DtStuLeaveBLL();
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();
}
#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 = dtStuLeaveIBLL.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 DtStuLeaveData = dtStuLeaveIBLL.GetDtStuLeaveEntity(keyValue);
var jsonData = new
{
DtStuLeave = DtStuLeaveData,
};
return Success(jsonData);
}
/// <summary>
/// 获取表单数据
/// </summary>
/// <param name="processId">流程实例主键</param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetFormDataByProcessId(string processId)
{
var DtStuLeaveData = dtStuLeaveIBLL.GetEntityByProcessId(processId);
var jsonData = new
{
DtStuLeave = DtStuLeaveData,
};
return Success(jsonData);
}
#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// </summary>
/// <param name="keyValue">主键</param>
/// <returns></returns>
[HttpPost]
[AjaxOnly]
public ActionResult DeleteForm(string keyValue)
{
dtStuLeaveIBLL.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)
{
DtStuLeaveEntity entity = strEntity.ToObject<DtStuLeaveEntity>();
entity.FlowNo = "0";
dtStuLeaveIBLL.SaveEntity(keyValue, entity);
if (string.IsNullOrEmpty(keyValue))
{
}
return Success("保存成功!");
}
#endregion
/// <summary>
/// 提交数据
/// </summary>
/// <param name="keyValue">主键</param>
/// <returns></returns>
[HttpPost]
[ValidateAntiForgeryToken]
[AjaxOnly]
public ActionResult SubmitList(string keyValue, string strEntity)
{
DtStuLeaveEntity entity = strEntity.ToObject<DtStuLeaveEntity>();
entity.FlowNo = "1";
dtStuLeaveIBLL.SaveEntity(keyValue, entity);
if (string.IsNullOrEmpty(keyValue))
{
}
return Success("提交成功!");
}
}
}

+ 51
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Form.cshtml Voir le fichier

@@ -0,0 +1,51 @@
@{
ViewBag.Title = "学生请假,审核";
Layout = "~/Views/Shared/_Form.cshtml";
}
<div class="lr-form-wrap" id="form">
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">申请人</div>
<input id="CreateUserName" type="text" readonly class="form-control currentInfo lr-currentInfo-user" />
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">所属系<font face="宋体">*</font></div>
<div id="CreateUserDeptNo" isvalid="yes" checkexpession="NotNull" ></div>
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">所属班级<font face="宋体">*</font></div>
<div id="CreateUserClassNo" isvalid="yes" checkexpession="NotNull" ></div>
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">请假类型<font face="宋体">*</font></div>
<div id="LeaveType" isvalid="yes" checkexpession="NotNull" ></div>
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">开始时间</div>
<input id="BeginDate" type="text" class="form-control lr-input-wdatepicker" autocomplete="off" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm',onpicked: function () { $('#BeginDate').trigger('change'); } })" />
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">结束时间<font face="宋体">*</font></div>
<input id="EndDate" type="text" class="form-control lr-input-wdatepicker" autocomplete="off" onfocus="WdatePicker({ dateFmt:'yyyy-MM-dd HH:mm',onpicked: function () { $('#EndDate').trigger('change'); } })" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">请假天数</div>
<input id="LeaveDay" type="text" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item" data-table="DtStuLeave" >
<div class="lr-form-item-title">请假事由<font face="宋体">*</font></div>
<textarea id="LeaveReason" class="form-control" style="height:100px;" isvalid="yes" checkexpession="NotNull" ></textarea>
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" style="display: none; " >
<div class="lr-form-item-title">申请时间</div>
<input id="LeaveAddTime" type="text" readonly class="form-control currentInfo lr-currentInfo-time" autocomplete="off" />
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" style="display: none; " >
<div class="lr-form-item-title">当前状态</div>
<input id="FlowNo" type="text" class="form-control" />
</div>
<div class="col-xs-4 lr-form-item" data-table="DtStuLeave" style="display: none; " >
<div class="lr-form-item-title">修改时间</div>
<input id="LastUpTime" type="text" readonly class="form-control currentInfo lr-currentInfo-time" />
</div>
</div>
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/DtStuLeave/Form.js")

+ 111
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Form.js Voir le fichier

@@ -0,0 +1,111 @@
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
* 创建人:超级管理员
* 日 期:2021-06-10 19:26
* 描 述:学生请假,审核
*/
var acceptClick;
var keyValue = request('keyValue');
// 设置权限
var setAuthorize;
// 设置表单数据
var setFormData;
// 验证数据是否填写完整
var validForm;
// 保存数据
var save;
var bootstrap = function ($, learun) {
"use strict";
// 设置权限
setAuthorize = function (data) {
if(!!data)
{
for (var field in data) {
if (data[field].isLook != 1) {// 如果没有查看权限就直接移除
$('#' + data[field].fieldId).parent().remove();
}
else {
if (data[field].isEdit != 1) {
$('#' + data[field].fieldId).attr('disabled', 'disabled');
if ($('#' + data[field].fieldId).hasClass('lrUploader-wrap')) {
$('#' + data[field].fieldId).css({ 'padding-right': '58px' });
$('#' + data[field].fieldId).find('.btn-success').remove();
}
}
}
}
}
};
var page = {
init: function () {
$('.lr-form-wrap').lrscroll();
page.bind();
page.initData();
},
bind: function () {
$('#CreateUserName')[0].lrvalue = learun.clientdata.get(['userinfo']).userId;
$('#CreateUserName').val(learun.clientdata.get(['userinfo']).realName);
$('#CreateUserDeptNo').lrDataSourceSelect({ code: 'CdDeptInfo',value: 'deptid',text: 'deptname' });
$('#CreateUserClassNo').lrDataSourceSelect({ code: 'bjsj',value: 'classno',text: 'classname' });
$('#LeaveType').lrDataItemSelect({ code: 'LeaveType' });
$('#LeaveAddTime').val(learun.formatDate(new Date(), 'yyyy-MM-dd hh:mm:ss'));
$('#LastUpTime').val(learun.formatDate(new Date(), 'yyyy-MM-dd hh:mm:ss'));
},
initData: function () {
if (!!keyValue) {
$.lrSetForm(top.$.rootUrl + '/EducationalAdministration/DtStuLeave/GetFormData?keyValue=' + keyValue, function (data) {
for (var id in data) {
if (!!data[id].length && data[id].length > 0) {
$('#' + id ).jfGridSet('refreshdata', data[id]);
}
else {
$('[data-table="' + id + '"]').lrSetFormData(data[id]);
}
}
});
}
}
};
// 设置表单数据
setFormData = function (processId,param,callback) {
if (!!processId) {
$.lrSetForm(top.$.rootUrl + '/EducationalAdministration/DtStuLeave/GetFormDataByProcessId?processId=' + processId, function (data) {
for (var id in data) {
if (!!data[id] && data[id].length > 0) {
$('#' + id ).jfGridSet('refreshdata', data[id]);
}
else {
if(id == 'DtStuLeave' && data[id] ){
keyValue = data[id].Id;
}
$('[data-table="' + id + '"]').lrSetFormData(data[id]);
}
}
});
}
callback && callback(); }
// 验证数据是否填写完整
validForm = function () {
if (!$('body').lrValidform()) {
return false;
}
return true;
};
// 保存数据
save = function (processId, callBack, i) {
var formData = $('body').lrGetFormData();
if(!!processId){
formData.processId =processId;
}
var postData = {
strEntity: JSON.stringify(formData)
};
$.lrSaveForm(top.$.rootUrl + '/EducationalAdministration/DtStuLeave/SaveForm?keyValue=' + keyValue, postData, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack(res, i);
}
});
};
page.init();
}

+ 52
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Index.cshtml Voir le fichier

@@ -0,0 +1,52 @@
@{
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-12 lr-form-item">
<div class="lr-form-item-title">所属系</div>
<div id="CreateUserDeptNo"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">所属班级</div>
<div id="CreateUserClassNo"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">请假类型</div>
<div id="LeaveType"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">请假事由</div>
<input id="LeaveReason" type="text" class="form-control" />
</div>
@*<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">当前状态</div>
<input id="FlowNo" 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_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;新增</a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;编辑</a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
</div>
</div>
</div>
<div class="lr-layout-body" id="gridtable"></div>
</div>
</div>
</div>
@Html.AppendJsFile("/Areas/EducationalAdministration/Views/DtStuLeave/Index.js")

+ 217
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/EducationalAdministration/Views/DtStuLeave/Index.js Voir le fichier

@@ -0,0 +1,217 @@
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
* 创建人:超级管理员
* 日 期:2021-06-10 19:26
* 描 述:学生请假,审核
*/
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);
$('#CreateUserDeptNo').lrDataSourceSelect({ code: 'CdDeptInfo', value: 'deptid', text: 'deptname' });
$('#CreateUserClassNo').lrDataSourceSelect({ code: 'bjsj', value: 'classno', text: 'classname' });
$('#LeaveType').lrDataItemSelect({ code: 'LeaveType' });
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
// 新增
$('#lr_add').on('click', function () {
learun.layerForm({
id: 'form',
title: '新增',
url: top.$.rootUrl + '/EducationalAdministration/DtStuLeave/Form',
width: 900,
height: 400,
callBack: function (id) {
var res = false;
// 验证数据
res = top[id].validForm();
// 保存数据
if (res) {
processId = learun.newGuid();
res = top[id].save(processId, refreshGirdData);
}
return res;
}
});
});
// 编辑
$('#lr_edit').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
if (learun.checkrow(keyValue)) {
var FlowNo = $('#gridtable').jfGridValue('FlowNo');
if (FlowNo != 0) {
learun.alert.warning("当前项目已提交不能编辑!");
return;
}
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/EducationalAdministration/DtStuLeave/Form?keyValue=' + keyValue,
width: 900,
height: 400,
callBack: function (id) {
var res = false;
// 验证数据
res = top[id].validForm();
// 保存数据
if (res) {
res = top[id].save('', function () {
page.search();
});
}
return res;
}
});
}
});
//提交
$('#lr_submit').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
if (learun.checkrow(keyValue)) {
var FlowNo = $('#gridtable').jfGridValue('FlowNo');
if (FlowNo != 0) {
learun.alert.warning("当前项目已提交,请耐心等待审批!");
return;
}
learun.layerConfirm('是否确认提交该项!', function (res) {
if (res) {
processId = learun.newGuid();
learun.postForm(top.$.rootUrl + '/EducationalAdministration/DtStuLeave/SubmitList', { keyValue: keyValue, FlowNo: 1 }, function (res) {
refreshGirdData(res, {});
});
}
});
}
});
// 删除
$('#lr_delete').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('Id');
if (learun.checkrow(keyValue)) {
var FlowNo = $('#gridtable').jfGridValue('FlowNo');
if (FlowNo != 0) {
learun.alert.warning("当前项目已提交不能编辑!");
return;
}
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/EducationalAdministration/DtStuLeave/DeleteForm', { keyValue: keyValue }, function () {
refreshGirdData();
});
}
});
}
});

},
// 初始化列表
initGird: function () {
$('#gridtable').lrAuthorizeJfGrid({
url: top.$.rootUrl + '/EducationalAdministration/DtStuLeave/GetPageList',
headData: [
{
label: "申请人", name: "CreateUserName", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('user', {
key: value,
callback: function (_data) {
callback(_data.name);
}
});
}
},
{
label: "所属系", name: "CreateUserDeptNo", 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: 'deptid',
callback: function (_data) {
callback(_data['deptname']);
}
});
}
},
{
label: "所属班级", name: "CreateUserClassNo", 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: "LeaveType", width: 100, align: "left",
formatterAsync: function (callback, value, row, op, $cell) {
learun.clientdata.getAsync('dataItem', {
key: value,
code: 'LeaveType',
callback: function (_data) {
callback(_data.text);
}
});
}
},
{ label: "开始时间", name: "BeginDate", width: 100, align: "left" },
{ label: "结束时间", name: "EndDate", width: 100, align: "left" },
{ label: "请假天数", name: "LeaveDay", width: 100, align: "left" },
{ label: "请假事由", name: "LeaveReason", width: 100, align: "left" },
{ label: "申请时间", name: "LeaveAddTime", width: 100, align: "left" },
{
label: "当前状态", name: "FlowNo", width: 100, align: "left",
formatter: function (cellvalue, row) {
if (cellvalue == 0) {
return '<span class=\"label label-warning\">草稿</span>';
} if (cellvalue == 1) {
return '<span class=\"label label-warning\">审批中</span>';
} else if (cellvalue == 2) {
return '<span class=\"label label-success\">审批通过</span>';
}
}
},
{ label: "修改时间", name: "LastUpTime", width: 100, align: "left" },
],
mainId: 'Id',
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: '',// 填写流程对应模板编号
processId: processId,
level: '1',
};
learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) {
learun.loading(false);
});
}
page.search();
}
};
page.init();
}

+ 1
- 12
Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj Voir le fichier

@@ -822,6 +822,7 @@
<Compile Include="Areas\CustomFunction\Controllers\OfficialSealController.cs" />
<Compile Include="Areas\CustomFunction\Controllers\OfficialSealUseController.cs" />
<Compile Include="Areas\CustomFunction\Controllers\OfficialSealRecordController.cs" />
<Compile Include="Areas\EducationalAdministration\Controllers\DtStuLeaveController.cs" />
</ItemGroup>
<ItemGroup>
<Content Include="Areas\AdmissionsPlatform\Views\AP_OnlineUserInfo\DropOutIndex.js" />
@@ -6429,18 +6430,6 @@
<Content Include="Areas\LogisticsManagement\Views\pxzhusuguanli\Index.js" />
<Content Include="Areas\LogisticsManagement\Views\pxzhusuguanli\Form.cshtml" />
<Content Include="Areas\LogisticsManagement\Views\pxzhusuguanli\Form.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSeal\Index.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSeal\Index.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSeal\Form.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSeal\Form.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSealUse\Index.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSealUse\Index.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSealUse\Form.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSealUse\Form.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSealRecord\Index.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSealRecord\Index.js" />
<Content Include="Areas\CustomFunction\Views\OfficialSealRecord\Form.cshtml" />
<Content Include="Areas\CustomFunction\Views\OfficialSealRecord\Form.js" />
</ItemGroup>
<ItemGroup>
<Folder Include="Areas\LR_Desktop\Models\" />


+ 29
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/EducationalAdministration/DtStuLeaveMap.cs Voir le fichier

@@ -0,0 +1,29 @@
using Learun.Application.TwoDevelopment.EducationalAdministration;
using System.Data.Entity.ModelConfiguration;

namespace Learun.Application.Mapping
{
/// <summary>
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public class DtStuLeaveMap : EntityTypeConfiguration<DtStuLeaveEntity>
{
public DtStuLeaveMap()
{
#region 表、主键
//表
this.ToTable("DTSTULEAVE");
//主键
this.HasKey(t => t.Id);
#endregion

#region 配置关系
#endregion
}
}
}


+ 1
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj Voir le fichier

@@ -571,6 +571,7 @@
<Compile Include="CustomFunction\OfficialSealMap.cs" />
<Compile Include="CustomFunction\OfficialSealUseMap.cs" />
<Compile Include="CustomFunction\OfficialSealRecordMap.cs" />
<Compile Include="EducationalAdministration\DtStuLeaveMap.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj">


+ 148
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveBLL.cs Voir le fichier

@@ -0,0 +1,148 @@
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 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public class DtStuLeaveBLL : DtStuLeaveIBLL
{
private DtStuLeaveService dtStuLeaveService = new DtStuLeaveService();

#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<DtStuLeaveEntity> GetPageList(Pagination pagination, string queryJson)
{
try
{
return dtStuLeaveService.GetPageList(pagination, queryJson);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 获取DtStuLeave表实体数据
/// </summary>
/// <param name="keyValue">主键</param>
/// <returns></returns>
public DtStuLeaveEntity GetDtStuLeaveEntity(string keyValue)
{
try
{
return dtStuLeaveService.GetDtStuLeaveEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 获取主表实体数据
/// </summary>
/// <param name="processId">流程实例ID</param>
/// <returns></returns>
public DtStuLeaveEntity GetEntityByProcessId(string processId)
{
try
{
return dtStuLeaveService.GetEntityByProcessId(processId);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// </summary>
/// <param name="keyValue">主键</param>
public void DeleteEntity(string keyValue)
{
try
{
dtStuLeaveService.DeleteEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// </summary>
/// <param name="keyValue">主键</param>
/// <param name="entity">实体</param>
public void SaveEntity(string keyValue, DtStuLeaveEntity entity)
{
try
{
dtStuLeaveService.SaveEntity(keyValue, entity);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

}
}

+ 140
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveEntity.cs Voir le fichier

@@ -0,0 +1,140 @@
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 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public class DtStuLeaveEntity
{
#region 实体成员
/// <summary>
/// 主键
/// </summary>
[Column("ID")]
public string Id { get; set; }
/// <summary>
/// 请假类型
/// </summary>
[Column("LEAVETYPE")]
public string LeaveType { get; set; }
/// <summary>
/// 开始时间
/// </summary>
[Column("BEGINDATE")]
public DateTime? BeginDate { get; set; }
/// <summary>
/// 结束时间
/// </summary>
[Column("ENDDATE")]
public DateTime? EndDate { get; set; }
/// <summary>
/// 当前位置
/// </summary>
[Column("LEAVEADDRESS")]
public string LeaveAddress { get; set; }
/// <summary>
/// 申请时间
/// </summary>
[Column("LEAVEADDTIME")]
public DateTime? LeaveAddTime { get; set; }
/// <summary>
/// 请假天数
/// </summary>
[Column("LEAVEDAY")]
public decimal? LeaveDay { get; set; }
/// <summary>
/// 请假事由
/// </summary>
[Column("LEAVEREASON")]
public string LeaveReason { get; set; }
/// <summary>
/// 申请人ID
/// </summary>
[Column("CREATEUSERID")]
public string CreateUserId { get; set; }
/// <summary>
/// 申请人编号
/// </summary>
[Column("CREATEUSERNO")]
public string CreateUserNo { get; set; }
/// <summary>
/// 申请人
/// </summary>
[Column("CREATEUSERNAME")]
public string CreateUserName { get; set; }
/// <summary>
/// 所属系
/// </summary>
[Column("CREATEUSERDEPTNO")]
public string CreateUserDeptNo { get; set; }
/// <summary>
/// 所属班级
/// </summary>
[Column("CREATEUSERCLASSNO")]
public string CreateUserClassNo { get; set; }
/// <summary>
/// 审核人ID
/// </summary>
[Column("AUDITUSERID")]
public string AuditUserId { get; set; }
/// <summary>
/// 审核人编号
/// </summary>
[Column("AUDITUSERNO")]
public string AuditUserNo { get; set; }
/// <summary>
/// 审核时间
/// </summary>
[Column("AUDITTIME")]
public DateTime? AuditTime { get; set; }
/// <summary>
/// 审核备注
/// </summary>
[Column("CHECKREMARK")]
public string CheckRemark { get; set; }
/// <summary>
/// 申请时间
/// </summary>
[Column("LASTUPTIME")]
public DateTime? LastUpTime { get; set; }
/// <summary>
/// 审核状态
/// </summary>
[Column("FLOWNO")]
public string FlowNo { get; set; }
/// <summary>
/// 流程编码
/// </summary>
[Column("PROCESSID")]
public string processId { get; set; }
#endregion

#region 扩展操作
/// <summary>
/// 新增调用
/// </summary>
public void Create()
{
this.Id = Guid.NewGuid().ToString();
}
/// <summary>
/// 编辑调用
/// </summary>
/// <param name="keyValue"></param>
public void Modify(string keyValue)
{
this.Id = keyValue;
}
#endregion
#region 扩展字段
#endregion
}
}


+ 55
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveIBLL.cs Voir le fichier

@@ -0,0 +1,55 @@
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 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public interface DtStuLeaveIBLL
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
IEnumerable<DtStuLeaveEntity> GetPageList(Pagination pagination, string queryJson);
/// <summary>
/// 获取DtStuLeave表实体数据
/// </summary>
/// <param name="keyValue">主键</param>
/// <returns></returns>
DtStuLeaveEntity GetDtStuLeaveEntity(string keyValue);
/// <summary>
/// 获取主表实体数据
/// </summary>
/// <param name="processId">流程实例ID</param>
/// <returns></returns>
DtStuLeaveEntity GetEntityByProcessId(string processId);
#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// </summary>
/// <param name="keyValue">主键</param>
void DeleteEntity(string keyValue);
/// <summary>
/// 保存实体数据(新增、修改)
/// </summary>
/// <param name="keyValue">主键</param>
/// <param name="entity">实体</param>
void SaveEntity(string keyValue, DtStuLeaveEntity entity);
#endregion

}
}

+ 205
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/EducationalAdministration/DtStuLeave/DtStuLeaveService.cs Voir le fichier

@@ -0,0 +1,205 @@
using Dapper;
using Learun.DataBase.Repository;
using Learun.Util;
using System;
using System.Collections.Generic;
using System.Data;
using System.Text;

namespace Learun.Application.TwoDevelopment.EducationalAdministration
{
/// <summary>
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
/// 创 建:超级管理员
/// 日 期:2021-06-10 19:26
/// 描 述:学生请假,审核
/// </summary>
public class DtStuLeaveService : RepositoryFactory
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<DtStuLeaveEntity> GetPageList(Pagination pagination, string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(@"
t.Id,
t.CreateUserName,
t.CreateUserDeptNo,
t.CreateUserClassNo,
t.LeaveType,
t.BeginDate,
t.EndDate,
t.LeaveDay,
t.LeaveReason,
t.LeaveAddTime,
t.FlowNo,
t.LastUpTime
");
strSql.Append(" FROM DtStuLeave t ");
strSql.Append(" WHERE 1=1 ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
if (!queryParam["CreateUserDeptNo"].IsEmpty())
{
dp.Add("CreateUserDeptNo",queryParam["CreateUserDeptNo"].ToString(), DbType.String);
strSql.Append(" AND t.CreateUserDeptNo = @CreateUserDeptNo ");
}
if (!queryParam["CreateUserClassNo"].IsEmpty())
{
dp.Add("CreateUserClassNo",queryParam["CreateUserClassNo"].ToString(), DbType.String);
strSql.Append(" AND t.CreateUserClassNo = @CreateUserClassNo ");
}
if (!queryParam["LeaveType"].IsEmpty())
{
dp.Add("LeaveType",queryParam["LeaveType"].ToString(), DbType.String);
strSql.Append(" AND t.LeaveType = @LeaveType ");
}
if (!queryParam["LeaveReason"].IsEmpty())
{
dp.Add("LeaveReason", "%" + queryParam["LeaveReason"].ToString() + "%", DbType.String);
strSql.Append(" AND t.LeaveReason Like @LeaveReason ");
}
if (!queryParam["FlowNo"].IsEmpty())
{
dp.Add("FlowNo", "%" + queryParam["FlowNo"].ToString() + "%", DbType.String);
strSql.Append(" AND t.FlowNo Like @FlowNo ");
}
return this.BaseRepository("CollegeMIS").FindList<DtStuLeaveEntity>(strSql.ToString(),dp, pagination);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 获取DtStuLeave表实体数据
/// </summary>
/// <param name="keyValue">主键</param>
/// <returns></returns>
public DtStuLeaveEntity GetDtStuLeaveEntity(string keyValue)
{
try
{
return this.BaseRepository("CollegeMIS").FindEntity<DtStuLeaveEntity>(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 获取主表实体数据
/// </summary>
/// <param name="processId">流程实例ID</param>
/// <returns></returns>
public DtStuLeaveEntity GetEntityByProcessId(string processId)
{
try
{
return this.BaseRepository("CollegeMIS").FindEntity<DtStuLeaveEntity>(t=>t.processId == processId);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// </summary>
/// <param name="keyValue">主键</param>
public void DeleteEntity(string keyValue)
{
try
{
this.BaseRepository("CollegeMIS").Delete<DtStuLeaveEntity>(t=>t.Id == keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// </summary>
/// <param name="keyValue">主键</param>
/// <param name="entity">实体</param>
/// <returns></returns>
public void SaveEntity(string keyValue, DtStuLeaveEntity entity)
{
try
{
if (!string.IsNullOrEmpty(keyValue))
{
entity.Modify(keyValue);
this.BaseRepository("CollegeMIS").Update(entity);
}
else
{
entity.Create();
this.BaseRepository("CollegeMIS").Insert(entity);
}
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

}
}

+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj Voir le fichier

@@ -1702,6 +1702,10 @@
<Compile Include="CustomFunction\OfficialSealRecord\OfficialSealRecordService.cs" />
<Compile Include="CustomFunction\OfficialSealRecord\OfficialSealRecordBLL.cs" />
<Compile Include="CustomFunction\OfficialSealRecord\OfficialSealRecordIBLL.cs" />
<Compile Include="EducationalAdministration\DtStuLeave\DtStuLeaveEntity.cs" />
<Compile Include="EducationalAdministration\DtStuLeave\DtStuLeaveService.cs" />
<Compile Include="EducationalAdministration\DtStuLeave\DtStuLeaveBLL.cs" />
<Compile Include="EducationalAdministration\DtStuLeave\DtStuLeaveIBLL.cs" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj">


Chargement…
Annuler
Enregistrer