libs/web: implement new phone digit datatype, useful for VoIP related config screens
[project/luci.git] / applications / luci-lqtapifoss / luasrc / model / cbi / luci_lqvoip / config.lua
1 --[[
2 LuCI - Lua Configuration Interface
3
4 Copyright 2010 John Crispin <blogic@openwrt.org>
5
6 Licensed under the Apache License, Version 2.0 (the "License");
7 you may not use this file except in compliance with the License.
8 You may obtain a copy of the License at
9
10         http://www.apache.org/licenses/LICENSE-2.0
11
12 ]]--
13
14 m = Map("telephony", translate("VoIP"))
15
16 s = m:section(NamedSection, "config", "config", "Config", "Here You can specify the generic Configuration.")
17 m.on_after_commit = function() luci.sys.call("/etc/init.d/telephony restart") end
18
19 s:option(Value, "netdev", translate("Network"))
20
21 e = s:option(ListValue, "fw_dl", translate("Download firmware"))
22 e:value("0", translate("No"))
23 e:value("1", translate("Yes"))
24 e.default = "0"
25
26 e = s:option(Value, "fw_url", translate("Firmware path"))
27 e:depends("fw_dl", 1)
28
29 return m