diff options
author | aalatchm <aalatchm@jamailca.com> | 2011-07-20 17:45:13 +0000 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2011-07-20 14:12:40 -0400 |
commit | c5542869099e3fa0128df871ceeb955ab35f77f0 (patch) | |
tree | 315a9135d9b9b41145abc32701c9e94489b76493 | |
parent | d9d69563103780befdab80843070c15857c96541 (diff) | |
download | acf-provisioning-c5542869099e3fa0128df871ceeb955ab35f77f0.tar.bz2 acf-provisioning-c5542869099e3fa0128df871ceeb955ab35f77f0.tar.xz |
Configure Linksys to use extension number for caller id name if none is defined.
-rw-r--r-- | templates/linksysata-template.lua | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/templates/linksysata-template.lua b/templates/linksysata-template.lua index 6c4c551..3972c33 100644 --- a/templates/linksysata-template.lua +++ b/templates/linksysata-template.lua @@ -5,6 +5,13 @@ server=values.device.registrar web_server=ENV['HTTP_HOST'] moh=values.device.musiconhold dialpattern="( " .. values.device.digitmap .. " )" + +local cid +if values.reg1.callerid == "" then + cid = values.reg1.extension +else + cid = values.reg1.callerid +end %> <% local values = ... %> @@ -256,7 +263,7 @@ http://<% io.write(web_server) %>/Linksys/$MA.xml -<Display_Name_1_ ua="na"><%= values.reg1.callerid %></Display_Name_1_> +<Display_Name_1_ ua="na"><%= cid %></Display_Name_1_> <User_ID_1_ ua="na"><% io.write(values.reg1.extension) %></User_ID_1_> <Password_1_ ua="na"><% io.write(values.reg1.password) %></Password_1_> <Use_Auth_ID_1_ ua="na">No</Use_Auth_ID_1_> |