From 0a0ca2621d63d04a64004616c13253826c187e1d Mon Sep 17 00:00:00 2001 From: Mika Havela Date: Fri, 4 Apr 2008 13:28:55 +0000 Subject: Show config errors in expert-tab. git-svn-id: svn://svn.alpinelinux.org/acf/ipsec-tools/trunk@926 ab2d0c66-481e-0410-8bed-d214d4d58bed --- ipsectools-controller.lua | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) (limited to 'ipsectools-controller.lua') diff --git a/ipsectools-controller.lua b/ipsectools-controller.lua index 6d3fb3c..ba0f667 100644 --- a/ipsectools-controller.lua +++ b/ipsectools-controller.lua @@ -52,12 +52,9 @@ end expert = function (self) local modifications = self.clientdata.filecontent or "" + local modifications2 = self.clientdata.filecontent2 or "" if ( self.clientdata.cmdsave ) then modifications = self.model:update_filecontent(modifications) - end - - local modifications2 = self.clientdata.filecontent2 or "" - if ( self.clientdata.cmdsave2 ) then modifications2 = self.model:update_filecontent2(modifications2) end @@ -79,6 +76,7 @@ expert = function (self) local status=self.model.getstatus() local file = self.model:get_filedetails() + local file2 = self.model:get_filedetails("2") -- Add buttons file.cmdsave = cfe ({ @@ -91,18 +89,6 @@ expert = function (self) file.cmdsave.descr="* Changes has been saved!" end - -- Add buttons - file.cmdsave2 = cfe ({ - name="cmdsave2", - label="Apply settings", - value="Apply", - type="submit", - }) - if (self.clientdata.cmdsave2) then - file.cmdsave2.descr="* Changes has been saved!" - end - - -- Management buttons local disablestart,disablestop,disablerestart -- Disable management buttons based on if the process is running or not @@ -117,6 +103,7 @@ expert = function (self) return ( { status = status, file = file, + file2 = file2, modifications = modifications, management = management, cmdmanagement = cmdmanagement, -- cgit v1.2.3