[UPDT] BIOMETRIC: Added fetch logs to the action of biometric card action

This commit is contained in:
Horilla
2025-11-11 15:33:26 +05:30
parent 6224768f2d
commit 2fcd768886
2 changed files with 17 additions and 0 deletions

View File

@@ -85,6 +85,16 @@ class BiometricCardView(HorillaCardView):
data-target="#genericModal"
""",
},
{
"action": "Fetch Logs",
"attrs": """
hx-get="{get_fetch_url}"
class="oh-dropdown__link"
data-toggle="oh-modal-toggle"
data-target="#BiometricDeviceTestModal"
hx-target="#BiometricDeviceTestFormTarget"
""",
},
{
"action": "archive_status",
"attrs": """

View File

@@ -225,6 +225,13 @@ class BiometricDevices(HorillaModel):
url = reverse_lazy("biometric-device-archive", kwargs={"device_id": self.pk})
return url
def get_fetch_url(self):
"""
This method to get Fetch Logs url
"""
url = reverse_lazy("biometric-device-fetch-logs", kwargs={"device_id": self.pk})
return url
def get_delete_url(self):
"""
This method to get delete url