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
8f6f6de3
authored
2021-10-07 10:30:05 +0800
by
周伟奇
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
add pos interface
1 parent
bb783cf1
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
0 deletions
src/apps/doc/internal_urls.py
src/apps/doc/views.py
src/apps/doc/internal_urls.py
View file @
8f6f6de
...
...
@@ -4,4 +4,5 @@ from . import views
urlpatterns
=
[
path
(
r''
,
views
.
DocView
.
as_view
()),
path
(
r'contract/v1'
,
views
.
SEContractView
.
as_view
()),
]
...
...
src/apps/doc/views.py
View file @
8f6f6de
...
...
@@ -440,6 +440,17 @@ se_cms_args = {
'content'
:
fields
.
Nested
(
se_cms_content
,
required
=
True
)
}
se_contract_content
=
{
'uniqSeq'
:
fields
.
Str
(
required
=
True
,
validate
=
validate
.
Length
(
max
=
128
)),
'applicationId'
:
fields
.
Str
(
required
=
True
,
validate
=
validate
.
Length
(
max
=
64
)),
'applicationEntity'
:
fields
.
Str
(
required
=
True
,
validate
=
validate
.
OneOf
(
consts
.
ENTITY
)),
"applicationVersion"
:
fields
.
Int
(
required
=
True
),
}
se_contract_args
=
{
'content'
:
fields
.
Nested
(
se_contract_content
,
required
=
True
)
}
result_item_args
=
{
consts
.
HEAD_LIST
[
0
]:
fields
.
Str
(
required
=
True
),
consts
.
HEAD_LIST
[
1
]:
fields
.
Str
(
required
=
True
),
...
...
@@ -1129,3 +1140,14 @@ class SECMSView(GenericView):
schema:
$ref: '#/definitions/ApiResponse'
'''
class
SEContractView
(
GenericView
):
permission_classes
=
[
IsAuthenticated
]
authentication_classes
=
[
OAuth2AuthenticationWithUser
]
# pos上传e-contract信息接口 SE
@use_args
(
se_contract_args
,
location
=
'data'
)
def
post
(
self
,
request
,
args
):
self
.
running_log
.
info
(
'e-contract in'
)
return
response
.
ok
()
...
...
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