mirror of https://github.com/jumpserver/jumpserver
16 lines
646 B
Python
16 lines
646 B
Python
from django.utils.translation import ugettext_lazy as _
|
|
from rest_framework import serializers
|
|
|
|
from common.drf.fields import EncryptedField
|
|
|
|
__all__ = ['WeComSettingSerializer']
|
|
|
|
|
|
class WeComSettingSerializer(serializers.Serializer):
|
|
PREFIX_TITLE = '%s-%s' % (_('Authentication'), _('WeCom'))
|
|
|
|
WECOM_CORPID = serializers.CharField(max_length=256, required=True, label='corpid')
|
|
WECOM_AGENTID = serializers.CharField(max_length=256, required=True, label='agentid')
|
|
WECOM_SECRET = EncryptedField(max_length=256, required=False, label='secret')
|
|
AUTH_WECOM = serializers.BooleanField(default=False, label=_('Enable WeCom Auth'))
|