From 9b98682005d9d613a92817ce6e16d46a1f782fdb Mon Sep 17 00:00:00 2001 From: Stanislav Romanov Date: Sat, 4 Jun 2022 10:56:13 +0300 Subject: [PATCH] Clear unused code --- app/routes/admin/indexes/item/settings.js | 33 ----------------------- 1 file changed, 33 deletions(-) diff --git a/app/routes/admin/indexes/item/settings.js b/app/routes/admin/indexes/item/settings.js index 7d598f2..cf8a5d6 100644 --- a/app/routes/admin/indexes/item/settings.js +++ b/app/routes/admin/indexes/item/settings.js @@ -1,39 +1,6 @@ import Route from '@ember/routing/route'; import { hash } from 'rsvp'; -function attributeValue(key) { - return function () { - return { - get() { - return this.settings[key].includes(this.name); - }, - - set(value) { - if (value) { - this.settings[key].addObject(this.name); - } else { - this.settings[key].removeObject(this.name); - } - }, - }; - }; -} - -class IndexAttribute { - name; - settings; - - @attributeValue('displayedAttributes') displayed; - @attributeValue('filterableAttributes') filterable; - @attributeValue('searchableAttributes') searchable; - @attributeValue('sortableAttributes') sortable; - - constructor(name, settings) { - this.name = name; - this.settings = settings; - } -} - export default class AdminIndexesItemSettingsRoute extends Route { async model() { const index = this.modelFor('admin.indexes.item');