feat: only show unlocked instruments and apprentices

This commit is contained in:
pskfyi 2022-01-10 21:47:26 -08:00 committed by John McCardle
parent 9333b0d48f
commit e65587bbb7
2 changed files with 16 additions and 3 deletions

View File

@ -1,9 +1,19 @@
<template> <template>
<responsive-grid> <responsive-grid>
<apprentice-button <apprentice-button
v-for="(process, index) in $store.state.processes" v-for="(process, index) in unlocked"
:key="`${index}-${process.workerLevel}`" :key="`${index}-${process.workerLevel}`"
:process="process" :process="process"
/> />
</responsive-grid> </responsive-grid>
</template> </template>
<script>
export default {
computed: {
unlocked() {
return this.$store.state.processes.filter((p) => p.unlocked)
},
},
}
</script>

View File

@ -24,11 +24,14 @@
<script> <script>
export default { export default {
computed: { computed: {
unlocked() {
return this.$store.state.processes.filter((p) => p.unlocked)
},
created() { created() {
return this.$store.state.processes.filter((p) => p.created) return this.unlocked.filter((p) => p.created)
}, },
uncreated() { uncreated() {
return this.$store.state.processes.filter((p) => !p.created) return this.unlocked.filter((p) => !p.created)
}, },
}, },
methods: { methods: {