Changeset 34893


Ignore:
Timestamp:
2021-02-16T23:43:20+13:00 (3 years ago)
Author:
davidb
Message:

Voting totals added in

Location:
main/trunk/model-sites-dev/eurovision-lod/collect/eurovision
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • main/trunk/model-sites-dev/eurovision-lod/collect/eurovision/etc/collectionConfig.xml

    r34877 r34893  
    144144    </format>
    145145  </search>
    146 
     146<!--
    147147  <search type="jenaTDB" orthogonal="true"/>
    148  
     148--> 
    149149
    150150  <infodb type="jdbm"/>
     
    453453    <gsf:metadata name="JuryVotesJSON" />
    454454    <gsf:metadata name="TeleVotesJSON" />
    455    
     455    <gsf:metadata name="JuryVotesTotal" />
     456    <gsf:metadata name="TeleVotesTotal" />
     457
    456458    <gsf:metadata name="Albania-J" />
    457459    <gsf:metadata name="Andorra-J" />
  • main/trunk/model-sites-dev/eurovision-lod/collect/eurovision/js/eurovision.js

    r34873 r34893  
    11
    2 function append_from_country_votes(vote_label, votes_json_type)
     2function append_from_country_votes(vote_label, votes_json_type, votes_type_total)
    33{
    44    // TODO
     
    77    if (gs.documentMetadata[votes_json_type]) {
    88    var $vote_div = $('<div>').attr("class","voting-label").append(vote_label);
     9    $vote_div.append(" (Total: " + gs.documentMetadata[votes_type_total] + ")");
    910    $('#from-country-votes').append($vote_div);
    1011   
  • main/trunk/model-sites-dev/eurovision-lod/collect/eurovision/prepare/voting-excel/xlsx-to-jsonmetadata.py

    r34891 r34893  
    5656    #
    5757    # for data_hashmap in data_hashmap_array_finals:
    58     #    print data_hashmap.get('To country'), data_hashmap.get('Year'), data_hashmap.get('Points'), "(Points from " + data_hashmap.get('From country') + ")"
     58    #    print(data_hashmap.get('To country'), data_hashmap.get('Year'), data_hashmap.get('Points'), "(Points from " + data_hashmap.get('From country') + ")")
    5959
    6060
     
    191191    # Debug output
    192192    #
    193     # print to_country_year_voting_groups
    194    
    195     # Next step is to express the grouped by-country voting data
     193    # print(to_country_year_voting_groups)
     194   
     195    # Next step is to express the grouped to-country voting data
    196196    # in the Greenstone JSON metadata format:
    197197   
  • main/trunk/model-sites-dev/eurovision-lod/collect/eurovision/transform/pages/document.xsl

    r34874 r34893  
    132132    <div id="from-country-votes">
    133133      <gsf:script>
    134     append_from_country_votes("Jury Votes","JuryVotesJSON");
    135     append_from_country_votes("Televotes","TeleVotesJSON");
     134    append_from_country_votes("Jury Votes","JuryVotesJSON","JuryVotesTotal");
     135    append_from_country_votes("Televotes","TeleVotesJSON","TeleVotesTotal");
    136136      </gsf:script>
    137137
Note: See TracChangeset for help on using the changeset viewer.