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

Fix #2321. Keep circle on change #2326

Merged
merged 3 commits into from
Oct 24, 2017

Conversation

offtherailz
Copy link
Member

@offtherailz offtherailz commented Oct 24, 2017

Description

This pull request fixes 2 kind of issues in Advanced Search circle spatial filter:

  • When you edit the circle's details the style doesn't change to marker
  • When you save the edited circle, the geometry is valid.

Issues

Please check if the PR fulfills these requirements

What kind of change does this PR introduce? (check one with "x", remove the others)

  • Bugfix

What is the current behavior? (You can also link to an open issue here)
In advanced search, when you try to edit the circle's details, a marker appears on the map instead of circle. When save the changes, the geometry is not valid and so the search produces no results.

What is the new behavior?
Now you can change the details and the geometry remains a circle.

Does this PR introduce a breaking change? (check one with "x", remove the other)

  • No

Other information:
The #2222 still exists. So the real geometry used for the filter is not the same of the one drown on the map.

@ghost ghost assigned offtherailz Oct 24, 2017
@ghost ghost added the pending review label Oct 24, 2017
@coveralls
Copy link

Coverage Status

Coverage increased (+0.08%) to 80.456% when pulling bf32363 on offtherailz:i2321 into 8fee578 on geosolutions-it:2017.05.00.

@coveralls
Copy link

coveralls commented Oct 24, 2017

Coverage Status

Coverage increased (+0.1%) to 80.491% when pulling 8472001 on offtherailz:i2321 into 8fee578 on geosolutions-it:2017.05.00.

@@ -144,12 +144,20 @@ class GeometryDetails extends React.Component {
center.x - this.circle.radius, center.y - this.circle.radius,
center.x + this.circle.radius, center.y + this.circle.radius
];

let coordinates = CoordinatesUtils.calculateCircleCoordinates(center, this.circle.radius, 100);
if (this.props.geometry && this.props.geometry.projection === "EPSG:4326") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can't we reproject from any projection that is not the current map projection to the current map projection?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I could try, but don't know if it works, because of #2222

@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 80.491% when pulling 366023b on offtherailz:i2321 into 8fee578 on geosolutions-it:2017.05.00.

@offtherailz offtherailz merged commit 515a4c0 into geosolutions-it:2017.05.00 Oct 24, 2017
@ghost ghost removed the pending review label Oct 24, 2017
@offtherailz offtherailz deleted the i2321 branch February 18, 2020 11:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants