chartManD commited on
Commit
10e7751
·
1 Parent(s): 89e83ae

Creacion del panel configuracion tags

Browse files
tecnicas/templates/tecnicas/{configuracion-panel.html → configuracion-panel-basic.html} RENAMED
@@ -8,12 +8,8 @@
8
  - Preguntar si desea darle un nombre a la sesion
9
  - Numero produtos
10
  - Numero jueces
11
- - Numero repeticiones, debe ser mayor a 1, no validar si es menos
12
- - Agregar palabras o Elejir vocabulario
13
- - Instrucciones
14
  - Tipo de escala, seran dos, de rango o estructurada
15
- - Orden de presentacion
16
- - Presentar un orden basico segun el numero de catadores y los productos, esta se le muestra el presentador
17
  -->
18
 
19
  {% block content %}
@@ -78,87 +74,6 @@
78
  {{ form_sesion.tamano_escala.errors }}
79
  </article>
80
  {% endif %}
81
- <!-- <article class="bg-gray-500 p-4 flex flex-col gap-2">
82
- <div class="flex flex-row justify-center items-center gap-5 text-lg">
83
- <p class="font-medium p-1 px-3 bg-gray-200">Segmento 1</p>
84
- <label for="etiquta_1">
85
- <select name="etiquta_1" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_1"
86
- required>
87
- <option value="1">no se percibe</option>
88
- <option value="2">poca percepcion</option>
89
- <option value="3">se percibe</option>
90
- <option value="4">percepcion intensa</option>
91
- <option value="5">percepcion muy intensa</option>
92
- </select>
93
- </label>
94
- <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
95
- </div>
96
- <div class="flex flex-row justify-center items-center gap-5 text-lg">
97
- <p class="font-medium p-1 px-3 bg-gray-200">Segmento 2</p>
98
- <label for="etiquta_2">
99
- <select name="etiquta_2" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_2"
100
- required>
101
- <option value="1">no se percibe</option>
102
- <option value="2" selected>poca percepcion</option>
103
- <option value="3">se percibe</option>
104
- <option value="4">percepcion intensa</option>
105
- <option value="5">percepcion muy intensa</option>
106
- </select>
107
- </label>
108
- <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
109
- </div>
110
- <div class="flex flex-row justify-center items-center gap-5 text-lg">
111
- <p class="font-medium p-1 px-3 bg-gray-200">Segmento 3</p>
112
- <label for="etiquta_3">
113
- <select name="etiquta_3" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_3"
114
- required>
115
- <option value="1">no se percibe</option>
116
- <option value="2">poca percepcion</option>
117
- <option value="3" selected>se percibe</option>
118
- <option value="4">percepcion intensa</option>
119
- <option value="5">percepcion muy intensa</option>
120
- </select>
121
- </label>
122
- <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
123
- </div>
124
- <div class="flex flex-row justify-center items-center gap-5 text-lg">
125
- <p class="font-medium p-1 px-3 bg-gray-200">Segmento 4</p>
126
- <label for="etiquta_4">
127
- <select name="etiquta_4" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_4"
128
- required>
129
- <option value="1">no se percibe</option>
130
- <option value="2">poca percepcion</option>
131
- <option value="3">se percibe</option>
132
- <option value="4" selected>percepcion intensa</option>
133
- <option value="5">percepcion muy intensa</option>
134
- </select>
135
- </label>
136
- <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
137
- </div>
138
- <div class="flex flex-row justify-center items-center gap-5 text-lg">
139
- <p class="font-medium p-1 px-3 bg-gray-200">Segmento 5</p>
140
- <label for="etiquta_5">
141
- <select name="etiquta_5" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_5"
142
- required>
143
- <option value="1">no se percibe</option>
144
- <option value="2">poca percepcion</option>
145
- <option value="3">se percibe</option>
146
- <option value="4">percepcion intensa</option>
147
- <option value="5" selected>percepcion muy intensa</option>
148
- </select>
149
- </label>
150
- <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
151
- </div>
152
- </article>
153
- <article class="absolute bg-gray-800/70 p-5 w-full h-full justify-center items-center hidden">
154
- <section class="p-2 bg-gray-400 w-fit">
155
- <form action="">
156
- {% csrf_token %}
157
- <label for="nueva_etiqueta">Nueva etiqueta:<input id="nueva_etiqueta" type="text"
158
- required></label>
159
- </form>
160
- </section>
161
- </article> -->
162
  </section>
163
  </article>
164
  <hr>
 
8
  - Preguntar si desea darle un nombre a la sesion
9
  - Numero produtos
10
  - Numero jueces
11
+ - Numero repeticiones, debe ser mayor a 1, no validar si es menos [-------------REALIZAR-------------]
 
 
12
  - Tipo de escala, seran dos, de rango o estructurada
 
 
13
  -->
14
 
15
  {% block content %}
 
74
  {{ form_sesion.tamano_escala.errors }}
75
  </article>
76
  {% endif %}
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
77
  </section>
78
  </article>
79
  <hr>
tecnicas/templates/tecnicas/configuracion-panel-tags.html ADDED
@@ -0,0 +1,103 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {% extends 'tecnicas/base.html' %}
2
+
3
+ {% block title %}Panel Configuracion{% endblock %}
4
+
5
+ <!--
6
+ ||||Debe tener los siguietens campos para:
7
+ -- Convenvionales tipo escalas
8
+ - Agregar palabras o Elejir vocabulario
9
+ - Instrucciones
10
+ - Orden de presentacion
11
+ - Presentar un orden basico segun el numero de catadores y los productos, esta se le muestra el presentador
12
+ -->
13
+
14
+ {% block content %}
15
+ <article class="w-full flex flex-col justify-center items-center bg-gray-600 my-10">
16
+ <article class="flex flex-col gap-4 bg-gray-400 md:p-10 p-5 rounded-2xl lg:w-4xl w-full">
17
+ <h1 class="text-center font-bold text-4xl">Panel de configuración</h1>
18
+ <hr>
19
+ <form method="post" action="" class="[&>article]:not-last:mb-4 [&>article]:not-first:pt-4 [&>article]:px-6">
20
+ {% csrf_token %}
21
+ <article class="bg-gray-500 p-4 flex flex-col gap-2">
22
+ <div class="flex flex-row justify-center items-center gap-5 text-lg">
23
+ <p class="font-medium p-1 px-3 bg-gray-200">Segmento 1</p>
24
+ <label for="etiquta_1">
25
+ <select name="etiquta_1" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_1" required>
26
+ <option value="1">no se percibe</option>
27
+ <option value="2">poca percepcion</option>
28
+ <option value="3">se percibe</option>
29
+ <option value="4">percepcion intensa</option>
30
+ <option value="5">percepcion muy intensa</option>
31
+ </select>
32
+ </label>
33
+ <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
34
+ </div>
35
+ <div class="flex flex-row justify-center items-center gap-5 text-lg">
36
+ <p class="font-medium p-1 px-3 bg-gray-200">Segmento 2</p>
37
+ <label for="etiquta_2">
38
+ <select name="etiquta_2" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_2" required>
39
+ <option value="1">no se percibe</option>
40
+ <option value="2" selected>poca percepcion</option>
41
+ <option value="3">se percibe</option>
42
+ <option value="4">percepcion intensa</option>
43
+ <option value="5">percepcion muy intensa</option>
44
+ </select>
45
+ </label>
46
+ <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
47
+ </div>
48
+ <div class="flex flex-row justify-center items-center gap-5 text-lg">
49
+ <p class="font-medium p-1 px-3 bg-gray-200">Segmento 3</p>
50
+ <label for="etiquta_3">
51
+ <select name="etiquta_3" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_3" required>
52
+ <option value="1">no se percibe</option>
53
+ <option value="2">poca percepcion</option>
54
+ <option value="3" selected>se percibe</option>
55
+ <option value="4">percepcion intensa</option>
56
+ <option value="5">percepcion muy intensa</option>
57
+ </select>
58
+ </label>
59
+ <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
60
+ </div>
61
+ <div class="flex flex-row justify-center items-center gap-5 text-lg">
62
+ <p class="font-medium p-1 px-3 bg-gray-200">Segmento 4</p>
63
+ <label for="etiquta_4">
64
+ <select name="etiquta_4" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_4" required>
65
+ <option value="1">no se percibe</option>
66
+ <option value="2">poca percepcion</option>
67
+ <option value="3">se percibe</option>
68
+ <option value="4" selected>percepcion intensa</option>
69
+ <option value="5">percepcion muy intensa</option>
70
+ </select>
71
+ </label>
72
+ <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
73
+ </div>
74
+ <div class="flex flex-row justify-center items-center gap-5 text-lg">
75
+ <p class="font-medium p-1 px-3 bg-gray-200">Segmento 5</p>
76
+ <label for="etiquta_5">
77
+ <select name="etiquta_5" class="p-1 rounded bg-gray-200 [*]:capitalize" id="etiquta_5" required>
78
+ <option value="1">no se percibe</option>
79
+ <option value="2">poca percepcion</option>
80
+ <option value="3">se percibe</option>
81
+ <option value="4">percepcion intensa</option>
82
+ <option value="5" selected>percepcion muy intensa</option>
83
+ </select>
84
+ </label>
85
+ <button type="button" class="p-1 rounded-lg bg-gray-200 active:bg-gray-400">➕</button>
86
+ </div>
87
+ </article>
88
+ <article class="absolute bg-gray-800/70 p-5 w-full h-full justify-center items-center hidden">
89
+ <section class="p-2 bg-gray-400 w-fit">
90
+ <form action="">
91
+ {% csrf_token %}
92
+ <label for="nueva_etiqueta">Nueva etiqueta:<input id="nueva_etiqueta" type="text"
93
+ required></label>
94
+ </form>
95
+ </section>
96
+ </article>
97
+ </form>
98
+ </article>
99
+ </article>
100
+ {% endblock %}
101
+
102
+ {% block extra_js %}
103
+ {% endblock %}
tecnicas/templates/tecnicas/seleccion-tecnica.html CHANGED
@@ -31,7 +31,7 @@
31
  <section
32
  class="modal-list-{{ cate }} flex flex-col text-lg bg-blue-100 p-4 pr-6 pl-8 sm:pl-12 z-10 -translate-y-1 rounded-b-2xl *:not-last:mb-4 transition-all duration-1000 hidden w-full">
33
  {% for tecnica in tecnicas %}
34
- <a href="{% url 'cata_system:panel_configuracion'%}?id_tecnica={{tecnica.id}}"
35
  class="bg-green-700 border-l-10 border-gray-700 rounded-md px-3 py-2 w-full font-bold tracking-wider text-left uppercase">
36
  {{ tecnica.nombre_tecnica }}
37
  </a>
 
31
  <section
32
  class="modal-list-{{ cate }} flex flex-col text-lg bg-blue-100 p-4 pr-6 pl-8 sm:pl-12 z-10 -translate-y-1 rounded-b-2xl *:not-last:mb-4 transition-all duration-1000 hidden w-full">
33
  {% for tecnica in tecnicas %}
34
+ <a href="{% url 'cata_system:panel_configuracion_basic'%}?id_tecnica={{tecnica.id}}"
35
  class="bg-green-700 border-l-10 border-gray-700 rounded-md px-3 py-2 w-full font-bold tracking-wider text-left uppercase">
36
  {{ tecnica.nombre_tecnica }}
37
  </a>
tecnicas/urls.py CHANGED
@@ -11,5 +11,6 @@ urlpatterns = [
11
  path("panel-catadores", views.managementCatadores, name="panel_catadores"),
12
  path("panel-sesiones", views.sesionesPanel, name="panel_sesiones"),
13
  path("seleccion-tecnica", views.selecionTecnica, name="seleccion_tecnica"),
14
- path("panel-configuracion", views.configuracionPanel, name="panel_configuracion"),
 
15
  ]
 
11
  path("panel-catadores", views.managementCatadores, name="panel_catadores"),
12
  path("panel-sesiones", views.sesionesPanel, name="panel_sesiones"),
13
  path("seleccion-tecnica", views.selecionTecnica, name="seleccion_tecnica"),
14
+ path("panel-configuracion-basic", views.configuracionPanelBasic, name="panel_configuracion_basic"),
15
+ path("panel-configuracion-tags", views.configuracionPanelTags, name="panel_configuracion_tags"),
16
  ]
tecnicas/views/__init__.py CHANGED
@@ -4,4 +4,5 @@ from .main_panel import mainPanel
4
  from .management_catadores import managementCatadores
5
  from .panel_sessions import sesionesPanel
6
  from .seleccion_tecnica import selecionTecnica
7
- from .configuracion_panel import configuracionPanel
 
 
4
  from .management_catadores import managementCatadores
5
  from .panel_sessions import sesionesPanel
6
  from .seleccion_tecnica import selecionTecnica
7
+ from .configuration_panel_basic import configuracionPanelBasic
8
+ from .configuration_panel_tags import configuracionPanelTags
tecnicas/views/{configuracion_panel.py → configuration_panel_basic.py} RENAMED
@@ -4,13 +4,13 @@ from django.urls import reverse
4
  from ..forms import SesionFirtsForm
5
  from ..models import TipoTecnica
6
 
7
- def configuracionPanel(req: HttpRequest):
8
  if req.method == "POST":
9
  form = SesionFirtsForm(req.POST)
10
  if form.is_valid():
11
  return redirect("/cata")
12
  else:
13
- return render(req, "tecnicas/configuracion-panel.html", { "form_sesion": form })
14
  elif req.method == "GET":
15
  try:
16
  id_tecnica = req.GET["id_tecnica"]
@@ -22,6 +22,6 @@ def configuracionPanel(req: HttpRequest):
22
 
23
  if tecnica:
24
  form_sesion = SesionFirtsForm()
25
- return render(req, "tecnicas/configuracion-panel.html", { "form_sesion": form_sesion })
26
  else:
27
  return redirect(reverse("cata_system:seleccion_tecnica") + "?error=la_tecnica_no_existe")
 
4
  from ..forms import SesionFirtsForm
5
  from ..models import TipoTecnica
6
 
7
+ def configuracionPanelBasic(req: HttpRequest):
8
  if req.method == "POST":
9
  form = SesionFirtsForm(req.POST)
10
  if form.is_valid():
11
  return redirect("/cata")
12
  else:
13
+ return render(req, "tecnicas/configuracion-panel-basic.html", { "form_sesion": form })
14
  elif req.method == "GET":
15
  try:
16
  id_tecnica = req.GET["id_tecnica"]
 
22
 
23
  if tecnica:
24
  form_sesion = SesionFirtsForm()
25
+ return render(req, "tecnicas/configuracion-panel-basic.html", { "form_sesion": form_sesion })
26
  else:
27
  return redirect(reverse("cata_system:seleccion_tecnica") + "?error=la_tecnica_no_existe")
tecnicas/views/configuration_panel_tags.py ADDED
@@ -0,0 +1,5 @@
 
 
 
 
 
 
1
+ from django.http import HttpRequest
2
+ from django.shortcuts import render
3
+
4
+ def configuracionPanelTags(req: HttpRequest):
5
+ return render(req, "tecnicas/configuracion-panel-tags.html")