From a30ec0c75eb0730e27ac5889170490b68331237c Mon Sep 17 00:00:00 2001 From: yumaojun <719118794@qq.com> Date: Wed, 16 Dec 2015 18:34:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20sudo=20=20=E8=A7=84?= =?UTF-8?q?=E5=88=99=E5=88=A0=E9=99=A4bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- jasset/models.py | 2 +- jperm/ansible_api.py | 2 +- templates/jperm/perm_sudo_list.html | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/jasset/models.py b/jasset/models.py index 746f3d109..2851b7d56 100644 --- a/jasset/models.py +++ b/jasset/models.py @@ -45,7 +45,7 @@ class IDC(models.Model): phone = models.CharField(max_length=32, blank=True, null=True, default='', verbose_name=u'联系电话') address = models.CharField(max_length=128, blank=True, null=True, default='', verbose_name=u"机房地址") network = models.TextField(blank=True, null=True, default='', verbose_name=u"IP地址段") - date_added = models.DateField(auto_now=True, default='', null=True) + date_added = models.DateField(auto_now=True, null=True) operator = models.CharField(max_length=32, blank=True, default='', null=True, verbose_name=u"运营商") comment = models.CharField(max_length=128, blank=True, default='', null=True, verbose_name=u"备注") diff --git a/jperm/ansible_api.py b/jperm/ansible_api.py index 71d6e9979..0ceea61d5 100644 --- a/jperm/ansible_api.py +++ b/jperm/ansible_api.py @@ -16,7 +16,7 @@ from passlib.hash import sha512_crypt from django.template.loader import get_template from django.template import Context -from utils import get_rand_pass + from jumpserver.api import logger diff --git a/templates/jperm/perm_sudo_list.html b/templates/jperm/perm_sudo_list.html index cabc875b8..f69a01948 100644 --- a/templates/jperm/perm_sudo_list.html +++ b/templates/jperm/perm_sudo_list.html @@ -89,7 +89,7 @@ function remove_sudo(sudo_id){ if (confirm("确认删除")) { $.ajax({ type: "POST", - url: "/jperm/sudo/perm_sudo_delete/", + url: "/jperm/sudo/del/", data: "id=" + sudo_id, success: function(msg){ alert( "成功: " + msg );