Commit 8df0db83 authored by Kushal Pandya's avatar Kushal Pandya

Merge branch '36460-metrics-dashboard-fails-to-load-script-doesn-t-stop' into 'master'

Remove update hook from date filter to prevent js from getting stuck

Closes #36460

See merge request gitlab-org/gitlab!20215
parents 027b5b06 4ebb6c3d
......@@ -55,10 +55,12 @@ export default {
};
},
},
mounted() {
this.verifyTimeRange();
watch: {
selectedTimeWindow() {
this.verifyTimeRange();
},
},
updated() {
mounted() {
this.verifyTimeRange();
},
methods: {
......
---
title: Remove update hook from date filter to prevent js from getting stuck
merge_request: 20215
author:
type: fixed
......@@ -51,6 +51,16 @@ describe('DateTimePicker', () => {
});
});
it('renders dropdown without a selectedTimeWindow set', done => {
createComponent({
selectedTimeWindow: {},
});
dateTimePicker.vm.$nextTick(() => {
expect(dateTimePicker.findAll('input').length).toBe(2);
done();
});
});
it('renders inputs with h/m/s truncated if its all 0s', done => {
createComponent({
selectedTimeWindow: {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment