Signed-off-by: Bill Erickson <berickxx@gmail.com>
this.noSuchItem = true;
} else {
this.itemBarcode = null;
- this.selectInput();
- return this.getItemById(res.id);
+
+ if (this.tab == 'list') {
+ this.selectInput();
+ return this.getItemById(res.id);
+ } else {
+ this.router.navigate([`/staff/cat/item/${res.id}/${this.tab}`]);
+ }
}
});
}
}
};
- return this.pcrud.retrieve('acp', this.itemId, flesh)
+ return this.pcrud.retrieve('acp', id, flesh)
.toPromise().then(item => {
this.item = item;
this.itemId = item.id();