@merefield What are your thoughts about this requirement?
Stefan apologies for not getting back to you. Thatâs a more practical consideration and quite a nice idea. Iâll consider it when I have some downtime. It wonât happen for a while though as have client work atm. Funding will always help to get stuff implemented/sooner.
No worries, I had thought it might have slipped through. Should I open a feature request somewhere?
Sure, here: Feature Request
Done! @everyone Please support this feature request!
Iâve released a significant performance fix that got rid of a duplicate call:
https://github.com/paviliondev/discourse-locations/pull/52
So the User Map should become responsive much sooner.
PS thanks to @Richie for pointing out the scalability challenge and helping me with the testing.
Hereâs his impressive User Map to prove you can get this working for over 500 people!:
Thanks for the continued development of the plugin @merefield
When I click on a marker on the map then the redirection raise an error in the browser console :
TypeError: "u is undefined"
navigatedToPost _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:9981
routeTo _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:9898
routeTo _discourse-custom-wizard-05c36c40f360683b056c7ad300041bc66902371a17c22f1686fa56420a8af7c1.js:1655
afterModel _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:69656
jQuery 12
success _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:8950
jQuery 4
_application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:67085:12
error _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:67085
jQuery 16
success _application-2f2672bcf25571484a5186c75f87af2bb65928918a5bc5c9932f237dc0636348.js:8950
jQuery 4
Outside of support period at moment but will take a look at next one.
Which map are you referring to - just tried the User map on a recent build and it works fine?
This is on a topic with a location.
New feature time!
Restricted search by country
Iâve added the ability to restrict search by the default country. This is default OFF.
Here is the new setting next to the existing related one:
This means your users, for example, will no-longer get addresses coming up in strange countries, if all they need is a single one, ie your site scope is country specific.
Credit to @Richie for proposing and funding this feature, thanks Rich!
(FYI this was stealth released a while back but not promoted)
I really like this feature! Thank you!
One thing I donât understand and no found any documentation for it. The location_user_profile_format
.
I use location iq and it generate the addresses too long (street + city + county + state + country + postalcode). If I use the address format then I can restrict these parameters. Is that right?
So if I only want to display postalcode + city + street then I can do it with this setting?
I try to use the (address: number ) parameters but it doesnât work for me. I think I am missed something It works great but too much unnecessary information in the addresses.
If you have time to add any instruction to set up this I really appreciate! Thank you!
Hi!
Iâm trying this amazing plugin. Seems a very solid piece of work!
The purpose of my use if having trade locations displayed on a trading category.
I have several questions:
-
I checked location user avatar but my avatar isnât displayed on the map. Am I missing something?
-
location map marker category color: is it possible to change the icon shape? When I choose a colored marker, itâs a bit too round for my taste, I like the default shape.
-
location user profile format: How do I find a list of geolocation attributes? I tried setting âaddressâ, but the location field in the user preference was still plain text, with no location selector.
-
Is it possible to show the location under the topic name on the topic list? So the users will see at first glance where the sale is located (itâs quite important since itâs an international forum)
-
If I click on the marker, I have an error:
With this console output:
_application-0839e21515af10c83cf59df7b5c45c2f8db9404f82c4186084346bb0a0a9b425.js:63408
TypeError: Cannot read property 'refresh' of undefined
_ember_jquery-d0ba1603b80181031290e4bd850857d41d63bc4a081d7b4bf16d4e1a4e355a22.js:36991 Error while
processing route: topicBySlugOrId Cannot read property 'refresh' of undefined TypeError: Cannot read
property 'refresh' of undefined
_ember_jquery-
d0ba1603b80181031290e4bd850857d41d63bc4a081d7b4bf16d4e1a4e355a22.js:38545 Uncaught TypeError: Cannot read property 'refresh' of undefined
I donât have custom theme components and as for the plugins, I only use procourse installer, data explorer and discourse locations.
edit:
I managed to do the 4.:
By adding this code to the the template list/topic-liste-item.raw:
{{~#if topic.location}}
<div class="title-location">
{{d-icon 'map-marker-alt'}} {{location-format topic.location opts}}{{location-label-container}}
</div>
{{~/if}}
Same issue here:
html code:
<h3 class="location-and-website">
<div class="user-profile-location"><svg class="fa d-icon d-icon-map-marker-alt svg-icon svg-string" xmlns="http://www.w3.org/2000/svg"><use xlink:href="#map-marker-alt"></use></svg> France</div>
<div class="user-profile-website">
<svg class="fa d-icon d-icon-globe svg-icon svg-string" xmlns="http://www.w3.org/2000/svg"><use xlink:href="#globe"></use></svg>
<a href="http://canapin.dev" rel="noopener " target="_blank">canapin.dev</a>
</div>
<span id="ember29" class="ember-view"> <div id="ember31" class="user-location-and-website-outlet replace-location ember-view"><!----><div class="user-profile-website">
<svg class="fa d-icon d-icon-globe svg-icon svg-string" xmlns="http://www.w3.org/2000/svg"><use xlink:href="#globe"></use></svg>
<span title="http://canapin.dev">canapin.dev</span>
</div>
</div>
</span>
</h3>
I think this issue is because location and website in one class. After I start use users location map feature this fixed.
instead of a âShow Mapâ button at the top of a thread, iâd prefer the map be responsive and already maximized within the constraints of the threadâs content. has something like this been considered?
Sorry @Canapin for slowness in response
This is just for the User Map I believe.
The logic to define the shape is here: discourse-locations/assets/javascripts/discourse/lib/map-utilities.js.es6 at b76f5c42401db9d30be3499408f913493f1cdcb7 ¡ paviliondev/discourse-locations ¡ GitHub.
It might be a nice enhancement to allow this to be customised. PR accepted.
First turn this on:
Then there will be a new setting appearing in User Profile:
I wouldnât worry at this stage about the more complex settings. Users just need to start typing and select the appropriate search result.
Well done for finding a solution
It has been reported before. I will have a look this soon.
Could you mock this up? Iâm not clear on exactly what you mean?
- map size could be responsive (within layout of threadâs content) with optional height limit
- positioned below address text, above threadâs content
- no need âshow mapâ button
Nice idea. If this came with option to default to collapsed view I would welcome it. PR Welcome.