[cisco-voip] Bulk insert E164 DID

Anthony Holloway avholloway+cisco-voip at gmail.com
Fri Oct 4 11:17:44 EDT 2013


Hi Tim, I know you are asking Pavan, but that is exactly how I tested, and
it still failed with my previously documented error message.

Starting DN number can only contain digits when performing bulk insert.

Here is the source code which performs the validation on DN bulk insert.
You should notice that the parseInt() function creates a number from a
string, and therefore, "\+16125551212" would not pass this check.  Possible
feature enhancement?  Maybe.

        var startNum = parseInt(elStart.value);
        var endNum = parseInt(elEnd.value);

        if (isNaN(startNum))
        {
            showValidationError(elStart, 'Starting DN number can only
contain digits when performing bulk insert.', 1);
            return false;
        }

        if (isNaN(endNum))
        {
            showValidationError(elEnd, 'Ending DN number can only
contain digits when performing bulk insert.', 1);
            return false;
        }

        // make sure start and end range is valid
        if (startNum > endNum)
        {
            showValidationError(elStart, 'Invalid DN Range.', 1);
            return false;
        }

        // make sure no more than 500 DNs max can be inserted
        var totaldn = endNum - startNum + 1;
        if (totaldn > 500)
        {
            var msg = 'Invalid DN Range.';
            msg += 'Only 500 directory numbers can be inserted at one time.';
            showValidationError(elStart, msg, 1);
            return false;
        }



On Fri, Oct 4, 2013 at 8:56 AM, Tim Smith <smithsonianwa at gmail.com> wrote:

> Oh also, can you escape the + in bulk insert?
> I.e. \+
>
> Cheers,
>
> Tim
>
> On Friday, 4 October 2013, Pavan K wrote:
>
>> Folks,
>> If i need to bulk insert 1000 sequential e164 directory numbers in ucm
>> 9.1, what's the best way to do that ?
>>
>> I can't use the bulk insert on the directory number page as it rejects
>> numbers that start with +
>>
>> I can't seem to use BAT as these numbers don't have phones associated
>> with them and consequently no Mac addresses for bulk insert of DN.
>>
>
> _______________________________________________
> cisco-voip mailing list
> cisco-voip at puck.nether.net
> https://puck.nether.net/mailman/listinfo/cisco-voip
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://puck.nether.net/pipermail/cisco-voip/attachments/20131004/fd5dc165/attachment.html>


More information about the cisco-voip mailing list