Documentation Source Text

Check-in [ed3480d864]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Improvements to the outcome display in the dashboard app.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | test-dashboard
Files: files | file ages | folders
SHA3-256: ed3480d8647137a8670c6ecf8e44d4ab81342b1d8ed367efaa0f065eb2402a0c
User & Date: drh 2019-08-07 18:00:26.613
Context
2019-08-07
19:23
Minor changes to the dashboard. (check-in: 90a47a80c2 user: drh tags: test-dashboard)
18:00
Improvements to the outcome display in the dashboard app. (check-in: ed3480d864 user: drh tags: test-dashboard)
17:46
The "outcomes" page on the dashboard automatically reloads every 5 minutes. (check-in: 448a7b73d2 user: drh tags: test-dashboard)
Changes
Unified Diff Ignore Whitespace Patch
Changes to misc/dashboard.tcl.
1
2
3
4
5
6
7
8
#!/home/drh/bin/wapptclsh
#
package require wapp
if {![info exists env(FOSSIL_URI)]} {
  error "This script must be run as a Fossil CGI extension"
}
proc open-database {} {
  set self [wapp-param SCRIPT_FILENAME]
|







1
2
3
4
5
6
7
8
#!/usr/bin/wapptclsh
#
package require wapp
if {![info exists env(FOSSIL_URI)]} {
  error "This script must be run as a Fossil CGI extension"
}
proc open-database {} {
  set self [wapp-param SCRIPT_FILENAME]
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
  set cnt [db one {SELECT count(*) FROM outcome}]
  common-header "Test Outcomes" olist
  wapp-subst {<ul>\n}
  set last_srchash {}
  set inner_close {}
  db eval {SELECT status, testName, platform.name AS pname, srchash, srcdate,
                  datetime(srcdate) AS sdate,
                  datetime(max(outcome.mtime),'unixepoch') AS odate
             FROM outcome, platform
            WHERE outcome.mtime>CAST(strftime('%s','now','-1 month') AS INT)
              AND platform.platformId=outcome.platformId
            GROUP BY testName, srchash
            ORDER BY srcdate DESC, outcome.mtime DESC, status DESC} {
     if {$srchash!=$last_srchash} {
       wapp-trim {







|







79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
  set cnt [db one {SELECT count(*) FROM outcome}]
  common-header "Test Outcomes" olist
  wapp-subst {<ul>\n}
  set last_srchash {}
  set inner_close {}
  db eval {SELECT status, testName, platform.name AS pname, srchash, srcdate,
                  datetime(srcdate) AS sdate,
                  datetime(max(outcome.mtime),'unixepoch') AS odate, report
             FROM outcome, platform
            WHERE outcome.mtime>CAST(strftime('%s','now','-1 month') AS INT)
              AND platform.platformId=outcome.platformId
            GROUP BY testName, srchash
            ORDER BY srcdate DESC, outcome.mtime DESC, status DESC} {
     if {$srchash!=$last_srchash} {
       wapp-trim {
104
105
106
107
108
109
110
111

112




113
114
115
116
117
118
119
       fail {set clr red}
       running {set clr gray}
       ok -
       pass {set clr green}
     }
     wapp-trim {
       <li><span style='color:%html($clr);'>
       %html($status - $testName at $pname on $odate)</span></li>

     }




  }
  wapp-trim {
    %unsafe($inner_close)
    </ul>
  }
  wapp-trim {
    <script nonce='%html([wapp-param FOSSIL_NONCE])'>







|
>

>
>
>
>







104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
       fail {set clr red}
       running {set clr gray}
       ok -
       pass {set clr green}
     }
     wapp-trim {
       <li><span style='color:%html($clr);'>
       <b>%html($status)</b> - %html($testName at $pname)
       <small>(%html($odate))
     }
     if {[string length $report]} {
       wapp-trim {- %html($report)}
     }
     wapp-trim {</small></span></li>}
  }
  wapp-trim {
    %unsafe($inner_close)
    </ul>
  }
  wapp-trim {
    <script nonce='%html([wapp-param FOSSIL_NONCE])'>