MasterVitronic / fusionpbx

Automatically exported from code.google.com/p/fusionpbx
0 stars 0 forks source link

Inbound Routes produces error message if Destination Number does not meet certain arbitrary criteria #350

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Go to Inbound Routes and click the icon to add a new route
2. Attempt to use a number containing less than SIX digits (not five) for the 
Destination number. Or, try to use a pattern that contains a non-numeric 
character.
3. Fill in other information and click Save

What is the expected output? What do you see instead?
It should accept the number or string given and place it in the destination 
number condition.  Instead, you get an error message saying "The destination 
number must be 5 or more digits" (which is wrong because a five digit number 
will also trigger the error).

What version of the product are you using? On what operating system?

FusionPBX 3.1.4 on Debian Linux

Please provide any additional information below.

While this can be fixed in editing by modifying the 
condition|destination_number field, the error message itself is extraneous and 
erroneous.  There is no reason that an error message should pop up at all, 
since the user may be trying to enter a regular expression or a label of some 
kind (examples might be (\d{4}) to pass all four-digit calls, or GV2345551212 
to pass an incoming call from Google Voice that for whatever reason is coming 
in with the GV prefix).  My opinion is that the only thing it may be 
appropriate to check for would be characters that are illegal in a regular 
expression or are "invisible", such as spaces, tabs, etc.  In any case there is 
no good reason to limit entries to six digits or more.

Original issue reported on code.google.com by michigantelephone on 16 Nov 2012 at 6:12

GoogleCodeExporter commented 9 years ago
You don't know the reason its written that way but that doesn't mean that there 
wasn't a reason. However the dev branch has a better way so I'm removing the 
requirement.

Original comment by markjcrane@gmail.com on 16 Nov 2012 at 10:35