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
08cbd670
Commit
08cbd670
authored
Dec 30, 2020
by
ruyun.zhang@suvalue.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复二次分配带出BUG
parent
fd0708d4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
1 deletions
+20
-1
performance/Performance.Services/Details/SecondAllotDetails.cs
+20
-1
No files found.
performance/Performance.Services/Details/SecondAllotDetails.cs
View file @
08cbd670
using
AutoMapper
;
using
Microsoft.Extensions.Logging
;
using
Performance.DtoModels
;
using
Performance.EntityModels
;
using
Performance.Infrastructure
;
using
Performance.Repository
;
using
System
;
using
System.Collections.Generic
;
...
...
@@ -11,6 +13,7 @@ namespace Performance.Services
{
public
class
SecondAllotDetails
:
IAutoInjection
{
private
readonly
ILogger
<
SecondAllotDetails
>
_logger
;
private
readonly
PerforAgsecondallotRepository
agsecondallotRepository
;
private
readonly
PerforAgusetempRepository
agusetempRepository
;
private
readonly
PerforAgtempitemRepository
agtempitemRepository
;
...
...
@@ -25,6 +28,7 @@ public class SecondAllotDetails : IAutoInjection
private
readonly
PersonService
personService
;
public
SecondAllotDetails
(
ILogger
<
SecondAllotDetails
>
logger
,
PerforAgsecondallotRepository
agsecondallotRepository
,
PerforAgusetempRepository
agusetempRepository
,
PerforAgtempitemRepository
agtempitemRepository
,
...
...
@@ -39,6 +43,7 @@ public class SecondAllotDetails : IAutoInjection
PersonService
personService
)
{
_logger
=
logger
;
this
.
agsecondallotRepository
=
agsecondallotRepository
;
this
.
agusetempRepository
=
agusetempRepository
;
this
.
agtempitemRepository
=
agtempitemRepository
;
...
...
@@ -401,6 +406,19 @@ private void SupplementFixedData(ag_secondallot secondAllot, List<BodyItem> body
}
}
}
else
if
(
employeeSource
==
(
int
)
EmployeeSource
.
Initial
)
{
var
savedDataList
=
agfixatitemRepository
.
GetEntities
(
w
=>
w
.
SecondId
==
secondAllot
.
Id
&&
w
.
RowNumber
.
HasValue
&&
w
.
RowNumber
==
-
1
);
if
(
savedDataList
!=
null
&&
savedDataList
.
Any
())
{
foreach
(
var
item
in
pairs
)
{
var
savedData
=
savedDataList
.
FirstOrDefault
(
w
=>
w
.
Type
==
(
int
)
TempColumnType
.
TopFixedColumns
&&
w
.
ItemName
==
item
.
Value
);
if
(!
string
.
IsNullOrEmpty
(
savedData
?.
ItemValue
)
&&
!
keyValue
.
Keys
.
Contains
(
item
.
Value
))
keyValue
.
Add
(
item
.
Value
,
savedData
.
ItemValue
);
}
}
}
else
{
var
configs
=
cofagainRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
secondAllot
.
AllotId
);
...
...
@@ -418,7 +436,8 @@ private void SupplementFixedData(ag_secondallot secondAllot, List<BodyItem> body
foreach
(
var
item
in
keyValue
)
{
var
field
=
bodyItems
.
FirstOrDefault
(
w
=>
w
.
RowNumber
==
-
1
&&
w
.
FiledName
==
item
.
Key
);
if
(
field
!=
null
&&
!
string
.
IsNullOrEmpty
(
item
.
Value
))
field
.
Value
=
item
.
Value
;
if
(
field
!=
null
&&
!
string
.
IsNullOrEmpty
(
item
.
Value
))
field
.
Value
=
item
.
Value
;
}
}
...
...
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