m = Map("system", translate("system"), translate("a_s_desc"))
+function m.on_parse()
+ local has_rdate = false
+
+ m.uci:foreach("system", "rdate",
+ function()
+ has_rdate = true
+ return false
+ end)
+
+ if not has_rdate then
+ m.uci:section("system", "rdate", nil, { })
+ m.uci:save("system")
+ end
+end
+
+
s = m:section(TypedSection, "system", "")
s.anonymous = true
s.addremove = false
s:option(Value, "log_ip").optional = true
s:option(Value, "conloglevel").optional = true
s:option(Value, "cronloglevel").optional = true
+
+s2 = m:section(TypedSection, "rdate", translate("timesrv", "Time Server (rdate)"))
+s2.anonymous = true
+s2.addremove = false
+
+s2:option(DynamicList, "server", translate("server", "Server"))
+
return m