From 7531a3ada7528ea2a881c822f39c1d338899cf4c Mon Sep 17 00:00:00 2001 From: ibuler Date: Wed, 18 May 2016 04:08:12 -0500 Subject: [PATCH 01/24] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E7=BC=96=E8=BE=91?= =?UTF-8?q?=E7=B3=BB=E7=BB=9F=E7=94=A8=E6=88=B7=EF=BC=8C=E7=94=A8=E6=88=B7?= =?UTF-8?q?=E5=90=8Djsbug=20(#240)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Update perm_role_edit.html --- connect.py | 2 +- templates/jperm/perm_role_edit.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/connect.py b/connect.py index f0f8effd3..5ff7ae268 100755 --- a/connect.py +++ b/connect.py @@ -585,7 +585,7 @@ class Nav(object): print "请输入运行命令所关联系统用户的ID, q退出" try: - role_id = raw_input("\033[1;32mRole>:\033[0m ").strip() + role_id = int(raw_input("\033[1;32mRole>:\033[0m ").strip()) if role_id == 'q': break except (IndexError, ValueError): diff --git a/templates/jperm/perm_role_edit.html b/templates/jperm/perm_role_edit.html index 8ad8ed973..fe10b6c44 100644 --- a/templates/jperm/perm_role_edit.html +++ b/templates/jperm/perm_role_edit.html @@ -94,7 +94,7 @@ $('#roleForm').validator({ timely: 2, theme: "yellow_right_effect", rules: { - check_name: [/(?!^root$)^\w{2,20}$/i, '大小写字母数字和下划线,2-20位,并且非root'], + check_name: [/(?!^root$)^[\w.]{2,20}$/i, '大小写字母数字和下划线小数点,2-20位,并且非root'], check_begin: [/^[\-]+BEGIN RSA PRIVATE KEY[\-]+/gm, 'RSA Key填写有误,请检查'], }, From 0cc04ee20d3c598b7028a8a31789926250400f50 Mon Sep 17 00:00:00 2001 From: zheng Date: Wed, 18 May 2016 18:14:18 +0800 Subject: [PATCH 02/24] Group edit (#241) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * 修复主机组编辑时回车导致主机丢失问题 在主机组编辑页面,如果直接执行回车会导致主机组中主机信息丢失。 本修复方法是关闭回车提交 * 编辑主机组在移除过滤保存时数据会丢失 现象:在反向移除选择的主机时,用过滤框搜索移除主机此时保存的数据是当前过滤显示的数据 后果:会造成原有主机组数据丢失 修复:在保存之前触发一次空值搜索 --- templates/jasset/group_edit.html | 1 + 1 file changed, 1 insertion(+) diff --git a/templates/jasset/group_edit.html b/templates/jasset/group_edit.html index f99e5f50c..b29ad7a48 100644 --- a/templates/jasset/group_edit.html +++ b/templates/jasset/group_edit.html @@ -153,6 +153,7 @@ }); function on_submit(id){ + search_ip('', 'asset_select', 'asset_select_total') //提交之前清空过滤框 $('#'+id+' option').each( function(){ $(this).prop('selected', true) From f2dda35f28a93d16a8e3ed3c451db9533134cef5 Mon Sep 17 00:00:00 2001 From: ibuler Date: Thu, 19 May 2016 17:47:50 +0800 Subject: [PATCH 03/24] Update footer.html --- templates/footer.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/footer.html b/templates/footer.html index 98aeb15d0..83861872f 100644 --- a/templates/footer.html +++ b/templates/footer.html @@ -1,6 +1,6 @@