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
6190df07
Commit
6190df07
authored
Oct 16, 2020
by
ruyun.zhang@suvalue.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
二次共用科主任其他绩效问题解决
parent
16ff0d6b
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
3 deletions
+19
-3
performance/Performance.Services/ComputeService.cs
+19
-3
No files found.
performance/Performance.Services/ComputeService.cs
View file @
6190df07
...
@@ -542,11 +542,27 @@ private List<ComputeResponse> AddAprAmount(int allotId, List<ComputeResponse> co
...
@@ -542,11 +542,27 @@ private List<ComputeResponse> AddAprAmount(int allotId, List<ComputeResponse> co
if
(
list
==
null
||
!
list
.
Any
())
if
(
list
==
null
||
!
list
.
Any
())
return
computes
;
return
computes
;
foreach
(
var
emp
in
computes
)
foreach
(
var
item
in
computes
.
GroupBy
(
w
=>
new
{
w
.
AccountingUnit
,
w
.
JobNumber
})
)
{
{
var
apramount
=
list
.
Where
(
t
=>
t
.
AccountingUnit
==
emp
.
AccountingUnit
&&
!
string
.
IsNullOrEmpty
(
t
.
PersonnelNumber
)
&&
emp
.
JobNumber
?.
Trim
()
==
t
.
PersonnelNumber
?.
Trim
());
// 补充过一次就不在补充了
emp
.
OthePerfor
=
apramount
?.
Sum
(
w
=>
w
.
Amount
);
var
emp
=
computes
.
Where
(
w
=>
w
.
AccountingUnit
==
item
.
Key
.
AccountingUnit
&&
w
.
JobNumber
==
item
.
Key
.
JobNumber
)
.
OrderByDescending
(
w
=>
w
.
Source
).
FirstOrDefault
();
var
apramount
=
list
.
Where
(
t
=>
t
.
AccountingUnit
==
emp
.
AccountingUnit
&&
!
string
.
IsNullOrEmpty
(
t
.
PersonnelNumber
)
&&
emp
.
JobNumber
?.
Trim
()
==
t
.
PersonnelNumber
?.
Trim
());
emp
.
OthePerfor
=
apramount
?.
Sum
(
w
=>
w
.
Amount
)
??
0
;
//foreach (var emp in computes)
//{
// if (!emp.OthePerfor.HasValue || emp.OthePerfor == 0)
// {
// var apramount = list.Where(t => t.AccountingUnit == emp.AccountingUnit
// && !string.IsNullOrEmpty(t.PersonnelNumber) && emp.JobNumber?.Trim() == t.PersonnelNumber?.Trim());
// emp.OthePerfor = apramount?.Sum(w => w.Amount) ?? 0;
// }
//}
}
}
return
computes
;
return
computes
;
}
}
...
...
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