Copy by default some parameters from call.execute to chan.startup of outgoing calls.
git-svn-id: http://yate.null.ro/svn/yate/trunk@2964 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
parent
e41063d92e
commit
05fa7aca7c
|
@ -2476,9 +2476,7 @@ ClientChannel::ClientChannel(const Message& msg, const String& peerid)
|
|||
m_targetid = peerid;
|
||||
m_peerId = peerid;
|
||||
Message* s = message("chan.startup");
|
||||
s->setParam("caller",msg.getValue("caller"));
|
||||
s->setParam("called",msg.getValue("called"));
|
||||
s->setParam("billid",msg.getValue("billid"));
|
||||
s->copyParams(msg,"caller,callername,called,billid,callto,username");
|
||||
String* cs = msg.getParam("chanstartup_parameters");
|
||||
if (!null(cs))
|
||||
s->copyParams(msg,*cs);
|
||||
|
|
|
@ -715,10 +715,7 @@ ConfChan::ConfChan(const String& name, const NamedList& params, bool counted, bo
|
|||
}
|
||||
if (m_billing) {
|
||||
Message* s = message("chan.startup",params);
|
||||
s->setParam("caller",params.getValue("caller"));
|
||||
s->setParam("called",params.getValue("called"));
|
||||
s->setParam("billid",params.getValue("billid"));
|
||||
s->setParam("username",params.getValue("username"));
|
||||
s->copyParams(params,"caller,callername,called,billid,callto,username");
|
||||
Engine::enqueue(s);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -42,7 +42,10 @@ public:
|
|||
Channel(__plugin, 0, (exeMsg != 0))
|
||||
{
|
||||
m_address = addr;
|
||||
Engine::enqueue(message("chan.startup",exeMsg));
|
||||
Message* s = message("chan.startup",exeMsg);
|
||||
if (exeMsg)
|
||||
s->copyParams(*exeMsg,"caller,callername,called,billid,callto,username");
|
||||
Engine::enqueue(s);
|
||||
};
|
||||
~DumbChannel();
|
||||
virtual void disconnected(bool final, const char *reason);
|
||||
|
|
|
@ -593,7 +593,7 @@ FaxChan::FaxChan(bool outgoing, const char *file, bool sender, Message& msg)
|
|||
m_address = file;
|
||||
Message* s = message("chan.startup",msg);
|
||||
if (outgoing)
|
||||
s->copyParams(msg,"called,caller,callername,billid");
|
||||
s->copyParams(msg,"caller,callername,called,billid,callto,username");
|
||||
Engine::enqueue(s);
|
||||
}
|
||||
|
||||
|
|
|
@ -2032,10 +2032,7 @@ YateH323Chan::YateH323Chan(YateH323Connection* conn,Message* msg,const char* add
|
|||
Message* s = message("chan.startup",msg);
|
||||
if (msg) {
|
||||
m_inband = msg->getBoolValue("dtmfinband",s_inband);
|
||||
s->setParam("caller",msg->getValue("caller"));
|
||||
s->setParam("called",msg->getValue("called"));
|
||||
s->setParam("billid",msg->getValue("billid"));
|
||||
s->setParam("username",msg->getValue("username"));
|
||||
s->copyParams(*msg,"caller,callername,called,billid,callto,username");
|
||||
}
|
||||
Engine::enqueue(s);
|
||||
}
|
||||
|
|
|
@ -1371,11 +1371,11 @@ AnalogChannel::AnalogChannel(ModuleLine* line, Message* msg, RecordTrigger recor
|
|||
// Startup
|
||||
Message* m = message("chan.startup");
|
||||
m->setParam("direction",status());
|
||||
if (msg)
|
||||
m->copyParams(*msg,"caller,callername,called,billid,callto,username");
|
||||
m_line->copyCall(*m);
|
||||
if (isOutgoing()) {
|
||||
if (isOutgoing())
|
||||
m_targetid = msg->getValue("id");
|
||||
m->addParam("billid",msg->getValue("billid"));
|
||||
}
|
||||
Engine::enqueue(m);
|
||||
|
||||
// Init call
|
||||
|
|
|
@ -782,9 +782,7 @@ bool SigChannel::startCall(Message& msg, String& trunks)
|
|||
Message* m = message("chan.startup",msg);
|
||||
m->setParam("direction",status());
|
||||
m_targetid = msg.getValue("id");
|
||||
m->setParam("caller",m_caller);
|
||||
m->setParam("called",m_called);
|
||||
m->setParam("billid",msg.getValue("billid"));
|
||||
m->copyParams(msg,"caller,callername,called,billid,callto,username");
|
||||
// TODO: Add call control parameter ?
|
||||
Engine::enqueue(m);
|
||||
return true;
|
||||
|
|
|
@ -1405,9 +1405,7 @@ YIAXConnection::YIAXConnection(YIAXEngine* iaxEngine, IAXTransaction* transactio
|
|||
if (msg) {
|
||||
m_targetid = msg->getValue("id");
|
||||
m_password = msg->getValue("password");
|
||||
m->setParam("caller",msg->getValue("caller"));
|
||||
m->setParam("called",msg->getValue("called"));
|
||||
m->setParam("billid",msg->getValue("billid"));
|
||||
m->copyParams(*msg,"caller,callername,called,billid,callto,username");
|
||||
}
|
||||
Engine::enqueue(m);
|
||||
}
|
||||
|
|
|
@ -2012,9 +2012,7 @@ YateSIPConnection::YateSIPConnection(Message& msg, const String& uri, const char
|
|||
setMaxcall(msg);
|
||||
Message* s = message("chan.startup",msg);
|
||||
s->setParam("caller",caller);
|
||||
s->setParam("called",msg.getValue("called"));
|
||||
s->setParam("billid",msg.getValue("billid"));
|
||||
s->setParam("username",msg.getValue("username"));
|
||||
s->copyParams(msg,"callername,called,billid,callto,username");
|
||||
s->setParam("calledfull",m_uri.getUser());
|
||||
if (m_callid)
|
||||
s->setParam("sip_callid",m_callid);
|
||||
|
|
Loading…
Reference in New Issue