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
78453b6e
Commit
78453b6e
authored
Dec 22, 2022
by
Licx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
二次绩效详情返回出勤时间
parent
09d9cd4f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
4 deletions
+7
-4
performance/Performance.Services/RedistributionService.cs
+7
-4
No files found.
performance/Performance.Services/RedistributionService.cs
View file @
78453b6e
...
...
@@ -125,7 +125,8 @@ public SecondDetailDto Load(int secondId, ComputeMode computeMode, EmployeeSourc
foreach
(
var
item
in
loadEmployees
)
{
item
.
StaffCoefficient
=
item
.
StaffCoefficient
??
1
;
// 人员系数
item
.
ActualAttendance
=
item
.
ActualAttendance
??
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
);
// 出勤
var
actualAttendance
=
(
allot
.
Month
>
0
&&
allot
.
Month
<
13
)
?
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
)
:
30
;
item
.
ActualAttendance
=
item
.
ActualAttendance
??
actualAttendance
;
// 出勤
item
.
TitleCoefficient
=
item
.
TitleCoefficient
??
1
;
// 职称系数
// 填报模板带出 行政工勤 绩效
if
(
computeMode
==
ComputeMode
.
NotCalculate
)
...
...
@@ -449,7 +450,8 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D
head
.
AddOrUpdate
(
"ComputeModeDescription"
,
EnumHelper
.
GetDescription
(
computeMode
));
var
allotStates
=
new
int
[]
{
(
int
)
AllotStates
.
绩效下发
,
(
int
)
AllotStates
.
归档
};
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
SecondId
),
second
.
Id
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
PaymentOfTheMonth
),
$"
{
allot
.
Year
}
年
{
allot
.
Month
.
ToString
().
PadLeft
(
2
,
'0'
)}
月"
);
var
monthName
=
string
.
IsNullOrEmpty
(
allot
.
Name
)
?
$"
{
allot
.
Month
.
ToString
().
PadLeft
(
2
,
'0'
)}
月"
:
allot
.
Name
;
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
PaymentOfTheMonth
),
$"
{
allot
.
Year
}
年
{
monthName
}
"
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
TotalDistPerformance
),
allotStates
.
Contains
(
allot
.
States
)
?
(
second
.
RealGiveFee
??
0
)
:
1000
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
NightShiftWorkPerforTotal
),
allotStates
.
Contains
(
allot
.
States
)
?
(
second
.
NightShiftWorkPerforFee
??
0
)
:
0
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
TotalPerformance
),
head
.
GetDecimal
(
nameof
(
ag_headsource
.
TotalDistPerformance
))
-
head
.
GetDecimal
(
nameof
(
ag_headsource
.
NightShiftWorkPerforTotal
)));
...
...
@@ -485,7 +487,8 @@ public void RowsExpand(per_allot allot, List<SecondColumnDictionary> dic, List<D
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
SeniorityTitlesAccountedPerformance
),
history
?.
SeniorityTitlesAccountedPerformance
??
titleRatio
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
Workload_Ratio_Default
),
history
?.
Workload_Ratio_Default
??
workloadRatio
);
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
DaysFullAttendance
),
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
));
var
daysFullAttendance
=
(
allot
.
Month
>
0
&&
allot
.
Month
<
13
)
?
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
)
:
30
;
head
.
AddOrUpdate
(
nameof
(
ag_headsource
.
DaysFullAttendance
),
daysFullAttendance
);
// 多工作量加载
var
status
=
(
new
int
[]
{
(
int
)
SecondAllotStatus
.
WaitReview
,
(
int
)
SecondAllotStatus
.
PassAudit
});
...
...
@@ -1678,7 +1681,7 @@ public object RedistributionEmployee(SecondEmployeeDto request)
{
Func
<
per_employee
,
decimal
?>
getDistPerformance
=
(
emp
)
=>
0
;
var
secondWorkload
=
GetSecondWorkloadByValue
(
second
.
AllotId
.
Value
,
second
.
UnitType
,
second
.
Department
);
var
monthDays
=
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
)
;
var
monthDays
=
(
allot
.
Month
>
0
&&
allot
.
Month
<
13
)
?
DateTime
.
DaysInMonth
(
allot
.
Year
,
allot
.
Month
)
:
30
;
foreach
(
var
employee
in
employees
)
{
Dictionary
<
string
,
object
>
item
=
new
Dictionary
<
string
,
object
>();
...
...
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