Skip to content

Commit f3749c3

Browse files
author
NarrowsProjects
committed
fix eslint issues
1 parent fcb9c19 commit f3749c3

6 files changed

Lines changed: 9 additions & 13 deletions

File tree

lib/public/components/Filters/common/FilteringModel.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,14 +146,14 @@ export class FilteringModel extends Observable {
146146
*/
147147
async setFilterFromURL() {
148148
const { params: { page = '', filter = {} } } = this._router;
149-
149+
150150
if (!(this._pageIdentifier === page)) {
151151
return;
152152
}
153153

154154
for (const [key, value] of Object.entries(filter)) {
155155
const filterModel = this._filters[key];
156-
156+
157157
if (!filterModel) {
158158
continue;
159159
}

lib/public/components/runEorReasons/runEorReasonSelection.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ import { h } from '/js/src/index.js';
2323
export const eorReasonFilterComponent = (eorReasonFilterModel, eorReasonTypes) => {
2424
const eorReasonsCategories = [...new Set(eorReasonTypes.map(({ category }) => category))];
2525
const { category: currentCategory, title: currentTitle } = eorReasonFilterModel;
26-
26+
2727
return [
2828
h('.flex-row', [
2929
h(

lib/public/views/Logs/Overview/LogsOverviewModel.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ export class LogsOverviewModel extends Observable {
6363
model.appConfiguration$.observe(() => updateDebounceTime());
6464

6565
// Filters
66-
// Set anything else to prevent an additional fetch
6766
this.filteringModel.pageIdentifier = pageIdentifier;
6867
excludeAnonymous && this._filteringModel.get('author').update('!Anonymous');
6968
this._filteringModel.setFilterFromURL();

lib/public/views/Runs/Overview/RunsWithQcModel.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,8 @@ export class RunsWithQcModel extends RunsOverviewModel {
146146
const callback = (observableData) => {
147147
const current = observableData.getCurrent();
148148
current?.apply({
149-
Success: (detectors) =>
150-
detectors.forEach(({ id }) => detectorsQcNotBadFraction.putFilter(`_${id}`, new NumericalComparisonFilterModel({ scale: 0.01, integer: false }))),
149+
Success: (detectors) => detectors.forEach(({ id }) =>
150+
detectorsQcNotBadFraction.putFilter(`_${id}`, new NumericalComparisonFilterModel({ scale: 0.01, integer: false }))),
151151
});
152152

153153
if (current?.isSuccess() && !this._detectorsNotBadFractionRegistered) {

lib/public/views/Runs/RunsModel.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,8 +50,10 @@ export class RunsModel extends Observable {
5050
if (! this._overviewModel.pagination.isInfiniteScrollEnabled) {
5151
this._overviewModel.load();
5252

53-
// This is done outside the constructor because the child classes need to set their filters after their filters are ready setting up.
54-
// Putting it in the constructor would cause duplicate api calls
53+
/**
54+
* This is done outside the constructor because the child classes need to set their filters after their filters are ready setting up.
55+
* Putting it in the constructor would cause duplicate api calls
56+
*/
5557
this._overviewModel.filteringModel.setFilterFromURL();
5658
}
5759
}

test/public/Filters/urlToFilter.test.js

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,14 @@
1111
* or submit itself to any jurisdiction.
1212
*/
1313

14-
const { expect } = require('chai');
1514
const {
1615
defaultBefore,
1716
defaultAfter,
18-
goToPage,
1917
fillInput,
2018
getPopoverSelector,
2119
getPeriodInputsSelectors,
2220
pressElement,
2321
openFilteringPanel,
24-
waitForTableLength,
2522
expectInputValue,
2623
} = require('../defaults.js');
2724

@@ -33,8 +30,6 @@ module.exports = () => {
3330
[page, browser] = await defaultBefore();
3431
});
3532

36-
const getQueryParameters = (page) => Object.fromEntries(new URL(page.url()).searchParams.entries());
37-
3833
it('should apply filters from url in logsOverviewPage', async () => {
3934
const url = 'http://localhost:4000/?page=log-overview&filter[author]=Jane&filter[title]=bogusbogusbogus&filter[content]=particle'+
4035
'&filter[tags][values]=DPG&filter[tags][operation]=and&filter[runNumbers]=1%2C2&filter[environmentIds]=8E4aZTjY'+

0 commit comments

Comments
 (0)