module (..., package.seeall) -- Load libraries require("controllerfunctions") -- ################################################################################ -- PUBLIC FUNCTIONS default_action = "status" function config(self) return controllerfunctions.handle_form(self, self.model.read_config, self.model.update_config, self.clientdata, "Save", "Edit OpenNTPD Config", "OpenNTPD Configuration Saved") end function status (self) return self.model.getstatus() end function details (self) return self.model.getstatusdetails() end function expert (self) return controllerfunctions.handle_form(self, self.model.get_filedetails, self.model.update_filedetails, self.clientdata, "Save", "Edit Config", "Configuration Set") end function startstop(self) return controllerfunctions.handle_startstop(self, self.model.startstop_service, self.model.getstatus, self.clientdata) end