Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
performance
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zry
performance
Commits
beaacc6a
Commit
beaacc6a
authored
Jul 15, 2020
by
lcx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
二次绩效模板修改,其他来源增加字段
parent
1c1701d3
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
164 additions
and
61 deletions
+164
-61
performance/Performance.Api/Controllers/SecondAllotController.cs
+2
-2
performance/Performance.Api/wwwroot/Performance.EntityModels.xml
+41
-6
performance/Performance.EntityModels/Entity/ag_othersource.cs
+32
-2
performance/Performance.EntityModels/Entity/ag_temp.cs
+5
-0
performance/Performance.EntityModels/Entity/per_dept_dic.cs
+11
-11
performance/Performance.EntityModels/Entity/per_employee.cs
+27
-28
performance/Performance.Services/SecondAllotService.cs
+46
-12
No files found.
performance/Performance.Api/Controllers/SecondAllotController.cs
View file @
beaacc6a
...
...
@@ -114,7 +114,7 @@ public ApiResponse SaveCompute([FromBody] List<ag_compute> request)
[
HttpPost
]
public
ApiResponse
SecondDetail
([
CustomizeValidator
(
RuleSet
=
"Refresh"
),
FromBody
]
UseTempRequest
request
)
{
var
result
=
secondAllotService
.
GetSecondDetail
(
request
);
var
result
=
secondAllotService
.
GetSecondDetail
(
request
,
claimService
.
GetUserId
()
);
return
new
ApiResponse
(
ResponseType
.
OK
,
result
);
}
...
...
@@ -333,7 +333,7 @@ public ApiResponse OtherList([FromBody] AgOtherRequest request)
var
result
=
secondAllotService
.
OtherList
(
request
.
SecondId
);
var
obj
=
new
{
header
=
secondAllotService
.
OtherListHeader
(
request
.
SecondId
,
result
?.
Sum
(
t
=>
t
.
Amount
)),
header
=
secondAllotService
.
OtherListHeader
(
request
.
SecondId
,
result
?.
Sum
(
t
=>
t
.
Real
Amount
)),
body
=
result
,
};
return
new
ApiResponse
(
ResponseType
.
OK
,
obj
);
...
...
performance/Performance.Api/wwwroot/Performance.EntityModels.xml
View file @
beaacc6a
...
...
@@ -713,9 +713,39 @@
职称
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.
Amount
"
>
<member
name=
"P:Performance.EntityModels.ag_othersource.
TitlePerformance
"
>
<summary>
金额
职称绩效
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.WorkPerformance"
>
<summary>
工作量绩效工资
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.DeptReward"
>
<summary>
科室单项奖励
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.DistPerformance"
>
<summary>
可分配绩效
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.OtherPerformance"
>
<summary>
医院其他绩效
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.NightWorkPerformance"
>
<summary>
夜班工作量绩效
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_othersource.RealAmount"
>
<summary>
实发绩效工资金额
</summary>
</member>
<member
name=
"T:Performance.EntityModels.ag_secondallot"
>
...
...
@@ -813,6 +843,11 @@
类型
</summary>
</member>
<member
name=
"P:Performance.EntityModels.ag_temp.IsEnable"
>
<summary>
是否可用 1 可用 2 不可用
</summary>
</member>
<member
name=
"T:Performance.EntityModels.ag_tempitem"
>
<summary>
二次绩效模板项
...
...
@@ -3223,14 +3258,14 @@
人员类别
</summary>
</member>
<member
name=
"P:Performance.EntityModels.per_employee.Attendance
Day
"
>
<member
name=
"P:Performance.EntityModels.per_employee.Attendance"
>
<summary>
出勤
天数
出勤
率
</summary>
</member>
<member
name=
"P:Performance.EntityModels.per_employee.Attendance"
>
<member
name=
"P:Performance.EntityModels.per_employee.Attendance
Day
"
>
<summary>
出勤
率
出勤
天数
</summary>
</member>
<member
name=
"P:Performance.EntityModels.per_employee.PermanentStaff"
>
...
...
performance/Performance.EntityModels/Entity/ag_othersource.cs
View file @
beaacc6a
...
...
@@ -47,8 +47,38 @@ public class ag_othersource
public
string
WorkPost
{
get
;
set
;
}
/// <summary>
///
金额
///
职称绩效
/// </summary>
public
Nullable
<
decimal
>
Amount
{
get
;
set
;
}
public
Nullable
<
decimal
>
TitlePerformance
{
get
;
set
;
}
/// <summary>
/// 工作量绩效工资
/// </summary>
public
Nullable
<
decimal
>
WorkPerformance
{
get
;
set
;
}
/// <summary>
/// 科室单项奖励
/// </summary>
public
Nullable
<
decimal
>
DeptReward
{
get
;
set
;
}
/// <summary>
/// 可分配绩效
/// </summary>
public
Nullable
<
decimal
>
DistPerformance
{
get
;
set
;
}
/// <summary>
/// 医院其他绩效
/// </summary>
public
Nullable
<
decimal
>
OtherPerformance
{
get
;
set
;
}
/// <summary>
/// 夜班工作量绩效
/// </summary>
public
Nullable
<
decimal
>
NightWorkPerformance
{
get
;
set
;
}
/// <summary>
/// 实发绩效工资金额
/// </summary>
public
Nullable
<
decimal
>
RealAmount
{
get
;
set
;
}
}
}
performance/Performance.EntityModels/Entity/ag_temp.cs
View file @
beaacc6a
...
...
@@ -30,5 +30,10 @@ public class ag_temp
/// 类型
/// </summary>
public
string
UnitType
{
get
;
set
;
}
/// <summary>
/// 是否可用 1 可用 2 不可用
/// </summary>
public
int
IsEnable
{
get
;
set
;
}
}
}
performance/Performance.EntityModels/Entity/per_dept_dic.cs
View file @
beaacc6a
...
...
@@ -7,55 +7,55 @@
using
System.ComponentModel.DataAnnotations
;
using
System.ComponentModel.DataAnnotations.Schema
;
namespace
Performance.EntityModels
namespace
Performance.EntityModels
{
/// <summary>
/// 科室字典表
/// </summary>
[
Table
(
"per_dept_dic"
)]
public
class
per_dept_dic
public
class
per_dept_dic
{
/// <summary>
///
/// </summary>
[
Key
]
public
int
Id
{
get
;
set
;
}
public
int
Id
{
get
;
set
;
}
/// <summary>
/// his系统科室名称
/// </summary>
public
string
HISDeptName
{
get
;
set
;
}
/// <summary>
/// 科室
/// </summary>
public
string
Department
{
get
;
set
;
}
/// <summary>
/// 核算单元
/// </summary>
public
string
AccountingUnit
{
get
;
set
;
}
/// <summary>
/// 核算单元类型
/// </summary>
public
string
UnitType
{
get
;
set
;
}
/// <summary>
/// 来源住院/门诊
/// </summary>
public
string
Source
{
get
;
set
;
}
/// <summary>
/// 医院Id
/// </summary>
public
Nullable
<
int
>
HospitalId
{
get
;
set
;
}
/// <summary>
///
/// </summary>
public
Nullable
<
DateTime
>
CreateTime
{
get
;
set
;
}
/// <summary>
///
/// </summary>
...
...
performance/Performance.EntityModels/Entity/per_employee.cs
View file @
beaacc6a
...
...
@@ -7,116 +7,115 @@
using
System.ComponentModel.DataAnnotations
;
using
System.ComponentModel.DataAnnotations.Schema
;
namespace
Performance.EntityModels
namespace
Performance.EntityModels
{
/// <summary>
/// 绩效人员表
/// </summary>
[
Table
(
"per_employee"
)]
public
class
per_employee
public
class
per_employee
{
/// <summary>
///
/// </summary>
[
Key
]
public
int
Id
{
get
;
set
;
}
public
int
Id
{
get
;
set
;
}
/// <summary>
/// 核算单元
/// </summary>
public
string
AccountingUnit
{
get
;
set
;
}
/// <summary>
/// 科室
/// </summary>
public
string
Department
{
get
;
set
;
}
/// <summary>
/// 姓名
/// </summary>
public
string
DoctorName
{
get
;
set
;
}
/// <summary>
/// 员工工号
/// </summary>
public
string
PersonnelNumber
{
get
;
set
;
}
/// <summary>
/// 正式/临聘
/// </summary>
public
string
JobCategory
{
get
;
set
;
}
/// <summary>
/// 职务
/// </summary>
public
string
Duty
{
get
;
set
;
}
/// <summary>
/// 职称
/// </summary>
public
string
JobTitle
{
get
;
set
;
}
/// <summary>
/// 人员类别
/// </summary>
public
string
UnitType
{
get
;
set
;
}
/// <summary>
/// 出勤天数
/// </summary>
public
Nullable
<
int
>
AttendanceDay
{
get
;
set
;
}
/// <summary>
/// 出勤率
/// </summary>
public
Nullable
<
decimal
>
Attendance
{
get
;
set
;
}
/// <summary>
/// 出勤天数
/// </summary>
public
Nullable
<
int
>
AttendanceDay
{
get
;
set
;
}
/// <summary>
/// 核算人数
/// </summary>
public
Nullable
<
decimal
>
PermanentStaff
{
get
;
set
;
}
/// <summary>
/// 效率人数
/// </summary>
public
Nullable
<
decimal
>
EfficiencyNumber
{
get
;
set
;
}
/// <summary>
/// 参加工作时间
/// </summary>
public
Nullable
<
DateTime
>
WorkTime
{
get
;
set
;
}
/// <summary>
/// 出生年月
/// </summary>
public
Nullable
<
DateTime
>
BirthDate
{
get
;
set
;
}
/// <summary>
/// 年龄
/// </summary>
public
Nullable
<
int
>
Age
{
get
;
set
;
}
/// <summary>
/// 备注
/// </summary>
public
string
Remark
{
get
;
set
;
}
/// <summary>
/// 医院Id
/// </summary>
public
Nullable
<
int
>
HospitalId
{
get
;
set
;
}
/// <summary>
/// 绩效Id
/// </summary>
public
Nullable
<
int
>
AllotId
{
get
;
set
;
}
/// <summary>
///
/// </summary>
public
Nullable
<
DateTime
>
CreateTime
{
get
;
set
;
}
/// <summary>
///
/// </summary>
...
...
performance/Performance.Services/SecondAllotService.cs
View file @
beaacc6a
...
...
@@ -274,13 +274,18 @@ public List<SecondListResponse> GetSecondList(int userId)
/// </summary>
/// <param name="request"></param>
/// <returns></returns>
public
SecondResponse
GetSecondDetail
(
UseTempRequest
request
)
public
SecondResponse
GetSecondDetail
(
UseTempRequest
request
,
int
userId
)
{
var
usetemp
=
perforAgusetempRepository
.
GetEntity
(
t
=>
t
.
HospitalId
==
request
.
HospitalId
&&
t
.
Department
==
request
.
Department
&&
t
.
UnitType
==
request
.
UnitType
);
//获取科室二次绩效费用分配使用的模板
if
(
usetemp
==
null
)
throw
new
PerformanceException
(
"当前科室暂未配置绩效模板"
);
var
temp
=
perforAgtempRepository
.
GetEntity
(
t
=>
t
.
Id
==
usetemp
.
UseTempId
);
if
(
temp
==
null
||
temp
.
IsEnable
!=
1
)
throw
new
PerformanceException
(
"模板无效,请重新选择"
);
var
second
=
perforAgsecondallotRepository
.
GetEntity
(
t
=>
t
.
Id
==
request
.
SecondId
);
//获取固定模板列 + 工作量列
var
headItems
=
GetHeadItems
(
request
.
TempId
,
usetemp
.
HospitalId
.
Value
,
usetemp
.
Department
,
usetemp
.
UnitType
);
...
...
@@ -310,7 +315,9 @@ public SecondResponse GetSecondDetail(UseTempRequest request)
else
{
//无数据 根据IsBring带出历史二次绩效中需要带出的数据
result
.
BodyItems
=
GetBringItems
(
request
,
headItems
);
//result.BodyItems = GetBringItems(request, headItems);
result
.
BodyItems
=
GetEmployees
(
second
.
AllotId
.
Value
,
userId
,
headItems
);
var
bodys
=
Mapper
.
Map
<
List
<
BodyItem
>>(
headItems
.
Where
(
t
=>
t
.
Type
==
1
));
if
(
bodys
!=
null
&&
bodys
.
Any
())
bodys
.
ForEach
(
t
=>
t
.
RowNumber
=
-
1
);
...
...
@@ -330,17 +337,38 @@ public SecondResponse GetSecondDetail(UseTempRequest request)
};
}
private
void
GetEmployees
(
int
allotId
,
int
userId
)
private
List
<
BodyItem
>
GetEmployees
(
int
allotId
,
int
userId
,
List
<
HeadItem
>
heads
)
{
Dictionary
<
int
,
Func
<
per_employee
,
object
>>
dict
=
new
Dictionary
<
int
,
Func
<
per_employee
,
object
>>
var
list
=
new
List
<
BodyItem
>();
var
employees
=
personService
.
GetPersons
(
allotId
,
userId
);
if
(
employees
==
null
||
!
employees
.
Any
())
return
list
;
Dictionary
<(
string
,
string
),
Func
<
per_employee
,
object
>>
dict
=
new
Dictionary
<(
string
,
string
),
Func
<
per_employee
,
object
>>
{
{
19
,
(
t
)
=>
t
.
DoctorName
},
{
20
,
(
t
)
=>
t
.
JobTitle
},
{
22
,
(
t
)
=>
t
.
AttendanceDay
},
{
(
"姓名"
,
"FullName"
)
,
(
t
)
=>
t
.
DoctorName
},
{
(
"岗位"
,
"Post"
)
,
(
t
)
=>
t
.
JobTitle
},
{
(
"实际出勤"
,
"ActualAttendance"
)
,
(
t
)
=>
t
.
AttendanceDay
},
};
var
employees
=
personService
.
GetPersons
(
allotId
,
userId
);
var
list
=
new
List
<
BodyItem
>();
int
rowNumber
=
1
;
foreach
(
var
employee
in
employees
)
{
foreach
(
var
item
in
dict
)
{
var
head
=
heads
.
FirstOrDefault
(
t
=>
t
.
FiledName
==
item
.
Key
.
Item1
&&
t
.
FiledId
==
item
.
Key
.
Item2
);
if
(
head
!=
null
)
{
var
body
=
Mapper
.
Map
<
BodyItem
>(
head
);
body
.
Value
=
item
.
Value
.
Invoke
(
employee
).
ToString
();
body
.
RowNumber
=
rowNumber
;
list
.
Add
(
body
);
}
}
rowNumber
++;
}
return
list
;
}
/// <summary>
...
...
@@ -691,7 +719,7 @@ public bool SaveCompute(List<ag_compute> request)
/// <returns></returns>
public
List
<
SecondTempResponse
>
GetTemp
(
int
hospitalid
,
string
department
,
int
userId
)
{
var
temps
=
perforAgtempRepository
.
GetEntities
();
var
temps
=
perforAgtempRepository
.
GetEntities
(
t
=>
t
.
IsEnable
==
1
);
if
(
temps
!=
null
&&
temps
.
Any
())
{
var
userrole
=
userroleRepository
.
GetEntity
(
t
=>
t
.
UserID
==
userId
);
...
...
@@ -1181,7 +1209,7 @@ public bool ConfirmAudit(int userId, SecondAuditRequest request)
WorkPost
=
item
.
WorkPost
,
JobNumber
=
item
.
WorkNumber
,
PersonName
=
item
.
Name
,
RealGiveFee
=
item
.
Amount
,
RealGiveFee
=
item
.
Real
Amount
,
});
}
}
...
...
@@ -1299,7 +1327,13 @@ public List<ag_othersource> OtherSave(int secondId, List<ag_othersource> request
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
Name
=
item
.
Name
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
Department
=
item
.
Department
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
WorkPost
=
item
.
WorkPost
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
Amount
=
item
.
Amount
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
TitlePerformance
=
item
.
TitlePerformance
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
WorkPerformance
=
item
.
WorkPerformance
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
DeptReward
=
item
.
DeptReward
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
DistPerformance
=
item
.
DistPerformance
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
OtherPerformance
=
item
.
OtherPerformance
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
NightWorkPerformance
=
item
.
NightWorkPerformance
;
existEntities
.
First
(
t
=>
t
.
Id
==
item
.
Id
).
RealAmount
=
item
.
RealAmount
;
}
perforAgothersourceRepository
.
UpdateRange
(
existEntities
.
ToArray
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment