Use indexKey if specified
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good
This commit is contained in:
parent
394bbab320
commit
c44c771feb
@ -49,7 +49,7 @@ export class ItemLayersComponent extends LayerGroupComponent implements OnChange
|
|||||||
}
|
}
|
||||||
|
|
||||||
getColorFromGradient(item:IItem,layer: ILayer, feature): style.Style {
|
getColorFromGradient(item:IItem,layer: ILayer, feature): style.Style {
|
||||||
var value = feature.get(layer.name);
|
var value = layer.indexKey ? feature.get(layer.indexKey): feature.get(layer.name);
|
||||||
var key = item.code + "_" + value;
|
var key = item.code + "_" + value;
|
||||||
if(!this.styleCache[key]) {
|
if(!this.styleCache[key]) {
|
||||||
var gradient: IGradientstop[] = layer.renderer.colorMap.gradient;
|
var gradient: IGradientstop[] = layer.renderer.colorMap.gradient;
|
||||||
|
Loading…
Reference in New Issue
Block a user