summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--rrdtool-model.lua8
1 files changed, 8 insertions, 0 deletions
diff --git a/rrdtool-model.lua b/rrdtool-model.lua
index e915a4a..98bd807 100644
--- a/rrdtool-model.lua
+++ b/rrdtool-model.lua
@@ -232,6 +232,14 @@ function getgraphfile(path)
path = nil
end
local filedetails = modelfunctions.getfiledetails(path)
+ -- If we create a new file, we want to help the user to know what variables he should use
+ if not (path) then
+ filedetails.value.filecontent.value = [[label=Example name for this graph
+group=General
+descr=Some describing text that helps the user to know what this graph is all about
+value=--start now-3600s --end now --width 680 --height 400 --step 300 DEF...
+]]
+ end
local output = {value={filename=filedetails.value.filename,
filecontent=filedetails.value.filecontent,}}
-- output.value.filecontent.rows="30" -- FIXME: For some reason I can't control the size of a textarea