|
|
|
@ -56,6 +56,15 @@
@@ -56,6 +56,15 @@
|
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
<span v-if="colorToFilter !== '' && !notesExistInFilteredColor"> |
|
|
|
|
Keine Notizen mit gewählter Farbe vorhanden<br> |
|
|
|
|
<a href="javascript:" |
|
|
|
|
class="color-change-button disable-filter-button" |
|
|
|
|
:style="'background-color: '+colorToFilter" |
|
|
|
|
v-on:click="colorToFilter = ''"> |
|
|
|
|
Filter ausschalten |
|
|
|
|
</a> |
|
|
|
|
</span> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
|
</div> |
|
|
|
@ -91,6 +100,15 @@ export default {
@@ -91,6 +100,15 @@ export default {
|
|
|
|
|
note.color = color; |
|
|
|
|
this.$store.commit('saveNotes'); |
|
|
|
|
} |
|
|
|
|
}, |
|
|
|
|
computed: { |
|
|
|
|
notesExistInFilteredColor() { |
|
|
|
|
let component = this; |
|
|
|
|
|
|
|
|
|
return this.$store.state.notes.filter((note) => { |
|
|
|
|
return note.color === component.colorToFilter; |
|
|
|
|
}).length; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
</script> |
|
|
|
|