zhangli пре 3 година
родитељ
комит
b4071426e4
7 измењених фајлова са 339 додато и 5 уклоњено
  1. +83
    -5
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Controllers/Emp_PayrollController.cs
  2. +45
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/Emp_Payroll/StatisticIndex.cshtml
  3. +111
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/Emp_Payroll/StatisticIndex.js
  4. +2
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
  5. +25
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollBLL.cs
  6. +8
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollIBLL.cs
  7. +65
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollService.cs

+ 83
- 5
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Controllers/Emp_PayrollController.cs Прегледај датотеку

@@ -3,6 +3,7 @@ using System.Data;
using Learun.Application.TwoDevelopment.PersonnelManagement;
using System.Web.Mvc;
using System.Collections.Generic;
using System.Linq;

namespace Learun.Application.Web.Areas.PersonnelManagement.Controllers
{
@@ -26,7 +27,7 @@ namespace Learun.Application.Web.Areas.PersonnelManagement.Controllers
[HttpGet]
public ActionResult Index()
{
return View();
return View();
}
/// <summary>
/// 表单页
@@ -35,7 +36,17 @@ namespace Learun.Application.Web.Areas.PersonnelManagement.Controllers
[HttpGet]
public ActionResult Form()
{
return View();
return View();
}

/// <summary>
/// 工资条统计
/// <summary>
/// <returns></returns>
[HttpGet]
public ActionResult StatisticIndex()
{
return View();
}
#endregion

@@ -71,12 +82,79 @@ namespace Learun.Application.Web.Areas.PersonnelManagement.Controllers
[AjaxOnly]
public ActionResult GetFormData(string keyValue)
{
var EMP_PayrollData = emp_PayrollIBLL.GetEMP_PayrollEntity( keyValue );
var jsonData = new {
var EMP_PayrollData = emp_PayrollIBLL.GetEMP_PayrollEntity(keyValue);
var jsonData = new
{
EMP_Payroll = EMP_PayrollData,
};
return Success(jsonData);
}

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetStatisticList(string queryJson)
{
var data = emp_PayrollIBLL.GetList(queryJson);
var datagroup = data.GroupBy(x => new { x.IssueMonth, x.IssueYear }).Select(x => new EMP_PayrollEntity
{
IssueYear = x.Key.IssueYear,
IssueMonth = x.Key.IssueMonth,
PostSalary = x.Select(y => y.PostSalary.ToDecimal()).Sum().ToString(),
PayWages = x.Select(y => y.PayWages.ToDecimal()).Sum().ToString(),
UpTenpercent = x.Select(y => y.UpTenpercent.ToDecimal()).Sum().ToString(),
SchoolSub = x.Select(y => y.SchoolSub.ToDecimal()).Sum().ToString(),
TemporarySub = x.Select(y => y.TemporarySub.ToDecimal()).Sum().ToString(),
RankWage = x.Select(y => y.RankWage.ToDecimal()).Sum().ToString(),
DifferentialSub = x.Select(y => y.DifferentialSub.ToDecimal()).Sum().ToString(),
MeritPay = x.Select(y => y.MeritPay.ToDecimal()).Sum().ToString(),
MeritPayLess = x.Select(y => y.MeritPayLess.ToDecimal()).Sum().ToString(),
MonthlyoneMerit = x.Select(y => y.MonthlyoneMerit.ToDecimal()).Sum().ToString(),
Tilt = x.Select(y => y.Tilt.ToDecimal()).Sum().ToString(),
Classfees = x.Select(y => y.Classfees.ToDecimal()).Sum().ToString(),
SuperClass = x.Select(y => y.SuperClass.ToDecimal()).Sum().ToString(),
TrainingDollars = x.Select(y => y.TrainingDollars.ToDecimal()).Sum().ToString(),
Bonus = x.Select(y => y.Bonus.ToDecimal()).Sum().ToString(),
BabySubsidies = x.Select(y => y.BabySubsidies.ToDecimal()).Sum().ToString(),
ClassTeacher = x.Select(y => y.ClassTeacher.ToDecimal()).Sum().ToString(),
KeyBenefits = x.Select(y => y.KeyBenefits.ToDecimal()).Sum().ToString(),
PositionFill = x.Select(y => y.PositionFill.ToDecimal()).Sum().ToString(),
OvertimePay = x.Select(y => y.OvertimePay.ToDecimal()).Sum().ToString(),
OnDutyfee = x.Select(y => y.OnDutyfee.ToDecimal()).Sum().ToString(),
ExaminationFee = x.Select(y => y.ExaminationFee.ToDecimal()).Sum().ToString(),
SecurityPay = x.Select(y => y.SecurityPay.ToDecimal()).Sum().ToString(),
MedicalBills = x.Select(y => y.MedicalBills.ToDecimal()).Sum().ToString(),
CoolingPurposes = x.Select(y => y.CoolingPurposes.ToDecimal()).Sum().ToString(),
HousSub = x.Select(y => y.HousSub.ToDecimal()).Sum().ToString(),
PropertySub = x.Select(y => y.PropertySub.ToDecimal()).Sum().ToString(),
HeatingSub = x.Select(y => y.HeatingSub.ToDecimal()).Sum().ToString(),
ComprehensiveSub = x.Select(y => y.ComprehensiveSub.ToDecimal()).Sum().ToString(),
ControlSub = x.Select(y => y.ControlSub.ToDecimal()).Sum().ToString(),
Replacement = x.Select(y => y.Replacement.ToDecimal()).Sum().ToString(),
SendSum = x.Select(y => y.SendSum.ToDecimal()).Sum().ToString(),
LossInsurance = x.Select(y => y.LossInsurance.ToDecimal()).Sum().ToString(),
Bartender = x.Select(y => y.Bartender.ToDecimal()).Sum().ToString(),
OcPension = x.Select(y => y.OcPension.ToDecimal()).Sum().ToString(),
HousFund = x.Select(y => y.HousFund.ToDecimal()).Sum().ToString(),
HealthCare = x.Select(y => y.HealthCare.ToDecimal()).Sum().ToString(),
TheRent = x.Select(y => y.TheRent.ToDecimal()).Sum().ToString(),
InternetFee = x.Select(y => y.InternetFee.ToDecimal()).Sum().ToString(),
AssDeductions = x.Select(y => y.AssDeductions.ToDecimal()).Sum().ToString(),
OtherDeductions = x.Select(y => y.OtherDeductions.ToDecimal()).Sum().ToString(),
WithBuckletax = x.Select(y => y.WithBuckletax.ToDecimal()).Sum().ToString(),
DeductionsSum = x.Select(y => y.DeductionsSum.ToDecimal()).Sum().ToString(),
TaxRevenue = x.Select(y => y.TaxRevenue.ToDecimal()).Sum().ToString(),
TaxIncome = x.Select(y => y.TaxIncome.ToDecimal()).Sum().ToString(),
NetCombined = x.Select(y => y.NetCombined.ToDecimal()).Sum().ToString()
}).OrderByDescending(x => x.IssueYear).ThenByDescending(x => x.IssueMonth);

return Success(datagroup);
}
#endregion

#region 提交数据
@@ -105,7 +183,7 @@ namespace Learun.Application.Web.Areas.PersonnelManagement.Controllers
public ActionResult SaveForm(string keyValue, string strEntity)
{
EMP_PayrollEntity entity = strEntity.ToObject<EMP_PayrollEntity>();
emp_PayrollIBLL.SaveEntity(keyValue,entity);
emp_PayrollIBLL.SaveEntity(keyValue, entity);
if (string.IsNullOrEmpty(keyValue))
{
}


+ 45
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/Emp_Payroll/StatisticIndex.cshtml Прегледај датотеку

@@ -0,0 +1,45 @@
@{
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="IssueYear"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">月份</div>
<div id="IssueMonth"></div>
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">姓名</div>
<input id="SalaryName" type="text" class="form-control" />
</div>
<div class="col-xs-12 lr-form-item">
<div class="lr-form-item-title">部门</div>
<div id="Department"></div>
</div>
</div>
</div>
</div>
</div>
<div class="lr-layout-tool-right">
<div class=" btn-group btn-group-sm">
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a>
</div>
</div>
</div>
<div class="lr-layout-body" id="gridtable"></div>
</div>
</div>
</div>


@Html.AppendJsFile("/Areas/PersonnelManagement/Views/Emp_Payroll/StatisticIndex.js")

+ 111
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/PersonnelManagement/Views/Emp_Payroll/StatisticIndex.js Прегледај датотеку

@@ -0,0 +1,111 @@
/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2020 力软信息技术(苏州)有限公司
* 创建人:超级管理员
* 日 期:2021-04-21 15:42
* 描 述:工资条统计
*/
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);
}, 220, 400);
//年份
$('#IssueYear').lrselect({
allowSearch: true,
type: 'multiple',
url: top.$.rootUrl + '/PersonnelManagement/MP_ManagementPlan/GetAcademicYear',
value: 'value',
text: 'text'
});
$('#IssueMonth').lrDataItemSelect({ code: 'MPMonth', type: 'multiple' });
$('#Department').lrselect({
type: 'tree',
// 展开最大高度
maxHeight: 200,
// 是否允许搜索
allowSearch: true,
// 访问数据接口地址
url: top.$.rootUrl + '/LR_OrganizationModule/Department/GetTree',
});
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
},
// 初始化列表
initGird: function () {
$('#gridtable').jfGrid({
url: top.$.rootUrl + '/PersonnelManagement/Emp_Payroll/GetStatisticList',
headData: [
{ label: "发放年份", name: "IssueYear", width: 100, align: "left" },
{ label: "发放月份", name: "IssueMonth", width: 100, align: "left" },
{ label: "岗位工资", name: "PostSalary", width: 100, align: "left", statistics: true },
{ label: "薪级工资", name: "PayWages", width: 100, align: "left", statistics: true },
{ label: "提高百分之十", name: "UpTenpercent", width: 100, align: "left", statistics: true },
{ label: "校内补贴", name: "SchoolSub", width: 100, align: "left", statistics: true },
{ label: "临时性补贴", name: "TemporarySub", width: 100, align: "left", statistics: true },
{ label: "职级工资", name: "RankWage", width: 100, align: "left", statistics: true },
{ label: "级差补贴", name: "DifferentialSub", width: 100, align: "left", statistics: true },
{ label: "绩效工资", name: "MeritPay", width: 100, align: "left", statistics: true },
{ label: "绩效工资减少额", name: "MeritPayLess", width: 100, align: "left", statistics: true },
{ label: "月发一次性绩效", name: "MonthlyoneMerit", width: 100, align: "left", statistics: true },
{ label: "倾斜", name: "Tilt", width: 100, align: "left", statistics: true },
{ label: "课时费", name: "Classfees", width: 100, align: "left", statistics: true },
{ label: "超课时", name: "SuperClass", width: 100, align: "left", statistics: true },
{ label: "培训课酬", name: "TrainingDollars", width: 100, align: "left", statistics: true },
{ label: "奖金", name: "Bonus", width: 100, align: "left", statistics: true },
{ label: "婴补", name: "BabySubsidies", width: 100, align: "left", statistics: true },
{ label: "班主任", name: "ClassTeacher", width: 100, align: "left", statistics: true },
{ label: "骨干津贴", name: "KeyBenefits", width: 100, align: "left", statistics: true },
{ label: "职务补", name: "PositionFill", width: 100, align: "left", statistics: true },
{ label: "加班费", name: "OvertimePay", width: 100, align: "left", statistics: true },
{ label: "值班费", name: "OnDutyfee", width: 100, align: "left", statistics: true },
{ label: "考务费", name: "ExaminationFee", width: 100, align: "left", statistics: true },
{ label: "安全绩效", name: "SecurityPay", width: 100, align: "left", statistics: true },
{ label: "医药费", name: "MedicalBills", width: 100, align: "left", statistics: true },
{ label: "防暑降温", name: "CoolingPurposes", width: 100, align: "left", statistics: true },
{ label: "房补", name: "HousSub", width: 100, align: "left", statistics: true },
{ label: "物业补贴", name: "PropertySub", width: 100, align: "left", statistics: true },
{ label: "采暖补贴", name: "HeatingSub", width: 100, align: "left", statistics: true },
{ label: "综合补助", name: "ComprehensiveSub", width: 100, align: "left", statistics: true },
{ label: "综治奖", name: "ControlSub", width: 100, align: "left", statistics: true },
{ label: "补发", name: "Replacement", width: 100, align: "left", statistics: true },
{ label: "应发合计", name: "SendSum", width: 100, align: "left", statistics: true },
{ label: "失保", name: "LossInsurance", width: 100, align: "left", statistics: true },
{ label: "养保", name: "Bartender", width: 100, align: "left", statistics: true },
{ label: "职业年金", name: "OcPension", width: 100, align: "left", statistics: true },
{ label: "房积金", name: "HousFund", width: 100, align: "left", statistics: true },
{ label: "医保", name: "HealthCare", width: 100, align: "left", statistics: true },
{ label: "房租", name: "TheRent", width: 100, align: "left", statistics: true },
{ label: "网费", name: "InternetFee", width: 100, align: "left", statistics: true },
{ label: "考核扣款", name: "AssDeductions", width: 100, align: "left", statistics: true },
{ label: "其他扣款", name: "OtherDeductions", width: 100, align: "left", statistics: true },
{ label: "代扣个税", name: "WithBuckletax", width: 100, align: "left", statistics: true },
{ label: "扣款合计", name: "DeductionsSum", width: 100, align: "left", statistics: true },
{ label: "纳税收入", name: "TaxRevenue", width: 100, align: "left", statistics: true },
{ label: "免税收入", name: "TaxIncome", width: 100, align: "left", statistics: true },
{ label: "应发合计", name: "NetCombined", width: 100, align: "left", statistics: true },
],
mainId: 'SalaryID',
isPage: false
});
page.search();
},
search: function (param) {
param = param || {};
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
}
};
refreshGirdData = function () {
$('#gridtable').jfGridSet('reload');
};
page.init();
}

+ 2
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj Прегледај датотеку

@@ -1377,6 +1377,7 @@
<Content Include="Areas\PersonnelManagement\Views\ContractManagement\FormRemove.js" />
<Content Include="Areas\PersonnelManagement\Views\ContractManagement\FormTerminate.js" />
<Content Include="Areas\PersonnelManagement\Views\ContractManagement\FormRenew.js" />
<Content Include="Areas\PersonnelManagement\Views\Emp_Payroll\StatisticIndex.js" />
<Content Include="Areas\PersonnelManagement\Views\MeetingManagement\FormView.js" />
<Content Include="Areas\PersonnelManagement\Views\MeetingManagement\IndexOfMyJoin.js" />
<Content Include="Areas\PersonnelManagement\Views\MeetingManagement\IndexOfMyApply.js" />
@@ -7172,6 +7173,7 @@
<Content Include="Areas\LR_OAModule\Views\Notice\IndexLostArticle.cshtml" />
<Content Include="Areas\LR_OAModule\Views\Notice\FormLostArticle.cshtml" />
<Content Include="Areas\LR_OAModule\Views\Notice\FormLostArticleView.cshtml" />
<Content Include="Areas\PersonnelManagement\Views\Emp_Payroll\StatisticIndex.cshtml" />
<Content Include="Areas\PersonnelManagement\Views\VisitorInfo\FormAdd.cshtml" />
<Content Include="Areas\PersonnelManagement\Views\VisitorInfo\FormAdd2.cshtml" />
<None Include="Properties\PublishProfiles\FolderProfile.pubxml" />


+ 25
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollBLL.cs Прегледај датотеку

@@ -67,6 +67,31 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
}
}

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

#endregion

#region 提交数据


+ 8
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollIBLL.cs Прегледај датотеку

@@ -27,6 +27,14 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
/// <param name="keyValue">主键</param>
/// <returns></returns>
EMP_PayrollEntity GetEMP_PayrollEntity(string keyValue);

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">分页参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
IEnumerable<EMP_PayrollEntity> GetList(string queryJson);
#endregion

#region 提交数据


+ 65
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/PersonnelManagement/Emp_Payroll/Emp_PayrollService.cs Прегледај датотеку

@@ -96,6 +96,71 @@ namespace Learun.Application.TwoDevelopment.PersonnelManagement
}
}

/// <summary>
/// 获取页面显示列表数据
/// </summary>
/// <param name="pagination">查询参数</param>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<EMP_PayrollEntity> GetList(string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT t.* ");
strSql.Append(" FROM EMP_Payroll t");
strSql.Append(" left join EmpInfo e on t.SalaryID=e.SalaryNumber ");
strSql.Append(" WHERE 1=1 ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
if (!queryParam["IssueYear"].IsEmpty())
{
var strArr = queryParam["IssueYear"].ToString().Split(',');
var strs = "";
foreach (var item in strArr)
{
strs += $"'{item}',";
}
strs = strs.TrimEnd(',');
strSql.Append($" AND t.IssueYear in ({strs}) ");
}
if (!queryParam["IssueMonth"].IsEmpty())
{
var strArr = queryParam["IssueMonth"].ToString().Split(',');
var strs = "";
foreach (var item in strArr)
{
strs += $"'{item}',";
}
strs = strs.TrimEnd(',');
strSql.Append($" AND t.IssueMonth in ({strs}) ");
}
if (!queryParam["SalaryName"].IsEmpty())
{
dp.Add("SalaryName", "%" + queryParam["SalaryName"].ToString() + "%", DbType.String);
strSql.Append(" AND t.SalaryName Like @SalaryName ");
}
if (!queryParam["Department"].IsEmpty())
{
dp.Add("Department", queryParam["Department"].ToString(), DbType.String);
strSql.Append(" AND e.F_DepartmentId = @Department ");
}
return this.BaseRepository("CollegeMIS").FindList<EMP_PayrollEntity>(strSql.ToString(), dp);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

#region 提交数据


Loading…
Откажи
Сачувај