Hi,
I have two dashboard :
- "Normal" dashboard : With the basic TimePicker.
- Another dashboard : where I want to remove 'Other'( All time) for the timepicker
How can i remove this choice in the Time Picker ?
PS : I can't (don't want to) touch the splunk files
Thanks
Hi @henriq_c
Try with following CSS change (verified in splunk 7.2.4)
<form>
<label>timepicker</label>
<fieldset submitButton="false">
<input type="time" token="field1" id="test">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row depends="$hide$">
<panel>
<html>
<style>
div[data-test="other-column"]
{
display:none !important;
}
</style>
</html>
</panel>
</row>
</form>
[Updated] Splunk 6.x
<form>
<label>timepicker</label>
<fieldset submitButton="false">
<input type="time" token="field1" id="test">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row depends="$hide$">
<panel>
<html>
<style>
div[data-view="views/shared/timerangepicker/dialog/Presets"] ul:last-child {
display:none;
}
</style>
</html>
</panel>
</row>
</form>
Hi @henriq_c
Try with following CSS change (verified in splunk 7.2.4)
<form>
<label>timepicker</label>
<fieldset submitButton="false">
<input type="time" token="field1" id="test">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row depends="$hide$">
<panel>
<html>
<style>
div[data-test="other-column"]
{
display:none !important;
}
</style>
</html>
</panel>
</row>
</form>
[Updated] Splunk 6.x
<form>
<label>timepicker</label>
<fieldset submitButton="false">
<input type="time" token="field1" id="test">
<label></label>
<default>
<earliest>-24h@h</earliest>
<latest>now</latest>
</default>
</input>
</fieldset>
<row depends="$hide$">
<panel>
<html>
<style>
div[data-view="views/shared/timerangepicker/dialog/Presets"] ul:last-child {
display:none;
}
</style>
</html>
</panel>
</row>
</form>
It doesnt work. It does not remove the 'Other' category from the time picker 😕
please let me know your splunk version.
@henriq_c i had updated code for Splunk 6.x please try and let me know.
v7.02 (it works with the 6.x code)