##// END OF EJS Templates
- Agregada la barra de perfil y patron activo.
jsalyrosas -
r208:209
parent child
Show More
1 NO CONTENT: new file 10644
@@ -118,6 +118,9
118 118 }, context_instance=RequestContext(request))
119 119
120 120 def view(request, profile_id):
121 objProfileActive = None
122 objPatternActive = None
123
121 124 if request.method == 'GET' and 'pattern' in request.GET:
122 125 pattern_value = request.GET["pattern"]
123 126 else:
@@ -131,9 +134,18
131 134 objAntennaUp = patternChoosen.antennaup_set.get()
132 135 objAntennaDown = patternChoosen.antennadown_set.get()
133 136
137 lsProfilesActive = Profile.objects.filter(is_active=1)
138 if len(lsProfilesActive) > 0:
139 objProfileActive = Profile.objects.get(is_active=1)
140
141 lsPatternsActive = Pattern.objects.filter(is_active=1)
142 if len(lsPatternsActive) > 0:
143 objPatternActive = Pattern.objects.get(is_active=1)
144
134 145 return render_to_response('abscontrol/view.html', {'objProfile': objProfile, 'profile_list': profile_list,
135 146 'patternChoosen' : patternChoosen, 'lsPatterns' : lsPatterns,
136 147 'antennaUp' : objAntennaUp, 'antennaDown' : objAntennaDown,
148 'profileActive' : objProfileActive, 'patternActive' : objPatternActive,
137 149 }, context_instance=RequestContext(request))
138 150
139 151 def edit(request, profile_id):
@@ -322,9 +334,18
322 334
323 335 lsPatterns = objProfile.pattern_set.all()
324 336
337 lsProfilesActive = Profile.objects.filter(is_active=1)
338 if len(lsProfilesActive) > 0:
339 objProfileActive = Profile.objects.get(is_active=1)
340
341 lsPatternsActive = Pattern.objects.filter(is_active=1)
342 if len(lsPatternsActive) > 0:
343 objPatternActive = Pattern.objects.get(is_active=1)
344
325 345 return render_to_response('abscontrol/viewPattern.html', {'objProfile': objProfile, 'profile_list': profile_list,
326 346 'patternChoosen' : patternChoosen, 'lsPatterns' : lsPatterns,
327 347 'antennaUp' : objAntennaUp, 'antennaDown' : objAntennaDown,
348 'profileActive' : objProfileActive, 'patternActive' : objPatternActive,
328 349 }, context_instance=RequestContext(request))
329 350
330 351 def deletePattern(request, profile_id, pattern_id):
@@ -25,8 +25,8
25 25 border: 0px solid #f00 !important; }
26 26
27 27 #content {
28 margin: 5px 0px;
29 border: 0px solid #1cc; }
28 margin: 2px 0px 0px 0px;
29 border: 0px solid #1cc !important; }
30 30
31 31 #topcolumn {
32 32 float: left;
@@ -37,11 +37,19
37 37 border: 1px solid #ddd !important;
38 38 box-shadow: 2px 2px 5px #888; }
39 39
40 #activeProfileBar {
41 float: left;
42 width: 980px;
43 margin: 0px 0px;
44 height: 25px;
45 border: 1px solid #ddd !important;
46 box-shadow: 1px 1px 5px #ccc; }
47
40 48 #maincolumn {
41 49 float: left;
42 50 width: 980px;
43 margin: 2px 0px;
44 padding: 0px 0px;
51 margin: 2px 0px 0px 0px;
52 padding: 2px 0px 6px 0px;
45 53 border: 1px solid #ddd !important;
46 54 box-shadow: 2px 2px 5px #666; }
47 55
@@ -124,7 +132,7
124 132 padding: 4px 0px; margin: 0;
125 133 font-family: 'Droid Sans', sans-serif;
126 134 font-size: 12px;
127 letter-spacing: 0.006;
135 letter-spacing: 0.006em;
128 136 width: 200px; }
129 137
130 138 #mnuProfiles {
@@ -158,6 +166,31
158 166 margin: 6px; }
159 167
160 168 /****************************************************************************************/
169 /****** BARRA DE PERFILES ACTIVOS *************/
170 /****************************************************************************************/
171
172 #activeProfileBar label, a{
173 line-height: 20px;
174 float: left;
175 letter-spacing: 0.01em;
176 padding: 3px 12px;
177 border: 0px solid #f00 !important; }
178
179 .titleBar {
180 color: #333;
181 margin-left: 2px;
182 text-align: right; }
183
184 .ActiveProfile, .ActivePattern, .lnkActiveProfile {
185 color: #001bf4;
186 margin: 0px 2px;
187 text-align: left;
188 text-decoration: None; }
189
190 .navbarsep{
191 float: left; }
192
193 /****************************************************************************************/
161 194 /******** FORMULARIO DE PERFILES *************************************/
162 195 /****************************************************************************************/
163 196 #divProfile {
@@ -168,8 +201,31
168 201
169 202 #divProfile label,input[type=text],input[type=file] {
170 203 font-family: 'Open Sans', sans-serif;
171 /*font-family: 'Roboto Condensed', sans-serif;*/
172 204 font-size: inherit; }
205
206 #divProfile label {
207 float: left;
208 text-align: right;
209 width: 120px;
210 padding: 3px 10px 3px 10px;
211 line-height: 20px;
212 border: 0px solid #d85 !important;
213 }
214
215 #divProfile input[type=text] {
216 letter-spacing: 0.08em;
217 padding: 2px 10px 2px 10px;
218 width: 200px;
219 }
220
221 #divProfile input[type=text]:FOCUS {
222 border: 1px solid #faa !important;
223 border-radius: 0.26em;
224 box-shadow: 2px 2px 5px #fbb;
225 }
226
227 .lblProfile {
228 width: 200px; }
173 229
174 230 #divPattern textarea,input[type=text],label,input[type=file],input[type=button],input[type=submit] {
175 231 font-family: 'Roboto Condensed', sans-serif;
@@ -7,7 +7,9
7 7 <nav class="MnuHorizontal" id="mnuProfiles">
8 8 <ul>
9 9 <li><a href="{% url abscontrol.views.new %}">New</a></li>
10 {% if objProfile and patternChoosen %}
10 11 <li><a href="{% url abscontrol.views.viewPattern objProfile.id patternChoosen.id %}">View</a></li>
12 {% endif %}
11 13 {% if objProfile.state == 0 %}
12 14 <li><a href="/abscontrol/changeName/{{ objProfile.id }}/">Save</a></li>
13 15 {% else %}
@@ -34,8 +36,10
34 36 </form>
35 37 {% else %}
36 38 <div id="divProfile">
37 <label for="lblName">Profile: {{ objProfile.name }}</label>
38 </div>
39 <label for="lblName">Profile:</label>
40 <label for="lblName" class="lblProfile">{{ objProfile.name }}</label>
41 </div>
42 <div class="cleardivs"></div>
39 43 {% endif %}
40 44 {% if patternChoosen %}
41 45 <div id="navPatterns">
@@ -6,11 +6,11
6 6 {% endblock %}
7 7 {% block maincolumn%}
8 8 <div id="maincolumn">
9 <!-- <form action="/abscontrol/{{ profile_id }}/save/" method="post" id="frmPattern"> -->
10 9 <form action="/abscontrol/upgrade/{{ profile_id }}/" method="post" id="frmPattern">
11 10 {% csrf_token %}
12 11 <div id="divProfile">
13 <label for="lblName">Profile: {{ profile_name }}</label>
12 <label for="lblName">Profile:</label>
13 <label for="lblName" class="lblProfile">{{ profile_name }}</label>
14 14 </div>
15 15 {% block mnuPattern %}
16 16 <div class="divMenu" id="divMnuPattern">
@@ -18,6 +18,21
18 18 </nav>
19 19 {% endblock %}
20 20 {% block maincolumn%}
21 {% block activeProfileBar %}
22 <div class="cleardivs"></div>
23 <div id="activeProfileBar">
24 <label for="lblProfileTitle" class="titleBar">Active Profile</label>
25 <img src="/media/navbarsep.png" class="navbarsep">
26 {% if profileActive != None %}
27 <a href="{% url abscontrol.views.view profileActive.id %}" class="lnkActiveProfile">{{ profileActive.name }}</a>
28 {% endif %}
29 {% if patternActive != None %}
30 <img src="/media/navbarsep.png" class="navbarsep">
31 <a href="{% url abscontrol.views.viewPattern profileActive.id patternActive.id %}" class="lnkActiveProfile">{{ patternActive.value }}</a>
32 {% endif %}
33 </div>
34 <div class="cleardivs"></div>
35 {% endblock %}
21 36 <div id="maincolumn">
22 37 {% if objProfile.state == 0 %}
23 38 <div id="divProfile">
General Comments 0
You need to be logged in to leave comments. Login now