Changeset 38134 for gs3-installations


Ignore:
Timestamp:
2023-09-14T23:43:22+12:00 (9 months ago)
Author:
davidb
Message:

About page generates tabletop XML when mode=tabletop and cl=CL4

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gs3-installations/computing50/trunk/sites/computing50/collect/computing-50-tabletop/transform/pages/about.xsl

    r38131 r38134  
    3131 
    3232  <xsl:template name="coll-description">
     33    <gsf:script src="{$library_name}/sites/{$site_name}/collect/{$collName}/script/gs2tabletop.js" />
     34   
    3335    <xsl:apply-templates select="pageResponse/collection"/>
    3436
    35     <gsf:div id="tabletop-collections-xml" />
    36 
     37    <pre id="tabletop-collections-xml" />   
    3738    <gsf:script>
    38       var cl2_url = gs.xsltParams.library_name + "/collection/" + gs.cgiParams.c + "/browse/CL4";
    39 
    40       $.ajax({
    41         url: cl2_url,
    42         data: { "o": "json" }
    43       }).done(function(data) {
    44         var classifier_response = data.page.pageResponse.classifier;
    45         //console.log(classifier_response);
    46 
    47     var classifier_node = classifier_response.classifierNode;
    48     for (var i=0; i&lt;classifier_node.length; i++) {
    49       var classifier_child = classifier_node[i];
    50       console.log(classifier_child);
    51       var title = classifier_child.metadataList.metadata.content;
    52       $('#tabletop-collections-xml').append('&lt;pre&gt;'+title+'&lt;/pre&gt;');
     39      $(document).ready(function() {
     40        if (gs.cgiParams.mode == "tabletop") {
     41          if (gs.cgiParams.cl == "CL4") {
     42            tabletopCL4ToCool_Stuff("tabletop-collections-xml");
     43      }
    5344    }
    5445      });
    55      
    5646    </gsf:script>
     47
    5748
    5849    <xsl:apply-templates select="serviceCluster"/>
Note: See TracChangeset for help on using the changeset viewer.