From fb7ce759c1045daf20e416547e6111f796030b60 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Thu, 17 Apr 2014 00:55:44 +0000 Subject: Started changes to use new htmlviewfunctions functions Still work to do to remove styling and long messy links --- weblog-status-html.lsp | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'weblog-status-html.lsp') diff --git a/weblog-status-html.lsp b/weblog-status-html.lsp index 2eb2fb5..56f0ff9 100644 --- a/weblog-status-html.lsp +++ b/weblog-status-html.lsp @@ -4,7 +4,7 @@ htmlviewfunctions = require("htmlviewfunctions") <% htmlviewfunctions.displaycommandresults({"createdatabase"}, session, true) %> -

Weblog Database Status

+<% local header_level = htmlviewfunctions.displaysectionstart(cfe({label="Weblog Database Status"}), page_info) %> <% local status if viewlibrary and viewlibrary.dispatch_component then if viewlibrary.check_permission("postgresql/postgresql/status") then @@ -12,27 +12,27 @@ if viewlibrary and viewlibrary.dispatch_component then end end %> -

Database status

-

-<% if status then %> -<% if status.value.status.errtxt then - print(status.value.status.errtxt) +<% +local statuscfe = cfe({ label="Database status" }) +if status then + statuscfe.value = status.value.status.errtxt or status.value.status.value else - print(status.value.status.value) -end %> -<% else %> -Unknown -<% end %> -

+ statuscfe.value = "Unknown" +end +htmlviewfunctions.displayitem(statuscfe) +%> + +<% +local databasecfe = cfe({ label="Weblog Database" }) +if data.value then + databasecfe.value = "Present" +else + databasecfe.value = "Missing" +end +htmlviewfunctions.displayitem(databasecfe) +%> -

Weblog Database

-

-<% if data.value then %> -Present -<% else %> -Missing -<% end %> -

+<% htmlviewfunctions.displaysectionend(header_level) %> <% if not data.value and viewlibrary and viewlibrary.dispatch_component then viewlibrary.dispatch_component("createdatabase") -- cgit v1.2.3