Skip to content
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

Only show GeoStyler for SLD Styles #160

Merged
merged 1 commit into from
Oct 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/main/java/org/geoserver/wms/web/data/GeoStyler.java
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,16 @@ private void renderHeaderCss(IHeaderResponse header) throws IOException, Templat
* @throws TemplateException
*/
private void renderHeaderScript(IHeaderResponse header) throws IOException, TemplateException {
String styleFormat = parent.getStyleInfo().getFormat();

if (!styleFormat.equals("sld")) {
LOGGER.info(
"Don't render GeoStyler for format "
+ styleFormat
+ " as it is not supported.");
return;
}

Map<String, Object> context = new HashMap<>();
LayerInfo layerInfo = parent.getLayerInfo();
ResourceInfo resource = layerInfo.getResource();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@
visibility: false
}
},
RuelCard: {
RuleCard: {
amountField: {
visibility: false
},
Expand Down
Loading