Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
D
doc
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
bo
doc
Commits
09e1934d
Commit
09e1934d
authored
Apr 15, 2025
by
bo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update orders_sort.md
parent
244cc275
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
21 deletions
+24
-21
orders_sort.md
orders_sort.md
+24
-21
No files found.
orders_sort.md
View file @
09e1934d
# 方式一
# 方式一
## /tools/v1/orders_sort_rcmd
##
pos
t
##
ge
t
## params:
cur_poi: lng,lat
next_order: id,lng,lat
# 下一单,经纬度
cur_poi: lng,lat
# 当前位置
next_order: id,lng,lat
,lng,lat # 指定下一单,单号,经纬度对 (已取货单只有一个经纬度)
orders: id,lng,lat,lng,lat;id,lng,lat;id,lng,lat
# 单子id关联经纬度,可以有多组组成,每组之间分号分隔
# 一组有 已经取货订单 和 未取货订单 两种状态,已取货订单 由id标记和纬经度组成
# 单子id在此处无意义,只是作为返回前台的标记
## return:
{
"path": 'id,lng,lat,1;id,lng,lat,2;id,lng,lat,1',
""
"data": {
"path": "id,lng,lat,2;id,lng,lat,2;id,lng,lat,1;id,lng,lat,2",
"total_line_distance": 20009.40
}
}
path字段,订单id,经纬度,1取货底/2送货地为一组,以分号分隔
total_line_distance字段 直线距离总和,单位米
# 方式二
## /tools/v1/orders_sort_rcmd
## post
## params:
body传递参数 json格式
## params: (body传递参数 json格式)
{
"cur_poi": ["lng", "lat"],
"next_order": {
"id": "id",
"end_poi": ["lng", "lat"]
},
"cur_poi": "lng,lat",
"next_order": "id"
"orders" : [{
"id": "id",
"st_poi":
["lng", "lat"]
,
"end_poi":
["lng", "lat"]
"st_poi":
"lng,lat"
,
"end_poi":
"lng,lat"
},{
"id": "id",
"st_poi":
["lng", "lat"]
,
"end_poi":
["lng", "lat"]
"st_poi":
"lng,lat"
,
"end_poi":
"lng,lat"
}]
}
\ No newline at end of file
## return:
与方式一相同
\ No newline at end of file
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