Merge pull request #278 from nmav/ocserv
[project/luci.git] / applications / luci-ltqtapi / luasrc / model / cbi / luci_ltqtapi / contact.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 m.on_after_commit = function() luci.sys.call("/etc/init.d/telephony reload") end
16
17 s = m:section(TypedSection, "contact", translate("Contact"), translate("Here You can specify the SIP contacts that you want to use."))
18 s.anonymous = true
19 s.addremove = true
20 s.template = "cbi/tsection"
21
22 s:option(Value, "desc", translate("Name"))
23 s:option(Value, "code", translate("Shortdial"))
24 s:option(Value, "dial", translate("Dial"))
25
26 t = s:option(ListValue, "type", translate("Type"))
27 t:value("sip", "SIP")
28 t:value("realm", "Landline")
29
30 return m