This commit is contained in:
j3d1 2026-08-17 19:30:48 +02:00
parent accbaf3603
commit 95ddb484eb
3 changed files with 275 additions and 17 deletions

View file

@ -47,7 +47,7 @@
Delete
</button>
<button class="btn btn-secondary"
@click="$router.push({path: '/print', query: {text: itemUrl}})">
@click="$router.push({path: '/print', query: {kind: 'item-url', user, id}})">
<b-icon-printer></b-icon-printer>
Print label
</button>
@ -86,12 +86,6 @@ export default {
},
location() {
return this.storage_locations.find(loc => loc.id === this.item.storage_location) || null
},
itemUrl() {
// The self-contained Item URL (see docs/design-in-progress/items-labels.md) - what
// a printed label actually encodes, since scanning it has to resolve the right
// frontend/backend/item with no other context, not just this browser's history.
return `${window.location.origin}/i/${this.user}/${this.id}`
}
},
methods: {