From 64ed4dd6998ab8cbfe5b4042e9c91fe86a49c551 Mon Sep 17 00:00:00 2001 From: Mika Havela Date: Fri, 25 Jan 2008 15:42:57 +0000 Subject: Added a expert-tab like in other acf-modules git-svn-id: svn://svn.alpinelinux.org/acf/alpine-conf/trunk@654 ab2d0c66-481e-0410-8bed-d214d4d58bed --- lbu-controller.lua | 14 ++++++++++++++ 1 file changed, 14 insertions(+) (limited to 'lbu-controller.lua') diff --git a/lbu-controller.lua b/lbu-controller.lua index dbe910f..04b729a 100644 --- a/lbu-controller.lua +++ b/lbu-controller.lua @@ -92,4 +92,18 @@ function commit(self) clientdata = self.clientdata, url = url, } ) end +expert = function (self) + local modifications = self.clientdata.modifications or "" + if ( self.clientdata.cmdsave) then + modifications = self.model:update_filecontent(modifications) + end + + local status = self.model.getstatus() + local url = ENV["SCRIPT_NAME"] .. self.conf.prefix .. self.conf.controller + + return { file = self.model:get_filedetails(), + status = status, + clientdata = self.clientdata, + url = url, } +end -- cgit v1.2.3