X-Git-Url: http://git.indexdata.com/?a=blobdiff_plain;f=www%2Fsearch.egw;h=9263dfa57c03127a6c79f0bedd1d08b9f14f0fd7;hb=25db261b6bbbfcc7bc26f679f195b51d31b9d7d7;hp=08e0aa107023b85dda38d7033cb658d35db098d7;hpb=94e0e8ff10cdb5142f983cd76156310461f9eb89;p=egate.git diff --git a/www/search.egw b/www/search.egw index 08e0aa1..9263dfa 100644 --- a/www/search.egw +++ b/www/search.egw @@ -1,6 +1,207 @@ { -# $Id: search.egw,v 1.8 1995/11/06 17:44:21 adam Exp $ +# $Id: search.egw,v 1.33 1996/02/29 15:41:39 adam Exp $ + +proc start-scan {scanNo cache dir initSet} { + global sessionId + global sessionParms + global sessionWait + global setNo + global hist + global targets + global nextSetNo + global env + global useIcons + global debug + + set host $hist($setNo,host) + + html "
\n" + display-scan $setNo $scanNo 0 + html "
\n"
+
+ button-europagate
+
+ html {}
+ if {$useIcons} {
+ html {}
+ } else {
+ html {Previous Terms | }
+ }
+
+ html {}
+ if {$useIcons} {
+ html {
}
+ } else {
+ html {Next Terms | }
+ }
+ html {}
+ button-new-query 0 $setNo
+
+ if {!$debug} return
+ html "
\n"
+ button-europagate
+ if {$setMax > 0 && $setMax < [z39.$setNo resultCount]} {
+ html {}
+ } else {
+ html {">Next Records} " | \n"
+ }
+ }
+ if {$setMax > 0 && $startPos != "" && $startPos != "1"} {
+ html {
}
+ } else {
+ html {">Previous Records} " | \n"
+ }
+ }
+ button-new-query 1 $setNo
+ button-new-target 1
+ button-view-history 0
+
+ html "
\n"
+}
if {[info commands saveState] == ""} {
source z39util.tcl
@@ -10,107 +211,189 @@
global setNo
global hist
- set oldHost $hist($setNo,host)
+ set setNo [lindex $sessionParms 0]
+ set startPos [lindex $sessionParms 1]
+ set endPos [lindex $sessionParms 2]
+
+ if {[egw_form] != ""} {
+ set hist($nextSetNo,idAuthentication) $hist($setNo,idAuthentication)
+ set hist($nextSetNo,host) $hist($setNo,host)
- if {[wform menu1] == ""} {
- set setNo [lindex $sessionParms 0]
- } else {
- if {![info exists hist($nextSetNo,host)]} {
- set hist($nextSetNo,host) $oldHost
+ if {$nextSetNo == $setNo} {
+ set setNo $nextSetNo
+ incr nextSetNo
+ } else {
+ catch {unset hist($setNo,hits)}
}
- set setNo $nextSetNo
- html "using host " $hist($setNo,host) "
\n"
+ egw_abort
+ return
+ }
+ set query [build-query $hist($setNo,host) 3]
+ if {"x$query" == "x"} {
+ html "