$(function() {
- NetworkProxy=function(id,protocol,host,port,username,password){
+ NetworkProxy=function(id,protocol,host,port,username,password,useNtlm){
var self=this;
//private String id;
this.id = ko.observable(id);
//private String protocol = "http";
this.protocol=ko.observable(protocol);
- this.protocol.subscribe(function(newValue){self.modified(true)});;
+ this.protocol.subscribe(function(newValue){self.modified(true)});
//private String host;
this.host=ko.observable(host);
- this.host.subscribe(function(newValue){self.modified(true)});;
+ this.host.subscribe(function(newValue){self.modified(true)});
//private int port = 8080;
this.port=ko.observable(port);
- this.port.subscribe(function(newValue){self.modified(true)});;
+ this.port.subscribe(function(newValue){self.modified(true)});
//private String username;
this.username=ko.observable(username?username:"");
- this.username.subscribe(function(newValue){self.modified(true)});;
+ this.username.subscribe(function(newValue){self.modified(true)});
//private String password;
this.password=ko.observable(password?password:"");
- this.password.subscribe(function(newValue){self.modified(true)});;
+ this.password.subscribe(function(newValue){self.modified(true)});
+
+ //use NTLM proxy
+ this.useNtlm=ko.observable(useNtlm);
+ this.useNtlm.subscribe(function(newValue){self.modified(true)});
this.modified=ko.observable(false);
}
if (data==null){
return null;
}
- return new NetworkProxy(data.id,data.protocol,data.host,data.port,data.username,data.password);
+ return new NetworkProxy(data.id,data.protocol,data.host,data.port,data.username,data.password,data.useNtlm);
}
mapNetworkProxies=function(data){
<th>${ columnDefinition.headerText }</th>
{{/each}}
<th>${$.i18n.prop('password')}</th>
+ <th>${$.i18n.prop('network.proxy.useNtlm')}</th>
<th>${$.i18n.prop('edit')}</th>
<th>${$.i18n.prop('delete')}</th>
<th>${$.i18n.prop('modified')}</th>
{{else}}
<td></td>
{{/if}}
+ <td>${row.useNtlm()}</td>
<td>
<a href="#" data-bind="click: function(){ editNetworkProxy(row) }">${$.i18n.prop('edit')}</a>
</td>
data-bind="value: networkProxy.password"/>
</div>
</div>
+ <div class="control-group">
+ <label class="control-label" for="password">${$.i18n.prop('network.proxy.useNtlm')}</label>
+ <div class="controls">
+ <input type="checkbox" id="useNtlm" name="useNtlm" data-bind="checked: networkProxy.useNtlm"/>
+ </div>
+ </div>
</fieldset>
<button data-bind="click: save" class="btn">${$.i18n.prop('save')}</button>