[OpenSIPS-Users] get_dialog_info issues

Ross Beer beer.ross at googlemail.com
Wed Sep 1 10:33:10 CEST 2010


Hi,

I am using the following piece of code to set dlg_val and then using
get_dialog_info to check to see if a user already has a call and if so
pass the new call to the same gatewar for attended transfer.

The code works perfectly if in the same dialog, i.e. when an invite is
sent and then requires authentication however it does not appear to
match any results across different dialogs. Also I can not see any
values in the 'vars' coloumn in the dialog database.

Am I using the feature correctly?

                                        # IS PART OF EXISTING CALL
                                        if
(get_dialog_info("server","$var(x)","user","$fU"))
                                        {
                                                xlog("************
Log: Seen Before Call *************\n");
                                                xlog("Log: Belonds to
Server: $var(x)\n");
                                                $du=$var(x);

                                                ## ADD VARIABLE TO ROUTE GATEWAY
                                                $dlg_val("server") = $var(x);
                                                $dlg_val("user") = $fU;
                                                route(1);
                                                exit;
                                        }
                                        else
                                        {

                                                xlog("************
Log: New INVITE *************\n");
                                                ds_select_dst("1", "4");

                                                xlog("LB Sent To
$avp(i:271)\n");


store_dlg_value("server","$avp(i:271)");
                                                store_dlg_value("user","$fU");
                                                #$dlg_val(server) = $avp(i:271);
                                                #$dlg_val(user) = $fU;
                                                route(1);
                                                exit;
                                        }

Kind regards,

Ross



More information about the Users mailing list