Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
周伟奇
/
bmw-ocr
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
f476be1f
authored
2021-03-24 11:31:32 +0800
by
周伟奇
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
fix bug
1 parent
3a34be19
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
0 deletions
src/apps/doc/views.py
src/apps/doc/views.py
View file @
f476be1
...
...
@@ -29,6 +29,12 @@ class CustomDate(fields.Date):
return
value
class
CustomDecimal
(
fields
.
Decimal
):
def
_deserialize
(
self
,
value
,
attr
,
data
,
**
kwargs
):
return
self
.
_to_string
(
self
.
_validated
(
value
))
# restframework将request.body封装至request.data, webargs从request.data中获取参数
@parser.location_loader
(
"data"
)
def
load_data
(
request
,
schema
):
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment