-
Notifications
You must be signed in to change notification settings - Fork 102
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
collapsed b:panel p:gmap #720
Comments
Sounds like the same bug as #205. Can you give us a reproducer? |
ok i pushed to my test project https://github.com/chongma/test. choose test-> gmap |
I have some difficulties to get the project up and running. Which application server do you use? |
I used TomEE 7.0.2 but added the same dependencies as there were on the BootsFacesWeb project to try to make it compatible |
OK, I've got a TomEE 7.0.2 on my PC, so I just have to re-import it into Eclipse. I don't understand why your project doesn't work with my Wildfly. Probably because I used the wrong URL, but still, it shouldn't be that difficult to find out the URL, should it? |
I had never heard of wildfly before now. Which URL was wrong? Did the server start ok? Maybe it is the faces version or web deployment descriptor because they are the only bits i added |
Ah well i have heard of JBoss of course. Yes that is exactly how the test looks on my system too. Let me know if you need me to do anything else |
As it turns out, this doesn't work with the PrimeFaces My best effort so far is this: <b:panel rendered="#{gmapBean.mapModel ne null}" title="Map"
collapsed="true"
onexpanded="PrimeFaces.widgets.hiddenMap._render();">
<p:gmap center="#{gmapBean.latLng.lat},#{gmapBean.latLng.lng}"
zoom="15" type="HYBRID" style="width:250px;height:250px;"
model="#{gmapBean.mapModel}" widgetVar="hiddenMap"/>
</b:panel> The Gmap widget is given a Problem: the map doesn't show. On the plus side, there's the error message indicating the I don't have the API key, so it seems to be the right direction. In theory, there's another, better approach: wrap the Gmap widget in a div like so: <div class="ui-hidden-container" id="gmapwrapperId">
<p:gmap ... />
</div> The problem with the second approach is that it does even less. The widget is initialized on the PrimeFaces side, but there's not even an error message. |
@tandraschko: does this pique your curiosity? It seems the deferred initialization of <p:panel rendered="#{gmapBean.mapModel ne null}" title="Map" header="Map"
collapsed="true" toggleable="true">
<p:gmap center="#{gmapBean.latLng.lat},#{gmapBean.latLng.lng}"
zoom="15" type="HYBRID" style="width:100%;height:250px;"
model="#{gmapBean.mapModel}" />
</p:panel> Also see http://stackoverflow.com/questions/19067780/primefaces-gmap-not-rendered-when-style-display-none. |
Yup, should actually work. Not sure if the problem is the panel or the gmap ;) |
I write for the same error a solution by b:tabView #205 |
i retest it, the bug was fixed with version 1.4.2 |
if a b:panel is collapsed on page load then a p:gmap inside does not get rendered.
The text was updated successfully, but these errors were encountered: