diff options
author | Jo-Philipp Wich <jow@openwrt.org> | 2009-03-29 23:39:40 +0000 |
---|---|---|
committer | Jo-Philipp Wich <jow@openwrt.org> | 2009-03-29 23:39:40 +0000 |
commit | 36b1bbd9ff880b764e932d27075bc5a9edd41e47 (patch) | |
tree | 5644036dce23c32caf01e34ed9634a440a0eccb9 /applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua | |
parent | 0c7effc0c0c4248d0fd96b6fb289139c388a9fb7 (diff) |
applications/luci-asterisk: rework voicemail management
Diffstat (limited to 'applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua')
-rw-r--r-- | applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua b/applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua new file mode 100644 index 0000000000..efd6a29167 --- /dev/null +++ b/applications/luci-asterisk/luasrc/model/cbi/asterisk/voicemail.lua @@ -0,0 +1,40 @@ +--[[ +LuCI - Lua Configuration Interface + +Copyright 2009 Jo-Philipp Wich <xm@subsignal.org> + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +$Id$ +]]-- + +require "luci.sys.zoneinfo" + + +cbimap = Map("asterisk", "Voicemail - Mailboxes") + +voicemail = cbimap:section(TypedSection, "voicemail", "Voicemail Boxes") +voicemail.addremove = true +voicemail.anonymous = true +voicemail.template = "cbi/tblsection" + +context = voicemail:option(ListValue, "context", "Context") +context:value("default") + +voicemail:option(Value, "number", "Mailbox Number", "Unique mailbox identifier") +voicemail:option(Value, "name", "Ownername", "Human readable display name") +voicemail:option(Value, "password", "Password", "Access protection") +voicemail:option(Value, "email", "eMail", "Where to send voice messages") +voicemail:option(Value, "page", "Pager", "Pager number") + +zone = voicemail:option(ListValue, "zone", "Timezone", "Used time format") +zone.titleref = luci.dispatcher.build_url("admin/asterisk/voicemail/settings") +cbimap.uci:foreach("asterisk", "voicezone", + function(s) zone:value(s['.name']) end) + + +return cbimap |