Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
financial-system
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xianyang
financial-system
Commits
f45ecd52
Commit
f45ecd52
authored
Aug 04, 2023
by
xianyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
明细查询优化
parent
dbb1b0aa
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
+8
-0
crud.py
app/api/account/crud.py
+8
-0
No files found.
app/api/account/crud.py
View file @
f45ecd52
...
@@ -523,6 +523,14 @@ class AccountStatistics(object):
...
@@ -523,6 +523,14 @@ class AccountStatistics(object):
guild_cond_list
=
[]
guild_cond_list
=
[]
start_time
=
time_str_to_timestamp
(
self
.
start_time
+
' 00:00:00'
)
start_time
=
time_str_to_timestamp
(
self
.
start_time
+
' 00:00:00'
)
end_time
=
time_str_to_timestamp
(
self
.
end_time
+
' 23:59:59'
)
end_time
=
time_str_to_timestamp
(
self
.
end_time
+
' 23:59:59'
)
if
not
self
.
amount_type
:
guild_cond_list
.
append
(
"amount_type=1"
)
else
:
if
self
.
amount_type
==
'consumable'
:
amount_type_num
=
2
else
:
amount_type_num
=
3
guild_cond_list
.
append
(
f
"amount_type={amount_type_num}"
)
guild_cond_list
.
append
(
f
" (income>0 or outcome>0 or initial_money>0) "
)
guild_cond_list
.
append
(
f
" (income>0 or outcome>0 or initial_money>0) "
)
guild_cond_list
.
append
(
f
" create_time >={start_time} and create_time<= {end_time}"
)
guild_cond_list
.
append
(
f
" create_time >={start_time} and create_time<= {end_time}"
)
if
self
.
user_id
:
if
self
.
user_id
:
...
...
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