Prevent immediate scan count repolling
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
<div class="inventory-staging-counts" id="inventory-staging-counts"
|
||||
hx-get="{% url 'food:inventory-staging-counts' %}"
|
||||
hx-trigger="load, every 5s" hx-swap="outerHTML"
|
||||
hx-trigger="every 5s" hx-swap="outerHTML"
|
||||
aria-live="polite" aria-atomic="true">
|
||||
<a href="{% url 'food:inventory-review' %}?state=processing"><strong>{{ processing_count }}</strong><span>Processing</span></a>
|
||||
<a href="{% url 'food:inventory-review' %}"><strong>{{ needs_review_count }}</strong><span>Needs Review</span></a>
|
||||
|
||||
+1
-1
@@ -43,7 +43,7 @@ class FoodFoundationTests(TestCase):
|
||||
self.assertEqual(response.status_code, 200)
|
||||
self.assertContains(response, '<strong>1</strong>', html=True)
|
||||
self.assertContains(response, '<strong>1</strong>', html=True)
|
||||
self.assertContains(response, 'hx-trigger="load, every 5s"')
|
||||
self.assertContains(response, 'hx-trigger="every 5s"')
|
||||
|
||||
InventoryScanItem.objects.filter(batch=batch, barcode='111').update(status=InventoryScanItem.Status.COMPLETE)
|
||||
response = self.client.get(url, secure=True)
|
||||
|
||||
Reference in New Issue
Block a user