Disable unwanted quick ranges

#1

Hey, i’m using grafana 4.6.3 with prometheus 2.1.0
i don’t want time ranges i don’t support to show in the quick ranges.
i want it to be editable.
can you do that please?
Thanks

#2

There is a feature request for this: https://github.com/grafana/grafana/issues/2417 but this is not something that is on the core team’s backlog atm.

As a quick hack, you can always try and remove the ranges manually from the JavaScript - find the minified JavaScript file for your Grafana install (on Ubuntu: /usr/share/grafana/public/app/boot.e4836696.js) and then find the array with the quick ranges and remove the ones you don’t want.

For example, if I want to remove Previous week then I would remove this from the time range array:

{from:"now-1w/w",to:"now-1w/w",display:"Previous week",section:1}
#3

Hi There,

Can this be used to change the default refresh rate for all users? for example I would like a 5 minute auto refresh default for the “last 6 hours” but the auto refresh to be off by default for the “Last 30 days”

Thanks

#4

I did the changes on the rangeutils.ts file, did a restart of the grafana server but nothing is getting reflected on the UI. Did i miss something?