summaryrefslogtreecommitdiff
path: root/channels/chan_console.c
diff options
context:
space:
mode:
authorJeff Peeler <jpeeler@digium.com>2008-04-21 23:42:45 +0000
committerJeff Peeler <jpeeler@digium.com>2008-04-21 23:42:45 +0000
commit41fd7a6a21fc870f75ceb219d130e0bd6519636c (patch)
tree5ea0c0e4501835ff0a5f3ba5d5857d07de851abb /channels/chan_console.c
parentf773e294f17bf2460b1dee4b46a78aa8e59fbb68 (diff)
(closes issue #6113)
Reported by: oej Tested by: jpeeler This patch implements multiple parking lots for parked calls. The default parkinglot is used by default, however setting the channel variable PARKINGLOT in the dialplan will allow use of any other configured parkinglot. See configs/features.conf.sample for more details on setting up another non-default parkinglot. Also, one can (currently) set the default parkinglot to use in the driver configuration file via the parkinglot option. Patch initially written by oej, brought up to date and finalized by mvanbaak, and then stabilized and converted to astobj2 by me. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@114487 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels/chan_console.c')
-rw-r--r--channels/chan_console.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/channels/chan_console.c b/channels/chan_console.c
index 7d62e6235..0fe3cbef4 100644
--- a/channels/chan_console.c
+++ b/channels/chan_console.c
@@ -141,6 +141,8 @@ static struct console_pvt {
AST_STRING_FIELD(mohinterpret);
/*! Default language */
AST_STRING_FIELD(language);
+ /*! Default parkinglot */
+ AST_STRING_FIELD(parkinglot);
);
/*! Current channel for this device */
struct ast_channel *owner;
@@ -1004,6 +1006,7 @@ static char *cli_list_devices(struct ast_cli_entry *e, int cmd, struct ast_cli_a
"=== ---> CallerID Name: %s\n"
"=== ---> MOH Interpret: %s\n"
"=== ---> Language: %s\n"
+ "=== ---> Parkinglot: %s\n"
"=== ---> Muted: %s\n"
"=== ---> Auto-Answer: %s\n"
"=== ---> Override Context: %s\n"
@@ -1011,7 +1014,7 @@ static char *cli_list_devices(struct ast_cli_entry *e, int cmd, struct ast_cli_a
pvt->name, (pvt == active_pvt) ? "Yes" : "No",
pvt->input_device, pvt->output_device, pvt->context,
pvt->exten, pvt->cid_num, pvt->cid_name, pvt->mohinterpret,
- pvt->language, pvt->muted ? "Yes" : "No", pvt->autoanswer ? "Yes" : "No",
+ pvt->language, pvt->parkinglot, pvt->muted ? "Yes" : "No", pvt->autoanswer ? "Yes" : "No",
pvt->overridecontext ? "Yes" : "No");
console_pvt_unlock(pvt);
@@ -1236,6 +1239,7 @@ static void set_pvt_defaults(struct console_pvt *pvt)
ast_string_field_set(pvt, language, "");
ast_string_field_set(pvt, cid_num, "");
ast_string_field_set(pvt, cid_name, "");
+ ast_string_field_set(pvt, parkinglot, "");
pvt->overridecontext = 0;
pvt->autoanswer = 0;
@@ -1248,6 +1252,7 @@ static void set_pvt_defaults(struct console_pvt *pvt)
ast_string_field_set(pvt, language, globals.language);
ast_string_field_set(pvt, cid_num, globals.cid_num);
ast_string_field_set(pvt, cid_name, globals.cid_name);
+ ast_string_field_set(pvt, parkinglot, globals.parkinglot);
pvt->overridecontext = globals.overridecontext;
pvt->autoanswer = globals.autoanswer;
@@ -1287,6 +1292,7 @@ static void store_config_core(struct console_pvt *pvt, const char *var, const ch
CV_F("callerid", store_callerid(pvt, value));
CV_BOOL("overridecontext", pvt->overridecontext);
CV_BOOL("autoanswer", pvt->autoanswer);
+ CV_STRFIELD("parkinglot", pvt, parkinglot);
if (pvt != &globals) {
CV_F("active", set_active(pvt, value))