PageRenderTime 27ms CodeModel.GetById 18ms RepoModel.GetById 0ms app.codeStats 0ms

/gnowsys-ndf/gnowsys_ndf/ndf/templates/ndf/mis_details.html

https://gitlab.com/g66shivam/gstudio
HTML | 758 lines | 582 code | 166 blank | 10 comment | 0 complexity | 11e990ba0acb51190c768bb6b9c51837 MD5 | raw file
  1. {% extends "ndf/base.html" %}
  2. {% load i18n %}
  3. {% load ndf_tags %}
  4. {% load pagination_tags %}
  5. {% block title %} {{ title }} {% endblock %}
  6. {% block head%}
  7. {{block.super}}
  8. <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  9. <!-- Scripts required for D3 graph -->
  10. <script type="text/javascript" src="/static/ndf/bower_components/d3/d3.min.js"></script> <!-- checked -->
  11. <script type="text/javascript" src="/static/ndf/bower_components/underscore/underscore.js"></script> <!-- checked -->
  12. <script sync="text/javascript" src="/static/ndf/bower_components/FileSaver/FileSaver.js" ></script> <!-- checked -->
  13. {% endblock %}
  14. {% block style %}
  15. {{block.super}}
  16. /* Setting css-properties for app-set in left panel */
  17. .active-app-set, .active-app-set-edit, .active-app-set-view {
  18. /*padding:0.5em 0 0.5em 0.5em; */
  19. /*margin-left: -10px !important;*/
  20. background-color:#efefef;
  21. }
  22. .active-app-set-edit {
  23. border-right: 4px solid #808080;
  24. font-weight: bold;
  25. }
  26. .active-app-set-view {
  27. border-left: 4px solid #808080;
  28. font-weight: bold;
  29. }
  30. {% endblock %}
  31. {% block meta_content %}
  32. {% check_is_gstaff groupid request.user as gstaff_access %}
  33. <ul class="side-nav">
  34. <li>
  35. <a></a>
  36. </li>
  37. {% for each in app_collection_set %}
  38. {% get_memberof_objects_count each.pk groupid as count %}
  39. {% if app_set_id == each|safe %}
  40. {% if '/new/' in request.path %}
  41. <li class="active-app-set-edit">
  42. {% else %}
  43. <li class="active-app-set-view">
  44. {% endif %}
  45. {% else %}
  46. <li>
  47. {% endif %}
  48. <div class="row">
  49. {% if each.type_of or each.name == "Caste" or each.name == "NUSSD Course" %}
  50. {% if app_name == "MIS" %}
  51. <a class="small-8 columns" href="{% url 'mis:mis_app_detail' groupid app_id each.pk %}" title="View all {{each.name}}'s">
  52. {% else %}
  53. <a class="small-8 columns" href="{% url 'mis-po:mis_app_detail' groupid app_id each.pk %}" title="View all {{each.name}}'s">
  54. {% endif %}
  55. {{each.name}} ({{count}})
  56. </a>
  57. {% if gstaff_access %}
  58. {% if app_name == "MIS" %}
  59. <a class="small-4 columns" href="{% url 'mis:mis_app_instance_create' groupid app_id each.pk %}" title="Add {{each.name}}">
  60. {% else %}
  61. <a class="small-4 columns" href="{% url 'mis-po:mis_app_instance_create' groupid app_id each.pk %}" title="Add {{each.name}}">
  62. {% endif %}
  63. +&nbsp;Add
  64. </a>
  65. {% endif %}
  66. {% else %}
  67. {{each.name}}
  68. {% endif %}
  69. </div>
  70. </li>
  71. {% endfor %}
  72. </ul>
  73. {% endblock %}
  74. {% block body_content %}
  75. {# template for showing apt_set_instance details #}
  76. {% if app_set_instance_template %}
  77. <!-- Consistent details-view -->
  78. {% if user.is_authenticated %}
  79. <a id="toggle-shelf" class="right-off-canvas-toggle right" ><i class='fi-book-bookmark'></i></a>
  80. {% endif %}
  81. <!-- Header of the page -->
  82. <header class="row page">
  83. <section class="medium-12 columns" >
  84. <h2>
  85. <span class='node'>{{node.name}}</span>
  86. <small class="label-list">
  87. {% for tag in node.tags %}
  88. <a href="{% url 'tag_info' groupid tag %}"><span class="label">{{tag}}</span></a>
  89. {% endfor %}
  90. </small>
  91. </h2>
  92. <dl class="row tabs" data-tab data-options="deep_linking:true">
  93. <dd class="active"><a href="#view-page"><i class="fi-eye"></i>{% trans "Read" %}</a></dd>
  94. <dd ><a href="#view-scheduler-calendar"><i class="fi-calendar"></i> {% trans "Events" %} </a></dd>
  95. <dd>
  96. <a href="#" data-dropdown="graph-hover" data-options="is_hover:true"><i class="fi-share"></i>{% trans "Graph" %}</a>
  97. <ul id="graph-hover" class="f-dropdown" data-dropdown-content>
  98. <li><a href="#view-concept-graph" data-reveal-id="view-concept-graph">{% trans "Concept Graph" %}</a></li>
  99. {% if node.collection_set %}
  100. <li><a href="#view-collection-graph" data-reveal-id="view-collection-graph">{% trans "Collection Graph" %}</a></li>
  101. {% endif %}
  102. {% if node.prior_node %}
  103. <li><a href="#view-dependency-graph" data-reveal-id="view-dependency-graph">{% trans "Dependency Graph" %}</a></li>
  104. {% endif %}
  105. </ul>
  106. </dd>
  107. <dd><a href="#view-map-widget" data-reveal-id="view-map-widget"><i class="fi-marker"></i>{% trans "Location" %}</a></dd>
  108. <dd><a href="#view-comments"><i class="fi-comment"></i> {% trans "Discuss" %}</a></dd>
  109. </dl>
  110. </section>
  111. </header>
  112. <div class="row">
  113. <section class="medium-9 columns">
  114. <div class="tabs-content">
  115. <!-- Read Tab content -->
  116. <div id="view-page" class="content active">
  117. {% if mime_type %}
  118. <div class="row">
  119. {% if "image" in mime_type %}
  120. <a class="small-12 columns" href="{% url 'file_detail' groupid system_id %}">
  121. <img src="{% url 'getFileThumbnail' groupid system_id %}" />
  122. </a>
  123. {% elif "video" in mime_type %}
  124. <a class="small-12 columns" href="{% url 'file_detail' groupid system_id %}">
  125. <img src="{% url 'getFileThumbnail' groupid system_id %}" />
  126. </a>
  127. {% else %}
  128. <a class="small-12 columns" href="{% url 'file_detail' groupid system_id %}">
  129. <font size="3">{{app_set_instance_name}}</font>
  130. </a>
  131. {% endif %}
  132. </div>
  133. {% endif %}
  134. {% if node.content %}
  135. <div class="row" id="about">
  136. <div class="small-12 columns">
  137. {% with node.html_content|safe as description %}
  138. {{description}}
  139. {% endwith %}
  140. </div>
  141. </div>
  142. {% endif %}
  143. {% for tab_name, display_fields in property_display_order %}
  144. {% ifnotequal tab_name "Address" %}
  145. {% for altname, value in display_fields %}
  146. <div class="row">
  147. <div class="small-4 columns">
  148. <label>{{altname}}</label>
  149. </div>
  150. <div class="small-8 columns">
  151. <p>{{value}}</p>
  152. </div>
  153. </div>
  154. {% endfor %}
  155. {% else %}
  156. {% if node.person_belongs_to_country %}
  157. <div class="row">
  158. <div class="small-4 columns">
  159. <label>Address</label>
  160. </div>
  161. <div class="small-8 columns">
  162. {{node.house_street|default_if_none:""}}{% if node.house_street %}; {% endif %}
  163. {{node.village|default_if_none:""}}{% if node.village %}; {% endif %}
  164. {{node.taluka|default_if_none:""}}{% if node.taluka %}; {% endif %}
  165. {{node.town_city|default_if_none:""}}{% if node.town_city %}; {% endif %}
  166. <br/>
  167. {% for n in node.person_belongs_to_district|slice:":1" %}
  168. <a href="#">{{n.name}}</a>{% if n.name %}; {% endif %}
  169. {% endfor %}
  170. {% for n in node.person_belongs_to_state|slice:":1" %}
  171. <a href="#">{{n.name}}</a>{% if n.name %} - {% endif %}
  172. {% endfor %}
  173. {{node.pin_code|default_if_none:""}}{% if node.pin_code %}; {% endif %}
  174. {% for n in node.person_belongs_to_country|slice:":1" %}
  175. <a href="#">{{n.name}}</a>
  176. {% endfor %}
  177. </div>
  178. </div>
  179. <br/>
  180. {% endif %}
  181. {% endifnotequal %}
  182. {% endfor %}
  183. {% if node.enrollment_code %}
  184. <br/>
  185. <div class="row" id="enrollment_code">
  186. <label class="small-4 columns">
  187. Enrollment Code
  188. </label>
  189. <div class="small-8 columns">
  190. {{node.enrollment_code}}
  191. </div>
  192. </div>
  193. {% endif %}
  194. {% if node.college_affiliated_to %}
  195. <br/>
  196. <div class="row" id="college_affiliated_to">
  197. <label class="small-4 columns">
  198. Affiliated to
  199. </label>
  200. <div class="small-8 columns">
  201. {% for n in node.college_affiliated_to|slice:":5" %}
  202. <a href="#">{{n.name}}</a><br/>
  203. {% if forloop.counter0 == 4%}
  204. ... <a href="#">See {{node.college_affiliated_to|length|add:"-5"}} more</a>
  205. {% endif %}
  206. {% endfor %}
  207. </div>
  208. </div>
  209. {% endif %}
  210. {% if node.college_of_student %}
  211. <br/>
  212. <div class="row" id="college_of_student">
  213. <label class="small-4 columns">
  214. No. of Students Enrolled
  215. </label>
  216. <div class="small-8 columns">
  217. {% if node.college_of_student|length > 5 %}
  218. <a href="#">{{node.college_of_student|length}}</a>
  219. {% else %}
  220. {% for n in node.college_of_student %}
  221. <a href="#">{{n.name|title}}</a><br/>
  222. {% endfor %}
  223. {% endif %}
  224. </div>
  225. </div>
  226. {% endif %}
  227. {% if node.college_has_trainer %}
  228. <br/>
  229. <div class="row" id="college_has_trainer">
  230. <label class="small-4 columns">
  231. No. of Teachers Enrolled
  232. </label>
  233. <div class="small-8 columns">
  234. {% if node.college_has_trainer|length > 5 %}
  235. <a href="#">{{node.college_has_trainer|length}}</a>
  236. {% else %}
  237. {% for n in node.college_has_trainer %}
  238. <a href="#">{{n.name|title}}</a><br/>
  239. {% endfor %}
  240. {% endif %}
  241. </div>
  242. </div>
  243. {% endif %}
  244. {% if node.affiliated_college %}
  245. <br/>
  246. <div class="row" id="affiliated_college">
  247. <label class="small-4 columns">
  248. Affiliated Colleges
  249. </label>
  250. <div class="small-8 columns">
  251. {% for n in node.affiliated_college|slice:":5" %}
  252. <a href="#">{{n.name}}</a><br/>
  253. {% if forloop.counter0 == 4%}
  254. ... <a href="#">See {{node.affiliated_college|length|add:"-5"}} more</a>
  255. {% endif %}
  256. {% endfor %}
  257. </div>
  258. </div>
  259. {% endif %}
  260. {% if node.university_of_student %}
  261. <br/>
  262. <div class="row" id="university_of_student">
  263. <label class="small-4 columns">
  264. No. of Students Enrolled
  265. </label>
  266. <div class="small-8 columns">
  267. {% if node.university_of_student|length > 5 %}
  268. <a href="#">{{node.university_of_student|length}}</a>
  269. {% else %}
  270. {% for n in node.university_of_student %}
  271. <a href="#">{{n.name|title}}</a><br/>
  272. {% endfor %}
  273. {% endif %}
  274. </div>
  275. </div>
  276. {% endif %}
  277. </div>
  278. <!-- Content for Concept Graph -->
  279. <div class="content reveal-modal graph-div" id="view-concept-graph" data-reveal>
  280. <a class="close-reveal-modal">&#215;</a>
  281. {% include "ndf/graph_concept.html" %}
  282. </div>
  283. <!-- Content for Collection Graph -->
  284. {% if node.collection_set %}
  285. <div class="content reveal-modal graph-div" id="view-collection-graph" data-reveal>
  286. <a class="close-reveal-modal">&#215;</a>
  287. {% include "ndf/graph_collection.html" %}
  288. </div>
  289. {% endif%}
  290. <!-- Content for dependency Graph -->
  291. {% if node.prior_node %}
  292. <div class="content reveal-modal graph-div" id="view-dependency-graph" data-reveal>
  293. <a class="close-reveal-modal">&#215;</a>
  294. {% include "ndf/graph_dependency.html" %}
  295. </div>
  296. {% endif %}
  297. <!-- Tab View Map Widget -->
  298. <div class="content reveal-modal graph-div" id="view-map-widget" data-reveal>
  299. <a class="close-reveal-modal" >&#215;</a>
  300. {% include "ndf/map_widget.html" with mode="read" source="custom_template_edit" %}
  301. </div>
  302. <!-- Tab View Scheduler-Calender -->
  303. <div class="content" id="view-scheduler-calendar" >
  304. {% include "ndf/scheduler_calender.html" with app_set_instance_atlist=app_set_instance_atlist %}
  305. </div>
  306. </div>
  307. </section>
  308. <section class="medium-3 columns">
  309. <div class="panel">
  310. <h3 class="subheader"></h3>
  311. Edited {{ node.last_update|timesince }} ago by <a class="user">{{node.user_details_dict.modified_by}}</a>
  312. <small>
  313. <div><a href="#view-changes"><i class="fi-clock"></i> Versions </a>
  314. {% for seq_no, version_no in node.version_dict.items reversed %}
  315. <abbr title={{version_no}}><a href="{% url 'node_version' groupid node.pk version_no %}" style="padding-left:5px;">+</a></abbr>
  316. {% endfor %}
  317. </div>
  318. </small>
  319. <!-- Button that converts collection into module-->
  320. {% if node.collection_set and user.is_authenticated%}
  321. <a href="#" class="button" id="module"></i> <span>{% trans "Make Module" %}</a>
  322. {% endif %}
  323. {% if node %}
  324. {% get_publish_policy request groupid node as group_policy %}
  325. {% check_group node.pk as is_group %}
  326. {% if group_policy == "allow" %}
  327. {% if is_group %}
  328. <div>
  329. <a class="button small" href="{% url 'publish_group' group_id node %}"> {% trans "Publish" %} </a>
  330. </div>
  331. {% else %}
  332. <div>
  333. <a class="button small" href="{% url 'publish_page' group_id node %}">{% trans "Publish" %} </a>
  334. </div>
  335. {% endif %}
  336. {% endif %}
  337. {% endif %}
  338. {% edit_policy groupid node request.user as status %}
  339. {% if status == "allow" %}
  340. {% get_edit_url node.pk as edit_url %}
  341. {% switch_group_conditions request.user group_id as switch_conditions %}
  342. {% check_group node.pk as is_group %}
  343. {% get_user_object node.created_by as created_user %}
  344. {% if is_group %}
  345. {% ifequal created_user request.user %}
  346. <a href="{#% url edit_url node %#}" class="small button split edit">
  347. <i class="fi-pencil"></i> {% trans "Edit" %} <span data-dropdown="edit-options"></span>
  348. </a>
  349. {% endifequal %}
  350. {% else %}
  351. {% if switch_conditions %}
  352. <input type="button" id="switch_group" class="button small" value="Publish in group/s">
  353. <div id="mySystemtype" class="reveal-modal" data-reveal >
  354. <h2>{% trans "Select Groups" %}</h2>
  355. <div id="module_drawer" >
  356. {% include "ndf/drawer_widget.html" with widget_for="collection_set" %}
  357. </div>
  358. <a class="close-reveal-modal st">&#215;</a>
  359. <input type="button" id="save_switch_group" class="button small-10 small-push-1 column" value="Save">
  360. </div>
  361. {% endif %}
  362. {% if app_name == "MIS" %}
  363. <a href="{% url 'mis:mis_app_instance_edit' groupid app_id app_set_id app_set_instance_id %}" class="small button split edit">
  364. {% else %}
  365. <a href="{% url 'mis-po:mis_app_instance_edit' groupid app_id app_set_id app_set_instance_id %}" class="small button split edit">
  366. {% endif %}
  367. <i class="fi-pencil"></i> {% trans "Edit" %} <span data-dropdown="edit-options"></span>
  368. </a>
  369. <ul id="edit-options" class="f-dropdown">
  370. <li>
  371. <a href="{% url 'page_create_edit' groupid %}">Create a new page</a>
  372. </li>
  373. </ul>
  374. {% endif %}
  375. {% endif %}
  376. </div>
  377. </section>
  378. </div>
  379. {% endif %}
  380. {% endblock %}
  381. {% block script %}
  382. {{block.super}}
  383. $(document).on('click', ".checkedAll", function() {
  384. if($(this).is(":checked")==true) {
  385. $('.objectsCheckbox input').prop( "checked", true );
  386. }
  387. else {
  388. $('.objectsCheckbox input').prop( "checked", false );
  389. }
  390. });
  391. $(document).on('click', ".button.confirmDeleteObjects", function(){
  392. var selectedobject = $(".objectsCheckbox input:checked");
  393. $('#myModal').foundation('reveal', 'open');
  394. // $('#myModal').foundation('reveal', 'close');
  395. if(selectedobject.length > 0) {
  396. var i = 0;
  397. var str = "";
  398. $.map(selectedobject,function(each){
  399. if(i == 0) {
  400. str = str.concat(each.parentElement.id)
  401. }
  402. else {
  403. str = str.concat(","+each.parentElement.id)
  404. }
  405. i = i+1;
  406. })
  407. $.ajax({
  408. url: "{% url 'deletion_instances' groupid %}",
  409. type: 'POST',
  410. data: {deleteobjects: str, csrfmiddlewaretoken: '{{ csrf_token }}', confirm: "yes"},
  411. beforeSend: function() {},
  412. success: function(result) {},
  413. complete: function() {
  414. $('#myModal').foundation('reveal', 'close');
  415. }
  416. });
  417. $.map(selectedobject,function(each) {
  418. each.parentElement.parentElement.remove()
  419. });
  420. $('#myModal').foundation('reveal', 'close');
  421. }
  422. else{
  423. alert("select object to delete")
  424. }
  425. });
  426. $(document).on('click',".button.deleteObjects",function(){
  427. var selectedobject = $(".objectsCheckbox input:checked");
  428. // $('#myModal').foundation('reveal', 'close');
  429. if(selectedobject.length > 0) {
  430. $('#myModal').foundation('reveal', 'open');
  431. // var confirmed = confirm("Deleting "+selectedobject.length+" objects");
  432. // if(confirmed == true){
  433. var i = 0;
  434. var str = "";
  435. $.map(selectedobject,function(each){
  436. if(i == 0) {
  437. str = str.concat(each.parentElement.id)
  438. }
  439. else {
  440. str = str.concat(","+each.parentElement.id)
  441. }
  442. i = i+1;
  443. })
  444. $.ajax({
  445. url: "{% url 'deletion_instances' groupid %}",
  446. type: 'POST',
  447. data: {deleteobjects:str,csrfmiddlewaretoken: '{{ csrf_token }}'},
  448. beforeSend: function() {},
  449. success: function(result) {
  450. $("#deletion_results").html("");
  451. for(var obj in result){
  452. var ulist = $("<ul>"+"</ul>")
  453. .attr("id","conceptlist")
  454. .appendTo($("#deletion_results"));
  455. var li = $("<li><b>"+result[obj].title+"</b></li>")
  456. .appendTo(ulist);
  457. var ulist1 = $("<ul>"+"</ul>")
  458. .attr("id","conceptlist")
  459. .appendTo(li);
  460. for(var obj2 in result[obj].content){
  461. object = result[obj].content[obj2]
  462. for(var obj3 in object){
  463. for(var each in object[obj3]){
  464. var li1 = $("<li>"+object[obj3][each]+"</li>")
  465. .appendTo(ulist1);
  466. }
  467. }
  468. }
  469. }
  470. },
  471. complete: function() {}
  472. });
  473. // }
  474. }
  475. else {
  476. alert("select object to delete")
  477. }
  478. });
  479. $(document).on('click', ".button.cancelDeleteObjects", function() {
  480. $('#myModal').foundation('reveal', 'close');
  481. });
  482. $(document).on('open', '#view-map-edit-widget[data-reveal], #view-map-widget[data-reveal]', function() {
  483. $.ajax({
  484. url: "{% url 'get_visited_location' groupid %}",
  485. success: function(data) {
  486. data = JSON.parse(data);
  487. var lastVisitedLocationVal = data;
  488. if(lastVisitedLocationVal) {
  489. if(lastVisitedLocationVal == "[]") {
  490. lastVisitedLocationVal = JSON.parse(lastVisitedLocationVal);
  491. }
  492. if(lastVisitedLocationVal.length > 0) {
  493. // lastVisitedLocationVal = JSON.parse(lastVisitedLocationVal);
  494. var zoom = lastVisitedLocationVal.pop(),
  495. lng = lastVisitedLocationVal[1],
  496. lat = lastVisitedLocationVal[0];
  497. map.setView([lat, lng], zoom);
  498. }
  499. }
  500. else if(tempArr.length) {
  501. var group = new L.featureGroup(tempArr)
  502. map.fitBounds(group.getBounds());
  503. }
  504. }
  505. });
  506. });
  507. $(document).on('opened', '#view-map-edit-widget[data-reveal], #view-map-widget[data-reveal]', function() {
  508. map.invalidateSize();
  509. });
  510. /*
  511. $(document).foundation({
  512. tab: {
  513. callback : function (tab) {
  514. // console.log(tab);
  515. }
  516. }
  517. });
  518. */
  519. var startDtInput = $("font:contains('start_time')");
  520. startDtInput = startDtInput.parent().next().find("input");
  521. var endDtInput = $("font:contains('end_time')");
  522. endDtInput = endDtInput.parent().next().find("input");
  523. if(startDtInput.length > 0) {
  524. startDtInput.datetimepicker({
  525. hourGrid: 6,
  526. minuteGrid: 15,
  527. onClose: function(dateText, inst) {
  528. if (endDtInput.val() != '') {
  529. var testStartDate = startDtInput.datetimepicker('getDate');
  530. var testEndDate = endDtInput.datetimepicker('getDate');
  531. if (testStartDate > testEndDate)
  532. endDtInput.datetimepicker('setDate', testStartDate);
  533. }
  534. else {
  535. endDtInput.val(dateText);
  536. }
  537. },
  538. onSelect: function(selectedDateTime) {
  539. endDtInput.datetimepicker('option', 'minDate', startDtInput.datetimepicker('getDate') );
  540. }
  541. });
  542. }
  543. if(endDtInput.length > 0){
  544. endDtInput.datetimepicker({
  545. hourGrid: 6,
  546. minuteGrid: 15,
  547. numberOfMonths: 2,
  548. onClose: function(dateText, inst) {
  549. if (startDtInput.val() != '') {
  550. var testStartDate = startDtInput.datetimepicker('getDate');
  551. var testEndDate = endDtInput.datetimepicker('getDate');
  552. if (testStartDate > testEndDate)
  553. startDtInput.datetimepicker('setDate', testEndDate);
  554. }
  555. else {
  556. startDtInput.val(dateText);
  557. }
  558. },
  559. onSelect: function (selectedDateTime){
  560. startDtInput.datetimepicker('option', 'maxDate', endDtInput.datetimepicker('getDate') );
  561. }
  562. });
  563. }
  564. // totWhen ---------------
  565. var totWhen = $("font:contains('tot_when')").parent().next().find("input");
  566. if(totWhen.length > 0) {
  567. totWhen.datetimepicker();
  568. $(totWhen).after('&nbsp;<input class="button tiny" type="button" value="Add Date"><br/>')
  569. $("input.tiny").after("<div id='tot-when-date-list'></div>")
  570. }
  571. $(totWhen).change(function(){
  572. if($(totWhen).val().length > 0) {
  573. $("input.tiny").removeClass("disabled");
  574. }
  575. else {
  576. $("input.tiny").addClass("disabled");
  577. }
  578. });
  579. $("input.tiny").click(function(){
  580. if(!$(this).hasClass("disabled")) {
  581. $("#tot-when-date-list").append('<span class="secondary label" style="margin-right:5px;"><span class="date-item">'+$(totWhen).val()+' </span><span style="font-size:large; cursor:pointer;" onclick="$(this).parent().remove();">&times;</span></span>');
  582. $(totWhen).val("");
  583. $("input.tiny").addClass("disabled");
  584. }
  585. })
  586. function getTotWhen() {
  587. var datesList = []
  588. dts = $("#tot-when-date-list .date-item");
  589. $.each(dts, function(i, val){datesList.push($(val).text().trim())});
  590. return datesList;
  591. }
  592. {% endblock %}