cookutils rev 1065

lighttpd/index.cgi: return webstat note back
author Aleksej Bobylev <al.bobylev@gmail.com>
date Wed Jun 06 00:32:43 2018 +0300 (2018-06-06)
parents 0af059297232
children c69daec36de2
files lighttpd/index.cgi
line diff
     1.1 --- a/lighttpd/index.cgi	Wed Jun 06 00:00:22 2018 +0300
     1.2 +++ b/lighttpd/index.cgi	Wed Jun 06 00:32:43 2018 +0300
     1.3 @@ -846,10 +846,6 @@
     1.4  # Note, $webstat file must be owned by www, otherwise this function will not be able to do the job.
     1.5  
     1.6  update_webstat() {
     1.7 -#	echo '<div id="waitme">'
     1.8 -#	show_note i 'Please wait while statistics are being collected.'
     1.9 -#	echo "</div>"
    1.10 -
    1.11  	# for receipts:
    1.12  	rtotal=$(ls $WOK/*/arch.$ARCH | wc -l)
    1.13  	rcooked=$(ls -d $WOK/*/taz | wc -l)
    1.14 @@ -874,8 +870,6 @@
    1.15  rtotal="$rtotal"; rcooked="$rcooked"; runbuilt="$runbuilt"; rblocked="$rblocked"; rbroken="$rbroken"
    1.16  ptotal="$ptotal"; pcooked="$pcooked"; punbuilt="$punbuilt"; pblocked="$pblocked"; pbroken="$pbroken"
    1.17  EOT
    1.18 -
    1.19 -	echo '<script>document.getElementById("waitme").remove();</script>'
    1.20  }
    1.21  
    1.22  
    1.23 @@ -883,7 +877,16 @@
    1.24  
    1.25  part() {
    1.26  	if [ -z "$nojs" ]; then
    1.27 -		echo "<div id='$1'></div><script>getPart('$1')</script>"
    1.28 +		case $1 in
    1.29 +			webstat)
    1.30 +				echo -n "<div id='$1'>"
    1.31 +				show_note i 'Please wait while statistics are being collected.'
    1.32 +				echo "</div><script>getPart('$1')</script>"
    1.33 +				;;
    1.34 +			*)
    1.35 +				echo "<div id='$1'></div><script>getPart('$1')</script>"
    1.36 +				;;
    1.37 +		esac
    1.38  		return
    1.39  	fi
    1.40