diff options
author | Ted Trask <ttrask01@yahoo.com> | 2012-04-18 01:26:11 +0000 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2012-04-18 01:26:11 +0000 |
commit | 49feb0b0d13aa92399f54fb48aef428d05527d15 (patch) | |
tree | 57c71c593528281c1ef9b798aa2bf03e59d8a860 /kamailio-controller.lua | |
parent | e19ee215667692e70cb4788dca4151e23aa73b96 (diff) | |
download | acf-kamailio-49feb0b0d13aa92399f54fb48aef428d05527d15.tar.bz2 acf-kamailio-49feb0b0d13aa92399f54fb48aef428d05527d15.tar.xz |
Started work on updating for acf-core-0.15
Removed controllerfunctions library (still needs more work and corresponding work in model)
Updated startstop functionality and deleted view
Updated for viewfunctions to htmlviewfunctions and modified require statements for acf libraries
Diffstat (limited to 'kamailio-controller.lua')
-rw-r--r-- | kamailio-controller.lua | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/kamailio-controller.lua b/kamailio-controller.lua index 8cd66ac..5a8b613 100644 --- a/kamailio-controller.lua +++ b/kamailio-controller.lua @@ -1,8 +1,5 @@ module(..., package.seeall) --- Load libraries -require("controllerfunctions") - default_action = "status" function status(self) @@ -10,7 +7,7 @@ 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 listfiles(self) @@ -18,7 +15,7 @@ function listfiles(self) end function edit(self) - return controllerfunctions.handle_form(self, function() return self.model.get_filedetails(self.clientdata.filename) end, self.model.update_filedetails, self.clientdata, "Save", "Edit File", "File Saved") + return self.handle_form(self, function() return self.model.get_filedetails(self.clientdata.filename) end, self.model.update_filedetails, self.clientdata, "Save", "Edit File", "File Saved") end function listusers(self) @@ -26,7 +23,7 @@ function listusers(self) end function createuser(self) - return controllerfunctions.handle_form(self, self.model.get_new_user, self.model.create_new_user, self.clientdata, "Create", "Create New User") + return self.handle_form(self, self.model.get_new_user, self.model.create_new_user, self.clientdata, "Create", "Create New User") end function deleteuser(self) @@ -34,7 +31,7 @@ function deleteuser(self) end function updateuser(self) - return controllerfunctions.handle_form(self, function() return self.model.get_user(self.clientdata.username) end, self.model.update_user, self.clientdata, "Update", "Update User") + return self.handle_form(self, function() return self.model.get_user(self.clientdata.username) end, self.model.update_user, self.clientdata, "Update", "Update User") end function listtables(self) @@ -50,11 +47,11 @@ function deletetableentry(self) end function updatetableentry(self) - return controllerfunctions.handle_form(self, function() return self.model.get_table_entry(self.clientdata.table, self.clientdata.id) end, self.model.update_table_entry, self.clientdata, "Update", "Update Table Entry", "Entry updated") + return self.handle_form(self, function() return self.model.get_table_entry(self.clientdata.table, self.clientdata.id) end, self.model.update_table_entry, self.clientdata, "Update", "Update Table Entry", "Entry updated") end function createtableentry(self) - return controllerfunctions.handle_form(self, function() return self.model.get_table_entry(self.clientdata.table) end, self.model.create_table_entry, self.clientdata, "Create", "Create New Table Entry", "Entry created") + return self.handle_form(self, function() return self.model.get_table_entry(self.clientdata.table) end, self.model.create_table_entry, self.clientdata, "Create", "Create New Table Entry", "Entry created") end function createdatabase(self) |