diff options
author | Vidhu Kant Sharma <vidhukant@vidhukant.com> | 2024-07-06 03:24:43 +0530 |
---|---|---|
committer | Vidhu Kant Sharma <vidhukant@vidhukant.com> | 2024-07-06 03:24:43 +0530 |
commit | f192b92ad382d9e8b89ac836bde96f8973ea2844 (patch) | |
tree | 5c364a787c166196f946778773138addab3916a6 /src | |
parent | c3206679f476e7fd001756190024e03f05340ea2 (diff) |
bug fix: when last item is deleted, list doesn't refresh in EditInvoice
Diffstat (limited to 'src')
-rw-r--r-- | src/views/EditInvoice.vue | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/views/EditInvoice.vue b/src/views/EditInvoice.vue index 1ea9664..fe749ea 100644 --- a/src/views/EditInvoice.vue +++ b/src/views/EditInvoice.vue @@ -51,6 +51,8 @@ const refreshItems = async () => { const res = await axios.get(`/invoice/${invoiceId}/item`) if (res.status === 200) { items.value = calculateArr(res.data.data) + } else if (res.status == 204) { + items.value = [] } } catch (err) { toast.error('An unhandled exception occoured. Please check logs') |