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
61a31bc8
Commit
61a31bc8
authored
Jul 06, 2021
by
lcx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
保存
parent
b8a7c1cd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
30 additions
and
7 deletions
+30
-7
performance/Performance.Services/ConfigService.cs
+30
-7
No files found.
performance/Performance.Services/ConfigService.cs
View file @
61a31bc8
...
@@ -1260,20 +1260,43 @@ public HandsonTable GetDrugtypeFactorConfig(int hospitalId)
...
@@ -1260,20 +1260,43 @@ public HandsonTable GetDrugtypeFactorConfig(int hospitalId)
return
table
;
return
table
;
}
}
public
void
SaveDrugtypeFactor
(
List
<
object
>
nestedHeadersArray
,
string
[][]
data
,
int
hospitalId
)
public
void
SaveDrugtypeFactor
(
List
<
object
>
nestedHeadersArray
,
string
[][]
data
,
int
hospitalId
,
int
allotId
)
{
{
if
(
data
==
null
||
!
data
.
Any
(
t
=>
t
!=
null
&&
t
.
Count
()
>
0
&&
!
string
.
IsNullOrEmpty
(
t
[
0
])))
return
;
if
(
data
==
null
||
!
data
.
Any
(
t
=>
t
!=
null
&&
t
.
Count
()
>
0
&&
!
string
.
IsNullOrEmpty
(
t
[
0
])))
return
;
var
charges
=
new
List
<
view_dic_category_factor
>();
var
charges
=
new
List
<
view_dic_category_factor
>();
if
(
nestedHeadersArray
[
0
]
is
List
<
NestedHeader
>
modelHeaders
&&
modelHeaders
.
Any
(
t
=>
!
string
.
IsNullOrEmpty
(
t
.
Label
)))
if
(
nestedHeadersArray
[
0
]
is
List
<
NestedHeader
>
modelHeaders
&&
modelHeaders
.
Any
(
t
=>
!
string
.
IsNullOrEmpty
(
t
.
Label
)))
{
{
var
models
=
modelHeaders
.
Where
(
t
=>
!
string
.
IsNullOrEmpty
(
t
.
Label
)).
Select
(
t
=>
t
.
Label
);
var
headers
=
nestedHeadersArray
[
1
]
as
List
<
string
>;
var
exmodels
=
perforExmoduleRepository
.
GetEntities
(
t
=>
t
.
HospitalId
==
hospitalId
&&
t
.
SheetType
==
(
int
)
SheetType
.
Income
);
var
modelnames
=
modelHeaders
.
Where
(
t
=>
!
string
.
IsNullOrEmpty
(
t
.
Label
)).
Select
(
t
=>
t
.
Label
);
if
(
exmodels
==
null
||
!
exmodels
.
Any
())
return
;
var
models
=
perforExmoduleRepository
.
GetEntities
(
t
=>
t
.
HospitalId
==
hospitalId
&&
t
.
SheetType
==
(
int
)
SheetType
.
Income
);
if
(
models
==
null
||
!
models
.
Any
())
return
;
foreach
(
var
item
in
data
.
Where
(
t
=>
t
!=
null
&&
t
.
Count
()
>
0
&&
!
string
.
IsNullOrEmpty
(
t
[
0
])))
{
foreach
(
var
item
in
data
.
Where
(
t
=>
t
!=
null
&&
t
.
Count
()
==
headers
.
Count
&&
!
string
.
IsNullOrEmpty
(
t
[
0
])))
{
string
charge
=
item
[
0
];
string
chargeType
=
item
[
1
];
int
index
=
0
;
foreach
(
var
modelname
in
modelnames
)
{
index
++;
var
exmodel
=
models
.
FirstOrDefault
(
t
=>
t
.
ModuleName
==
modelname
);
if
(
exmodel
==
null
)
continue
;
var
dic
=
new
view_dic_category_factor
{
HospitalId
=
hospitalId
,
AllotID
=
allotId
,
Charge
=
charge
,
ChargeType
=
chargeType
,
ExModuleId
=
exmodel
.
Id
,
ModuleName
=
modelname
,
YSZ
=
ConvertHelper
.
To
<
decimal
?>(
item
[
2
+
3
*
(
index
-
1
)]),
HLZ
=
ConvertHelper
.
To
<
decimal
?>(
item
[
3
+
3
*
(
index
-
1
)]),
YJZ
=
ConvertHelper
.
To
<
decimal
?>(
item
[
4
+
3
*
(
index
-
1
)]),
};
charges
.
Add
(
dic
);
}
}
}
}
}
}
}
...
...
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