KEYCLOAK-3281: Pressing Enter in Identity Provider form causes error

This commit is contained in:
Stan Silvert 2016-10-28 12:06:53 -04:00
parent 33bd7ca45f
commit 89348af59e
3 changed files with 21 additions and 9 deletions

View file

@ -956,7 +956,7 @@ module.controller('RealmIdentityProviderCtrl', function($scope, $filter, $upload
id: $scope.identityProvider.internalId
}, $scope.identityProvider, function () {
$route.reload();
Notifications.success("The " + $scope.identityProvider.alias + " provider has been update.");
Notifications.success("The " + $scope.identityProvider.alias + " provider has been updated.");
});
}
};

View file

@ -222,8 +222,11 @@
<input class="form-control" id="fromUrl" type="text" ng-model="fromUrl.data">
</div>
<kc-tooltip>{{:: 'identity-provider.import-from-url.tooltip' | translate}}</kc-tooltip>
<div class="col-md-6" data-ng-show="importUrl">
<button type="submit" data-ng-click="importFrom()" data-ng-show="importUrl" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="importFrom"></label>
<div class="col-md-6">
<button id="importFrom" type="button" data-ng-click="importFrom()" data-ng-show="importUrl" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
</div>
<div class="form-group" data-ng-show="newIdentityProvider">
@ -238,8 +241,11 @@
{{files[0].name}}
</span>
</div>
<div class="col-md-6" data-ng-show="importFile">
<button type="submit" data-ng-click="uploadFile()" data-ng-show="importFile" class="btn btn-primary">{{:: 'import' | translate}}</button>
<div class="form-group">
<label class="col-md-2 control-label" for="importFile"></label>
<div class="col-md-6" data-ng-show="importFile">
<button id="importFile" type="button" data-ng-click="uploadFile()" data-ng-show="importFile" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
</div>
</div>
</fieldset>

View file

@ -191,8 +191,11 @@
<input class="form-control" id="fromUrl" type="text" ng-model="fromUrl.data">
</div>
<kc-tooltip>{{:: 'saml.import-from-url.tooltip' | translate}}</kc-tooltip>
<div class="col-sm-4" data-ng-show="importUrl">
<button type="submit" data-ng-click="importFrom()" data-ng-show="importUrl" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
<div class="form-group">
<label class="col-md-2 control-label" for="importFrom"></label>
<div class="col-md-6">
<button id="importFrom" type="button" data-ng-click="importFrom()" data-ng-show="importUrl" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
</div>
<div class="form-group" data-ng-show="newIdentityProvider">
@ -206,8 +209,11 @@
{{files[0].name}}
</span>
</div>
<div class="col-sm-4" data-ng-show="importFile">
<button type="submit" data-ng-click="uploadFile()" data-ng-show="importFile" class="btn btn-primary">{{:: 'import' | translate}}</button>
<div class="form-group">
<label class="col-md-2 control-label" for="importFile"></label>
<div class="col-sm-6" data-ng-show="importFile">
<button id="importFile" type="button" data-ng-click="uploadFile()" data-ng-show="importFile" class="btn btn-primary">{{:: 'import' | translate}}</button>
</div>
</div>
</div>
</fieldset>