ignore iteration property when checking for unsaved changes
closes #11063
This commit is contained in:
@@ -66,6 +66,11 @@ describe('unsavedChangesSrv', function() {
|
|||||||
expect(tracker.hasChanges()).to.be(false);
|
expect(tracker.hasChanges()).to.be(false);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
it('Should ignore .iteration changes', () => {
|
||||||
|
dash.iteration = new Date().getTime() + 1;
|
||||||
|
expect(tracker.hasChanges()).to.be(false);
|
||||||
|
});
|
||||||
|
|
||||||
it.skip('Should ignore row collapse change', function() {
|
it.skip('Should ignore row collapse change', function() {
|
||||||
dash.rows[0].collapse = true;
|
dash.rows[0].collapse = true;
|
||||||
expect(tracker.hasChanges()).to.be(false);
|
expect(tracker.hasChanges()).to.be(false);
|
||||||
|
|||||||
@@ -97,6 +97,9 @@ export class Tracker {
|
|||||||
dash.refresh = 0;
|
dash.refresh = 0;
|
||||||
dash.schemaVersion = 0;
|
dash.schemaVersion = 0;
|
||||||
|
|
||||||
|
// ignore iteration property
|
||||||
|
delete dash.iteration;
|
||||||
|
|
||||||
// filter row and panels properties that should be ignored
|
// filter row and panels properties that should be ignored
|
||||||
dash.rows = _.filter(dash.rows, function(row) {
|
dash.rows = _.filter(dash.rows, function(row) {
|
||||||
if (row.repeatRowId) {
|
if (row.repeatRowId) {
|
||||||
|
|||||||
Reference in New Issue
Block a user