Fix: leaftlet layer input shall not be validated
This commit is contained in:
parent
c64f126254
commit
322a2c9dfb
|
@ -128,7 +128,7 @@ angular.module('ffffng')
|
||||||
var doSubmit = function (node) {
|
var doSubmit = function (node) {
|
||||||
if ($scope.nodeForm.$invalid) {
|
if ($scope.nodeForm.$invalid) {
|
||||||
var firstInvalid = _.filter($element.find('form').find('input'), function (input) {
|
var firstInvalid = _.filter($element.find('form').find('input'), function (input) {
|
||||||
return $scope.nodeForm[input.name].$invalid;
|
return input.name !== 'leaflet-base-layers' && $scope.nodeForm[input.name].$invalid;
|
||||||
})[0];
|
})[0];
|
||||||
if (firstInvalid) {
|
if (firstInvalid) {
|
||||||
$window.scrollTo(0, $window.pageYOffset + firstInvalid.getBoundingClientRect().top - 100);
|
$window.scrollTo(0, $window.pageYOffset + firstInvalid.getBoundingClientRect().top - 100);
|
||||||
|
|
Loading…
Reference in a new issue