mirror of
https://github.com/home-assistant/frontend.git
synced 2025-07-24 09:46:36 +00:00
Add disabled by column to entity datatable (#9799)
This commit is contained in:
parent
b0fd93e0c3
commit
72773f3bc8
@ -164,7 +164,7 @@ export class HaConfigEntities extends SubscribeMixin(LitElement) {
|
|||||||
);
|
);
|
||||||
|
|
||||||
private _columns = memoize(
|
private _columns = memoize(
|
||||||
(narrow, _language): DataTableColumnContainer => ({
|
(narrow, _language, showDisabled): DataTableColumnContainer => ({
|
||||||
icon: {
|
icon: {
|
||||||
title: "",
|
title: "",
|
||||||
type: "icon",
|
type: "icon",
|
||||||
@ -221,6 +221,19 @@ export class HaConfigEntities extends SubscribeMixin(LitElement) {
|
|||||||
filterable: true,
|
filterable: true,
|
||||||
width: "15%",
|
width: "15%",
|
||||||
},
|
},
|
||||||
|
disabled_by: {
|
||||||
|
title: this.hass.localize(
|
||||||
|
"ui.panel.config.entities.picker.headers.disabled_by"
|
||||||
|
),
|
||||||
|
sortable: true,
|
||||||
|
hidden: narrow || !showDisabled,
|
||||||
|
filterable: true,
|
||||||
|
width: "15%",
|
||||||
|
template: (disabled_by) =>
|
||||||
|
this.hass.localize(
|
||||||
|
`ui.panel.config.devices.disabled_by.${disabled_by}`
|
||||||
|
) || disabled_by,
|
||||||
|
},
|
||||||
status: {
|
status: {
|
||||||
title: this.hass.localize(
|
title: this.hass.localize(
|
||||||
"ui.panel.config.entities.picker.headers.status"
|
"ui.panel.config.entities.picker.headers.status"
|
||||||
@ -466,7 +479,11 @@ export class HaConfigEntities extends SubscribeMixin(LitElement) {
|
|||||||
: "/config"}
|
: "/config"}
|
||||||
.route=${this.route}
|
.route=${this.route}
|
||||||
.tabs=${configSections.integrations}
|
.tabs=${configSections.integrations}
|
||||||
.columns=${this._columns(this.narrow, this.hass.language)}
|
.columns=${this._columns(
|
||||||
|
this.narrow,
|
||||||
|
this.hass.language,
|
||||||
|
this._showDisabled
|
||||||
|
)}
|
||||||
.data=${filteredEntities}
|
.data=${filteredEntities}
|
||||||
.activeFilters=${activeFilters}
|
.activeFilters=${activeFilters}
|
||||||
.numHidden=${this._numHiddenEntities}
|
.numHidden=${this._numHiddenEntities}
|
||||||
|
@ -2148,6 +2148,7 @@
|
|||||||
"entity_id": "Entity ID",
|
"entity_id": "Entity ID",
|
||||||
"integration": "Integration",
|
"integration": "Integration",
|
||||||
"area": "Area",
|
"area": "Area",
|
||||||
|
"disabled_by": "Disabled by",
|
||||||
"status": "Status"
|
"status": "Status"
|
||||||
},
|
},
|
||||||
"selected": "{number} selected",
|
"selected": "{number} selected",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user