Toggle navigation
Toggle navigation
This project
Loading...
Sign in
zhouhui.jiang
/
Test_LangGraph
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
zhouhui.jiang
2025-11-16 21:39:48 +0800
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
5a587a09512df8e921bb808cee530f378b76344b
5a587a09
1 parent
606c5821
update
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
0 deletions
API/waybill_api.py
API/waybill_api.py
View file @
5a587a0
...
...
@@ -42,6 +42,7 @@ def create_waybill_d(consignmentCode: str, Authorization: str = None) -> str:
- message: 创建结果描述(成功时:"创建运单成功",失败时:具体的失败原因)
- consignmentCode: 运单编号
- waybill_id: 运单ID
- consStatus: 运单状态
- operate_unit_name: 操作单位名称
- operate_unit_code: 操作单位代码
- detailList: 明细列表
...
...
@@ -96,6 +97,7 @@ def create_waybill_d(consignmentCode: str, Authorization: str = None) -> str:
result_data
=
{
"consignmentCode"
:
code
,
"waybill_id"
:
str
(
waybill_id
)
if
waybill_id
else
""
,
"consStatus"
:
""
,
"operate_unit_name"
:
""
,
"operate_unit_code"
:
""
,
"detailList"
:
[]
...
...
@@ -118,6 +120,7 @@ def create_waybill_d(consignmentCode: str, Authorization: str = None) -> str:
if
head_resp
.
status_code
==
200
:
head_json
=
head_resp
.
json
()
head_extra
=
(
head_json
.
get
(
"data"
)
or
{})
.
get
(
"extra"
)
or
{}
result_data
[
"consStatus"
]
=
head_extra
.
get
(
"consStatus"
)
or
""
result_data
[
"operate_unit_name"
]
=
head_extra
.
get
(
"operateUnitName"
)
or
""
result_data
[
"operate_unit_code"
]
=
head_extra
.
get
(
"operateUnitCode"
)
or
""
except
Exception
:
...
...
@@ -243,6 +246,7 @@ def query_waybill_info(consignmentCode: str, Authorization: str = None) -> str:
- message: 查询结果描述(成功时:"查询详情成功",失败时:具体的失败原因)
- consignmentCode: 运单编号
- waybill_id: 运单ID
- consStatus: 运单状态
- operate_unit_name: 操作单位名称
- operate_unit_code: 操作单位代码
- detailList: 明细列表
...
...
@@ -257,6 +261,7 @@ def query_waybill_info(consignmentCode: str, Authorization: str = None) -> str:
result_data
=
{
"consignmentCode"
:
consignmentCode
,
"waybill_id"
:
""
,
"consStatus"
:
""
,
"operate_unit_name"
:
""
,
"operate_unit_code"
:
""
,
"detailList"
:
[]
...
...
@@ -285,6 +290,9 @@ def query_waybill_info(consignmentCode: str, Authorization: str = None) -> str:
result_data
[
"consignmentCode"
]
=
returned_code
result_data
[
"waybill_id"
]
=
str
(
waybill_id
)
if
waybill_id
else
""
# 提取运单状态
result_data
[
"consStatus"
]
=
head_extra
.
get
(
"consStatus"
)
or
""
# 提取公司信息
result_data
[
"operate_unit_name"
]
=
head_extra
.
get
(
"operateUnitName"
)
or
""
result_data
[
"operate_unit_code"
]
=
head_extra
.
get
(
"operateUnitCode"
)
or
""
...
...
Please
register
or
login
to post a comment