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
ddaf6481
Commit
ddaf6481
authored
Oct 15, 2019
by
李承祥
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
获取录入数据是,补充type和sourcetype;刷新应用模板时,同时也对type和sourcetype进行补充
parent
0af79186
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
3 deletions
+10
-3
performance/Performance.DtoModels/AutoMapper/AutoMapperConfigs.cs
+1
-2
performance/Performance.Services/SecondAllotService.cs
+9
-1
No files found.
performance/Performance.DtoModels/AutoMapper/AutoMapperConfigs.cs
View file @
ddaf6481
...
...
@@ -186,8 +186,7 @@ public AutoMapperConfigs()
CreateMap
<
ag_tempitem
,
HeadItem
>();
CreateMap
<
ag_workload
,
HeadItem
>()
.
ForMember
(
dest
=>
dest
.
FiledId
,
opt
=>
opt
.
MapFrom
(
src
=>
src
.
ItemId
))
.
ForMember
(
dest
=>
dest
.
FiledName
,
opt
=>
opt
.
MapFrom
(
src
=>
src
.
ItemName
))
.
ForMember
(
dest
=>
dest
.
Type
,
opt
=>
opt
.
NullSubstitute
(
3
));
.
ForMember
(
dest
=>
dest
.
FiledName
,
opt
=>
opt
.
MapFrom
(
src
=>
src
.
ItemName
));
CreateMap
<
ag_fixatitem
,
BodyItem
>()
.
ForMember
(
dest
=>
dest
.
FiledName
,
opt
=>
opt
.
MapFrom
(
src
=>
src
.
ItemName
))
.
ForMember
(
dest
=>
dest
.
Value
,
opt
=>
opt
.
MapFrom
(
src
=>
src
.
ItemValue
));
...
...
performance/Performance.Services/SecondAllotService.cs
View file @
ddaf6481
...
...
@@ -199,6 +199,8 @@ public void RefreshTemp(UseTempRequest request)
UnitType
=
fixatList
.
First
().
UnitType
,
Sort
=
tempItem
?.
FirstOrDefault
(
w
=>
w
.
FiledName
==
s
)?.
Sort
??
workItem
?.
FirstOrDefault
(
w
=>
w
.
ItemName
==
s
)?.
Sort
,
FactorValue
=
workItem
?.
FirstOrDefault
(
w
=>
w
.
ItemName
==
s
)?.
FactorValue
,
Type
=
tempItem
?.
FirstOrDefault
(
w
=>
w
.
FiledName
==
s
)?.
Type
??
3
,
SourceType
=
tempItem
?.
FirstOrDefault
(
w
=>
w
.
FiledName
==
s
)?.
SourceType
??
1
,
}));
});
if
(
addItems
!=
null
&&
addItems
.
Count
()
>
0
)
...
...
@@ -357,7 +359,11 @@ public SecondResponse GetSecondDetail(UseTempRequest request)
//获取工作量列头
var
workItem
=
perforAgworkloadRepository
.
GetEntities
(
t
=>
t
.
HospitalId
==
usetemp
.
HospitalId
&&
t
.
Department
==
usetemp
.
Department
&&
t
.
UnitType
==
usetemp
.
UnitType
);
if
(
workItem
!=
null
&&
workItem
.
Count
>
0
)
headItems
.
AddRange
(
Mapper
.
Map
<
List
<
HeadItem
>>(
workItem
));
{
var
workDtos
=
Mapper
.
Map
<
List
<
HeadItem
>>(
workItem
);
workDtos
.
ForEach
(
t
=>
{
t
.
Type
=
3
;
});
headItems
.
AddRange
(
workDtos
);
}
var
result
=
new
SecondResponse
{
HeadItems
=
headItems
};
//获取数据
...
...
@@ -379,6 +385,8 @@ public SecondResponse GetSecondDetail(UseTempRequest request)
AllotId
=
fixatList
.
First
().
AllotId
,
SecondId
=
fixatList
.
First
().
SecondId
,
UnitType
=
fixatList
.
First
().
UnitType
,
Type
=
headItems
?.
FirstOrDefault
(
s
=>
s
.
FiledName
==
t
)?.
Type
,
SourceType
=
headItems
?.
FirstOrDefault
(
s
=>
s
.
FiledName
==
t
)?.
SourceType
,
Sort
=
headItems
?.
FirstOrDefault
(
s
=>
s
.
FiledName
==
t
)?.
Sort
,
FactorValue
=
headItems
?.
FirstOrDefault
(
s
=>
s
.
FiledName
==
t
)?.
FactorValue
,
}));
...
...
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