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
34972b5a
Commit
34972b5a
authored
Aug 30, 2022
by
Licx
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' into 医院其他绩效
# Conflicts: # performance/Performance.Services/EmployeeService.cs
parents
91a49d67
152ebb34
Show whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
139 additions
and
95 deletions
+139
-95
performance/Performance.Api/Controllers/ReportGlobalController.cs
+4
-4
performance/Performance.Repository/PerforPerapramountRepository.cs
+66
-39
performance/Performance.Services/AllotCompute/ResultComputeService.cs
+1
-0
performance/Performance.Services/AllotService.cs
+1
-0
performance/Performance.Services/ComputeService.cs
+8
-4
performance/Performance.Services/DapperService.cs
+24
-0
performance/Performance.Services/EmployeeService.cs
+2
-12
performance/Performance.Services/PersonService.cs
+9
-14
performance/Performance.Services/RedistributionService.cs
+1
-2
performance/Performance.Services/ReportGlobalService.cs
+12
-13
performance/Performance.Services/SecondAllot/SecondAllotDetails.cs
+2
-2
performance/Performance.Services/SecondAllot/SecondAllotService.cs
+1
-1
performance/Performance.Services/SecondAllotService.cs
+8
-4
No files found.
performance/Performance.Api/Controllers/ReportGlobalController.cs
View file @
34972b5a
...
...
@@ -164,8 +164,8 @@ public ApiResponse GetReportPersonTag(int hospitalId, int allotId)
var
relust
=
reportGlobalService
.
GetReportPersonTag
(
hospitalId
,
allotId
);
return
new
ApiResponse
(
ResponseType
.
OK
,
new
{
relust
.
ColHeaders
,
relust
.
Data
relust
.
handsonTable
.
ColHeaders
,
relust
.
handsonTable
.
Data
});
}
/// <summary>
...
...
@@ -179,13 +179,13 @@ public ApiResponse GetReportPersonTag(int hospitalId, int allotId)
public
ActionResult
DownloadReportPersonTag
(
int
hospitalId
,
int
allotId
)
{
var
result
=
reportGlobalService
.
GetReportPersonTag
(
hospitalId
,
allotId
).
Data
;
var
(
result
,
colHeaders
)
=
reportGlobalService
.
GetReportPersonTag
(
hospitalId
,
allotId
)
;
var
ser
=
JsonHelper
.
Serialize
(
result
);
var
rows
=
JsonHelper
.
Deserialize
<
List
<
Dictionary
<
string
,
object
>>>(
ser
);
var
filepath
=
reportGlobalService
.
ReportPersonTagDownload
(
rows
,
"人员标签"
);
var
filepath
=
reportGlobalService
.
ReportPersonTagDownload
(
rows
,
colHeaders
,
"人员标签"
);
var
memoryStream
=
new
MemoryStream
();
using
(
var
stream
=
new
FileStream
(
filepath
,
FileMode
.
Open
))
...
...
performance/Performance.Repository/PerforPerapramountRepository.cs
View file @
34972b5a
...
...
@@ -3,6 +3,7 @@
// * FileName: per_apr_amount.cs
// </copyright>
//-----------------------------------------------------------------------
using
Dapper
;
using
Performance.EntityModels
;
using
System
;
using
System.Collections.Generic
;
...
...
@@ -16,50 +17,76 @@ namespace Performance.Repository
/// </summary>
public
partial
class
PerforPerapramountRepository
:
PerforRepository
<
per_apr_amount
>
{
public
List
<
view_per_apr_amount
>
GetFullAmount
(
Expression
<
Func
<
per_apr_amount
,
bool
>>
predicate
)
{
var
amounts
=
GetEntities
(
predicate
);
if
(
amounts
==
null
||
!
amounts
.
Any
())
return
new
List
<
view_per_apr_amount
>();
//public List<view_per_apr_amount> GetFullAmount(Expression<Func<per_apr_amount, bool>> predicate)
//{
// var amounts = GetEntities(predicate);
// if (amounts == null || !amounts.Any())
// return new List<view_per_apr_amount>();
// var ids = amounts.Select(w => w.AllotId).Distinct().ToList();
// var employees = this.context.Set<per_employee>()
// .Where(w => w.AllotId.HasValue && ids.Contains(w.AllotId.Value))
// .Select(w => new
// {
// UnitType = w.UnitType,
// AccountingUnit = w.AccountingUnit,
// AllotId = w.AllotId,
// PersonnelNumber = w.PersonnelNumber,
// DoctorName = w.DoctorName,
// });
var
ids
=
amounts
.
Select
(
w
=>
w
.
AllotId
).
Distinct
().
ToList
();
// var res = from outer in amounts
// join inner in employees
// on new { outer.AllotId, outer.PersonnelNumber } equals new { AllotId = inner.AllotId ?? 0, inner.PersonnelNumber } into temp
// from tt in temp.DefaultIfEmpty()
// select new view_per_apr_amount
// {
// Id = outer.Id,
// AllotId = outer.AllotId,
// PersonnelNumber = outer.PersonnelNumber,
// PerforType = outer.PerforType,
// Amount = outer.Amount,
// DoctorName = tt?.DoctorName ?? "",
// AccountingUnit = tt?.AccountingUnit ?? "",
// UnitType = tt?.UnitType ?? "",
// TypeInDepartment = outer.TypeInDepartment,
// Status = outer.Status,
// AuditTime = outer.AuditTime,
// AuditUser = outer.AuditUser,
// CreateDate = outer.CreateDate,
// CreateUser = outer.CreateUser,
// Remark = outer.Remark,
// IsVerify = outer.IsVerify,
// VerifyMessage = outer.VerifyMessage,
// };
// return res.ToList() ?? new List<view_per_apr_amount>();
//}
var
employees
=
this
.
context
.
Set
<
per_employee
>()
.
Where
(
w
=>
w
.
AllotId
.
HasValue
&&
ids
.
Contains
(
w
.
AllotId
.
Value
))
.
Select
(
w
=>
new
public
List
<
view_per_apr_amount
>
GetFullAmount
(
int
?
allotId
,
int
?
status
,
string
typeInDepartment
=
""
)
{
UnitType
=
w
.
UnitType
,
AccountingUnit
=
w
.
AccountingUnit
,
AllotId
=
w
.
AllotId
,
PersonnelNumber
=
w
.
PersonnelNumber
,
DoctorName
=
w
.
DoctorName
,
});
string
sql
=
"select AllotId, PersonnelNumber, Trim(AccountingUnit) AccountingUnit, UnitType, DoctorName, PerforType, Amount, TypeInDepartment, Status, Remark from view_other_amount where ifnull(amount,0)<>0 "
;
DynamicParameters
parameters
=
new
DynamicParameters
();
var
res
=
from
outer
in
amounts
join
inner
in
employees
on
new
{
outer
.
AllotId
,
outer
.
PersonnelNumber
}
equals
new
{
AllotId
=
inner
.
AllotId
??
0
,
inner
.
PersonnelNumber
}
into
temp
from
tt
in
temp
.
DefaultIfEmpty
()
select
new
view_per_apr_amount
if
(
allotId
.
HasValue
&&
allotId
>
0
)
{
Id
=
outer
.
Id
,
AllotId
=
outer
.
AllotId
,
PersonnelNumber
=
outer
.
PersonnelNumber
,
PerforType
=
outer
.
PerforType
,
Amount
=
outer
.
Amount
,
DoctorName
=
tt
?.
DoctorName
??
""
,
AccountingUnit
=
tt
?.
AccountingUnit
??
""
,
UnitType
=
tt
?.
UnitType
??
""
,
TypeInDepartment
=
outer
.
TypeInDepartment
,
Status
=
outer
.
Status
,
AuditTime
=
outer
.
AuditTime
,
AuditUser
=
outer
.
AuditUser
,
CreateDate
=
outer
.
CreateDate
,
CreateUser
=
outer
.
CreateUser
,
Remark
=
outer
.
Remark
,
IsVerify
=
outer
.
IsVerify
,
VerifyMessage
=
outer
.
VerifyMessage
,
};
return
res
.
ToList
()
??
new
List
<
view_per_apr_amount
>();
sql
+=
" and allotId = @allotId"
;
parameters
.
Add
(
"allotId"
,
allotId
);
}
if
(
status
.
HasValue
&&
status
>
0
)
{
sql
+=
" and status = @status"
;
parameters
.
Add
(
name
:
"status"
,
status
);
}
if
(!
string
.
IsNullOrEmpty
(
typeInDepartment
))
{
sql
+=
" and typeInDepartment = @typeInDepartment"
;
parameters
.
Add
(
name
:
"typeInDepartment"
,
typeInDepartment
);
}
return
DapperQuery
<
view_per_apr_amount
>(
sql
,
parameters
).
ToList
();
}
}
}
performance/Performance.Services/AllotCompute/ResultComputeService.cs
View file @
34972b5a
...
...
@@ -701,6 +701,7 @@ public bool IssuedChangeSecond(per_allot allot, List<ag_secondallot> secondList)
}
_service
.
FreezeAllotSync
(
allot
.
ID
);
_service
.
SecondUseTempRestoreSync
();
_service
.
RestoreSecondAllotAsync
();
}
}
perforAgsecondallotRepository
.
UpdateRange
(
updSeconds
.
ToArray
());
...
...
performance/Performance.Services/AllotService.cs
View file @
34972b5a
...
...
@@ -454,6 +454,7 @@ public void Generate(per_allot allot)
resultComputeService
.
GenerateSecondAllot
(
allot
);
_service
.
FreezeAllotSync
(
allot
.
ID
);
_service
.
SecondUseTempRestoreSync
();
_service
.
RestoreSecondAllotAsync
();
_service
.
ClearAllotSync
();
UpdateAllotStates
(
allot
.
ID
,
(
int
)
AllotStates
.
绩效结果解析成功
,
EnumHelper
.
GetDescription
(
AllotStates
.
绩效结果解析成功
),
generate
);
...
...
performance/Performance.Services/ComputeService.cs
View file @
34972b5a
...
...
@@ -621,7 +621,7 @@ public List<DeptResponse> GetAdminPerformance(int allotId)
#
region
医院其他绩效
&&
不公示其他绩效
var
otherPerformances
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
allotId
&&
t
.
Status
==
3
)
.
GetFullAmount
(
allotId
,
3
)
?.
GroupBy
(
t
=>
new
{
t
.
AccountingUnit
,
t
.
UnitType
})
.
Select
(
t
=>
new
view_per_total_amount
(
t
.
Key
.
UnitType
.
Replace
(
"行政后勤"
,
"行政工勤"
),
t
.
Key
.
AccountingUnit
,
""
,
t
.
Sum
(
s
=>
s
.
Amount
)
??
0
))
.
ToList
();
...
...
@@ -838,7 +838,7 @@ public List<ComputeResponse> AllCompute(int allotId, int hospitalId, int isShowM
// 医院其他绩效汇总
var
totalAmounts
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
allotId
&&
t
.
Status
==
3
)
.
GetFullAmount
(
allotId
,
3
)
?.
GroupBy
(
w
=>
new
{
w
.
AccountingUnit
,
w
.
UnitType
,
w
.
PersonnelNumber
})
.
Select
(
w
=>
new
view_per_total_amount
(
w
.
Key
.
UnitType
,
w
.
Key
.
AccountingUnit
,
w
.
Key
.
PersonnelNumber
,
w
.
Sum
(
t
=>
t
.
Amount
)
??
0
))
?.
ToList
();
...
...
@@ -2019,7 +2019,7 @@ public bool UpdateHeadersStatus(ComputerAliasUpdate request)
// 数据库中无数据
if
(
hasreq
&&
!
hasdata
)
{
var
items
=
request
.
computerAliasHead
.
Select
(
t
=>
t
.
Head
.
ToLower
())
;
var
items
=
request
.
computerAliasHead
;
var
data
=
heads
.
Select
(
t
=>
new
cof_alias
{
Route
=
request
.
Route
,
...
...
@@ -2027,11 +2027,15 @@ public bool UpdateHeadersStatus(ComputerAliasUpdate request)
OriginalName
=
t
.
Alias
,
HospitalId
=
request
.
HospitalId
,
Name
=
t
.
Name
,
States
=
items
.
Contains
(
t
.
Alias
??
""
)
?
1
:
0
,
SumStatus
=
t
.
SumStatus
,
Sort
=
request
.
computerAliasHead
.
Any
(
w
=>
w
.
Name
==
t
.
Name
)
?
request
.
computerAliasHead
.
FirstOrDefault
(
w
=>
w
.
Name
==
t
.
Name
).
Sort
:
t
.
Sort
}).
ToList
();
data
.
ForEach
(
t
=>
{
var
state
=
items
.
FirstOrDefault
(
i
=>
i
.
Head
.
ToLower
().
Contains
(
t
.
Alias
));
t
.
States
=
state
!=
null
?
state
.
States
:
1
;
});
cofaliasRepository
.
AddRange
(
data
.
ToArray
());
}
...
...
performance/Performance.Services/DapperService.cs
View file @
34972b5a
...
...
@@ -224,5 +224,29 @@ Deptdic GetDeptdic(List<per_dept_dic> dics, string department, string hISDeptNam
}
#
endregion
/// <summary>
/// 科室改名历史数据处理
/// </summary>
/// <param name="allotId"></param>
public
Task
RestoreSecondAllotAsync
()
{
return
Task
.
Factory
.
StartNew
(()
=>
{
using
(
var
connection
=
new
MySqlConnection
(
_options
.
Value
.
PerformanceConnectionString
))
{
if
(
connection
.
State
!=
ConnectionState
.
Open
)
connection
.
Open
();
try
{
string
sql
=
$@"call proc_restore_secondallot()"
;
connection
.
Execute
(
sql
,
commandTimeout
:
60
*
60
);
}
catch
(
Exception
)
{
throw
;
}
}
});
}
}
}
performance/Performance.Services/EmployeeService.cs
View file @
34972b5a
...
...
@@ -457,17 +457,7 @@ public List<per_apr_amount> GetAprList(int allotId, int userId)
/// <returns></returns>
public
List
<
view_per_apr_amount
>
GetAprList
(
int
allotId
,
string
department
,
int
?
status
=
null
,
DateTime
?
date
=
null
)
{
Expression
<
Func
<
per_apr_amount
,
bool
>>
predicate
=
w
=>
w
.
AllotId
==
allotId
&&
w
.
Amount
.
HasValue
&&
w
.
Amount
!=
0
;
if
(!
string
.
IsNullOrEmpty
(
department
))
predicate
=
predicate
.
And
(
w
=>
!
string
.
IsNullOrEmpty
(
w
.
TypeInDepartment
)
&&
w
.
TypeInDepartment
==
department
);
if
(
status
.
HasValue
)
predicate
=
predicate
.
And
(
w
=>
w
.
Status
==
status
);
if
(
date
!=
null
)
predicate
=
predicate
.
And
((
w
)
=>
w
.
CreateDate
==
date
);
var
list
=
perapramountRepository
.
GetFullAmount
(
predicate
);
var
list
=
perapramountRepository
.
GetFullAmount
(
allotId
,
status
,
department
);
if
(
list
!=
null
&&
list
.
Any
())
list
=
list
.
OrderBy
(
t
=>
t
.
DoctorName
).
ToList
();
...
...
@@ -784,7 +774,7 @@ public List<TitleValue> GetPerforTypeDict(int allotId)
public
List
<
Dictionary
<
string
,
string
>>
GetOtherPerStats
(
int
allotId
,
string
department
=
null
)
{
var
others
=
new
List
<
Dictionary
<
string
,
string
>>();
var
aprAmountList
=
perapramountRepository
.
GetFullAmount
(
w
=>
w
.
AllotId
==
allotId
&&
w
.
Status
==
3
);
var
aprAmountList
=
perapramountRepository
.
GetFullAmount
(
allotId
,
3
);
if
(
department
!=
null
)
aprAmountList
=
aprAmountList
.
Where
(
t
=>
t
.
AccountingUnit
==
department
).
ToList
();
var
perForType
=
aprAmountList
.
Select
(
t
=>
t
.
PerforType
).
Distinct
();
...
...
performance/Performance.Services/PersonService.cs
View file @
34972b5a
...
...
@@ -131,20 +131,15 @@ public void CreateAllotPersons(int hospitalId, int allotId, int prevAllotId = -1
BankCard
=
t
.
BankCard
,
Remark
=
t
.
Remark
,
CreateTime
=
DateTime
.
Now
,
PersonnelNumber
=
t
.
PersonnelNumber
,
JobNumber
=
t
.
JobNumber
};
if
(!
string
.
IsNullOrEmpty
(
t
.
PersonnelNumber
)
&&
!
string
.
IsNullOrEmpty
(
t
.
JobNumber
))
{
entity
.
PersonnelNumber
=
t
.
PersonnelNumber
;
entity
.
JobNumber
=
t
.
JobNumber
;
}
else
{
string
number
=
!
string
.
IsNullOrEmpty
(
t
.
PersonnelNumber
)
?
t
.
PersonnelNumber
:
t
.
JobNumber
;
entity
.
PersonnelNumber
=
number
;
entity
.
JobNumber
=
number
;
}
return
entity
;
}).
ToList
();
SaveAllotPersons
(
data
);
}
...
...
@@ -383,7 +378,7 @@ public bool DeletePerson(int employeeId)
if
(
employee
==
null
)
throw
new
PerformanceException
(
$"员工信息错误!"
);
var
oldbackup
=
perforPeremployeeBackupRepository
.
GetEntity
(
t
=>
t
.
Id
==
employee
.
Id
);
var
oldbackup
=
perforPeremployeeBackupRepository
.
GetEntity
(
t
=>
t
.
Id
==
employee
.
Id
);
if
(
oldbackup
!=
null
)
perforPeremployeeBackupRepository
.
Remove
(
oldbackup
);
...
...
@@ -852,7 +847,7 @@ public ApiResponse BathSavePerson(int allotId, int HospitalId, SaveCollectData r
var
jsons
=
JsonHelper
.
Serialize
(
dicData
);
var
newEmployees
=
JsonHelper
.
Deserialize
<
List
<
per_employee
>>(
jsons
);
var
oldEmployees
=
peremployeeRepository
.
GetEntities
(
t
=>
t
.
HospitalId
==
HospitalId
&&
t
.
AllotId
==
allotId
);
var
accountinglist
=
perforCofaccountingRepository
.
GetEntities
(
t
=>
t
.
AllotId
==
allotId
);
List
<
Dictionary
<
string
,
string
>>
error
=
new
List
<
Dictionary
<
string
,
string
>>();
for
(
int
i
=
0
;
i
<
newEmployees
.
Count
;
i
++)
...
...
@@ -909,8 +904,8 @@ public ApiResponse BathSavePerson(int allotId, int HospitalId, SaveCollectData r
});
}
var
accounting
list
=
perforCofaccountingRepository
.
GetEntity
(
w
=>
w
.
UnitType
==
newEmployees
[
i
].
UnitType
&&
w
.
AccountingUnit
==
newEmployees
[
i
].
AccountingUnit
);
if
(
accounting
lis
t
==
null
)
var
accounting
Unit
=
accountinglist
.
FirstOrDefault
(
w
=>
w
.
UnitType
==
newEmployees
[
i
].
UnitType
&&
w
.
AccountingUnit
==
newEmployees
[
i
].
AccountingUnit
);
if
(
accounting
Uni
t
==
null
)
{
error
.
Add
(
new
Dictionary
<
string
,
string
>
{
...
...
@@ -980,7 +975,7 @@ public ApiResponse BathSavePerson(int allotId, int HospitalId, SaveCollectData r
employees
.
ForEach
(
e
=>
{
var
result
=
backupTab
.
FirstOrDefault
(
d
=>
d
.
PersonnelNumber
.
Contains
(
e
.
PersonnelNumber
)
&&
d
.
AllotId
==
e
.
AllotId
&&
d
.
HospitalId
==
e
.
HospitalId
);
if
(
result
!=
null
)
if
(
result
!=
null
)
{
e
.
JobNumber
=
result
.
JobNumber
;
e
.
JobCategory
=
result
.
JobCategory
;
...
...
performance/Performance.Services/RedistributionService.cs
View file @
34972b5a
...
...
@@ -938,8 +938,7 @@ public void SupplementOtherPerfor(ag_secondallot second, List<Dictionary<string,
if
(
rows
==
null
||
rows
.
Count
==
0
)
return
;
var
perapramounts
=
_perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
second
.
AllotId
&&
t
.
Status
==
3
);
var
perapramounts
=
_perapramountRepository
.
GetFullAmount
(
second
.
AllotId
,
3
);
if
(
perapramounts
==
null
||
!
perapramounts
.
Any
())
return
;
...
...
performance/Performance.Services/ReportGlobalService.cs
View file @
34972b5a
...
...
@@ -544,7 +544,7 @@ private T GetCellValue<T>(IRow row, List<string> columns, string key)
#
region
人员、科室标签配置
public
HandsonTable
GetReportPersonTag
(
int
hospitalId
,
int
allotId
)
public
(
HandsonTable
handsonTable
,
List
<
string
>
colHeaders
)
GetReportPersonTag
(
int
hospitalId
,
int
allotId
)
{
var
hos
=
_hospitalRepository
.
GetEntity
(
t
=>
t
.
ID
==
hospitalId
);
var
columnHeaders
=
_computeService
.
CustomColumnHeaders
(
hos
,
"/result/all_employee"
);
...
...
@@ -590,7 +590,7 @@ select new
Tag5
=
t
?.
Tag5
,
}).
Distinct
()?.
ToList
();
if
(
data
==
null
||
!
data
.
Any
())
return
result
;
if
(
data
==
null
||
!
data
.
Any
())
return
(
result
,
null
)
;
var
users
=
new
List
<
sys_user
>();
if
(
hos
?.
IsOwnerQuery
==
1
)
...
...
@@ -630,10 +630,10 @@ select new
if
(
columns
.
Contains
(
t
.
Data
))
t
.
ReadOnly
=
true
;
});
return
result
;
return
(
result
,
result
.
ColHeaders
.
ToList
())
;
}
public
string
ReportPersonTagDownload
(
List
<
Dictionary
<
string
,
object
>>
rows
,
string
title
)
public
string
ReportPersonTagDownload
(
List
<
Dictionary
<
string
,
object
>>
rows
,
List
<
string
>
colHeaders
,
string
title
)
{
var
data
=
new
List
<
Dictionary
<
string
,
object
>>();
foreach
(
var
obj
in
rows
)
...
...
@@ -662,17 +662,16 @@ public string ReportPersonTagDownload(List<Dictionary<string, object>> rows, str
{
worksheet
.
SetValue
(
1
,
1
,
title
);
var
headList
=
data
.
FirstOrDefault
().
ToList
();
for
(
int
col
=
0
;
col
<
headList
.
Count
;
col
++)
for
(
int
col
=
0
;
col
<
colHeaders
.
Count
;
col
++)
{
worksheet
.
SetValue
(
2
,
col
+
1
,
headList
[
col
].
Key
);
worksheet
.
SetValue
(
2
,
col
+
1
,
colHeaders
[
col
]
);
}
for
(
int
col
=
0
;
col
<
headList
.
Count
;
col
++)
for
(
int
col
=
0
;
col
<
colHeaders
.
Count
;
col
++)
{
for
(
int
row
=
0
;
row
<
data
.
Count
();
row
++)
{
var
temp
=
data
.
ElementAt
(
row
);
var
value
=
temp
[
headList
[
col
].
Key
]
!=
null
?
temp
[
headList
[
col
].
Key
].
ToString
()
:
temp
[
headList
[
col
].
Key
];
var
value
=
temp
[
colHeaders
[
col
]]
!=
null
?
temp
[
colHeaders
[
col
]].
ToString
()
:
temp
[
colHeaders
[
col
]
];
worksheet
.
Cells
[
row
+
3
,
col
+
1
].
Value
=
value
;
}
...
...
@@ -689,10 +688,10 @@ public string ReportPersonTagDownload(List<Dictionary<string, object>> rows, str
worksheet
.
Cells
[
row
,
col
].
Style
.
HorizontalAlignment
=
ExcelHorizontalAlignment
.
Center
;
}
}
worksheet
.
Cells
[
1
,
1
,
1
,
headList
.
Count
].
Merge
=
true
;
worksheet
.
Cells
[
1
,
1
,
1
,
headList
.
Count
].
Style
.
Font
.
Bold
=
true
;
worksheet
.
Cells
[
1
,
1
,
1
,
headList
.
Count
].
Style
.
Font
.
Size
=
16
;
worksheet
.
Cells
[
2
,
1
,
2
,
headList
.
Count
].
Style
.
Font
.
Bold
=
true
;
worksheet
.
Cells
[
1
,
1
,
1
,
colHeaders
.
Count
].
Merge
=
true
;
worksheet
.
Cells
[
1
,
1
,
1
,
colHeaders
.
Count
].
Style
.
Font
.
Bold
=
true
;
worksheet
.
Cells
[
1
,
1
,
1
,
colHeaders
.
Count
].
Style
.
Font
.
Size
=
16
;
worksheet
.
Cells
[
2
,
1
,
2
,
colHeaders
.
Count
].
Style
.
Font
.
Bold
=
true
;
worksheet
.
Row
(
1
).
Height
=
24
;
worksheet
.
View
.
FreezePanes
(
3
,
1
);
worksheet
.
Cells
.
AutoFitColumns
();
...
...
performance/Performance.Services/SecondAllot/SecondAllotDetails.cs
View file @
34972b5a
...
...
@@ -487,7 +487,7 @@ private void SupplementOtherPerfor(ag_secondallot secondAllot, List<BodyItem> bo
{
if
(
bodyItems
==
null
||
!
bodyItems
.
Any
(
w
=>
w
.
RowNumber
>
-
1
))
return
;
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
secondAllot
.
AllotId
&&
t
.
Status
==
3
);
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
secondAllot
.
AllotId
,
3
);
if
(
perapramounts
==
null
||
!
perapramounts
.
Any
())
return
;
var
rowNumberList
=
bodyItems
.
Where
(
w
=>
w
.
RowNumber
>
-
1
).
Select
(
w
=>
w
.
RowNumber
).
Distinct
().
OrderBy
(
t
=>
t
).
ToList
();
...
...
@@ -816,7 +816,7 @@ public List<ag_othersource> GetOtherTempDetails(int userId, int secondId, int is
private
void
SupplementSecondDetail
(
ag_secondallot
second
,
List
<
per_employee
>
employees
,
List
<
ag_othersource
>
result
,
bool
isTitlePerformance
=
true
)
{
// 补充医院其他绩效 及 预留比例
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
second
.
AllotId
&&
t
.
Status
==
3
);
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
second
.
AllotId
,
3
);
var
distPerformance
=
rescomputeRepository
.
GetEntities
(
t
=>
t
.
AllotID
==
second
.
AllotId
);
foreach
(
var
item
in
result
)
...
...
performance/Performance.Services/SecondAllot/SecondAllotService.cs
View file @
34972b5a
...
...
@@ -195,7 +195,7 @@ private void SupplementOtherPerfor(ag_secondallot secondAllot, List<ag_bodysourc
{
if
(
bodyItems
==
null
||
!
bodyItems
.
Any
(
w
=>
w
.
RowNumber
>
-
1
))
return
;
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
secondAllot
.
AllotId
&&
t
.
Status
==
3
);
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
secondAllot
.
AllotId
,
3
);
if
(
perapramounts
==
null
||
!
perapramounts
.
Any
())
return
;
foreach
(
var
rowitem
in
bodyItems
)
...
...
performance/Performance.Services/SecondAllotService.cs
View file @
34972b5a
...
...
@@ -179,7 +179,10 @@ public List<SecondListResponse> GetSecondList(int userId)
// 查询过往科室的绩效
var
histroys
=
agsecondallotRepository
.
GetEntities
(
t
=>
allotListId
.
Contains
(
t
.
AllotId
.
Value
)
&&
unitType
.
Contains
(
t
.
NewUnitType
)
&&
t
.
NewAccountingUnit
==
userInfo
.
User
.
Department
);
if
(
histroys
!=
null
&&
histroys
.
Any
())
secondList
.
AddRange
(
histroys
.
ToArray
());
{
var
sids
=
secondList
.
Select
(
w
=>
w
.
Id
).
ToArray
();
secondList
.
AddRange
(
histroys
.
Where
(
w
=>
!
sids
.
Contains
(
w
.
Id
)));
}
var
list
=
_mapper
.
Map
<
List
<
SecondListResponse
>>(
secondList
);
...
...
@@ -917,8 +920,8 @@ public List<SecondTempResponse> GetTemp(int hospitalid, string department, int u
public
bool
UseTemp
(
UseTempRequest
request
)
{
var
result
=
false
;
var
entit
y
=
agusetempRepository
.
GetEntity
(
t
=>
t
.
HospitalId
==
request
.
HospitalId
&&
t
.
Department
==
request
.
Department
&&
t
.
UnitType
==
request
.
UnitType
);
var
entit
ies
=
agusetempRepository
.
GetEntities
(
t
=>
t
.
HospitalId
==
request
.
HospitalId
&&
t
.
Department
==
request
.
Department
);
var
entity
=
entities
.
FirstOrDefault
(
w
=>
UnitTypeUtil
.
IsEqualsUnitType
(
w
.
UnitType
,
request
.
UnitType
)
);
if
(
entity
==
null
)
{
entity
=
_mapper
.
Map
<
ag_usetemp
>(
request
);
...
...
@@ -1737,6 +1740,7 @@ public bool ConfirmAudit(int userId, SecondAuditRequest request)
if
(
request
.
IsPass
==
1
)
_service
.
FreezeAllotSync
(
second
.
AllotId
.
Value
);
_service
.
SecondUseTempRestoreSync
();
_service
.
RestoreSecondAllotAsync
();
return
result
;
}
...
...
@@ -2319,7 +2323,7 @@ public dynamic Print(int secondId)
}
// 补充医院其他绩效 及 预留比例
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
t
=>
t
.
AllotId
==
second
.
AllotId
&&
t
.
Status
==
3
);
var
perapramounts
=
perapramountRepository
.
GetFullAmount
(
second
.
AllotId
,
3
);
var
employees
=
personService
.
GetPerEmployee
(
second
.
AllotId
.
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