Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in
Toggle navigation
F
fund_report
Project
Project
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
彭熊
fund_report
Commits
d144adb0
Commit
d144adb0
authored
Jan 22, 2021
by
pengxiong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix5
parent
c8d49e6e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
2 deletions
+10
-2
report_service.py
app/service/report_service.py
+10
-2
No files found.
app/service/report_service.py
View file @
d144adb0
...
...
@@ -14,7 +14,8 @@ import uuid
from
sqlalchemy
import
and_
,
or_
# from sqlalchemy import union_all
from
app.api.engine
import
TAMP_SQL
,
tamp_diagnose_app_engine
,
template_folder
,
temp_img_save_folder
,
pdf_save_folder
from
app.api.engine
import
TAMP_SQL
,
tamp_diagnose_app_engine
,
template_folder
,
temp_img_save_folder
,
pdf_save_folder
,
\
pdf_folder
from
app.model.tamp_diagnose_app
import
HoldReport
,
HoldDiagnoseReport
,
PeriodicReport
,
Customer
,
ReportView
,
\
FundReportManange
from
app.utils.jinjia2html_v2
import
DataIntegrate
...
...
@@ -189,6 +190,7 @@ def make_report(args):
args
[
'create_time'
]
=
datetime
.
datetime
.
now
()
args
[
'update_status'
]
=
1
data
=
{}
record_id
=
0
default_template
=
''
with
TAMP_SQL
(
tamp_diagnose_app_engine
)
as
tamp_diagnose_app
:
...
...
@@ -264,9 +266,15 @@ def make_report(args):
'update_status'
:
2
,
'update_time'
:
datetime
.
datetime
.
now
()
})
data
=
{
"id"
:
record_id
,
"file"
:
pdf_folder
+
pdf_name
,
"customer_id"
:
customer_id
,
"ifa_id"
:
ifa_id
,
"update_status"
:
res
[
0
]
.
update_status
,
"update_time"
:
res
[
0
]
.
update_time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
)}
else
:
res
.
update
({
'update_status'
:
0
,
'update_time'
:
datetime
.
datetime
.
now
()
})
return
{
'record_id'
:
record_id
}
data
=
{
"id"
:
record_id
,
"file"
:
''
,
"customer_id"
:
customer_id
,
"ifa_id"
:
ifa_id
,
"update_status"
:
res
[
0
]
.
update_status
,
"update_time"
:
res
[
0
]
.
update_time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
)}
return
data
\ No newline at end of file
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