On Sat, Jan 17, 2009 at 10:39 AM, Benny Amorsen <benny+use...@amorsen.dk> wrote: > > Only if the dial plan actually gets enough information to set the > accountcode, which at least historically wasn't the case for Asterisk. > In 1.2.x, you couldn't in the dialplan tell if a call went A->B or > A->C(SIP redirect)->B. BLINDXFER didn't get set correctly in all > cases. > > The alternative is to use the built-in accountcode from sip.conf; I > haven't verified how well that actually works. It won't work if you > need to distinguish two different phones behind a SIP trunk, but I > don't think anything can, so we can forget about that case. >
I've always set the accountcode directly in the dialplan using SetAccountCode and now the newer CDR function. I to encountered occassional problems relying on Asterisk picking up the accountcode from configuration files or a realtime database. We changed our approach to doing a FastAGI call to get the accountcode, the FastAGI call provides the channel name from which the authenticated username and then accountcode can be looked up. As for blind transfers I've always seen the accountcode on the transferred call leg set to that of the call that initiated it. If you wanted it the other way around you do have the option of breaking back into the dialplan when a blind transfer occurs by using the TRANSFER_CONTEXT. At the moment depending on which Asterisk version you are using that won't completely solve the problem since the CDRs produced when transfers occur are all wrong and differently wrong in the different Asterisk versions. Regards, Greyman. _______________________________________________ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users