summaryrefslogtreecommitdiffstats
path: root/src/components/settings/Docker.vue
blob: c411c307f7ca9098a250a53ac03d455740f3e303 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
<template>
    <div>
        <div class="dockerHost-list my-4">
            <p v-if="$root.dockerHostList.length === 0">
                {{ $t("Not available, please setup.") }}
            </p>

            <ul class="list-group mb-3" style="border-radius: 1rem;">
                <li v-for="(dockerHost, index) in $root.dockerHostList" :key="index" class="list-group-item">
                    {{ dockerHost.name }}<br>
                    <a href="#" @click="$refs.dockerHostDialog.show(dockerHost.id)">{{ $t("Edit") }}</a>
                </li>
            </ul>

            <button class="btn btn-primary me-2" type="button" @click="$refs.dockerHostDialog.show()">
                {{ $t("Setup Docker Host") }}
            </button>
        </div>

        <DockerHostDialog ref="dockerHostDialog" />
    </div>
</template>

<script>
import DockerHostDialog from "../../components/DockerHostDialog.vue";

export default {
    components: {
        DockerHostDialog,
    },

    data() {
        return {};
    },

    computed: {
        settings() {
            return this.$parent.$parent.$parent.settings;
        },
        saveSettings() {
            return this.$parent.$parent.$parent.saveSettings;
        },
        settingsLoaded() {
            return this.$parent.$parent.$parent.settingsLoaded;
        },
    }
};
</script>