componentsDjangoType 2.1.0__tar.gz → 2.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. {componentsdjangotype-2.1.0/componentsDjangoType.egg-info → componentsdjangotype-2.1.2}/PKG-INFO +1 -1
  2. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2/componentsDjangoType.egg-info}/PKG-INFO +1 -1
  3. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/authenticator_configurator.py +25 -2
  4. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/views/layouts/index.html +7 -4
  5. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/views/login.html +4 -0
  6. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/views/signup.html +8 -1
  7. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/setup.py +1 -1
  8. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/LICENSE +0 -0
  9. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/MANIFEST.in +0 -0
  10. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/README.md +0 -0
  11. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/__init__.py +0 -0
  12. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/__pycache__/__init__.cpython-312.pyc +0 -0
  13. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/__init__.py +0 -0
  14. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/__pycache__/__init__.cpython-312.pyc +0 -0
  15. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/commands/__init__.py +0 -0
  16. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/commands/__pycache__/__init__.cpython-312.pyc +0 -0
  17. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/commands/__pycache__/createApp.cpython-312.pyc +0 -0
  18. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/commands/createApp.py +0 -0
  19. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType/management/commands/createcomponent.py +0 -0
  20. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType.egg-info/SOURCES.txt +0 -0
  21. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType.egg-info/dependency_links.txt +0 -0
  22. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType.egg-info/requires.txt +0 -0
  23. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/componentsDjangoType.egg-info/top_level.txt +0 -0
  24. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/__init__.py +0 -0
  25. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/authentication/__init__.py +0 -0
  26. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/authentication/auth.py +0 -0
  27. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/authentication/forms.py +0 -0
  28. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/copy_source.py +0 -0
  29. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/css/authentication.css +0 -0
  30. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/js/alertErrors.js +0 -0
  31. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/views/home.html +0 -0
  32. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/services/utils/views/logged.html +0 -0
  33. {componentsdjangotype-2.1.0 → componentsdjangotype-2.1.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: componentsDjangoType
3
- Version: 2.1.0
3
+ Version: 2.1.2
4
4
  Summary: Comandos para crear archivos html, css y js
5
5
  Home-page: https://github.com/jose-CR/componentsDjangoType
6
6
  Author: Alejandro
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: componentsDjangoType
3
- Version: 2.1.0
3
+ Version: 2.1.2
4
4
  Summary: Comandos para crear archivos html, css y js
5
5
  Home-page: https://github.com/jose-CR/componentsDjangoType
6
6
  Author: Alejandro
@@ -1,6 +1,6 @@
1
1
  import os
2
2
  from django.core.management import call_command
3
- from services.authentication import auth
3
+ from services.authentication import auth, forms
4
4
  from services.copy_source import copy_static_file
5
5
 
6
6
  class DjangoProjectManager:
@@ -134,27 +134,41 @@ urlpatterns = [
134
134
 
135
135
  # Ruta para el nuevo archivo a crear
136
136
  authentication_path = os.path.join(authentication_dir, 'auth.py')
137
+ form_path = os.path.join(authentication_dir, 'form.py')
137
138
 
138
139
  # Usar el atributo __file__ del módulo 'auth' para obtener la ruta del archivo fuente
139
140
  auth_source_path = os.path.abspath(auth.__file__)
141
+ form_source_path = os.path.abspath(forms.__file__)
140
142
 
141
143
  if not os.path.exists(auth_source_path):
142
144
  stdout.write(f"El archivo fuente '{auth_source_path}' no existe. Verifica la instalación del paquete.")
143
145
  return
146
+
147
+ if not os.path.exists(form_source_path):
148
+ stdout.write(f"El archivo fuente '{form_source_path}' no existe. Verifica la instalación del paquete.")
149
+ return
144
150
 
145
151
  if not os.path.exists(authentication_path):
146
152
  stdout.write(f"Creando el archivo '{authentication_path}'...")
153
+ stdout.write(f"Creando el archivo '{form_path}'...")
147
154
 
148
155
  # Leer el contenido de 'auth.py' del paquete
149
156
  try:
150
157
  with open(auth_source_path, 'r') as source_file:
151
158
  auth_code = source_file.read()
159
+
160
+ with open(form_source_path, 'r') as source_file:
161
+ form_code = source_file.read()
152
162
 
153
163
  # Escribir el contenido en el nuevo archivo 'authentication.py'
154
164
  with open(authentication_path, 'w') as dest_file:
155
165
  dest_file.write(auth_code)
166
+
167
+ with open(form_path, 'w') as dest_file:
168
+ dest_file.write(form_code)
156
169
 
157
170
  stdout.write(f"El archivo '{authentication_path}' fue creado y el código fue copiado.")
171
+ stdout.write(f"El archivo '{form_path}' fue creado y el código fue copiado.")
158
172
  except Exception as e:
159
173
  stdout.write(f"Error al copiar el archivo: {e}")
160
174
  else:
@@ -226,24 +240,33 @@ urlpatterns = [
226
240
  layouts_dir = os.path.join(templates_dir, 'layouts')
227
241
  js_dir = os.path.join(static_dir, 'js')
228
242
  css_dir = os.path.join(static_dir, 'css')
243
+ user_dir_css = os.path.join(css_dir, 'user')
244
+ user_dir_html = os.path.join(templates_dir, 'user')
245
+ user_dir_components = os.path.join(templates_dir, 'components')
229
246
 
230
247
  # Crear las carpetas principales y subcarpetas
231
248
  os.makedirs(templates_dir, exist_ok=True)
232
249
  os.makedirs(layouts_dir, exist_ok=True)
233
250
  os.makedirs(static_dir, exist_ok=True)
234
251
  os.makedirs(js_dir, exist_ok=True)
235
- os.makedirs(css_dir, exist_ok=True)
252
+ os.makedirs(css_dir, exist_ok=True)
253
+ os.makedirs(user_dir_css, exist_ok=True)
254
+ os.makedirs(user_dir_html, exist_ok=True)
255
+ os.makedirs(user_dir_components, exist_ok=True)
236
256
 
237
257
  stdout.write("Estructura de carpetas creada.\n")
238
258
 
239
259
  files_to_copy = [
240
260
  ("services.utils.js", "alertErrors.js", os.path.join(js_dir, "alertErrors.js")),
241
261
  ("services.utils.css", "authentication.css", os.path.join(css_dir, "authentication.css")),
262
+ ("services.utils.css.user", "aside.css", os.path.join(user_dir_css, "aside.css")),
242
263
  ("services.utils.views.layouts", "index.html", os.path.join(layouts_dir, "index.html")),
243
264
  ("services.utils.views", "home.html", os.path.join(templates_dir, "home.html")),
244
265
  ("services.utils.views", "signup.html", os.path.join(templates_dir, "signup.html")),
245
266
  ("services.utils.views", "login.html", os.path.join(templates_dir, "login.html")),
246
267
  ("services.utils.views", "logged.html", os.path.join(templates_dir, "logged.html")),
268
+ ("services.utils.views.user", "user.html", os.path.join(user_dir_html, "user.html")),
269
+ ("services.utils.views.components", "aside.html", os.path.join(user_dir_components, "aside.html")),
247
270
  ]
248
271
 
249
272
  for package, resource_name, destination_path in files_to_copy:
@@ -5,7 +5,10 @@
5
5
  <meta charset="UTF-8">
6
6
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
7
7
  <link rel="stylesheet" href="{% static 'css/authentication.css' %}">
8
- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.6.0/css/all.min.css">
8
+ {% block css %}
9
+ {% endblock %}
10
+ <!-- boxicons -->
11
+ <script src="https://unpkg.com/boxicons@2.1.4/dist/boxicons.js"></script>
9
12
  <title>django components</title>
10
13
  </head>
11
14
  <body class="bg-gray-100 text-gray-800">
@@ -13,7 +16,7 @@
13
16
  <nav class="navbar">
14
17
  <div class="logo">
15
18
  <a href="{% url 'home' %}">
16
- <i class="fa-solid fa-house"></i>
19
+ <box-icon name='home' flip='horizontal' size="md" color="#ffffff"></box-icon>
17
20
  </a>
18
21
  </div>
19
22
  <div class="menu-toggle">
@@ -34,7 +37,7 @@
34
37
  {% endblock %}
35
38
  </div>
36
39
 
37
-
38
- <script src="{% static 'js/alertErrors.js'%}"></script>
40
+ {% block script %}
41
+ {% endblock %}
39
42
  </body>
40
43
  </html>
@@ -1,4 +1,5 @@
1
1
  {% extends "layouts/index.html" %}
2
+ {% load static %}
2
3
  {% block layout %}
3
4
  {% if error %}
4
5
  <div class="alert" id="alert">
@@ -30,4 +31,7 @@
30
31
  </form>
31
32
  </div>
32
33
  </div>
34
+ {% endblock %}
35
+ {% block script %}
36
+ <script src="{% static 'js/alertErrors.js'%}"></script>
33
37
  {% endblock %}
@@ -1,4 +1,5 @@
1
1
  {% extends "layouts/index.html" %}
2
+ {% load static %}
2
3
  {% block layout %}
3
4
  {% if error %}
4
5
  <div class="alert" id="alert">
@@ -16,10 +17,13 @@
16
17
 
17
18
  <div class="form-wrapper">
18
19
  <div class="form-container">
19
- <form action="" method="post" class="form-control">
20
+ <form action="" method="post" class="form-control" enctype="multipart/form-data">
20
21
  {% csrf_token %}
21
22
  <h1>sing up</h1>
22
23
 
24
+ <label for="img_url">Imagen de Perfil:</label>
25
+ {{ form.image }}
26
+
23
27
  <label for="username">Usuario:</label>
24
28
  {{ form.username }}
25
29
 
@@ -33,4 +37,7 @@
33
37
  </form>
34
38
  </div>
35
39
  </div>
40
+ {% endblock %}
41
+ {% block script %}
42
+ <script src="{% static 'js/alertErrors.js'%}"></script>
36
43
  {% endblock %}
@@ -2,7 +2,7 @@ from setuptools import setup, find_packages
2
2
 
3
3
  setup(
4
4
  name='componentsDjangoType',
5
- version='2.1.0',
5
+ version='2.1.2',
6
6
  packages=find_packages(),
7
7
  include_package_data=True,
8
8
  package_data={