This commit is contained in:
j3d1 2026-07-23 04:41:04 +02:00
parent 7c91661be2
commit 796fef81be
37 changed files with 3404 additions and 108 deletions

View file

@ -109,16 +109,21 @@ export default {
},
computed: {
...mapGetters(["inventory_items", "loaded_items"]),
...mapState(["user"]),
...mapState(["user", "storage_locations"]),
},
methods: {
...mapActions(["fetchInventoryItems", "deleteInventoryItem"]),
...mapActions(["fetchInventoryItems", "deleteInventoryItem", "fetchStorageLocations"]),
only_images(files) {
return files.filter(file => file.mime_type.startsWith("image/"));
},
locationPath(item) {
const loc = this.storage_locations.find(loc => loc.id === item.storage_location)
return loc ? loc.path : null
},
},
async mounted() {
await this.fetchInventoryItems()
await this.fetchStorageLocations()
}
}
</script>