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
83c6192e
Commit
83c6192e
authored
Mar 01, 2022
by
lcx
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'hotfix/新建绩效复制数据过滤'
parents
3b76ba1f
d4eaea20
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
11 deletions
+19
-11
performance/Performance.Services/ConfigService.cs
+19
-11
No files found.
performance/Performance.Services/ConfigService.cs
View file @
83c6192e
...
...
@@ -980,10 +980,10 @@ public void Copy(per_allot allot)
}
logger
.
LogInformation
(
$"copy drugTypes"
);
var
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
);
var
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
&&
t
.
HospitalId
==
allot
.
HospitalId
);
if
(
drugTypes
==
null
||
!
drugTypes
.
Any
())
{
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypes
!=
null
&&
drugTypes
.
Any
())
{
var
newDrugTypes
=
drugTypes
.
Select
(
t
=>
new
cof_drugtype
{
HospitalId
=
allot
.
HospitalId
,
AllotID
=
allot
.
ID
,
Charge
=
t
.
Charge
,
ChargeType
=
t
.
ChargeType
});
...
...
@@ -992,10 +992,10 @@ public void Copy(per_allot allot)
}
logger
.
LogInformation
(
$"copy drugTypeDisburses"
);
var
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
);
var
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
&&
t
.
HospitalId
==
allot
.
HospitalId
);
if
(
drugTypeDisburses
==
null
||
!
drugTypeDisburses
.
Any
())
{
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypeDisburses
!=
null
&&
drugTypeDisburses
.
Any
())
{
var
newDrugTypeDisburses
=
drugTypeDisburses
.
Select
(
t
=>
new
cof_drugtype_disburse
{
HospitalId
=
allot
.
HospitalId
,
AllotID
=
allot
.
ID
,
Charge
=
t
.
Charge
,
ChargeType
=
t
.
ChargeType
});
...
...
@@ -1004,10 +1004,10 @@ public void Copy(per_allot allot)
}
logger
.
LogInformation
(
$"copy drugTypeFactors"
);
var
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
);
var
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
&&
t
.
HospitalId
==
allot
.
HospitalId
);
if
(
drugTypeFactors
==
null
||
!
drugTypeFactors
.
Any
())
{
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypeFactors
!=
null
&&
drugTypeFactors
.
Any
())
{
var
newDrugtypeFactors
=
drugTypeFactors
.
Select
(
t
=>
new
cof_drugtype_factor
...
...
@@ -1117,7 +1117,7 @@ public void NewCopy(CopyRequest request)
}
var
Types
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
&&
t
.
HospitalId
==
allot
.
HospitalId
);
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypes
=
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
_drugtypeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypes
!=
null
&&
drugTypes
.
Any
())
{
var
newDrugTypes
=
drugTypes
.
Select
(
t
=>
new
cof_drugtype
{
HospitalId
=
allot
.
HospitalId
,
AllotID
=
allot
.
ID
,
Charge
=
t
.
Charge
,
ChargeType
=
t
.
ChargeType
});
...
...
@@ -1131,21 +1131,29 @@ public void NewCopy(CopyRequest request)
{
drugtypeDisburseRepository
.
RemoveRange
(
drugTypeDisburses
.
ToArray
());
}
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypeDisburses
=
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
drugtypeDisburseRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypeDisburses
!=
null
&&
drugTypeDisburses
.
Any
())
{
var
newDrugTypeDisburses
=
drugTypeDisburses
.
Select
(
t
=>
new
cof_drugtype_disburse
{
HospitalId
=
allot
.
HospitalId
,
AllotID
=
allot
.
ID
,
Charge
=
t
.
Charge
,
ChargeType
=
t
.
ChargeType
});
var
newDrugTypeDisburses
=
drugTypeDisburses
.
Select
(
t
=>
new
cof_drugtype_disburse
{
HospitalId
=
allot
.
HospitalId
,
AllotID
=
allot
.
ID
,
Charge
=
t
.
Charge
,
ChargeType
=
t
.
ChargeType
});
drugtypeDisburseRepository
.
AddRange
(
newDrugTypeDisburses
.
ToArray
());
}
break
;
case
"drugTypeFactors"
:
logger
.
LogInformation
(
$"copy drugTypeFactors"
);
var
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
);
var
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allot
.
ID
&&
t
.
HospitalId
==
allot
.
HospitalId
);
if
(
drugTypeFactors
!=
null
)
{
cofdrugtypefactorRepository
.
RemoveRange
(
drugTypeFactors
.
ToArray
());
}
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
)
??
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
drugTypeFactors
=
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
allotId
&&
t
.
HospitalId
==
allot
.
HospitalId
)
??
cofdrugtypefactorRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
-
1
);
if
(
drugTypeFactors
!=
null
&&
drugTypeFactors
.
Any
())
{
var
newDrugtypeFactors
=
drugTypeFactors
.
Select
(
t
=>
new
cof_drugtype_factor
...
...
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