Browse Source

updated page authorization

1Mike21 1 year ago
parent
commit
77e489d218
4 changed files with 8 additions and 7 deletions
  1. 5 2
      SharixAdmin/templates/SharixAdmin/auth.html
  2. 1 1
      bin/webuser.sh
  3. 2 4
      core/urls.py
  4. 0 0
      install_unix.sh

+ 5 - 2
SharixAdmin/templates/SharixAdmin/auth.html

@@ -6,7 +6,7 @@
 <div class="text-center" style="margin-top: 150px;">
     <div class="form-signin" style="width: 100%; max-width:330px; margin: auto; display:block;">
         <form class="m-2 p-2" method="post">
-            <img class="mb-4" src="{% static 'SharixAdmin/img/logo.png' %}" alt="" width="72" >
+            <img class="mb-4" style="height: 100px;" src="{% static 'SharixAdmin/img/logo.png' %}" alt="" >
             <h1 class="h3 mb-3 fw-normal">{% trans 'Log in' %}</h1>
             {% csrf_token %}
             
@@ -26,7 +26,10 @@
                     {% trans 'Please, enter the correct phone number and password.' %}
                 </div>
             {% endif %}
-            <button class="w-100 btn btn-primary btn-lg" type="submit">{% trans 'Login' %}</button>
+            <div>
+              <a class="w-100 btn btn-primary btn-lg mb-3" href="{% url 'webservice_running:registration' %}">Регистрация</a>
+              <button class=" w-100 btn btn-primary btn-lg" type="submit">{% trans 'Login' %}</button>
+            </div>
             <p class="mt-5 mb-3 text-muted">© 2022</p>
           </form>
     </div>

+ 1 - 1
bin/webuser.sh

@@ -1,5 +1,5 @@
 #!/bin/bash
 #cd /path/to/project
-cd /root/sharix-open-webapp-base
+cd /root/sharix-open-webapp-base/
 #exec /path/to/project/env/bin/gunicorn core.wsgi:application -c core/conf_gunicorn.py
 exec /root/sharix-open-webapp-base/env/bin/gunicorn core.wsgi:application -c core/conf_gunicorn.py

+ 2 - 4
core/urls.py

@@ -22,10 +22,8 @@ urlpatterns = (
     )
 
     
-
-    + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
-    + static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
   )
 
 if settings.DEBUG:
-    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
+    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
+    urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)

+ 0 - 0
install_unix.sh