Closed aleayr closed 8 years ago
I think we'd want to understand more about the stories and what are involved to help push this one along?
The benefit a mapping module brings over just embedding a map is that it allows you to create a dynamic view of items near a specific location, and then display that view as points on a map. Many agencies would see a benefit from this when displaying shopfronts or providers near the user. It is particularly useful where users move about frequently, or an agency lists services in overseas areas, or in regional and remote locations. The other benefit it brings is in allowing the map's views filters to be exposed to the user, thereby enabling the user to dynamically switch between different types of services or providers, as well as shift the locational bounds as required.
I am looking for a simple interface mostly to show data the department produces. We currently use National map, but it is not very responsive when embedded. Simple is the key, show people your data and let them search it.
Pinging @kurtsalsa as I think he was working on something similar.
I'm implementing a front end solution at the moment. It's only POC at this moment but I'm also having the issue of search by location, which isn't available in govCMS. Do GMAP and Location provide this functionality, I thought they only provide views of all content via views on a map and location based search in drupal search, but I'm not that familiar with them.
The PoC just pulls everything back on a single map level in a json object via custom ajax and renders it using the Google Maps JS API, when the user clicks though on this level, we pull the next level in. It works well enough but this won't work well when users move the map around or zoom in etc.
I know leaflet provides search by location functionality in views, however I'm pretty sure it still uses session vars for anonymous users, invalidating varnish cache, so it's not a great option.
I think that using Map class getBounds() function I should be able to pass that into my view and pull back all of my layers with lat / long points within those bounds, regardless of their layer and get what I need. This would then work when the user zooms / moves the map etc. I can just store the updated data in the browser and avoid having to constantly retrieve it.
I'm not sure it that works for you @aleayr, but that's my workaround for govCMS.
The DECD team requires the ability to embed maps from Google and http://www.location.sa.gov.au/viewer/ as part of our launch.
This is further complicated by the need to auto-generate these maps when importing data from a csv file using feed.
My original attempt to use an iframe has been unsuccessful as the iframe code has been blacklisted in the WYSIWYG editor.
An example of the content we need to replicate in the govCMS system can be seen here:
http://www.decd.sa.gov.au/locs/a8_publish/modules/locations_new/school_detail.asp?id=3636&type=AZ`
Can this issue be escalated? Our ideal solution would include a module that can handle embedding maps, whilst playing nicely with the feeds and feeds tamper modules.
Is the data in lat long format is does it require to be geocoded?
We use lat and long as some of our schools are on long country roads so google doesn't always display them correctly.
From the CSV file, currently we have latitude and longitude as separate fields (e.g. "34.815955" and "140.216073") which get plugged into the search as "-34.815955,140.216073"
@Pixie74943, if iframes were allowed in the editor, would this be a satisfactory option for you to keep moving forward?
I believe if iframes were accepted by the rich-text editor then it would solve our current problem.
Is this something that could be implemented in the next 48hours? If not, what is the expected timeframe?
@aleayr from a broader strategy perspective, adding complex capabilities to wysiwyg editors is probably grinding against structured data initiatives. In the distro, we should add geo and gis capabilities. But to get over the line for DECD, perhaps we can give them this capability in the editor without committing such a change to the distro?
I've created #162 as a beginning module capability. We'd still need to provide does and evaluate if it should be available out of the box or featurized to provide a base implementation.
@nicholas-gk @Pixie74943 - it sounds like Comms and DECD have some overlapping requirements in regarding to mapping functionality. Comms currently uses iFrames to embed the National Map - https://www.communications.gov.au/what-we-do/internet/competition-broadband/telecommunications-new-developments-map @nicholas-gk may be able to provide some feedback on how this interim solution is currently working from a management/publishing perspective...
@kurtsalsa With the gmap module you create your view and add "Search: Search Terms" as an exposed filter. The search terms work with the Location module if youv'e set up geocoding and have geocoded data for the items in your view. The exposed filter search box just filters the items in the view which is being mapped, so from an end user's perspective it just narrows down the number of items on the map. You'd need to spin up a local environment to see if it meets your specific needs, however it is usually pretty good. We think Gmap is certainly a much better solution than iframes.
@WebProject2015, agreed re the iframes. The addressfield module is already in govCMS, so I'm not sure if that could be leveraged instead of also adding Location @fiasco?
We're still in PoC phase at the moment and our use case is a little different. We need to display very large polygons with a large number of points, rather than individual points on a map, the search is by clicking on a polygon, then the map should zoom in and show the polygons that existing within that polygons area. I'll take a look to see if GMap will help with our requirements.
@kurtsalsa my PR was really just to get some conversation happening. I too would like to see if we could achieve our objectives here with less. Perhaps the geocoder module would be a better fit over the location module?
mapping in Drupal 7 is quite interesting - from 1-2 modules simple task to "mapping module suite" that can provide robust features and APIs.
Two very useful links regarding "Drupal mapping" are on Drupal community:
Not only Google map, mapping also brings many other popular frameworks and service providers into the panels.
For example. data.gov.au(http://data.gov.au/dataset/acnc2014ais) uses "Map box"(https://www.mapbox.com/about/maps/), leaflet (http://leafletjs.com/) and OpenStreetMap(https://www.openstreetmap.org) Some government sites uses OpenLayers http://openlayers.org/ for advanced mapping features such as GeoScience Australia, State of Victoria gov site.
IMO, before moving into this mapping area, iFrame is a good solution for urgent and small requirements. On another side, we can start from collecting more generic user requirements, modules analysis, hardware requirements such as higher memory or more storage space, UI and mapping accessibility etc.
@cdriessen We have the ability to use iFrames if we are creating individual pages (I've created a text format that accepts iframe) however when using the feeds import it does not accept the iframes. From what I can see this is because it's importing into the Rich-text format and will not allow me to import into a different text format.
For us to get what we need from a module/extension/upgrade we need to be able to import data (Long and Lat) via the feeds module and have a map auto generated. This seems slightly different to Dept Comms needs (correct me if I am wrong) - we are generating locations for 900+ schools and education sites, so manual isn't a viable option.
I've only had a cursory look at the locations and gmap modules, however I was unable to connect them with Feeds. I placed a locations field in my content type and manually entered long and lat - giving me the map I needed. However when I went over to the Feeds module, I was unable to select this locations field as a mapping option.
@Pixie74943
Need a "fields mapping module" for feeds in your case
Check this out "feeds location module" https://www.drupal.org/project/location_feeds
This is only from technical side regrading "unable to select this locations field as a mapping option" :)
I've just had an unofficial chat with a developer friend of mine and we've nutted out a workaround for using iframes via the import that is working quite nicely. We've created a new text format and set it as the default for the importer.
I still need to test it in the live site to be 100% it all works as it does in the test environment. The iframe solution obviously isn't the best for accessibilty, but it will get us over the line :)
@jozhao Thanks :+1: that looks perfect (haven't tested it)
@jozhao Last commit was 3 years ago, there also hasn't been an issue closed or a bug fixed in three years. The maintainer has at least commented on bugs within the past 12 months, but it would appear only to ask for other maintainers.
True. Many modules in Drupal community are as this one. Even in current govcms code base, we may notice this point more or less. So is Drupal core, we are still trying to push a book module fix on both 7 and 8 which has been discussed for 6+ years since 6. :)
I didn't suggest adding this one into govcms code base, instead, as Josh and Jason, we are trying to keep govcms code base in a scaleable and stable condition.
Back to this discussion, iFrame can resolve urgent and small requirements. We need a careful plan and analysis the generic requirements before setting up a govcms mapping solution.
On 10 Feb 2016, at 6:33 PM, WebProject2015 notifications@github.com wrote:
@jozhao Last commit was 3 years ago, there also hasn't been an issue closed or a bug fixed in three years. The maintainer has at least commented on bugs within the past 12 months, but it would appear only to ask for other maintainers.
— Reply to this email directly or view it on GitHub.
I just thought I'd see if anyone had an opinion on the views json output / Google Maps js API solutions we're using. I'm not sure if it fits your use case, but it's working well and we don't require an iframe.
Hi everyone, I'm the lead developer of NationalMap and its underlying library, TerriaJS, at NICTA / Data61. It sounds like you at least considered using NationalMap with GovCMS and maybe ran into some difficulties, so I wanted to introduce myself in case I can help. We have seen several Australian government web sites embed NationalMap via an iframe now, and there are more options for tweaking there than may be immediately apparent. We're also in the process of some UI changes that will, among other things, make NationalMap much more usable inside smaller windows. Lastly, for advanced scenarios, it's possible to use TerriaJS inside a div on a web page in much the same way you would Leaflet or Google Maps.
Let me know if I can help. My email address in on the web page linked from my github profile if you want to contact me directly.
Services module has now been committed which can provide the functionality for this issue. Please create a new ticket if it does not.
A web build has several stories requiring address and dynamic map functionalities. The following modules are handy for that: Location module (https://www.drupal.org/project/location) GMap module (https://www.drupal.org/project/gmap)