I have a repeating panel that inherits from MetricsPanelCtrl…
onRefersh() it makes an ajax call and sets values on the panel’s template using jquery selectors…
$.getJSON(uri, result => {
this.setData(result);
});
Problem is when the panel is repeated only the first panel’s dom elements are set, even through I can see an ajax call was made for each panel. What seems to be happening is every ajax response set’s the first panel’s dom elements…
I suspect the answer may have something to do with scopedVars? I figured out I need templateSrv to get template vars to make my unique ajax request per panel, but thats only for text it seems, not dom elements…