@@ -0,0 +1,151 @@ | |||||
using System; | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Web.Mvc; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.Web.Areas.ReceiveSendFeeManagement.Controllers | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public class FD_BudgetBasicsController : MvcControllerBase | |||||
{ | |||||
private FD_BudgetBasicsIBLL fD_BudgetBasicsIBLL = new FD_BudgetBasicsBLL(); | |||||
#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 = fD_BudgetBasicsIBLL.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 FD_BudgetBasicsData = fD_BudgetBasicsIBLL.GetFD_BudgetBasicsEntity( keyValue ); | |||||
var jsonData = new { | |||||
FD_BudgetBasics = FD_BudgetBasicsData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
/// <summary> | |||||
/// 获取表单数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetFormDataByProcessId(string processId) | |||||
{ | |||||
var FD_BudgetBasicsData = fD_BudgetBasicsIBLL.GetFormDataByProcessId(processId); | |||||
var jsonData = new | |||||
{ | |||||
FD_BudgetBasics = FD_BudgetBasicsData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
#endregion | |||||
#region 提交数据 | |||||
/// <summary> | |||||
/// 删除实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult DeleteForm(string keyValue) | |||||
{ | |||||
var entity = fD_BudgetBasicsIBLL.GetFD_BudgetBasicsEntity(keyValue); | |||||
entity.BIsDelete = true; | |||||
entity.BDeleteTime=DateTime.Now; | |||||
entity.BDeleteUser = LoginUserInfo.Get().userId; | |||||
fD_BudgetBasicsIBLL.SaveEntity(keyValue, entity); | |||||
return Success("删除成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="strEntity">实体</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[ValidateAntiForgeryToken] | |||||
[AjaxOnly] | |||||
public ActionResult SaveForm(string keyValue, string strEntity) | |||||
{ | |||||
FD_BudgetBasicsEntity entity = strEntity.ToObject<FD_BudgetBasicsEntity>(); | |||||
fD_BudgetBasicsIBLL.SaveEntity(keyValue,entity); | |||||
if (string.IsNullOrEmpty(keyValue)) | |||||
{ | |||||
} | |||||
return Success("保存成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 提交资助变更 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult ChangeStatusById(string keyValue, string processId) | |||||
{ | |||||
fD_BudgetBasicsIBLL.ChangeStatusById(keyValue, 1, processId); | |||||
return Success("操作成功!"); | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,122 @@ | |||||
using System; | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Web.Mvc; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.Web.Areas.ReceiveSendFeeManagement.Controllers | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public class FD_IncomeManageController : MvcControllerBase | |||||
{ | |||||
private FD_IncomeManageIBLL fD_IncomeManageIBLL = new FD_IncomeManageBLL(); | |||||
#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 = fD_IncomeManageIBLL.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 FD_IncomeManageData = fD_IncomeManageIBLL.GetFD_IncomeManageEntity( keyValue ); | |||||
var jsonData = new { | |||||
FD_IncomeManage = FD_IncomeManageData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
#endregion | |||||
#region 提交数据 | |||||
/// <summary> | |||||
/// 删除实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult DeleteForm(string keyValue) | |||||
{ | |||||
var entity = fD_IncomeManageIBLL.GetFD_IncomeManageEntity(keyValue); | |||||
entity.IIsDelete = true; | |||||
entity.IDeleteTime = DateTime.Now; | |||||
entity.IDeleteUser = LoginUserInfo.Get().userId; | |||||
fD_IncomeManageIBLL.SaveEntity(keyValue, entity); | |||||
return Success("删除成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="strEntity">实体</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[ValidateAntiForgeryToken] | |||||
[AjaxOnly] | |||||
public ActionResult SaveForm(string keyValue, string strEntity) | |||||
{ | |||||
FD_IncomeManageEntity entity = strEntity.ToObject<FD_IncomeManageEntity>(); | |||||
fD_IncomeManageIBLL.SaveEntity(keyValue,entity); | |||||
if (string.IsNullOrEmpty(keyValue)) | |||||
{ | |||||
} | |||||
return Success("保存成功!"); | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,171 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Web.Mvc; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.Web.Areas.ReceiveSendFeeManagement.Controllers | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public class FD_PayManageController : MvcControllerBase | |||||
{ | |||||
private FD_PayManageIBLL fD_PayManageIBLL = new FD_PayManageBLL(); | |||||
private FD_IncomeManageIBLL fD_IncomeManageIBLL = new FD_IncomeManageBLL(); | |||||
#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 = fD_PayManageIBLL.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 FD_PayManageData = fD_PayManageIBLL.GetFD_PayManageEntity(keyValue); | |||||
var jsonData = new | |||||
{ | |||||
FD_PayManage = FD_PayManageData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
/// <summary> | |||||
/// 获取表单数据 | |||||
/// </summary> | |||||
/// <param name="processId">流程Id</param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetFormDataByProcessId(string processId) | |||||
{ | |||||
var FD_PayManageData = fD_PayManageIBLL.GetFormDataByProcessId(processId); | |||||
var jsonData = new | |||||
{ | |||||
FD_PayManage = FD_PayManageData, | |||||
}; | |||||
return Success(jsonData); | |||||
} | |||||
/// <summary> | |||||
/// 获取收入预算下拉框列表 | |||||
/// </summary> | |||||
/// <param name=""></param> | |||||
/// <returns></returns> | |||||
[HttpGet] | |||||
[AjaxOnly] | |||||
public ActionResult GetIncomeList(string budgetType, string financeBudgetType) | |||||
{ | |||||
var fD_IncomeManageData = fD_IncomeManageIBLL.GetIncomeList(budgetType, financeBudgetType); | |||||
var list = new List<object>(); | |||||
foreach (var item in fD_IncomeManageData) | |||||
{ | |||||
list.Add(new | |||||
{ | |||||
text = item.IName, | |||||
value = item.IId, | |||||
}); | |||||
} | |||||
return Success(list); | |||||
} | |||||
#endregion | |||||
#region 提交数据 | |||||
/// <summary> | |||||
/// 删除实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult DeleteForm(string keyValue) | |||||
{ | |||||
fD_PayManageIBLL.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) | |||||
{ | |||||
FD_PayManageEntity entity = strEntity.ToObject<FD_PayManageEntity>(); | |||||
fD_PayManageIBLL.SaveEntity(keyValue, entity); | |||||
if (string.IsNullOrEmpty(keyValue)) | |||||
{ | |||||
} | |||||
return Success("保存成功!"); | |||||
} | |||||
/// <summary> | |||||
/// 提交 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <returns></returns> | |||||
[HttpPost] | |||||
[AjaxOnly] | |||||
public ActionResult ChangeStatusById(string keyValue, string processId) | |||||
{ | |||||
fD_PayManageIBLL.ChangeStatusById(keyValue, 1, processId); | |||||
return Success("操作成功!"); | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,15 @@ | |||||
@{ | |||||
ViewBag.Title = "基础信息上报"; | |||||
Layout = "~/Views/Shared/_Form.cshtml"; | |||||
} | |||||
<div class="lr-form-wrap" id="form"> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_BudgetBasics" > | |||||
<div class="lr-form-item-title">附件上传</div> | |||||
<div id="BFile" ></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_BudgetBasics" > | |||||
<div class="lr-form-item-title">备注</div> | |||||
<textarea id="BRemarks" class="form-control" style="height:100px;" ></textarea> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/ReceiveSendFeeManagement/Views/FD_BudgetBasics/Form.js") |
@@ -0,0 +1,117 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-27 17:42 | |||||
* 描 述:基础信息上报 | |||||
*/ | |||||
var acceptClick; | |||||
var keyValue = request('keyValue'); | |||||
// 设置权限 | |||||
var setAuthorize; | |||||
// 设置表单数据 | |||||
var setFormData; | |||||
// 验证数据是否填写完整 | |||||
var validForm; | |||||
// 保存数据 | |||||
var save; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
$('.lr-form-wrap').lrscroll(); | |||||
page.bind(); | |||||
page.initData(); | |||||
}, | |||||
bind: function () { | |||||
$('#BFile').lrUploader(); | |||||
}, | |||||
initData: function () { | |||||
if (!!keyValue) { | |||||
$.lrSetForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/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 + '/ReceiveSendFeeManagement/FD_BudgetBasics/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 == 'FD_BudgetBasics' && data[id]) { | |||||
keyValue = data[id].BId; | |||||
} | |||||
$('[data-table="' + id + '"]').lrSetFormData(data[id]); | |||||
//setTimeout(function () { | |||||
// ue.setContent(data[id].F_NewsContent); | |||||
//}, 100); | |||||
} | |||||
} | |||||
}); | |||||
} | |||||
callback && callback(); | |||||
} | |||||
// 验证数据是否填写完整 | |||||
validForm = function () { | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
return true; | |||||
}; | |||||
// 保存数据 | |||||
save = function (processId, callBack, i) { | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
var postData = {}; | |||||
var strEntity = $('body').lrGetFormData(); | |||||
if (!!processId) { | |||||
strEntity.BProcessId = processId; | |||||
} | |||||
postData.strEntity = JSON.stringify(strEntity); | |||||
$.lrSaveForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||||
if (!!processId) { | |||||
var res = {}; | |||||
res.code = 200; | |||||
if (!!callBack) { | |||||
callBack(res, i); | |||||
} | |||||
} else { | |||||
// 保存成功后才回调 | |||||
if (!!callBack) { | |||||
callBack(res, strEntity, i); | |||||
} | |||||
} | |||||
}); | |||||
}; | |||||
// 保存数据 | |||||
//acceptClick = function (callBack) { | |||||
// if (!$('body').lrValidform()) { | |||||
// return false; | |||||
// } | |||||
// var postData = { | |||||
// strEntity: JSON.stringify($('body').lrGetFormData()) | |||||
// }; | |||||
// $.lrSaveForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||||
// // 保存成功后才回调 | |||||
// if (!!callBack) { | |||||
// callBack(); | |||||
// } | |||||
// }); | |||||
//}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,31 @@ | |||||
@{ | |||||
ViewBag.Title = "基础信息上报"; | |||||
Layout = "~/Views/Shared/_Index.cshtml"; | |||||
} | |||||
<div class="lr-layout " > | |||||
<div class="lr-layout-center"> | |||||
<div class="lr-layout-wrap lr-layout-wrap-notitle "> | |||||
<div class="lr-layout-tool"> | |||||
<div class="lr-layout-tool-left"> | |||||
<div class="lr-layout-tool-item"> | |||||
<div id="datesearch"></div> | |||||
</div> | |||||
</div> | |||||
<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/ReceiveSendFeeManagement/Views/FD_BudgetBasics/Index.js") |
@@ -0,0 +1,191 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-27 17:42 | |||||
* 描 述:基础信息上报 | |||||
*/ | |||||
var refreshGirdData; | |||||
var processId = ''; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var startTime; | |||||
var endTime; | |||||
var page = { | |||||
init: function () { | |||||
page.initGird(); | |||||
page.bind(); | |||||
}, | |||||
bind: function () { | |||||
// 时间搜索框 | |||||
$('#datesearch').lrdate({ | |||||
dfdata: [ | |||||
{ name: '今天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00') }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||||
{ name: '近7天', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'd', -6) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||||
{ name: '近1个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -1) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } }, | |||||
{ name: '近3个月', begin: function () { return learun.getDate('yyyy-MM-dd 00:00:00', 'm', -3) }, end: function () { return learun.getDate('yyyy-MM-dd 23:59:59') } } | |||||
], | |||||
// 月 | |||||
mShow: false, | |||||
premShow: false, | |||||
// 季度 | |||||
jShow: false, | |||||
prejShow: false, | |||||
// 年 | |||||
ysShow: false, | |||||
yxShow: false, | |||||
preyShow: false, | |||||
yShow: false, | |||||
// 默认 | |||||
dfvalue: '1', | |||||
selectfn: function (begin, end) { | |||||
startTime = begin; | |||||
endTime = end; | |||||
page.search(); | |||||
} | |||||
}); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
// 新增 | |||||
$('#lr_add').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '新增', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/Form', | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
top[id].save(); | |||||
return location.reload(); | |||||
} | |||||
}); | |||||
}); | |||||
// 编辑 | |||||
$('#lr_edit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('BId'); | |||||
var status = $('#gridtable').jfGridValue('BStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,不可修改!"); | |||||
return; | |||||
} | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/Form?keyValue=' + keyValue, | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
top[id].save(); | |||||
return refreshGirdData('', ''); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 删除 | |||||
$('#lr_delete').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('BId'); | |||||
var status = $('#gridtable').jfGridValue('BStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,不可删除!"); | |||||
return; | |||||
} | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||||
if (res) { | |||||
learun.deleteForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/DeleteForm', { keyValue: keyValue }, function () { | |||||
refreshGirdData('', ''); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 打印 | |||||
$('#lr_print').on('click', function () { | |||||
$('#gridtable').jqprintTable(); | |||||
}); | |||||
// 提交 | |||||
$('#lr_submit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('BId'); | |||||
if (learun.checkrow(keyValue)) { | |||||
var status = $('#gridtable').jfGridValue('BStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,请耐心等待审批!"); | |||||
return; | |||||
} | |||||
learun.layerConfirm('是否确认提交该项!', function (res) { | |||||
if (res) { | |||||
processId = learun.newGuid(); | |||||
learun.postForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/ChangeStatusById', { keyValue: keyValue, processId: processId }, function (res) { | |||||
refreshGirdData(res, {}); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_BudgetBasics/GetPageList', | |||||
headData: [ | |||||
{ label: "姓名", name: "BName", width: 100, align: "left" }, | |||||
{ | |||||
label: '部门', name: 'BDept', width: 100, align: 'left', | |||||
formatterAsync: function (callback, value, row) { | |||||
learun.clientdata.getAsync('department', { | |||||
key: value, | |||||
callback: function (item) { | |||||
callback(item.name); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ label: "创建时间", name: "BCreateTime", width: 150, align: "left" }, | |||||
{ | |||||
label: "状态", name: "BStatus", width: 100, align: "left", | |||||
formatter: function (cellvalue) { | |||||
if (cellvalue == 0) { | |||||
return '<span class=\"label label-default\" style=\"cursor: pointer;\">草稿</span>'; | |||||
} else if (cellvalue == 1) { | |||||
return '<span class=\"label label-warning\" style=\"cursor: pointer;\">审批中</span>'; | |||||
} else if (cellvalue == 2) { | |||||
return '<span class=\"label label-success\" style=\"cursor: pointer;\">已审批</span>'; | |||||
} | |||||
} | |||||
}, | |||||
{ label: "备注", name: "BRemarks", width: 100, align: "left" } | |||||
], | |||||
mainId: 'BId', | |||||
isPage: true | |||||
}); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
param.StartTime = startTime; | |||||
param.EndTime = endTime; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
//refreshGirdData = function () { | |||||
// $('#gridtable').jfGridSet('reload'); | |||||
//}; | |||||
refreshGirdData = function (res, postData) { | |||||
if (res && res.code && res.code == 200) { | |||||
// 发起流程 | |||||
var postData = { | |||||
schemeCode: 'FD_BudgetBasics',// 填写流程对应模板编号 | |||||
processId: processId, | |||||
level: '1', | |||||
}; | |||||
learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) { | |||||
learun.loading(false); | |||||
}); | |||||
} | |||||
page.search(); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,43 @@ | |||||
@{ | |||||
ViewBag.Title = "收入预算管理"; | |||||
Layout = "~/Views/Shared/_Form.cshtml"; | |||||
} | |||||
<div class="lr-form-wrap" id="form"> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title">项目编号</div> | |||||
<input id="IEnCode" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title">项目名称<font face="宋体">*</font></div> | |||||
<input id="IName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title">预算类型<font face="宋体">*</font></div> | |||||
<div id="ITopType" isvalid="yes" checkexpession="NotNull" ></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title">预算科目</div> | |||||
<div id="ISecondType" ></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage"> | |||||
<div class="lr-form-item-title">人数</div> | |||||
<input id="IPeopleNum" type="number" class="form-control" isvalid="yes" checkexpession="NumOrNull" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title" id="idIQuota">定额<font face="宋体">*</font></div> | |||||
<input id="IQuota" type="number" class="form-control" isvalid="yes" checkexpession="Num" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage"> | |||||
<div class="lr-form-item-title" id="idIAmount">金额<font face="宋体">*</font></div> | |||||
<input id="IAmount" type="number" class="form-control" isvalid="yes" checkexpession="Num" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_IncomeManage" id="divIActual" style="display: none" > | |||||
<div class="lr-form-item-title">年度实际收入<font face="宋体">*</font></div> | |||||
<input id="IActual" type="number" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_IncomeManage" > | |||||
<div class="lr-form-item-title">备注</div> | |||||
<textarea id="IRemarks" class="form-control" style="height:100px;" ></textarea> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/ReceiveSendFeeManagement/Views/FD_IncomeManage/Form.js") |
@@ -0,0 +1,86 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-28 10:40 | |||||
* 描 述:收入预算管理 | |||||
*/ | |||||
var acceptClick; | |||||
var keyValue = request('keyValue'); | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
$('.lr-form-wrap').lrscroll(); | |||||
page.bind(); | |||||
page.initData(); | |||||
}, | |||||
bind: function () { | |||||
$('#ITopType').lrDataItemSelect({ | |||||
code: 'BudgetType', select: function (item) { | |||||
if (item) { | |||||
if (item.id == '0' || item.text == '财政预算') { | |||||
$('#ISecondType').removeAttr("readonly"); | |||||
$('#idIQuota').html('定额<font face="宋体">*</font>'); | |||||
document.getElementById("divIActual").style.display = "none"; | |||||
} else { | |||||
$('#IPeopleNum').attr('readonly', 'readonly'); | |||||
$('#ISecondType').lrDataItemSelect({ code: 'financeBudgetType' }); | |||||
$('#ISecondType').attr('readonly', 'readonly'); | |||||
$('#idIQuota').html('年度预计收入<font face="宋体">*</font>'); | |||||
document.getElementById("divIActual").style.display = ""; | |||||
$('#idIAmount').html('金额<font face="宋体">*</font>'); | |||||
} | |||||
} | |||||
} | |||||
}); | |||||
$('#ISecondType').lrDataItemSelect({ code: 'financeBudgetType', select: function(item) { | |||||
if (item) { | |||||
if (item.text == '人员经费') { | |||||
$('#IPeopleNum').removeAttr("readonly"); | |||||
} else { | |||||
$('#IPeopleNum').val(''); | |||||
$('#IPeopleNum').attr('readonly', 'readonly'); | |||||
} | |||||
if (item.text == '财政专项') { | |||||
$('#idIQuota').html('申报金额<font face="宋体">*</font>'); | |||||
$('#idIAmount').html('批复金额<font face="宋体">*</font>'); | |||||
} else { | |||||
$('#spanIQuota').text('定额<font face="宋体">*</font>'); | |||||
$('#idIAmount').html('金额<font face="宋体">*</font>'); | |||||
} | |||||
} | |||||
} }); | |||||
}, | |||||
initData: function () { | |||||
if (!!keyValue) { | |||||
$.lrSetForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/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]); | |||||
} | |||||
} | |||||
}); | |||||
} | |||||
} | |||||
}; | |||||
// 保存数据 | |||||
acceptClick = function (callBack) { | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
var postData = { | |||||
strEntity: JSON.stringify($('body').lrGetFormData()) | |||||
}; | |||||
$.lrSaveForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||||
// 保存成功后才回调 | |||||
if (!!callBack) { | |||||
callBack(); | |||||
} | |||||
}); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,57 @@ | |||||
@{ | |||||
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> | |||||
<input id="IEnCode" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">项目名称</div> | |||||
<input id="IName" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">预算类型</div> | |||||
<div id="ITopType"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">预算科目</div> | |||||
<div id="ISecondType"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">定额</div> | |||||
<input id="IQuota" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">金额</div> | |||||
<input id="IAmount" 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> 新增</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> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-body" id="gridtable"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/ReceiveSendFeeManagement/Views/FD_IncomeManage/Index.js") |
@@ -0,0 +1,138 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-28 10:40 | |||||
* 描 述:收入预算管理 | |||||
*/ | |||||
var refreshGirdData; | |||||
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); | |||||
}, 300, 400); | |||||
$('#ITopType').lrDataItemSelect({ | |||||
code: 'BudgetType', select: function (item) { | |||||
if (item) { | |||||
if (item.id == '0' || item.text == '财政预算') { | |||||
$('#ISecondType').removeAttr("readonly"); | |||||
} else { | |||||
$('#ISecondType').lrDataItemSelect({ code: 'financeBudgetType' }); | |||||
$('#ISecondType').attr('readonly', 'readonly'); | |||||
} | |||||
} else { | |||||
$('#ISecondType').lrDataItemSelect({ code: 'financeBudgetType' }); | |||||
$('#ISecondType').attr('readonly', 'readonly'); | |||||
} | |||||
} | |||||
}); | |||||
$('#ISecondType').lrDataItemSelect({ code: 'financeBudgetType' }); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
// 新增 | |||||
$('#lr_add').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '新增', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/Form', | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
}); | |||||
// 编辑 | |||||
$('#lr_edit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('IId'); | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/Form?keyValue=' + keyValue, | |||||
width: 600, | |||||
height: 400, | |||||
callBack: function (id) { | |||||
return top[id].acceptClick(refreshGirdData); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 删除 | |||||
$('#lr_delete').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('IId'); | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||||
if (res) { | |||||
learun.deleteForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/DeleteForm', { keyValue: keyValue }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 打印 | |||||
$('#lr_print').on('click', function () { | |||||
$('#gridtable').jqprintTable(); | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').lrAuthorizeJfGrid({ | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_IncomeManage/GetPageList', | |||||
headData: [ | |||||
{ label: "项目编号", name: "IEnCode", width: 100, align: "left" }, | |||||
{ label: "项目名称", name: "IName", width: 100, align: "left" }, | |||||
{ | |||||
label: "预算类型", name: "ITopType", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('dataItem', { | |||||
key: value, | |||||
code: 'BudgetType', | |||||
callback: function (_data) { | |||||
callback(_data.text); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "预算科目", name: "ISecondType", width: 100, align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('dataItem', { | |||||
key: value, | |||||
code: 'financeBudgetType', | |||||
callback: function (_data) { | |||||
callback(_data.text); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ label: "人数", name: "IPeopleNum", width: 100, align: "left" }, | |||||
{ label: "定额/申报金额", name: "IQuota", width: 150, align: "left" }, | |||||
{ label: "年度预计收入", name: "IQuota", width: 150, align: "left" }, | |||||
{ label: "年度实际收入", name: "IActual", width: 100, align: "left" }, | |||||
{ label: "金额/批复金额", name: "IAmount", width: 150, align: "left" }, | |||||
{ label: "备注", name: "IRemarks", width: 100, align: "left" }, | |||||
], | |||||
mainId: 'IId', | |||||
isPage: true | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
refreshGirdData = function () { | |||||
$('#gridtable').jfGridSet('reload'); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,63 @@ | |||||
@{ | |||||
ViewBag.Title = "支出预算管理"; | |||||
Layout = "~/Views/Shared/_Form.cshtml"; | |||||
} | |||||
<div class="lr-form-wrap" id="form"> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">报销类型</div> | |||||
<div id="PType" ></div> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">付款方式<font face="宋体">*</font></div> | |||||
<div id="PPayType" isvalid="yes" checkexpession="NotNull" ></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">收款单位</div> | |||||
<input id="PPayee" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">开户银行</div> | |||||
<input id="PPayeeBank" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">银行账号</div> | |||||
<input id="PPayeeBankAccount" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">收款人</div> | |||||
<input id="PCollectionUser" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">开卡银行</div> | |||||
<input id="PCollectionBank1" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">卡号</div> | |||||
<input id="PCollectionBankAccount1" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">开卡银行</div> | |||||
<input id="PCollectionBank2" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-6 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">卡号</div> | |||||
<input id="PCollectionBankAccount2" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">资金支出用途</div> | |||||
<textarea id="PPurpose" class="form-control" style="height:80px;" ></textarea> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">资金支出来源<font face="宋体">*</font></div> | |||||
<div id="PTopSource" isvalid="yes" checkexpession="NotNull" ></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">财政专项名称<font face="宋体">*</font></div> | |||||
<div id="PIncomeId" isvalid="yes" checkexpession="NotNull" ></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item" data-table="FD_PayManage" > | |||||
<div class="lr-form-item-title">支出金额<font face="宋体">*</font></div> | |||||
<input id="PAmount" type="text" class="form-control" isvalid="yes" checkexpession="Num" /> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/ReceiveSendFeeManagement/Views/FD_PayManage/Form.js") |
@@ -0,0 +1,136 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-28 14:18 | |||||
* 描 述:支出预算管理 | |||||
*/ | |||||
var acceptClick; | |||||
var keyValue = request('keyValue'); | |||||
// 设置权限 | |||||
var setAuthorize; | |||||
// 设置表单数据 | |||||
var setFormData; | |||||
// 验证数据是否填写完整 | |||||
var validForm; | |||||
// 保存数据 | |||||
var save; | |||||
var bootstrap = function ($, learun) { | |||||
"use strict"; | |||||
var page = { | |||||
init: function () { | |||||
$('.lr-form-wrap').lrscroll(); | |||||
page.bind(); | |||||
page.initData(); | |||||
}, | |||||
bind: function () { | |||||
$('#PType').lrDataItemSelect({ code: 'payReimburseType' }); | |||||
$('#PPayType').lrDataItemSelect({ code: 'fdPayType' }); | |||||
$('#PTopSource').lrDataItemSelect({ | |||||
code: 'fdPaySource', select: function (item) { | |||||
var budgetType = ''; | |||||
var financeBudgetType = ''; | |||||
if (item) { | |||||
if (item.text == '学校经费' || item.text == '部门专项经费') { | |||||
budgetType = '0'; | |||||
financeBudgetType = '1'; | |||||
} else if (item.text == '财政专项经费') { | |||||
budgetType = '0'; | |||||
financeBudgetType = '2'; | |||||
} else { | |||||
budgetType = '2'; | |||||
} | |||||
} | |||||
//财政专项名称 | |||||
$('#PIncomeId').lrselectRefresh({ | |||||
placeholder: "请选择财政专项名称", | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/GetIncomeList?budgetType=' + budgetType + '&financeBudgetType=' + financeBudgetType, | |||||
value: 'value', | |||||
text: 'text' | |||||
}); | |||||
} | |||||
}); | |||||
//财政专项名称 | |||||
$('#PIncomeId').lrselect({ | |||||
placeholder: "请选择财政专项名称", | |||||
allowSearch: true, | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/GetIncomeList?budgetType=&financeBudgetType=', | |||||
value: 'value', | |||||
text: 'text' | |||||
}); | |||||
}, | |||||
initData: function () { | |||||
if (!!keyValue) { | |||||
$.lrSetForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/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 + '/ReceiveSendFeeManagement/FD_PayManage/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 == 'FD_PayManage' && data[id]) { | |||||
keyValue = data[id].PId; | |||||
} | |||||
$('[data-table="' + id + '"]').lrSetFormData(data[id]); | |||||
} | |||||
} | |||||
}); | |||||
} | |||||
callback && callback(); | |||||
} | |||||
// 验证数据是否填写完整 | |||||
validForm = function () { | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
return true; | |||||
}; | |||||
// 保存数据 | |||||
save = function (processId, callBack, i) { | |||||
console.log('保存'); | |||||
if (!$('body').lrValidform()) { | |||||
return false; | |||||
} | |||||
var postData = {}; | |||||
var strEntity = $('body').lrGetFormData(); | |||||
if (!!processId) { | |||||
strEntity.PProcessId = processId; | |||||
} | |||||
postData.strEntity = JSON.stringify(strEntity); | |||||
$.lrSaveForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/SaveForm?keyValue=' + keyValue, postData, function (res) { | |||||
if (!!processId) { | |||||
var res = {}; | |||||
res.code = 200; | |||||
if (!!callBack) { | |||||
callBack(res, i); | |||||
} | |||||
} else { | |||||
// 保存成功后才回调 | |||||
if (!!callBack) { | |||||
callBack(res, strEntity, i); | |||||
} | |||||
} | |||||
}); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -0,0 +1,62 @@ | |||||
@{ | |||||
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="PType"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">付款方式</div> | |||||
<div id="PPayType"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">收款单位</div> | |||||
<input id="PPayee" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">收款人</div> | |||||
<input id="PCollectionUser" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">资金支出用途</div> | |||||
<input id="PPurpose" type="text" class="form-control" /> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">资金支出来源</div> | |||||
<div id="PTopSource"></div> | |||||
</div> | |||||
<div class="col-xs-12 lr-form-item"> | |||||
<div class="lr-form-item-title">支出金额</div> | |||||
<input id="PAmount" 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> 新增</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_submit" class="btn btn-default"><i class="fa fa-plus"></i> 提交</a> | |||||
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i> 打印</a> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
<div class="lr-layout-body" id="gridtable"></div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
@Html.AppendJsFile("/Areas/ReceiveSendFeeManagement/Views/FD_PayManage/Index.js") |
@@ -0,0 +1,241 @@ | |||||
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) | |||||
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
* 创建人:超级管理员 | |||||
* 日 期:2021-05-28 14:18 | |||||
* 描 述:支出预算管理 | |||||
*/ | |||||
var refreshGirdData; | |||||
var processId = ''; | |||||
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); | |||||
$('#PType').lrDataItemSelect({ code: 'payReimburseType' }); | |||||
$('#PPayType').lrDataItemSelect({ code: 'fdPayType' }); | |||||
$('#PTopSource').lrDataItemSelect({ code: 'fdPaySource' }); | |||||
// 刷新 | |||||
$('#lr_refresh').on('click', function () { | |||||
location.reload(); | |||||
}); | |||||
// 新增 | |||||
$('#lr_add').on('click', function () { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '新增', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/Form', | |||||
width: 700, | |||||
height: 600, | |||||
callBack: function (id) { | |||||
top[id].save(); | |||||
return location.reload(); | |||||
} | |||||
}); | |||||
}); | |||||
// 编辑 | |||||
$('#lr_edit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('PId'); | |||||
var status = $('#gridtable').jfGridValue('PStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,不可修改!"); | |||||
return; | |||||
} | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerForm({ | |||||
id: 'form', | |||||
title: '编辑', | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/Form?keyValue=' + keyValue, | |||||
width: 700, | |||||
height: 600, | |||||
callBack: function (id) { | |||||
top[id].save(); | |||||
return refreshGirdData('', '', ''); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 删除 | |||||
$('#lr_delete').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('PId'); | |||||
var status = $('#gridtable').jfGridValue('PStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,不可删除!"); | |||||
return; | |||||
} | |||||
if (learun.checkrow(keyValue)) { | |||||
learun.layerConfirm('是否确认删除该项!', function (res) { | |||||
if (res) { | |||||
learun.deleteForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/DeleteForm', { keyValue: keyValue }, function () { | |||||
refreshGirdData(); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
// 打印 | |||||
$('#lr_print').on('click', function () { | |||||
$('#gridtable').jqprintTable(); | |||||
}); | |||||
// 提交 | |||||
$('#lr_submit').on('click', function () { | |||||
var keyValue = $('#gridtable').jfGridValue('PId'); | |||||
if (learun.checkrow(keyValue)) { | |||||
var status = $('#gridtable').jfGridValue('PStatus'); | |||||
if (status != 0) { | |||||
learun.alert.warning("当前项目已提交,请耐心等待审批!"); | |||||
return; | |||||
} | |||||
var pTopSource = $('#gridtable').jfGridValue('PTopSource'); | |||||
var type = ''; | |||||
if (pTopSource == '1' || pTopSource == '2') { | |||||
type = '1'; | |||||
//学校经费和部门专项经费都从公用经费扣除 | |||||
} else { | |||||
type = '2';//专项经费 | |||||
} | |||||
learun.layerConfirm('是否确认提交该项!', function (res) { | |||||
if (res) { | |||||
processId = learun.newGuid(); | |||||
learun.postForm(top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/ChangeStatusById', { keyValue: keyValue, processId: processId }, function (res) { | |||||
refreshGirdData(res, {}); | |||||
}); | |||||
} | |||||
}); | |||||
} | |||||
}); | |||||
}, | |||||
// 初始化列表 | |||||
initGird: function () { | |||||
$('#gridtable').jfGrid({ | |||||
url: top.$.rootUrl + '/ReceiveSendFeeManagement/FD_PayManage/GetPageList', | |||||
headData: [ | |||||
{ | |||||
label: "报销类型", | |||||
name: "PType", | |||||
width: 100, | |||||
align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('dataItem', | |||||
{ | |||||
key: value, | |||||
code: 'payReimburseType', | |||||
callback: function (_data) { | |||||
callback(_data.text); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "付款方式", | |||||
name: "PPayType", | |||||
width: 100, | |||||
align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('dataItem', | |||||
{ | |||||
key: value, | |||||
code: 'fdPayType', | |||||
callback: function (_data) { | |||||
callback(_data.text); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ label: "收款单位", name: "PPayee", width: 100, align: "left" }, | |||||
{ label: "开户银行", name: "PPayeeBank", width: 100, align: "left" }, | |||||
{ label: "银行账号", name: "PPayeeBankAccount", width: 100, align: "left" }, | |||||
{ label: "收款人", name: "PCollectionUser", width: 100, align: "left" }, | |||||
{ label: "开卡银行", name: "PCollectionBank1", width: 100, align: "left" }, | |||||
{ label: "卡号", name: "PCollectionBankAccount1", width: 100, align: "left" }, | |||||
{ label: "开卡银行", name: "PCollectionBank2", width: 100, align: "left" }, | |||||
{ label: "卡号", name: "PCollectionBankAccount2", width: 100, align: "left" }, | |||||
{ label: "资金支出用途", name: "PPurpose", width: 100, align: "left" }, | |||||
{ | |||||
label: "资金支出来源", | |||||
name: "PTopSource", | |||||
width: 100, | |||||
align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('dataItem', | |||||
{ | |||||
key: value, | |||||
code: 'fdPaySource', | |||||
callback: function (_data) { | |||||
callback(_data.text); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ | |||||
label: "财政专项名称", | |||||
name: "PIncomeId", | |||||
width: 100, | |||||
align: "left", | |||||
formatterAsync: function (callback, value, row, op, $cell) { | |||||
learun.clientdata.getAsync('custmerData', { | |||||
url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'incomeList', | |||||
key: value, | |||||
keyId: 'iid', | |||||
callback: function (_data) { | |||||
callback(_data['iname']); | |||||
} | |||||
}); | |||||
} | |||||
}, | |||||
{ label: "支出金额", name: "PAmount", width: 100, align: "left" }, | |||||
{ | |||||
label: "状态", name: "PStatus", width: 100, align: "left", | |||||
formatter: function (cellvalue) { | |||||
if (cellvalue == '0') { | |||||
return '<span class=\"label label-default\" style=\"cursor: pointer;\">草稿</span>'; | |||||
} else if (cellvalue == '1') { | |||||
return '<span class=\"label label-warning\" style=\"cursor: pointer;\">审批中</span>'; | |||||
} else if (cellvalue == '2') { | |||||
return '<span class=\"label label-success\" style=\"cursor: pointer;\">已审批</span>'; | |||||
} | |||||
} | |||||
} | |||||
], | |||||
mainId: 'PId', | |||||
isPage: true | |||||
}); | |||||
page.search(); | |||||
}, | |||||
search: function (param) { | |||||
param = param || {}; | |||||
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) }); | |||||
} | |||||
}; | |||||
//refreshGirdData = function () { | |||||
// $('#gridtable').jfGridSet('reload'); | |||||
//}; | |||||
refreshGirdData = function (res, postData, type) { | |||||
if (res && res.code && res.code == 200) { | |||||
// 发起流程 | |||||
var schemeCode = ''; | |||||
if (type == '1') | |||||
schemeCode = 'publicFunds'; | |||||
else | |||||
schemeCode = 'specialUseFunds'; | |||||
if (schemeCode) { | |||||
var postData = { | |||||
schemeCode: schemeCode,// 填写流程对应模板编号 | |||||
processId: processId, | |||||
level: '1', | |||||
}; | |||||
learun.httpAsync('Post', top.$.rootUrl + '/LR_NewWorkFlow/NWFProcess/CreateFlow', postData, function (data) { | |||||
learun.loading(false); | |||||
}); | |||||
} | |||||
} | |||||
page.search(); | |||||
}; | |||||
page.init(); | |||||
} |
@@ -807,6 +807,9 @@ | |||||
<Compile Include="Areas\AssetManagementSystem\Controllers\AssStorageRoomController.cs" /> | <Compile Include="Areas\AssetManagementSystem\Controllers\AssStorageRoomController.cs" /> | ||||
<Compile Include="Areas\PersonnelManagement\Controllers\VisitorInfoController.cs" /> | <Compile Include="Areas\PersonnelManagement\Controllers\VisitorInfoController.cs" /> | ||||
<Compile Include="Areas\EducationalAdministration\Controllers\SchoolNewsController.cs" /> | <Compile Include="Areas\EducationalAdministration\Controllers\SchoolNewsController.cs" /> | ||||
<Compile Include="Areas\ReceiveSendFeeManagement\Controllers\FD_BudgetBasicsController.cs" /> | |||||
<Compile Include="Areas\ReceiveSendFeeManagement\Controllers\FD_IncomeManageController.cs" /> | |||||
<Compile Include="Areas\ReceiveSendFeeManagement\Controllers\FD_PayManageController.cs" /> | |||||
</ItemGroup> | </ItemGroup> | ||||
<ItemGroup> | <ItemGroup> | ||||
<Content Include="Areas\AdmissionsPlatform\Views\AP_OnlineUserInfo\DropOutIndex.js" /> | <Content Include="Areas\AdmissionsPlatform\Views\AP_OnlineUserInfo\DropOutIndex.js" /> | ||||
@@ -6447,6 +6450,18 @@ | |||||
<Content Include="Areas\PersonnelManagement\Views\VisitorInfo\Form.cshtml" /> | <Content Include="Areas\PersonnelManagement\Views\VisitorInfo\Form.cshtml" /> | ||||
<Content Include="Areas\PersonnelManagement\Views\VisitorInfo\Form.js" /> | <Content Include="Areas\PersonnelManagement\Views\VisitorInfo\Form.js" /> | ||||
<Content Include="Areas\EducationalAdministration\Views\SchoolNews\Form.cshtml" /> | <Content Include="Areas\EducationalAdministration\Views\SchoolNews\Form.cshtml" /> | ||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_BudgetBasics\Index.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_BudgetBasics\Index.js" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_BudgetBasics\Form.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_BudgetBasics\Form.js" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_IncomeManage\Index.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_IncomeManage\Index.js" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_IncomeManage\Form.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_IncomeManage\Form.js" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_PayManage\Index.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_PayManage\Index.js" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_PayManage\Form.cshtml" /> | |||||
<Content Include="Areas\ReceiveSendFeeManagement\Views\FD_PayManage\Form.js" /> | |||||
</ItemGroup> | </ItemGroup> | ||||
<ItemGroup> | <ItemGroup> | ||||
<Folder Include="Areas\EducationalAdministration\Views\OpenLessonPlanOfElectivePre\" /> | <Folder Include="Areas\EducationalAdministration\Views\OpenLessonPlanOfElectivePre\" /> | ||||
@@ -561,6 +561,9 @@ | |||||
<Compile Include="PersonnelManagement\VisitorInfoMap.cs" /> | <Compile Include="PersonnelManagement\VisitorInfoMap.cs" /> | ||||
<Compile Include="LR_Desktop\LostArticleInfoMap.cs" /> | <Compile Include="LR_Desktop\LostArticleInfoMap.cs" /> | ||||
<Compile Include="EducationalAdministration\LR_OA_SchoolNewsMap.cs" /> | <Compile Include="EducationalAdministration\LR_OA_SchoolNewsMap.cs" /> | ||||
<Compile Include="ReceiveSendFeeManagement\FD_BudgetBasicsMap.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_IncomeManageMap.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_PayManageMap.cs" /> | |||||
</ItemGroup> | </ItemGroup> | ||||
<ItemGroup> | <ItemGroup> | ||||
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | <ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | ||||
@@ -0,0 +1,29 @@ | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Data.Entity.ModelConfiguration; | |||||
namespace Learun.Application.Mapping | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public class FD_BudgetBasicsMap : EntityTypeConfiguration<FD_BudgetBasicsEntity> | |||||
{ | |||||
public FD_BudgetBasicsMap() | |||||
{ | |||||
#region 表、主键 | |||||
//表 | |||||
this.ToTable("FD_BUDGETBASICS"); | |||||
//主键 | |||||
this.HasKey(t => t.BId); | |||||
#endregion | |||||
#region 配置关系 | |||||
#endregion | |||||
} | |||||
} | |||||
} | |||||
@@ -0,0 +1,29 @@ | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Data.Entity.ModelConfiguration; | |||||
namespace Learun.Application.Mapping | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public class FD_IncomeManageMap : EntityTypeConfiguration<FD_IncomeManageEntity> | |||||
{ | |||||
public FD_IncomeManageMap() | |||||
{ | |||||
#region 表、主键 | |||||
//表 | |||||
this.ToTable("FD_INCOMEMANAGE"); | |||||
//主键 | |||||
this.HasKey(t => t.IId); | |||||
#endregion | |||||
#region 配置关系 | |||||
#endregion | |||||
} | |||||
} | |||||
} | |||||
@@ -0,0 +1,29 @@ | |||||
using Learun.Application.TwoDevelopment.ReceiveSendFeeManagement; | |||||
using System.Data.Entity.ModelConfiguration; | |||||
namespace Learun.Application.Mapping | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public class FD_PayManageMap : EntityTypeConfiguration<FD_PayManageEntity> | |||||
{ | |||||
public FD_PayManageMap() | |||||
{ | |||||
#region 表、主键 | |||||
//表 | |||||
this.ToTable("FD_PAYMANAGE"); | |||||
//主键 | |||||
this.HasKey(t => t.PId); | |||||
#endregion | |||||
#region 配置关系 | |||||
#endregion | |||||
} | |||||
} | |||||
} | |||||
@@ -1661,6 +1661,18 @@ | |||||
<Compile Include="EducationalAdministration\SchoolNews\SchoolNewsService.cs" /> | <Compile Include="EducationalAdministration\SchoolNews\SchoolNewsService.cs" /> | ||||
<Compile Include="EducationalAdministration\SchoolNews\SchoolNewsBLL.cs" /> | <Compile Include="EducationalAdministration\SchoolNews\SchoolNewsBLL.cs" /> | ||||
<Compile Include="EducationalAdministration\SchoolNews\SchoolNewsIBLL.cs" /> | <Compile Include="EducationalAdministration\SchoolNews\SchoolNewsIBLL.cs" /> | ||||
<Compile Include="ReceiveSendFeeManagement\FD_BudgetBasics\FD_BudgetBasicsEntity.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_BudgetBasics\FD_BudgetBasicsService.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_BudgetBasics\FD_BudgetBasicsBLL.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_BudgetBasics\FD_BudgetBasicsIBLL.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_IncomeManage\FD_IncomeManageEntity.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_IncomeManage\FD_IncomeManageService.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_IncomeManage\FD_IncomeManageBLL.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_IncomeManage\FD_IncomeManageIBLL.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_PayManage\FD_PayManageEntity.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_PayManage\FD_PayManageService.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_PayManage\FD_PayManageBLL.cs" /> | |||||
<Compile Include="ReceiveSendFeeManagement\FD_PayManage\FD_PayManageIBLL.cs" /> | |||||
</ItemGroup> | </ItemGroup> | ||||
<ItemGroup> | <ItemGroup> | ||||
<ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | <ProjectReference Include="..\..\..\Learun.Application.Organization\Learun.Application.Organization.csproj"> | ||||
@@ -0,0 +1,165 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public class FD_BudgetBasicsBLL : FD_BudgetBasicsIBLL | |||||
{ | |||||
private FD_BudgetBasicsService fD_BudgetBasicsService = new FD_BudgetBasicsService(); | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_BudgetBasicsEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_BudgetBasicsService.GetPageList(pagination, queryJson); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_BudgetBasicsEntity GetFD_BudgetBasicsEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_BudgetBasicsService.GetFD_BudgetBasicsEntity(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_BudgetBasicsEntity GetFormDataByProcessId(string processId) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_BudgetBasicsService.GetFormDataByProcessId(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 | |||||
{ | |||||
fD_BudgetBasicsService.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> | |||||
/// <returns></returns> | |||||
public void SaveEntity(string keyValue, FD_BudgetBasicsEntity entity) | |||||
{ | |||||
try | |||||
{ | |||||
fD_BudgetBasicsService.SaveEntity(keyValue, entity); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
public void ChangeStatusById(string keyValue, int status, string processId) | |||||
{ | |||||
try | |||||
{ | |||||
fD_BudgetBasicsService.ChangeStatusById(keyValue, status, processId); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,101 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.ComponentModel.DataAnnotations.Schema; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public class FD_BudgetBasicsEntity | |||||
{ | |||||
#region 实体成员 | |||||
/// <summary> | |||||
/// 主键 | |||||
/// </summary> | |||||
[Column("BID")] | |||||
public string BId { get; set; } | |||||
/// <summary> | |||||
/// 姓名 | |||||
/// </summary> | |||||
[Column("BNAME")] | |||||
public string BName { get; set; } | |||||
/// <summary> | |||||
/// 部门 | |||||
/// </summary> | |||||
[Column("BDEPT")] | |||||
public string BDept { get; set; } | |||||
/// <summary> | |||||
/// 当前时间 | |||||
/// </summary> | |||||
[Column("BCREATETIME")] | |||||
public DateTime? BCreateTime { get; set; } | |||||
/// <summary> | |||||
/// 附件 | |||||
/// </summary> | |||||
[Column("BFILE")] | |||||
public string BFile { get; set; } | |||||
/// <summary> | |||||
/// 备注 | |||||
/// </summary> | |||||
[Column("BREMARKS")] | |||||
public string BRemarks { get; set; } | |||||
/// <summary> | |||||
/// 状态 0草稿,1审批中,2已审批,3已拒绝 | |||||
/// </summary> | |||||
[Column("BSTATUS")] | |||||
public int? BStatus { get; set; } | |||||
/// <summary> | |||||
/// 流程Id | |||||
/// </summary> | |||||
[Column("BPROCESSID")] | |||||
public string BProcessId { get; set; } | |||||
/// <summary> | |||||
/// 是否删除 | |||||
/// </summary> | |||||
[Column("BISDELETE")] | |||||
public bool? BIsDelete { get; set; } | |||||
/// <summary> | |||||
/// 删除时间 | |||||
/// </summary> | |||||
[Column("BDELETETIME")] | |||||
public DateTime? BDeleteTime { get; set; } | |||||
/// <summary> | |||||
/// 删除用户 | |||||
/// </summary> | |||||
[Column("BDELETEUSER")] | |||||
public string BDeleteUser { get; set; } | |||||
#endregion | |||||
#region 扩展操作 | |||||
/// <summary> | |||||
/// 新增调用 | |||||
/// </summary> | |||||
public void Create() | |||||
{ | |||||
this.BId = Guid.NewGuid().ToString(); | |||||
var userinfo = LoginUserInfo.Get(); | |||||
this.BName = userinfo.realName; | |||||
this.BDept = userinfo.departmentId; | |||||
this.BCreateTime = DateTime.Now; | |||||
this.BIsDelete = false; | |||||
this.BStatus = 0; | |||||
} | |||||
/// <summary> | |||||
/// 编辑调用 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
public void Modify(string keyValue) | |||||
{ | |||||
this.BId = keyValue; | |||||
} | |||||
#endregion | |||||
#region 扩展字段 | |||||
#endregion | |||||
} | |||||
} | |||||
@@ -0,0 +1,56 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public interface FD_BudgetBasicsIBLL | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
IEnumerable<FD_BudgetBasicsEntity> GetPageList(Pagination pagination, string queryJson); | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
FD_BudgetBasicsEntity GetFD_BudgetBasicsEntity(string keyValue); | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="processId"></param> | |||||
/// <returns></returns> | |||||
FD_BudgetBasicsEntity GetFormDataByProcessId(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, FD_BudgetBasicsEntity entity); | |||||
void ChangeStatusById(string keyValue, int status, string processId); | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,195 @@ | |||||
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.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-27 17:42 | |||||
/// 描 述:基础信息上报 | |||||
/// </summary> | |||||
public class FD_BudgetBasicsService : RepositoryFactory | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">查询参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_BudgetBasicsEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append("SELECT "); | |||||
strSql.Append(@" | |||||
t.BId, | |||||
t.BName, | |||||
t.BDept, | |||||
t.BCreateTime, | |||||
t.BRemarks,t.BStatus | |||||
"); | |||||
strSql.Append(" FROM FD_BudgetBasics t "); | |||||
strSql.Append(" WHERE 1=1 and BIsDelete=0 "); | |||||
var queryParam = queryJson.ToJObject(); | |||||
// 虚拟参数 | |||||
var dp = new DynamicParameters(new { }); | |||||
if (!queryParam["StartTime"].IsEmpty() && !queryParam["EndTime"].IsEmpty()) | |||||
{ | |||||
dp.Add("startTime", queryParam["StartTime"].ToDate(), DbType.DateTime); | |||||
dp.Add("endTime", queryParam["EndTime"].ToDate(), DbType.DateTime); | |||||
strSql.Append(" AND ( t.BCreateTime >= @startTime AND t.BCreateTime <= @endTime ) "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<FD_BudgetBasicsEntity>(strSql.ToString(), dp, pagination); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_BudgetBasicsEntity GetFD_BudgetBasicsEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return this.BaseRepository("CollegeMIS").FindEntity<FD_BudgetBasicsEntity>(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_BudgetBasics表实体数据 | |||||
/// </summary> | |||||
/// <param name="processId">流程</param> | |||||
/// <returns></returns> | |||||
public FD_BudgetBasicsEntity GetFormDataByProcessId(string processId) | |||||
{ | |||||
try | |||||
{ | |||||
return this.BaseRepository("CollegeMIS").FindEntity<FD_BudgetBasicsEntity>(x => x.BProcessId == 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<FD_BudgetBasicsEntity>(t => t.BId == keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="entity">实体</param> | |||||
public void SaveEntity(string keyValue, FD_BudgetBasicsEntity 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); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 修改审批状态 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <param name="status"></param> | |||||
public void ChangeStatusById(string keyValue, int status, string processId) | |||||
{ | |||||
try | |||||
{ | |||||
BaseRepository("CollegeMis").ExecuteBySql("update FD_BudgetBasics set BStatus=" + status + ",BProcessId='" + processId + "' where BId='" + keyValue + "'", null); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,150 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public class FD_IncomeManageBLL : FD_IncomeManageIBLL | |||||
{ | |||||
private FD_IncomeManageService fD_IncomeManageService = new FD_IncomeManageService(); | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_IncomeManageEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_IncomeManageService.GetPageList(pagination, queryJson); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_IncomeManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_IncomeManageEntity> GetIncomeList(string budgetType, string financeBudgetType) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_IncomeManageService.GetIncomeList(budgetType, financeBudgetType); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_IncomeManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_IncomeManageEntity GetFD_IncomeManageEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_IncomeManageService.GetFD_IncomeManageEntity(keyValue); | |||||
} | |||||
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 | |||||
{ | |||||
fD_IncomeManageService.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> | |||||
/// <returns></returns> | |||||
public void SaveEntity(string keyValue, FD_IncomeManageEntity entity) | |||||
{ | |||||
try | |||||
{ | |||||
fD_IncomeManageService.SaveEntity(keyValue, entity); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,136 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.ComponentModel.DataAnnotations.Schema; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public class FD_IncomeManageEntity | |||||
{ | |||||
#region 实体成员 | |||||
/// <summary> | |||||
/// 主键 | |||||
/// </summary> | |||||
[Column("IID")] | |||||
public string IId { get; set; } | |||||
/// <summary> | |||||
/// 一级分类 | |||||
/// </summary> | |||||
[Column("ITOPTYPE")] | |||||
public string ITopType { get; set; } | |||||
/// <summary> | |||||
/// 二级分类 | |||||
/// </summary> | |||||
[Column("ISECONDTYPE")] | |||||
public string ISecondType { get; set; } | |||||
/// <summary> | |||||
/// 项目名称 | |||||
/// </summary> | |||||
[Column("INAME")] | |||||
public string IName { get; set; } | |||||
/// <summary> | |||||
/// 项目编号 | |||||
/// </summary> | |||||
[Column("IENCODE")] | |||||
public string IEnCode { get; set; } | |||||
/// <summary> | |||||
/// 人数 | |||||
/// </summary> | |||||
[Column("IPEOPLENUM")] | |||||
public int? IPeopleNum { get; set; } | |||||
/// <summary> | |||||
/// 定额/申报金额/年度预计收入 | |||||
/// </summary> | |||||
[Column("IQUOTA")] | |||||
public decimal? IQuota { get; set; } | |||||
/// <summary> | |||||
/// 年度实际收入 | |||||
/// </summary> | |||||
[Column("IACTUAL")] | |||||
public decimal? IActual { get; set; } | |||||
/// <summary> | |||||
/// 金额/批复金额 | |||||
/// </summary> | |||||
[Column("IAMOUNT")] | |||||
public decimal? IAmount { get; set; } | |||||
/// <summary> | |||||
/// 使用金额 | |||||
/// </summary> | |||||
[Column("IUSEAMOUNT")] | |||||
public decimal? IUseAmount { get; set; } | |||||
/// <summary> | |||||
/// 剩余金额 | |||||
/// </summary> | |||||
[Column("ISURPLUSAMOUNT")] | |||||
public decimal? ISurplusAmount { get; set; } | |||||
/// <summary> | |||||
/// 备注 | |||||
/// </summary> | |||||
[Column("IREMARKS")] | |||||
public string IRemarks { get; set; } | |||||
/// <summary> | |||||
/// 创建时间 | |||||
/// </summary> | |||||
[Column("ICREATETIME")] | |||||
public DateTime? ICreateTime { get; set; } | |||||
/// <summary> | |||||
/// 创建用户 | |||||
/// </summary> | |||||
[Column("ICREATEUSERNAME")] | |||||
public string ICreateUserName { get; set; } | |||||
/// <summary> | |||||
/// 创建用户 | |||||
/// </summary> | |||||
[Column("ICREATEUSERID")] | |||||
public string ICreateUserId { get; set; } | |||||
/// <summary> | |||||
/// 是否删除 | |||||
/// </summary> | |||||
[Column("IISDELETE")] | |||||
public bool? IIsDelete { get; set; } | |||||
/// <summary> | |||||
/// 删除时间 | |||||
/// </summary> | |||||
[Column("IDELETETIME")] | |||||
public DateTime? IDeleteTime { get; set; } | |||||
/// <summary> | |||||
/// 删除用户 | |||||
/// </summary> | |||||
[Column("IDELETEUSER")] | |||||
public string IDeleteUser { get; set; } | |||||
#endregion | |||||
#region 扩展操作 | |||||
/// <summary> | |||||
/// 新增调用 | |||||
/// </summary> | |||||
public void Create() | |||||
{ | |||||
this.IId = Guid.NewGuid().ToString(); | |||||
this.IIsDelete = false; | |||||
this.ICreateTime=DateTime.Now; | |||||
var userinfo = LoginUserInfo.Get(); | |||||
this.ICreateUserId = userinfo.userId; | |||||
this.ICreateUserName = userinfo.realName; | |||||
} | |||||
/// <summary> | |||||
/// 编辑调用 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
public void Modify(string keyValue) | |||||
{ | |||||
this.IId = keyValue; | |||||
} | |||||
#endregion | |||||
#region 扩展字段 | |||||
#endregion | |||||
} | |||||
} | |||||
@@ -0,0 +1,50 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public interface FD_IncomeManageIBLL | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
IEnumerable<FD_IncomeManageEntity> GetPageList(Pagination pagination, string queryJson); | |||||
IEnumerable<FD_IncomeManageEntity> GetIncomeList(string budgetType, string financeBudgetType); | |||||
/// <summary> | |||||
/// 获取FD_IncomeManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
FD_IncomeManageEntity GetFD_IncomeManageEntity(string keyValue); | |||||
#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, FD_IncomeManageEntity entity); | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,212 @@ | |||||
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.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 10:40 | |||||
/// 描 述:收入预算管理 | |||||
/// </summary> | |||||
public class FD_IncomeManageService : RepositoryFactory | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">查询参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_IncomeManageEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append("SELECT "); | |||||
strSql.Append(@" | |||||
t.IId, | |||||
t.IEnCode, | |||||
t.IName, | |||||
t.ITopType, | |||||
t.ISecondType, | |||||
t.IPeopleNum, | |||||
t.IQuota, | |||||
t.IAmount, | |||||
t.IActual, | |||||
t.IRemarks | |||||
"); | |||||
strSql.Append(" FROM FD_IncomeManage t "); | |||||
strSql.Append(" WHERE 1=1 and IIsDelete<>1 "); | |||||
var queryParam = queryJson.ToJObject(); | |||||
// 虚拟参数 | |||||
var dp = new DynamicParameters(new { }); | |||||
if (!queryParam["IEnCode"].IsEmpty()) | |||||
{ | |||||
dp.Add("IEnCode", "%" + queryParam["IEnCode"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.IEnCode Like @IEnCode "); | |||||
} | |||||
if (!queryParam["IName"].IsEmpty()) | |||||
{ | |||||
dp.Add("IName", "%" + queryParam["IName"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.IName Like @IName "); | |||||
} | |||||
if (!queryParam["ITopType"].IsEmpty()) | |||||
{ | |||||
dp.Add("ITopType", queryParam["ITopType"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.ITopType = @ITopType "); | |||||
} | |||||
if (!queryParam["ISecondType"].IsEmpty()) | |||||
{ | |||||
dp.Add("ISecondType", queryParam["ISecondType"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.ISecondType = @ISecondType "); | |||||
} | |||||
if (!queryParam["IQuota"].IsEmpty()) | |||||
{ | |||||
dp.Add("IQuota", "%" + queryParam["IQuota"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.IQuota Like @IQuota "); | |||||
} | |||||
if (!queryParam["IAmount"].IsEmpty()) | |||||
{ | |||||
dp.Add("IAmount", "%" + queryParam["IAmount"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.IAmount Like @IAmount "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<FD_IncomeManageEntity>(strSql.ToString(), dp, pagination); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_IncomeManage列表 | |||||
/// </summary> | |||||
/// <param name=""></param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_IncomeManageEntity> GetIncomeList(string budgetType, string financeBudgetType) | |||||
{ | |||||
try | |||||
{ | |||||
var sql = "select IId,ITopType,ISecondType,IName,IEnCode from [dbo].[FD_IncomeManage] WHERE IIsDelete=0 "; | |||||
if (!string.IsNullOrEmpty(budgetType)) | |||||
sql += $" and ITopType='{budgetType}' "; | |||||
if (!string.IsNullOrEmpty(financeBudgetType)) | |||||
sql += $" and ISecondType='{financeBudgetType}'"; | |||||
return this.BaseRepository("CollegeMIS").FindList<FD_IncomeManageEntity>(sql); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_IncomeManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_IncomeManageEntity GetFD_IncomeManageEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return this.BaseRepository("CollegeMIS").FindEntity<FD_IncomeManageEntity>(keyValue); | |||||
} | |||||
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<FD_IncomeManageEntity>(t => t.IId == keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="entity">实体</param> | |||||
public void SaveEntity(string keyValue, FD_IncomeManageEntity 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 | |||||
} | |||||
} |
@@ -0,0 +1,173 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public class FD_PayManageBLL : FD_PayManageIBLL | |||||
{ | |||||
private FD_PayManageService fD_PayManageService = new FD_PayManageService(); | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">分页参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_PayManageEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_PayManageService.GetPageList(pagination, queryJson); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_PayManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_PayManageEntity GetFD_PayManageEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_PayManageService.GetFD_PayManageEntity(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_PayManage表实体数据 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
public FD_PayManageEntity GetFormDataByProcessId(string processId) | |||||
{ | |||||
try | |||||
{ | |||||
return fD_PayManageService.GetFormDataByProcessId(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 | |||||
{ | |||||
fD_PayManageService.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> | |||||
/// <returns></returns> | |||||
public void SaveEntity(string keyValue, FD_PayManageEntity entity) | |||||
{ | |||||
try | |||||
{ | |||||
fD_PayManageService.SaveEntity(keyValue, entity); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 提交 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <param name="status"></param> | |||||
/// <param name="processId"></param> | |||||
public void ChangeStatusById(string keyValue, int status, string processId) | |||||
{ | |||||
try | |||||
{ | |||||
fD_PayManageService.ChangeStatusById(keyValue, status, processId); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowBusinessException(ex); | |||||
} | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,183 @@ | |||||
using Learun.Util; | |||||
using System; | |||||
using System.ComponentModel.DataAnnotations.Schema; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public class FD_PayManageEntity | |||||
{ | |||||
#region 实体成员 | |||||
/// <summary> | |||||
/// 主键 | |||||
/// </summary> | |||||
[Column("PID")] | |||||
public string PId { get; set; } | |||||
/// <summary> | |||||
/// 支出报销类型 | |||||
/// </summary> | |||||
[Column("PTYPE")] | |||||
public string PType { get; set; } | |||||
/// <summary> | |||||
/// 报销部门 | |||||
/// </summary> | |||||
[Column("PDEPT")] | |||||
public string PDept { get; set; } | |||||
/// <summary> | |||||
/// 报销时间 | |||||
/// </summary> | |||||
[Column("PTIME")] | |||||
public DateTime? PTime { get; set; } | |||||
/// <summary> | |||||
/// 报销用户 | |||||
/// </summary> | |||||
[Column("PUSERNAME")] | |||||
public string PUserName { get; set; } | |||||
/// <summary> | |||||
/// 报销用户 | |||||
/// </summary> | |||||
[Column("PUSERID")] | |||||
public string PUserId { get; set; } | |||||
/// <summary> | |||||
/// 付款方式 | |||||
/// </summary> | |||||
[Column("PPAYTYPE")] | |||||
public string PPayType { get; set; } | |||||
/// <summary> | |||||
/// 付款类型,收款单位/个人账户 | |||||
/// </summary> | |||||
[Column("PPAYMOLD")] | |||||
public int? PPayMold { get; set; } | |||||
/// <summary> | |||||
/// 收款单位名称 | |||||
/// </summary> | |||||
[Column("PPAYEE")] | |||||
public string PPayee { get; set; } | |||||
/// <summary> | |||||
/// 收款单位银行 | |||||
/// </summary> | |||||
[Column("PPAYEEBANK")] | |||||
public string PPayeeBank { get; set; } | |||||
/// <summary> | |||||
/// 收款单位账户 | |||||
/// </summary> | |||||
[Column("PPAYEEBANKACCOUNT")] | |||||
public string PPayeeBankAccount { get; set; } | |||||
/// <summary> | |||||
/// 收款人 | |||||
/// </summary> | |||||
[Column("PCOLLECTIONUSER")] | |||||
public string PCollectionUser { get; set; } | |||||
/// <summary> | |||||
/// 收款人银行1 | |||||
/// </summary> | |||||
[Column("PCOLLECTIONBANK1")] | |||||
public string PCollectionBank1 { get; set; } | |||||
/// <summary> | |||||
/// 收款人银行账号1 | |||||
/// </summary> | |||||
[Column("PCOLLECTIONBANKACCOUNT1")] | |||||
public string PCollectionBankAccount1 { get; set; } | |||||
/// <summary> | |||||
/// 收款人银行2 | |||||
/// </summary> | |||||
[Column("PCOLLECTIONBANK2")] | |||||
public string PCollectionBank2 { get; set; } | |||||
/// <summary> | |||||
/// 收款人银行账号2 | |||||
/// </summary> | |||||
[Column("PCOLLECTIONBANKACCOUNT2")] | |||||
public string PCollectionBankAccount2 { get; set; } | |||||
/// <summary> | |||||
/// 资金支出用途 | |||||
/// </summary> | |||||
[Column("PPURPOSE")] | |||||
public string PPurpose { get; set; } | |||||
/// <summary> | |||||
/// 资金支出来源类型 | |||||
/// </summary> | |||||
[Column("PTOPSOURCE")] | |||||
public string PTopSource { get; set; } | |||||
/// <summary> | |||||
/// 资金支出来源类型2 | |||||
/// </summary> | |||||
[Column("PSECONDSOURCE")] | |||||
public string PSecondSource { get; set; } | |||||
/// <summary> | |||||
/// 资金支出来源 | |||||
/// </summary> | |||||
[Column("PINCOMEID")] | |||||
public string PIncomeId { get; set; } | |||||
/// <summary> | |||||
/// 支出金额 | |||||
/// </summary> | |||||
[Column("PAMOUNT")] | |||||
public decimal? PAmount { get; set; } | |||||
/// <summary> | |||||
/// 备注 | |||||
/// </summary> | |||||
[Column("PREMARKS")] | |||||
public string PRemarks { get; set; } | |||||
/// <summary> | |||||
/// 状态 0草稿,1审批中,2已通过,3已拒绝 | |||||
/// </summary> | |||||
[Column("PSTATUS")] | |||||
public int? PStatus { get; set; } | |||||
/// <summary> | |||||
/// 流程Id | |||||
/// </summary> | |||||
[Column("PPROCESSID")] | |||||
public string PProcessId { get; set; } | |||||
/// <summary> | |||||
/// 是否删除 | |||||
/// </summary> | |||||
[Column("PISDELETE")] | |||||
public bool? PIsDelete { get; set; } | |||||
/// <summary> | |||||
/// 删除时间 | |||||
/// </summary> | |||||
[Column("PDELETETIME")] | |||||
public DateTime? PDeleteTime { get; set; } | |||||
/// <summary> | |||||
/// 删除用户 | |||||
/// </summary> | |||||
[Column("PDELETEUSER")] | |||||
public string PDeleteUser { get; set; } | |||||
#endregion | |||||
#region 扩展操作 | |||||
/// <summary> | |||||
/// 新增调用 | |||||
/// </summary> | |||||
public void Create() | |||||
{ | |||||
this.PId = Guid.NewGuid().ToString(); | |||||
this.PIsDelete = false; | |||||
this.PStatus = 0; | |||||
this.PTime = DateTime.Now; | |||||
var userinfo = LoginUserInfo.Get(); | |||||
this.PDept = userinfo.departmentId; | |||||
this.PUserName = userinfo.realName; | |||||
this.PUserId = userinfo.userId; | |||||
} | |||||
/// <summary> | |||||
/// 编辑调用 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
public void Modify(string keyValue) | |||||
{ | |||||
this.PId = keyValue; | |||||
} | |||||
#endregion | |||||
#region 扩展字段 | |||||
#endregion | |||||
} | |||||
} | |||||
@@ -0,0 +1,58 @@ | |||||
using Learun.Util; | |||||
using System.Data; | |||||
using System.Collections.Generic; | |||||
namespace Learun.Application.TwoDevelopment.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public interface FD_PayManageIBLL | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
IEnumerable<FD_PayManageEntity> GetPageList(Pagination pagination, string queryJson); | |||||
/// <summary> | |||||
/// 获取FD_PayManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
FD_PayManageEntity GetFD_PayManageEntity(string keyValue); | |||||
FD_PayManageEntity GetFormDataByProcessId(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, FD_PayManageEntity entity); | |||||
/// <summary> | |||||
/// 提交 修改状态 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <param name="status"></param> | |||||
/// <param name="processId"></param> | |||||
void ChangeStatusById(string keyValue, int status, string processId); | |||||
#endregion | |||||
} | |||||
} |
@@ -0,0 +1,238 @@ | |||||
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.ReceiveSendFeeManagement | |||||
{ | |||||
/// <summary> | |||||
/// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 | |||||
/// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 | |||||
/// 创 建:超级管理员 | |||||
/// 日 期:2021-05-28 14:18 | |||||
/// 描 述:支出预算管理 | |||||
/// </summary> | |||||
public class FD_PayManageService : RepositoryFactory | |||||
{ | |||||
#region 获取数据 | |||||
/// <summary> | |||||
/// 获取页面显示列表数据 | |||||
/// </summary> | |||||
/// <param name="pagination">查询参数</param> | |||||
/// <param name="queryJson">查询参数</param> | |||||
/// <returns></returns> | |||||
public IEnumerable<FD_PayManageEntity> GetPageList(Pagination pagination, string queryJson) | |||||
{ | |||||
try | |||||
{ | |||||
var strSql = new StringBuilder(); | |||||
strSql.Append("SELECT "); | |||||
strSql.Append(@" | |||||
t.PId, | |||||
t.PType, | |||||
t.PPayType, | |||||
t.PPayee, | |||||
t.PPayeeBank, | |||||
t.PPayeeBankAccount, | |||||
t.PCollectionUser, | |||||
t.PCollectionBank1, | |||||
t.PCollectionBankAccount1, | |||||
t.PCollectionBank2, | |||||
t.PCollectionBankAccount2, | |||||
t.PPurpose, | |||||
t.PTopSource, | |||||
t.PIncomeId, | |||||
t.PAmount, | |||||
t.PStatus | |||||
"); | |||||
strSql.Append(" FROM FD_PayManage t "); | |||||
strSql.Append(" WHERE 1=1 "); | |||||
var queryParam = queryJson.ToJObject(); | |||||
// 虚拟参数 | |||||
var dp = new DynamicParameters(new { }); | |||||
if (!queryParam["PType"].IsEmpty()) | |||||
{ | |||||
dp.Add("PType", queryParam["PType"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.PType = @PType "); | |||||
} | |||||
if (!queryParam["PPayType"].IsEmpty()) | |||||
{ | |||||
dp.Add("PPayType", queryParam["PPayType"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.PPayType = @PPayType "); | |||||
} | |||||
if (!queryParam["PPayee"].IsEmpty()) | |||||
{ | |||||
dp.Add("PPayee", "%" + queryParam["PPayee"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.PPayee Like @PPayee "); | |||||
} | |||||
if (!queryParam["PCollectionUser"].IsEmpty()) | |||||
{ | |||||
dp.Add("PCollectionUser", "%" + queryParam["PCollectionUser"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.PCollectionUser Like @PCollectionUser "); | |||||
} | |||||
if (!queryParam["PPurpose"].IsEmpty()) | |||||
{ | |||||
dp.Add("PPurpose", "%" + queryParam["PPurpose"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.PPurpose Like @PPurpose "); | |||||
} | |||||
if (!queryParam["PTopSource"].IsEmpty()) | |||||
{ | |||||
dp.Add("PTopSource", queryParam["PTopSource"].ToString(), DbType.String); | |||||
strSql.Append(" AND t.PTopSource = @PTopSource "); | |||||
} | |||||
if (!queryParam["PAmount"].IsEmpty()) | |||||
{ | |||||
dp.Add("PAmount", "%" + queryParam["PAmount"].ToString() + "%", DbType.String); | |||||
strSql.Append(" AND t.PAmount Like @PAmount "); | |||||
} | |||||
return this.BaseRepository("CollegeMIS").FindList<FD_PayManageEntity>(strSql.ToString(), dp, pagination); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_PayManage表实体数据 | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <returns></returns> | |||||
public FD_PayManageEntity GetFD_PayManageEntity(string keyValue) | |||||
{ | |||||
try | |||||
{ | |||||
return this.BaseRepository("CollegeMIS").FindEntity<FD_PayManageEntity>(keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 获取FD_PayManage表实体数据 | |||||
/// </summary> | |||||
/// <returns></returns> | |||||
public FD_PayManageEntity GetFormDataByProcessId(string processId) | |||||
{ | |||||
try | |||||
{ | |||||
return this.BaseRepository("CollegeMIS").FindEntity<FD_PayManageEntity>(x => x.PProcessId == 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<FD_PayManageEntity>(t => t.PId == keyValue); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
if (ex is ExceptionEx) | |||||
{ | |||||
throw; | |||||
} | |||||
else | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 保存实体数据(新增、修改) | |||||
/// </summary> | |||||
/// <param name="keyValue">主键</param> | |||||
/// <param name="entity">实体</param> | |||||
public void SaveEntity(string keyValue, FD_PayManageEntity 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); | |||||
} | |||||
} | |||||
} | |||||
/// <summary> | |||||
/// 修改状态 | |||||
/// </summary> | |||||
/// <param name="keyValue"></param> | |||||
/// <param name="status"></param> | |||||
/// <param name="processId"></param> | |||||
public void ChangeStatusById(string keyValue, int status, string processId) | |||||
{ | |||||
try | |||||
{ | |||||
string sql = "update FD_PayManage set PStatus=" + status + ",PProcessId='" + processId + | |||||
"' where PId='" + keyValue + "'"; | |||||
BaseRepository("CollegeMis").ExecuteBySql(sql); | |||||
} | |||||
catch (Exception ex) | |||||
{ | |||||
throw ExceptionEx.ThrowServiceException(ex); | |||||
} | |||||
} | |||||
#endregion | |||||
} | |||||
} |