Changeset 1033


Ignore:
Timestamp:
01/04/11 10:23:16 (13 years ago)
Author:
vronk
Message:

mini-fix on withSummary, fixes on model/htmlpage, terms/htmlpage

Location:
MDService2/trunk/MDService2
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • MDService2/trunk/MDService2/WebContent/index.jsp

    r1032 r1033  
    116116                <div id="query-input" class="content">         
    117117                         <s:form action="searchretrieve">
    118                                 <!-- <label id="toggle_inputmode_cmd"  value="TEXT" />-->                                                              
     118                                <!-- <label id="toggle_inputmode_cmd"  value="TEXT" />-->                                                       
    119119                                <input type="text" id="input-simplequery" name="_query"  />
    120                                 <input type="submit"  value="submit" id="submit-query"/>
    121                                 <input type="checkbox" checked="false" id="input-withsumary" name="WS"/>
     120                                <input type="submit"  value="submit" id="submit-query"/>                               
    122121                                <input type="text" id="query_list" name="_query_" />   
    123122                                <table class="cmds-ui-elem-stretch"><tr>
     
    138137                                        <!-- <textarea id="columns_list" class="cmds-ui-elem-stretch"></textarea>
    139138                                         -->   
    140                                 </td>                   
     139                                </td>           
     140                                <td><input type="checkbox" checked="false" id="input-withsummary" name="WS"/><label>with Summary</label></td>       
    141141                                </tr></table>           
    142142                        </s:form>
  • MDService2/trunk/MDService2/WebContent/scripts/mdservice2_ui.js

    r1032 r1033  
    115115        q.repository = getSelectedRepository();
    116116        if (ws) {
    117                 q.options = "withSumary";
     117                q.options = "withSummary";
    118118        }
    119119        notifyUser("submit_query:" + q.query_uri(),'debug');
     
    11311131                        notifyUser(searchclauseset.sctext,'debug');
    11321132                        //submit_query ($('#columns_list').attr("value"),searchclauseset.sctext, $('#input-simplequery').attr("value"));                       
    1133                         submit_query (columns_widget.getColumnsListText(),searchclauseset.sctext, $('#input-simplequery').attr("value"), $('#input-withsumary').attr("checked"));
     1133                        submit_query (columns_widget.getColumnsListText(),searchclauseset.sctext, $('#input-simplequery').attr("value"), $('#input-withsummary').attr("checked"));
    11341134        });
    11351135
     
    14591459                columns_widget.load(query.columns.split(','));
    14601460                $('#input-simplequery').attr("value",query.squery);
    1461                 $('#input-withsumary').attr("checked",(query.options != null));
     1461                $('#input-withsummary').attr("checked",(query.options != null));
    14621462        }
    14631463
  • MDService2/trunk/MDService2/WebContent/scripts/mdservice_model.js

    r1032 r1033  
    100100        params = params + "collection=" + this.getcollectiontext("index") + "&columns=" + this.getcolumnstext() + "&startRecord=" + this.startRecord + "&maximumRecords=" + this.maximumRecords + "&repository=" + this.repository;
    101101        if  (this.options != null) {
    102                 params = params + "&options=withSumary";
     102                params = params + "&options=withSummary";
    103103        }
    104104        return params;
  • MDService2/trunk/MDService2/WebContent/style/cmds-ui.css

    r1029 r1033  
    140140.cmd_filter { background-image: url("imgs/cdb-icon-filter.png"); }
    141141.cmd_get { background-image: url("imgs/icon_get.gif");}
     142.cmd-info { background-image: url("imgs/cdb-icon-info.png");}
    142143.cmd_load {     background-image: url("imgs/cdb-icon-load.png");}
    143144.cmd_reload {   background-image: url("imgs/cdb-icon-load.png");}
  • MDService2/trunk/MDService2/docs/MDService2.wadl

    r885 r1033  
    2828                                        <param name="repository" type="xs:int" style="matrix" default="1">
    2929                                                <doc>allows to dynamically select one of the available repositories for the queries.<br/>
    30                                                                 Probably this should be rather a semantic identifier
     30                                                                Probably this should be rather a semantic identifier (a string-key instead of int)
    3131                                                        </doc>
    3232          </param>                   
     
    238238        </resource>
    239239       
     240                </resources>
     241               
     242    <resources base="http://cmdi.clarin.eu/mdservice/admin/">
     243       
     244        <resource id="cache" path="cache/{format}">
     245                <doc title="Cache" >
     246                                                Allows to view the cache-index
     247                                        </doc>
     248            <method name="GET">
     249                <request>                               
     250                        <param name="format" type="xs:string" style="template" default="public" >
     251                                        <option value="xml" />
     252                                        <option value="htmlpage" />
     253                                </param>
     254                </request>
     255                <response>
     256                                <representation mediaType="text/html">                       
     257                    </representation>                   
     258                </response>
     259            </method>
     260                <resource id="cache-del" path="del">
     261                        <doc title="Cache" >
     262                                                        Allows to delete/flush (parts of) cache; parameters constraint the part of cache to be deleted;
     263                                                        no param means: delete everything
     264                                                </doc>
     265                    <method name="GET">
     266                        <request>                               
     267                                <param name="actionkey" type="xs:string" style="query" default="public" optional="yes"></param>                                     
     268                                <param name="repository" type="xs:int" style="query" default="public" optional="yes"></param>                                     
     269                                <param name="date" type="xs:date" style="query" default="public" optional="yes"></param>                                     
     270                        </request>
     271                        <response>
     272                                        <representation mediaType="text/html"></representation>                   
     273                        </response>
     274                    </method>
     275                </resource>       
     276        </resource>
     277       
     278
    240279    </resources>
    241280   
  • MDService2/trunk/MDService2/src/xsl/cmd_functions.xsl

    r1029 r1033  
    154154                <xsl:param name="url" />
    155155                <!--   <xsl:value-of select="replace($url, 'http://www.isocat.org/datcat/','isocat:')" /> -->
    156                 <xsl:variable name="matching_termset"  select="$terms_setup/Termsets/Termset[starts-with($url,@url_prefix)]" />
     156                <xsl:variable name="matching_termset"  select="if($url!='') then $terms_setup/Termsets/Termset[@url_prefix][starts-with($url,@url_prefix)] else ()" />
    157157                 <xsl:message>shortURL: <xsl:copy-of select="$matching_termset" />:: <xsl:value-of select="$matching_termset[1]/@url_prefix" />
    158                                 <xsl:copy-of select="$url" />
     158                                <xsl:value-of select="$url" />
    159159                </xsl:message>                 
    160160                <xsl:value-of select="if ($matching_termset/@url_prefix and $matching_termset/@url_prefix!='' and $url!='') then replace($url, $matching_termset[1]/@url_prefix, concat(string-join($matching_termset/@id,','),':')) else $url" />             
  • MDService2/trunk/MDService2/src/xsl/model2view.xsl

    r765 r1033  
    206206                                        </xsl:when>
    207207                                        <xsl:otherwise>
    208                                         <!--  testwise: show only non empty Terms-->
    209                                                 <xsl:apply-templates select="Term[@count_distinct_text &gt; 1]" mode="detail">
     208                                        <!--  testwise: show only non empty Terms, no good, because only leaf-elements have filled @count_distinct_text
     209                                                <xsl:apply-templates select="Term[@count_distinct_text &gt; 1]" mode="detail"> -->
     210                                                <xsl:apply-templates select="Term" mode="detail">
    210211                                                        <xsl:with-param name="parentid" select="$xid" />                                                               
    211212                                                </xsl:apply-templates>         
  • MDService2/trunk/MDService2/src/xsl/terms2view.xsl

    r1029 r1033  
    1515<xsl:import href="cmd_commons.xsl"/>
    1616
    17 <xsl:output method="xml" /
     17<!--  <xsl:output method="xml" />  --
    1818
    1919<!-- <xsl:param name="size_lowerbound">0</xsl:param>
     
    197197                                        <xsl:otherwise>
    198198                                        <!--  testwise: show only non empty Terms-->
    199                                                 <xsl:apply-templates select="Term[@count_distinct_text &gt; 1]" mode="detail">
     199                                                <xsl:apply-templates select="Term" mode="detail">
    200200                                                        <xsl:with-param name="parentid" select="$xid" />                                                               
    201201                                                </xsl:apply-templates>         
     
    349349        <script type="text/javascript" >
    350350                $(function(){
    351                         $("#modeltree").treeTable({initialState:"expanded"});
     351                        $(".terms-tree").treeTable({initialState:"expanded"});
    352352                });
    353353        </script>
Note: See TracChangeset for help on using the changeset viewer.