Hello,
I'm trying to do a simple blind call forwarding with the below script added
into "main request routing logic". (123 dials 789 and 789 is forwarded to 456)
if(avp_db_load("$ru","$avp(s:callfwd)")){
$ru = $avp(s:callfwd);
xlog("forwarded to: $avp(s:callfwd)");
route(1);
exit;
}
My usr_preferences table is as below.
opensips=> select * from usr_preferences;
id | uuid | username | domain| attribute | type | value |
last_modified
----+------+----------+--------+-----------+------+------------------------+---------------------
1 | | 789 | | callfwd | 0| sip:456@xxxxxxxxxxx
|1900-01-01 00:00:01
(1 row)
opensips=>
I have added the avpops module as below.
#AVPOPS module
loadmodule "avpops.so"
modparam("avpops","db_url","postgres://opensips:xxxxxxxx@localhost/opensips")
modparam("avpops","avp_table","usr_preferences")
Anyways, this script does not do the call forwarding task. Anyone could help on
this please. Could there be a problem of the position that I have added the
script in "main request routing logic".
_______________________________________________
Users mailing list
[email protected]
http://lists.opensips.org/cgi-bin/mailman/listinfo/users