Quantcast
Viewing all articles
Browse latest Browse all 2401

XAF - Web Map Module (Coming soon in v15.2)

With this release, we're shipping a new Map module for XAF Web apps - allowing you display business objects on different kinds of maps. The module integrates the client-side dxMap and dxVectorMap widgets from DevExtreme into ASP.NET XAF applications via specialized XAF server-side wrappers like List and Property Editors: WebMapsListEditor, WebVectorMapsListEditor and WebMapsPropertyEditor.


Primary Capabilities

While designing this module, we considered customer feedback received during the research we conducted earlier this year and also previous user requests from the Support Center and other sources. Let's take a quick look at the functionality implemented in the initial release:


1. Interactive map displays objects implementing the IMapsMarker interface using the Google Maps API or Bing Maps API:

Image may be NSFW.
Clik here to view.
2015-09-30_1040.png

2. Vector map displays objects implementing the IAreaInfo interface as areas with different colors:

Image may be NSFW.
Clik here to view.
2015-09-30_1056.png


3. Vector map displays objects implementing the IVectorMapsPieMarker interface as pie-chart markers:

Image may be NSFW.
Clik here to view.
2015-09-30_1059.png

You can experience a live demo of our Map module in the ListEditors | Maps section of the offline Feature Center demo that is installed with XAF or check its online version at demos.devexpress.com/xaf/featurecenter once v15.2 is officially released.


Configuration

You can configure map types via the Model Editor invoked from Visual Studio or in code:

1. Configuring WebMapsPropertyEditor for a DetailView:

Image may be NSFW.
Clik here to view.

2. Configuring WebVectorMapsListEditor for a ListView:

Image may be NSFW.
Clik here to view.

3. Customizing the underlying dxMap widget in code of a ViewController for a ListView:

usingDevExpress.Persistent.Base;

namespaceDevExpress.ExpressApp.Maps.Web.Controllers {

   publicclassMapCenterController:ObjectViewController<ListView, Store> {

       protectedoverridevoidOnViewControlsCreated() {

           base.OnViewControlsCreated();

           ((WebMapsListEditor)View.Editor).MapViewer.ClientSideEvents.Customize=GetCustomizeScript();

       }

       privatestringGetCustomizeScript() {

           return@"function(sender, map) {

      map.option('center', 'Brooklyn Bridge,New York,NY');

                      map.option('autoAdjust', false);

    }";

       }

   }

}

===========================

We'd love to get your feedback on this new Map module and whether you are planning to use it in upcoming XAF Web apps.

Image may be NSFW.
Clik here to view.

Viewing all articles
Browse latest Browse all 2401

Trending Articles