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
6d21eeaf
Commit
6d21eeaf
authored
Oct 15, 2020
by
lcx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
collect返回数据根据行号排序
parent
3fddbdd4
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
performance/Performance.Services/CollectService.cs
+6
-2
No files found.
performance/Performance.Services/CollectService.cs
View file @
6d21eeaf
...
...
@@ -310,7 +310,7 @@ public HandsonTable GetCollectData(int userId, int allotId, string sheetName)
List
<
HandsonRowData
>
rowDatas
=
null
;
var
collectdata
=
perforcollectdataRepository
.
GetEntities
(
w
=>
w
.
SheetName
==
sheet
.
SheetName
);
var
collectdata
=
perforcollectdataRepository
.
GetEntities
(
w
=>
w
.
SheetName
==
sheet
.
SheetName
&&
w
.
AllotID
==
allotId
);
if
(
collectdata
!=
null
)
{
Dictionary
<
string
,
string
>
config
=
null
;
...
...
@@ -326,7 +326,7 @@ public HandsonTable GetCollectData(int userId, int allotId, string sheetName)
config
=
CollectDataConfig
.
Default
;
rowDatas
=
new
List
<
HandsonRowData
>();
foreach
(
var
rownumber
in
collectdata
.
Select
(
w
=>
w
.
RowNumber
).
Distinct
())
foreach
(
var
rownumber
in
collectdata
.
Select
(
w
=>
w
.
RowNumber
).
Distinct
()
.
OrderBy
(
t
=>
t
)
)
{
var
first
=
collectdata
.
FirstOrDefault
(
w
=>
w
.
RowNumber
==
rownumber
);
var
json
=
JsonHelper
.
Serialize
(
first
);
...
...
@@ -355,6 +355,10 @@ public HandsonTable GetCollectData(int userId, int allotId, string sheetName)
rowDatas
=
GetCommonData
(
sheet
);
}
rowDatas
?.
RemoveAll
(
t
=>
!
t
.
CellData
.
Any
(
w
=>
!
string
.
IsNullOrEmpty
(
w
.
Value
?.
ToString
())));
if
(
rowDatas
!=
null
&&
rowDatas
.
Any
())
rowDatas
=
rowDatas
.
OrderBy
(
t
=>
t
.
Row
).
ToList
();
HandsonTable
handson
=
new
HandsonTable
(
sheet
.
SheetType
.
Value
,
cols
,
permissions
);
handson
.
SetRowData
(
rowDatas
);
return
handson
;
...
...
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