Documentation Source Text

Check-in [90a47a80c2]
Login

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

Overview
Comment:Minor changes to the dashboard.
Downloads: Tarball | ZIP archive
Timelines: family | ancestors | descendants | both | test-dashboard
Files: files | file ages | folders
SHA3-256: 90a47a80c2dad46d353779d15d04a345bdc3c589df3f639e09271d3f066a723f
User & Date: drh 2019-08-07 19:23:28.972
Context
2019-08-12
10:27
Minor improvements to dashboard. (Closed-Leaf check-in: 44eb5d574e user: drh tags: test-dashboard)
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)
Changes
Unified Diff Ignore Whitespace Patch
Changes to misc/dashboard.tcl.
35
36
37
38
39
40
41




42
43
44
45
46
47
48
      ostype TEXT,                 -- 'linux','windows','mac','sparc'
      os TEXT,                     -- ex: 'Ubuntu 18.04', 'Windows 10'
      owner TEXT,                  -- ex: 'drh'
      location TEXT,               -- ex: 'Charlotte, NC'
      description TEXT             -- ex: 'Yoga laptop'
    );
  }




}
proc common-header {{title {Test Dashboard}} {exlist {}} {newlist {}}} {
  wapp-trim {
     <div class='fossil-doc' data-title='%html($title)'>
     <div class='submenu'>
  }
  set base [wapp-param BASE_URL]







>
>
>
>







35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
      ostype TEXT,                 -- 'linux','windows','mac','sparc'
      os TEXT,                     -- ex: 'Ubuntu 18.04', 'Windows 10'
      owner TEXT,                  -- ex: 'drh'
      location TEXT,               -- ex: 'Charlotte, NC'
      description TEXT             -- ex: 'Yoga laptop'
    );
  }
  if {[db one {PRAGMA journal_mode}]!="wal"} {
    db eval {PRAGMA journal_mode=WAL}
  }
  db timeout 5000
}
proc common-header {{title {Test Dashboard}} {exlist {}} {newlist {}}} {
  wapp-trim {
     <div class='fossil-doc' data-title='%html($title)'>
     <div class='submenu'>
  }
  set base [wapp-param BASE_URL]
72
73
74
75
76
77
78
79
80




81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
  common-footer
}

# Show a list of test outcomes
#
proc wapp-page-olist {} {
  open-database
  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 {
         %unsafe($inner_close)
         <li><a href='https://sqlite.org/src/timeline?c=%html($srchash)'>
         %html%($sdate)% %html%([string range $srchash 0 16])%</a>
         <ol>







<

>
>
>
>









|







76
77
78
79
80
81
82

83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
  common-footer
}

# Show a list of test outcomes
#
proc wapp-page-olist {} {
  open-database

  common-header "Test Outcomes" olist
  set now [db one {SELECT datetime('now')}]
  wapp-trim {
    <p>Test Outcomes As Of %html($now)</p>
  }
  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, outcome.platformId
            ORDER BY srcdate DESC, outcome.mtime DESC, status DESC} {
     if {$srchash!=$last_srchash} {
       wapp-trim {
         %unsafe($inner_close)
         <li><a href='https://sqlite.org/src/timeline?c=%html($srchash)'>
         %html%($sdate)% %html%([string range $srchash 0 16])%</a>
         <ol>
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
  }
  wapp-trim {
    %unsafe($inner_close)
    </ul>
  }
  wapp-trim {
    <script nonce='%html([wapp-param FOSSIL_NONCE])'>
      setTimer(function(){location.reload();},1000*60*5);
    </script>
  }
  common-footer
}

# Make sure the Fossil user has the listed capability.
# Return 0 on success.  If the capability is missing,







|







125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
  }
  wapp-trim {
    %unsafe($inner_close)
    </ul>
  }
  wapp-trim {
    <script nonce='%html([wapp-param FOSSIL_NONCE])'>
      setTimeout(function(){location.reload();},1000*60);
    </script>
  }
  common-footer
}

# Make sure the Fossil user has the listed capability.
# Return 0 on success.  If the capability is missing,