mirror of
https://github.com/sysadminsmedia/homebox.git
synced 2025-12-21 13:23:14 +01:00
fix: Show item Purchase and Sold sections when date is set (#769)
Consider the case where an item has a purchase or sold date set, but no other details, and display the sections in this case. Fixes #759.
This commit is contained in:
committed by
GitHub
parent
f000e14f07
commit
e955183dc1
@@ -325,7 +325,7 @@
|
||||
if (preferences.value.showEmpty) {
|
||||
return true;
|
||||
}
|
||||
return item.value?.purchaseFrom || item.value?.purchasePrice !== 0;
|
||||
return item.value?.purchaseFrom || item.value?.purchasePrice !== 0 || validDate(item.value?.purchaseTime);
|
||||
});
|
||||
|
||||
const purchaseDetails = computed<Details>(() => {
|
||||
@@ -358,7 +358,7 @@
|
||||
if (preferences.value.showEmpty) {
|
||||
return true;
|
||||
}
|
||||
return item.value?.soldTo || item.value?.soldPrice !== 0;
|
||||
return item.value?.soldTo || item.value?.soldPrice !== 0 || validDate(item.value?.soldTime);
|
||||
});
|
||||
|
||||
const soldDetails = computed<Details>(() => {
|
||||
|
||||
Reference in New Issue
Block a user