Ignore:
Timestamp:
01/03/16 20:55:59 (9 years ago)
Author:
nanardon
Message:

Add timeline view to employment page

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LATMOS-Accounts-Web/root/html/users/employment.tt

    r1515 r1583  
    77 
    88<div id="objectform" class="objectform"> 
     9 
     10 
     11[% IF c.stash.user.listEmployment %] 
     12<div id=timeline style="width: 80%"></div> 
     13 
     14<script> 
     15$(function() { 
     16    $.ajax({ 
     17        url: "[% c.uri_for('/json/timeline', username) %]", 
     18        dataType: "json", 
     19        success: function(data) { 
     20            var t2 = Timeframe("#timeline") 
     21                .start(data.start) 
     22                .end(data.end) 
     23                .majorTicks(5, "years") 
     24                .minorTicks(1, "year"); 
     25            t2.addCategory(data.employments) 
     26            t2.draw(); 
     27        } 
     28    }); 
     29        
     30}); 
     31</script> 
    932 
    1033<div style="height: 150px; overflow-y: auto;"> 
     
    4467[% END %] 
    4568</div> 
     69 
     70[% END %] 
    4671 
    4772[% BLOCK formattr %] 
Note: See TracChangeset for help on using the changeset viewer.