Files
dozzle-monitoring/assets/pages/Container.vue
Amir Raminfar b4e0afdb2c Adds authentication as a feature with simple username and password configuration (#1127)
* Starting work for auth

* Adds flags

* Does redirect

* Refactors code

* Adds vue templates

* Completes logic

* Cleans up some of the error messages

* Refactors

* Updates readme

* Updates titles

* Adds logout

* Cleans up imports
2021-04-08 08:29:58 -07:00

48 lines
936 B
Vue

<template>
<div>
<search></search>
<log-container :id="id" show-title :scrollable="activeContainers.length > 0"> </log-container>
</div>
</template>
<script>
import { mapGetters } from "vuex";
import Search from "../components/Search";
import LogContainer from "../components/LogContainer";
export default {
props: ["id"],
name: "Container",
components: {
LogContainer,
Search,
},
data() {
return {
title: "loading",
};
},
metaInfo() {
return {
title: this.title,
};
},
mounted() {
if (this.allContainersById[this.id]) {
this.title = this.allContainersById[this.id].name;
}
},
computed: {
...mapGetters(["allContainersById", "activeContainers"]),
},
watch: {
id() {
this.title = this.allContainersById[this.id].name;
},
allContainersById() {
this.title = this.allContainersById[this.id].name;
},
},
};
</script>