X-Git-Url: http://jsfdemo.indexdata.com/?a=blobdiff_plain;ds=inline;f=www%2Fsearch.egw;h=eabe4b9344aa2b75185065f9c40d5636e6348149;hb=3871eda3b3a1518d4d18c1ffc0ed0375cb88bdf5;hp=45589ac97cef816e49128b2a3296e1e90d920332;hpb=cc5af6a5323f9576c208519dbf4351b4f818e166;p=egate.git diff --git a/www/search.egw b/www/search.egw index 45589ac..eabe4b9 100644 --- a/www/search.egw +++ b/www/search.egw @@ -1,8 +1,8 @@ { -# $Id: search.egw,v 1.26 1996/01/09 16:16:48 adam Exp $ +# $Id: search.egw,v 1.32 1996/02/12 13:39:40 adam Exp $ -proc start-scan {scanNo cache dir} { +proc start-scan {scanNo cache dir initSet} { global sessionId global sessionParms global sessionWait @@ -16,15 +16,13 @@ proc start-scan {scanNo cache dir} { set host $hist($setNo,host) - html "
\n" + html "
\n" display-scan $setNo $scanNo 0 html "
\n"
@@ -94,10 +157,10 @@ proc start-scan {scanNo cache dir} {
foreach e {SERVER_NAME PATH_INFO SCRIPT_NAME} {
html $e {: } $env($e) {
} \n
}
- html "form: " [wform] "
\n"
+ html "form: " [egw_form] "
\n"
html "target: " $host "
\n"
html "databases: " $hist($setNo,database) "
\n"
- html "selected: " [wform base] "
\n"
+ html "selected: " [egw_form base] "
\n"
html "setNo: " $setNo "
\n"
html "nextSetNo: " $nextSetNo "
\n"
}
@@ -110,7 +173,7 @@ proc buttons {setNo setMax startPos after} {
html "
\n"
button-europagate
- if {$setMax < [z39.$setNo resultCount]} {
+ if {$setMax > 0 && $setMax < [z39.$setNo resultCount]} {
html {Next Records} " | \n"
}
}
- if {$startPos != "" && $startPos != "1"} {
+ if {$setMax > 0 && $startPos != "" && $startPos != "1"} {
html {\n"
- wabort
- return
+ set i [lindex $sessionParms 1]
+ if {$i == ""} {
+ for {set j 1} {$j <= 3} {incr j} {
+ if {[egw_form scan$j] != ""} {
+ set i $j
+ break
+ }
}
}
+ if {$i != ""} {
+ set scanNo 1000
+ set hist($setNo,scan) $i
+ set termPlusAttr [build-scan $hist($setNo,host) $i]
+ set hist($setNo,$scanNo,scanTerm) [lindex $termPlusAttr 0]
+ set hist($setNo,scanAttr) [lindex $termPlusAttr 1]
+ start-scan $scanNo 0 {} $setNo
+ html "\n"
+ egw_abort
+ return
+ }
set query [build-query $hist($setNo,host) 3]
if {"x$query" == "x"} {
html "