Merge pull request #3128 from jumpserver/v52_remoteapp

[Bugfix] 修复remote-app应用创建/更新时,参数设置不成功的bug
pull/3134/head
BaiJiangJie 2019-08-15 19:09:29 +08:00 committed by GitHub
commit 7d1e8d258c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 5 deletions

View File

@ -110,16 +110,15 @@ function hiddenFields(){
function constructParams(data) {
var typeList = ['chrome', 'mysql_workbench', 'vmware_client', 'custom'];
var params = {};
for (var type in typeList){
if (data.type === type){
$.each(typeList, function(index, value){
if (data.type === value){
for (var k in data){
if (k.startsWith(data.type)){
if (k.startsWith(value)){
params[k] = data[k]
}
}
break
}
}
});
return params;
}
$(document).ready(function () {