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
dafe918e
Commit
dafe918e
authored
Apr 28, 2020
by
魏强
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update;
parent
c1282bdb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
1 deletions
+17
-1
Controller/RentController.py
+17
-1
No files found.
Controller/RentController.py
View file @
dafe918e
...
...
@@ -353,7 +353,7 @@ def force_refund():
logger
.
info
(
'comment'
)
logger
.
info
(
comment
)
if
not
refund_type
or
not
rent_no
or
not
comment
:
if
not
refund_type
or
not
rent_no
:
return
jsonify
(
PARAMETER_ERROR
)
rent_info
=
db
.
session
.
query
(
Production
,
Rent
)
.
join
(
Rent
,
Rent
.
id
==
Production
.
rent_id
)
.
filter
(
...
...
@@ -371,17 +371,33 @@ def force_refund():
elif
refund_type
==
'3'
:
# 按时间扣款
back_time
=
json_data
.
get
(
'back_time'
,
None
)
logger
.
info
(
'back time'
)
logger
.
info
(
back_time
)
if
not
comment
or
not
back_time
:
return
jsonify
(
PARAMETER_ERROR
)
money
=
RentService
.
check_fee_liuyuan
(
rent_info
.
Rent
.
pay_time
.
strftime
(
'
%
Y-
%
m-
%
d
%
H:
%
M:
%
S'
),
back_time
.
strftime
(
'
%
Y-
%
m-
%
d
%
H:
%
M:
%
S'
),
rent_info
.
Rent
.
one_day_price
,
rent_info
.
Rent
.
free_time
)
elif
refund_type
==
'4'
:
# 退10元
if
not
comment
:
return
jsonify
(
PARAMETER_ERROR
)
money
=
1000
elif
refund_type
==
'5'
:
# 退15元
if
not
comment
:
return
jsonify
(
PARAMETER_ERROR
)
money
=
1500
elif
refund_type
==
'6'
:
# 退25元
if
not
comment
:
return
jsonify
(
PARAMETER_ERROR
)
money
=
2500
else
:
return
jsonify
({
'code'
:
-
1
,
'msg'
:
'refund type error!'
})
...
...
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