mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-04 12:49:10 +00:00
fix: Rebuild cache in background (#17487)
This commit is contained in:
@@ -97,6 +97,10 @@ class ItemVariantsCacheManager:
|
||||
for key in keys:
|
||||
frappe.cache().hdel(key, self.item_code)
|
||||
|
||||
def rebuild_cache(self):
|
||||
self.clear_cache()
|
||||
enqueue_build_cache(self.item_code)
|
||||
|
||||
|
||||
def build_cache(item_code):
|
||||
frappe.cache().hset('item_cache_build_in_progress', item_code, 1)
|
||||
|
||||
Reference in New Issue
Block a user