mirror of https://github.com/jumpserver/jumpserver
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
626 B
22 lines
626 B
8 years ago
|
# ~*~ coding: utf-8 ~*~
|
||
|
#
|
||
|
|
||
|
from django import forms
|
||
7 years ago
|
from django.utils.translation import ugettext_lazy as _
|
||
8 years ago
|
|
||
|
from .models import Terminal
|
||
|
|
||
|
|
||
|
class TerminalForm(forms.ModelForm):
|
||
|
class Meta:
|
||
|
model = Terminal
|
||
7 years ago
|
fields = ['name', 'remote_addr', 'ssh_port', 'http_port', 'comment']
|
||
8 years ago
|
help_texts = {
|
||
7 years ago
|
'remote_addr': _('A unique addr of every terminal, user browser can arrive it'),
|
||
|
'ssh_port': _("Coco ssh listen port"),
|
||
|
'http_port': _("Coco http/ws listen port"),
|
||
8 years ago
|
}
|
||
8 years ago
|
widgets = {
|
||
|
'name': forms.TextInput(attrs={'readonly': 'readonly'})
|
||
7 years ago
|
}
|