Timout form updates
parent
a9d1799eda
commit
cb6767dfb4
|
@ -160,7 +160,7 @@
|
||||||
// We can pass it default values.
|
// We can pass it default values.
|
||||||
defaults:{
|
defaults:{
|
||||||
id:null,
|
id:null,
|
||||||
idTokenValiditySeconds: 0,
|
idTokenValiditySeconds: 600,
|
||||||
applicationName:"",
|
applicationName:"",
|
||||||
clientSecret:"",
|
clientSecret:"",
|
||||||
registeredRedirectUri:[],
|
registeredRedirectUri:[],
|
||||||
|
@ -171,8 +171,8 @@
|
||||||
logoUrl:"",
|
logoUrl:"",
|
||||||
clientId:"",
|
clientId:"",
|
||||||
allowRefresh:false,
|
allowRefresh:false,
|
||||||
accessTokenValiditySeconds: 0,
|
accessTokenValiditySeconds: 3600,
|
||||||
refreshTokenValiditySeconds: 0,
|
refreshTokenValiditySeconds: 604800,
|
||||||
displayClientSecret: false,
|
displayClientSecret: false,
|
||||||
generateClientSecret: false,
|
generateClientSecret: false,
|
||||||
requireClientSecret: true
|
requireClientSecret: true
|
||||||
|
@ -332,6 +332,7 @@
|
||||||
|
|
||||||
events:{
|
events:{
|
||||||
"click .btn-primary":"saveClient",
|
"click .btn-primary":"saveClient",
|
||||||
|
"click #allowRefresh" : "toggleRefreshTokenTimeout",
|
||||||
"click .btn-cancel": function() { window.history.back(); return false; },
|
"click .btn-cancel": function() { window.history.back(); return false; },
|
||||||
"change #requireClientSecret":"toggleRequireClientSecret",
|
"change #requireClientSecret":"toggleRequireClientSecret",
|
||||||
"change #displayClientSecret":"toggleDisplayClientSecret",
|
"change #displayClientSecret":"toggleDisplayClientSecret",
|
||||||
|
@ -339,6 +340,10 @@
|
||||||
"change #logoUrl input":"previewLogo"
|
"change #logoUrl input":"previewLogo"
|
||||||
},
|
},
|
||||||
|
|
||||||
|
toggleRefreshTokenTimeout:function () {
|
||||||
|
$("#refreshTokenValiditySeconds", this.$el).toggle();
|
||||||
|
},
|
||||||
|
|
||||||
previewLogo:function(event) {
|
previewLogo:function(event) {
|
||||||
if ($('#logoUrl input').val()) {
|
if ($('#logoUrl input').val()) {
|
||||||
//$('#logoBlock').show();
|
//$('#logoBlock').show();
|
||||||
|
@ -483,6 +488,10 @@
|
||||||
, autocomplete: _.uniq(_.flatten(app.clientList.pluck("scope")))
|
, autocomplete: _.uniq(_.flatten(app.clientList.pluck("scope")))
|
||||||
, collection: this.scopeCollection}).render().el);
|
, collection: this.scopeCollection}).render().el);
|
||||||
|
|
||||||
|
if (!this.model.get("allowRefresh")) {
|
||||||
|
$("#refreshTokenValiditySeconds", this.$el).hide();
|
||||||
|
}
|
||||||
|
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
|
@ -99,15 +99,6 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="control-group">
|
|
||||||
<label class="control-label">Refresh Tokens</label>
|
|
||||||
<div class="controls">
|
|
||||||
<label class="checkbox">
|
|
||||||
<input type="checkbox" id="allowRefresh" <%=(allowRefresh == true ? 'checked' : '')%>> Allow refresh tokens?
|
|
||||||
</label>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="control-group" id="scope">
|
<div class="control-group" id="scope">
|
||||||
<label class="control-label">Scope</label>
|
<label class="control-label">Scope</label>
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
|
@ -193,6 +184,15 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="control-group">
|
||||||
|
<label class="control-label">Refresh Tokens</label>
|
||||||
|
<div class="controls">
|
||||||
|
<label class="checkbox">
|
||||||
|
<input type="checkbox" id="allowRefresh" <%=(allowRefresh == true ? 'checked' : '')%>> Allow refresh tokens?
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="control-group" id="refreshTokenValiditySeconds">
|
<div class="control-group" id="refreshTokenValiditySeconds">
|
||||||
<label class="control-label">Refresh Token
|
<label class="control-label">Refresh Token
|
||||||
Timeout</label>
|
Timeout</label>
|
||||||
|
|
Loading…
Reference in New Issue