From 80f25c722a6ad2a9fe3932a6a7a1aa63169ddf33 Mon Sep 17 00:00:00 2001 From: Ted Trask Date: Wed, 18 Apr 2012 01:16:30 +0000 Subject: 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 and modified require statements for acf libraries --- fetchmail-controller.lua | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'fetchmail-controller.lua') diff --git a/fetchmail-controller.lua b/fetchmail-controller.lua index 404c05b..c2168f7 100644 --- a/fetchmail-controller.lua +++ b/fetchmail-controller.lua @@ -1,7 +1,5 @@ module(..., package.seeall) -require("controllerfunctions") - default_action = "status" function status(self) @@ -9,15 +7,15 @@ function status(self) end function startstop(self) - return controllerfunctions.handle_startstop(self, self.model.startstop_service, self.clientdata) + return self.handle_form(self, self.model.get_startstop, self.model.startstop_service, self.clientdata) end function editconfig(self) - return controllerfunctions.handle_form(self, self.model.getconfig, self.model.updateconfig, self.clientdata, "Save", "Edit Config", "Configuration Set") + return self.handle_form(self, self.model.getconfig, self.model.updateconfig, self.clientdata, "Save", "Edit Config", "Configuration Set") end function expert(self) - return controllerfunctions.handle_form(self, self.model.get_filedetails, self.model.update_filecontent, self.clientdata, "Save", "Edit Config", "Configuration Set") + return self.handle_form(self, self.model.get_filedetails, self.model.update_filecontent, self.clientdata, "Save", "Edit Config", "Configuration Set") end function listentries(self) @@ -25,11 +23,11 @@ function listentries(self) end function editentry(self) - return controllerfunctions.handle_form(self, function() return self.model.readentry(self.clientdata.entry, self.clientdata.method, self.clientdata.remotemailbox, self.clientdata.localdomain) end, self.model.updateentry, self.clientdata, "Save", "Edit Entry", "Entry Saved") + return self.handle_form(self, function() return self.model.readentry(self.clientdata.entry, self.clientdata.method, self.clientdata.remotemailbox, self.clientdata.localdomain) end, self.model.updateentry, self.clientdata, "Save", "Edit Entry", "Entry Saved") end function createentry(self) - return controllerfunctions.handle_form(self, self.model.readentry, self.model.createentry, self.clientdata, "Create", "Create Entry", "Entry Created") + return self.handle_form(self, self.model.readentry, self.model.createentry, self.clientdata, "Create", "Create Entry", "Entry Created") end function deleteentry(self) -- cgit v1.2.3