Commit eda53d1d authored by Ted Trask's avatar Ted Trask

Started work on updating for acf-core-0.15

Removed controllerfunctions library (still needs more work and corresponding work in model)
Updated for viewfunctions to htmlviewfunctions
parent 19a6c8d6
module(..., package.seeall) module(..., package.seeall)
-- Load libraries
require("controllerfunctions")
mvc = {} mvc = {}
mvc.on_load = function(self, parent) mvc.on_load = function(self, parent)
self.model.set_processname(string.match(self.conf.prefix, "[^/]+")) self.model.set_processname(string.match(self.conf.prefix, "[^/]+"))
...@@ -15,7 +12,7 @@ function status(self) ...@@ -15,7 +12,7 @@ function status(self)
end end
function startstop(self) function startstop(self)
return controllerfunctions.handle_form(self, self.model.get_startstop, self.model.startstop_service, self.clientdata) return self.handle_form(self, self.model.get_startstop, self.model.startstop_service, self.clientdata)
end end
function details(self) function details(self)
...@@ -27,5 +24,5 @@ function listfiles(self) ...@@ -27,5 +24,5 @@ function listfiles(self)
end end
function expert(self) function expert(self)
return controllerfunctions.handle_form(self, function() return self.model.getfiledetails(self.clientdata.filename) end, self.model.updatefiledetails, self.clientdata, "Save", "Edit Postgresql File", "File Saved") return self.handle_form(self, function() return self.model.getfiledetails(self.clientdata.filename) end, self.model.updatefiledetails, self.clientdata, "Save", "Edit Postgresql File", "File Saved")
end end
<% local data, viewlibrary = ... <% local data, viewlibrary = ...
require("viewfunctions") require("htmlviewfunctions")
%> %>
<% viewlibrary.dispatch_component("status") %> <% viewlibrary.dispatch_component("status") %>
...@@ -7,6 +7,6 @@ require("viewfunctions") ...@@ -7,6 +7,6 @@ require("viewfunctions")
<H2><%= html.html_escape(data.label) %></H2> <H2><%= html.html_escape(data.label) %></H2>
<DL> <DL>
<% <%
displayitem(data) htmlviewfunctions.displayitem(data)
%> %>
</DL> </DL>
<% local data, viewlibrary, page_info, session = ... <% local data, viewlibrary, page_info, session = ...
require("viewfunctions") require("htmlviewfunctions")
%> %>
<% displaycommandresults({"expert"}, session) %> <% htmlviewfunctions.displaycommandresults({"expert"}, session) %>
<% if viewlibrary and viewlibrary.dispatch_component then <% if viewlibrary and viewlibrary.dispatch_component then
viewlibrary.dispatch_component("status") viewlibrary.dispatch_component("status")
......
<% local data, viewlibrary = ... <% local data, viewlibrary = ...
require("viewfunctions")
%> %>
<% if viewlibrary and viewlibrary.dispatch_component then <% if viewlibrary and viewlibrary.dispatch_component then
......
...@@ -34,7 +34,7 @@ end ...@@ -34,7 +34,7 @@ end
-- ################################################################################ -- ################################################################################
-- PUBLIC FUNCTIONS -- PUBLIC FUNCTIONS
function get_startstop(clientdata) function get_startstop(clientdata)
return modelfunctions.get_startstop(processname) return modelfunctions.get_startstop(processname)
end end
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment