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

GMF draw feature directive #1001

Merged
merged 1 commit into from Apr 12, 2016
Merged

GMF draw feature directive #1001

merged 1 commit into from Apr 12, 2016

Conversation

adube
Copy link
Contributor

@adube adube commented Apr 8, 2016

This PR introduces the gmf-drawfeature directive, which allows the user to draw vector features on the map and change their style, geometry, etc. There are still things to do to consider the tool completed.

Features

This PR introduces

  • a new gmf-drawfeature directive that combines the ngeo-drawfeature and gmf-featurestyle directives
  • an example
  • you can select a feature from the list or from the map
  • you can change the style
  • you can modify the geometry
  • delete one or more features

It also contains some bug fixes across the other components used by the directive.

This PR will not introduce

  • proper modification of circles
  • proper modification of rectangles
  • move feature
  • export
  • drop-down menu on feature "click"
  • official CSS styling
  • show vertexes on selection / feature modification
  • export

Todo

  • Fix the example (not working properly in builded version)
  • Code review
  • Travis build passes
  • Merge into 1 commit

Live example

@adube adube force-pushed the edit-feature branch 2 times, most recently from 0a7fcd9 to c428a8e Compare April 8, 2016 16:00
@fgravin
Copy link
Member

fgravin commented Apr 11, 2016

Can you rebase please

* @ngdoc directive
* @ngname gmfEditfeature
*/
gmf.editfeatureDirective = function() {
Copy link
Member

Choose a reason for hiding this comment

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

If one day we want to edit a real feature (from WFS), edit its attributes for example. Would it be in same directive ?
Is the name editFeature is well chosen ?

@sbrunner
Copy link
Member

Just one issue I see, the measure should be rounded at 3 significant digits :-)

@adube
Copy link
Contributor Author

adube commented Apr 11, 2016

  • Rebase: OK
  • Multiple selection: No
  • Rounded at 3 significant digits: What do you mean ?

@sbrunner
Copy link
Member

For example display 591 km instance of 591.54 km in the panel and on the map when the "Display length" is checked, finally the same as the tooltip that's display while drawing :-)

@adube adube force-pushed the edit-feature branch 4 times, most recently from f8cd417 to ceac59d Compare April 11, 2016 18:00
@adube adube changed the title (wip) GMF edit feature directive (wip) GMF draw feature directive Apr 11, 2016
@adube
Copy link
Contributor Author

adube commented Apr 11, 2016

@fgravin Ready for merge.

@pgiraud
Copy link
Contributor

pgiraud commented Apr 12, 2016

@sbrunner "561 km" already has 3 significant digits. Other examples are 5.42 km or 48.6 km or 7520 km.

@sbrunner
Copy link
Member

@pgiraud yes it's what's I say, but we get 591.54 km that have 5 significant digits ...

@sbrunner
Copy link
Member

We will get, now it's corrected :-)

@fgravin fgravin changed the title (wip) GMF draw feature directive GMF draw feature directive Apr 12, 2016
controller: 'GmfDrawfeatureController',
scope: {
'active': '=gmfDrawfeatureActive',
'map': '=gmfDrawfeatureMap'
Copy link
Member

Choose a reason for hiding this comment

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

<gmfDrawfeatureMap

@fgravin
Copy link
Member

fgravin commented Apr 12, 2016

Perfect just one minor comment.
Please update it and i'll merge

@adube
Copy link
Contributor Author

adube commented Apr 12, 2016

Done.

@fgravin fgravin merged commit 96d165b into camptocamp:master Apr 12, 2016
@adube adube deleted the edit-feature branch April 12, 2016 15:56
@sbrunner sbrunner added this to the Older milestone Aug 23, 2019
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

4 participants