summaryrefslogtreecommitdiffstats
path: root/modules-controller.lua
blob: dc7735ce6ebb79546b61417bc17eed14180f99b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
-- the interfaces  controller
require("controllerfunctions")

module (..., package.seeall)

default_action = "status"

status = function(self)
	return self.model.read_modules()
end

edit = function(self)
	return controllerfunctions.handle_form(self, self.model.read_file, self.model.write_file, self.clientdata, "Save", "Edit Modules file", "File saved")
end

reload = function(self)
	return self:redirect_to_referrer(self.model.reloadmodules())
end