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
22114acb
Commit
22114acb
authored
Dec 23, 2021
by
lcx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
刷新报表
parent
3bacd8be
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
1 deletions
+16
-1
performance/Performance.Api/Controllers/AllotController.cs
+9
-1
performance/Performance.Services/AllotService.cs
+7
-0
No files found.
performance/Performance.Api/Controllers/AllotController.cs
View file @
22114acb
...
...
@@ -297,7 +297,15 @@ public ApiResponse GenerateReport([CustomizeValidator(RuleSet = "Delete"), FromB
if
(
null
==
allot
||
!
states
.
Contains
(
allot
.
States
))
throw
new
PerformanceException
(
"当前绩效暂未生成,无法统计报表数据。"
);
//_publishEndpoint.Publish(allot).Wait();
_backgroundTaskQueue
.
QueueBackgroundWorkItem
(
async
token
=>
{
using
(
var
scope
=
_serviceScopeFactory
.
CreateScope
())
{
var
scopedServices
=
scope
.
ServiceProvider
.
GetRequiredService
<
AllotService
>();
scopedServices
.
GenerateReport
(
allot
);
await
Task
.
Delay
(
TimeSpan
.
FromSeconds
(
5
),
token
);
}
});
return
new
ApiResponse
(
ResponseType
.
OK
,
"统计报表数据任务开始"
);
}
...
...
performance/Performance.Services/AllotService.cs
View file @
22114acb
...
...
@@ -487,8 +487,15 @@ public void Generate(per_allot allot)
/// <param name="allot"></param>
public
void
GenerateReport
(
per_allot
allot
)
{
try
{
reportService
.
ExecProc
(
"call proc_report_performance(@hospitalid, @year, @month);"
,
new
{
allot
.
HospitalId
,
allot
.
Year
,
allot
.
Month
});
}
catch
(
Exception
ex
)
{
_logger
.
LogError
(
$"
{
allot
.
Year
}
年
{
allot
.
Month
}
月绩效报表生成失败。 allotid:
{
allot
.
ID
}
。"
+
ex
.
Message
);
}
}
/// <summary>
/// 验证科室核算单元、工号
...
...
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