Ignore:
Timestamp:
01/02/11 19:30:58 (13 years ago)
Author:
vronk
Message:

changes to columns, terms (unfinished) ; .ui-context-dialog

Location:
MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/action/Cache.java

    r980 r1029  
    172172                }
    173173               
    174                 DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-ddThh:mm:ss");
     174                DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd hh:mm:ss");
    175175                e.setAttribute("date", dateFormat.format(new Date()).toString());
    176176                cacheindex_doc.getFirstChild().appendChild(e);
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/action/CollectionProxyAction.java

    r862 r1029  
    3434                //targetURL =new URL( getBaseURL(), getActionkey());
    3535                //FIXME: get maxdepth-constant out of here !!
    36                 targetURL = new URL(getBaseURL(), "?operation=getCollections&maxdepth=3&collection=");
     36                targetURL = new URL(getBaseURL(), "?operation=getCollections&maxdepth=2&collection=");
    3737                //Admin.notifyUser("CollectionProxy.targetURL:" + targetURL);
    3838
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/action/GenericProxyAction.java

    r980 r1029  
    5656        private int maxdepth;
    5757        private String format;
     58        private String options;
    5859        private String actionContentType;
    5960        private String userMsg;
     
    142143        }
    143144
     145        public String getOptions() {
     146                return options;
     147        }
     148
     149        public void setOptions(String options) {
     150                this.options = options;
     151        }
     152
    144153        public String getActionContentType() {
    145                 if (format.toLowerCase().equals("xml")) {
     154                if (format.toLowerCase().startsWith("html")) {
     155                        this.actionContentType = "text/html";
     156                } else {
    146157                        this.actionContentType = "text/xml";
    147                 } else {
    148                         this.actionContentType = "text/html";
    149158                }
    150159               
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/action/MDRepoProxyAction.java

    r890 r1029  
    115115                        query.setMaximumRecords(getMaximumRecords());
    116116                        query.setStartRecord(getStartRecord());
     117                        query.setOptions(getOptions());
    117118                        //Admin.notifyUser("MDRPA.records:" + query.getStartRecord());
    118119                        //Admin.notifyUser("MDRPA.records:" + query.getMaximumRecords());
     
    120121                       
    121122                        targetURL =new URL( getBaseURL(), urls.get(getActionkey()) + query.toURLParam() );
     123                        Admin.notifyUser("MDRPA.targetURL.query.toURLParam:" + query.toURLParam());
    122124                        Admin.notifyUser("MDRPA.targetURL:" + targetURL);
    123125                return targetURL;
  • MDService2/trunk/MDService2/src/eu/clarin/cmdi/mdservice/model/Query.java

    r911 r1029  
    5858        private String maximumRecords = "50";
    5959        private String squery = null;
     60        private String options = null;
    6061        private int maxdepth=1;
    6162       
     
    199200        }
    200201       
     202        public String getOptions() {
     203                return options;
     204        }
     205
     206        public void setOptions(String options) {
     207                this.options = options;
     208        }
     209
    201210        public String getStartRecord() {
    202211                return startRecord;
     
    312321                        //  2010-07-11 this is just a hack, because url-encoding the handle acted strange
    313322                        //String corrid = getQueryString().replace('_', '/');
    314                         String corrid = getQueryString();
    315                         targetRequest = "//MdSelfLink[.='" + corrid + "']";                     
     323                        //  2010-12-28 needed for the lucene-index to recognize..
     324                                //  probably not the best place to handle -> move to repository: sanitize-query?
     325                        String corrid = getQueryString().replace(":","\\:").toLowerCase();
     326                        Admin.notifyUser("Query.toURLParam.corrid=" + corrid);
     327                        targetRequest = "//MdSelfLink[ft:query(.,'" + corrid + "')]";                   
    316328                } else {
    317329                        if (query_cql == null){
     
    322334                        if ((startRecord != null) && (maximumRecords != null)) {
    323335                                targetRequest = targetRequest +  "&startRecord=" + getStartRecord() + "&iend=" + getMaximumRecords();
     336                        }
     337                        if ((options != null)) {
     338                                targetRequest = targetRequest +  "&format=xml-" + getOptions();
    324339                        }
    325340                }
Note: See TracChangeset for help on using the changeset viewer.