trafficcontrol-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fri...@apache.org
Subject [incubator-trafficcontrol] 01/02: changed maxLength of zip code to be longer.
Date Wed, 24 Jan 2018 22:19:31 GMT
This is an automated email from the ASF dual-hosted git repository.

friede pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-trafficcontrol.git

commit b1a116f87d8c7dae54de0b53f19d60b4114f5926
Author: David Neuman <david.neuman64@gmail.com>
AuthorDate: Wed Jan 24 14:45:47 2018 -0700

    changed maxLength of zip code to be longer.
---
 traffic_ops/app/lib/UI/PhysLocation.pm                              | 2 +-
 .../common/modules/form/physLocation/FormPhysLocationController.js  | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/traffic_ops/app/lib/UI/PhysLocation.pm b/traffic_ops/app/lib/UI/PhysLocation.pm
index 54a643d..02cee29 100644
--- a/traffic_ops/app/lib/UI/PhysLocation.pm
+++ b/traffic_ops/app/lib/UI/PhysLocation.pm
@@ -345,7 +345,7 @@ sub is_valid {
 	$self->field('location.address')->is_required->is_like( qr/^[a-zA-Z0-9\ \.\-]+/,
"Use alphanumeric characters, '.','-', or space." );
 	$self->field('location.city')->is_required->is_like( qr/^[a-zA-Z0-9\ \.\-]+/, "Use
alphanumeric characters, '.','-', or space." );
 	$self->field('location.state')->is_required->is_like( qr/^[A-Z]{2}/, "Uppercase
2 char. state abbreviation." );
-	$self->field('location.zip')->is_required->is_like( qr/^[0-9]{5,5}$/, "Enter a
valid 5 digit zipcode." );
+	$self->field('location.zip')->is_required->is_like( qr/^[0-9]/, "Enter a valid
zip code." );
 	$self->field('location.phone')->is_like( qr/^$|[0-9]{3}\-[0-9]{3}\-[0-9]{4}/, "Phone
number format is: ###-###-####" );
 	$self->field('location.email')->check( sub {
 			my ( $value, $params ) = @_;
diff --git a/traffic_portal/app/src/common/modules/form/physLocation/FormPhysLocationController.js
b/traffic_portal/app/src/common/modules/form/physLocation/FormPhysLocationController.js
index d7f78fc..a0ed71e 100644
--- a/traffic_portal/app/src/common/modules/form/physLocation/FormPhysLocationController.js
+++ b/traffic_portal/app/src/common/modules/form/physLocation/FormPhysLocationController.js
@@ -6,9 +6,9 @@
  * to you under the Apache License, Version 2.0 (the
  * "License"); you may not use this file except in compliance
  * with the License.  You may obtain a copy of the License at
- * 
+ *
  *   http://www.apache.org/licenses/LICENSE-2.0
- * 
+ *
  * Unless required by applicable law or agreed to in writing,
  * software distributed under the License is distributed on an
  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -34,7 +34,7 @@ var FormPhysLocationController = function(physLocation, $scope, $location,
formU
         { name: 'address', type: 'text', required: true, maxLength: 128 },
         { name: 'city', type: 'text', required: true, maxLength: 128 },
         { name: 'state', type: 'text', required: true, maxLength: 2 },
-        { name: 'zip', type: 'text', required: true, maxLength: 5 },
+        { name: 'zip', type: 'text', required: true, maxLength: 11 },
         { name: 'poc', type: 'text', required: false, maxLength: 128 },
         { name: 'phone', type: 'text', required: false, maxLength: 45 },
         { name: 'email', type: 'email', required: false, maxLength: 128 }

-- 
To stop receiving notification emails like this one, please contact
friede@apache.org.

Mime
View raw message