setLatestDownloadedProduct method
Typical use-case: a product page is refreshed through a pull-gesture.
Implementation
void setLatestDownloadedProduct(
Product product, {
bool notify = true,
}) {
_latestDownloadedProducts[product.barcode!] = product;
_timestamps[product.barcode!] = LocalDatabase.nowInMillis();
if (notify) {
localDatabase.notifyListeners();
}
}