Modify

Opened 7 years ago

Closed 7 years ago

Last modified 6 years ago

#15676 closed enhancement (fixed)

[PATCH] New keyword 'currentselection' for parameter 'select' in LoadAndZoom handler

Reported by: skorbut Owned by: team
Priority: normal Milestone: 17.12
Component: Core remotecontrol Version:
Keywords: Cc:

Description

The RemoteControl function allows to select OSM objects based on their ID and then set tags for these objects using a call such as:

GET /load_and_zoom?left=...&right=...&top=...&bottom=...&addtags=name=MyName&select=node1234,way5678

However, when importing data from another datasource that is unrelated to OSM, OSM IDs (here "node1234" and "way5678") for an import can't be directly used to create an URL for the remote plugin since they are unknown to this datasource. Because of this I'd like to realize a workflow, where one can select one (or multiple) OSM objects in JOSM and then add tags to these selected objects using a call such as:

GET /load_and_zoom?left=...&right=...&top=...&bottom=...&addtags=name=MyName&select=currentselection

To get a more solid idea how this would work, look at http://demo.tlab.ch/tomas-gr . There you'll find data from a touristic organisation which are donated under CC0 to OSM. The workflow would be:

  1. In JOSM: open a suitable region
  2. (optional) In JOSM: create a new node/way/relation
  3. In JOSM: Select OSM object(s) onto which tags should be pasted
  4. On website: Click link to paste tags into JOSM
  5. In JOSM: Decide which tags to actually apply to object(s)

I've attached a corresponding patch.

It's written in a way that would also allow to select new objects in addition to the currently selected ones:

GET /load_and_zoom?left=...&right=...&top=...&bottom=...&addtags=name=MyName&select=currentselection,node1234,way5678

PS: I'm aware that the tags listed at http://demo.tlab.ch/tomas-gr (e.g. stars=...) still need some tweaking to be directly imported.

Attachments (1)

currentselection.diff (2.1 KB ) - added by skorbut 7 years ago.

Download all attachments as: .zip

Change History (4)

by skorbut, 7 years ago

Attachment: currentselection.diff added

comment:1 by Don-vip, 7 years ago

Milestone: 17.12

comment:2 by Don-vip, 7 years ago

Resolution: fixed
Status: newclosed

In 13212/josm:

fix #15676 - Remote Control: add new keyword currentselection for parameter select in LoadAndZoomHandler (patch by skorbut, modified)

comment:3 by simon04, 6 years ago

In 14377/josm:

see #15676 - Add usage example for select=currentselection

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.