user-panel #9
|
@ -143,6 +143,12 @@
|
|||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<a class="nav-link fw-bold" href="{# url 'api:tokens' #}">
|
||||
<i class="bi-menu-button-wide icon_sidebar"></i>
|
||||
{% trans 'Tokens' %}
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</nav>
|
||||
|
|
|
@ -43,6 +43,7 @@ INSTALLED_APPS = [
|
|||
"django.contrib.staticfiles",
|
||||
'django_extensions',
|
||||
'django_bootstrap5',
|
||||
'django_tables2',
|
||||
"rest_framework",
|
||||
"login",
|
||||
"user",
|
||||
|
@ -53,6 +54,7 @@ INSTALLED_APPS = [
|
|||
"lot",
|
||||
"documents",
|
||||
"dashboard",
|
||||
"api",
|
||||
]
|
||||
|
||||
|
||||
|
|
|
@ -24,4 +24,5 @@ urlpatterns = [
|
|||
path("evidence/", include("evidence.urls")),
|
||||
path("device/", include("device.urls")),
|
||||
path("lot/", include("lot.urls")),
|
||||
path('api/', include('api.urls')),
|
||||
]
|
||||
|
|
|
@ -56,6 +56,15 @@ class UserTagForm(forms.Form):
|
|||
|
||||
def __init__(self, *args, **kwargs):
|
||||
self.uuid = kwargs.pop('uuid', None)
|
||||
annotation = Annotation.objects.filter(
|
||||
uuid=self.uuid,
|
||||
type=Annotation.Type.SYSTEM,
|
||||
key='CUSTOM_ID',
|
||||
).first()
|
||||
|
||||
if annotation:
|
||||
kwargs['initial'].update({'tag': annotation.value})
|
||||
|
||||
super().__init__(*args, **kwargs)
|
||||
|
||||
def clean(self):
|
||||
|
|
|
@ -3,9 +3,10 @@ Django==5.0.6
|
|||
django-bootstrap5==24.2
|
||||
django-extensions==3.2.3
|
||||
djangorestframework==3.15.1
|
||||
django-tables2==2.6.0
|
||||
python-decouple==3.3
|
||||
py-dmidecode==0.1.3
|
||||
pandas==2.2.2
|
||||
xlrd==2.0.1
|
||||
odfpy==1.4.1
|
||||
|
||||
pytz==2024.2
|
||||
|
|
Loading…
Reference in New Issue