Primefaces GMap不用h:形式渲染

时间:2018-05-16 13:33:31

标签: google-maps jsf-2.2 primefaces-gmap

Primefaces当封装在h:form标签

中时,不会呈现GMap
<h:form>

  <p:gmap id="map" center="30.3753, 69.3451" zoom="6" type="map" model="#{branchBean.map}"></p:gmap>

</h:form>

当封闭h:form标签时,会显示地图。

使用primefaces版本是6.1

1 个答案:

答案 0 :(得分:0)

我使用id而不是类名引用gss的css,将其从#map更改为.mapStyle并将其设置在gmap的styleClass属性中。现在它很好用。