diff --git a/jasset/views.py b/jasset/views.py index 22c72f8e5..fc2a1225c 100644 --- a/jasset/views.py +++ b/jasset/views.py @@ -232,7 +232,7 @@ def host_add_batch(request): active_types = {'激活': 1, '禁用': 0} dept_id = get_user_dept(request) if request.method == 'POST': - multi_hosts = request.POST.get('j_multi').split('\n') + multi_hosts = request.POST.get('j_multi').splitlines() for host in multi_hosts: if host == '': break @@ -927,4 +927,4 @@ def host_search(request): posts = list(set(post_all) & set(post_perm)) contact_list, p, contacts, page_range, current_page, show_first, show_end = pages(posts, request) - return my_render('jasset/host_search.html', locals(), request) \ No newline at end of file + return my_render('jasset/host_search.html', locals(), request) diff --git a/templates/jasset/host_search.html b/templates/jasset/host_search.html index 38ed8c1ad..2fe6e0449 100644 --- a/templates/jasset/host_search.html +++ b/templates/jasset/host_search.html @@ -35,7 +35,7 @@ {{ post.date_added|date:"Y-m-d H:i:s" }} {{ post.comment }} - 详情 + 详情 {% ifnotequal session_role_id 0 %} 编辑 删除