Re: Originate with label?

[email protected]
Newsgroups gmane.comp.telephony.pbx.asterisk.user
Message-ID <[email protected]>
On 8/29/2022 8:31 AM, Antony Stone wrote:
> Hi.
>
> https://wiki.asterisk.org/wiki/display/AST/Asterisk+16+Application_Originate
>
> I need to use Originate() in a dialplan, pointing to another location in the
> same extension of the same context, so for example:
>
> Originate(Local/${Dest}@Dialout,exten,${CONTEXT},${EXTEN},158);
>
> I don't seem to be able to substitute the priority 158 with a label - is this
> deliberate or is this a bug?

The underlying API that Originate uses here 
(ast_pbx_outgoing_exten_predial) accepts an integer priority, not a 
string, which would preclude labels.
However, Originate itself could accept a string and convert it to the 
integer priority before making that call. I think that would be an 
improvement/new feature, not a bug that exists today, per se, but an 
easy and useful enhancement at that. Another option would be a dialplan 
function to allow users to manually get the integer priority of a label, 
which could be useful for existing code that expects numeric priorities.

NA

-- 
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --

Check out the new Asterisk community forum at: https://community.asterisk.org/

New to Asterisk? Start here:
      https://wiki.asterisk.org/wiki/display/AST/Getting+Started

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.