mirror of https://github.com/jumpserver/jumpserver
fix: 修改协议错误信息翻译
parent
bf6fcc9020
commit
52d3e1b34b
|
@ -17,7 +17,7 @@ __all__ = [
|
|||
class ProtocolField(serializers.RegexField):
|
||||
protocols = '|'.join(dict(Asset.Protocol.choices).keys())
|
||||
default_error_messages = {
|
||||
'invalid': _('Protocol format should {}/{}'.format(protocols, '1-65535'))
|
||||
'invalid': _('Protocol format should {}/{}').format(protocols, '1-65535')
|
||||
}
|
||||
regex = r'^(%s)/(\d{1,5})$' % protocols
|
||||
|
||||
|
|
Loading…
Reference in New Issue