Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Relation reference widget wrong feature when "on map identification" #29884

Closed
qgib opened this issue May 14, 2019 · 11 comments
Closed

Relation reference widget wrong feature when "on map identification" #29884

qgib opened this issue May 14, 2019 · 11 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Forms High Priority Regression Something which used to work, but doesn't anymore

Comments

@qgib
Copy link
Contributor

qgib commented May 14, 2019

Author Name: matteo ghetta (@ghtmtt)
Original Redmine Issue: 22071
Affected QGIS version: 3.4.6
Redmine category:edit_widget
Assignee: Alessandro Pasotti


If confirmed I think something is really weird. In attach the complete project.

  • line layer with ID field
  • table layer with FK field
  • 1:N relation between line ID (parent) and table FK (child)
  • table FK widget type set (automatically) as "relation reference" and the "On map identification" checkbox checked
  • adding a line in the table layer and clicking on the "identify on map" button
  • the FK field of the table layer is set to line layer ID - 1 (so when the line ID is 2 the FK of the table is 1)

Verified with the same project in QGIS 3.4.6 and master


@qgib
Copy link
Contributor Author

qgib commented May 20, 2019

Author Name: Alessandro Pasotti (@elpaso)


I searched the whole code base but I cannot find any button labeled with "identify on map", let alone that I don't get how you can identify on map a table layer feature which has no geometry.

Can you please clarify?


  • status_id was changed from Open to Feedback

@qgib
Copy link
Contributor Author

qgib commented May 20, 2019

Author Name: matteo ghetta (@ghtmtt)


Yep, see attached image.


  • 14960 was configured as ksnip_20190520-135720.png

@qgib
Copy link
Contributor Author

qgib commented May 20, 2019

Author Name: Alessandro Pasotti (@elpaso)


I said: "I cannot find any button labeled with "identify on map""

not that I cannot find the options to set "On map identification"

@qgib
Copy link
Contributor Author

qgib commented May 20, 2019

Author Name: matteo ghetta (@ghtmtt)


I'm trying to identify geometric object FROM a geometryless table. I thought it make sense: if I want to identify a geometric pipe that belongs to a not spatial worker.

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: Giovanni Manghi (@gioman)


I'm also struggling to understand what is the issue and how replicate it.

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: matteo ghetta (@ghtmtt)


OK I try to be more clear:

  • open the attached project
  • a 1:N relation is already set up: Parent = Condotte Field = ID, Child = operai Field = FK
  • the labels on the condotte layers are taken from ID field
  • select operai and enter in the editing mode
  • add another row in the table and, instead of entering manually in the FK field the ID of the condotte layer, click on the On map identification button
  • when clicking on, for example, condotte with label (and ID) = 2, the FK field is filled with 1 (ID - 1). Therefore the relation is wrong

A gif in attach


  • 14965 was configured as ezgif.com-video-to-gif.gif

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: Giovanni Manghi (@gioman)


matteo ghetta wrote:

OK I try to be more clear:

  • open the attached project
  • a 1:N relation is already set up: Parent = Condotte Field = ID, Child = operai Field = FK
  • the labels on the condotte layers are taken from ID field
  • select operai and enter in the editing mode
  • add another row in the table and, instead of entering manually in the FK field the ID of the condotte layer, click on the On map identification button
  • when clicking on, for example, condotte with label (and ID) = 2, the FK field is filled with 1 (ID - 1). Therefore the relation is wrong

A gif in attach

Hi Matteo the gif is tiny, is not possible to read/see anything in it.

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: matteo ghetta (@ghtmtt)


OK here the link to the vieo that can be downloaded:

https://www.faunalia.eu/~matteo/qgis_bug/

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: Alessandro Pasotti (@elpaso)


  • assigned_to_id was configured as Alessandro Pasotti
  • status_id was changed from Feedback to Open

@qgib
Copy link
Contributor Author

qgib commented May 21, 2019

Author Name: Alessandro Pasotti (@elpaso)


PR #10047


  • status_id was changed from Open to In Progress
  • pull_request_patch_supplied was changed from 0 to 1
  • resolution was changed from to fixed/implemented

@qgib
Copy link
Contributor Author

qgib commented May 22, 2019

Author Name: Alessandro Pasotti (@elpaso)


Applied in changeset 2b14dac.


  • done_ratio was changed from 0 to 100
  • status_id was changed from In Progress to Closed

@qgib qgib closed this as completed May 22, 2019
@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! High Priority Forms Regression Something which used to work, but doesn't anymore labels May 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Forms High Priority Regression Something which used to work, but doesn't anymore
Projects
None yet
Development

No branches or pull requests

1 participant