Commit 8aff5434da95f84e0edfc3e4bc5cbae88f5b31dc
1 parent
9f7fddb9
Exists in
master
and in
5 other branches
Including links templates in the subject template [Issues: #120,#121,#122]
Showing
1 changed file
with
12 additions
and
85 deletions
Show diff stats
courses/templates/subject/form_view_teacher.html
@@ -225,7 +225,6 @@ | @@ -225,7 +225,6 @@ | ||
225 | {% if user|has_role:'system_admin' or topic.owner == user%} | 225 | {% if user|has_role:'system_admin' or topic.owner == user%} |
226 | {% include "files/create_file.html" %} | 226 | {% include "files/create_file.html" %} |
227 | {% endif %} | 227 | {% endif %} |
228 | - | ||
229 | <!-- MODAL REMOVE FILE --> | 228 | <!-- MODAL REMOVE FILE --> |
230 | <div class="modal" id="removeFileModal"> | 229 | <div class="modal" id="removeFileModal"> |
231 | <div class="modal-dialog"> | 230 | <div class="modal-dialog"> |
@@ -273,59 +272,13 @@ | @@ -273,59 +272,13 @@ | ||
273 | </div> | 272 | </div> |
274 | <!-- EndModal --> | 273 | <!-- EndModal --> |
275 | 274 | ||
276 | - <!--MODAL CREATE LINK--> | ||
277 | - <div class="modal fade" id="createLinksModal" tabindex="-1" role="dialog" aria-labelledby="createLink" style="display: none;"> | ||
278 | - <div class="modal-dialog" role="document"> | ||
279 | - <div class="modal-content"> | ||
280 | - <div class="modal-header"> | ||
281 | - <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | ||
282 | - <h4 class="modal-title" id="createLink">Create a New Link</h4> | ||
283 | - </div> | ||
284 | - <div class="modal-body"> | ||
285 | - <!-- Card --> | ||
286 | - <div class="form-group is-empty"> | ||
287 | - <label class="control-label" for="inputDefault">Name</label> | ||
288 | - <input type="text" class="form-control" id="inputDefault"> | ||
289 | - </div> | ||
290 | - <div class="form-group is-empty"> | ||
291 | - <label class="control-label" for="inputDefault">Url</label> | ||
292 | - <input type="text" class="form-control" id="inputDefault"> | ||
293 | - </div> | ||
294 | - <div class="form-group is-empty"> | ||
295 | - <label class="control-label" for="inputDefault">Descrição</label> | ||
296 | - <textarea class="form-control" rows="3"></textarea> | ||
297 | - </div> | ||
298 | - <div class="form-group"> | ||
299 | - <a href="javascript:void(0)" class="btn btn-raised btn-default">Cancel</a> | ||
300 | - <a href="javascript:void(0)" class="btn btn-raised btn-primary">Submit</a> | ||
301 | - </div> | ||
302 | - <!-- .end Card --> | ||
303 | - </div> | ||
304 | - </div> | ||
305 | - </div> | ||
306 | - </div> | ||
307 | - <!-- EndModal --> | 275 | + {% if user|has_role:'system_admin' or topic.owner == user%} |
276 | + {% include "links/create_link.html" %} | ||
277 | + {% endif %} | ||
308 | 278 | ||
309 | - <!-- MODAL REMOVE LINK --> | ||
310 | - <div class="modal" id="removeLink"> | ||
311 | - <div class="modal-dialog"> | ||
312 | - <div class="modal-content"> | ||
313 | - <div class="modal-header"> | ||
314 | - <button type="button" class="close" data-dismiss="modal" aria-hidden="true">X</button> | ||
315 | - <h4 class="modal-title"></h4> | ||
316 | - </div> | ||
317 | - <div class="modal-body"> | ||
318 | - <p>Do you really want to delete this link?</p> | ||
319 | - </div> | ||
320 | - <div class="modal-footer"> | ||
321 | - | ||
322 | - <a href="#" target="_self"><button type="button" class="btn btn-primary" data-dismiss="modal" aria-hidden="true">Confirm</button></a> | ||
323 | - | ||
324 | - </div> | ||
325 | - </div> | ||
326 | - </div> | ||
327 | - </div> | ||
328 | - <!-- END --> | 279 | + {% if user|has_role:'system_admin' or topic.owner == user%} |
280 | + {% include "links/delete_link.html" %} | ||
281 | + {% endif %} | ||
329 | 282 | ||
330 | <!-- MODAL EMBEED--> | 283 | <!-- MODAL EMBEED--> |
331 | <div class="modal fade" id="embedModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"> | 284 | <div class="modal fade" id="embedModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"> |
@@ -388,7 +341,7 @@ | @@ -388,7 +341,7 @@ | ||
388 | </div> | 341 | </div> |
389 | <div class="modal-body"> | 342 | <div class="modal-body"> |
390 | <form class="form-horizontal"> | 343 | <form class="form-horizontal"> |
391 | - | 344 | + |
392 | <fieldset> | 345 | <fieldset> |
393 | <legend>Atividade Proposta</legend> | 346 | <legend>Atividade Proposta</legend> |
394 | <div class="form-group is-empty"> | 347 | <div class="form-group is-empty"> |
@@ -572,36 +525,10 @@ | @@ -572,36 +525,10 @@ | ||
572 | <!--EndForumModal--> | 525 | <!--EndForumModal--> |
573 | 526 | ||
574 | <!-- MODAL LINK EDIT--> | 527 | <!-- MODAL LINK EDIT--> |
575 | - <div class="modal fade" id="linksModalEdit" tabindex="-1" role="dialog" aria-labelledby="myModalLabel"> | ||
576 | - <div class="modal-dialog" role="document"> | ||
577 | - <div class="modal-content"> | ||
578 | - <div class="modal-header"> | ||
579 | - <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button> | ||
580 | - <h4 class="modal-title" id="myModalLabel">Links</h4> | ||
581 | - </div> | ||
582 | - <div class="modal-body"> | ||
583 | - <!-- Card --> | ||
584 | - <div class="form-group"> | ||
585 | - <label class="control-label" for="inputDefault">Name</label> | ||
586 | - <input value="Python" type="text" class="form-control" id="inputDefault"> | ||
587 | - </div> | ||
588 | - <div class="form-group"> | ||
589 | - <label class="control-label" for="inputDefault">Url</label> | ||
590 | - <input value="https://www.python.org/" type="text" class="form-control" id="inputDefault"> | ||
591 | - </div> | ||
592 | - <div class="form-group is-empty"> | ||
593 | - <label class="control-label" for="inputDefault">Descrição</label> | ||
594 | - <textarea class="form-control" rows="3"></textarea> | ||
595 | - </div> | ||
596 | - <div class="form-group"> | ||
597 | - <a href="javascript:void(0)" class="btn btn-raised btn-default">Cancel</a> | ||
598 | - <a href="javascript:void(0)" class="btn btn-raised btn-primary">Submit</a> | ||
599 | - </div> | ||
600 | - <!-- .end Card --> | ||
601 | - </div> | ||
602 | - </div> | ||
603 | - </div> | ||
604 | - </div> | 528 | + {% if user|has_role:'system_admin' or topic.owner == user%} |
529 | + {% include "links/update_link.html" %} | ||
530 | + {% endif %} | ||
531 | + | ||
605 | <!-- EndModal --> | 532 | <!-- EndModal --> |
606 | </div> | 533 | </div> |
607 | </div> | 534 | </div> |
@@ -624,4 +551,4 @@ | @@ -624,4 +551,4 @@ | ||
624 | </div> | 551 | </div> |
625 | </div> | 552 | </div> |
626 | </div> | 553 | </div> |
627 | - </div> | ||
628 | \ No newline at end of file | 554 | \ No newline at end of file |
555 | + </div> |