Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tour_business
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
魏强
tour_business
Commits
36b7eaf4
Commit
36b7eaf4
authored
Jun 15, 2020
by
魏强
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qwe;
parent
880b1874
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
2 deletions
+11
-2
Service/RentService.py
+11
-2
No files found.
Service/RentService.py
View file @
36b7eaf4
...
...
@@ -197,7 +197,7 @@ class RentService():
@staticmethod
def
get_search_info_
(
key_word
,
page
,
limit
):
sql
=
'''
SELECT rent.rent_no, production.rent_hatch_no, production.total, production.is_return,
SELECT rent.rent_no,
rent.rent_type,
production.rent_hatch_no, production.total, production.is_return,
production.return_hatch_no, customers.phone, rent.pay_time FROM rent
LEFT JOIN production ON production.rent_id = rent.id
LEFT JOIN customers ON customers.id = rent.customer_id
...
...
@@ -214,7 +214,16 @@ class RentService():
cur_info
[
'hatch_no'
]
=
info
.
rent_hatch_no
cur_info
[
'total'
]
=
info
.
total
if
info
.
total
else
0
cur_info
[
'phone'
]
=
info
.
phone
if
info
.
is_return
==
1
:
if
info
.
rent_type
==
2
:
if
cur_info
[
'total'
]
<=
0
:
if
info
.
return_hatch_no
==
127
:
cur_info
[
'status'
]
=
3
else
:
cur_info
[
'status'
]
=
2
else
:
cur_info
[
'status'
]
=
1
elif
info
.
is_return
==
1
:
if
cur_info
[
'total'
]
<=
0
:
if
info
.
return_hatch_no
==
127
:
cur_info
[
'status'
]
=
3
...
...
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