diff --git a/Dockerfile b/Dockerfile index f7a9c3513..05561714e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,6 +6,7 @@ RUN useradd jumpserver COPY ./requirements /tmp/requirements +RUN rpm -ivh https://repo.mysql.com/mysql57-community-release-el6.rpm RUN yum -y install epel-release openldap-clients telnet && cd /tmp/requirements && \ yum -y install $(cat rpm_requirements.txt) diff --git a/README.md b/README.md index cf2b97ec5..5141bb664 100644 --- a/README.md +++ b/README.md @@ -46,7 +46,7 @@ Jumpserver采纳分布式架构,支持多机房跨区域部署,中心节点 ### License & Copyright -Copyright (c) 2014-2018 Beijing Duizhan Tech, Inc., All rights reserved. +Copyright (c) 2014-2019 Beijing Duizhan Tech, Inc., All rights reserved. Licensed under The GNU General Public License version 2 (GPLv2) (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at diff --git a/apps/__init__.py b/apps/__init__.py index 5f076f504..f62c895b3 100644 --- a/apps/__init__.py +++ b/apps/__init__.py @@ -1,5 +1,4 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- # - -__version__ = "1.4.8" +__version__ = "1.4.9" diff --git a/apps/assets/api/__init__.py b/apps/assets/api/__init__.py index 1d7dbca00..b0efb6af8 100644 --- a/apps/assets/api/__init__.py +++ b/apps/assets/api/__init__.py @@ -5,3 +5,4 @@ from .system_user import * from .node import * from .domain import * from .cmd_filter import * +from .asset_user import * diff --git a/apps/assets/api/asset_user.py b/apps/assets/api/asset_user.py new file mode 100644 index 000000000..7000a95a5 --- /dev/null +++ b/apps/assets/api/asset_user.py @@ -0,0 +1,101 @@ +# -*- coding: utf-8 -*- +# + + +from rest_framework.response import Response +from rest_framework import viewsets, status, generics +from rest_framework.pagination import LimitOffsetPagination + +from common.permissions import IsOrgAdminOrAppUser +from common.utils import get_object_or_none, get_logger + +from ..backends.multi import AssetUserManager +from ..models import Asset +from .. import serializers +from ..tasks import test_asset_users_connectivity_manual + + +__all__ = [ + 'AssetUserViewSet', 'AssetUserAuthInfoApi', 'AssetUserTestConnectiveApi', +] + + +logger = get_logger(__name__) + + +class AssetUserViewSet(viewsets.GenericViewSet): + pagination_class = LimitOffsetPagination + serializer_class = serializers.AssetUserSerializer + permission_classes = (IsOrgAdminOrAppUser, ) + http_method_names = ['get', 'post'] + + def create(self, request, *args, **kwargs): + serializer = self.get_serializer(data=request.data) + serializer.is_valid(raise_exception=True) + serializer.save() + return Response(serializer.data, status=status.HTTP_201_CREATED) + + def list(self, request, *args, **kwargs): + queryset = self.filter_queryset(self.get_queryset()) + serializer = self.get_serializer(queryset, many=True) + return Response(serializer.data) + + def get_queryset(self): + username = self.request.GET.get('username') + asset_id = self.request.GET.get('asset_id') + asset = get_object_or_none(Asset, pk=asset_id) + queryset = AssetUserManager.filter(username=username, asset=asset) + return queryset + + def filter_queryset(self, queryset): + queryset = sorted( + queryset, + key=lambda q: (q.asset.hostname, q.connectivity, q.username) + ) + return queryset + + +class AssetUserAuthInfoApi(generics.RetrieveAPIView): + serializer_class = serializers.AssetUserAuthInfoSerializer + permission_classes = (IsOrgAdminOrAppUser,) + + def retrieve(self, request, *args, **kwargs): + instance = self.get_object() + serializer = self.get_serializer(instance) + status_code = status.HTTP_200_OK + if not instance: + status_code = status.HTTP_400_BAD_REQUEST + return Response(serializer.data, status=status_code) + + def get_object(self): + username = self.request.GET.get('username') + asset_id = self.request.GET.get('asset_id') + asset = get_object_or_none(Asset, pk=asset_id) + try: + instance = AssetUserManager.get(username, asset) + except Exception as e: + logger.error(e, exc_info=True) + return None + else: + return instance + + +class AssetUserTestConnectiveApi(generics.RetrieveAPIView): + """ + Test asset users connective + """ + + def get_asset_users(self): + username = self.request.GET.get('username') + asset_id = self.request.GET.get('asset_id') + asset = get_object_or_none(Asset, pk=asset_id) + asset_users = AssetUserManager.filter(username=username, asset=asset) + return asset_users + + def retrieve(self, request, *args, **kwargs): + asset_users = self.get_asset_users() + task = test_asset_users_connectivity_manual.delay(asset_users) + return Response({"task": task.id}) + + + diff --git a/apps/assets/api/domain.py b/apps/assets/api/domain.py index b9c4aa39b..27ea40a47 100644 --- a/apps/assets/api/domain.py +++ b/apps/assets/api/domain.py @@ -51,9 +51,10 @@ class GatewayTestConnectionApi(SingleObjectMixin, APIView): model = Gateway object = None - def get(self, request, *args, **kwargs): + def post(self, request, *args, **kwargs): self.object = self.get_object(Gateway.objects.all()) - ok, e = self.object.test_connective() + local_port = self.request.data.get('port') or self.object.port + ok, e = self.object.test_connective(local_port=local_port) if ok: return Response("ok") else: diff --git a/apps/assets/api/system_user.py b/apps/assets/api/system_user.py index 5c131f400..9805872e7 100644 --- a/apps/assets/api/system_user.py +++ b/apps/assets/api/system_user.py @@ -30,7 +30,7 @@ from ..tasks import push_system_user_to_assets_manual, \ logger = get_logger(__file__) __all__ = [ - 'SystemUserViewSet', 'SystemUserAuthInfoApi', + 'SystemUserViewSet', 'SystemUserAuthInfoApi', 'SystemUserAssetAuthInfoApi', 'SystemUserPushApi', 'SystemUserTestConnectiveApi', 'SystemUserAssetsListView', 'SystemUserPushToAssetApi', 'SystemUserTestAssetConnectivityApi', 'SystemUserCommandFilterRuleListApi', @@ -68,6 +68,22 @@ class SystemUserAuthInfoApi(generics.RetrieveUpdateDestroyAPIView): return Response(status=204) +class SystemUserAssetAuthInfoApi(generics.RetrieveAPIView): + """ + Get system user with asset auth info + """ + queryset = SystemUser.objects.all() + permission_classes = (IsOrgAdminOrAppUser,) + serializer_class = serializers.SystemUserAuthSerializer + + def get_object(self): + instance = super().get_object() + aid = self.kwargs.get('aid') + asset = get_object_or_404(Asset, pk=aid) + instance.load_specific_asset_auth(asset) + return instance + + class SystemUserPushApi(generics.RetrieveAPIView): """ Push system user to cluster assets api diff --git a/apps/authentication/ldap/__init__.py b/apps/assets/backends/__init__.py similarity index 100% rename from apps/authentication/ldap/__init__.py rename to apps/assets/backends/__init__.py diff --git a/apps/assets/backends/base.py b/apps/assets/backends/base.py new file mode 100644 index 000000000..c93ea6a31 --- /dev/null +++ b/apps/assets/backends/base.py @@ -0,0 +1,60 @@ +# -*- coding: utf-8 -*- +# + +from django.core.exceptions import MultipleObjectsReturned, ObjectDoesNotExist +from abc import abstractmethod + + +class NotSupportError(Exception): + pass + + +class BaseBackend: + ObjectDoesNotExist = ObjectDoesNotExist + MultipleObjectsReturned = MultipleObjectsReturned + NotSupportError = NotSupportError + MSG_NOT_EXIST = '{} Object matching query does not exist' + MSG_MULTIPLE = '{} get() returned more than one object ' \ + '-- it returned {}!' + + @classmethod + def get(cls, username, asset): + instances = cls.filter(username, asset) + if len(instances) == 1: + return instances[0] + elif len(instances) == 0: + cls.raise_does_not_exist(cls.__name__) + else: + cls.raise_multiple_return(cls.__name__, len(instances)) + + @classmethod + @abstractmethod + def filter(cls, username=None, asset=None, latest=True): + """ + :param username: 用户名 + :param asset: 对象 + :param latest: 是否是最新记录 + :return: 元素为的可迭代对象( or ) + """ + pass + + @classmethod + @abstractmethod + def create(cls, **kwargs): + """ + :param kwargs: + { + name, username, asset, comment, password, public_key, private_key, + (org_id) + } + :return: 对象 + """ + pass + + @classmethod + def raise_does_not_exist(cls, name): + raise cls.ObjectDoesNotExist(cls.MSG_NOT_EXIST.format(name)) + + @classmethod + def raise_multiple_return(cls, name, length): + raise cls.MultipleObjectsReturned(cls.MSG_MULTIPLE.format(name, length)) diff --git a/apps/authentication/radius/__init__.py b/apps/assets/backends/external/__init__.py similarity index 100% rename from apps/authentication/radius/__init__.py rename to apps/assets/backends/external/__init__.py diff --git a/apps/assets/backends/external/db.py b/apps/assets/backends/external/db.py new file mode 100644 index 000000000..f3f6c16d6 --- /dev/null +++ b/apps/assets/backends/external/db.py @@ -0,0 +1,31 @@ +# -*- coding: utf-8 -*- +# + +from assets.models import AuthBook + +from ..base import BaseBackend + + +class AuthBookBackend(BaseBackend): + + @classmethod + def filter(cls, username=None, asset=None, latest=True): + queryset = AuthBook.objects.all() + if username: + queryset = queryset.filter(username=username) + if asset: + queryset = queryset.filter(asset=asset) + if latest: + queryset = queryset.latest_version() + return queryset + + @classmethod + def create(cls, **kwargs): + auth_info = { + 'password': kwargs.pop('password', ''), + 'public_key': kwargs.pop('public_key', ''), + 'private_key': kwargs.pop('private_key', '') + } + obj = AuthBook.objects.create(**kwargs) + obj.set_auth(**auth_info) + return obj diff --git a/apps/assets/backends/external/utils.py b/apps/assets/backends/external/utils.py new file mode 100644 index 000000000..62be16c1d --- /dev/null +++ b/apps/assets/backends/external/utils.py @@ -0,0 +1,16 @@ +# -*- coding: utf-8 -*- +# + +# from django.conf import settings + +from .db import AuthBookBackend +# from .vault import VaultBackend + + +def get_backend(): + default_backend = AuthBookBackend + + # if settings.BACKEND_ASSET_USER_AUTH_VAULT: + # return VaultBackend + + return default_backend diff --git a/apps/assets/backends/external/vault.py b/apps/assets/backends/external/vault.py new file mode 100644 index 000000000..da7583458 --- /dev/null +++ b/apps/assets/backends/external/vault.py @@ -0,0 +1,19 @@ +# -*- coding: utf-8 -*- +# + +from ..base import BaseBackend + + +class VaultBackend(BaseBackend): + + @classmethod + def get(cls, username, asset): + pass + + @classmethod + def filter(cls, username=None, asset=None, latest=True): + pass + + @classmethod + def create(cls, **kwargs): + pass diff --git a/apps/assets/backends/internal/__init__.py b/apps/assets/backends/internal/__init__.py new file mode 100644 index 000000000..f19a64d9a --- /dev/null +++ b/apps/assets/backends/internal/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- +# + + diff --git a/apps/assets/backends/internal/admin_user.py b/apps/assets/backends/internal/admin_user.py new file mode 100644 index 000000000..e67b41fc9 --- /dev/null +++ b/apps/assets/backends/internal/admin_user.py @@ -0,0 +1,38 @@ +# -*- coding: utf-8 -*- +# + +from assets.models import Asset + +from ..base import BaseBackend +from .utils import construct_authbook_object + + +class AdminUserBackend(BaseBackend): + + @classmethod + def filter(cls, username=None, asset=None, **kwargs): + instances = cls.construct_authbook_objects(username, asset) + return instances + + @classmethod + def _get_assets(cls, asset): + if not asset: + assets = Asset.objects.all().prefetch_related('admin_user') + else: + assets = [asset] + return assets + + @classmethod + def construct_authbook_objects(cls, username, asset): + instances = [] + assets = cls._get_assets(asset) + for asset in assets: + if username and asset.admin_user.username != username: + continue + instance = construct_authbook_object(asset.admin_user, asset) + instances.append(instance) + return instances + + @classmethod + def create(cls, **kwargs): + raise cls.NotSupportError("Not support create") diff --git a/apps/assets/backends/internal/asset_user.py b/apps/assets/backends/internal/asset_user.py new file mode 100644 index 000000000..8502cf5d9 --- /dev/null +++ b/apps/assets/backends/internal/asset_user.py @@ -0,0 +1,32 @@ +# -*- coding: utf-8 -*- +# + +from ..base import BaseBackend +from .admin_user import AdminUserBackend +from .system_user import SystemUserBackend + + +class AssetUserBackend(BaseBackend): + @classmethod + def filter(cls, username=None, asset=None, **kwargs): + admin_user_instances = AdminUserBackend.filter(username, asset) + system_user_instances = SystemUserBackend.filter(username, asset) + instances = cls._merge_instances(admin_user_instances, system_user_instances) + return instances + + @classmethod + def _merge_instances(cls, admin_user_instances, system_user_instances): + admin_user_instances_keyword_list = [ + {'username': instance.username, 'asset': instance.asset} + for instance in admin_user_instances + ] + instances = [ + instance for instance in system_user_instances + if instance.keyword not in admin_user_instances_keyword_list + ] + admin_user_instances.extend(instances) + return admin_user_instances + + @classmethod + def create(cls, **kwargs): + raise cls.NotSupportError("Not support create") diff --git a/apps/assets/backends/internal/system_user.py b/apps/assets/backends/internal/system_user.py new file mode 100644 index 000000000..52b22215c --- /dev/null +++ b/apps/assets/backends/internal/system_user.py @@ -0,0 +1,75 @@ +# -*- coding: utf-8 -*- +# + +import itertools + +from assets.models import Asset + +from ..base import BaseBackend +from .utils import construct_authbook_object + + +class SystemUserBackend(BaseBackend): + + @classmethod + def filter(cls, username=None, asset=None, **kwargs): + instances = cls.construct_authbook_objects(username, asset) + return instances + + @classmethod + def _distinct_system_users_by_username(cls, system_users): + system_users = sorted( + system_users, + key=lambda su: (su.username, su.priority, su.date_updated), + reverse=True, + ) + results = itertools.groupby(system_users, key=lambda su: su.username) + system_users = [next(result[1]) for result in results] + return system_users + + @classmethod + def _filter_system_users_by_username(cls, system_users, username): + _system_users = cls._distinct_system_users_by_username(system_users) + if username: + _system_users = [su for su in _system_users if username == su.username] + return _system_users + + @classmethod + def _construct_authbook_objects(cls, system_users, asset): + instances = [] + for system_user in system_users: + instance = construct_authbook_object(system_user, asset) + instances.append(instance) + return instances + + @classmethod + def _get_assets_with_system_users(cls, asset=None): + """ + { 'asset': set(, , ...) } + """ + if not asset: + _assets = Asset.objects.all().prefetch_related('systemuser_set') + else: + _assets = [asset] + + assets = {asset: set(asset.systemuser_set.all()) for asset in _assets} + return assets + + @classmethod + def construct_authbook_objects(cls, username, asset): + """ + :return: [, , ...] + """ + instances = [] + assets = cls._get_assets_with_system_users(asset) + for _asset, _system_users in assets.items(): + _system_users = cls._filter_system_users_by_username(_system_users, username) + _instances = cls._construct_authbook_objects(_system_users, _asset) + instances.extend(_instances) + return instances + + @classmethod + def create(cls, **kwargs): + raise Exception("Not support create") + + diff --git a/apps/assets/backends/internal/utils.py b/apps/assets/backends/internal/utils.py new file mode 100644 index 000000000..65b4fa821 --- /dev/null +++ b/apps/assets/backends/internal/utils.py @@ -0,0 +1,26 @@ +# -*- coding: utf-8 -*- +# + +from assets.models import AuthBook + + +def construct_authbook_object(asset_user, asset): + """ + 作用: 将对象构造成为对象并返回 + + :param asset_user: 对象 + :param asset: 对象 + :return: 对象 + """ + fields = [ + 'id', 'name', 'username', 'comment', 'org_id', + '_password', '_private_key', '_public_key', + 'date_created', 'date_updated', 'created_by' + ] + + obj = AuthBook(asset=asset, version=0, is_latest=True) + for field in fields: + value = getattr(asset_user, field) + setattr(obj, field, value) + return obj + diff --git a/apps/assets/backends/multi.py b/apps/assets/backends/multi.py new file mode 100644 index 000000000..785176885 --- /dev/null +++ b/apps/assets/backends/multi.py @@ -0,0 +1,40 @@ +# -*- coding: utf-8 -*- +# + +from .base import BaseBackend + +from .external.utils import get_backend +from .internal.asset_user import AssetUserBackend + + +class AssetUserManager(BaseBackend): + """ + 资产用户管理器 + """ + external_backend = get_backend() + internal_backend = AssetUserBackend + + @classmethod + def filter(cls, username=None, asset=None, **kwargs): + external_instance = list(cls.external_backend.filter(username, asset)) + internal_instance = list(cls.internal_backend.filter(username, asset)) + instances = cls._merge_instances(external_instance, internal_instance) + return instances + + @classmethod + def create(cls, **kwargs): + instance = cls.external_backend.create(**kwargs) + return instance + + @classmethod + def _merge_instances(cls, external_instances, internal_instances): + external_instances_keyword_list = [ + {'username': instance.username, 'asset': instance.asset} + for instance in external_instances + ] + instances = [ + instance for instance in internal_instances + if instance.keyword not in external_instances_keyword_list + ] + external_instances.extend(instances) + return external_instances diff --git a/apps/assets/const.py b/apps/assets/const.py index 7cee7aedd..901ade1ff 100644 --- a/apps/assets/const.py +++ b/apps/assets/const.py @@ -32,6 +32,18 @@ TEST_SYSTEM_USER_CONN_TASKS = [ } ] + +ASSET_USER_CONN_CACHE_KEY = 'ASSET_USER_CONN_{}_{}' +TEST_ASSET_USER_CONN_TASKS = [ + { + "name": "ping", + "action": { + "module": "ping", + } + } +] + + TASK_OPTIONS = { 'timeout': 10, 'forks': 10, diff --git a/apps/assets/forms/asset.py b/apps/assets/forms/asset.py index 0a6b2f093..774867a6b 100644 --- a/apps/assets/forms/asset.py +++ b/apps/assets/forms/asset.py @@ -97,24 +97,12 @@ class AssetBulkUpdateForm(OrgModelForm): } ) ) - port = forms.IntegerField( - label=_('Port'), required=False, min_value=1, max_value=65535, - ) - admin_user = forms.ModelChoiceField( - required=False, queryset=AdminUser.objects, - label=_("Admin user"), - widget=forms.Select( - attrs={ - 'class': 'select2', - 'data-placeholder': _('Admin user') - } - ) - ) class Meta: model = Asset fields = [ - 'assets', 'port', 'admin_user', 'labels', 'nodes', 'platform' + 'assets', 'port', 'admin_user', 'labels', 'platform', + 'protocol', 'domain', ] widgets = { 'labels': forms.SelectMultiple( @@ -125,6 +113,13 @@ class AssetBulkUpdateForm(OrgModelForm): ), } + def __init__(self, *args, **kwargs): + super().__init__(*args, **kwargs) + # 重写其他字段为不再required + for name, field in self.fields.items(): + if name != 'assets': + field.required = False + def save(self, commit=True): changed_fields = [] for field in self._meta.fields: diff --git a/apps/assets/forms/domain.py b/apps/assets/forms/domain.py index 25295782a..5a88a1dd7 100644 --- a/apps/assets/forms/domain.py +++ b/apps/assets/forms/domain.py @@ -66,6 +66,9 @@ class GatewayForm(PasswordAndKeyAuthForm, OrgModelForm): 'name', 'ip', 'port', 'username', 'protocol', 'domain', 'password', 'private_key_file', 'is_active', 'comment', ] + help_texts = { + 'protocol': _("SSH gateway support proxy SSH,RDP,VNC") + } widgets = { 'name': forms.TextInput(attrs={'placeholder': _('Name')}), 'username': forms.TextInput(attrs={'placeholder': _('Username')}), diff --git a/apps/assets/forms/user.py b/apps/assets/forms/user.py index 575d3e59c..e832ab158 100644 --- a/apps/assets/forms/user.py +++ b/apps/assets/forms/user.py @@ -35,8 +35,12 @@ class PasswordAndKeyAuthForm(forms.ModelForm): if private_key_file: key_string = private_key_file.read() private_key_file.seek(0) + key_string = key_string.decode() + if not validate_ssh_private_key(key_string, password): - raise forms.ValidationError(_('Invalid private key')) + msg = _('Invalid private key, Only support ' + 'RSA/DSA format key') + raise forms.ValidationError(msg) return private_key_file def validate_password_key(self): @@ -150,5 +154,6 @@ class SystemUserForm(OrgModelForm, PasswordAndKeyAuthForm): 'priority': _('1-100, High level will be using login asset as default, ' 'if user was granted more than 2 system user'), 'login_mode': _('If you choose manual login mode, you do not ' - 'need to fill in the username and password.') + 'need to fill in the username and password.'), + 'sudo': _("Use comma split multi command, ex: /bin/whoami,/bin/ifconfig") } diff --git a/apps/assets/migrations/0002_auto_20180105_1807_squashed_0009_auto_20180307_1212.py b/apps/assets/migrations/0002_auto_20180105_1807_squashed_0009_auto_20180307_1212.py new file mode 100644 index 000000000..7cbf78a43 --- /dev/null +++ b/apps/assets/migrations/0002_auto_20180105_1807_squashed_0009_auto_20180307_1212.py @@ -0,0 +1,158 @@ +# Generated by Django 2.1.7 on 2019-02-28 10:16 + +import assets.models.asset +from django.db import migrations, models +import django.db.models.deletion +import uuid + + +class Migration(migrations.Migration): + + replaces = [('assets', '0002_auto_20180105_1807'), ('assets', '0003_auto_20180109_2331'), ('assets', '0004_auto_20180125_1218'), ('assets', '0005_auto_20180126_1637'), ('assets', '0006_auto_20180130_1502'), ('assets', '0007_auto_20180225_1815'), ('assets', '0008_auto_20180306_1804'), ('assets', '0009_auto_20180307_1212')] + + dependencies = [ + ('assets', '0001_initial'), + ] + + operations = [ + migrations.AlterModelOptions( + name='adminuser', + options={'ordering': ['name'], 'verbose_name': 'Admin user'}, + ), + migrations.AlterModelOptions( + name='asset', + options={'verbose_name': 'Asset'}, + ), + migrations.AlterModelOptions( + name='assetgroup', + options={'ordering': ['name'], 'verbose_name': 'Asset group'}, + ), + migrations.AlterModelOptions( + name='cluster', + options={'ordering': ['name'], 'verbose_name': 'Cluster'}, + ), + migrations.AlterModelOptions( + name='systemuser', + options={'ordering': ['name'], 'verbose_name': 'System user'}, + ), + migrations.RemoveField( + model_name='asset', + name='cluster', + ), + migrations.AlterField( + model_name='assetgroup', + name='created_by', + field=models.CharField(blank=True, max_length=32, null=True, verbose_name='Created by'), + ), + migrations.CreateModel( + name='Label', + fields=[ + ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=128, verbose_name='Name')), + ('value', models.CharField(max_length=128, verbose_name='Value')), + ('category', models.CharField(choices=[('S', 'System'), ('U', 'User')], default='U', max_length=128, verbose_name='Category')), + ('is_active', models.BooleanField(default=True, verbose_name='Is active')), + ('comment', models.TextField(blank=True, null=True, verbose_name='Comment')), + ('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')), + ], + options={ + 'db_table': 'assets_label', + }, + ), + migrations.AlterUniqueTogether( + name='label', + unique_together={('name', 'value')}, + ), + migrations.AddField( + model_name='asset', + name='labels', + field=models.ManyToManyField(blank=True, related_name='assets', to='assets.Label', verbose_name='Labels'), + ), + migrations.RemoveField( + model_name='asset', + name='cabinet_no', + ), + migrations.RemoveField( + model_name='asset', + name='cabinet_pos', + ), + migrations.RemoveField( + model_name='asset', + name='env', + ), + migrations.RemoveField( + model_name='asset', + name='remote_card_ip', + ), + migrations.RemoveField( + model_name='asset', + name='status', + ), + migrations.RemoveField( + model_name='asset', + name='type', + ), + migrations.CreateModel( + name='Node', + fields=[ + ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), + ('key', models.CharField(max_length=64, unique=True, verbose_name='Key')), + ('value', models.CharField(max_length=128, verbose_name='Value')), + ('child_mark', models.IntegerField(default=0)), + ('date_create', models.DateTimeField(auto_now_add=True)), + ], + ), + migrations.RemoveField( + model_name='asset', + name='groups', + ), + migrations.RemoveField( + model_name='systemuser', + name='cluster', + ), + migrations.AlterField( + model_name='asset', + name='admin_user', + field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.PROTECT, to='assets.AdminUser', verbose_name='Admin user'), + ), + migrations.AlterField( + model_name='systemuser', + name='protocol', + field=models.CharField(choices=[('ssh', 'ssh'), ('rdp', 'rdp')], default='ssh', max_length=16, verbose_name='Protocol'), + ), + migrations.AddField( + model_name='asset', + name='nodes', + field=models.ManyToManyField(default=assets.models.asset.default_node, related_name='assets', to='assets.Node', verbose_name='Nodes'), + ), + migrations.AddField( + model_name='systemuser', + name='nodes', + field=models.ManyToManyField(blank=True, to='assets.Node', verbose_name='Nodes'), + ), + migrations.AlterField( + model_name='adminuser', + name='created_by', + field=models.CharField(max_length=128, null=True, verbose_name='Created by'), + ), + migrations.AlterField( + model_name='adminuser', + name='username', + field=models.CharField(max_length=128, verbose_name='Username'), + ), + migrations.AlterField( + model_name='asset', + name='platform', + field=models.CharField(choices=[('Linux', 'Linux'), ('Unix', 'Unix'), ('MacOS', 'MacOS'), ('BSD', 'BSD'), ('Windows', 'Windows'), ('Other', 'Other')], default='Linux', max_length=128, verbose_name='Platform'), + ), + migrations.AlterField( + model_name='systemuser', + name='created_by', + field=models.CharField(max_length=128, null=True, verbose_name='Created by'), + ), + migrations.AlterField( + model_name='systemuser', + name='username', + field=models.CharField(max_length=128, verbose_name='Username'), + ), + ] diff --git a/apps/assets/migrations/0010_auto_20180307_1749_squashed_0019_auto_20180816_1320.py b/apps/assets/migrations/0010_auto_20180307_1749_squashed_0019_auto_20180816_1320.py new file mode 100644 index 000000000..364e36d1f --- /dev/null +++ b/apps/assets/migrations/0010_auto_20180307_1749_squashed_0019_auto_20180816_1320.py @@ -0,0 +1,220 @@ +# Generated by Django 2.1.7 on 2019-02-28 10:16 + +import assets.models.utils +import django.core.validators +from django.db import migrations, models +import django.db.models.deletion +import uuid + + +# Functions from the following migrations need manual copying. +# Move them and any dependencies into this file, then update the +# RunPython operations to refer to the local versions: +# assets.migrations.0017_auto_20180702_1415 + +def migrate_win_to_ssh_protocol(apps, schema_editor): + asset_model = apps.get_model("assets", "Asset") + db_alias = schema_editor.connection.alias + asset_model.objects.using(db_alias).filter(platform__startswith='Win').update(protocol='rdp') + + +class Migration(migrations.Migration): + + replaces = [('assets', '0010_auto_20180307_1749'), ('assets', '0011_auto_20180326_0957'), ('assets', '0012_auto_20180404_1302'), ('assets', '0013_auto_20180411_1135'), ('assets', '0014_auto_20180427_1245'), ('assets', '0015_auto_20180510_1235'), ('assets', '0016_auto_20180511_1203'), ('assets', '0017_auto_20180702_1415'), ('assets', '0018_auto_20180807_1116'), ('assets', '0019_auto_20180816_1320')] + + dependencies = [ + ('assets', '0009_auto_20180307_1212'), + ] + + operations = [ + migrations.AlterField( + model_name='node', + name='value', + field=models.CharField(max_length=128, unique=True, verbose_name='Value'), + ), + migrations.CreateModel( + name='Domain', + fields=[ + ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=128, unique=True, verbose_name='Name')), + ('comment', models.TextField(blank=True, verbose_name='Comment')), + ('date_created', models.DateTimeField(auto_now_add=True, null=True, verbose_name='Date created')), + ], + ), + migrations.CreateModel( + name='Gateway', + fields=[ + ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=128, unique=True, verbose_name='Name')), + ('username', models.CharField(blank=True, max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username')), + ('_password', models.CharField(blank=True, max_length=256, null=True, verbose_name='Password')), + ('_private_key', models.TextField(blank=True, max_length=4096, null=True, validators=[assets.models.utils.private_key_validator], verbose_name='SSH private key')), + ('_public_key', models.TextField(blank=True, max_length=4096, verbose_name='SSH public key')), + ('date_created', models.DateTimeField(auto_now_add=True)), + ('date_updated', models.DateTimeField(auto_now=True)), + ('created_by', models.CharField(max_length=128, null=True, verbose_name='Created by')), + ('ip', models.GenericIPAddressField(db_index=True, verbose_name='IP')), + ('port', models.IntegerField(default=22, verbose_name='Port')), + ('protocol', models.CharField(choices=[('ssh', 'ssh'), ('rdp', 'rdp')], default='ssh', max_length=16, verbose_name='Protocol')), + ('comment', models.CharField(blank=True, max_length=128, null=True, verbose_name='Comment')), + ('is_active', models.BooleanField(default=True, verbose_name='Is active')), + ('domain', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Domain', verbose_name='Domain')), + ], + options={ + 'abstract': False, + }, + ), + migrations.AddField( + model_name='asset', + name='domain', + field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='assets', to='assets.Domain', verbose_name='Domain'), + ), + migrations.AddField( + model_name='systemuser', + name='assets', + field=models.ManyToManyField(blank=True, to='assets.Asset', verbose_name='Assets'), + ), + migrations.AlterField( + model_name='systemuser', + name='sudo', + field=models.TextField(default='/bin/whoami', verbose_name='Sudo'), + ), + migrations.AlterField( + model_name='adminuser', + name='username', + field=models.CharField(max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_-]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.AlterField( + model_name='systemuser', + name='username', + field=models.CharField(max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_-]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.AlterField( + model_name='adminuser', + name='username', + field=models.CharField(max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.AlterField( + model_name='systemuser', + name='username', + field=models.CharField(max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.AlterField( + model_name='node', + name='value', + field=models.CharField(max_length=128, verbose_name='Value'), + ), + migrations.AddField( + model_name='asset', + name='protocol', + field=models.CharField(choices=[('ssh', 'ssh'), ('rdp', 'rdp'), ('telnet', 'telnet (beta)')], default='ssh', max_length=128, verbose_name='Protocol'), + ), + migrations.AddField( + model_name='systemuser', + name='login_mode', + field=models.CharField(choices=[('auto', 'Automatic login'), ('manual', 'Manually login')], default='auto', max_length=10, verbose_name='Login mode'), + ), + migrations.AlterField( + model_name='adminuser', + name='username', + field=models.CharField(blank=True, max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.AlterField( + model_name='asset', + name='platform', + field=models.CharField(choices=[('Linux', 'Linux'), ('Unix', 'Unix'), ('MacOS', 'MacOS'), ('BSD', 'BSD'), ('Windows', 'Windows'), ('Windows2016', 'Windows(2016)'), ('Other', 'Other')], default='Linux', max_length=128, verbose_name='Platform'), + ), + migrations.AlterField( + model_name='systemuser', + name='protocol', + field=models.CharField(choices=[('ssh', 'ssh'), ('rdp', 'rdp'), ('telnet', 'telnet (beta)')], default='ssh', max_length=16, verbose_name='Protocol'), + ), + migrations.AlterField( + model_name='systemuser', + name='username', + field=models.CharField(blank=True, max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username'), + ), + migrations.RunPython( + code=migrate_win_to_ssh_protocol, + ), + migrations.AddField( + model_name='adminuser', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='asset', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='domain', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='gateway', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='label', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='node', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AddField( + model_name='systemuser', + name='org_id', + field=models.CharField(blank=True, default=None, max_length=36, null=True), + ), + migrations.AlterField( + model_name='adminuser', + name='name', + field=models.CharField(max_length=128, verbose_name='Name'), + ), + migrations.AlterField( + model_name='asset', + name='hostname', + field=models.CharField(max_length=128, verbose_name='Hostname'), + ), + migrations.AlterField( + model_name='gateway', + name='name', + field=models.CharField(max_length=128, verbose_name='Name'), + ), + migrations.AlterField( + model_name='systemuser', + name='name', + field=models.CharField(max_length=128, verbose_name='Name'), + ), + migrations.AlterUniqueTogether( + name='adminuser', + unique_together={('name', 'org_id')}, + ), + migrations.AddField( + model_name='asset', + name='cpu_vcpus', + field=models.IntegerField(null=True, verbose_name='CPU vcpus'), + ), + migrations.AlterUniqueTogether( + name='asset', + unique_together={('org_id', 'hostname')}, + ), + migrations.AlterUniqueTogether( + name='gateway', + unique_together={('name', 'org_id')}, + ), + migrations.AlterUniqueTogether( + name='systemuser', + unique_together={('name', 'org_id')}, + ), + migrations.AlterUniqueTogether( + name='label', + unique_together={('name', 'value', 'org_id')}, + ), + ] diff --git a/apps/assets/migrations/0026_auto_20190325_2035.py b/apps/assets/migrations/0026_auto_20190325_2035.py new file mode 100644 index 000000000..c329658e0 --- /dev/null +++ b/apps/assets/migrations/0026_auto_20190325_2035.py @@ -0,0 +1,43 @@ +# Generated by Django 2.1.7 on 2019-03-25 12:35 + +import assets.models.utils +import django.core.validators +from django.db import migrations, models +import django.db.models.deletion +import uuid + + +class Migration(migrations.Migration): + + dependencies = [ + ('assets', '0025_auto_20190221_1902'), + ] + + operations = [ + migrations.CreateModel( + name='AuthBook', + fields=[ + ('org_id', models.CharField(blank=True, db_index=True, default='', max_length=36, verbose_name='Organization')), + ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)), + ('name', models.CharField(max_length=128, verbose_name='Name')), + ('username', models.CharField(blank=True, max_length=32, validators=[django.core.validators.RegexValidator('^[0-9a-zA-Z_@\\-\\.]*$', 'Special char not allowed')], verbose_name='Username')), + ('_password', models.CharField(blank=True, max_length=256, null=True, verbose_name='Password')), + ('_private_key', models.TextField(blank=True, max_length=4096, null=True, validators=[assets.models.utils.private_key_validator], verbose_name='SSH private key')), + ('_public_key', models.TextField(blank=True, max_length=4096, verbose_name='SSH public key')), + ('comment', models.TextField(blank=True, verbose_name='Comment')), + ('date_created', models.DateTimeField(auto_now_add=True)), + ('date_updated', models.DateTimeField(auto_now=True)), + ('created_by', models.CharField(max_length=128, null=True, verbose_name='Created by')), + ('is_latest', models.BooleanField(default=False, verbose_name='Latest version')), + ('version', models.IntegerField(default=1, verbose_name='Version')), + ('asset', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='assets.Asset', verbose_name='Asset')), + ], + options={ + 'verbose_name': 'AuthBook', + }, + ), + migrations.AlterModelOptions( + name='node', + options={'ordering': ['key'], 'verbose_name': 'Node'}, + ), + ] diff --git a/apps/assets/models/__init__.py b/apps/assets/models/__init__.py index c60830fba..b87a18796 100644 --- a/apps/assets/models/__init__.py +++ b/apps/assets/models/__init__.py @@ -7,3 +7,4 @@ from .node import * from .asset import * from .cmd_filter import * from .utils import * +from .authbook import * diff --git a/apps/assets/models/asset.py b/apps/assets/models/asset.py index 244c2b7e7..5ad9830f3 100644 --- a/apps/assets/models/asset.py +++ b/apps/assets/models/asset.py @@ -197,6 +197,7 @@ class Asset(OrgModelMixin): def get_auth_info(self): if self.admin_user: + self.admin_user.load_specific_asset_auth(self) return { 'username': self.admin_user.username, 'password': self.admin_user.password, @@ -232,6 +233,7 @@ class Asset(OrgModelMixin): """ data = self.to_json() if self.admin_user: + self.admin_user.load_specific_asset_auth(self) admin_user = self.admin_user data.update({ 'username': admin_user.username, diff --git a/apps/assets/models/authbook.py b/apps/assets/models/authbook.py new file mode 100644 index 000000000..a040bbd0d --- /dev/null +++ b/apps/assets/models/authbook.py @@ -0,0 +1,93 @@ +# -*- coding: utf-8 -*- +# + +from django.db import models +from django.utils.translation import ugettext_lazy as _ +from django.core.cache import cache + +from orgs.mixins import OrgManager + +from .base import AssetUser +from ..const import ASSET_USER_CONN_CACHE_KEY + +__all__ = ['AuthBook'] + + +class AuthBookQuerySet(models.QuerySet): + + def latest_version(self): + return self.filter(is_latest=True) + + +class AuthBookManager(OrgManager): + pass + + +class AuthBook(AssetUser): + asset = models.ForeignKey('assets.Asset', on_delete=models.CASCADE, verbose_name=_('Asset')) + is_latest = models.BooleanField(default=False, verbose_name=_('Latest version')) + version = models.IntegerField(default=1, verbose_name=_('Version')) + + objects = AuthBookManager.from_queryset(AuthBookQuerySet)() + + class Meta: + verbose_name = _('AuthBook') + + def _set_latest(self): + self._remove_pre_obj_latest() + self.is_latest = True + self.save() + + def _get_pre_obj(self): + pre_obj = self.__class__.objects.filter( + username=self.username, asset=self.asset).latest_version().first() + return pre_obj + + def _remove_pre_obj_latest(self): + pre_obj = self._get_pre_obj() + if pre_obj: + pre_obj.is_latest = False + pre_obj.save() + + def _set_version(self): + pre_obj = self._get_pre_obj() + if pre_obj: + self.version = pre_obj.version + 1 + else: + self.version = 1 + self.save() + + def set_version_and_latest(self): + self._set_version() + self._set_latest() + + @property + def _conn_cache_key(self): + return ASSET_USER_CONN_CACHE_KEY.format(self.id, self.asset.id) + + @property + def connectivity(self): + value = cache.get(self._conn_cache_key, self.UNKNOWN) + return value + + @connectivity.setter + def connectivity(self, value): + _connectivity = self.UNKNOWN + + for host in value.get('dark', {}).keys(): + if host == self.asset.hostname: + _connectivity = self.UNREACHABLE + + for host in value.get('contacted', {}).keys(): + if host == self.asset.hostname: + _connectivity = self.REACHABLE + + cache.set(self._conn_cache_key, _connectivity, 3600) + + @property + def keyword(self): + return {'username': self.username, 'asset': self.asset} + + def __str__(self): + return '{}@{}'.format(self.username, self.asset) + diff --git a/apps/assets/models/base.py b/apps/assets/models/base.py index 37e099e99..30d8ae0f5 100644 --- a/apps/assets/models/base.py +++ b/apps/assets/models/base.py @@ -9,13 +9,17 @@ from django.db import models from django.utils.translation import ugettext_lazy as _ from django.conf import settings -from common.utils import get_signer, ssh_key_string_to_obj, ssh_key_gen +from common.utils import ( + get_signer, ssh_key_string_to_obj, ssh_key_gen, get_logger +) from common.validators import alphanumeric from orgs.mixins import OrgModelMixin from .utils import private_key_validator signer = get_signer() +logger = get_logger(__file__) + class AssetUser(OrgModelMixin): id = models.UUIDField(default=uuid.uuid4, primary_key=True) @@ -45,8 +49,8 @@ class AssetUser(OrgModelMixin): @password.setter def password(self, password_raw): - raise AttributeError("Using set_auth do that") - # self._password = signer.sign(password_raw) + # raise AttributeError("Using set_auth do that") + self._password = signer.sign(password_raw) @property def private_key(self): @@ -55,8 +59,8 @@ class AssetUser(OrgModelMixin): @private_key.setter def private_key(self, private_key_raw): - raise AttributeError("Using set_auth do that") - # self._private_key = signer.sign(private_key_raw) + # raise AttributeError("Using set_auth do that") + self._private_key = signer.sign(private_key_raw) @property def private_key_obj(self): @@ -88,6 +92,11 @@ class AssetUser(OrgModelMixin): else: return None + @public_key.setter + def public_key(self, public_key_raw): + # raise AttributeError("Using set_auth do that") + self._public_key = signer.sign(public_key_raw) + @property def public_key_obj(self): if self.public_key: @@ -115,6 +124,25 @@ class AssetUser(OrgModelMixin): def get_auth(self, asset=None): pass + def load_specific_asset_auth(self, asset): + from ..backends.multi import AssetUserManager + try: + other = AssetUserManager.get(username=self.username, asset=asset) + except Exception as e: + logger.error(e, exc_info=True) + else: + self._merge_auth(other) + + def _merge_auth(self, other): + if not other: + return + if other.password: + self.password = other.password + if other.public_key: + self.public_key = other.public_key + if other.private_key: + self.private_key = other.private_key + def clear_auth(self): self._password = '' self._private_key = '' diff --git a/apps/assets/models/domain.py b/apps/assets/models/domain.py index 7272a60fd..5deefc35c 100644 --- a/apps/assets/models/domain.py +++ b/apps/assets/models/domain.py @@ -60,7 +60,9 @@ class Gateway(AssetUser): unique_together = [('name', 'org_id')] verbose_name = _("Gateway") - def test_connective(self): + def test_connective(self, local_port=None): + if local_port is None: + local_port = self.port client = paramiko.SSHClient() client.set_missing_host_key_policy(paramiko.AutoAddPolicy()) proxy = paramiko.SSHClient() @@ -76,12 +78,11 @@ class Gateway(AssetUser): paramiko.SSHException) as e: return False, str(e) - sock = proxy.get_transport().open_channel( - 'direct-tcpip', ('127.0.0.1', self.port), ('127.0.0.1', 0) - ) - try: - client.connect("127.0.0.1", port=self.port, + sock = proxy.get_transport().open_channel( + 'direct-tcpip', ('127.0.0.1', local_port), ('127.0.0.1', 0) + ) + client.connect("127.0.0.1", port=local_port, username=self.username, password=self.password, key_filename=self.private_key_file, diff --git a/apps/assets/models/node.py b/apps/assets/models/node.py index 449c8e310..e5e25c770 100644 --- a/apps/assets/models/node.py +++ b/apps/assets/models/node.py @@ -29,6 +29,7 @@ class Node(OrgModelMixin): class Meta: verbose_name = _("Node") + ordering = ['key'] def __str__(self): return self.full_value @@ -275,7 +276,8 @@ class Node(OrgModelMixin): @classmethod def default_node(cls): defaults = {'value': 'Default'} - return cls.objects.get_or_create(defaults=defaults, key='1') + obj, created = cls.objects.get_or_create(defaults=defaults, key='1') + return obj def as_tree_node(self): from common.tree import TreeNode diff --git a/apps/assets/serializers/__init__.py b/apps/assets/serializers/__init__.py index ad4439be3..f9866688d 100644 --- a/apps/assets/serializers/__init__.py +++ b/apps/assets/serializers/__init__.py @@ -8,3 +8,4 @@ from .system_user import * from .node import * from .domain import * from .cmd_filter import * +from .asset_user import * diff --git a/apps/assets/serializers/asset_user.py b/apps/assets/serializers/asset_user.py new file mode 100644 index 000000000..f7345437e --- /dev/null +++ b/apps/assets/serializers/asset_user.py @@ -0,0 +1,65 @@ +# -*- coding: utf-8 -*- +# + +from django.utils.translation import ugettext as _ +from rest_framework import serializers + +from ..models import AuthBook +from ..backends.multi import AssetUserManager + +__all__ = [ + 'AssetUserSerializer', 'AssetUserAuthInfoSerializer', +] + + +class AssetUserSerializer(serializers.ModelSerializer): + + password = serializers.CharField( + max_length=256, allow_blank=True, allow_null=True, write_only=True, + required=False, help_text=_('Password') + ) + public_key = serializers.CharField( + max_length=4096, allow_blank=True, allow_null=True, write_only=True, + required=False, help_text=_('Public key') + ) + private_key = serializers.CharField( + max_length=4096, allow_blank=True, allow_null=True, write_only=True, + required=False, help_text=_('Private key') + ) + + class Meta: + model = AuthBook + read_only_fields = ( + 'date_created', 'date_updated', 'created_by', + 'is_latest', 'version', 'connectivity', + ) + fields = '__all__' + extra_kwargs = { + 'username': {'required': True} + } + + def get_field_names(self, declared_fields, info): + fields = super().get_field_names(declared_fields, info) + fields = [f for f in fields if not f.startswith('_') and f != 'id'] + fields.extend(['connectivity']) + return fields + + def create(self, validated_data): + kwargs = { + 'name': validated_data.get('name'), + 'username': validated_data.get('username'), + 'asset': validated_data.get('asset'), + 'comment': validated_data.get('comment', ''), + 'org_id': validated_data.get('org_id', ''), + 'password': validated_data.get('password'), + 'public_key': validated_data.get('public_key'), + 'private_key': validated_data.get('private_key') + } + instance = AssetUserManager.create(**kwargs) + return instance + + +class AssetUserAuthInfoSerializer(serializers.ModelSerializer): + class Meta: + model = AuthBook + fields = ['password', 'private_key', 'public_key'] diff --git a/apps/assets/serializers/node.py b/apps/assets/serializers/node.py index 79c573c60..f0ff3062b 100644 --- a/apps/assets/serializers/node.py +++ b/apps/assets/serializers/node.py @@ -1,10 +1,7 @@ # -*- coding: utf-8 -*- from rest_framework import serializers -from rest_framework_bulk.serializers import BulkListSerializer -from common.mixins import BulkSerializerMixin from ..models import Asset, Node -from .asset import AssetGrantedSerializer __all__ = [ @@ -22,7 +19,7 @@ class NodeSerializer(serializers.ModelSerializer): 'id', 'key', 'value', 'assets_amount', 'org_id', ] read_only_fields = [ - 'id', 'key', 'assets_amount', 'org_id', + 'key', 'assets_amount', 'org_id', ] def validate_value(self, data): diff --git a/apps/assets/signals.py b/apps/assets/signals.py deleted file mode 100644 index 20da657b1..000000000 --- a/apps/assets/signals.py +++ /dev/null @@ -1,5 +0,0 @@ -# -*- coding: utf-8 -*- -# -from django.dispatch import Signal - -on_app_ready = Signal() diff --git a/apps/assets/signals_handler.py b/apps/assets/signals_handler.py index 7d3b67f6c..4afb97e75 100644 --- a/apps/assets/signals_handler.py +++ b/apps/assets/signals_handler.py @@ -5,9 +5,12 @@ from django.db.models.signals import post_save, m2m_changed, post_delete from django.dispatch import receiver from common.utils import get_logger -from .models import Asset, SystemUser, Node -from .tasks import update_assets_hardware_info_util, \ - test_asset_connectivity_util, push_system_user_to_assets +from .models import Asset, SystemUser, Node, AuthBook +from .tasks import ( + update_assets_hardware_info_util, + test_asset_connectivity_util, + push_system_user_to_assets +) logger = get_logger(__file__) @@ -109,3 +112,10 @@ def on_node_assets_changed(sender, instance=None, **kwargs): def on_node_update_or_created(sender, instance=None, created=False, **kwargs): if instance and not created: instance.expire_full_value() + + +@receiver(post_save, sender=AuthBook) +def on_auth_book_created(sender, instance=None, created=False, **kwargs): + if created: + logger.debug('Receive create auth book object signal.') + instance.set_version_and_latest() diff --git a/apps/assets/tasks.py b/apps/assets/tasks.py index 79d055588..172175f38 100644 --- a/apps/assets/tasks.py +++ b/apps/assets/tasks.py @@ -26,20 +26,26 @@ disk_pattern = re.compile(r'^hd|sd|xvd|vd') PERIOD_TASK = os.environ.get("PERIOD_TASK", "on") +def check_asset_can_run_ansible(asset): + if not asset.is_active: + msg = _("Asset has been disabled, skipped: {}").format(asset) + logger.info(msg) + return False + if not asset.support_ansible(): + msg = _("Asset may not be support ansible, skipped: {}").format(asset) + logger.info(msg) + return False + return True + + def clean_hosts(assets): clean_assets = [] for asset in assets: - if not asset.is_active: - msg = _("Asset has been disabled, skipped: {}").format(asset) - logger.info(msg) - continue - if not asset.support_ansible(): - msg = _("Asset may not be support ansible, skipped: {}").format(asset) - logger.info(msg) + if not check_asset_can_run_ansible(asset): continue clean_assets.append(asset) if not clean_assets: - logger.info(_("No assets matched, stop task")) + print(_("No assets matched, stop task")) return clean_assets @@ -259,7 +265,7 @@ def test_system_user_connectivity_util(system_user, assets, task_name): task, created = update_or_create_ansible_task( task_name, hosts=hosts, tasks=tasks, pattern='all', options=const.TASK_OPTIONS, - run_as=system_user, created_by=system_user.org_id, + run_as=system_user.username, created_by=system_user.org_id, ) result = task.run() set_system_user_connectivity_info(system_user, result) @@ -341,6 +347,12 @@ def get_push_system_user_tasks(system_user): } }) if system_user.sudo: + sudo = system_user.sudo.replace('\r\n', '\n').replace('\r', '\n') + sudo_list = sudo.split('\n') + sudo_tmp = [] + for s in sudo_list: + sudo_tmp.append(s.strip(',')) + sudo = ','.join(sudo_tmp) tasks.append({ 'name': 'Set {} sudo setting'.format(system_user.username), 'action': { @@ -348,8 +360,7 @@ def get_push_system_user_tasks(system_user): 'args': "dest=/etc/sudoers state=present regexp='^{0} ALL=' " "line='{0} ALL=(ALL) NOPASSWD: {1}' " "validate='visudo -cf %s'".format( - system_user.username, - system_user.sudo, + system_user.username, sudo, ) } }) @@ -365,16 +376,18 @@ def push_system_user_util(system_user, assets, task_name): logger.info(msg) return - tasks = get_push_system_user_tasks(system_user) hosts = clean_hosts(assets) if not hosts: return {} - task, created = update_or_create_ansible_task( - task_name=task_name, hosts=hosts, tasks=tasks, pattern='all', - options=const.TASK_OPTIONS, run_as_admin=True, - created_by=system_user.org_id, - ) - return task.run() + for host in hosts: + system_user.load_specific_asset_auth(host) + tasks = get_push_system_user_tasks(system_user) + task, created = update_or_create_ansible_task( + task_name=task_name, hosts=[host], tasks=tasks, pattern='all', + options=const.TASK_OPTIONS, run_as_admin=True, + created_by=system_user.org_id, + ) + task.run() @shared_task @@ -410,6 +423,43 @@ def test_admin_user_connectability_period(): pass +@shared_task +def set_asset_user_connectivity_info(asset_user, result): + summary = result[1] + asset_user.connectivity = summary + + +@shared_task +def test_asset_user_connectivity_util(asset_user, task_name): + """ + :param asset_user: 对象 + :param task_name: + :return: + """ + from ops.utils import update_or_create_ansible_task + tasks = const.TEST_ASSET_USER_CONN_TASKS + if not check_asset_can_run_ansible(asset_user.asset): + return + + task, created = update_or_create_ansible_task( + task_name, hosts=[asset_user.asset], tasks=tasks, pattern='all', + options=const.TASK_OPTIONS, + run_as=asset_user.username, created_by=asset_user.org_id + ) + result = task.run() + set_asset_user_connectivity_info(asset_user, result) + + +@shared_task +def test_asset_users_connectivity_manual(asset_users): + """ + :param asset_users: 对象 + """ + for asset_user in asset_users: + task_name = _("Test asset user connectivity: {}").format(asset_user) + test_asset_user_connectivity_util(asset_user, task_name) + + # @shared_task # @register_as_period_task(interval=3600) # @after_app_ready_start diff --git a/apps/assets/templates/assets/_asset_user_auth_modal.html b/apps/assets/templates/assets/_asset_user_auth_modal.html new file mode 100644 index 000000000..be615ce52 --- /dev/null +++ b/apps/assets/templates/assets/_asset_user_auth_modal.html @@ -0,0 +1,28 @@ +{% extends '_modal.html' %} +{% load i18n %} +{% block modal_id %}asset_user_auth_modal{% endblock %} +{% block modal_title%}{% trans "Update asset user auth" %}{% endblock %} +{% block modal_body %} +
+ {% csrf_token %} +
+ +
+

+
+
+
+ +
+

+
+
+
+ +
+ +
+
+
+{% endblock %} +{% block modal_confirm_id %}btn_asset_user_auth_modal_confirm{% endblock %} diff --git a/apps/assets/templates/assets/_gateway_test_modal.html b/apps/assets/templates/assets/_gateway_test_modal.html new file mode 100644 index 000000000..2eef52c7e --- /dev/null +++ b/apps/assets/templates/assets/_gateway_test_modal.html @@ -0,0 +1,18 @@ +{% extends '_modal.html' %} +{% load i18n %} +{% block modal_id %}gateway_test{% endblock %} +{% block modal_title%}{% trans "Test gateway test connection" %}{% endblock %} +{% block modal_body %} +{% load bootstrap3 %} +
+
+ + +
+ + {% trans 'If use nat, set the ssh real port' %} +
+
+
+{% endblock %} +{% block modal_confirm_id %}btn_gateway_test{% endblock %} \ No newline at end of file diff --git a/apps/assets/templates/assets/admin_user_assets.html b/apps/assets/templates/assets/admin_user_assets.html index 7a9882563..d22c5406f 100644 --- a/apps/assets/templates/assets/admin_user_assets.html +++ b/apps/assets/templates/assets/admin_user_assets.html @@ -84,6 +84,7 @@ + {% include 'assets/_asset_user_auth_modal.html' %} {% endblock %} {% block custom_foot_js %} {% endblock %} diff --git a/apps/assets/templates/assets/asset_asset_user_list.html b/apps/assets/templates/assets/asset_asset_user_list.html new file mode 100644 index 000000000..540be02d8 --- /dev/null +++ b/apps/assets/templates/assets/asset_asset_user_list.html @@ -0,0 +1,218 @@ +{% extends 'base.html' %} +{% load common_tags %} +{% load static %} +{% load i18n %} + +{% block custom_head_css_js %} +{% endblock %} + +{% block content %} +
+
+
+
+ +
+
+
+
+ {% trans 'Asset users of' %} {{ asset.hostname }} +
+ + + + + + + + + + +
+
+
+ + + + + + + + + + + + + +
{% trans 'Username' %}{% trans 'Version' %}{% trans 'Reachable' %}{% trans 'Date updated' %}{% trans 'Action' %}
+
+
+
+
+
+
+ {% trans 'Quick modify' %} +
+
+ + + {% if asset.protocol == 'ssh' %} + + + + + {% endif %} + +
{% trans 'Test connective' %}: + + + +
+
+
+
+
+
+
+
+
+ {% include 'assets/_asset_user_auth_modal.html' %} +{% endblock %} +{% block custom_foot_js %} + +{% endblock %} \ No newline at end of file diff --git a/apps/assets/templates/assets/asset_detail.html b/apps/assets/templates/assets/asset_detail.html index c766f583c..4ff3bdf75 100644 --- a/apps/assets/templates/assets/asset_detail.html +++ b/apps/assets/templates/assets/asset_detail.html @@ -19,6 +19,9 @@
  • {% trans 'Asset detail' %}
  • +
  • + {% trans 'Asset user list' %} +
  • {% if user.is_superuser %}
  • {% trans 'Update' %} @@ -32,7 +35,7 @@
    -
    +
    {{ asset.hostname }} @@ -139,7 +142,7 @@
    {% if user.is_superuser or user.is_org_admin %} -
    +
    {% trans 'Quick modify' %} diff --git a/apps/assets/templates/assets/domain_gateway_list.html b/apps/assets/templates/assets/domain_gateway_list.html index e7a3467e3..d621fb0ec 100644 --- a/apps/assets/templates/assets/domain_gateway_list.html +++ b/apps/assets/templates/assets/domain_gateway_list.html @@ -15,10 +15,16 @@ @@ -33,7 +39,8 @@ - +
    - +
    @@ -73,6 +84,7 @@ +{% include 'assets/_gateway_test_modal.html' %} {% endblock %} {% block content_bottom_left %}{% endblock %} {% block custom_foot_js %} @@ -84,7 +96,7 @@ function initTable() { {targets: 7, createdCell: function (td, cellData, rowData) { var update_btn = '{% trans "Update" %}'.replace('{{ DEFAULT_PK }}', cellData); var del_btn = '{% trans "Delete" %}'.replace('{{ DEFAULT_PK }}', cellData); - var test_btn = '{% trans "Test connection" %}'.replace('{{ DEFAULT_PK }}', cellData); + var test_btn = '{% trans "Test connection" %}'.replace('{{ DEFAULT_PK }}', cellData).replace("PORT", rowData.port); if(rowData.protocol === 'rdp'){ test_btn = '{% trans "Test connection" %}'.replace('{{ DEFAULT_PK }}', cellData); } @@ -114,15 +126,21 @@ $(document).ready(function(){ $data_table.ajax.reload(); }, 3000); }).on('click', '.btn-test', function () { - var $this = $(this); - var uid = $this.data('uid'); + $("#ssh_test_port").val($(this).data('port')); + $("#gateway_id").val($(this).data('uid')); + $("#gateway_test").modal('show'); + +}).on('click', '#btn_gateway_test', function () { + var data = $("#test_gateway_form").serializeObject(); + var uid = data.gateway_id; var the_url = '{% url "api-assets:test-gateway-connective" pk=DEFAULT_PK %}'.replace('{{ DEFAULT_PK }}', uid); APIUpdateAttr({ url: the_url, - method: "GET", + method: "POST", + body: JSON.stringify({'port': parseInt(data.port)}), success_message: "{% trans 'Can be connected' %}", fail_message: "{% trans 'The connection fails' %}" - }) + }) }); {% endblock %} diff --git a/apps/assets/templates/assets/system_user_asset.html b/apps/assets/templates/assets/system_user_asset.html index 9bcf6b5aa..4ffdf2a91 100644 --- a/apps/assets/templates/assets/system_user_asset.html +++ b/apps/assets/templates/assets/system_user_asset.html @@ -132,6 +132,7 @@ + {% include 'assets/_asset_user_auth_modal.html' %} {% endblock %} {% block custom_foot_js %} {% endblock %} diff --git a/apps/assets/templates/assets/user_asset_list.html b/apps/assets/templates/assets/user_asset_list.html index 0e39aa899..329f24c72 100644 --- a/apps/assets/templates/assets/user_asset_list.html +++ b/apps/assets/templates/assets/user_asset_list.html @@ -17,7 +17,6 @@
    -
    @@ -46,6 +45,7 @@ + @@ -62,16 +62,19 @@ {% block custom_foot_js %} @@ -95,6 +114,29 @@ width: 'auto' }); }) + .on('click', '.btn_export', function () { + var date_form = $('#id_date_from').val(); + var date_to = $('#id_date_to').val(); + var user = $('.select2 option:selected').val(); + var keyword = $('#search').val(); + $.ajax({ + url: "{% url "audits:login-log-export" %}", + method: 'POST', + data: JSON.stringify({ + 'date_form':date_form, + 'date_to':date_to, + 'user':user, + 'keyword':keyword + }), + dataType: "json", + success: function (data, textStatus) { + window.open(data.redirect) + }, + error: function () { + toastr.error('Export failed'); + } + }) + }) {% endblock %} diff --git a/apps/audits/urls/view_urls.py b/apps/audits/urls/view_urls.py index 473a2d83f..ef400cb99 100644 --- a/apps/audits/urls/view_urls.py +++ b/apps/audits/urls/view_urls.py @@ -14,4 +14,5 @@ urlpatterns = [ path('operate-log/', views.OperateLogListView.as_view(), name='operate-log-list'), path('password-change-log/', views.PasswordChangeLogList.as_view(), name='password-change-log-list'), path('command-execution-log/', views.CommandExecutionListView.as_view(), name='command-execution-log-list'), + path('login-log/export/', views.LoginLogExportView.as_view(), name='login-log-export'), ] diff --git a/apps/audits/utils.py b/apps/audits/utils.py new file mode 100644 index 000000000..36c54e81b --- /dev/null +++ b/apps/audits/utils.py @@ -0,0 +1,22 @@ +import csv +import codecs +from django.http import HttpResponse + + +def get_excel_response(filename): + excel_response = HttpResponse(content_type='text/csv') + excel_response[ + 'Content-Disposition'] = 'attachment; filename="%s"' % filename + excel_response.write(codecs.BOM_UTF8) + return excel_response + + +def write_content_to_excel(response, header=None, login_logs=None, fields=None): + writer = csv.writer(response, dialect='excel', quoting=csv.QUOTE_MINIMAL) + if header: + writer.writerow(header) + if login_logs: + for log in login_logs: + data = [getattr(log, field.name) for field in fields] + writer.writerow(data) + return response \ No newline at end of file diff --git a/apps/audits/views.py b/apps/audits/views.py index b19514e9b..372159b74 100644 --- a/apps/audits/views.py +++ b/apps/audits/views.py @@ -1,14 +1,28 @@ +import csv +import json +import uuid +import codecs + + from django.conf import settings +from django.urls import reverse +from django.utils import timezone +from django.core.cache import cache +from django.http import HttpResponse, JsonResponse +from django.utils.decorators import method_decorator +from django.views import View +from django.views.decorators.csrf import csrf_exempt from django.views.generic import ListView from django.utils.translation import ugettext as _ +from django.contrib.auth.mixins import LoginRequiredMixin from django.db.models import Q +from audits.utils import get_excel_response, write_content_to_excel from common.mixins import DatetimeSearchMixin from common.permissions import AdminUserRequiredMixin from orgs.utils import current_org from ops.views import CommandExecutionListView as UserCommandExecutionListView -from users.models import User from .models import FTPLog, OperateLog, PasswordChangeLog, UserLoginLog @@ -222,14 +236,49 @@ class CommandExecutionListView(UserCommandExecutionListView): return users def get_context_data(self, **kwargs): - context = { + context = super().get_context_data(**kwargs) + context.update({ 'app': _('Audits'), - 'action': _('Command execution list'), + 'action': _('Command execution log'), 'date_from': self.date_from, 'date_to': self.date_to, 'user_list': self.get_user_list(), 'keyword': self.keyword, 'user_id': self.user_id, - } - kwargs.update(context) - return super().get_context_data(**kwargs) + }) + return super().get_context_data(**context) + + +@method_decorator(csrf_exempt, name='dispatch') +class LoginLogExportView(LoginRequiredMixin, View): + + def get(self, request): + fields = [ + field for field in UserLoginLog._meta.fields + ] + filename = 'login-logs-{}.csv'.format( + timezone.localtime(timezone.now()).strftime('%Y-%m-%d_%H-%M-%S') + ) + excel_response = get_excel_response(filename) + header = [field.verbose_name for field in fields] + login_logs = cache.get(request.GET.get('spm', ''), []) + + response = write_content_to_excel(excel_response, login_logs=login_logs, + header=header, fields=fields) + return response + + def post(self, request): + try: + date_form = json.loads(request.body).get('date_form', []) + date_to = json.loads(request.body).get('date_to', []) + user = json.loads(request.body).get('user', []) + keyword = json.loads(request.body).get('keyword', []) + + login_logs = UserLoginLog.get_login_logs( + date_form=date_form, date_to=date_to, user=user, keyword=keyword) + except ValueError: + return HttpResponse('Json object not valid', status=400) + spm = uuid.uuid4().hex + cache.set(spm, login_logs, 300) + url = reverse('audits:login-log-export') + '?spm=%s' % spm + return JsonResponse({'redirect': url}) \ No newline at end of file diff --git a/apps/authentication/api/__init__.py b/apps/authentication/api/__init__.py new file mode 100644 index 000000000..0e8a44178 --- /dev/null +++ b/apps/authentication/api/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- +# + +from .auth import * diff --git a/apps/users/api/auth.py b/apps/authentication/api/auth.py similarity index 57% rename from apps/users/api/auth.py rename to apps/authentication/api/auth.py index c4ed7ff3a..2d9cfe367 100644 --- a/apps/users/api/auth.py +++ b/apps/authentication/api/auth.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- # + import uuid from django.core.cache import cache @@ -14,16 +15,21 @@ from rest_framework.views import APIView from common.utils import get_logger, get_request_ip from common.permissions import IsOrgAdminOrAppUser from orgs.mixins import RootOrgViewMixin -from ..serializers import UserSerializer -from ..tasks import write_login_log_async -from ..models import User, LoginLog -from ..utils import check_user_valid, check_otp_code, \ - increase_login_failed_count, is_block_login, \ - clean_failed_count -from ..hands import Asset, SystemUser +from users.serializers import UserSerializer +from users.models import User +from assets.models import Asset, SystemUser +from audits.models import UserLoginLog as LoginLog +from users.utils import ( + check_user_valid, check_otp_code, increase_login_failed_count, + is_block_login, clean_failed_count +) +from ..signals import post_auth_success, post_auth_failed logger = get_logger(__name__) +__all__ = [ + 'UserAuthApi', 'UserConnectionTokenApi', 'UserOtpAuthApi', +] class UserAuthApi(RootOrgViewMixin, APIView): @@ -46,37 +52,22 @@ class UserAuthApi(RootOrgViewMixin, APIView): username = request.data.get('username', '') exist = User.objects.filter(username=username).first() reason = LoginLog.REASON_PASSWORD if exist else LoginLog.REASON_NOT_EXIST - data = { - 'username': username, - 'mfa': LoginLog.MFA_UNKNOWN, - 'reason': reason, - 'status': False - } - self.write_login_log(request, data) + self.send_auth_signal(success=False, username=username, reason=reason) increase_login_failed_count(username, ip) return Response({'msg': msg}, status=401) if user.password_has_expired: - data = { - 'username': user.username, - 'mfa': int(user.otp_enabled), - 'reason': LoginLog.REASON_PASSWORD_EXPIRED, - 'status': False - } - self.write_login_log(request, data) + self.send_auth_signal( + success=False, username=username, + reason=LoginLog.REASON_PASSWORD_EXPIRED + ) msg = _("The user {} password has expired, please update.".format( user.username)) logger.info(msg) return Response({'msg': msg}, status=401) if not user.otp_enabled: - data = { - 'username': user.username, - 'mfa': int(user.otp_enabled), - 'reason': LoginLog.REASON_NOTHING, - 'status': True - } - self.write_login_log(request, data) + self.send_auth_signal(success=True, user=user) # 登陆成功,清除原来的缓存计数 clean_failed_count(username, ip) token = user.create_bearer_token(request) @@ -91,7 +82,7 @@ class UserAuthApi(RootOrgViewMixin, APIView): 'code': 101, 'msg': _('Please carry seed value and ' 'conduct MFA secondary certification'), - 'otp_url': reverse('api-users:user-otp-auth'), + 'otp_url': reverse('api-auth:user-otp-auth'), 'seed': seed, 'user': self.serializer_class(user).data }, status=300 @@ -108,22 +99,14 @@ class UserAuthApi(RootOrgViewMixin, APIView): ) return user, msg - @staticmethod - def write_login_log(request, data): - login_ip = request.data.get('remote_addr', None) - login_type = request.data.get('login_type', '') - user_agent = request.data.get('HTTP_USER_AGENT', '') - - if not login_ip: - login_ip = get_request_ip(request) - - tmp_data = { - 'ip': login_ip, - 'type': login_type, - 'user_agent': user_agent, - } - data.update(tmp_data) - write_login_log_async.delay(**data) + def send_auth_signal(self, success=True, user=None, username='', reason=''): + if success: + post_auth_success.send(sender=self.__class__, user=user, request=self.request) + else: + post_auth_failed.send( + sender=self.__class__, username=username, + request=self.request, reason=reason + ) class UserConnectionTokenApi(RootOrgViewMixin, APIView): @@ -167,29 +150,6 @@ class UserConnectionTokenApi(RootOrgViewMixin, APIView): return super().get_permissions() -class UserToken(APIView): - permission_classes = (AllowAny,) - - def post(self, request): - if not request.user.is_authenticated: - username = request.data.get('username', '') - email = request.data.get('email', '') - password = request.data.get('password', '') - public_key = request.data.get('public_key', '') - - user, msg = check_user_valid( - username=username, email=email, - password=password, public_key=public_key) - else: - user = request.user - msg = None - if user: - token = user.create_bearer_token(request) - return Response({'Token': token, 'Keyword': 'Bearer'}, status=200) - else: - return Response({'error': msg}, status=406) - - class UserOtpAuthApi(RootOrgViewMixin, APIView): permission_classes = (AllowAny,) serializer_class = UserSerializer @@ -197,52 +157,25 @@ class UserOtpAuthApi(RootOrgViewMixin, APIView): def post(self, request): otp_code = request.data.get('otp_code', '') seed = request.data.get('seed', '') - user = cache.get(seed, None) if not user: return Response( {'msg': _('Please verify the user name and password first')}, status=401 ) - if not check_otp_code(user.otp_secret_key, otp_code): - data = { - 'username': user.username, - 'mfa': int(user.otp_enabled), - 'reason': LoginLog.REASON_MFA, - 'status': False - } - self.write_login_log(request, data) + self.send_auth_signal(success=False, username=user.username, reason=LoginLog.REASON_MFA) return Response({'msg': _('MFA certification failed')}, status=401) - - data = { - 'username': user.username, - 'mfa': int(user.otp_enabled), - 'reason': LoginLog.REASON_NOTHING, - 'status': True - } - self.write_login_log(request, data) + self.send_auth_signal(success=True, user=user) token = user.create_bearer_token(request) - return Response( - { - 'token': token, - 'user': self.serializer_class(user).data - } - ) + data = {'token': token, 'user': self.serializer_class(user).data} + return Response(data) - @staticmethod - def write_login_log(request, data): - login_ip = request.data.get('remote_addr', None) - login_type = request.data.get('login_type', '') - user_agent = request.data.get('HTTP_USER_AGENT', '') - - if not login_ip: - login_ip = get_request_ip(request) - - tmp_data = { - 'ip': login_ip, - 'type': login_type, - 'user_agent': user_agent - } - data.update(tmp_data) - write_login_log_async.delay(**data) + def send_auth_signal(self, success=True, user=None, username='', reason=''): + if success: + post_auth_success.send(sender=self.__class__, user=user, request=self.request) + else: + post_auth_failed.send( + sender=self.__class__, username=username, + request=self.request, reason=reason + ) diff --git a/apps/authentication/backends/__init__.py b/apps/authentication/backends/__init__.py new file mode 100644 index 000000000..ec51c5a2b --- /dev/null +++ b/apps/authentication/backends/__init__.py @@ -0,0 +1,2 @@ +# -*- coding: utf-8 -*- +# diff --git a/apps/users/authentication.py b/apps/authentication/backends/api.py similarity index 95% rename from apps/users/authentication.py rename to apps/authentication/backends/api.py index 5faa7bb60..75b9bdb3f 100644 --- a/apps/users/authentication.py +++ b/apps/authentication/backends/api.py @@ -8,13 +8,13 @@ from django.core.cache import cache from django.conf import settings from django.utils.translation import ugettext as _ from django.utils.six import text_type -from django.utils.translation import ugettext_lazy as _ +from django.contrib.auth import get_user_model from rest_framework import HTTP_HEADER_ENCODING from rest_framework import authentication, exceptions from rest_framework.authentication import CSRFCheck from common.utils import get_object_or_none, make_signature, http_to_unixtime -from .models import User, AccessKey, PrivateToken +from ..models import AccessKey, PrivateToken def get_request_date_header(request): @@ -42,7 +42,6 @@ class AccessKeyAuthentication(authentication.BaseAuthentication): 失败 """ keyword = 'Sign' - model = AccessKey def authenticate(self, request): auth = authentication.get_authorization_header(request).split() @@ -109,7 +108,7 @@ class AccessKeyAuthentication(authentication.BaseAuthentication): class AccessTokenAuthentication(authentication.BaseAuthentication): keyword = 'Bearer' - model = User + model = get_user_model() expiration = settings.TOKEN_EXPIRATION or 3600 def authenticate(self, request): @@ -133,10 +132,9 @@ class AccessTokenAuthentication(authentication.BaseAuthentication): raise exceptions.AuthenticationFailed(msg) return self.authenticate_credentials(token) - @staticmethod - def authenticate_credentials(token): + def authenticate_credentials(self, token): user_id = cache.get(token) - user = get_object_or_none(User, id=user_id) + user = get_object_or_none(self.model, id=user_id) if not user: msg = _('Invalid token or cache refreshed.') diff --git a/apps/authentication/ldap/backends.py b/apps/authentication/backends/ldap.py similarity index 86% rename from apps/authentication/ldap/backends.py rename to apps/authentication/backends/ldap.py index 7fcccc046..b35903420 100644 --- a/apps/authentication/ldap/backends.py +++ b/apps/authentication/backends/ldap.py @@ -16,8 +16,13 @@ class LDAPAuthorizationBackend(LDAPBackend): """ def authenticate(self, request=None, username=None, password=None, **kwargs): + logger.info('Authentication LDAP backend') + if not username: + logger.info('Authenticate failed: username is None') + return None ldap_user = LDAPUser(self, username=username.strip(), request=request) user = self.authenticate_ldap_user(ldap_user, password) + logger.info('Authenticate user: {}'.format(user)) return user def get_user(self, user_id): @@ -83,7 +88,10 @@ class LDAPUser(_LDAPUser): def _populate_user_from_attributes(self): super()._populate_user_from_attributes() if not hasattr(self._user, 'email') or '@' not in self._user.email: - email = '{}@{}'.format(self._user.username, settings.EMAIL_SUFFIX) + if '@' not in self._user.username: + email = '{}@{}'.format(self._user.username, settings.EMAIL_SUFFIX) + else: + email = self._user.username setattr(self._user, 'email', email) diff --git a/apps/authentication/backends/openid/__init__.py b/apps/authentication/backends/openid/__init__.py new file mode 100644 index 000000000..2deaf3cae --- /dev/null +++ b/apps/authentication/backends/openid/__init__.py @@ -0,0 +1,6 @@ +# -*- coding: utf-8 -*- +# + +from .backends import * +from .middleware import * +from .utils import * diff --git a/apps/authentication/openid/backends.py b/apps/authentication/backends/openid/backends.py similarity index 69% rename from apps/authentication/openid/backends.py rename to apps/authentication/backends/openid/backends.py index 15a758acc..b8e4ae609 100644 --- a/apps/authentication/openid/backends.py +++ b/apps/authentication/backends/openid/backends.py @@ -4,16 +4,19 @@ from django.contrib.auth import get_user_model from django.conf import settings -from . import client from common.utils import get_logger -from authentication.openid.models import OIDT_ACCESS_TOKEN +from .utils import new_client +from .models import OIDT_ACCESS_TOKEN UserModel = get_user_model() logger = get_logger(__file__) +client = new_client() -BACKEND_OPENID_AUTH_CODE = \ - 'authentication.openid.backends.OpenIDAuthorizationCodeBackend' + +__all__ = [ + 'OpenIDAuthorizationCodeBackend', 'OpenIDAuthorizationPasswordBackend', +] class BaseOpenIDAuthorizationBackend(object): @@ -39,41 +42,41 @@ class BaseOpenIDAuthorizationBackend(object): class OpenIDAuthorizationCodeBackend(BaseOpenIDAuthorizationBackend): def authenticate(self, request, **kwargs): - logger.info('1.openid code backend') + logger.info('Authentication OpenID code backend') code = kwargs.get('code') redirect_uri = kwargs.get('redirect_uri') if not code or not redirect_uri: + logger.info('Authenticate failed: No code or No redirect uri') return None try: oidt_profile = client.update_or_create_from_code( - code=code, - redirect_uri=redirect_uri - ) + code=code, redirect_uri=redirect_uri + ) except Exception as e: - logger.error(e) + logger.info('Authenticate failed: get oidt_profile: {}'.format(e)) else: # Check openid user single logout or not with access_token request.session[OIDT_ACCESS_TOKEN] = oidt_profile.access_token - user = oidt_profile.user - + logger.info('Authenticate success: user -> {}'.format(user)) return user if self.user_can_authenticate(user) else None class OpenIDAuthorizationPasswordBackend(BaseOpenIDAuthorizationBackend): def authenticate(self, request, username=None, password=None, **kwargs): - logger.info('2.openid password backend') + logger.info('Authentication OpenID password backend') if not settings.AUTH_OPENID: + logger.info('Authenticate failed: AUTH_OPENID is False') return None - elif not username: + logger.info('Authenticate failed: Not username') return None try: @@ -82,9 +85,10 @@ class OpenIDAuthorizationPasswordBackend(BaseOpenIDAuthorizationBackend): ) except Exception as e: - logger.error(e) + logger.info('Authenticate failed: get oidt_profile: {}'.format(e)) else: user = oidt_profile.user + logger.info('Authenticate success: user -> {}'.format(user)) return user if self.user_can_authenticate(user) else None diff --git a/apps/authentication/openid/middleware.py b/apps/authentication/backends/openid/middleware.py similarity index 70% rename from apps/authentication/openid/middleware.py rename to apps/authentication/backends/openid/middleware.py index 128b20984..df5ee93c1 100644 --- a/apps/authentication/openid/middleware.py +++ b/apps/authentication/backends/openid/middleware.py @@ -6,12 +6,13 @@ from django.contrib.auth import logout from django.utils.deprecation import MiddlewareMixin from django.contrib.auth import BACKEND_SESSION_KEY -from . import client from common.utils import get_logger -from .backends import BACKEND_OPENID_AUTH_CODE -from authentication.openid.models import OIDT_ACCESS_TOKEN +from .utils import new_client +from .models import OIDT_ACCESS_TOKEN +BACKEND_OPENID_AUTH_CODE = 'OpenIDAuthorizationCodeBackend' logger = get_logger(__file__) +__all__ = ['OpenIDAuthenticationMiddleware'] class OpenIDAuthenticationMiddleware(MiddlewareMixin): @@ -20,22 +21,22 @@ class OpenIDAuthenticationMiddleware(MiddlewareMixin): """ def process_request(self, request): - # Don't need openid auth if AUTH_OPENID is False if not settings.AUTH_OPENID: return - # Don't need check single logout if user not authenticated if not request.user.is_authenticated: return - - elif request.session[BACKEND_SESSION_KEY] != BACKEND_OPENID_AUTH_CODE: + elif request.session[BACKEND_SESSION_KEY].endswith( + BACKEND_OPENID_AUTH_CODE): return # Check openid user single logout or not with access_token + client = new_client() try: client.openid_connect_client.userinfo( - token=request.session.get(OIDT_ACCESS_TOKEN)) + token=request.session.get(OIDT_ACCESS_TOKEN) + ) except Exception as e: logout(request) diff --git a/apps/authentication/openid/models.py b/apps/authentication/backends/openid/models.py similarity index 92% rename from apps/authentication/openid/models.py rename to apps/authentication/backends/openid/models.py index e3c0a4842..fd75ed870 100644 --- a/apps/authentication/openid/models.py +++ b/apps/authentication/backends/openid/models.py @@ -5,7 +5,8 @@ from django.db import transaction from django.contrib.auth import get_user_model from keycloak.realm import KeycloakRealm from keycloak.keycloak_openid import KeycloakOpenID -from ..signals import post_create_openid_user + +from .signals import post_create_openid_user OIDT_ACCESS_TOKEN = 'oidt_access_token' @@ -38,10 +39,6 @@ class Client(object): self.openid_connect_client = self.new_openid_connect_client() def new_realm(self): - """ - :param authentication.openid.models.Realm realm: - :return keycloak.realm.Realm: - """ return KeycloakRealm( server_url=self.server_url, realm_name=self.realm_name, @@ -76,7 +73,7 @@ class Client(object): :param str username: authentication username :param str password: authentication password - :return: authentication.models.OpenIDTokenProfile + :return: OpenIDTokenProfile """ token_response = self.openid_client.token( username=username, password=password @@ -93,7 +90,7 @@ class Client(object): :param str code: authentication code :param str redirect_uri: - :rtype: authentication.models.OpenIDTokenProfile + :rtype: OpenIDTokenProfile """ token_response = self.openid_connect_client.authorization_code( @@ -114,7 +111,7 @@ class Client(object): - refresh_expires_in :param dict token_response: - :rtype: authentication.openid.models.OpenIDTokenProfile + :rtype: OpenIDTokenProfile """ userinfo = self.openid_connect_client.userinfo( diff --git a/apps/authentication/backends/openid/signals.py b/apps/authentication/backends/openid/signals.py new file mode 100644 index 000000000..d5e57a005 --- /dev/null +++ b/apps/authentication/backends/openid/signals.py @@ -0,0 +1,5 @@ +from django.dispatch import Signal + + +post_create_openid_user = Signal(providing_args=('user',)) +post_openid_login_success = Signal(providing_args=('user', 'request')) diff --git a/apps/authentication/openid/tests.py b/apps/authentication/backends/openid/tests.py similarity index 100% rename from apps/authentication/openid/tests.py rename to apps/authentication/backends/openid/tests.py diff --git a/apps/authentication/backends/openid/urls.py b/apps/authentication/backends/openid/urls.py new file mode 100644 index 000000000..019529e12 --- /dev/null +++ b/apps/authentication/backends/openid/urls.py @@ -0,0 +1,11 @@ +# -*- coding: utf-8 -*- +# +from django.urls import path + +from . import views + +urlpatterns = [ + path('login/', views.OpenIDLoginView.as_view(), name='openid-login'), + path('login/complete/', views.OpenIDLoginCompleteView.as_view(), + name='openid-login-complete'), +] diff --git a/apps/authentication/openid/__init__.py b/apps/authentication/backends/openid/utils.py similarity index 94% rename from apps/authentication/openid/__init__.py rename to apps/authentication/backends/openid/utils.py index bc4c753ca..15160d224 100644 --- a/apps/authentication/openid/__init__.py +++ b/apps/authentication/backends/openid/utils.py @@ -4,6 +4,8 @@ from django.conf import settings from .models import Client +__all__ = ['new_client'] + def new_client(): """ @@ -15,6 +17,3 @@ def new_client(): client_id=settings.AUTH_OPENID_CLIENT_ID, client_secret=settings.AUTH_OPENID_CLIENT_SECRET ) - - -client = new_client() diff --git a/apps/authentication/openid/views.py b/apps/authentication/backends/openid/views.py similarity index 64% rename from apps/authentication/openid/views.py rename to apps/authentication/backends/openid/views.py index 9aeb0bf7b..45b5bfe23 100644 --- a/apps/authentication/openid/views.py +++ b/apps/authentication/backends/openid/views.py @@ -3,7 +3,6 @@ import logging -from django.urls import reverse from django.conf import settings from django.core.cache import cache from django.views.generic.base import RedirectView @@ -14,43 +13,35 @@ from django.http.response import ( HttpResponseRedirect ) -from . import client +from .utils import new_client from .models import Nonce -from users.models import LoginLog -from users.tasks import write_login_log_async -from common.utils import get_request_ip +from .signals import post_openid_login_success logger = logging.getLogger(__name__) +client = new_client() + +__all__ = ['OpenIDLoginView', 'OpenIDLoginCompleteView'] -def get_base_site_url(): - return settings.BASE_SITE_URL - - -class LoginView(RedirectView): +class OpenIDLoginView(RedirectView): def get_redirect_url(self, *args, **kwargs): + redirect_uri = settings.BASE_SITE_URL + str(settings.LOGIN_COMPLETE_URL) nonce = Nonce( - redirect_uri=get_base_site_url() + reverse( - "authentication:openid-login-complete"), - + redirect_uri=redirect_uri, next_path=self.request.GET.get('next') ) - cache.set(str(nonce.state), nonce, 24*3600) - self.request.session['openid_state'] = str(nonce.state) - authorization_url = client.openid_connect_client.\ authorization_url( redirect_uri=nonce.redirect_uri, scope='code', state=str(nonce.state) ) - return authorization_url -class LoginCompleteView(RedirectView): +class OpenIDLoginCompleteView(RedirectView): def get(self, request, *args, **kwargs): if 'error' in request.GET: @@ -79,24 +70,8 @@ class LoginCompleteView(RedirectView): return HttpResponseBadRequest() login(self.request, user) - - data = { - 'username': user.username, - 'mfa': int(user.otp_enabled), - 'reason': LoginLog.REASON_NOTHING, - 'status': True - } - self.write_login_log(data) - + post_openid_login_success.send( + sender=self.__class__, user=user, request=self.request + ) return HttpResponseRedirect(nonce.next_path or '/') - def write_login_log(self, data): - login_ip = get_request_ip(self.request) - user_agent = self.request.META.get('HTTP_USER_AGENT', '') - tmp_data = { - 'ip': login_ip, - 'type': 'W', - 'user_agent': user_agent - } - data.update(tmp_data) - write_login_log_async.delay(**data) diff --git a/apps/authentication/radius/backends.py b/apps/authentication/backends/radius.py similarity index 100% rename from apps/authentication/radius/backends.py rename to apps/authentication/backends/radius.py diff --git a/apps/authentication/const.py b/apps/authentication/const.py new file mode 100644 index 000000000..f19a64d9a --- /dev/null +++ b/apps/authentication/const.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- +# + + diff --git a/apps/authentication/forms.py b/apps/authentication/forms.py new file mode 100644 index 000000000..c722629db --- /dev/null +++ b/apps/authentication/forms.py @@ -0,0 +1,29 @@ +# -*- coding: utf-8 -*- +# + +from django import forms +from django.contrib.auth.forms import AuthenticationForm +from django.utils.translation import gettext_lazy as _ +from captcha.fields import CaptchaField + + +class UserLoginForm(AuthenticationForm): + username = forms.CharField(label=_('Username'), max_length=100) + password = forms.CharField( + label=_('Password'), widget=forms.PasswordInput, + max_length=128, strip=False + ) + + def confirm_login_allowed(self, user): + if not user.is_staff: + raise forms.ValidationError( + self.error_messages['inactive'], + code='inactive',) + + +class UserLoginCaptchaForm(UserLoginForm): + captcha = CaptchaField() + + +class UserCheckOtpCodeForm(forms.Form): + otp_code = forms.CharField(label=_('MFA code'), max_length=6) diff --git a/apps/authentication/migrations/0001_initial.py b/apps/authentication/migrations/0001_initial.py new file mode 100644 index 000000000..6e45f932b --- /dev/null +++ b/apps/authentication/migrations/0001_initial.py @@ -0,0 +1,56 @@ +# Generated by Django 2.1.7 on 2019-02-28 08:07 + +from django.conf import settings +from django.db import migrations, models +import django.db.models.deletion +import uuid + + +class Migration(migrations.Migration): + + initial = True + + dependencies = [ + migrations.swappable_dependency(settings.AUTH_USER_MODEL), + ('users', '0019_auto_20190304_1459'), + ] + + state_operations = [ + migrations.CreateModel( + name='AccessKey', + fields=[ + ('id', + models.UUIDField(default=uuid.uuid4, editable=False, + primary_key=True, serialize=False, + verbose_name='AccessKeyID')), + ('secret', + models.UUIDField(default=uuid.uuid4, editable=False, + verbose_name='AccessKeySecret')), + ('user', models.ForeignKey( + on_delete=django.db.models.deletion.CASCADE, + related_name='access_keys', + to=settings.AUTH_USER_MODEL, verbose_name='User')), + ], + ), + migrations.CreateModel( + name='PrivateToken', + fields=[ + ('key', + models.CharField(max_length=40, primary_key=True, + serialize=False, verbose_name='Key')), + ('created', models.DateTimeField(auto_now_add=True, + verbose_name='Created')), + ('user', models.OneToOneField( + on_delete=django.db.models.deletion.CASCADE, + related_name='auth_token', + to=settings.AUTH_USER_MODEL, verbose_name='User')), + ], + options={ + 'verbose_name': 'Private Token', + }, + ), + ] + + operations = [ + migrations.SeparateDatabaseAndState(state_operations=state_operations) + ] diff --git a/apps/authentication/migrations/__init__.py b/apps/authentication/migrations/__init__.py new file mode 100644 index 000000000..ec51c5a2b --- /dev/null +++ b/apps/authentication/migrations/__init__.py @@ -0,0 +1,2 @@ +# -*- coding: utf-8 -*- +# diff --git a/apps/authentication/models.py b/apps/authentication/models.py index 8b1378917..e4e822408 100644 --- a/apps/authentication/models.py +++ b/apps/authentication/models.py @@ -1 +1,33 @@ +import uuid +from django.db import models +from django.utils.translation import ugettext_lazy as _ +from rest_framework.authtoken.models import Token +from django.conf import settings + +class AccessKey(models.Model): + id = models.UUIDField(verbose_name='AccessKeyID', primary_key=True, + default=uuid.uuid4, editable=False) + secret = models.UUIDField(verbose_name='AccessKeySecret', + default=uuid.uuid4, editable=False) + user = models.ForeignKey(settings.AUTH_USER_MODEL, verbose_name='User', + on_delete=models.CASCADE, related_name='access_keys') + + def get_id(self): + return str(self.id) + + def get_secret(self): + return str(self.secret) + + def get_full_value(self): + return '{}:{}'.format(self.id, self.secret) + + def __str__(self): + return str(self.id) + + +class PrivateToken(Token): + """Inherit from auth token, otherwise migration is boring""" + + class Meta: + verbose_name = _('Private Token') \ No newline at end of file diff --git a/apps/authentication/serializers.py b/apps/authentication/serializers.py new file mode 100644 index 000000000..cf4968a56 --- /dev/null +++ b/apps/authentication/serializers.py @@ -0,0 +1,16 @@ +# -*- coding: utf-8 -*- +# +from rest_framework import serializers + +from .models import AccessKey + + +__all__ = ['AccessKeySerializer'] + + +class AccessKeySerializer(serializers.ModelSerializer): + + class Meta: + model = AccessKey + fields = ['id', 'secret'] + read_only_fields = ['id', 'secret'] diff --git a/apps/authentication/signals.py b/apps/authentication/signals.py index f33a3b821..0a305290c 100644 --- a/apps/authentication/signals.py +++ b/apps/authentication/signals.py @@ -1,4 +1,5 @@ from django.dispatch import Signal -post_create_openid_user = Signal(providing_args=('user',)) +post_auth_success = Signal(providing_args=('user', 'request')) +post_auth_failed = Signal(providing_args=('username', 'request', 'reason')) diff --git a/apps/authentication/signals_handlers.py b/apps/authentication/signals_handlers.py index d45ea1dfa..a0732894f 100644 --- a/apps/authentication/signals_handlers.py +++ b/apps/authentication/signals_handlers.py @@ -2,9 +2,16 @@ from django.http.request import QueryDict from django.conf import settings from django.dispatch import receiver from django.contrib.auth.signals import user_logged_out +from django.utils import timezone from django_auth_ldap.backend import populate_user -from .openid import client -from .signals import post_create_openid_user + +from common.utils import get_request_ip +from .backends.openid import new_client +from .backends.openid.signals import ( + post_create_openid_user, post_openid_login_success +) +from .tasks import write_login_log_async +from .signals import post_auth_success, post_auth_failed @receiver(user_logged_out) @@ -17,6 +24,7 @@ def on_user_logged_out(sender, request, user, **kwargs): 'redirect_uri': settings.BASE_SITE_URL }) + client = new_client() openid_logout_url = "%s?%s" % ( client.openid_connect_client.get_url( name='end_session_endpoint'), @@ -33,8 +41,46 @@ def on_post_create_openid_user(sender, user=None, **kwargs): user.save() +@receiver(post_openid_login_success) +def on_openid_login_success(sender, user=None, request=None, **kwargs): + post_auth_success.send(sender=sender, user=user, request=request) + + @receiver(populate_user) def on_ldap_create_user(sender, user, ldap_user, **kwargs): if user and user.name != 'admin': user.source = user.SOURCE_LDAP user.save() + + +def generate_data(username, request): + if not request.user.is_anonymous and request.user.is_app: + login_ip = request.data.get('remote_addr', None) + login_type = request.data.get('login_type', '') + user_agent = request.data.get('HTTP_USER_AGENT', '') + else: + login_ip = get_request_ip(request) + user_agent = request.META.get('HTTP_USER_AGENT', '') + login_type = 'W' + data = { + 'username': username, + 'ip': login_ip, + 'type': login_type, + 'user_agent': user_agent, + 'datetime': timezone.now() + } + return data + + +@receiver(post_auth_success) +def on_user_auth_success(sender, user, request, **kwargs): + data = generate_data(user.username, request) + data.update({'mfa': int(user.otp_enabled), 'status': True}) + write_login_log_async.delay(**data) + + +@receiver(post_auth_failed) +def on_user_auth_failed(sender, username, request, reason, **kwargs): + data = generate_data(username, request) + data.update({'reason': reason, 'status': False}) + write_login_log_async.delay(**data) diff --git a/apps/authentication/tasks.py b/apps/authentication/tasks.py new file mode 100644 index 000000000..d64d92992 --- /dev/null +++ b/apps/authentication/tasks.py @@ -0,0 +1,22 @@ +# -*- coding: utf-8 -*- +# + +from celery import shared_task +from ops.celery.decorator import register_as_period_task +from django.contrib.sessions.models import Session +from django.utils import timezone + +from .utils import write_login_log + + +@shared_task +def write_login_log_async(*args, **kwargs): + write_login_log(*args, **kwargs) + + +@register_as_period_task(interval=3600*24) +@shared_task +def clean_django_sessions(): + Session.objects.filter(expire_date__lt=timezone.now()).delete() + + diff --git a/apps/authentication/urls/api_urls.py b/apps/authentication/urls/api_urls.py index 8b1378917..b22c49884 100644 --- a/apps/authentication/urls/api_urls.py +++ b/apps/authentication/urls/api_urls.py @@ -1 +1,20 @@ +# coding:utf-8 +# + +from __future__ import absolute_import + +from django.urls import path + +from .. import api + +app_name = 'authentication' + + +urlpatterns = [ + # path('token/', api.UserToken.as_view(), name='user-token'), + path('auth/', api.UserAuthApi.as_view(), name='user-auth'), + path('connection-token/', + api.UserConnectionTokenApi.as_view(), name='connection-token'), + path('otp/auth/', api.UserOtpAuthApi.as_view(), name='user-otp-auth'), +] diff --git a/apps/authentication/urls/view_urls.py b/apps/authentication/urls/view_urls.py index 4d4e6753a..8602daca5 100644 --- a/apps/authentication/urls/view_urls.py +++ b/apps/authentication/urls/view_urls.py @@ -1,16 +1,20 @@ # coding:utf-8 # -from django.urls import path -from authentication.openid import views +from __future__ import absolute_import + +from django.urls import path, include + +from .. import views app_name = 'authentication' urlpatterns = [ # openid - path('openid/login/', views.LoginView.as_view(), name='openid-login'), - path('openid/login/complete/', views.LoginCompleteView.as_view(), - name='openid-login-complete'), + path('openid/', include(('authentication.backends.openid.urls', 'authentication'), namespace='openid')), - # other + # login + path('login/', views.UserLoginView.as_view(), name='login'), + path('login/otp/', views.UserLoginOtpView.as_view(), name='login-otp'), + path('logout/', views.UserLogoutView.as_view(), name='logout'), ] diff --git a/apps/authentication/utils.py b/apps/authentication/utils.py new file mode 100644 index 000000000..baf2fff31 --- /dev/null +++ b/apps/authentication/utils.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +# +from django.utils.translation import ugettext as _ +from common.utils import get_ip_city, validate_ip + + +def write_login_log(*args, **kwargs): + from audits.models import UserLoginLog + default_city = _("Unknown") + ip = kwargs.get('ip', '') + if not (ip and validate_ip(ip)): + ip = ip[:15] + city = default_city + else: + city = get_ip_city(ip) or default_city + kwargs.update({'ip': ip, 'city': city}) + UserLoginLog.objects.create(**kwargs) + diff --git a/apps/authentication/views.py b/apps/authentication/views.py deleted file mode 100644 index 8b1378917..000000000 --- a/apps/authentication/views.py +++ /dev/null @@ -1 +0,0 @@ - diff --git a/apps/authentication/views/__init__.py b/apps/authentication/views/__init__.py new file mode 100644 index 000000000..5e7732adc --- /dev/null +++ b/apps/authentication/views/__init__.py @@ -0,0 +1,4 @@ +# -*- coding: utf-8 -*- +# + +from .login import * diff --git a/apps/authentication/views/login.py b/apps/authentication/views/login.py new file mode 100644 index 000000000..89d647291 --- /dev/null +++ b/apps/authentication/views/login.py @@ -0,0 +1,208 @@ +# ~*~ coding: utf-8 ~*~ +# + +from __future__ import unicode_literals +import os +from django.core.cache import cache +from django.contrib.auth import login as auth_login, logout as auth_logout +from django.http import HttpResponse +from django.shortcuts import reverse, redirect +from django.utils.decorators import method_decorator +from django.utils.translation import ugettext as _ +from django.views.decorators.cache import never_cache +from django.views.decorators.csrf import csrf_protect +from django.views.decorators.debug import sensitive_post_parameters +from django.views.generic.base import TemplateView +from django.views.generic.edit import FormView +from django.conf import settings + +from common.utils import get_request_ip +from users.models import User +from audits.models import UserLoginLog as LoginLog +from users.utils import ( + check_otp_code, is_block_login, clean_failed_count, get_user_or_tmp_user, + set_tmp_user_to_cache, increase_login_failed_count, + redirect_user_first_login_or_index, +) +from ..signals import post_auth_success, post_auth_failed +from .. import forms + + +__all__ = [ + 'UserLoginView', 'UserLoginOtpView', 'UserLogoutView', +] + + +@method_decorator(sensitive_post_parameters(), name='dispatch') +@method_decorator(csrf_protect, name='dispatch') +@method_decorator(never_cache, name='dispatch') +class UserLoginView(FormView): + form_class = forms.UserLoginForm + form_class_captcha = forms.UserLoginCaptchaForm + redirect_field_name = 'next' + key_prefix_captcha = "_LOGIN_INVALID_{}" + + def get_template_names(self): + template_name = 'users/login.html' + if not settings.XPACK_ENABLED: + return template_name + + from xpack.plugins.license.models import License + if not License.has_valid_license(): + return template_name + + template_name = 'users/new_login.html' + return template_name + + def get(self, request, *args, **kwargs): + if request.user.is_staff: + return redirect(redirect_user_first_login_or_index( + request, self.redirect_field_name) + ) + request.session.set_test_cookie() + return super().get(request, *args, **kwargs) + + def post(self, request, *args, **kwargs): + # limit login authentication + ip = get_request_ip(request) + username = self.request.POST.get('username') + if is_block_login(username, ip): + return self.render_to_response(self.get_context_data(block_login=True)) + return super().post(request, *args, **kwargs) + + def form_valid(self, form): + if not self.request.session.test_cookie_worked(): + return HttpResponse(_("Please enable cookies and try again.")) + user = form.get_user() + # user password expired + if user.password_has_expired: + reason = LoginLog.REASON_PASSWORD_EXPIRED + self.send_auth_signal(success=False, username=user.username, reason=reason) + return self.render_to_response(self.get_context_data(password_expired=True)) + + set_tmp_user_to_cache(self.request, user) + username = form.cleaned_data.get('username') + ip = get_request_ip(self.request) + # 登陆成功,清除缓存计数 + clean_failed_count(username, ip) + return redirect(self.get_success_url()) + + def form_invalid(self, form): + # write login failed log + username = form.cleaned_data.get('username') + exist = User.objects.filter(username=username).first() + reason = LoginLog.REASON_PASSWORD if exist else LoginLog.REASON_NOT_EXIST + # limit user login failed count + ip = get_request_ip(self.request) + increase_login_failed_count(username, ip) + # show captcha + cache.set(self.key_prefix_captcha.format(ip), 1, 3600) + self.send_auth_signal(success=False, username=username, reason=reason) + + old_form = form + form = self.form_class_captcha(data=form.data) + form._errors = old_form.errors + return super().form_invalid(form) + + def get_form_class(self): + ip = get_request_ip(self.request) + if cache.get(self.key_prefix_captcha.format(ip)): + return self.form_class_captcha + else: + return self.form_class + + def get_success_url(self): + user = get_user_or_tmp_user(self.request) + + if user.otp_enabled and user.otp_secret_key: + # 1,2,mfa_setting & T + return reverse('authentication:login-otp') + elif user.otp_enabled and not user.otp_secret_key: + # 1,2,mfa_setting & F + return reverse('users:user-otp-enable-authentication') + elif not user.otp_enabled: + # 0 & T,F + auth_login(self.request, user) + self.send_auth_signal(success=True, user=user) + return redirect_user_first_login_or_index(self.request, self.redirect_field_name) + + def get_context_data(self, **kwargs): + context = { + 'demo_mode': os.environ.get("DEMO_MODE"), + 'AUTH_OPENID': settings.AUTH_OPENID, + } + kwargs.update(context) + return super().get_context_data(**kwargs) + + def send_auth_signal(self, success=True, user=None, username='', reason=''): + if success: + post_auth_success.send(sender=self.__class__, user=user, request=self.request) + else: + post_auth_failed.send( + sender=self.__class__, username=username, + request=self.request, reason=reason + ) + + +class UserLoginOtpView(FormView): + template_name = 'users/login_otp.html' + form_class = forms.UserCheckOtpCodeForm + redirect_field_name = 'next' + + def form_valid(self, form): + user = get_user_or_tmp_user(self.request) + otp_code = form.cleaned_data.get('otp_code') + otp_secret_key = user.otp_secret_key + + if check_otp_code(otp_secret_key, otp_code): + auth_login(self.request, user) + self.send_auth_signal(success=True, user=user) + return redirect(self.get_success_url()) + else: + self.send_auth_signal( + success=False, username=user.username, + reason=LoginLog.REASON_MFA + ) + form.add_error( + 'otp_code', _('MFA code invalid, or ntp sync server time') + ) + return super().form_invalid(form) + + def get_success_url(self): + return redirect_user_first_login_or_index(self.request, self.redirect_field_name) + + def send_auth_signal(self, success=True, user=None, username='', reason=''): + if success: + post_auth_success.send(sender=self.__class__, user=user, request=self.request) + else: + post_auth_failed.send( + sender=self.__class__, username=username, + request=self.request, reason=reason + ) + + +@method_decorator(never_cache, name='dispatch') +class UserLogoutView(TemplateView): + template_name = 'flash_message_standalone.html' + + def get(self, request, *args, **kwargs): + auth_logout(request) + next_uri = request.COOKIES.get("next") + if next_uri: + return redirect(next_uri) + response = super().get(request, *args, **kwargs) + return response + + def get_context_data(self, **kwargs): + context = { + 'title': _('Logout success'), + 'messages': _('Logout success, return login page'), + 'interval': 1, + 'redirect_url': reverse('authentication:login'), + 'auto_redirect': True, + } + kwargs.update(context) + return super().get_context_data(**kwargs) + + + diff --git a/apps/common/api.py b/apps/common/api.py index cf3855b60..269d493d0 100644 --- a/apps/common/api.py +++ b/apps/common/api.py @@ -1,197 +1,17 @@ # -*- coding: utf-8 -*- # - import os -import json -import jms_storage import uuid -from rest_framework.views import Response, APIView -from rest_framework import generics -from ldap3 import Server, Connection -from django.core.mail import send_mail +from rest_framework.views import Response +from rest_framework import generics, serializers from django.core.cache import cache -from django.utils.translation import ugettext_lazy as _ -from django.conf import settings - -from .permissions import IsOrgAdmin, IsSuperUser -from .serializers import ( - MailTestSerializer, LDAPTestSerializer, OutputSerializer -) -from .models import Setting -class MailTestingAPI(APIView): - permission_classes = (IsOrgAdmin,) - serializer_class = MailTestSerializer - success_message = _("Test mail sent to {}, please check") - - def post(self, request): - serializer = self.serializer_class(data=request.data) - if serializer.is_valid(): - email_host_user = serializer.validated_data["EMAIL_HOST_USER"] - for k, v in serializer.validated_data.items(): - if k.startswith('EMAIL'): - setattr(settings, k, v) - try: - subject = "Test" - message = "Test smtp setting" - send_mail(subject, message, email_host_user, [email_host_user]) - except Exception as e: - return Response({"error": str(e)}, status=401) - - return Response({"msg": self.success_message.format(email_host_user)}) - else: - return Response({"error": str(serializer.errors)}, status=401) - - -class LDAPTestingAPI(APIView): - permission_classes = (IsOrgAdmin,) - serializer_class = LDAPTestSerializer - success_message = _("Test ldap success") - - def post(self, request): - serializer = self.serializer_class(data=request.data) - if serializer.is_valid(): - host = serializer.validated_data["AUTH_LDAP_SERVER_URI"] - bind_dn = serializer.validated_data["AUTH_LDAP_BIND_DN"] - password = serializer.validated_data["AUTH_LDAP_BIND_PASSWORD"] - use_ssl = serializer.validated_data.get("AUTH_LDAP_START_TLS", False) - search_ougroup = serializer.validated_data["AUTH_LDAP_SEARCH_OU"] - search_filter = serializer.validated_data["AUTH_LDAP_SEARCH_FILTER"] - attr_map = serializer.validated_data["AUTH_LDAP_USER_ATTR_MAP"] - - try: - attr_map = json.loads(attr_map) - except json.JSONDecodeError: - return Response({"error": "AUTH_LDAP_USER_ATTR_MAP not valid"}, status=401) - - server = Server(host, use_ssl=use_ssl) - conn = Connection(server, bind_dn, password) - try: - conn.bind() - except Exception as e: - return Response({"error": str(e)}, status=401) - - users = [] - for search_ou in str(search_ougroup).split("|"): - ok = conn.search(search_ou, search_filter % ({"user": "*"}), - attributes=list(attr_map.values())) - if not ok: - return Response({"error": _("Search no entry matched in ou {}").format(search_ou)}, status=401) - - for entry in conn.entries: - user = {} - for attr, mapping in attr_map.items(): - if hasattr(entry, mapping): - user[attr] = getattr(entry, mapping) - users.append(user) - if len(users) > 0: - return Response({"msg": _("Match {} s users").format(len(users))}) - else: - return Response({"error": "Have user but attr mapping error"}, status=401) - else: - return Response({"error": str(serializer.errors)}, status=401) - - -class ReplayStorageCreateAPI(APIView): - permission_classes = (IsSuperUser,) - - def post(self, request): - storage_data = request.data - - if storage_data.get('TYPE') == 'ceph': - port = storage_data.get('PORT') - if port.isdigit(): - storage_data['PORT'] = int(storage_data.get('PORT')) - - storage_name = storage_data.pop('NAME') - data = {storage_name: storage_data} - - if not self.is_valid(storage_data): - return Response({ - "error": _("Error: Account invalid (Please make sure the " - "information such as Access key or Secret key is correct)")}, - status=401 - ) - - Setting.save_storage('TERMINAL_REPLAY_STORAGE', data) - return Response({"msg": _('Create succeed')}, status=200) - - @staticmethod - def is_valid(storage_data): - if storage_data.get('TYPE') == 'server': - return True - storage = jms_storage.get_object_storage(storage_data) - target = 'tests.py' - src = os.path.join(settings.BASE_DIR, 'common', target) - return storage.is_valid(src, target) - - -class ReplayStorageDeleteAPI(APIView): - permission_classes = (IsSuperUser,) - - def post(self, request): - storage_name = str(request.data.get('name')) - Setting.delete_storage('TERMINAL_REPLAY_STORAGE', storage_name) - return Response({"msg": _('Delete succeed')}, status=200) - - -class CommandStorageCreateAPI(APIView): - permission_classes = (IsSuperUser,) - - def post(self, request): - storage_data = request.data - storage_name = storage_data.pop('NAME') - data = {storage_name: storage_data} - if not self.is_valid(storage_data): - return Response( - {"error": _("Error: Account invalid (Please make sure the " - "information such as Access key or Secret key is correct)")}, - status=401 - ) - - Setting.save_storage('TERMINAL_COMMAND_STORAGE', data) - return Response({"msg": _('Create succeed')}, status=200) - - @staticmethod - def is_valid(storage_data): - if storage_data.get('TYPE') == 'server': - return True - try: - storage = jms_storage.get_log_storage(storage_data) - except Exception: - return False - - return storage.ping() - - -class CommandStorageDeleteAPI(APIView): - permission_classes = (IsSuperUser,) - - def post(self, request): - storage_name = str(request.data.get('name')) - Setting.delete_storage('TERMINAL_COMMAND_STORAGE', storage_name) - return Response({"msg": _('Delete succeed')}, status=200) - - -class DjangoSettingsAPI(APIView): - def get(self, request): - if not settings.DEBUG: - return Response("Not in debug mode") - - data = {} - for i in [settings, getattr(settings, '_wrapped')]: - if not i: - continue - for k, v in i.__dict__.items(): - if k and k.isupper(): - try: - json.dumps(v) - data[k] = v - except (json.JSONDecodeError, TypeError): - data[k] = str(v) - return Response(data) +class OutputSerializer(serializers.Serializer): + output = serializers.CharField() + is_end = serializers.BooleanField() + mark = serializers.CharField() class LogTailApi(generics.RetrieveAPIView): diff --git a/apps/common/apps.py b/apps/common/apps.py index bc6db2151..ea797805d 100644 --- a/apps/common/apps.py +++ b/apps/common/apps.py @@ -1,13 +1,17 @@ from __future__ import unicode_literals +import sys from django.apps import AppConfig +from django.dispatch import receiver +from django.db.backends.signals import connection_created + + +@receiver(connection_created, dispatch_uid="my_unique_identifier") +def on_db_connection_ready(sender, **kwargs): + from .signals import django_ready + if 'migrate' not in sys.argv: + django_ready.send(CommonConfig) class CommonConfig(AppConfig): name = 'common' - - def ready(self): - from . import signals_handler - from .signals import django_ready - django_ready.send(self.__class__) - return super().ready() diff --git a/apps/common/fields.py b/apps/common/fields.py deleted file mode 100644 index cccc265de..000000000 --- a/apps/common/fields.py +++ /dev/null @@ -1,106 +0,0 @@ -# -*- coding: utf-8 -*- -# -import json - -from django.db import models -from django import forms -from django.utils import six -from django.core.exceptions import ValidationError -from django.utils.translation import ugettext as _ -from rest_framework import serializers -from .utils import get_signer - -signer = get_signer() - - -class FormDictField(forms.Field): - widget = forms.Textarea - - def to_python(self, value): - """Returns a Python boolean object.""" - # Explicitly check for the string 'False', which is what a hidden field - # will submit for False. Also check for '0', since this is what - # RadioSelect will provide. Because bool("True") == bool('1') == True, - # we don't need to handle that explicitly. - if isinstance(value, six.string_types): - value = value.replace("'", '"') - try: - value = json.loads(value) - return value - except json.JSONDecodeError: - return ValidationError(_("Not a valid json")) - else: - return ValidationError(_("Not a string type")) - - def validate(self, value): - if isinstance(value, ValidationError): - raise value - if not value and self.required: - raise ValidationError(self.error_messages['required'], code='required') - - def has_changed(self, initial, data): - # Sometimes data or initial may be a string equivalent of a boolean - # so we should run it through to_python first to get a boolean value - return self.to_python(initial) != self.to_python(data) - - -class StringIDField(serializers.Field): - def to_representation(self, value): - return {"pk": value.pk, "name": value.__str__()} - - -class StringManyToManyField(serializers.RelatedField): - def to_representation(self, value): - return value.__str__() - - -class EncryptMixin: - def from_db_value(self, value, expression, connection, context): - if value is not None: - return signer.unsign(value) - return super().from_db_value(self, value, expression, connection, context) - - def get_prep_value(self, value): - if value is None: - return value - return signer.sign(value) - - -class EncryptTextField(EncryptMixin, models.TextField): - description = _("Encrypt field using Secret Key") - - -class EncryptCharField(EncryptMixin, models.CharField): - def __init__(self, *args, **kwargs): - kwargs['max_length'] = 2048 - super().__init__(*args, **kwargs) - - -class FormEncryptMixin: - pass - - -class FormEncryptCharField(FormEncryptMixin, forms.CharField): - pass - - -class FormEncryptDictField(FormEncryptMixin, FormDictField): - pass - - -class ChoiceDisplayField(serializers.ChoiceField): - def __init__(self, *args, **kwargs): - super(ChoiceDisplayField, self).__init__(*args, **kwargs) - self.choice_strings_to_display = { - six.text_type(key): value for key, value in self.choices.items() - } - - def to_representation(self, value): - if value is None: - return value - return { - 'value': self.choice_strings_to_values.get(six.text_type(value), - value), - 'display': self.choice_strings_to_display.get(six.text_type(value), - value), - } diff --git a/apps/common/fields/__init__.py b/apps/common/fields/__init__.py new file mode 100644 index 000000000..f918a3279 --- /dev/null +++ b/apps/common/fields/__init__.py @@ -0,0 +1,6 @@ +# -*- coding: utf-8 -*- +# + +from .form import * +from .model import * +from .serializer import * diff --git a/apps/common/fields/form.py b/apps/common/fields/form.py new file mode 100644 index 000000000..156e331dd --- /dev/null +++ b/apps/common/fields/form.py @@ -0,0 +1,63 @@ +# -*- coding: utf-8 -*- +# +import json + +from django import forms +from django.utils import six +from django.core.exceptions import ValidationError +from django.utils.translation import ugettext as _ +from ..utils import get_signer + +signer = get_signer() + +__all__ = [ + 'FormDictField', 'FormEncryptCharField', 'FormEncryptDictField', + 'FormEncryptMixin', +] + + +class FormDictField(forms.Field): + widget = forms.Textarea + + def to_python(self, value): + """Returns a Python boolean object.""" + # Explicitly check for the string 'False', which is what a hidden field + # will submit for False. Also check for '0', since this is what + # RadioSelect will provide. Because bool("True") == bool('1') == True, + # we don't need to handle that explicitly. + if isinstance(value, six.string_types): + value = value.replace("'", '"') + try: + value = json.loads(value) + return value + except json.JSONDecodeError: + return ValidationError(_("Not a valid json")) + else: + return ValidationError(_("Not a string type")) + + def validate(self, value): + if isinstance(value, ValidationError): + raise value + if not value and self.required: + raise ValidationError(self.error_messages['required'], code='required') + + def has_changed(self, initial, data): + # Sometimes data or initial may be a string equivalent of a boolean + # so we should run it through to_python first to get a boolean value + return self.to_python(initial) != self.to_python(data) + + +class FormEncryptMixin: + pass + + +class FormEncryptCharField(FormEncryptMixin, forms.CharField): + pass + + +class FormEncryptDictField(FormEncryptMixin, FormDictField): + pass + + + + diff --git a/apps/common/fields/model.py b/apps/common/fields/model.py new file mode 100644 index 000000000..b844d3517 --- /dev/null +++ b/apps/common/fields/model.py @@ -0,0 +1,132 @@ +# -*- coding: utf-8 -*- +# +import json +from django.db import models +from django.utils.translation import ugettext_lazy as _ + +from ..utils import get_signer + + +__all__ = [ + 'JsonMixin', 'JsonDictMixin', 'JsonListMixin', 'JsonTypeMixin', + 'JsonCharField', 'JsonTextField', 'JsonListCharField', 'JsonListTextField', + 'JsonDictCharField', 'JsonDictTextField', 'EncryptCharField', + 'EncryptTextField', 'EncryptMixin', +] +signer = get_signer() + + +class JsonMixin: + tp = None + + @staticmethod + def json_decode(data): + try: + return json.loads(data) + except (TypeError, json.JSONDecodeError): + return None + + @staticmethod + def json_encode(data): + return json.dumps(data) + + def from_db_value(self, value, expression, connection, context): + if value is None: + return value + return self.json_decode(value) + + def to_python(self, value): + if value is None: + return value + + if not isinstance(value, str) or not value.startswith('"'): + return value + else: + return self.json_decode(value) + + def get_prep_value(self, value): + if value is None: + return value + return self.json_encode(value) + + +class JsonTypeMixin(JsonMixin): + tp = dict + + def from_db_value(self, value, expression, connection, context): + value = super().from_db_value(value, expression, connection, context) + if not isinstance(value, self.tp): + value = self.tp() + return value + + def to_python(self, value): + data = super().to_python(value) + if not isinstance(data, self.tp): + data = self.tp() + return data + + def get_prep_value(self, value): + if not isinstance(value, self.tp): + value = self.tp() + return self.json_encode(value) + + +class JsonDictMixin(JsonTypeMixin): + tp = dict + + +class JsonDictCharField(JsonDictMixin, models.CharField): + description = _("Marshal dict data to char field") + + +class JsonDictTextField(JsonDictMixin, models.TextField): + description = _("Marshal dict data to text field") + + +class JsonListMixin(JsonTypeMixin): + tp = list + + +class JsonStrListMixin(JsonListMixin): + pass + + +class JsonListCharField(JsonListMixin, models.CharField): + description = _("Marshal list data to char field") + + +class JsonListTextField(JsonListMixin, models.TextField): + description = _("Marshal list data to text field") + + +class JsonCharField(JsonMixin, models.CharField): + description = _("Marshal data to char field") + + +class JsonTextField(JsonMixin, models.TextField): + description = _("Marshal data to text field") + + +class EncryptMixin: + def from_db_value(self, value, expression, connection, context): + if value is not None: + return signer.unsign(value) + return None + + def get_prep_value(self, value): + if value is None: + return value + return signer.sign(value) + + +class EncryptTextField(EncryptMixin, models.TextField): + description = _("Encrypt field using Secret Key") + + +class EncryptCharField(EncryptMixin, models.CharField): + def __init__(self, *args, **kwargs): + kwargs['max_length'] = 2048 + super().__init__(*args, **kwargs) + + + diff --git a/apps/common/fields/serializer.py b/apps/common/fields/serializer.py new file mode 100644 index 000000000..339be075c --- /dev/null +++ b/apps/common/fields/serializer.py @@ -0,0 +1,41 @@ +# -*- coding: utf-8 -*- +# + +from rest_framework import serializers +from django.utils import six + + +__all__ = ['StringIDField', 'StringManyToManyField', 'ChoiceDisplayField'] + + +class StringIDField(serializers.Field): + def to_representation(self, value): + return {"pk": value.pk, "name": value.__str__()} + + +class StringManyToManyField(serializers.RelatedField): + def to_representation(self, value): + return value.__str__() + + +class ChoiceDisplayField(serializers.ChoiceField): + def __init__(self, *args, **kwargs): + super(ChoiceDisplayField, self).__init__(*args, **kwargs) + self.choice_strings_to_display = { + six.text_type(key): value for key, value in self.choices.items() + } + + def to_representation(self, value): + if value is None: + return value + return { + 'value': self.choice_strings_to_values.get(six.text_type(value), value), + 'display': self.choice_strings_to_display.get(six.text_type(value), value), + } + + +class DictField(serializers.DictField): + def to_representation(self, value): + if not value or not isinstance(value, dict): + value = {} + return super().to_representation(value) diff --git a/apps/common/migrations/0006_auto_20190304_1515.py b/apps/common/migrations/0006_auto_20190304_1515.py new file mode 100644 index 000000000..77303a39a --- /dev/null +++ b/apps/common/migrations/0006_auto_20190304_1515.py @@ -0,0 +1,22 @@ +# Generated by Django 2.1.7 on 2019-03-04 07:15 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('common', '0005_auto_20190221_1902'), + ] + + database_operations = [ + migrations.AlterModelTable('setting', 'settings_setting') + ] + state_operations = [migrations.DeleteModel('setting')] + + operations = [ + migrations.SeparateDatabaseAndState( + database_operations=database_operations, + state_operations=state_operations + ) + ] diff --git a/apps/common/tasks.py b/apps/common/tasks.py index 5aefd28ee..dec738921 100644 --- a/apps/common/tasks.py +++ b/apps/common/tasks.py @@ -2,7 +2,6 @@ from django.core.mail import send_mail from django.conf import settings from celery import shared_task from .utils import get_logger -from .models import Setting logger = get_logger(__file__) diff --git a/apps/common/utils/__init__.py b/apps/common/utils/__init__.py new file mode 100644 index 000000000..802943072 --- /dev/null +++ b/apps/common/utils/__init__.py @@ -0,0 +1,8 @@ +# -*- coding: utf-8 -*- +# + +from .common import * +from .django import * +from .encode import * +from .http import * +from .ipip import * diff --git a/apps/common/utils.py b/apps/common/utils/common.py similarity index 54% rename from apps/common/utils.py rename to apps/common/utils/common.py index 85f47ae00..dcd7daf16 100644 --- a/apps/common/utils.py +++ b/apps/common/utils/common.py @@ -1,104 +1,18 @@ # -*- coding: utf-8 -*- # import re -import sys from collections import OrderedDict -from six import string_types -import base64 -import os from itertools import chain import logging import datetime -import time -import hashlib -from email.utils import formatdate -import calendar -import threading -from io import StringIO import uuid from functools import wraps import copy - -import paramiko -import sshpubkeys -from itsdangerous import TimedJSONWebSignatureSerializer, JSONWebSignatureSerializer, \ - BadSignature, SignatureExpired -from django.shortcuts import reverse as dj_reverse -from django.conf import settings -from django.utils import timezone +import ipaddress UUID_PATTERN = re.compile(r'[0-9a-zA-Z\-]{36}') - - -def reverse(view_name, urlconf=None, args=None, kwargs=None, - current_app=None, external=False): - url = dj_reverse(view_name, urlconf=urlconf, args=args, - kwargs=kwargs, current_app=current_app) - - if external: - site_url = settings.SITE_URL - url = site_url.strip('/') + url - return url - - -def get_object_or_none(model, **kwargs): - try: - obj = model.objects.get(**kwargs) - except model.DoesNotExist: - return None - return obj - - -class Singleton(type): - def __init__(cls, *args, **kwargs): - cls.__instance = None - super().__init__(*args, **kwargs) - - def __call__(cls, *args, **kwargs): - if cls.__instance is None: - cls.__instance = super().__call__(*args, **kwargs) - return cls.__instance - else: - return cls.__instance - - -class Signer(metaclass=Singleton): - """用来加密,解密,和基于时间戳的方式验证token""" - def __init__(self, secret_key=None): - self.secret_key = secret_key - - def sign(self, value): - s = JSONWebSignatureSerializer(self.secret_key, algorithm_name='HS256') - return s.dumps(value).decode() - - def unsign(self, value): - if value is None: - return value - s = JSONWebSignatureSerializer(self.secret_key, algorithm_name='HS256') - try: - return s.loads(value) - except BadSignature: - return {} - - def sign_t(self, value, expires_in=3600): - s = TimedJSONWebSignatureSerializer(self.secret_key, expires_in=expires_in) - return str(s.dumps(value), encoding="utf8") - - def unsign_t(self, value): - s = TimedJSONWebSignatureSerializer(self.secret_key) - try: - return s.loads(value) - except (BadSignature, SignatureExpired): - return {} - - -def date_expired_default(): - try: - years = int(settings.DEFAULT_EXPIRED_YEARS) - except TypeError: - years = 70 - return timezone.now() + timezone.timedelta(days=365*years) +ipip_db = None def combine_seq(s1, s2, callback=None): @@ -146,88 +60,6 @@ def timesince(dt, since='', default="just now"): return default -def ssh_key_string_to_obj(text, password=None): - key = None - try: - key = paramiko.RSAKey.from_private_key(StringIO(text), password=password) - except paramiko.SSHException: - pass - - try: - key = paramiko.DSSKey.from_private_key(StringIO(text), password=password) - except paramiko.SSHException: - pass - return key - - -def ssh_pubkey_gen(private_key=None, username='jumpserver', hostname='localhost', password=None): - if isinstance(private_key, bytes): - private_key = private_key.decode("utf-8") - if isinstance(private_key, string_types): - private_key = ssh_key_string_to_obj(private_key, password=password) - if not isinstance(private_key, (paramiko.RSAKey, paramiko.DSSKey)): - raise IOError('Invalid private key') - - public_key = "%(key_type)s %(key_content)s %(username)s@%(hostname)s" % { - 'key_type': private_key.get_name(), - 'key_content': private_key.get_base64(), - 'username': username, - 'hostname': hostname, - } - return public_key - - -def ssh_key_gen(length=2048, type='rsa', password=None, username='jumpserver', hostname=None): - """Generate user ssh private and public key - - Use paramiko RSAKey generate it. - :return private key str and public key str - """ - - if hostname is None: - hostname = os.uname()[1] - - f = StringIO() - try: - if type == 'rsa': - private_key_obj = paramiko.RSAKey.generate(length) - elif type == 'dsa': - private_key_obj = paramiko.DSSKey.generate(length) - else: - raise IOError('SSH private key must be `rsa` or `dsa`') - private_key_obj.write_private_key(f, password=password) - private_key = f.getvalue() - public_key = ssh_pubkey_gen(private_key_obj, username=username, hostname=hostname) - return private_key, public_key - except IOError: - raise IOError('These is error when generate ssh key.') - - -def validate_ssh_private_key(text, password=None): - if isinstance(text, bytes): - try: - text = text.decode("utf-8") - except UnicodeDecodeError: - return False - - key = ssh_key_string_to_obj(text, password=password) - if key is None: - return False - else: - return True - - -def validate_ssh_public_key(text): - ssh = sshpubkeys.SSHKey(text) - try: - ssh.parse() - except (sshpubkeys.InvalidKeyException, UnicodeDecodeError): - return False - except NotImplementedError as e: - return False - return True - - def setattr_bulk(seq, key, value): def set_attr(obj): setattr(obj, key, value) @@ -243,70 +75,6 @@ def set_or_append_attr_bulk(seq, key, value): setattr(obj, key, value) -def content_md5(data): - """计算data的MD5值,经过Base64编码并返回str类型。 - - 返回值可以直接作为HTTP Content-Type头部的值 - """ - if isinstance(data, str): - data = hashlib.md5(data.encode('utf-8')) - value = base64.b64encode(data.hexdigest().encode('utf-8')) - return value.decode('utf-8') - - -_STRPTIME_LOCK = threading.Lock() - -_GMT_FORMAT = "%a, %d %b %Y %H:%M:%S GMT" -_ISO8601_FORMAT = "%Y-%m-%dT%H:%M:%S.000Z" - - -def to_unixtime(time_string, format_string): - time_string = time_string.decode("ascii") - with _STRPTIME_LOCK: - return int(calendar.timegm(time.strptime(time_string, format_string))) - - -def http_date(timeval=None): - """返回符合HTTP标准的GMT时间字符串,用strftime的格式表示就是"%a, %d %b %Y %H:%M:%S GMT"。 - 但不能使用strftime,因为strftime的结果是和locale相关的。 - """ - return formatdate(timeval, usegmt=True) - - -def http_to_unixtime(time_string): - """把HTTP Date格式的字符串转换为UNIX时间(自1970年1月1日UTC零点的秒数)。 - - HTTP Date形如 `Sat, 05 Dec 2015 11:10:29 GMT` 。 - """ - return to_unixtime(time_string, _GMT_FORMAT) - - -def iso8601_to_unixtime(time_string): - """把ISO8601时间字符串(形如,2012-02-24T06:07:48.000Z)转换为UNIX时间,精确到秒。""" - return to_unixtime(time_string, _ISO8601_FORMAT) - - -def make_signature(access_key_secret, date=None): - if isinstance(date, bytes): - date = bytes.decode(date) - if isinstance(date, int): - date_gmt = http_date(date) - elif date is None: - date_gmt = http_date(int(time.time())) - else: - date_gmt = date - - data = str(access_key_secret) + "\n" + date_gmt - return content_md5(data) - - -def encrypt_password(password, salt=None): - from passlib.hash import sha512_crypt - if password: - return sha512_crypt.using(rounds=5000).hash(password, salt=salt) - return None - - def capacity_convert(size, expect='auto', rate=1000): """ :param size: '100MB', '1G' @@ -374,11 +142,6 @@ def is_uuid(seq): return True -def get_signer(): - signer = Signer(settings.SECRET_KEY) - return signer - - def get_request_ip(request): x_forwarded_for = request.META.get('HTTP_X_FORWARDED_FOR', '').split(',') if x_forwarded_for and x_forwarded_for[0]: @@ -388,22 +151,13 @@ def get_request_ip(request): return login_ip -def get_command_storage_setting(): - default = settings.DEFAULT_TERMINAL_COMMAND_STORAGE - value = settings.TERMINAL_COMMAND_STORAGE - if not value: - return default - value.update(default) - return value - - -def get_replay_storage_setting(): - default = settings.DEFAULT_TERMINAL_REPLAY_STORAGE - value = settings.TERMINAL_REPLAY_STORAGE - if not value: - return default - value.update(default) - return value +def validate_ip(ip): + try: + ipaddress.ip_address(ip) + return True + except ValueError: + pass + return False def with_cache(func): @@ -537,4 +291,4 @@ class LocalProxy(object): __rmod__ = lambda x, o: o % x._get_current_object() __rdivmod__ = lambda x, o: x._get_current_object().__rdivmod__(o) __copy__ = lambda x: copy.copy(x._get_current_object()) - __deepcopy__ = lambda x, memo: copy.deepcopy(x._get_current_object(), memo) \ No newline at end of file + __deepcopy__ = lambda x, memo: copy.deepcopy(x._get_current_object(), memo) diff --git a/apps/common/utils/django.py b/apps/common/utils/django.py new file mode 100644 index 000000000..9a0af8f7d --- /dev/null +++ b/apps/common/utils/django.py @@ -0,0 +1,54 @@ +# -*- coding: utf-8 -*- +# +import re +from django.shortcuts import reverse as dj_reverse +from django.conf import settings +from django.utils import timezone + + +UUID_PATTERN = re.compile(r'[0-9a-zA-Z\-]{36}') + + +def reverse(view_name, urlconf=None, args=None, kwargs=None, + current_app=None, external=False): + url = dj_reverse(view_name, urlconf=urlconf, args=args, + kwargs=kwargs, current_app=current_app) + + if external: + site_url = settings.SITE_URL + url = site_url.strip('/') + url + return url + + +def get_object_or_none(model, **kwargs): + try: + obj = model.objects.get(**kwargs) + except model.DoesNotExist: + return None + return obj + + +def date_expired_default(): + try: + years = int(settings.DEFAULT_EXPIRED_YEARS) + except TypeError: + years = 70 + return timezone.now() + timezone.timedelta(days=365*years) + + +def get_command_storage_setting(): + default = settings.DEFAULT_TERMINAL_COMMAND_STORAGE + value = settings.TERMINAL_COMMAND_STORAGE + if not value: + return default + value.update(default) + return value + + +def get_replay_storage_setting(): + default = settings.DEFAULT_TERMINAL_REPLAY_STORAGE + value = settings.TERMINAL_REPLAY_STORAGE + if not value: + return default + value.update(default) + return value diff --git a/apps/common/utils/encode.py b/apps/common/utils/encode.py new file mode 100644 index 000000000..aefa19238 --- /dev/null +++ b/apps/common/utils/encode.py @@ -0,0 +1,184 @@ +# -*- coding: utf-8 -*- +# +import re +from six import string_types +import base64 +import os +import time +import hashlib +from io import StringIO + +import paramiko +import sshpubkeys +from itsdangerous import ( + TimedJSONWebSignatureSerializer, JSONWebSignatureSerializer, + BadSignature, SignatureExpired +) +from django.conf import settings + +from .http import http_date + + +UUID_PATTERN = re.compile(r'[0-9a-zA-Z\-]{36}') + + +class Singleton(type): + def __init__(cls, *args, **kwargs): + cls.__instance = None + super().__init__(*args, **kwargs) + + def __call__(cls, *args, **kwargs): + if cls.__instance is None: + cls.__instance = super().__call__(*args, **kwargs) + return cls.__instance + else: + return cls.__instance + + +class Signer(metaclass=Singleton): + """用来加密,解密,和基于时间戳的方式验证token""" + def __init__(self, secret_key=None): + self.secret_key = secret_key + + def sign(self, value): + s = JSONWebSignatureSerializer(self.secret_key, algorithm_name='HS256') + return s.dumps(value).decode() + + def unsign(self, value): + if value is None: + return value + s = JSONWebSignatureSerializer(self.secret_key, algorithm_name='HS256') + try: + return s.loads(value) + except BadSignature: + return {} + + def sign_t(self, value, expires_in=3600): + s = TimedJSONWebSignatureSerializer(self.secret_key, expires_in=expires_in) + return str(s.dumps(value), encoding="utf8") + + def unsign_t(self, value): + s = TimedJSONWebSignatureSerializer(self.secret_key) + try: + return s.loads(value) + except (BadSignature, SignatureExpired): + return {} + + +def ssh_key_string_to_obj(text, password=None): + key = None + try: + key = paramiko.RSAKey.from_private_key(StringIO(text), password=password) + except paramiko.SSHException: + pass + + try: + key = paramiko.DSSKey.from_private_key(StringIO(text), password=password) + except paramiko.SSHException: + pass + return key + + +def ssh_pubkey_gen(private_key=None, username='jumpserver', hostname='localhost', password=None): + if isinstance(private_key, bytes): + private_key = private_key.decode("utf-8") + if isinstance(private_key, string_types): + private_key = ssh_key_string_to_obj(private_key, password=password) + if not isinstance(private_key, (paramiko.RSAKey, paramiko.DSSKey)): + raise IOError('Invalid private key') + + public_key = "%(key_type)s %(key_content)s %(username)s@%(hostname)s" % { + 'key_type': private_key.get_name(), + 'key_content': private_key.get_base64(), + 'username': username, + 'hostname': hostname, + } + return public_key + + +def ssh_key_gen(length=2048, type='rsa', password=None, username='jumpserver', hostname=None): + """Generate user ssh private and public key + + Use paramiko RSAKey generate it. + :return private key str and public key str + """ + + if hostname is None: + hostname = os.uname()[1] + + f = StringIO() + try: + if type == 'rsa': + private_key_obj = paramiko.RSAKey.generate(length) + elif type == 'dsa': + private_key_obj = paramiko.DSSKey.generate(length) + else: + raise IOError('SSH private key must be `rsa` or `dsa`') + private_key_obj.write_private_key(f, password=password) + private_key = f.getvalue() + public_key = ssh_pubkey_gen(private_key_obj, username=username, hostname=hostname) + return private_key, public_key + except IOError: + raise IOError('These is error when generate ssh key.') + + +def validate_ssh_private_key(text, password=None): + if isinstance(text, bytes): + try: + text = text.decode("utf-8") + except UnicodeDecodeError: + return False + + key = ssh_key_string_to_obj(text, password=password) + if key is None: + return False + else: + return True + + +def validate_ssh_public_key(text): + ssh = sshpubkeys.SSHKey(text) + try: + ssh.parse() + except (sshpubkeys.InvalidKeyException, UnicodeDecodeError): + return False + except NotImplementedError as e: + return False + return True + + +def content_md5(data): + """计算data的MD5值,经过Base64编码并返回str类型。 + + 返回值可以直接作为HTTP Content-Type头部的值 + """ + if isinstance(data, str): + data = hashlib.md5(data.encode('utf-8')) + value = base64.b64encode(data.hexdigest().encode('utf-8')) + return value.decode('utf-8') + + +def make_signature(access_key_secret, date=None): + if isinstance(date, bytes): + date = bytes.decode(date) + if isinstance(date, int): + date_gmt = http_date(date) + elif date is None: + date_gmt = http_date(int(time.time())) + else: + date_gmt = date + + data = str(access_key_secret) + "\n" + date_gmt + return content_md5(data) + + +def encrypt_password(password, salt=None): + from passlib.hash import sha512_crypt + if password: + return sha512_crypt.using(rounds=5000).hash(password, salt=salt) + return None + + +def get_signer(): + signer = Signer(settings.SECRET_KEY) + return signer diff --git a/apps/common/utils/http.py b/apps/common/utils/http.py new file mode 100644 index 000000000..185397881 --- /dev/null +++ b/apps/common/utils/http.py @@ -0,0 +1,37 @@ +# -*- coding: utf-8 -*- +# +import time +from email.utils import formatdate +import calendar +import threading + +_STRPTIME_LOCK = threading.Lock() + +_GMT_FORMAT = "%a, %d %b %Y %H:%M:%S GMT" +_ISO8601_FORMAT = "%Y-%m-%dT%H:%M:%S.000Z" + + +def to_unixtime(time_string, format_string): + time_string = time_string.decode("ascii") + with _STRPTIME_LOCK: + return int(calendar.timegm(time.strptime(time_string, format_string))) + + +def http_date(timeval=None): + """返回符合HTTP标准的GMT时间字符串,用strftime的格式表示就是"%a, %d %b %Y %H:%M:%S GMT"。 + 但不能使用strftime,因为strftime的结果是和locale相关的。 + """ + return formatdate(timeval, usegmt=True) + + +def http_to_unixtime(time_string): + """把HTTP Date格式的字符串转换为UNIX时间(自1970年1月1日UTC零点的秒数)。 + + HTTP Date形如 `Sat, 05 Dec 2015 11:10:29 GMT` 。 + """ + return to_unixtime(time_string, _GMT_FORMAT) + + +def iso8601_to_unixtime(time_string): + """把ISO8601时间字符串(形如,2012-02-24T06:07:48.000Z)转换为UNIX时间,精确到秒。""" + return to_unixtime(time_string, _ISO8601_FORMAT) diff --git a/apps/common/utils/ipip/__init__.py b/apps/common/utils/ipip/__init__.py new file mode 100644 index 000000000..864ac8d44 --- /dev/null +++ b/apps/common/utils/ipip/__init__.py @@ -0,0 +1,3 @@ +# -*- coding: utf-8 -*- +# +from .ipdb import * diff --git a/apps/common/utils/ipip/ipdb.py b/apps/common/utils/ipip/ipdb.py new file mode 100644 index 000000000..e17fb523c --- /dev/null +++ b/apps/common/utils/ipip/ipdb.py @@ -0,0 +1,18 @@ +# -*- coding: utf-8 -*- +# +import os + +import ipdb + +ipip_db = None + + +def get_ip_city(ip): + global ipip_db + if ipip_db is None: + ipip_db_path = os.path.join(os.path.dirname(__file__), 'ipipfree.ipdb') + ipip_db = ipdb.City(ipip_db_path) + info = list(set(ipip_db.find(ip, 'CN'))) + if '' in info: + info.remove('') + return ' '.join(info) \ No newline at end of file diff --git a/apps/common/utils/ipip/ipipfree.ipdb b/apps/common/utils/ipip/ipipfree.ipdb new file mode 100755 index 000000000..911e1ac33 Binary files /dev/null and b/apps/common/utils/ipip/ipipfree.ipdb differ diff --git a/apps/fixtures/fake.json b/apps/fixtures/fake.json deleted file mode 100644 index 421feccfa..000000000 --- a/apps/fixtures/fake.json +++ /dev/null @@ -1 +0,0 @@ -[{"model": "users.usergroup", "pk": "01633e9e-aaf9-434a-bc3d-33f75efb045d", "fields": {"is_discard": false, "discard_time": null, "name": "Barbara Shaw", "comment": "Sed ante.", "date_created": "2017-12-07T08:20:51.486Z", "created_by": "deborah79"}}, {"model": "users.usergroup", "pk": "05480995-a607-43f4-9aae-6373e5144196", "fields": {"is_discard": false, "discard_time": null, "name": "Irene Dunn", "comment": "In tempor, turpis nec euismod scelerisque, quam turpis adipiscing lorem, vitae mattis nibh ligula nec sem.", "date_created": "2017-12-07T08:20:51.823Z", "created_by": "maria71"}}, {"model": "users.usergroup", "pk": "0aaefcf4-a3be-4b0c-8347-e537c939b1d6", "fields": {"is_discard": false, "discard_time": null, "name": "Jean Gilbert", "comment": "Maecenas tincidunt lacus at velit.", "date_created": "2017-12-07T08:20:52.464Z", "created_by": "amanda67"}}, {"model": "users.usergroup", "pk": "0c9f3bb1-6b99-4fb0-931a-6a973d043039", "fields": {"is_discard": false, "discard_time": null, "name": "Mildred Bishop", "comment": "Donec diam neque, vestibulum eget, vulputate ut, ultrices vel, augue.", "date_created": "2017-12-07T08:20:52.443Z", "created_by": "catherine91"}}, {"model": "users.usergroup", "pk": "0cfa92a2-b265-4117-a90f-d6e36cc742df", "fields": {"is_discard": false, "discard_time": null, "name": "Sarah Hill", "comment": "Cras mi pede, malesuada in, imperdiet et, commodo vulputate, justo.", "date_created": "2017-12-07T08:20:51.520Z", "created_by": "cynthia75"}}, {"model": "users.usergroup", "pk": "0ff9b33d-6db3-411b-bc8a-201cee0492d5", "fields": {"is_discard": false, "discard_time": null, "name": "Patricia Cook", "comment": "Pellentesque eget nunc.", "date_created": "2017-12-07T08:20:51.693Z", "created_by": "sharon84"}}, {"model": "users.usergroup", "pk": "10a4c70a-8202-4cc6-b1ed-81c93961325d", "fields": {"is_discard": false, "discard_time": null, "name": "Joyce Wagner", "comment": "Vivamus tortor.", "date_created": "2017-12-07T08:20:52.242Z", "created_by": "mary85"}}, {"model": "users.usergroup", "pk": "10e9791a-7af7-4a80-a392-4261c2f19a59", "fields": {"is_discard": false, "discard_time": null, "name": "Kathryn Sims", "comment": "Praesent id massa id nisl venenatis lacinia.", "date_created": "2017-12-07T08:20:52.422Z", "created_by": "jennifer76"}}, {"model": "users.usergroup", "pk": "18a646d6-b82d-4f0b-80a3-d61fe702ef7b", "fields": {"is_discard": false, "discard_time": null, "name": "Heather Hernandez", "comment": "Fusce congue, diam id ornare imperdiet, sapien urna pretium nisl, ut volutpat sapien arcu sed augue.", "date_created": "2017-12-07T08:20:51.464Z", "created_by": "doris73"}}, {"model": "users.usergroup", "pk": "1a51e2a6-cfd1-44fe-b774-3ef3de1c81dc", "fields": {"is_discard": false, "discard_time": null, "name": "Jessica Pierce", "comment": "Etiam justo.", "date_created": "2017-12-07T08:20:51.748Z", "created_by": "bonnie74"}}, {"model": "users.usergroup", "pk": "1af7873a-8614-484b-8a40-c2cab92a0125", "fields": {"is_discard": false, "discard_time": null, "name": "Nancy Griffin", "comment": "Etiam justo.", "date_created": "2017-12-07T08:20:51.617Z", "created_by": "stephanie64"}}, {"model": "users.usergroup", "pk": "1bbfbb77-2f3e-4ed9-abbb-948556a7b250", "fields": {"is_discard": false, "discard_time": null, "name": "Ruby Frazier", "comment": "Sed accumsan felis.", "date_created": "2017-12-07T08:20:52.221Z", "created_by": "diane63"}}, {"model": "users.usergroup", "pk": "1cdf25f1-24f3-4438-ad07-0b01fff85d6a", "fields": {"is_discard": false, "discard_time": null, "name": "Lisa Robertson", "comment": "Vestibulum sed magna at nunc commodo placerat.", "date_created": "2017-12-07T08:20:52.370Z", "created_by": "wanda76"}}, {"model": "users.usergroup", "pk": "1ebb17e6-9224-469e-960c-e79ea05e1843", "fields": {"is_discard": false, "discard_time": null, "name": "Jessica Olson", "comment": "Sed accumsan felis.", "date_created": "2017-12-07T08:20:52.028Z", "created_by": "kathryn81"}}, {"model": "users.usergroup", "pk": "1f69d022-44cd-4d05-8280-1f867f843812", "fields": {"is_discard": false, "discard_time": null, "name": "Ruby Hanson", "comment": "Donec quis orci eget orci vehicula condimentum.", "date_created": "2017-12-07T08:20:51.585Z", "created_by": "anna68"}}, {"model": "users.usergroup", "pk": "20854f59-6e0f-4c32-a9e5-6027fa0a4286", "fields": {"is_discard": false, "discard_time": null, "name": "Andrea Fuller", "comment": "Vivamus metus arcu, adipiscing molestie, hendrerit at, vulputate vitae, nisl.", "date_created": "2017-12-07T08:20:52.285Z", "created_by": "angela93"}}, {"model": "users.usergroup", "pk": "20f701d5-44cf-4fc2-97cc-ed58a6879f46", "fields": {"is_discard": false, "discard_time": null, "name": "Julie Sullivan", "comment": "Duis bibendum, felis sed interdum venenatis, turpis enim blandit mi, in porttitor pede justo eu massa.", "date_created": "2017-12-07T08:20:52.050Z", "created_by": "margaret68"}}, {"model": "users.usergroup", "pk": "22aabd20-ef34-4449-9b7d-ff98e09908d2", "fields": {"is_discard": false, "discard_time": null, "name": "Amy Reyes", "comment": "Aenean lectus.", "date_created": "2017-12-07T08:20:51.553Z", "created_by": "brenda80"}}, {"model": "users.usergroup", "pk": "256b4fb1-b364-42b0-986a-c36ce05c9910", "fields": {"is_discard": false, "discard_time": null, "name": "Ashley Watson", "comment": "Etiam justo.", "date_created": "2017-12-07T08:20:52.072Z", "created_by": "robin65"}}, {"model": "users.usergroup", "pk": "2ab45c5e-8b7c-4b15-a23b-f0674dea4811", "fields": {"is_discard": false, "discard_time": null, "name": "Sara Reid", "comment": "Mauris enim leo, rhoncus sed, vestibulum sit amet, cursus id, turpis.", "date_created": "2017-12-07T08:20:51.931Z", "created_by": "jean73"}}, {"model": "users.usergroup", "pk": "2ac447b3-fe58-4070-ac04-2229ee3f67d1", "fields": {"is_discard": false, "discard_time": null, "name": "Joyce Hill", "comment": "Vivamus vestibulum sagittis sapien.", "date_created": "2017-12-07T08:20:52.485Z", "created_by": "kathleen72"}}, {"model": "users.usergroup", "pk": "2acdcb21-17da-4848-91d2-43d0f3c7a675", "fields": {"is_discard": false, "discard_time": null, "name": "Mary Nelson", "comment": "Donec semper sapien a libero.", "date_created": "2017-12-07T08:20:51.844Z", "created_by": "wanda76"}}, {"model": "users.usergroup", "pk": "2b6d1ada-eeff-4708-a5a2-c0cf700c7903", "fields": {"is_discard": false, "discard_time": null, "name": "Beverly Watson", "comment": "In hac habitasse platea dictumst.", "date_created": "2017-12-07T08:20:52.339Z", "created_by": "mildred72"}}, {"model": "users.usergroup", "pk": "2e0b2a25-b32f-44a0-b087-f0f17de66e26", "fields": {"is_discard": false, "discard_time": null, "name": "Default", "comment": "Default user group", "date_created": "2017-12-07T08:20:09.593Z", "created_by": "System"}}, {"model": "users.usergroup", "pk": "30425714-f98a-4c72-aee4-cd2ec6386a83", "fields": {"is_discard": false, "discard_time": null, "name": "Carol Nguyen", "comment": "Sed sagittis.", "date_created": "2017-12-07T08:20:51.865Z", "created_by": "stephanie64"}}, {"model": "users.usergroup", "pk": "3130014e-a92c-4942-9c5f-4f0d7d456bea", "fields": {"is_discard": false, "discard_time": null, "name": "Nicole Henry", "comment": "Vestibulum ac est lacinia nisi venenatis tristique.", "date_created": "2017-12-07T08:20:51.790Z", "created_by": "kathleen72"}}, {"model": "users.usergroup", "pk": "324a10dd-2f10-4c04-b616-80f669b213ef", "fields": {"is_discard": false, "discard_time": null, "name": "Rachel Watson", "comment": "Lorem ipsum dolor sit amet, consectetuer adipiscing elit.", "date_created": "2017-12-07T08:20:52.006Z", "created_by": "kelly79"}}, {"model": "users.usergroup", "pk": "32c811fe-c525-4ee0-ab06-4f1caffc0df4", "fields": {"is_discard": false, "discard_time": null, "name": "Joyce Rodriguez", "comment": "Mauris ullamcorper purus sit amet nulla.", "date_created": "2017-12-07T08:20:52.412Z", "created_by": "lisa84"}}, {"model": "users.usergroup", "pk": "348bc076-34b7-4b48-8b13-6920b4536e0b", "fields": {"is_discard": false, "discard_time": null, "name": "Jessica Sanders", "comment": "Aenean lectus.", "date_created": "2017-12-07T08:20:52.211Z", "created_by": "phyllis92"}}, {"model": "users.usergroup", "pk": "35fbe872-3fa9-4d2a-aeae-92e2b919408d", "fields": {"is_discard": false, "discard_time": null, "name": "Sandra Cruz", "comment": "Phasellus sit amet erat.", "date_created": "2017-12-07T08:20:52.104Z", "created_by": "frances91"}}, {"model": "users.usergroup", "pk": "36e8af59-a0e4-43ac-b75b-a553316db215", "fields": {"is_discard": false, "discard_time": null, "name": "Kathryn Cook", "comment": "Cras in purus eu magna vulputate luctus.", "date_created": "2017-12-07T08:20:51.780Z", "created_by": "lisa75"}}, {"model": "users.usergroup", "pk": "39b4c13c-7b1c-46ec-b5f0-eddc5c9dc0d1", "fields": {"is_discard": false, "discard_time": null, "name": "Kathy Watkins", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla dapibus dolor vel est.", "date_created": "2017-12-07T08:20:51.596Z", "created_by": "katherine74"}}, {"model": "users.usergroup", "pk": "42e81e2b-5e41-492d-ba1c-2c776f6825b9", "fields": {"is_discard": false, "discard_time": null, "name": "Angela Franklin", "comment": "Duis aliquam convallis nunc.", "date_created": "2017-12-07T08:20:52.349Z", "created_by": "amanda67"}}, {"model": "users.usergroup", "pk": "439508f0-ef68-47b7-8b1f-0fa8519d55d2", "fields": {"is_discard": false, "discard_time": null, "name": "Marilyn Crawford", "comment": "Phasellus sit amet erat.", "date_created": "2017-12-07T08:20:51.736Z", "created_by": "phyllis92"}}, {"model": "users.usergroup", "pk": "44dcd0b3-13c5-4ffc-81c2-226feb264f4f", "fields": {"is_discard": false, "discard_time": null, "name": "Betty Torres", "comment": "Mauris enim leo, rhoncus sed, vestibulum sit amet, cursus id, turpis.", "date_created": "2017-12-07T08:20:52.296Z", "created_by": "margaret94"}}, {"model": "users.usergroup", "pk": "47e25432-402f-423d-b089-dc1a4c69f0f1", "fields": {"is_discard": false, "discard_time": null, "name": "Angela Brooks", "comment": "Etiam vel augue.", "date_created": "2017-12-07T08:20:51.498Z", "created_by": "lisa90"}}, {"model": "users.usergroup", "pk": "50b6d093-3208-45d1-aaae-ed1d3c23a7b6", "fields": {"is_discard": false, "discard_time": null, "name": "Elizabeth Wagner", "comment": "Donec ut dolor.", "date_created": "2017-12-07T08:20:51.996Z", "created_by": "joan86"}}, {"model": "users.usergroup", "pk": "562e85d0-cfba-43b2-ad51-1e11e78a2e67", "fields": {"is_discard": false, "discard_time": null, "name": "Andrea Cox", "comment": "Donec ut mauris eget massa tempor convallis.", "date_created": "2017-12-07T08:20:52.381Z", "created_by": "wanda88"}}, {"model": "users.usergroup", "pk": "575c7e54-02d4-4196-8566-6f1ea8f36f8b", "fields": {"is_discard": false, "discard_time": null, "name": "Tina Olson", "comment": "In tempor, turpis nec euismod scelerisque, quam turpis adipiscing lorem, vitae mattis nibh ligula nec sem.", "date_created": "2017-12-07T08:20:52.264Z", "created_by": "kelly79"}}, {"model": "users.usergroup", "pk": "5931fc80-cb0c-4b8a-8fb1-c8ddfd3d5fd0", "fields": {"is_discard": false, "discard_time": null, "name": "Ashley Rivera", "comment": "Suspendisse ornare consequat lectus.", "date_created": "2017-12-07T08:20:52.518Z", "created_by": "brenda85"}}, {"model": "users.usergroup", "pk": "5b7d215d-6cd3-4eb6-9ba0-2056758c457e", "fields": {"is_discard": false, "discard_time": null, "name": "Christine George", "comment": "Fusce consequat.", "date_created": "2017-12-07T08:20:52.402Z", "created_by": "wanda88"}}, {"model": "users.usergroup", "pk": "5c97733d-13ef-4336-ad29-29ae8e3af1f7", "fields": {"is_discard": false, "discard_time": null, "name": "Beverly Howell", "comment": "Integer pede justo, lacinia eget, tincidunt eget, tempus vel, pede.", "date_created": "2017-12-07T08:20:52.178Z", "created_by": "anna85"}}, {"model": "users.usergroup", "pk": "5ccbede6-9538-40f4-a2af-b255ea441291", "fields": {"is_discard": false, "discard_time": null, "name": "Nancy Moore", "comment": "Morbi quis tortor id nulla ultrices aliquet.", "date_created": "2017-12-07T08:20:51.704Z", "created_by": "diane63"}}, {"model": "users.usergroup", "pk": "61b1878f-970d-4540-a606-a1e606c07f32", "fields": {"is_discard": false, "discard_time": null, "name": "Janice Harvey", "comment": "Sed sagittis.", "date_created": "2017-12-07T08:20:52.232Z", "created_by": "doris86"}}, {"model": "users.usergroup", "pk": "62ec8b72-aa17-4a86-89b5-cf904ad16f4b", "fields": {"is_discard": false, "discard_time": null, "name": "Alice Mccoy", "comment": "Integer ac neque.", "date_created": "2017-12-07T08:20:52.507Z", "created_by": "wanda76"}}, {"model": "users.usergroup", "pk": "6699de3c-c1f6-4c60-bf21-26e4eebdabad", "fields": {"is_discard": false, "discard_time": null, "name": "Kathleen Thompson", "comment": "Aenean fermentum.", "date_created": "2017-12-07T08:20:51.954Z", "created_by": "robin65"}}, {"model": "users.usergroup", "pk": "6bd04a04-f94d-4723-a187-3d9eb5e87b25", "fields": {"is_discard": false, "discard_time": null, "name": "Frances Graham", "comment": "Duis ac nibh.", "date_created": "2017-12-07T08:20:51.475Z", "created_by": "catherine91"}}, {"model": "users.usergroup", "pk": "6c5566e7-f9ed-4722-8e5c-ae9c71eeeefd", "fields": {"is_discard": false, "discard_time": null, "name": "Pamela Reyes", "comment": "Praesent id massa id nisl venenatis lacinia.", "date_created": "2017-12-07T08:20:52.125Z", "created_by": "diane63"}}, {"model": "users.usergroup", "pk": "73daab8c-d57e-4cf8-8625-3191f179c5f2", "fields": {"is_discard": false, "discard_time": null, "name": "Janice Chavez", "comment": "Donec dapibus.", "date_created": "2017-12-07T08:20:52.083Z", "created_by": "rachel76"}}, {"model": "users.usergroup", "pk": "7acf822f-682a-4242-af4c-1dab52961bef", "fields": {"is_discard": false, "discard_time": null, "name": "Phyllis Carr", "comment": "Nulla justo.", "date_created": "2017-12-07T08:20:51.574Z", "created_by": "deborah79"}}, {"model": "users.usergroup", "pk": "82a41770-d7e3-43dd-8722-3fe712d96b8c", "fields": {"is_discard": false, "discard_time": null, "name": "Paula Gutierrez", "comment": "Nulla tellus.", "date_created": "2017-12-07T08:20:51.833Z", "created_by": "jennifer76"}}, {"model": "users.usergroup", "pk": "8328f6c7-80b5-466c-bf37-b347ec2483ad", "fields": {"is_discard": false, "discard_time": null, "name": "Kelly Dean", "comment": "Etiam justo.", "date_created": "2017-12-07T08:20:52.147Z", "created_by": "margaret68"}}, {"model": "users.usergroup", "pk": "84840e74-dccc-4663-829a-82496687b29b", "fields": {"is_discard": false, "discard_time": null, "name": "Kathryn Bell", "comment": "Curabitur in libero ut massa volutpat convallis.", "date_created": "2017-12-07T08:20:51.606Z", "created_by": "maria72"}}, {"model": "users.usergroup", "pk": "8997d40e-46aa-4c27-b4db-5e1bb4460d45", "fields": {"is_discard": false, "discard_time": null, "name": "Pamela Cunningham", "comment": "Cras non velit nec nisi vulputate nonummy.", "date_created": "2017-12-07T08:20:52.475Z", "created_by": "joan88"}}, {"model": "users.usergroup", "pk": "91cf56b4-1e16-4bd6-9f04-435d7799ced7", "fields": {"is_discard": false, "discard_time": null, "name": "Maria Fisher", "comment": "Aliquam quis turpis eget elit sodales scelerisque.", "date_created": "2017-12-07T08:20:52.189Z", "created_by": "diane63"}}, {"model": "users.usergroup", "pk": "93bbe048-b49d-4ff2-bae5-88bd759b37c4", "fields": {"is_discard": false, "discard_time": null, "name": "Catherine Morris", "comment": "Nullam orci pede, venenatis non, sodales sed, tincidunt eu, felis.", "date_created": "2017-12-07T08:20:51.975Z", "created_by": "sarah87"}}, {"model": "users.usergroup", "pk": "94459801-cf94-4acd-8536-4853afc7f506", "fields": {"is_discard": false, "discard_time": null, "name": "Helen Mason", "comment": "Donec diam neque, vestibulum eget, vulputate ut, ultrices vel, augue.", "date_created": "2017-12-07T08:20:52.039Z", "created_by": "christine83"}}, {"model": "users.usergroup", "pk": "9509a7e1-71fc-48a9-b16a-84bb1559cd22", "fields": {"is_discard": false, "discard_time": null, "name": "Bonnie Arnold", "comment": "Duis bibendum.", "date_created": "2017-12-07T08:20:51.650Z", "created_by": "rachel76"}}, {"model": "users.usergroup", "pk": "974627ea-562c-421e-965c-7629b7ae32b4", "fields": {"is_discard": false, "discard_time": null, "name": "Wanda Parker", "comment": "Quisque arcu libero, rutrum ac, lobortis vel, dapibus at, diam.", "date_created": "2017-12-07T08:20:51.875Z", "created_by": "diane88"}}, {"model": "users.usergroup", "pk": "9c1c4a2f-e1e1-436d-b175-a4dbaff84f2c", "fields": {"is_discard": false, "discard_time": null, "name": "Phyllis Garcia", "comment": "Praesent id massa id nisl venenatis lacinia.", "date_created": "2017-12-07T08:20:51.639Z", "created_by": "jane91"}}, {"model": "users.usergroup", "pk": "a0d4b642-4250-40e9-af49-5d6b96aebf0b", "fields": {"is_discard": false, "discard_time": null, "name": "Amanda Armstrong", "comment": "Morbi odio odio, elementum eu, interdum eu, tincidunt in, leo.", "date_created": "2017-12-07T08:20:51.985Z", "created_by": "alice65"}}, {"model": "users.usergroup", "pk": "a1211050-9d15-4c83-9039-623b8e73cd7e", "fields": {"is_discard": false, "discard_time": null, "name": "Sharon Carter", "comment": "Fusce congue, diam id ornare imperdiet, sapien urna pretium nisl, ut volutpat sapien arcu sed augue.", "date_created": "2017-12-07T08:20:51.564Z", "created_by": "deborah92"}}, {"model": "users.usergroup", "pk": "a4ba911f-1a48-406a-b073-18325675d410", "fields": {"is_discard": false, "discard_time": null, "name": "Jessica Palmer", "comment": "Lorem ipsum dolor sit amet, consectetuer adipiscing elit.", "date_created": "2017-12-07T08:20:51.672Z", "created_by": "sandra90"}}, {"model": "users.usergroup", "pk": "a9c18eb2-487f-430b-8a21-9fda58f8e010", "fields": {"is_discard": false, "discard_time": null, "name": "Cynthia Phillips", "comment": "Curabitur convallis.", "date_created": "2017-12-07T08:20:51.531Z", "created_by": "doris76"}}, {"model": "users.usergroup", "pk": "aa396508-4225-46db-8987-01e797703b8c", "fields": {"is_discard": false, "discard_time": null, "name": "Gloria Elliott", "comment": "Pellentesque ultrices mattis odio.", "date_created": "2017-12-07T08:20:51.812Z", "created_by": "doris86"}}, {"model": "users.usergroup", "pk": "aba21946-88f9-4118-9618-102e4cc80c79", "fields": {"is_discard": false, "discard_time": null, "name": "Kimberly Fox", "comment": "Integer non velit.", "date_created": "2017-12-07T08:20:52.136Z", "created_by": "brenda80"}}, {"model": "users.usergroup", "pk": "b29c503b-8880-49a0-a411-7fffe18d66f7", "fields": {"is_discard": false, "discard_time": null, "name": "Julia Dixon", "comment": "Cras in purus eu magna vulputate luctus.", "date_created": "2017-12-07T08:20:51.682Z", "created_by": "brenda80"}}, {"model": "users.usergroup", "pk": "b2c06c2d-e84c-40fe-bcb5-de5c472bd7ae", "fields": {"is_discard": false, "discard_time": null, "name": "Shirley Johnson", "comment": "Donec odio justo, sollicitudin ut, suscipit a, feugiat et, eros.", "date_created": "2017-12-07T08:20:52.061Z", "created_by": "linda78"}}, {"model": "users.usergroup", "pk": "b3dae698-cbfd-447e-b464-969e9cb7cc98", "fields": {"is_discard": false, "discard_time": null, "name": "Lori Cooper", "comment": "Nulla neque libero, convallis eget, eleifend luctus, ultricies eu, nibh.", "date_created": "2017-12-07T08:20:51.886Z", "created_by": "christine83"}}, {"model": "users.usergroup", "pk": "b45b237e-ce9c-4fa3-8cd3-a86ab0269c79", "fields": {"is_discard": false, "discard_time": null, "name": "Jean Harris", "comment": "Vestibulum sed magna at nunc commodo placerat.", "date_created": "2017-12-07T08:20:51.759Z", "created_by": "frances91"}}, {"model": "users.usergroup", "pk": "b7316da9-aed5-4329-bd3c-bc2ff34a1ec4", "fields": {"is_discard": false, "discard_time": null, "name": "Debra Cooper", "comment": "Vivamus vel nulla eget eros elementum pellentesque.", "date_created": "2017-12-07T08:20:51.661Z", "created_by": "ruth84"}}, {"model": "users.usergroup", "pk": "bbbc2f67-193c-4e4a-8355-f4f3d585ff26", "fields": {"is_discard": false, "discard_time": null, "name": "Christina Jackson", "comment": "Integer aliquet, massa id lobortis convallis, tortor risus dapibus augue, vel accumsan tellus nisi eu orci.", "date_created": "2017-12-07T08:20:51.896Z", "created_by": "maria72"}}, {"model": "users.usergroup", "pk": "bc85d48a-5e80-471c-b348-a1123421d96d", "fields": {"is_discard": false, "discard_time": null, "name": "Irene Gilbert", "comment": "In hac habitasse platea dictumst.", "date_created": "2017-12-07T08:20:51.724Z", "created_by": "cheryl72"}}, {"model": "users.usergroup", "pk": "be9b966c-81a2-4ca1-baa8-31c798ad36f1", "fields": {"is_discard": false, "discard_time": null, "name": "Ruby Rodriguez", "comment": "Cras in purus eu magna vulputate luctus.", "date_created": "2017-12-07T08:20:52.391Z", "created_by": "anna68"}}, {"model": "users.usergroup", "pk": "c724a40b-5aae-4fec-84bd-4cb533e08347", "fields": {"is_discard": false, "discard_time": null, "name": "Andrea Morris", "comment": "Maecenas pulvinar lobortis est.", "date_created": "2017-12-07T08:20:51.920Z", "created_by": "nancy94"}}, {"model": "users.usergroup", "pk": "c770b1ef-455a-4351-918f-ebb30488c967", "fields": {"is_discard": false, "discard_time": null, "name": "Mary Hunt", "comment": "Integer tincidunt ante vel ipsum.", "date_created": "2017-12-07T08:20:51.801Z", "created_by": "deborah92"}}, {"model": "users.usergroup", "pk": "c8cfd3c6-fc6f-4191-9a06-a756a79ad7c2", "fields": {"is_discard": false, "discard_time": null, "name": "Linda Ortiz", "comment": "In sagittis dui vel nisl.", "date_created": "2017-12-07T08:20:51.855Z", "created_by": "tammy68"}}, {"model": "users.usergroup", "pk": "cb64989f-138c-40f8-b55a-958e3faf982b", "fields": {"is_discard": false, "discard_time": null, "name": "Emily Arnold", "comment": "Vivamus vestibulum sagittis sapien.", "date_created": "2017-12-07T08:20:52.168Z", "created_by": "catherine89"}}, {"model": "users.usergroup", "pk": "cc857995-38c6-409b-813c-c3ffc753f38b", "fields": {"is_discard": false, "discard_time": null, "name": "Louise Collins", "comment": "Nam dui.", "date_created": "2017-12-07T08:20:52.327Z", "created_by": "margaret94"}}, {"model": "users.usergroup", "pk": "d0f501b7-59df-447a-9677-e312b1e307d7", "fields": {"is_discard": false, "discard_time": null, "name": "Judy Wallace", "comment": "Vivamus tortor.", "date_created": "2017-12-07T08:20:51.910Z", "created_by": "sarah87"}}, {"model": "users.usergroup", "pk": "d6dcd1e8-3de8-4a9f-ae77-99c2db8fb740", "fields": {"is_discard": false, "discard_time": null, "name": "Jennifer Lane", "comment": "Pellentesque viverra pede ac diam.", "date_created": "2017-12-07T08:20:52.253Z", "created_by": "sharon84"}}, {"model": "users.usergroup", "pk": "d9441645-2adc-4a2c-8ac9-88c4acd27f1c", "fields": {"is_discard": false, "discard_time": null, "name": "Tina Moore", "comment": "Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.", "date_created": "2017-12-07T08:20:52.316Z", "created_by": "catherine91"}}, {"model": "users.usergroup", "pk": "d9fb5700-8b80-4977-880b-01aa12ce9d0a", "fields": {"is_discard": false, "discard_time": null, "name": "Julia Hudson", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla dapibus dolor vel est.", "date_created": "2017-12-07T08:20:52.093Z", "created_by": "margaret68"}}, {"model": "users.usergroup", "pk": "da7d3fc2-c0a8-4063-b6ea-5cdff12cfa21", "fields": {"is_discard": false, "discard_time": null, "name": "Deborah Mason", "comment": "Maecenas rhoncus aliquam lacus.", "date_created": "2017-12-07T08:20:52.275Z", "created_by": "angela93"}}, {"model": "users.usergroup", "pk": "e01c4f7b-99b4-4acc-a17f-bcfa65aa6713", "fields": {"is_discard": false, "discard_time": null, "name": "Carolyn Morgan", "comment": "Praesent lectus.", "date_created": "2017-12-07T08:20:52.433Z", "created_by": "kimberly82"}}, {"model": "users.usergroup", "pk": "e52a38be-1b6e-4aa0-af94-81df5bbbf128", "fields": {"is_discard": false, "discard_time": null, "name": "Tammy Martinez", "comment": "Cras mi pede, malesuada in, imperdiet et, commodo vulputate, justo.", "date_created": "2017-12-07T08:20:52.453Z", "created_by": "bobby67"}}, {"model": "users.usergroup", "pk": "e8b48349-c0fb-46dd-a381-060da38b7d03", "fields": {"is_discard": false, "discard_time": null, "name": "Martha Garcia", "comment": "Duis mattis egestas metus.", "date_created": "2017-12-07T08:20:51.509Z", "created_by": "anna85"}}, {"model": "users.usergroup", "pk": "e8c27151-8bbd-4860-b63b-c1268734004e", "fields": {"is_discard": false, "discard_time": null, "name": "Phyllis Ramos", "comment": "Maecenas pulvinar lobortis est.", "date_created": "2017-12-07T08:20:52.157Z", "created_by": "brenda85"}}, {"model": "users.usergroup", "pk": "e8d74351-5019-409d-aa0f-be2eed38eb50", "fields": {"is_discard": false, "discard_time": null, "name": "Amanda Snyder", "comment": "Suspendisse ornare consequat lectus.", "date_created": "2017-12-07T08:20:51.628Z", "created_by": "maria71"}}, {"model": "users.usergroup", "pk": "edf7e651-2192-4d81-83d1-3ba18c114524", "fields": {"is_discard": false, "discard_time": null, "name": "Donna Riley", "comment": "Nam ultrices, libero non mattis pulvinar, nulla pede ullamcorper augue, a suscipit nulla elit ac nulla.", "date_created": "2017-12-07T08:20:52.017Z", "created_by": "emily88"}}, {"model": "users.usergroup", "pk": "f02bde64-1585-407d-b2b4-03b1e3646181", "fields": {"is_discard": false, "discard_time": null, "name": "Wanda Williamson", "comment": "Aliquam sit amet diam in magna bibendum imperdiet.", "date_created": "2017-12-07T08:20:52.114Z", "created_by": "jane91"}}, {"model": "users.usergroup", "pk": "f2e7b16f-c9df-44d7-bafc-2264d4c56ea2", "fields": {"is_discard": false, "discard_time": null, "name": "Jane Bishop", "comment": "Morbi a ipsum.", "date_created": "2017-12-07T08:20:52.360Z", "created_by": "angela93"}}, {"model": "users.usergroup", "pk": "f471eacf-29bf-48f2-a8f7-190180592024", "fields": {"is_discard": false, "discard_time": null, "name": "Gloria Oliver", "comment": "Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.", "date_created": "2017-12-07T08:20:51.964Z", "created_by": "kathleen72"}}, {"model": "users.usergroup", "pk": "f4e73db5-0f56-443a-bc04-75c97606a32d", "fields": {"is_discard": false, "discard_time": null, "name": "Judy Stewart", "comment": "Duis at velit eu est congue elementum.", "date_created": "2017-12-07T08:20:51.942Z", "created_by": "katherine74"}}, {"model": "users.usergroup", "pk": "f61bf503-4071-4105-8865-03c298b8493b", "fields": {"is_discard": false, "discard_time": null, "name": "Maria Owens", "comment": "Nulla neque libero, convallis eget, eleifend luctus, ultricies eu, nibh.", "date_created": "2017-12-07T08:20:52.497Z", "created_by": "jane91"}}, {"model": "users.usergroup", "pk": "f70a94bd-ccfc-47a8-9ffc-c82354c1eab3", "fields": {"is_discard": false, "discard_time": null, "name": "Mary Hawkins", "comment": "Quisque arcu libero, rutrum ac, lobortis vel, dapibus at, diam.", "date_created": "2017-12-07T08:20:52.529Z", "created_by": "amy74"}}, {"model": "users.usergroup", "pk": "f97785ce-0128-40e8-9d1a-59a6da0f26c6", "fields": {"is_discard": false, "discard_time": null, "name": "Lillian Rose", "comment": "Morbi vestibulum, velit id pretium iaculis, diam erat fermentum justo, nec condimentum neque sapien placerat ante.", "date_created": "2017-12-07T08:20:51.714Z", "created_by": "nancy94"}}, {"model": "users.usergroup", "pk": "fb79c29a-7082-4a61-b7f9-664936689962", "fields": {"is_discard": false, "discard_time": null, "name": "Lori Moreno", "comment": "Suspendisse potenti.", "date_created": "2017-12-07T08:20:51.769Z", "created_by": "jane91"}}, {"model": "users.usergroup", "pk": "fb996880-5d5b-45f0-a350-48c909540bbe", "fields": {"is_discard": false, "discard_time": null, "name": "Elizabeth Nelson", "comment": "Maecenas rhoncus aliquam lacus.", "date_created": "2017-12-07T08:20:52.200Z", "created_by": "amanda67"}}, {"model": "users.usergroup", "pk": "fdc3f016-e595-4167-ba89-dfcdfd47729c", "fields": {"is_discard": false, "discard_time": null, "name": "Frances Cook", "comment": "Suspendisse potenti.", "date_created": "2017-12-07T08:20:51.542Z", "created_by": "ruth71"}}, {"model": "users.usergroup", "pk": "ffe5fe09-16d1-40ea-b27a-c5c69e85ae4f", "fields": {"is_discard": false, "discard_time": null, "name": "Marilyn Hall", "comment": "Fusce consequat.", "date_created": "2017-12-07T08:20:52.306Z", "created_by": "jane91"}}, {"model": "assets.cluster", "pk": "39db8373-d161-4832-83e3-6139d10e827b", "fields": {"name": "Debra Kim", "bandwidth": "200M", "contact": "Carol Ryan", "phone": "3-(970)673-3761", "address": "Gustine4937 Duke Way", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:52.544Z", "operator": "BGP\u5168\u7f51\u901a", "created_by": "Fake", "comment": "Aenean sit amet justo."}}, {"model": "assets.cluster", "pk": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "fields": {"name": "Ashley Henry", "bandwidth": "200M", "contact": "Susan Coleman", "phone": "2-(441)661-3806", "address": "Riverbank916 Old Shore Road", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:52.541Z", "operator": "\u5317\u4eac\u8054\u901a", "created_by": "Fake", "comment": "Aenean auctor gravida sem."}}, {"model": "assets.cluster", "pk": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "fields": {"name": "Tammy Pierce", "bandwidth": "200M", "contact": "Ruth Fernandez", "phone": "9-(356)562-2635", "address": "Oakley36 Talisman Center", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:52.547Z", "operator": "\u5317\u4eac\u8054\u901a", "created_by": "Fake", "comment": "Praesent blandit."}}, {"model": "assets.cluster", "pk": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "fields": {"name": "Theresa Jones", "bandwidth": "200M", "contact": "Lillian Jackson", "phone": "4-(213)114-4147", "address": "Red Bluff6 Amoth Way", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:52.538Z", "operator": "BGP\u5168\u7f51\u901a", "created_by": "Fake", "comment": "Donec vitae nisi."}}, {"model": "assets.cluster", "pk": "c0df1aa0-bde7-4226-a69a-d02976888456", "fields": {"name": "Default", "bandwidth": "", "contact": "", "phone": "", "address": "", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:09.606Z", "operator": "", "created_by": "System", "comment": "Default Cluster"}}, {"model": "assets.cluster", "pk": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "fields": {"name": "Karen Watkins", "bandwidth": "200M", "contact": "Sharon Flores", "phone": "6-(843)981-7826", "address": "Coachella02341 Hoffman Crossing", "intranet": "", "extranet": "", "date_created": "2017-12-07T08:20:52.550Z", "operator": "\u5317\u4eac\u7535\u4fe1", "created_by": "Fake", "comment": "Proin leo odio, porttitor id, consequat in, consequat ut, nulla."}}, {"model": "assets.adminuser", "pk": "26267cd3-4b22-41a6-ae76-327195767ee7", "fields": {"name": "Judith Gordon", "username": "mary", "_password": "eyJhbGciOiJIUzI1NiJ9.InNpdCI.qhSlAh3rB-ai6rdQ-gxKBSFGhk-AbwiFe_CqQxSS3hM", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Donec semper sapien a libero.", "date_created": "2017-12-07T08:20:52.614Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "fields": {"name": "Robin Ferguson", "username": "rebecca", "_password": "eyJhbGciOiJIUzI1NiJ9.ImFsaXF1YW0i.ROd2JUuL9lh3hBqwH2HJ7tf8zsYXtJR776EsV1Jpvnw", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Etiam justo.", "date_created": "2017-12-07T08:20:52.598Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "fields": {"name": "Jacqueline Garza", "username": "karen", "_password": "eyJhbGciOiJIUzI1NiJ9.ImlhY3VsaXMi._s5XG4x4ntDRnnbi38JeFne1fvF3h3f9nQJRUGL_vq0", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Nulla tellus.", "date_created": "2017-12-07T08:20:52.618Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "61423c66-048f-4125-9844-6a15557cd345", "fields": {"name": "Ashley West", "username": "andrea", "_password": "eyJhbGciOiJIUzI1NiJ9.InBlZGUi.VNfxhauAGiZelQ34CO0YMVbRtgnIiH5Z-vY1jjYXhWA", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Suspendisse potenti.", "date_created": "2017-12-07T08:20:52.589Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "6617bb42-6281-4095-ad30-4cefa0e2231e", "fields": {"name": "Nancy Henry", "username": "barbara", "_password": "eyJhbGciOiJIUzI1NiJ9.Imx1Y3R1cyI.HgJMJ_hzKIXE6FmvnIJpfQbY4kKS5qd1c2IJ_GxPdqQ", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Duis consequat dui nec nisi volutpat eleifend.", "date_created": "2017-12-07T08:20:52.602Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "68d875b0-162f-4360-abcf-b10bfae3f451", "fields": {"name": "Marilyn Anderson", "username": "carolyn", "_password": "eyJhbGciOiJIUzI1NiJ9.InZlc3RpYnVsdW0i.T6kOgaWPNOQhwvRxcDNwPInAoTWO8oQ6iipJWCyeZvs", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Morbi odio odio, elementum eu, interdum eu, tincidunt in, leo.", "date_created": "2017-12-07T08:20:52.592Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "fields": {"name": "Kelly Day", "username": "ashley", "_password": "eyJhbGciOiJIUzI1NiJ9.Imxhb3JlZXQi.cxHpzVDWQCDMNkadZ2bP2BKaKWpahOkM4O2_-QxO4Kg", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Ut tellus.", "date_created": "2017-12-07T08:20:52.611Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "fields": {"name": "Elizabeth Lawson", "username": "nicole", "_password": "eyJhbGciOiJIUzI1NiJ9.ImFudGUi.MEBUyQoLV79tCcbpomj9Q6JdrivWra1ZLsj5UvGmRNg", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Nulla nisl.", "date_created": "2017-12-07T08:20:52.605Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "fields": {"name": "Doris Diaz", "username": "kathy", "_password": "eyJhbGciOiJIUzI1NiJ9.ImxvcmVtIg.oO5aOD2S0EIsqSl9OTTabrNpCWrG3T8nDgA_4OqrsHE", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Nulla nisl.", "date_created": "2017-12-07T08:20:52.609Z", "created_by": "Fake"}}, {"model": "assets.adminuser", "pk": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "fields": {"name": "Kimberly Owens", "username": "denise", "_password": "eyJhbGciOiJIUzI1NiJ9.ImJsYW5kaXQi.ib6BRTHTJx8JP6SbdGdZc1_HRSsZHp9wj-FC4vN41ic", "_private_key": null, "become": true, "become_method": "sudo", "become_user": "root", "_become_pass": "", "_public_key": "", "comment": "Nullam sit amet turpis elementum ligula vehicula consequat.", "date_created": "2017-12-07T08:20:52.595Z", "created_by": "Fake"}}, {"model": "assets.systemuser", "pk": "2e83e252-b84c-4fab-b055-389d07c3acd8", "fields": {"name": "Maria Morris", "username": "phyllis", "_password": "eyJhbGciOiJIUzI1NiJ9.ImlkIg.lr9X3DQPFH2zptTUg3pRWbYLzWhfDYsw0w_q9pEod3I", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.571Z", "created_by": "Fake", "comment": "Proin leo odio, porttitor id, consequat in, consequat ut, nulla."}}, {"model": "assets.systemuser", "pk": "383481b8-6fbf-4e94-b648-0d2de1f07f77", "fields": {"name": "Michelle Nelson", "username": "diane", "_password": "eyJhbGciOiJIUzI1NiJ9.ImVzdCI.kqn80ndZDQ0Gc7AnT112KsF2joNDpppfPsuPxS6cOwk", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.574Z", "created_by": "Fake", "comment": "Aenean sit amet justo."}}, {"model": "assets.systemuser", "pk": "587dbf83-2f91-4c8b-8d75-59807dfbcefd", "fields": {"name": "Shirley Grant", "username": "carol", "_password": "eyJhbGciOiJIUzI1NiJ9.ImFlbmVhbiI.bmZGuIfjr5BAmIBuL3RLAL9zT2H1bTiHdZ9350HzSeg", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.568Z", "created_by": "Fake", "comment": "Sed accumsan felis."}}, {"model": "assets.systemuser", "pk": "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "fields": {"name": "Patricia Grant", "username": "phyllis", "_password": "eyJhbGciOiJIUzI1NiJ9.ImR1aSI.AYqnix4dp06WLJ645L4MAveLycKVrZSyNjJnIq0fU2g", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.583Z", "created_by": "Fake", "comment": "Vivamus vel nulla eget eros elementum pellentesque."}}, {"model": "assets.systemuser", "pk": "7540c5c1-6380-4928-ba1b-0eab77de20e9", "fields": {"name": "Tina Carter", "username": "martha", "_password": "eyJhbGciOiJIUzI1NiJ9.InByaW1pcyI.OAlhMPsCXTLC41MGIrALVio6iqoIwHbHFj-r4Kg4lso", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.577Z", "created_by": "Fake", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Duis faucibus accumsan odio."}}, {"model": "assets.systemuser", "pk": "9fcfed52-7476-4345-ba2f-c246e8e27522", "fields": {"name": "Ruth Armstrong", "username": "virginia", "_password": "eyJhbGciOiJIUzI1NiJ9.InV0Ig.lmRSuoHi4jv9YOiKOSfPjnCwSvHOnUh0UQcZXnEWZzo", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.561Z", "created_by": "Fake", "comment": "Maecenas tristique, est et tempus semper, est quam pharetra magna, ac consequat metus sapien ut nunc."}}, {"model": "assets.systemuser", "pk": "a08c8830-7838-4660-9072-fd038ecb02f4", "fields": {"name": "Nicole Gardner", "username": "helen", "_password": "eyJhbGciOiJIUzI1NiJ9.ImFtZXQi.k9EjNQL559Kyrp0ygulJ1FYqzM9PWKz9BZ7NqyeyH2o", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.558Z", "created_by": "Fake", "comment": "Nam ultrices, libero non mattis pulvinar, nulla pede ullamcorper augue, a suscipit nulla elit ac nulla."}}, {"model": "assets.systemuser", "pk": "a7786710-df8c-4abd-9946-f7ceceaed688", "fields": {"name": "Annie Hart", "username": "betty", "_password": "eyJhbGciOiJIUzI1NiJ9.ImNvbmRpbWVudHVtIg.n0KeFDo_o3Hr1cl0P1X3CAza029GFd1GFLthcxjSCgI", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.564Z", "created_by": "Fake", "comment": "Mauris lacinia sapien quis libero."}}, {"model": "assets.systemuser", "pk": "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "fields": {"name": "Linda Mendoza", "username": "judith", "_password": "eyJhbGciOiJIUzI1NiJ9.InByb2luIg.j4I43DiE0E2dweGu63szcIkK6MrpiW1Iyr8uolb1eoI", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.555Z", "created_by": "Fake", "comment": "Morbi vel lectus in quam fringilla rhoncus."}}, {"model": "assets.systemuser", "pk": "f056becf-3b4b-400e-898d-211d9b5a1d99", "fields": {"name": "Donna Jackson", "username": "anne", "_password": "eyJhbGciOiJIUzI1NiJ9.InJ1dHJ1bSI.e9e4AJVlXCLyu2tkGWKY-NsMt-cO_6iX0iBXXzYWWNs", "protocol": "ssh", "_private_key": "", "_public_key": "", "auth_method": "K", "auto_push": true, "sudo": "/sbin/ifconfig", "shell": "/bin/bash", "date_created": "2017-12-07T08:20:52.580Z", "created_by": "Fake", "comment": "Mauris ullamcorper purus sit amet nulla."}}, {"model": "assets.assetgroup", "pk": "09168b5c-4d5f-484b-8166-d9026063ab0b", "fields": {"name": "Robin Parker", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.633Z", "comment": "Vivamus vestibulum sagittis sapien.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "0e8bcd4b-2163-4c15-90c0-9789f4232ba1", "fields": {"name": "Christine Peters", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.895Z", "comment": "Cras mi pede, malesuada in, imperdiet et, commodo vulputate, justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1154dbfa-b520-462f-a169-a560b1598f44", "fields": {"name": "Janice Fisher", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.892Z", "comment": "Phasellus id sapien in sapien iaculis congue.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1336c3b8-4c15-493d-a180-e0fc6ad060b2", "fields": {"name": "Janice Matthews", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.898Z", "comment": "Fusce posuere felis sed lacus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "13e7438c-a4ec-4c75-b09f-422c157bd76c", "fields": {"name": "Janet Roberts", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.713Z", "comment": "Maecenas leo odio, condimentum id, luctus nec, molestie sed, justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "18fede16-2309-40eb-a9b7-e159d1fefa41", "fields": {"name": "Laura Dean", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.679Z", "comment": "Vestibulum quam sapien, varius ut, blandit non, interdum in, ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "19c435b1-bf74-4870-a16c-8ebf462fa6da", "fields": {"name": "Betty Gray", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.889Z", "comment": "Morbi ut odio.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1b66354b-2a36-423e-a59c-88ac6f73c928", "fields": {"name": "Teresa Fernandez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.673Z", "comment": "Donec vitae nisi.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1dd09ace-5b53-4a6e-90a7-fbb9c718d0f5", "fields": {"name": "Wanda Gomez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.691Z", "comment": "In tempor, turpis nec euismod scelerisque, quam turpis adipiscing lorem, vitae mattis nibh ligula nec sem.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1e5c7012-46e5-4c71-b95b-911b24f63a13", "fields": {"name": "Stephanie Ruiz", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.743Z", "comment": "Proin risus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1ed242df-3e7b-459a-876b-3e9be645ef70", "fields": {"name": "Wanda Parker", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.657Z", "comment": "Mauris sit amet eros.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1f128730-d0eb-4e96-b144-f8425bc226dc", "fields": {"name": "Anna Perkins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.855Z", "comment": "Praesent id massa id nisl venenatis lacinia.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "1f5f2fac-3463-4215-8290-ce84ae8809ac", "fields": {"name": "Carol Vasquez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.811Z", "comment": "Sed vel enim sit amet nunc viverra dapibus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "23714c28-4186-413a-b1c4-6f688c2ec85c", "fields": {"name": "Laura Olson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.760Z", "comment": "Integer tincidunt ante vel ipsum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "262f8fd6-a9e5-4687-b1bd-e6983fffe60f", "fields": {"name": "Shirley Watkins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.876Z", "comment": "Donec dapibus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "29ad2563-c5eb-4963-9314-d1fc6a49f51a", "fields": {"name": "Michelle Perry", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.864Z", "comment": "Quisque ut erat.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "2da084a8-bdd6-42ee-a39e-9d78c7cf0535", "fields": {"name": "Rebecca Vasquez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.825Z", "comment": "Sed ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "33449baf-3516-4ba0-a9f5-b878ac1da501", "fields": {"name": "Dorothy Gonzales", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.747Z", "comment": "Integer ac neque.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "37f2a85d-be6f-498e-9847-3a071fb22544", "fields": {"name": "Shirley Stephens", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.651Z", "comment": "Curabitur gravida nisi at nibh.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "3f6382dc-ae61-4a93-9e5e-1e41dff4b6e2", "fields": {"name": "Christine Kennedy", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.841Z", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Mauris viverra diam vitae quam.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4511fc92-9c49-4806-94b7-ea21ce11217d", "fields": {"name": "Phyllis Butler", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.638Z", "comment": "Aenean auctor gravida sem.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4a24f49f-2d90-4474-bb4a-93295db257ce", "fields": {"name": "Betty Murray", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.844Z", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Duis faucibus accumsan odio.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4a437dbf-ae1a-47e8-8e21-0687891a479b", "fields": {"name": "Catherine Hawkins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.755Z", "comment": "Sed ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4c145ce1-c3e3-441a-a86d-69df17b7101f", "fields": {"name": "Sharon Mcdonald", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.771Z", "comment": "Pellentesque eget nunc.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4dd7deb8-18df-4c9a-9085-0abb84af419c", "fields": {"name": "Anna Elliott", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.881Z", "comment": "Lorem ipsum dolor sit amet, consectetuer adipiscing elit.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "4ff4976f-2364-454b-907e-6e1be1e09bd9", "fields": {"name": "Lois Stevens", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.716Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "50048717-231c-47d0-94c1-801f098f6814", "fields": {"name": "Julia Hart", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.878Z", "comment": "Aliquam quis turpis eget elit sodales scelerisque.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "51d39285-f6c6-467b-8d6a-089c05c9670e", "fields": {"name": "Angela Diaz", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.702Z", "comment": "Pellentesque viverra pede ac diam.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "544592b9-052b-4169-afd6-bc1cb722d8a3", "fields": {"name": "Mary Montgomery", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.853Z", "comment": "Fusce congue, diam id ornare imperdiet, sapien urna pretium nisl, ut volutpat sapien arcu sed augue.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "5503bc69-fc4d-4e34-9ef9-b780a654576c", "fields": {"name": "Irene Lawrence", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.688Z", "comment": "Quisque erat eros, viverra eget, congue eget, semper rutrum, nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "556852cc-b5b6-41df-b24b-4d443de4dfdf", "fields": {"name": "Emily Green", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.665Z", "comment": "Duis bibendum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "55c19958-5101-4dbc-94c7-9e1512e4c4a2", "fields": {"name": "Annie Wood", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.774Z", "comment": "Etiam pretium iaculis justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "5b117b17-c720-4c86-bd8f-ddcdf770515f", "fields": {"name": "Helen Hicks", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.794Z", "comment": "Maecenas leo odio, condimentum id, luctus nec, molestie sed, justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "5e3cc371-a2d1-49cb-af5b-56cf54e9912f", "fields": {"name": "Teresa Fowler", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.705Z", "comment": "Integer aliquet, massa id lobortis convallis, tortor risus dapibus augue, vel accumsan tellus nisi eu orci.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "628f77e6-4410-4779-88a6-2f622a92a784", "fields": {"name": "Frances Foster", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.737Z", "comment": "Nullam porttitor lacus at turpis.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "62a70279-caef-49bb-8af9-14d9c15ea855", "fields": {"name": "Anna Richardson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.836Z", "comment": "Phasellus sit amet erat.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "67be35c1-440a-41ef-aa33-20c17ba1ecb6", "fields": {"name": "Debra Mcdonald", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.819Z", "comment": "Curabitur in libero ut massa volutpat convallis.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "fields": {"name": "Donna Hicks", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.676Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "6a158957-3ab2-4af6-8ba0-2b30e22428ad", "fields": {"name": "Joan Brown", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.684Z", "comment": "Sed ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "6c64d761-87e4-4277-8210-f63bdf6641c7", "fields": {"name": "Louise Jenkins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.631Z", "comment": "Integer pede justo, lacinia eget, tincidunt eget, tempus vel, pede.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "6e4f95c0-3aba-4301-bfe2-e6dc9a370048", "fields": {"name": "Tammy Mccoy", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.696Z", "comment": "Maecenas ut massa quis augue luctus tincidunt.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "6ef8cd9a-1995-4ff8-a83a-907d97b67762", "fields": {"name": "Jennifer Lynch", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.721Z", "comment": "Integer a nibh.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "6fb8cec4-ed7a-40ae-9c13-36e514d05ce7", "fields": {"name": "Janice Schmidt", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.708Z", "comment": "Praesent id massa id nisl venenatis lacinia.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "71a93e4a-7e0a-49b5-9d91-99c0d45ac2a9", "fields": {"name": "Rose Gardner", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.791Z", "comment": "Duis bibendum, felis sed interdum venenatis, turpis enim blandit mi, in porttitor pede justo eu massa.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "7a313985-9460-41df-bd86-7f3c19ed85fa", "fields": {"name": "Sharon Young", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.662Z", "comment": "Vivamus vel nulla eget eros elementum pellentesque.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "7a9da454-b9bb-46e1-bcf7-05232f263138", "fields": {"name": "Jessica Griffin", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.867Z", "comment": "Donec semper sapien a libero.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "7f472514-ded2-4a09-8ff0-b9b91f85ca8e", "fields": {"name": "Cheryl Rodriguez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.636Z", "comment": "Cras non velit nec nisi vulputate nonummy.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "7f99a303-baf6-4a3a-b2d5-38b42083c6ed", "fields": {"name": "Cheryl Lane", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.777Z", "comment": "Nulla neque libero, convallis eget, eleifend luctus, ultricies eu, nibh.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "7fa66d80-3134-483b-add5-3082d5fc2829", "fields": {"name": "Marilyn Castillo", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.681Z", "comment": "Praesent blandit.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "8182f741-e273-49e3-b0cc-c531391da513", "fields": {"name": "Donna Rogers", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.769Z", "comment": "Ut at dolor quis odio consequat varius.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "81f2bad8-24ab-4f14-81c9-1c0b11e2e158", "fields": {"name": "Anne Montgomery", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.625Z", "comment": "Maecenas pulvinar lobortis est.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "822af801-f8ab-4980-9c50-9fbe3ef66e02", "fields": {"name": "Helen Nguyen", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.847Z", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla dapibus dolor vel est.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "83810313-256d-4a42-9be7-b8254d37111f", "fields": {"name": "Sharon Gutierrez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.858Z", "comment": "Pellentesque viverra pede ac diam.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "85145b4d-07b2-47e6-bb0c-bd723e117724", "fields": {"name": "Joyce Ellis", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.693Z", "comment": "Mauris ullamcorper purus sit amet nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "8738ff4e-64a3-419d-8fa0-b093640dee59", "fields": {"name": "Anna Perez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.622Z", "comment": "Pellentesque at nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "87a4a0fb-7f42-49f2-add9-dac68c528586", "fields": {"name": "Kelly Jacobs", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.814Z", "comment": "Praesent id massa id nisl venenatis lacinia.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "881a0460-7989-42af-a588-957efe57fb8e", "fields": {"name": "Default", "created_by": "", "date_created": "2017-12-07T08:20:09.610Z", "comment": "Default asset group", "system_users": []}}, {"model": "assets.assetgroup", "pk": "8c045cf6-befa-40f9-8f86-84f8c4b0aa30", "fields": {"name": "Judith Boyd", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.884Z", "comment": "Nulla tellus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "8c963f9a-52b0-47ce-8d56-41d8810513f2", "fields": {"name": "Nancy Watkins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.850Z", "comment": "Donec dapibus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "8fb62b59-6cae-499c-853d-d7d4c0e91a57", "fields": {"name": "Beverly Collins", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.649Z", "comment": "Fusce posuere felis sed lacus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "902ecbb6-740e-4784-98e4-6f44bbb67cc9", "fields": {"name": "Joan Meyer", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.718Z", "comment": "Cras mi pede, malesuada in, imperdiet et, commodo vulputate, justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "90f583be-21d6-43b0-af42-6a6d22b4e15f", "fields": {"name": "Jane Phillips", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.758Z", "comment": "Fusce posuere felis sed lacus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "913f9232-bd66-40f8-80cf-21593dddb59b", "fields": {"name": "Helen Lewis", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.822Z", "comment": "Curabitur gravida nisi at nibh.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "9164d22e-d5a4-4584-a073-5e8208d79d28", "fields": {"name": "Ruth Montgomery", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.763Z", "comment": "Fusce posuere felis sed lacus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "92cbd38e-f65b-4a3b-8956-5d53d00cc1ab", "fields": {"name": "Sarah Thompson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.830Z", "comment": "Praesent lectus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "92d63bd2-4797-4789-a2dc-83aa9f9c9276", "fields": {"name": "Elizabeth Baker", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.861Z", "comment": "Quisque id justo sit amet sapien dignissim vestibulum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "94707978-527b-4782-8451-519620c3ce38", "fields": {"name": "Carolyn Murray", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.668Z", "comment": "Duis bibendum, felis sed interdum venenatis, turpis enim blandit mi, in porttitor pede justo eu massa.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a0cc880c-2d10-47d9-8a9b-b7297346c582", "fields": {"name": "Diane Larson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.780Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a12acc55-4021-4df9-b591-5a03245a5208", "fields": {"name": "Kathryn Smith", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.732Z", "comment": "Morbi quis tortor id nulla ultrices aliquet.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a274e6ce-b2d0-4ffe-a22e-6cdc4d3743be", "fields": {"name": "Beverly Carter", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.646Z", "comment": "Maecenas pulvinar lobortis est.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a3d348d7-2723-4fd2-bb63-18215b492053", "fields": {"name": "Rachel George", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.788Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a5a13b13-8df3-4141-a7a7-89e04a95a690", "fields": {"name": "Evelyn Ruiz", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.752Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a630b6ff-a7bb-4fb2-8073-75322865320b", "fields": {"name": "Louise Powell", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.671Z", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Nulla dapibus dolor vel est.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "a851f4f0-532b-4d1a-a610-5b02eb0027af", "fields": {"name": "Diana Cooper", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.839Z", "comment": "Sed ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "aff61d74-9aa1-4f90-af38-fd0f4985c9d4", "fields": {"name": "Diana Campbell", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.873Z", "comment": "In hac habitasse platea dictumst.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "ba8ebaa3-499d-4afe-9e29-a3069b5470df", "fields": {"name": "Margaret Harper", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.735Z", "comment": "Morbi vestibulum, velit id pretium iaculis, diam erat fermentum justo, nec condimentum neque sapien placerat ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "bd317a7f-4ba8-4c6c-9ce2-5e39a24817fe", "fields": {"name": "Rachel Carr", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.729Z", "comment": "Mauris enim leo, rhoncus sed, vestibulum sit amet, cursus id, turpis.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "c778d607-59ba-4a12-a464-fc9519316ed5", "fields": {"name": "Kelly Hughes", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.710Z", "comment": "Donec odio justo, sollicitudin ut, suscipit a, feugiat et, eros.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "fields": {"name": "Jane Peters", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.699Z", "comment": "Duis bibendum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "cc5331db-4a80-45d9-88b9-62b7c164bcfd", "fields": {"name": "Gloria Richards", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.799Z", "comment": "Sed sagittis.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "cc5e77a5-ae3f-4410-b6af-956980dab38f", "fields": {"name": "Sharon Greene", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.802Z", "comment": "In sagittis dui vel nisl.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "ce263cf4-3210-42fa-8869-06783f1e8973", "fields": {"name": "Dorothy Hunt", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.641Z", "comment": "Cras in purus eu magna vulputate luctus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "d2adba2e-73ac-4036-871e-db4b4c2a1a70", "fields": {"name": "Judy Wilson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.828Z", "comment": "Duis aliquam convallis nunc.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "d5d99362-f06d-408f-aaba-4f657c63ceee", "fields": {"name": "Diane Roberts", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.808Z", "comment": "Morbi vestibulum, velit id pretium iaculis, diam erat fermentum justo, nec condimentum neque sapien placerat ante.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "d7ba405e-5cc8-40e2-98c5-d2cdbfb2c1bb", "fields": {"name": "Elizabeth Lopez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.796Z", "comment": "Maecenas rhoncus aliquam lacus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "d97cbcde-d878-4787-be9f-737e6950f9b0", "fields": {"name": "Mildred Armstrong", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.805Z", "comment": "Donec dapibus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "dec1d0de-875a-4930-b4c8-f17f60f9af2f", "fields": {"name": "Marilyn Payne", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.782Z", "comment": "Nulla ut erat id mauris vulputate elementum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "e11fcf30-c50b-4df6-8457-736208b1a3a1", "fields": {"name": "Susan Foster", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.785Z", "comment": "Nulla neque libero, convallis eget, eleifend luctus, ultricies eu, nibh.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "e3063d5f-25a8-402a-9b46-51cfb8235db6", "fields": {"name": "Doris Griffin", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.628Z", "comment": "Cras pellentesque volutpat dui.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "e46c7191-8f2a-4c01-be61-90445d409c47", "fields": {"name": "Alice Thomas", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.659Z", "comment": "Mauris ullamcorper purus sit amet nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "e919d5b9-f718-4205-b16c-55a5b45f2e50", "fields": {"name": "Jennifer Gordon", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.750Z", "comment": "Phasellus in felis.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "e9c034d2-9be0-49b2-a0cf-730f7270819e", "fields": {"name": "Dorothy Boyd", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.766Z", "comment": "Pellentesque at nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "ef8818e7-1e9c-4868-9d9a-7985618ae897", "fields": {"name": "Joyce Fields", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.816Z", "comment": "Donec odio justo, sollicitudin ut, suscipit a, feugiat et, eros.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "f5e7a82d-95a1-494d-91e0-8a56608b8c8e", "fields": {"name": "Ruth Woods", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.726Z", "comment": "Mauris ullamcorper purus sit amet nulla.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "f5f374b4-5784-412f-b83c-60f42b3ed2b1", "fields": {"name": "Jane Lawson", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.833Z", "comment": "Suspendisse ornare consequat lectus.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "fa887c60-4c10-426c-ad53-f1724c012af5", "fields": {"name": "Rebecca Long", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.643Z", "comment": "Quisque id justo sit amet sapien dignissim vestibulum.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "fc7fc3d1-903e-4109-a712-26e0c8936dfa", "fields": {"name": "Lisa Welch", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.724Z", "comment": "Vivamus metus arcu, adipiscing molestie, hendrerit at, vulputate vitae, nisl.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "fd6b95d7-57ae-4351-b37b-067772887179", "fields": {"name": "Bonnie Brooks", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.870Z", "comment": "In quis justo.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "ff36e4da-5156-48a1-9bec-f54b107cfa02", "fields": {"name": "Annie Dunn", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.654Z", "comment": "Donec vitae nisi.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "ff83212a-498d-49ce-abbc-22d13119871c", "fields": {"name": "Patricia Mitchell", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.740Z", "comment": "Aliquam erat volutpat.", "system_users": []}}, {"model": "assets.assetgroup", "pk": "fffe1e01-b3d8-43e6-a92c-a651eda567ec", "fields": {"name": "Andrea Chavez", "created_by": "Fake", "date_created": "2017-12-07T08:20:52.887Z", "comment": "Phasellus in felis.", "system_users": []}}, {"model": "assets.asset", "pk": "028cf88c-a5af-42f5-921f-ff7dee540ba1", "fields": {"ip": "60.60.60.60", "hostname": "virginia68", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.881Z", "comment": "", "groups": ["94707978-527b-4782-8451-519620c3ce38", "881a0460-7989-42af-a588-957efe57fb8e", "902ecbb6-740e-4784-98e4-6f44bbb67cc9"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "02ebd0a1-6177-43ab-9c6c-e0cb649d722d", "fields": {"ip": "1.1.1.1", "hostname": "mildred89", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:52.942Z", "comment": "", "groups": ["67be35c1-440a-41ef-aa33-20c17ba1ecb6", "544592b9-052b-4169-afd6-bc1cb722d8a3", "262f8fd6-a9e5-4687-b1bd-e6983fffe60f"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "03beb4e6-4632-4284-b1f0-b6f61c1a12c4", "fields": {"ip": "56.56.56.56", "hostname": "louise94", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.763Z", "comment": "", "groups": ["a5a13b13-8df3-4141-a7a7-89e04a95a690", "f5f374b4-5784-412f-b83c-60f42b3ed2b1", "50048717-231c-47d0-94c1-801f098f6814"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "06d1d681-b84d-4018-9db9-3b38a78a18f8", "fields": {"ip": "72.72.72.72", "hostname": "marie87", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.314Z", "comment": "", "groups": ["881a0460-7989-42af-a588-957efe57fb8e", "a0cc880c-2d10-47d9-8a9b-b7297346c582", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "0a5a0a24-e2a9-4618-9abc-98273fd99d03", "fields": {"ip": "6.6.6.6", "hostname": "carolyn66", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.108Z", "comment": "", "groups": ["6a158957-3ab2-4af6-8ba0-2b30e22428ad", "c778d607-59ba-4a12-a464-fc9519316ed5", "e11fcf30-c50b-4df6-8457-736208b1a3a1"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "0ba05a7d-9530-4b49-ab19-9a8676e401df", "fields": {"ip": "31.31.31.31", "hostname": "maria65", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.908Z", "comment": "", "groups": ["c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "1154dbfa-b520-462f-a169-a560b1598f44", "4ff4976f-2364-454b-907e-6e1be1e09bd9"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "10eb8298-be8c-4127-a121-3e008f38dfc7", "fields": {"ip": "76.76.76.76", "hostname": "deborah88", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.460Z", "comment": "", "groups": ["c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "7a9da454-b9bb-46e1-bcf7-05232f263138"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "1247e3b4-ba60-4182-888a-52a671285a7c", "fields": {"ip": "94.94.94.94", "hostname": "joyce79", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.152Z", "comment": "", "groups": ["ff36e4da-5156-48a1-9bec-f54b107cfa02", "5b117b17-c720-4c86-bd8f-ddcdf770515f", "1ed242df-3e7b-459a-876b-3e9be645ef70"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "130abdb5-6ad0-44ae-a3d3-e0f6046d829a", "fields": {"ip": "83.83.83.83", "hostname": "anna85", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.731Z", "comment": "", "groups": ["68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "13e7438c-a4ec-4c75-b09f-422c157bd76c", "29ad2563-c5eb-4963-9314-d1fc6a49f51a"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "15ad4725-8850-422f-94d0-019358091a72", "fields": {"ip": "88.88.88.88", "hostname": "norma92", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.921Z", "comment": "", "groups": ["62a70279-caef-49bb-8af9-14d9c15ea855", "6ef8cd9a-1995-4ff8-a83a-907d97b67762", "4ff4976f-2364-454b-907e-6e1be1e09bd9"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "168ce0e9-1e32-4b6e-9583-5db54f730edf", "fields": {"ip": "44.44.44.44", "hostname": "amy93", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.328Z", "comment": "", "groups": ["19c435b1-bf74-4870-a16c-8ebf462fa6da", "fa887c60-4c10-426c-ad53-f1724c012af5", "4c145ce1-c3e3-441a-a86d-69df17b7101f"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "2e83e252-b84c-4fab-b055-389d07c3acd8", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "17788047-7e40-4669-9d8a-9b049be9589a", "fields": {"ip": "47.47.47.47", "hostname": "jessica65", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.438Z", "comment": "", "groups": ["881a0460-7989-42af-a588-957efe57fb8e", "556852cc-b5b6-41df-b24b-4d443de4dfdf", "71a93e4a-7e0a-49b5-9d91-99c0d45ac2a9"], "system_users": ["9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "18cd2ed4-05c9-4745-8dc8-953ef6ffb40f", "fields": {"ip": "58.58.58.58", "hostname": "michelle78", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.809Z", "comment": "", "groups": ["81f2bad8-24ab-4f14-81c9-1c0b11e2e158", "aff61d74-9aa1-4f90-af38-fd0f4985c9d4", "bd317a7f-4ba8-4c6c-9ce2-5e39a24817fe"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "193ffb60-7691-4f39-a276-52ce2b2402ad", "fields": {"ip": "3.3.3.3", "hostname": "jennifer74", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.007Z", "comment": "", "groups": ["aff61d74-9aa1-4f90-af38-fd0f4985c9d4", "e3063d5f-25a8-402a-9b46-51cfb8235db6", "262f8fd6-a9e5-4687-b1bd-e6983fffe60f"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "19906beb-c3b6-4f6f-b845-0b181aacc9a6", "fields": {"ip": "50.50.50.50", "hostname": "janet75", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.542Z", "comment": "", "groups": ["33449baf-3516-4ba0-a9f5-b878ac1da501", "92d63bd2-4797-4789-a2dc-83aa9f9c9276", "87a4a0fb-7f42-49f2-add9-dac68c528586"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "1b9d02ed-0f13-4b5a-84de-d0ea448442e4", "fields": {"ip": "96.96.96.96", "hostname": "donna78", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.228Z", "comment": "", "groups": ["4a24f49f-2d90-4474-bb4a-93295db257ce", "d7ba405e-5cc8-40e2-98c5-d2cdbfb2c1bb", "bd317a7f-4ba8-4c6c-9ce2-5e39a24817fe"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "20718d09-98ab-4ed4-8d85-207bd46c852c", "fields": {"ip": "16.16.16.16", "hostname": "janet89", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.424Z", "comment": "", "groups": ["8738ff4e-64a3-419d-8fa0-b093640dee59", "e3063d5f-25a8-402a-9b46-51cfb8235db6", "4c145ce1-c3e3-441a-a86d-69df17b7101f"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "a08c8830-7838-4660-9072-fd038ecb02f4", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "22d80fa1-1d92-45a7-b415-d8b389ac2888", "fields": {"ip": "0.0.0.0", "hostname": "michelle69", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:52.906Z", "comment": "", "groups": ["e9c034d2-9be0-49b2-a0cf-730f7270819e", "2da084a8-bdd6-42ee-a39e-9d78c7cf0535", "5e3cc371-a2d1-49cb-af5b-56cf54e9912f"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "2387841b-9306-4d56-807f-849671e0e1c4", "fields": {"ip": "89.89.89.89", "hostname": "anne71", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.960Z", "comment": "", "groups": ["7f99a303-baf6-4a3a-b2d5-38b42083c6ed", "6a158957-3ab2-4af6-8ba0-2b30e22428ad", "ef8818e7-1e9c-4868-9d9a-7985618ae897"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "23e98146-dab9-47bf-80f2-88ea15cb6224", "fields": {"ip": "2.2.2.2", "hostname": "jennifer83", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:52.975Z", "comment": "", "groups": ["1f128730-d0eb-4e96-b144-f8425bc226dc", "ce263cf4-3210-42fa-8869-06783f1e8973", "a12acc55-4021-4df9-b591-5a03245a5208"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "258f301a-207b-459e-9f3e-277417ff428a", "fields": {"ip": "61.61.61.61", "hostname": "catherine65", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.915Z", "comment": "", "groups": ["19c435b1-bf74-4870-a16c-8ebf462fa6da", "1336c3b8-4c15-493d-a180-e0fc6ad060b2"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "2ef30092-fb45-49e7-bae1-e105928c46ed", "fields": {"ip": "48.48.48.48", "hostname": "patricia69", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.473Z", "comment": "", "groups": ["8fb62b59-6cae-499c-853d-d7d4c0e91a57", "6a158957-3ab2-4af6-8ba0-2b30e22428ad", "4c145ce1-c3e3-441a-a86d-69df17b7101f"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "2f9ab896-4cf1-41ee-9601-d13d2d6cf254", "fields": {"ip": "93.93.93.93", "hostname": "theresa77", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.115Z", "comment": "", "groups": ["92d63bd2-4797-4789-a2dc-83aa9f9c9276", "87a4a0fb-7f42-49f2-add9-dac68c528586", "262f8fd6-a9e5-4687-b1bd-e6983fffe60f"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "32c17a26-2cd7-481f-b1e6-b4f6483b900c", "fields": {"ip": "28.28.28.28", "hostname": "bonnie81", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.813Z", "comment": "", "groups": ["8182f741-e273-49e3-b0cc-c531391da513", "37f2a85d-be6f-498e-9847-3a071fb22544", "6e4f95c0-3aba-4301-bfe2-e6dc9a370048"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "9fcfed52-7476-4345-ba2f-c246e8e27522", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "3976c985-e291-4c1c-8a9c-d162195eafc9", "fields": {"ip": "66.66.66.66", "hostname": "annie92", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.101Z", "comment": "", "groups": ["ff36e4da-5156-48a1-9bec-f54b107cfa02", "a12acc55-4021-4df9-b591-5a03245a5208", "c778d607-59ba-4a12-a464-fc9519316ed5"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "397ef248-cdc4-4db4-93c7-7f049cf68182", "fields": {"ip": "85.85.85.85", "hostname": "annie69", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.805Z", "comment": "", "groups": ["92d63bd2-4797-4789-a2dc-83aa9f9c9276", "dec1d0de-875a-4930-b4c8-f17f60f9af2f", "9164d22e-d5a4-4584-a073-5e8208d79d28"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "3a5f05ad-be10-4ecd-bf79-ad4b9f5adddd", "fields": {"ip": "87.87.87.87", "hostname": "michelle68", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.880Z", "comment": "", "groups": ["7f472514-ded2-4a09-8ff0-b9b91f85ca8e", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e", "4c145ce1-c3e3-441a-a86d-69df17b7101f"], "system_users": ["6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "3a6561c6-2b3a-4ad8-b17d-b95668af9b61", "fields": {"ip": "54.54.54.54", "hostname": "patricia71", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.686Z", "comment": "", "groups": ["556852cc-b5b6-41df-b24b-4d443de4dfdf", "2da084a8-bdd6-42ee-a39e-9d78c7cf0535", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "3eccfe2a-f18b-4f67-95e4-cbc5bb12f124", "fields": {"ip": "82.82.82.82", "hostname": "ann84", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.695Z", "comment": "", "groups": ["913f9232-bd66-40f8-80cf-21593dddb59b", "c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "90f583be-21d6-43b0-af42-6a6d22b4e15f"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "3f65b084-1c8d-45ba-a9b3-3c825a3833f5", "fields": {"ip": "15.15.15.15", "hostname": "wanda80", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.392Z", "comment": "", "groups": ["1f128730-d0eb-4e96-b144-f8425bc226dc", "19c435b1-bf74-4870-a16c-8ebf462fa6da", "4511fc92-9c49-4806-94b7-ea21ce11217d"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "2e83e252-b84c-4fab-b055-389d07c3acd8"]}}, {"model": "assets.asset", "pk": "3ff86a95-7afd-4ff1-ad1d-5ceee9d34153", "fields": {"ip": "8.8.8.8", "hostname": "phyllis79", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.175Z", "comment": "", "groups": ["628f77e6-4410-4779-88a6-2f622a92a784", "6ef8cd9a-1995-4ff8-a83a-907d97b67762", "1b66354b-2a36-423e-a59c-88ac6f73c928"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "428238fb-e317-4bde-b88b-f1d4f80beba7", "fields": {"ip": "51.51.51.51", "hostname": "janice75", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.577Z", "comment": "", "groups": ["1f5f2fac-3463-4215-8290-ce84ae8809ac", "5b117b17-c720-4c86-bd8f-ddcdf770515f", "bd317a7f-4ba8-4c6c-9ce2-5e39a24817fe"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "4793dd99-42c8-42a0-87d9-614641e3f334", "fields": {"ip": "18.18.18.18", "hostname": "bonnie93", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.488Z", "comment": "", "groups": ["8182f741-e273-49e3-b0cc-c531391da513", "4ff4976f-2364-454b-907e-6e1be1e09bd9", "4511fc92-9c49-4806-94b7-ea21ce11217d"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "49738cda-9467-48dd-84f4-7866c28b051c", "fields": {"ip": "11.11.11.11", "hostname": "donna73", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.268Z", "comment": "", "groups": ["4a24f49f-2d90-4474-bb4a-93295db257ce", "e919d5b9-f718-4205-b16c-55a5b45f2e50", "d97cbcde-d878-4787-be9f-737e6950f9b0"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "a08c8830-7838-4660-9072-fd038ecb02f4", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "4d7a9aeb-6614-4d9f-afba-f331aa54185a", "fields": {"ip": "17.17.17.17", "hostname": "judy83", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.456Z", "comment": "", "groups": ["8738ff4e-64a3-419d-8fa0-b093640dee59", "33449baf-3516-4ba0-a9f5-b878ac1da501", "c9a5c3b3-caf2-40c6-9282-83800a4a72c9"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "5613ee31-0542-41f7-b117-92bc049b7a4d", "fields": {"ip": "73.73.73.73", "hostname": "joan77", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.347Z", "comment": "", "groups": ["51d39285-f6c6-467b-8d6a-089c05c9670e", "4dd7deb8-18df-4c9a-9085-0abb84af419c", "55c19958-5101-4dbc-94c7-9e1512e4c4a2"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "587ca351-2a78-489d-bc18-2b287d7ceff6", "fields": {"ip": "27.27.27.27", "hostname": "anna69", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.780Z", "comment": "", "groups": ["8c045cf6-befa-40f9-8f86-84f8c4b0aa30", "6c64d761-87e4-4277-8210-f63bdf6641c7", "9164d22e-d5a4-4584-a073-5e8208d79d28"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "59749e11-2375-4adb-8728-fe96637623d3", "fields": {"ip": "38.38.38.38", "hostname": "denise93", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.131Z", "comment": "", "groups": ["cc5331db-4a80-45d9-88b9-62b7c164bcfd", "23714c28-4186-413a-b1c4-6f688c2ec85c", "544592b9-052b-4169-afd6-bc1cb722d8a3"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "5d06eb4a-c175-4dd3-a18a-c7098ed39de1", "fields": {"ip": "7.7.7.7", "hostname": "kimberly73", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.140Z", "comment": "", "groups": ["a274e6ce-b2d0-4ffe-a22e-6cdc4d3743be", "8fb62b59-6cae-499c-853d-d7d4c0e91a57", "1e5c7012-46e5-4c71-b95b-911b24f63a13"], "system_users": ["587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "5fd6a42a-8226-4e0d-8dd8-585052b28a4b", "fields": {"ip": "81.81.81.81", "hostname": "lori85", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.657Z", "comment": "", "groups": ["ff36e4da-5156-48a1-9bec-f54b107cfa02", "4511fc92-9c49-4806-94b7-ea21ce11217d", "262f8fd6-a9e5-4687-b1bd-e6983fffe60f"], "system_users": ["6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "603e0f06-4453-42bb-ae58-a2e1193eeb98", "fields": {"ip": "24.24.24.24", "hostname": "marilyn79", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.681Z", "comment": "", "groups": ["0e8bcd4b-2163-4c15-90c0-9789f4232ba1", "9164d22e-d5a4-4584-a073-5e8208d79d28", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "617cf548-a72e-459c-bc83-7acc4da1f32d", "fields": {"ip": "21.21.21.21", "hostname": "frances77", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.586Z", "comment": "", "groups": ["8fb62b59-6cae-499c-853d-d7d4c0e91a57", "1f5f2fac-3463-4215-8290-ce84ae8809ac", "544592b9-052b-4169-afd6-bc1cb722d8a3"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "694215ef-23b3-4b90-899f-3af1aaed82fd", "fields": {"ip": "79.79.79.79", "hostname": "gloria72", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.581Z", "comment": "", "groups": ["8fb62b59-6cae-499c-853d-d7d4c0e91a57", "92d63bd2-4797-4789-a2dc-83aa9f9c9276", "a630b6ff-a7bb-4fb2-8073-75322865320b"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "6f6e3ba3-db28-4f9f-b403-95075b0aff40", "fields": {"ip": "97.97.97.97", "hostname": "andrew81", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.270Z", "comment": "", "groups": ["aff61d74-9aa1-4f90-af38-fd0f4985c9d4", "6fb8cec4-ed7a-40ae-9c13-36e514d05ce7", "5e3cc371-a2d1-49cb-af5b-56cf54e9912f"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "76f0d5a6-c66c-4436-9dee-c82c0f3f91f6", "fields": {"ip": "29.29.29.29", "hostname": "ruby76", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.845Z", "comment": "", "groups": ["8fb62b59-6cae-499c-853d-d7d4c0e91a57", "71a93e4a-7e0a-49b5-9d91-99c0d45ac2a9", "5e3cc371-a2d1-49cb-af5b-56cf54e9912f"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "7b6f3a7f-13e6-4aa0-94e0-de9d2128bd4f", "fields": {"ip": "65.65.65.65", "hostname": "kathleen73", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.063Z", "comment": "", "groups": ["a851f4f0-532b-4d1a-a610-5b02eb0027af", "4c145ce1-c3e3-441a-a86d-69df17b7101f", "6e4f95c0-3aba-4301-bfe2-e6dc9a370048"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "7ccb267c-5943-40fa-a9df-2593fa34c2e4", "fields": {"ip": "37.37.37.37", "hostname": "lois67", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.100Z", "comment": "", "groups": ["ff36e4da-5156-48a1-9bec-f54b107cfa02", "7f472514-ded2-4a09-8ff0-b9b91f85ca8e", "92cbd38e-f65b-4a3b-8956-5d53d00cc1ab"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "7da0b957-0e51-466d-896d-f96104aefebf", "fields": {"ip": "23.23.23.23", "hostname": "catherine80", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.648Z", "comment": "", "groups": ["e919d5b9-f718-4205-b16c-55a5b45f2e50", "23714c28-4186-413a-b1c4-6f688c2ec85c"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "7e4d3f2e-93ab-4dc2-95b1-551b96716805", "fields": {"ip": "41.41.41.41", "hostname": "linda77", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.227Z", "comment": "", "groups": ["94707978-527b-4782-8451-519620c3ce38", "a630b6ff-a7bb-4fb2-8073-75322865320b"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "7e610acd-d3ad-4c96-9b61-a0504bc3423d", "fields": {"ip": "64.64.64.64", "hostname": "laura94", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.025Z", "comment": "", "groups": ["8fb62b59-6cae-499c-853d-d7d4c0e91a57", "33449baf-3516-4ba0-a9f5-b878ac1da501", "1b66354b-2a36-423e-a59c-88ac6f73c928"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "a08c8830-7838-4660-9072-fd038ecb02f4", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "7fade84a-c1f2-4bf2-8670-0aba91a4fec9", "fields": {"ip": "22.22.22.22", "hostname": "judy94", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.617Z", "comment": "", "groups": ["e3063d5f-25a8-402a-9b46-51cfb8235db6", "ff83212a-498d-49ce-abbc-22d13119871c", "5e3cc371-a2d1-49cb-af5b-56cf54e9912f"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "81f090e4-c564-47c7-8637-a5982ce26d0f", "fields": {"ip": "42.42.42.42", "hostname": "pamela79", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.258Z", "comment": "", "groups": ["d7ba405e-5cc8-40e2-98c5-d2cdbfb2c1bb", "90f583be-21d6-43b0-af42-6a6d22b4e15f", "6e4f95c0-3aba-4301-bfe2-e6dc9a370048"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "2e83e252-b84c-4fab-b055-389d07c3acd8"]}}, {"model": "assets.asset", "pk": "823cf499-388e-4626-8d47-c4872d7ce140", "fields": {"ip": "20.20.20.20", "hostname": "betty78", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.554Z", "comment": "", "groups": ["81f2bad8-24ab-4f14-81c9-1c0b11e2e158", "8c963f9a-52b0-47ce-8d56-41d8810513f2", "4511fc92-9c49-4806-94b7-ea21ce11217d"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "83164ebf-dab8-47c3-90fa-bce35be99e98", "fields": {"ip": "40.40.40.40", "hostname": "judith75", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.196Z", "comment": "", "groups": ["55c19958-5101-4dbc-94c7-9e1512e4c4a2", "1336c3b8-4c15-493d-a180-e0fc6ad060b2", "a12acc55-4021-4df9-b591-5a03245a5208"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "89c24676-008b-4ef3-b487-f18630a1b8bb", "fields": {"ip": "95.95.95.95", "hostname": "jean88", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.190Z", "comment": "", "groups": ["1154dbfa-b520-462f-a169-a560b1598f44", "92cbd38e-f65b-4a3b-8956-5d53d00cc1ab", "6e4f95c0-3aba-4301-bfe2-e6dc9a370048"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "2e83e252-b84c-4fab-b055-389d07c3acd8", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "8a56b198-b7a5-464e-aef8-71e54ba87956", "fields": {"ip": "39.39.39.39", "hostname": "kathryn84", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.163Z", "comment": "", "groups": ["09168b5c-4d5f-484b-8166-d9026063ab0b", "71a93e4a-7e0a-49b5-9d91-99c0d45ac2a9", "9164d22e-d5a4-4584-a073-5e8208d79d28"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "8d5c67c1-3aab-4a98-a4a0-acf24b16b18a", "fields": {"ip": "10.10.10.10", "hostname": "virginia94", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.237Z", "comment": "", "groups": ["e46c7191-8f2a-4c01-be61-90445d409c47", "51d39285-f6c6-467b-8d6a-089c05c9670e", "dec1d0de-875a-4930-b4c8-f17f60f9af2f"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "8db73974-5081-4d16-a398-8dde704cc4eb", "fields": {"ip": "67.67.67.67", "hostname": "diane83", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.137Z", "comment": "", "groups": ["fffe1e01-b3d8-43e6-a92c-a651eda567ec", "1f128730-d0eb-4e96-b144-f8425bc226dc", "1ed242df-3e7b-459a-876b-3e9be645ef70"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "913b0950-9d03-4d20-aa0a-3075fd67e450", "fields": {"ip": "78.78.78.78", "hostname": "jessica83", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.535Z", "comment": "", "groups": ["19c435b1-bf74-4870-a16c-8ebf462fa6da", "4a24f49f-2d90-4474-bb4a-93295db257ce", "87a4a0fb-7f42-49f2-add9-dac68c528586"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "96a7b054-fa30-4274-809c-f6ae7e6b13fd", "fields": {"ip": "35.35.35.35", "hostname": "nancy85", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.035Z", "comment": "", "groups": ["68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "8c963f9a-52b0-47ce-8d56-41d8810513f2", "fa887c60-4c10-426c-ad53-f1724c012af5"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "97e8f7d4-1f55-4242-9eb8-df6ba3e74c1e", "fields": {"ip": "13.13.13.13", "hostname": "deborah67", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.329Z", "comment": "", "groups": ["51d39285-f6c6-467b-8d6a-089c05c9670e", "68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "4511fc92-9c49-4806-94b7-ea21ce11217d"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "f056becf-3b4b-400e-898d-211d9b5a1d99"]}}, {"model": "assets.asset", "pk": "986aa470-91cf-4d6b-a33d-b4af5bf36358", "fields": {"ip": "49.49.49.49", "hostname": "diane94", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.508Z", "comment": "", "groups": ["628f77e6-4410-4779-88a6-2f622a92a784", "f5f374b4-5784-412f-b83c-60f42b3ed2b1", "29ad2563-c5eb-4963-9314-d1fc6a49f51a"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "99949c8f-cf5a-41a7-8c81-42da6d457a52", "fields": {"ip": "63.63.63.63", "hostname": "teresa81", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.988Z", "comment": "", "groups": ["4a437dbf-ae1a-47e8-8e21-0687891a479b", "0e8bcd4b-2163-4c15-90c0-9789f4232ba1", "ef8818e7-1e9c-4868-9d9a-7985618ae897"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "9c2b3703-0df0-46d0-a0c8-19b96ec519e8", "fields": {"ip": "84.84.84.84", "hostname": "susan86", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.768Z", "comment": "", "groups": ["19c435b1-bf74-4870-a16c-8ebf462fa6da", "7f99a303-baf6-4a3a-b2d5-38b42083c6ed", "1336c3b8-4c15-493d-a180-e0fc6ad060b2"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "9f3f9503-7a27-4c11-b1a1-b36cd2288c5b", "fields": {"ip": "33.33.33.33", "hostname": "diana73", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.972Z", "comment": "", "groups": ["e3063d5f-25a8-402a-9b46-51cfb8235db6", "544592b9-052b-4169-afd6-bc1cb722d8a3", "1ed242df-3e7b-459a-876b-3e9be645ef70"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "a266ea31-4c68-4038-a06f-1b294b14692a", "fields": {"ip": "70.70.70.70", "hostname": "janice76", "port": 22, "admin_user": "f247e2af-7e72-40ea-9ec7-15a1dd2cbbc3", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.241Z", "comment": "", "groups": ["4a437dbf-ae1a-47e8-8e21-0687891a479b", "6ef8cd9a-1995-4ff8-a83a-907d97b67762", "50048717-231c-47d0-94c1-801f098f6814"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3"]}}, {"model": "assets.asset", "pk": "a3f4e0ec-cb1b-4905-ac6a-92eb937eebe5", "fields": {"ip": "5.5.5.5", "hostname": "katherine66", "port": 22, "admin_user": "26267cd3-4b22-41a6-ae76-327195767ee7", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.075Z", "comment": "", "groups": ["7f472514-ded2-4a09-8ff0-b9b91f85ca8e", "50048717-231c-47d0-94c1-801f098f6814", "ba8ebaa3-499d-4afe-9e29-a3069b5470df"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "a490a8b4-4e0c-4a23-82d0-ddfd8a868ea6", "fields": {"ip": "92.92.92.92", "hostname": "joan88", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.073Z", "comment": "", "groups": ["d7ba405e-5cc8-40e2-98c5-d2cdbfb2c1bb", "a630b6ff-a7bb-4fb2-8073-75322865320b", "ff83212a-498d-49ce-abbc-22d13119871c"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "a9c60e1a-345f-43fd-af43-6ca2d1376c13", "fields": {"ip": "77.77.77.77", "hostname": "emily68", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.498Z", "comment": "", "groups": ["a851f4f0-532b-4d1a-a610-5b02eb0027af", "7fa66d80-3134-483b-add5-3082d5fc2829", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "a9dbbd26-33ab-419a-b5a5-9e461c81d3b6", "fields": {"ip": "34.34.34.34", "hostname": "mary65", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.004Z", "comment": "", "groups": ["ff36e4da-5156-48a1-9bec-f54b107cfa02", "4c145ce1-c3e3-441a-a86d-69df17b7101f", "7a313985-9460-41df-bd86-7f3c19ed85fa"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "aefe5248-7ff4-4c44-886e-56d71face029", "fields": {"ip": "46.46.46.46", "hostname": "carolyn87", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.402Z", "comment": "", "groups": ["7f99a303-baf6-4a3a-b2d5-38b42083c6ed", "a630b6ff-a7bb-4fb2-8073-75322865320b", "dec1d0de-875a-4930-b4c8-f17f60f9af2f"], "system_users": ["9fcfed52-7476-4345-ba2f-c246e8e27522", "587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "afbecdda-b4bc-4aa7-a8dc-ea5ecca2b322", "fields": {"ip": "80.80.80.80", "hostname": "karen93", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.617Z", "comment": "", "groups": ["19c435b1-bf74-4870-a16c-8ebf462fa6da", "881a0460-7989-42af-a588-957efe57fb8e", "83810313-256d-4a42-9be7-b8254d37111f"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "b519b4d8-0c09-4bde-a9e7-f83a54526289", "fields": {"ip": "99.99.99.99", "hostname": "judy72", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.338Z", "comment": "", "groups": ["fd6b95d7-57ae-4351-b37b-067772887179", "94707978-527b-4782-8451-519620c3ce38", "822af801-f8ab-4980-9c50-9fbe3ef66e02"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "b738b7aa-81fa-4789-bf86-ab6b42e609da", "fields": {"ip": "30.30.30.30", "hostname": "virginia74", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.877Z", "comment": "", "groups": ["13e7438c-a4ec-4c75-b09f-422c157bd76c", "fc7fc3d1-903e-4109-a712-26e0c8936dfa", "37f2a85d-be6f-498e-9847-3a071fb22544"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "b902cf41-a9fb-4c0c-9ad1-9141676c1a33", "fields": {"ip": "62.62.62.62", "hostname": "phyllis74", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.950Z", "comment": "", "groups": ["8c045cf6-befa-40f9-8f86-84f8c4b0aa30", "2da084a8-bdd6-42ee-a39e-9d78c7cf0535", "9164d22e-d5a4-4584-a073-5e8208d79d28"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "bfa5238f-ba6a-40dd-92bb-71a475eaaa23", "fields": {"ip": "71.71.71.71", "hostname": "gloria71", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.277Z", "comment": "", "groups": ["8738ff4e-64a3-419d-8fa0-b093640dee59", "a274e6ce-b2d0-4ffe-a22e-6cdc4d3743be", "f5f374b4-5784-412f-b83c-60f42b3ed2b1"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3"]}}, {"model": "assets.asset", "pk": "c620b7e1-0466-42a0-93a0-c475ee8f7fff", "fields": {"ip": "12.12.12.12", "hostname": "mary70", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.298Z", "comment": "", "groups": ["62a70279-caef-49bb-8af9-14d9c15ea855", "90f583be-21d6-43b0-af42-6a6d22b4e15f", "1336c3b8-4c15-493d-a180-e0fc6ad060b2"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "c69e28c5-5762-45cb-8529-982ef7c4aec5", "fields": {"ip": "59.59.59.59", "hostname": "doris66", "port": 22, "admin_user": "992c01fa-241d-4fc5-9c2f-92ebf130fc41", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.844Z", "comment": "", "groups": ["1f128730-d0eb-4e96-b144-f8425bc226dc", "37f2a85d-be6f-498e-9847-3a071fb22544", "e11fcf30-c50b-4df6-8457-736208b1a3a1"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "ca39d0c2-4557-45dc-8be8-84d124ac7659", "fields": {"ip": "68.68.68.68", "hostname": "cynthia68", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.171Z", "comment": "", "groups": ["4a24f49f-2d90-4474-bb4a-93295db257ce", "5b117b17-c720-4c86-bd8f-ddcdf770515f", "4c145ce1-c3e3-441a-a86d-69df17b7101f"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "cd1e8581-93be-4884-a810-1098011ca39a", "fields": {"ip": "32.32.32.32", "hostname": "mary80", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.940Z", "comment": "", "groups": ["68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "913f9232-bd66-40f8-80cf-21593dddb59b", "7a9da454-b9bb-46e1-bcf7-05232f263138"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "cdd42e4c-df6c-4ebc-ab46-052fea50eb6b", "fields": {"ip": "52.52.52.52", "hostname": "ashley69", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.612Z", "comment": "", "groups": ["51d39285-f6c6-467b-8d6a-089c05c9670e", "8fb62b59-6cae-499c-853d-d7d4c0e91a57", "e919d5b9-f718-4205-b16c-55a5b45f2e50"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "2e83e252-b84c-4fab-b055-389d07c3acd8", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "ced65bbb-2016-47e8-87ef-73fca713fff1", "fields": {"ip": "45.45.45.45", "hostname": "catherine90", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.364Z", "comment": "", "groups": ["fffe1e01-b3d8-43e6-a92c-a651eda567ec", "4a437dbf-ae1a-47e8-8e21-0687891a479b", "23714c28-4186-413a-b1c4-6f688c2ec85c"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "2e83e252-b84c-4fab-b055-389d07c3acd8"]}}, {"model": "assets.asset", "pk": "cfcfb53b-5ffe-4e27-ab8b-75b95644191e", "fields": {"ip": "86.86.86.86", "hostname": "catherine93", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.842Z", "comment": "", "groups": ["1f5f2fac-3463-4215-8290-ce84ae8809ac", "7f99a303-baf6-4a3a-b2d5-38b42083c6ed", "83810313-256d-4a42-9be7-b8254d37111f"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "d3f3cde0-b4b8-4dc1-89ad-5473e6d85c93", "fields": {"ip": "53.53.53.53", "hostname": "kathleen75", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.649Z", "comment": "", "groups": ["a274e6ce-b2d0-4ffe-a22e-6cdc4d3743be", "67be35c1-440a-41ef-aa33-20c17ba1ecb6", "50048717-231c-47d0-94c1-801f098f6814"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "daeaee6e-ec14-48f4-86e7-bfb0845e8aa5", "fields": {"ip": "90.90.90.90", "hostname": "alice92", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.997Z", "comment": "", "groups": ["81f2bad8-24ab-4f14-81c9-1c0b11e2e158", "ff36e4da-5156-48a1-9bec-f54b107cfa02", "37f2a85d-be6f-498e-9847-3a071fb22544"], "system_users": ["a08c8830-7838-4660-9072-fd038ecb02f4", "9fcfed52-7476-4345-ba2f-c246e8e27522"]}}, {"model": "assets.asset", "pk": "de19760b-87de-43a5-bb61-3298ee528c7b", "fields": {"ip": "14.14.14.14", "hostname": "helen65", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.360Z", "comment": "", "groups": ["68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "1154dbfa-b520-462f-a169-a560b1598f44", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "df93cb9c-9c1a-40d5-943a-d788b182a0ee", "fields": {"ip": "25.25.25.25", "hostname": "alice73", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.715Z", "comment": "", "groups": ["cc5331db-4a80-45d9-88b9-62b7c164bcfd", "822af801-f8ab-4980-9c50-9fbe3ef66e02", "37f2a85d-be6f-498e-9847-3a071fb22544"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "e4177209-0df9-4a29-92bf-080a7a80e5b1", "fields": {"ip": "98.98.98.98", "hostname": "maria77", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.306Z", "comment": "", "groups": ["881a0460-7989-42af-a588-957efe57fb8e", "6fb8cec4-ed7a-40ae-9c13-36e514d05ce7", "7a9da454-b9bb-46e1-bcf7-05232f263138"], "system_users": ["c1611e85-00a2-45e8-a94e-410dfc8ce8b3", "383481b8-6fbf-4e94-b648-0d2de1f07f77", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "e62badbb-d053-4ae6-83ca-1b7bbb3724c3", "fields": {"ip": "75.75.75.75", "hostname": "kathy84", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "df56ab04-6a2c-43b3-a5a2-9730e28e4e73", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.424Z", "comment": "", "groups": ["ce263cf4-3210-42fa-8869-06783f1e8973", "913f9232-bd66-40f8-80cf-21593dddb59b", "6c64d761-87e4-4277-8210-f63bdf6641c7"], "system_users": ["383481b8-6fbf-4e94-b648-0d2de1f07f77", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "e6a84edb-2bb4-4e48-8932-ce497c2aa8f5", "fields": {"ip": "43.43.43.43", "hostname": "nancy74", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.296Z", "comment": "", "groups": ["fffe1e01-b3d8-43e6-a92c-a651eda567ec", "556852cc-b5b6-41df-b24b-4d443de4dfdf", "dec1d0de-875a-4930-b4c8-f17f60f9af2f"], "system_users": ["587dbf83-2f91-4c8b-8d75-59807dfbcefd", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "e9370b0d-324b-4c59-bc0d-2c5e00beef0b", "fields": {"ip": "26.26.26.26", "hostname": "ruth75", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "c0df1aa0-bde7-4226-a69a-d02976888456", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.747Z", "comment": "", "groups": ["c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "8c963f9a-52b0-47ce-8d56-41d8810513f2", "ff83212a-498d-49ce-abbc-22d13119871c"], "system_users": ["f056becf-3b4b-400e-898d-211d9b5a1d99", "2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "eaec3237-d344-4099-83a1-73c2f3c4c01d", "fields": {"ip": "91.91.91.91", "hostname": "anna88", "port": 22, "admin_user": "5e9a3c79-4b3b-4ddc-9f12-7c99b1edf976", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:56.035Z", "comment": "", "groups": ["5503bc69-fc4d-4e34-9ef9-b780a654576c", "6a158957-3ab2-4af6-8ba0-2b30e22428ad", "18fede16-2309-40eb-a9b7-e159d1fefa41"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8"]}}, {"model": "assets.asset", "pk": "eb0187b1-d448-421a-8aa0-36b3d7ae0954", "fields": {"ip": "9.9.9.9", "hostname": "sharon86", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.206Z", "comment": "", "groups": ["cc5331db-4a80-45d9-88b9-62b7c164bcfd", "d2adba2e-73ac-4036-871e-db4b4c2a1a70", "09168b5c-4d5f-484b-8166-d9026063ab0b"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "assets.asset", "pk": "eb8ead8e-7fa0-42f7-977b-938aa514235b", "fields": {"ip": "4.4.4.4", "hostname": "diana86", "port": 22, "admin_user": "61423c66-048f-4125-9844-6a15557cd345", "cluster": "5782020d-58a5-4e69-ae9f-157caf64e7f0", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.041Z", "comment": "", "groups": ["7f472514-ded2-4a09-8ff0-b9b91f85ca8e", "8182f741-e273-49e3-b0cc-c531391da513", "6c64d761-87e4-4277-8210-f63bdf6641c7"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "a08c8830-7838-4660-9072-fd038ecb02f4", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a"]}}, {"model": "assets.asset", "pk": "f1e5be58-0ddc-442a-be07-67e84b648e01", "fields": {"ip": "55.55.55.55", "hostname": "pamela70", "port": 22, "admin_user": "7f4d01fb-e8b7-471c-8cf8-ef1ea75e5bb5", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.724Z", "comment": "", "groups": ["e3063d5f-25a8-402a-9b46-51cfb8235db6", "cc5331db-4a80-45d9-88b9-62b7c164bcfd", "f5e7a82d-95a1-494d-91e0-8a56608b8c8e"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "587dbf83-2f91-4c8b-8d75-59807dfbcefd"]}}, {"model": "assets.asset", "pk": "f9d062aa-4cf8-4e02-8d7c-a3675f35288f", "fields": {"ip": "19.19.19.19", "hostname": "carol69", "port": 22, "admin_user": "7de29b0c-15ba-4471-9c51-96c3cf6a44e7", "cluster": "7cf2ee9e-9cea-4a5f-b822-38c37c449a97", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:53.521Z", "comment": "", "groups": ["913f9232-bd66-40f8-80cf-21593dddb59b", "c9a5c3b3-caf2-40c6-9282-83800a4a72c9", "29ad2563-c5eb-4963-9314-d1fc6a49f51a"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "fb5a8c7d-1208-45d2-b07f-4d313050b6a4", "fields": {"ip": "69.69.69.69", "hostname": "lois64", "port": 22, "admin_user": "5c986676-bfd7-4ade-8b9d-3631a7b9b50e", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.207Z", "comment": "", "groups": ["67be35c1-440a-41ef-aa33-20c17ba1ecb6", "29ad2563-c5eb-4963-9314-d1fc6a49f51a", "1dd09ace-5b53-4a6e-90a7-fbb9c718d0f5"], "system_users": ["2e83e252-b84c-4fab-b055-389d07c3acd8", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "fc9b4ee5-4e5c-47bb-9f55-e144cd4b3027", "fields": {"ip": "74.74.74.74", "hostname": "susan87", "port": 22, "admin_user": "68d875b0-162f-4360-abcf-b10bfae3f451", "cluster": "6a75b014-2fb3-494c-910d-fd6f39a5e409", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:55.387Z", "comment": "", "groups": ["d7ba405e-5cc8-40e2-98c5-d2cdbfb2c1bb", "dec1d0de-875a-4930-b4c8-f17f60f9af2f", "37f2a85d-be6f-498e-9847-3a071fb22544"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "6ba87731-d4c4-4acc-bd97-c7be78d60b3a", "7540c5c1-6380-4928-ba1b-0eab77de20e9"]}}, {"model": "assets.asset", "pk": "fd61d29a-6513-4b26-94dc-63cf9d252770", "fields": {"ip": "36.36.36.36", "hostname": "carol94", "port": 22, "admin_user": "6617bb42-6281-4095-ad30-4cefa0e2231e", "cluster": "39db8373-d161-4832-83e3-6139d10e827b", "is_active": true, "type": "Server", "env": "Prod", "status": "In use", "public_ip": null, "remote_card_ip": null, "cabinet_no": null, "cabinet_pos": null, "number": null, "vendor": null, "model": null, "sn": null, "cpu_model": null, "cpu_count": null, "cpu_cores": null, "memory": null, "disk_total": null, "disk_info": null, "platform": null, "os": null, "os_version": null, "os_arch": null, "hostname_raw": null, "created_by": "Fake", "date_created": "2017-12-07T08:20:54.068Z", "comment": "", "groups": ["fffe1e01-b3d8-43e6-a92c-a651eda567ec", "68aea94a-2a82-4a6a-87f4-1e280e1bbbe4", "c9a5c3b3-caf2-40c6-9282-83800a4a72c9"], "system_users": ["a7786710-df8c-4abd-9946-f7ceceaed688", "2e83e252-b84c-4fab-b055-389d07c3acd8", "a08c8830-7838-4660-9072-fd038ecb02f4"]}}, {"model": "users.user", "pk": "01545644-ae90-4a64-935a-04776b70c8c0", "fields": {"password": "pbkdf2_sha256$36000$ekPadeuXH0YD$B3MpYATjENErBYzMcKlaIN1pjAlctTQDe+6KGCYRelM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.888Z", "username": "robin91", "name": "Heather Nichols", "email": "kimberly@twitternation.name", "role": "App", "avatar": "", "wechat": "brenda93", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.888Z", "created_by": "ruth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "0174b307-b625-4734-9258-6d1c1a84af00", "fields": {"password": "pbkdf2_sha256$36000$jWY6Tjg0AbC5$lCJOQ8V6tDeefutsMx/ku+fEfOzPca5b05SllmTRdSY=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.290Z", "username": "lisa90", "name": "Kelly Carpenter", "email": "anna@voolia.biz", "role": "App", "avatar": "", "wechat": "wanda93", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Pellentesque eget nunc.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.290Z", "created_by": "christine83", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "03c53c8b-258d-4e25-9739-b511288d38e1", "fields": {"password": "pbkdf2_sha256$36000$OFR3TTgmcE15$bxK6/Y8U/O7uAfidX0tlouOVUpT1c6QWwNYgnKHOBZU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.215Z", "username": "kimberly70", "name": "Carol Thomas", "email": "jacqueline@thoughtbridge.org", "role": "Admin", "avatar": "", "wechat": "robin73", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi a ipsum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.215Z", "created_by": "cynthia70", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "05de0183-7c0b-41d1-9023-e0a2fcde256e", "fields": {"password": "pbkdf2_sha256$36000$ZEdnpLFBzY84$dA3O+/96yI+mzIjmwYaAO3Jf9Nt5NGsbGht3DnuaGDM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:44.938Z", "username": "cynthia70", "name": "Frances Alexander", "email": "carolyn@linktype.net", "role": "Admin", "avatar": "", "wechat": "marie70", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Donec semper sapien a libero.", "is_first_login": false, "date_expired": "2087-11-20T08:20:44.939Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "0bfe154a-14df-4ddf-85b8-1df0d2ec91a2", "fields": {"password": "pbkdf2_sha256$36000$DI77WJQFbxNV$NfLn+H46T0ZNNtR5OegxGPLbYw61hpZeDt0rPsIm3UI=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.357Z", "username": "maria71", "name": "Jacqueline Henry", "email": "kathryn@eire.org", "role": "User", "avatar": "", "wechat": "linda73", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Integer pede justo, lacinia eget, tincidunt eget, tempus vel, pede.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.357Z", "created_by": "brenda80", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "0fab488e-2237-4b61-811f-482a95580e05", "fields": {"password": "pbkdf2_sha256$36000$W0HfNiZd6mBZ$aht8c0BpMydvOawE6Rx66zlHoGno9wN/Jt2di7uAcIc=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.080Z", "username": "doris76", "name": "Lois Brooks", "email": "diane@avaveo.org", "role": "User", "avatar": "", "wechat": "susan92", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Duis ac nibh.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.080Z", "created_by": "rachel76", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "106384fb-22d3-4380-853a-bfd112f3d9bf", "fields": {"password": "pbkdf2_sha256$36000$0OkKTb7jZsM3$EL5H0IgRclu/vJ2KRLBUTi7Zmr8X0wMQW4S1kBBVn9M=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.038Z", "username": "katherine67", "name": "Diana Hunter", "email": "doris@fadeo.mil", "role": "Admin", "avatar": "", "wechat": "joan79", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Aenean sit amet justo.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.038Z", "created_by": "judith70", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "11946ae8-f14e-4e35-8b80-431dd3e43c6a", "fields": {"password": "pbkdf2_sha256$36000$XDsnwsQKLSHU$rM3WVBBHaaTSlhKFb6zwhDPVzpGnRm8i1ZRc42pLgKw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.688Z", "username": "teresa94", "name": "Heather Cole", "email": "amanda@dabvine.edu", "role": "User", "avatar": "", "wechat": "ruth81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi sem mauris, laoreet ut, rhoncus aliquet, pulvinar sed, nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.688Z", "created_by": "cynthia75", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "129cfef8-32aa-4d30-a6ca-c591468b7b2f", "fields": {"password": "pbkdf2_sha256$36000$dUSbLiakjtuL$dJk6vp78lzsW8wYkUZU0sI3FD27jZmgW9Afj1S1n1Qg=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.021Z", "username": "mary85", "name": "Teresa Payne", "email": "sandra@voomm.net", "role": "Admin", "avatar": "", "wechat": "frances82", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Praesent blandit.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.021Z", "created_by": "deborah79", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "13d4be0b-b02c-4e23-a7ed-3f2813a2d6f4", "fields": {"password": "pbkdf2_sha256$36000$eivp88seIbfP$2xP0MG8vEmuRz/UkgmAqbvN+UvEgWwYWvPnDnilSnrc=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.813Z", "username": "cheryl72", "name": "Kathleen Jacobs", "email": "virginia@dabfeed.edu", "role": "Admin", "avatar": "", "wechat": "diana79", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi ut odio.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.814Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "19a40886-4756-4a98-a5f7-71205ebe7f9f", "fields": {"password": "pbkdf2_sha256$36000$JpQ7M699PJZE$T+TrPlf5TOO4T/R6wNL+5gmGcHSdxzTA/FSRtSgNmGk=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.750Z", "username": "barbara67", "name": "Phyllis Reyes", "email": "beverly@avamm.mil", "role": "Admin", "avatar": "", "wechat": "nancy72", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Praesent id massa id nisl venenatis lacinia.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.750Z", "created_by": "elizabeth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "19f072c2-ad1f-4437-be07-dcca2436e937", "fields": {"password": "pbkdf2_sha256$36000$w42gsygNqjBe$LUahp6/Un0oCF8tT5s+1CLZa3eMn0J7wKH42iJGvYJ0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.436Z", "username": "janice76", "name": "Paula Rivera", "email": "lori@eamia.net", "role": "User", "avatar": "", "wechat": "denise78", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Mauris sit amet eros.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.436Z", "created_by": "doris76", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "1a1b6569-4f63-4c02-b3c5-ce83cbba32c7", "fields": {"password": "pbkdf2_sha256$36000$yqJuNTFxvcB2$UV4cASSnwfssde9aL32use1eejlxCj1U4G27eQNLAx0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.729Z", "username": "sandra90", "name": "Janice Johnson", "email": "katherine@tekfly.mil", "role": "User", "avatar": "", "wechat": "mary88", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nam congue, risus semper porta volutpat, quam pede lobortis ligula, sit amet eleifend pede libero quis orci.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.729Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "1bf05b47-b4e3-421b-a733-1cff53582818", "fields": {"password": "pbkdf2_sha256$36000$80X7Jk8wxsiI$DErHf832Y3dK9NwaX/fPqXwPVELjmpvIkZkPk/JaFBU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.613Z", "username": "deborah92", "name": "Ann Knight", "email": "jean@skaboo.info", "role": "Admin", "avatar": "", "wechat": "paul69", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Quisque arcu libero, rutrum ac, lobortis vel, dapibus at, diam.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.613Z", "created_by": "helen87", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "2400a442-7509-4f15-b998-3adae95236cb", "fields": {"password": "pbkdf2_sha256$36000$0JwwziwRnWNz$UUctXyvVOCnwdOlt5l9s44eWTtFTiDWwIulv+J9i+8c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.100Z", "username": "lisa94", "name": "Sandra Wells", "email": "rebecca@gigabox.biz", "role": "Admin", "avatar": "", "wechat": "patricia70", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin interdum mauris non ligula pellentesque ultrices.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.100Z", "created_by": "sandra90", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "254daec5-b5be-4ebc-9f91-b9cf694845db", "fields": {"password": "pbkdf2_sha256$36000$bIVONZZdpAcA$ZHNw+HzzVKCck8v1wGuwvWU2dXsYG8Pk3TsiKEZxbm0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.421Z", "username": "anna85", "name": "Doris Carr", "email": "sharon@zoonder.biz", "role": "App", "avatar": "", "wechat": "deborah94", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Donec quis orci eget orci vehicula condimentum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.422Z", "created_by": "margaret68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "28900216-560f-4bea-ba8d-b0806efb1cd3", "fields": {"password": "pbkdf2_sha256$36000$Z452ZHWkW0rO$cWb6IKyFlUNge+G9pjU/hIgxRG4pac6SqQ5KQU6WH8c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.834Z", "username": "mildred74", "name": "Barbara Evans", "email": "lillian@zoozzy.gov", "role": "Admin", "avatar": "", "wechat": "diane84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Quisque erat eros, viverra eget, congue eget, semper rutrum, nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.834Z", "created_by": "jane91", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "293bec40-fa3a-43c4-b4e5-b0df85818a93", "fields": {"password": "pbkdf2_sha256$36000$5nr48OR1SqlE$mRqb8SV1YjU0VehQl+KjpwbBBPZncWNDtY5vju46qb0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.746Z", "username": "marie94", "name": "Norma Turner", "email": "carol@demivee.info", "role": "Admin", "avatar": "", "wechat": "doris67", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Mauris ullamcorper purus sit amet nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.746Z", "created_by": "ruth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "2dbdca73-6145-42ee-84ba-fd62d61f3837", "fields": {"password": "pbkdf2_sha256$36000$n3NvgEK3TGPH$YlfKknOdBngsAtfQ866vTHR5rcnAqMPi+/ekTPz0gmM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.882Z", "username": "doris86", "name": "Helen Peterson", "email": "betty@skipstorm.info", "role": "Admin", "avatar": "", "wechat": "stephanie85", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi vel lectus in quam fringilla rhoncus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.882Z", "created_by": "amy74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "3a8ea16b-a521-4370-b5b1-94768fd0292b", "fields": {"password": "pbkdf2_sha256$36000$7lReZD1aqZ25$E021ZGjB2p9YPTQ3M2elMV7cBJrT4fexUybzOilEttg=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.039Z", "username": "elizabeth84", "name": "Elizabeth Wright", "email": "marie@midel.net", "role": "App", "avatar": "", "wechat": "doris72", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Cras pellentesque volutpat dui.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.039Z", "created_by": "cheryl74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "3b7ea257-76cd-4ac9-988d-2e633a819fcc", "fields": {"password": "pbkdf2_sha256$36000$XcVLJ00m76u4$kKbm0F47WAj++Xjhyv7SSuy6Qd5yYEWMfirLAcOtSj0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.952Z", "username": "helen87", "name": "Rachel Chavez", "email": "frances@shufflebeat.gov", "role": "App", "avatar": "", "wechat": "rebecca67", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Praesent id massa id nisl venenatis lacinia.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.952Z", "created_by": "katherine74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "3cc3641d-8a9a-47d0-bd2e-07a342ad25d1", "fields": {"password": "pbkdf2_sha256$36000$mE1B13oy3VqR$SLpFkzBYIUg+3snAua5n9qj51kDjpbYe8o7/cLpgc/Y=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.013Z", "username": "amanda67", "name": "Louise Hernandez", "email": "carol@thoughtstorm.name", "role": "User", "avatar": "", "wechat": "deborah66", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vestibulum quam sapien, varius ut, blandit non, interdum in, ante.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.013Z", "created_by": "margaret68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "3f285d25-1fb2-41aa-ad99-20aa9332053a", "fields": {"password": "pbkdf2_sha256$36000$HMffFit6jPUQ$n446iBJ1mxqijaUMtyFKyUNcT8af8mI/j3iKB/TFPrM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.147Z", "username": "lisa84", "name": "Norma Watkins", "email": "sarah@edgeclub.mil", "role": "App", "avatar": "", "wechat": "deborah87", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Aenean auctor gravida sem.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.147Z", "created_by": "denise86", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "3f58b94c-ae39-4f24-ab06-49ecda9ed96b", "fields": {"password": "pbkdf2_sha256$36000$GZQxdWAAfpLM$PSzrA2VNWpJ41zhK67Rc0cp9XAN0MXPvMjdDzzkiWwY=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:44.998Z", "username": "gloria82", "name": "Marilyn Hansen", "email": "janice@meetz.gov", "role": "User", "avatar": "", "wechat": "mary71", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Sed sagittis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:44.999Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "43c468cf-ecc3-4d7b-b1fc-ff033a45f529", "fields": {"password": "pbkdf2_sha256$36000$FET05R16KsGU$30yYgWTJJ6g5gTaodnG8uFnwH0WlQNlrEXl6vrhVhmM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.547Z", "username": "sharon84", "name": "Brenda Hamilton", "email": "maria@twitterbeat.gov", "role": "User", "avatar": "", "wechat": "denise91", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi sem mauris, laoreet ut, rhoncus aliquet, pulvinar sed, nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.547Z", "created_by": "sarah64", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "46e736be-8937-47d1-8244-857106feff0b", "fields": {"password": "pbkdf2_sha256$36000$GQJtJua0fxpq$uZyJjo+MkO2tyHEwlr+ukbU9bLbxNjb1Z4KEK+1M4Ug=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.680Z", "username": "joan88", "name": "Kathryn Martinez", "email": "kathleen@miboo.biz", "role": "User", "avatar": "", "wechat": "bonnie94", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In quis justo.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.680Z", "created_by": "sandra90", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "4df1d5a9-9627-431c-a079-b880fd21323e", "fields": {"password": "pbkdf2_sha256$36000$0djue4WLyNAC$qexjZ5iUzUmRZrJjBSJ9F+49HbQ0YcXUujF0jB7KAwE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.561Z", "username": "marilyn69", "name": "Betty Spencer", "email": "heather@riffpedia.biz", "role": "User", "avatar": "", "wechat": "wanda67", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam varius.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.561Z", "created_by": "mary85", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "54d963e9-9712-435e-8d58-085fc6fc88b1", "fields": {"password": "pbkdf2_sha256$36000$cJDQogliyC6D$t4zTZasnmtp2XWrvg3WV4ztL0a3m7EZtVYPhIUPuz14=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.104Z", "username": "jennifer76", "name": "Diana Sanders", "email": "shirley@livez.net", "role": "Admin", "avatar": "", "wechat": "diana80", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Quisque id justo sit amet sapien dignissim vestibulum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.104Z", "created_by": "emily88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "5d130adc-4e26-4251-9175-818c65bea65f", "fields": {"password": "pbkdf2_sha256$36000$zklFW4UIlY5m$UfKnn+HTKfo1Luuqqh2TzPvh3hiolSBqEu8RRSCjEr0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.916Z", "username": "kathleen72", "name": "Norma Fuller", "email": "lori@camimbo.name", "role": "Admin", "avatar": "", "wechat": "deborah71", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam molestie nibh in lectus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.916Z", "created_by": "bonnie74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "61196f61-b30e-4533-b190-8ebf9cb2016c", "fields": {"password": "pbkdf2_sha256$36000$Txvk8KyVUqjC$NfTgG1B2HSoBgerUeqgpXiaVGFGqkaGBV3MwcUKiryY=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.153Z", "username": "alice65", "name": "Michelle Hicks", "email": "kimberly@leexo.edu", "role": "App", "avatar": "", "wechat": "doris81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In sagittis dui vel nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.153Z", "created_by": "doris73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "6508bcc6-1ca0-40d7-8feb-f0a371c26364", "fields": {"password": "pbkdf2_sha256$36000$3ULJd9tQzGv6$My0v36L+qhqP8J44ngW1FIwFUnCj3x5GzavMKW7rS7k=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.676Z", "username": "catherine91", "name": "Doris Willis", "email": "lisa@mymm.gov", "role": "Admin", "avatar": "", "wechat": "phyllis64", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Mauris ullamcorper purus sit amet nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.676Z", "created_by": "elizabeth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "658d9699-1f02-4237-ae63-f25337cd4c38", "fields": {"password": "pbkdf2_sha256$36000$3SD0C1qH16ej$ztF0l/soLgQm/dMPlOWxF+PQnAain/Oso7RViaGkMGU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.815Z", "username": "linda93", "name": "Lisa Palmer", "email": "denise@rhybox.com", "role": "Admin", "avatar": "", "wechat": "andrea94", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vestibulum ac est lacinia nisi venenatis tristique.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.815Z", "created_by": "doris86", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "67637b7f-1717-4f52-b07f-d8bdb4eeebdd", "fields": {"password": "pbkdf2_sha256$36000$KY3hpdOCLA9V$T1M618Ce/keRem5/+zu75WjBnJ43DbZqHXOqOqRnil4=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:44.822Z", "username": "jean73", "name": "Dorothy Walker", "email": "michael@feednation.mil", "role": "User", "avatar": "", "wechat": "cheryl67", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vestibulum quam sapien, varius ut, blandit non, interdum in, ante.", "is_first_login": false, "date_expired": "2087-11-20T08:20:44.822Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "6b9a5f80-1a91-4c4b-b088-003470c09959", "fields": {"password": "pbkdf2_sha256$36000$jXuvMOkXTKwn$Rg5hTIMvpDyv34NixRSvSYFzZpEiEqRLvIa6DdC7O+c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.234Z", "username": "mildred72", "name": "Kelly Ruiz", "email": "lisa@browsedrive.mil", "role": "App", "avatar": "", "wechat": "louise79", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Integer pede justo, lacinia eget, tincidunt eget, tempus vel, pede.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.234Z", "created_by": "denise86", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "6dfb5d80-e8cf-404e-84f5-e42a56421990", "fields": {"password": "pbkdf2_sha256$36000$pE7DY2lLRGVr$f20EcKdtPmSs2v9JTd/EICXZMaAuH4wEpHNtWee71NE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.054Z", "username": "rachel86", "name": "Barbara Foster", "email": "lori@devpoint.net", "role": "App", "avatar": "", "wechat": "cynthia75", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In tempor, turpis nec euismod scelerisque, quam turpis adipiscing lorem, vitae mattis nibh ligula nec sem.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.054Z", "created_by": "bobby67", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "6ef7f455-500c-4ad0-b813-235822d037fa", "fields": {"password": "pbkdf2_sha256$36000$JQ9Ng8CvX3qw$JFEAn3ThP05iaQet1L9mmsLYdO8sxXJ+WN5rn3wm11c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.222Z", "username": "kathryn81", "name": "Ruby Hawkins", "email": "tina@snaptags.info", "role": "Admin", "avatar": "", "wechat": "judith81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Duis at velit eu est congue elementum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.222Z", "created_by": "amanda67", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "74e8a737-6499-4411-bce0-6170e609dc4b", "fields": {"password": "pbkdf2_sha256$36000$DUDY3gC963EF$A0swyBoH4+/v892DUjZshnK8aq5y2hN21R/usqu345c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.560Z", "username": "shirley87", "name": "Ann Oliver", "email": "paula@quinu.name", "role": "User", "avatar": "", "wechat": "judith91", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nam ultrices, libero non mattis pulvinar, nulla pede ullamcorper augue, a suscipit nulla elit ac nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.560Z", "created_by": "nancy94", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "76b83bc0-122b-4f65-8613-d49728e4f7c0", "fields": {"password": "pbkdf2_sha256$36000$IjBHf1wVhrVr$CzuNfhwTM11SCWBKMUvPhRVLqvHD8sQGiMW+lueeEJE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.305Z", "username": "gloria75", "name": "Sarah Barnes", "email": "carol@tazzy.name", "role": "App", "avatar": "", "wechat": "jennifer72", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Maecenas ut massa quis augue luctus tincidunt.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.305Z", "created_by": "karen75", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "77d8bd16-a79d-46ab-b56b-1a2aeb2bb4e7", "fields": {"password": "pbkdf2_sha256$36000$e7dB98TLCYc0$njPZU/eJb79K8eQmYygA4ScIDudgz2D/w0gAqIEM6T8=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.598Z", "username": "robin65", "name": "Julie Brown", "email": "teresa@brightdog.info", "role": "User", "avatar": "", "wechat": "carolyn68", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Sed sagittis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.598Z", "created_by": "christine83", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "84690e31-6c78-43b4-af27-d004eeea72c8", "fields": {"password": "pbkdf2_sha256$36000$S2kN49YESsQo$dhOcKIR4dZsv17saaBG5L5A6+2bURHyYNZkYQXQlMYU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.481Z", "username": "deborah79", "name": "Janice Berry", "email": "sarah@fivechat.com", "role": "App", "avatar": "", "wechat": "denise74", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.481Z", "created_by": "jane94", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "84a8e881-8baa-4048-9c36-906cfd768a73", "fields": {"password": "pbkdf2_sha256$36000$C00pW8X6PWLQ$r+sm+WxJtFzMOzr7j20ee0jrvTg6fNFBfO44mMF0uTQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.283Z", "username": "angela93", "name": "Julia Snyder", "email": "elizabeth@meedoo.mil", "role": "User", "avatar": "", "wechat": "susan74", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Donec odio justo, sollicitudin ut, suscipit a, feugiat et, eros.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.283Z", "created_by": "wanda88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "893efcfd-83b4-4391-93e8-1a439e83a78e", "fields": {"password": "pbkdf2_sha256$36000$dZuppxeYK2Wn$4y6SCVkq3YMv01e01yPTYRFFcxiPK5Cs+LkPsDHJsug=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.427Z", "username": "katherine74", "name": "Christine Rogers", "email": "kimberly@innotype.gov", "role": "Admin", "avatar": "", "wechat": "cynthia81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Fusce congue, diam id ornare imperdiet, sapien urna pretium nisl, ut volutpat sapien arcu sed augue.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.427Z", "created_by": "melissa87", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "8ae47e89-b1aa-46c0-b889-f39ec7c9d524", "fields": {"password": "pbkdf2_sha256$36000$psKjG67S6RJ1$FTBpXPptZhxwa+MP1TOA+wxrSIEVPjKEqfMVRe7QC8o=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.172Z", "username": "michelle67", "name": "Laura Frazier", "email": "norma@demivee.name", "role": "User", "avatar": "", "wechat": "maria77", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vestibulum ac est lacinia nisi venenatis tristique.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.172Z", "created_by": "cynthia70", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "8f30a514-aade-4179-85be-dfde6fbf29ae", "fields": {"password": "pbkdf2_sha256$36000$FQX8iBKyklSD$/uXjllZXSbukeyPHQ6ANtqjkrxYwDdXx5fK8oCxiPbQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.088Z", "username": "andrea85", "name": "Cheryl Cooper", "email": "evelyn@babblestorm.net", "role": "User", "avatar": "", "wechat": "virginia75", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Lorem ipsum dolor sit amet, consectetuer adipiscing elit.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.088Z", "created_by": "wanda88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "900ad3c2-20ab-41c4-9073-0db26d9e7062", "fields": {"password": "pbkdf2_sha256$36000$Y2RhGz7QZ2iT$PuB1fTERaUcNKz0ALtgPafW8bMKYqN+SZVn6Hi6rbF4=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.417Z", "username": "sarah64", "name": "Brenda Robinson", "email": "tina@rhynoodle.gov", "role": "User", "avatar": "", "wechat": "kathy88", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam porttitor lacus at turpis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.417Z", "created_by": "katherine74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "95cdcde0-593a-4280-a954-1c66a064fdf2", "fields": {"password": "pbkdf2_sha256$36000$rzMzLpd6G1nO$TbNohXyfh4GiBV+hIiRiiOCzeDvshn0yFIQcw9mnqEk=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.948Z", "username": "stephanie64", "name": "Amanda Bradley", "email": "louise@shufflester.edu", "role": "Admin", "avatar": "", "wechat": "sharon84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nulla suscipit ligula in lacus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.948Z", "created_by": "kelly79", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "976db0b2-6471-4e74-83bb-22d1edf9d07a", "fields": {"password": "pbkdf2_sha256$36000$zUEvDDyaWk0h$VbDEFx9DJc2jAIAuo1D2GGuNKWK8bHjD8dZfGeYj5Y8=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.816Z", "username": "lisa75", "name": "Sandra Brooks", "email": "paula@flashdog.name", "role": "App", "avatar": "", "wechat": "betty65", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nulla justo.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.816Z", "created_by": "amy74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "988ed037-fbc7-49a5-8ed6-6ba21443adf9", "fields": {"password": "pbkdf2_sha256$36000$CzKIzoR8JKMg$AKw9eZo+svCzAo7328hgBAC9DS8jEPnky1xEGSchLGQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.764Z", "username": "theresa89", "name": "Elizabeth Jordan", "email": "ann@babbleopia.name", "role": "Admin", "avatar": "", "wechat": "martha68", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi vel lectus in quam fringilla rhoncus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.764Z", "created_by": "jean73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "997fb6db-5319-4831-a930-a03b584bf231", "fields": {"password": "pbkdf2_sha256$36000$QthLyekDYiUV$llkyfwgHXmpey8ItJwJZgGap11gkHr427eY2rH0lkIY=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.115Z", "username": "cheryl74", "name": "Nancy Rodriguez", "email": "judith@feedfish.edu", "role": "User", "avatar": "", "wechat": "louise85", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Donec semper sapien a libero.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.115Z", "created_by": "rachel86", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "9ac9786b-9b27-423a-8461-df8bb351517e", "fields": {"password": "pbkdf2_sha256$36000$72qCogFSa5tJ$ioBGLjf2/bpaGtztTtfg41Je4Xnc7IazJGLUCqsrc20=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.967Z", "username": "linda78", "name": "Irene Howell", "email": "lori@skajo.biz", "role": "Admin", "avatar": "", "wechat": "nancy87", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nunc purus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.967Z", "created_by": "deborah79", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "9ce5cb35-b73a-43df-8db3-b5b9da2cfb80", "fields": {"password": "pbkdf2_sha256$36000$MMWxi7JlGqpu$QOTCNcSkUtny58A1jR/8nZiA4Tn0O+yg7OlyRoBayvs=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.295Z", "username": "christine83", "name": "Alice Johnston", "email": "tina@ooba.biz", "role": "User", "avatar": "", "wechat": "tammy69", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Cras in purus eu magna vulputate luctus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.295Z", "created_by": "emily88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "9d96f826-82c8-48bb-8e66-41eacf413685", "fields": {"password": "pbkdf2_sha256$36000$kEus08UgzXZk$Ak5DWw0MvDPlv/dxZCj9Jeob+YzlbjUDba+VxUVy6qU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.604Z", "username": "amy74", "name": "Margaret Taylor", "email": "robin@rhyloo.edu", "role": "User", "avatar": "", "wechat": "martha79", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Maecenas tincidunt lacus at velit.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.604Z", "created_by": "betty87", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "9e0e7c8e-553b-456a-b094-fda19397e3c2", "fields": {"password": "pbkdf2_sha256$36000$bN66TMdazmSv$ZrtIdvydQKk0dzN7BvWg2tfZUWxN5eo7laoAOtjKOZw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.689Z", "username": "christine86", "name": "Ann Clark", "email": "debra@skivee.info", "role": "App", "avatar": "", "wechat": "kathleen85", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam porttitor lacus at turpis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.690Z", "created_by": "ruth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "a1fc1d65-0b93-431e-90d0-2ee614a85ac5", "fields": {"password": "pbkdf2_sha256$36000$HkM2ryYWSC45$4GmctDFRnDgAPL6g4kOUvPZCJ8PZbwHOEtezF/kfamw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.885Z", "username": "janice65", "name": "Anne Crawford", "email": "katherine@lazzy.edu", "role": "Admin", "avatar": "", "wechat": "judith91", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin eu mi.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.885Z", "created_by": "christine83", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "a7e872b9-3996-4472-86e6-360472786a01", "fields": {"password": "pbkdf2_sha256$36000$Wrqb3zlqjgJj$FafGjmmEhYQZuKNXbzhsSLUBfYLVhe+VsEyMvrJ5mqI=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.492Z", "username": "diane63", "name": "Kathryn Jordan", "email": "katherine@geba.edu", "role": "Admin", "avatar": "", "wechat": "carol74", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Aenean lectus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.492Z", "created_by": "kathryn81", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "a918e434-49de-4d8e-a31c-b579ce5caac4", "fields": {"password": "pbkdf2_sha256$36000$NUM8iFHKTJNj$DC2PKnWoflXTaDA4oWOffSANvBVbJ/UPH58/txeSQLc=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.492Z", "username": "cynthia75", "name": "Judith Diaz", "email": "heather@jabbersphere.com", "role": "Admin", "avatar": "", "wechat": "judith72", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In sagittis dui vel nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.492Z", "created_by": "marie94", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "a9ef8ad6-e8ff-4ff0-a52f-de9e60c7a538", "fields": {"password": "pbkdf2_sha256$36000$Y7SVa80wf4J2$Rg1aqJW1hDa7VVfL+kWHz/pyIq/0/ezTRwwYojBLE4M=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.410Z", "username": "tammy68", "name": "Laura Wood", "email": "julia@jaxspan.name", "role": "User", "avatar": "", "wechat": "irene65", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Lorem ipsum dolor sit amet, consectetuer adipiscing elit.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.410Z", "created_by": "michelle67", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "abbd32ac-f1a8-42df-8cf8-bdb33de6a422", "fields": {"password": "pbkdf2_sha256$36000$nSps6waft4W6$BEtvLVbNzNdLt8EdVwocfgYWkQqfAlYvm1wbCWd/rfs=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.899Z", "username": "catherine89", "name": "Tina Ray", "email": "linda@eare.edu", "role": "App", "avatar": "", "wechat": "bonnie66", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In hac habitasse platea dictumst.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.899Z", "created_by": "brenda85", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "adba40a0-d9e8-4f17-b61f-023f0efc5c71", "fields": {"password": "pbkdf2_sha256$36000$pE7q8btYLdBG$Li5n43ady+BPnogN9OyvMZP6H1WUcElhwDffY70iBjQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.622Z", "username": "jane94", "name": "Theresa Evans", "email": "janet@skilith.net", "role": "User", "avatar": "", "wechat": "jennifer72", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vivamus tortor.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.622Z", "created_by": "wanda88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "aeeff980-5eca-4348-82fd-b728edad73df", "fields": {"password": "pbkdf2_sha256$36000$2W6LZl4pLNz9$7sd1/teKLDGYCa19oJS030Y/kbP8TxYT68HXEjUN8Yw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.456Z", "username": "wanda88", "name": "Linda Edwards", "email": "kathy@dablist.com", "role": "Admin", "avatar": "", "wechat": "sarah85", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nulla mollis molestie lorem.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.456Z", "created_by": "doris73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "b1305e47-a5fd-4a96-9ad4-1b42e1ff02ab", "fields": {"password": "pbkdf2_sha256$36000$ispYVWEwhld1$fBI4sKsYg1kN1GxAcpPWo2akYpYr+e4ZHJTBr9GGwvg=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.964Z", "username": "wanda76", "name": "Linda Kennedy", "email": "diana@wikizz.com", "role": "Admin", "avatar": "", "wechat": "judith94", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Pellentesque eget nunc.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.964Z", "created_by": "cheryl74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "b6ba2c18-4c1d-4bfc-b797-7b08a0716510", "fields": {"password": "pbkdf2_sha256$36000$qjlVpHgp4L3N$3JBdqZn2lUQAEW2iDj6P8G8UPnGtEdGJfZUVhEMa14c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.363Z", "username": "deborah91", "name": "Patricia Kim", "email": "louise@skiptube.org", "role": "User", "avatar": "", "wechat": "christine89", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam sit amet turpis elementum ligula vehicula consequat.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.363Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "b85ef060-fe34-439e-9ba1-80830c6b1154", "fields": {"password": "pbkdf2_sha256$36000$vXYezntEBYrO$yxVQbywPPzS6X739/FXf7jn0mOf9OV9QWB2rl2GjOPQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.884Z", "username": "jane91", "name": "Amanda Ward", "email": "heather@vinder.com", "role": "User", "avatar": "", "wechat": "jacqueline88", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Aenean fermentum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.884Z", "created_by": "kimberly76", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "b999c5a8-bf0c-4b75-a947-7d2ebefe937a", "fields": {"password": "pbkdf2_sha256$36000$5iE8awzRgDmB$CrXjLEN4I1GZiXpGlW6LL2etCUnpw2cHM+rp0HGfdKI=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.977Z", "username": "marilyn92", "name": "Margaret Cruz", "email": "denise@skimia.edu", "role": "Admin", "avatar": "", "wechat": "jean84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vivamus vel nulla eget eros elementum pellentesque.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.977Z", "created_by": "michelle67", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "bac381b9-bc3d-405f-8ec2-fe63e38cf642", "fields": {"password": "pbkdf2_sha256$36000$ieFjMrLRH9D9$fvgRX8vuyXPTrh8qe95OGt5UDPHj3a/H9OTjGH6N9YQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.478Z", "username": "bonnie74", "name": "Debra Crawford", "email": "maria@devshare.info", "role": "User", "avatar": "", "wechat": "mildred93", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Suspendisse potenti.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.478Z", "created_by": "cheryl74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "baf87b84-f58e-4f7e-8237-305fb031fb42", "fields": {"password": "pbkdf2_sha256$36000$x4p6j1gtzDyh$sKywBUyC1CYsJZU/4N48KfMdxACnYJw15h6gUfCsSPM=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.234Z", "username": "judith91", "name": "Andrea Diaz", "email": "lori@trilith.org", "role": "App", "avatar": "", "wechat": "pamela89", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Mauris enim leo, rhoncus sed, vestibulum sit amet, cursus id, turpis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.234Z", "created_by": "mary85", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "bd5c73f2-d42e-4def-b032-1dde457eff9f", "fields": {"password": "pbkdf2_sha256$36000$tiZlhQDhDmM2$UE+GwjLORRbWu6/5XAVXE0vhLzrtLE4TFOSNUudneoI=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.231Z", "username": "maria72", "name": "Sandra Owens", "email": "katherine@linkbuzz.com", "role": "App", "avatar": "", "wechat": "michelle66", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi porttitor lorem id ligula.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.231Z", "created_by": "anna68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "bf894606-81e4-4285-8f05-74a681b074e2", "fields": {"password": "pbkdf2_sha256$36000$3BnPvXORCEYA$wag/o7EnBJf+CR2W1byLqIAd56jAJKiKkn3pkpBL9XA=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.287Z", "username": "betty87", "name": "Lillian Barnes", "email": "anne@gabspot.gov", "role": "User", "avatar": "", "wechat": "jane84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nunc nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.287Z", "created_by": "cynthia70", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c23e3afa-42a0-4336-b57c-c8bfdde80e8c", "fields": {"password": "pbkdf2_sha256$36000$4NcioMUKB3nf$KgDvjCpDccUTk5U6AQG2OyM7YzM0pX27tyrg3lmIrSc=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.018Z", "username": "ruth67", "name": "Deborah Parker", "email": "katherine@riffpath.edu", "role": "Admin", "avatar": "", "wechat": "wanda74", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Duis bibendum, felis sed interdum venenatis, turpis enim blandit mi, in porttitor pede justo eu massa.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.018Z", "created_by": "jean73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c72887dd-2629-42ce-a781-719415dc2376", "fields": {"password": "pbkdf2_sha256$36000$Vl4z5b4ML07c$Fws7ChAspG1fhm5XYPoFaGPcx0phq+IImPj2PbA9OyI=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.950Z", "username": "diane88", "name": "Sara Burns", "email": "angela@ainyx.edu", "role": "Admin", "avatar": "", "wechat": "amanda65", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vivamus vestibulum sagittis sapien.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.950Z", "created_by": "sharon84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c759f080-d06a-4266-9626-2b76d98f274c", "fields": {"password": "pbkdf2_sha256$36000$Eyilxpy2FODw$uFy7ZheueWfuQnI7JIj7draAlHJas7SMXqbgQZN/JG4=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.792Z", "username": "anna68", "name": "Irene Andrews", "email": "brenda@dynabox.net", "role": "App", "avatar": "", "wechat": "amanda83", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nam dui.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.792Z", "created_by": "bonnie74", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c86f492a-7ba7-43cb-aa30-65217190056c", "fields": {"password": "pbkdf2_sha256$36000$lhH7D2Q9po5S$huBkHUy22xssZieRDnNuAZpIBIl/D+mEi0Z5OTp+qsk=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.820Z", "username": "nancy94", "name": "Linda Lynch", "email": "debra@yabox.biz", "role": "Admin", "avatar": "", "wechat": "carolyn81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nunc purus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.820Z", "created_by": "wanda88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c88eaa6a-0991-4bbf-accd-01639316b5b7", "fields": {"password": "pbkdf2_sha256$36000$Q0baEgcoCokf$QJUjraa4FX1lhOpPPcl8n9zMrFPV/PyNjdIZ+BkiXTA=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.230Z", "username": "phyllis92", "name": "Frances Wells", "email": "julia@vinte.name", "role": "User", "avatar": "", "wechat": "maria66", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi quis tortor id nulla ultrices aliquet.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.230Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "c9bd556f-5d95-40f7-b827-ce165a84a497", "fields": {"password": "pbkdf2_sha256$36000$aOKSaSe20zFK$De+cDQazS8vbI/K0E5emmD6PB5zqaaNfcuHlOG77UPE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:44.882Z", "username": "bobby67", "name": "Jane Perry", "email": "annie@jatri.gov", "role": "User", "avatar": "", "wechat": "stephanie78", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Donec posuere metus vitae ipsum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:44.882Z", "created_by": "jean73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "ca62a021-f557-4158-969a-b14aafc30a55", "fields": {"password": "pbkdf2_sha256$36000$baahuyfFqrof$Q3xb+dKNlJfwDoLc06QgIeTruvV4g0LsWX2w9T7HsPc=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.301Z", "username": "kelly79", "name": "Julia Moore", "email": "gloria@tagopia.info", "role": "User", "avatar": "", "wechat": "debra87", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Praesent lectus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.302Z", "created_by": "gloria82", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "cbd5fcae-728e-4fce-9cff-e21279475db8", "fields": {"password": "pbkdf2_sha256$36000$EsdCABCYFCmk$4PKD08PlCDFS+B/eIjEf0OUwWGEy8UTB/eErANceBRA=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.854Z", "username": "melissa87", "name": "Angela Wilson", "email": "sandra@brainverse.edu", "role": "App", "avatar": "", "wechat": "nancy89", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Aliquam erat volutpat.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.854Z", "created_by": "margaret68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "cc00cb90-3e2b-47ea-ac01-21a7c14b4010", "fields": {"password": "pbkdf2_sha256$36000$d4IV0ba51pDb$AoJIunbxHi83NLprK+cXuRohCvqKyjli2i7EGyE0MUU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.349Z", "username": "emily88", "name": "Laura Garcia", "email": "irene@trupe.com", "role": "App", "avatar": "", "wechat": "donna78", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "In hac habitasse platea dictumst.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.349Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "cc97024b-003d-4b10-8166-221a5a5c4ad4", "fields": {"password": "pbkdf2_sha256$36000$g4RAXiMBcQoq$UzocQ6FRPTSUs5NelpUMorVga29rHGMuEiGch2cRQtE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.627Z", "username": "brenda85", "name": "Linda Romero", "email": "sarah@gigabox.biz", "role": "User", "avatar": "", "wechat": "mildred66", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Maecenas rhoncus aliquam lacus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.628Z", "created_by": "anna85", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "ccdc9718-ca0a-4cf9-bc6f-0b3294db3dd0", "fields": {"password": "pbkdf2_sha256$36000$cFhZPJr62jYU$2IMi4Zmz0DUkOWrcM6mrTi9rZ5VDGFswjOxUmla/h9o=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.557Z", "username": "kimberly76", "name": "Catherine Griffin", "email": "betty@midel.net", "role": "User", "avatar": "", "wechat": "phyllis79", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Suspendisse accumsan tortor quis turpis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.557Z", "created_by": "emily88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "d0df0f52-e192-48e1-abdd-76599036db0d", "fields": {"password": "pbkdf2_sha256$36000$5CIt1BMId38U$DOUs3pzqsdLyNCU7n+JkhUyhbMNq10xDirEREHBTj0Q=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.166Z", "username": "brenda80", "name": "Teresa Crawford", "email": "jacqueline@wikizz.org", "role": "App", "avatar": "", "wechat": "debra93", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin risus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.166Z", "created_by": "melissa87", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "d3be688a-57ed-42c3-941c-bf64b337ff1a", "fields": {"password": "pbkdf2_sha256$36000$MKJYXuqE9zsA$+0LCYWZ2YDoEzcVIDiOhxKDtMdn1WHjzVeePh8v/EN0=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.164Z", "username": "doris73", "name": "Stephanie Stevens", "email": "lillian@chatterbridge.info", "role": "Admin", "avatar": "", "wechat": "ann83", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin at turpis a pede posuere nonummy.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.164Z", "created_by": "anna68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "dc98b1fe-814f-4aa4-b2ef-816d4dcd0cd8", "fields": {"password": "pbkdf2_sha256$36000$sTyK1iWh1Phq$shM3tDQxsHTkxmqa0V6L2ya59oCe4J9ybhpxqO96Rto=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.427Z", "username": "kimberly82", "name": "Jacqueline Greene", "email": "sandra@thoughtmix.org", "role": "App", "avatar": "", "wechat": "sarah63", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Duis faucibus accumsan odio.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.427Z", "created_by": "melissa79", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "ddf3ad0c-da0e-4c17-9700-b3280721c936", "fields": {"password": "pbkdf2_sha256$36000$7CEJewV0ogIh$0g9IgP/DVu3uZiEcrs8SLGcL+DOvKl5QujvDc8Fb4VA=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.090Z", "username": "ruth71", "name": "Norma Martinez", "email": "tina@skaboo.mil", "role": "Admin", "avatar": "", "wechat": "judy64", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Curabitur gravida nisi at nibh.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.090Z", "created_by": "wanda88", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "df237a5b-5c4d-43ea-ab81-de884bba2c59", "fields": {"password": "pbkdf2_sha256$36000$jGI2I4XD11MZ$9ESz8XB/fLX45r1Z92nLr1MKOx2atRIowtTP6S42ymU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.363Z", "username": "karen75", "name": "Wanda Kelley", "email": "donna@npath.gov", "role": "App", "avatar": "", "wechat": "cynthia63", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin risus.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.363Z", "created_by": "doris73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "df4c346e-2813-4e70-8b75-ae22c615c0d7", "fields": {"password": "pbkdf2_sha256$36000$cXwp6rlD0xcr$XlHVK8SKPUmek6w8RwiBiaTfXFvpaen9kh64Wc97C3I=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.495Z", "username": "rachel76", "name": "Heather Alvarez", "email": "katherine@kanoodle.name", "role": "Admin", "avatar": "", "wechat": "sarah84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Quisque porta volutpat erat.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.495Z", "created_by": "karen75", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "e00a494e-8a75-4a32-a3d4-8146d5943383", "fields": {"password": "pbkdf2_sha256$36000$DMD8RAEYTMni$XSXVQ7yHM+3YEpe8vtyMU37On9EBPkoQuD8W+SUzhOE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.352Z", "username": "joan86", "name": "Diane Moreno", "email": "andrea@feedmix.org", "role": "Admin", "avatar": "", "wechat": "nancy80", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Curabitur convallis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.352Z", "created_by": "gloria82", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "e2419c14-bad8-41c2-b0a6-6af0647d9861", "fields": {"password": "pbkdf2_sha256$36000$VG90MjpKpZq9$HD5qgv/+VCJWL9whQePuhOqGWvIk812WZoSE7Xw75lQ=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.623Z", "username": "sara67", "name": "Carol Harrison", "email": "judith@reallinks.mil", "role": "User", "avatar": "", "wechat": "louise74", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Sed sagittis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.623Z", "created_by": "brenda80", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "e2bb5ed2-7ef9-4645-841d-622e8600ba10", "fields": {"password": "pbkdf2_sha256$36000$pWyXKcODSv1S$BaJvNB0wGxH/2EivCZ98gx44uxM/pgwiNTy9n7vxQRE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.215Z", "username": "frances91", "name": "Sara Harrison", "email": "joan@teklist.net", "role": "Admin", "avatar": "", "wechat": "beverly90", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nulla mollis molestie lorem.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.215Z", "created_by": "janice65", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "e5c687d5-2287-483d-850a-49a2fc50fb62", "fields": {"password": "pbkdf2_sha256$36000$YZf2tNqNLcnO$sCkn27Co5bVcjxm9Vf4zBkYwOoXfDQoXDhYHjV8cPQA=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.368Z", "username": "christina73", "name": "Wanda Bradley", "email": "judith@jabbertype.gov", "role": "Admin", "avatar": "", "wechat": "diane84", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi quis tortor id nulla ultrices aliquet.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.368Z", "created_by": "judy68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "e8c3b8f8-fa07-4612-abc0-6027449da1e2", "fields": {"password": "pbkdf2_sha256$36000$eZ4yYmSXYUiS$iTM47iUrc9vMmO37bhmvNA4OlVZ2pKAOIHLWMB0pR4w=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:51.169Z", "username": "sarah87", "name": "Susan Fields", "email": "julie@gabtune.edu", "role": "Admin", "avatar": "", "wechat": "diane90", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam sit amet turpis elementum ligula vehicula consequat.", "is_first_login": false, "date_expired": "2087-11-20T08:20:51.170Z", "created_by": "admin", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "edc529d5-0377-4456-831f-ec42cf5b34d2", "fields": {"password": "pbkdf2_sha256$36000$3VcSL8Ap6zHd$14Y4+uZHRU8gwFgEXdIEZZ2+NWV15sRBV2YWgWbdyhY=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:09.494Z", "username": "admin", "name": "Administrator", "email": "admin@jumpserver.org", "role": "Admin", "avatar": "", "wechat": "", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Administrator is the super user of system", "is_first_login": false, "date_expired": "2087-11-20T08:20:09.494Z", "created_by": "System", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "ee6783eb-e28a-46de-af4d-5f141b5d00ff", "fields": {"password": "pbkdf2_sha256$36000$PE8tb0ELw96J$eVcNnYpmeItf5IxmQ6SzxyE37WgY+sCTsxKuNrswqfw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.696Z", "username": "jennifer88", "name": "Frances Lawson", "email": "brenda@twitterwire.biz", "role": "User", "avatar": "", "wechat": "helen80", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi a ipsum.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.696Z", "created_by": "ruth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "eec71fff-0071-4540-abd7-c04e5f4c1253", "fields": {"password": "pbkdf2_sha256$36000$sRs2tOHUXeOf$Sv08+zpL65DatVkLKvmFQzXuuetmD/8VTFJEvDoT074=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.667Z", "username": "theresa73", "name": "Ruby Wilson", "email": "michelle@centimia.mil", "role": "App", "avatar": "", "wechat": "judy63", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Suspendisse potenti.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.667Z", "created_by": "phyllis92", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "eee9d142-acf6-47c0-ac34-753b8fe6a79a", "fields": {"password": "pbkdf2_sha256$36000$PDgyhClJSgk5$54bSRv/LASscHDwEaa21531m3mWKU6gnI1Q/r2v2tZw=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.361Z", "username": "denise86", "name": "Teresa Anderson", "email": "norma@gevee.mil", "role": "App", "avatar": "", "wechat": "donna94", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Morbi sem mauris, laoreet ut, rhoncus aliquet, pulvinar sed, nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.361Z", "created_by": "elizabeth84", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "f5c41b9b-506f-425e-a2ba-7e671888e6be", "fields": {"password": "pbkdf2_sha256$36000$3pLuPgNpQKcf$oMNe1NkI9JWnqQQQ3HGgwzGd5LPdsaApOimTxa1Dqp8=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:49.747Z", "username": "judith70", "name": "Paula Little", "email": "lori@feedspan.gov", "role": "Admin", "avatar": "", "wechat": "debra86", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Fusce congue, diam id ornare imperdiet, sapien urna pretium nisl, ut volutpat sapien arcu sed augue.", "is_first_login": false, "date_expired": "2087-11-20T08:20:49.747Z", "created_by": "rachel86", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "f6dcb401-6db4-4f35-b430-1e57bb042ab6", "fields": {"password": "pbkdf2_sha256$36000$ERbzYcpezZ1B$CuvGMj7LhEcVaNouIi3nocUEzbpL1RVLvAQZH8vLLhE=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:45.540Z", "username": "margaret68", "name": "Rachel White", "email": "wanda@edgeclub.com", "role": "App", "avatar": "", "wechat": "rebecca67", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nam nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:45.540Z", "created_by": "jean73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "f921ca32-0cfe-4e42-8c94-7d6b3625d402", "fields": {"password": "pbkdf2_sha256$36000$qn44GrsBcawS$YYlPQrCcHV1YblGlt3rqHC6dU16VhDd8HcWu3hH+g6I=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:46.528Z", "username": "ruth84", "name": "Stephanie Lopez", "email": "heather@gigazoom.info", "role": "User", "avatar": "", "wechat": "melissa83", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Ut at dolor quis odio consequat varius.", "is_first_login": false, "date_expired": "2087-11-20T08:20:46.528Z", "created_by": "margaret68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "f956dff0-53a4-4ece-a245-9e046e50abdc", "fields": {"password": "pbkdf2_sha256$36000$3MYJAB1Ck8xG$jhxDJGKJRbSskDKAv52OC4U9WjcizaLArpMHFAnv1Dk=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:50.156Z", "username": "judy68", "name": "Laura Evans", "email": "deborah@feedfire.edu", "role": "App", "avatar": "", "wechat": "rose81", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Vivamus metus arcu, adipiscing molestie, hendrerit at, vulputate vitae, nisl.", "is_first_login": false, "date_expired": "2087-11-20T08:20:50.156Z", "created_by": "anna68", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "fc46c58e-b3e4-49ce-baed-cd316dc8f5cb", "fields": {"password": "pbkdf2_sha256$36000$BDLiryRYnwLq$IUnDvbsiAJPtLosybtjZ7GGPNV8UlFhlZfyN87nb7Qs=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.754Z", "username": "margaret94", "name": "Irene Phillips", "email": "pamela@quimm.com", "role": "App", "avatar": "", "wechat": "bonnie73", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Proin leo odio, porttitor id, consequat in, consequat ut, nulla.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.754Z", "created_by": "michelle67", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "fc50d1b3-e794-4ada-9380-72d74f232a24", "fields": {"password": "pbkdf2_sha256$36000$vg4IGE06ODw4$an5eZ5ffmXbTfWWjW+lLNgmmL6I2Lb5t0hA86+8cf9c=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:47.094Z", "username": "stephanie79", "name": "Tina Cook", "email": "mary@aimbo.name", "role": "App", "avatar": "", "wechat": "joyce91", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Ut at dolor quis odio consequat varius.", "is_first_login": false, "date_expired": "2087-11-20T08:20:47.095Z", "created_by": "doris73", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}, {"model": "users.user", "pk": "fe868e28-5c1d-4c79-b56b-7631b6c7793f", "fields": {"password": "pbkdf2_sha256$36000$0PVjqtfrlrJt$xmJUXi2oK8NpDtFTmnF6V38FvB8AFU9kaK2KkH5kx1I=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-07T08:20:48.285Z", "username": "melissa79", "name": "Jessica Morris", "email": "maria@divape.name", "role": "App", "avatar": "", "wechat": "ruth89", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Nullam orci pede, venenatis non, sodales sed, tincidunt eu, felis.", "is_first_login": false, "date_expired": "2087-11-20T08:20:48.286Z", "created_by": "jane94", "user_permissions": [], "groups": ["2e0b2a25-b32f-44a0-b087-f0f17de66e26"]}}] \ No newline at end of file diff --git a/apps/fixtures/init.json b/apps/fixtures/init.json deleted file mode 100644 index 802c2e85d..000000000 --- a/apps/fixtures/init.json +++ /dev/null @@ -1 +0,0 @@ -[{"model": "users.usergroup", "pk": "f3c6b021-59a9-43e7-b022-c2e9bfac84d7", "fields": {"is_discard": false, "discard_time": null, "name": "Default", "comment": "Default user group", "date_created": "2017-12-12T08:13:20.906Z", "created_by": "System"}}, {"model": "users.loginlog", "pk": "328c7d0f-214d-4665-8c7b-f3063718530e", "fields": {"username": "admin", "type": "ST", "ip": "127.0.0.1", "city": "Unknown", "user_agent": "", "datetime": "2017-12-12T08:10:28.973Z"}}, {"model": "users.loginlog", "pk": "a72fa02e-3b2c-40a0-8cb1-0c2f98d8f248", "fields": {"username": "admin", "type": "ST", "ip": "127.0.0.1", "city": "Unknown", "user_agent": "", "datetime": "2017-12-12T08:10:28.980Z"}}, {"model": "assets.cluster", "pk": "a950b8aa-073b-45ab-b72e-5bdfbb614653", "fields": {"name": "Default", "admin_user": null, "bandwidth": "", "contact": "", "phone": "", "address": "", "intranet": "", "extranet": "", "date_created": "2017-12-12T08:13:20.919Z", "operator": "", "created_by": "System", "comment": "Default Cluster"}}, {"model": "assets.assetgroup", "pk": "d742a7be-faf1-4c29-ae0a-e6aa640ab395", "fields": {"name": "Default", "created_by": "", "date_created": "2017-12-12T08:13:20.923Z", "comment": "Default asset group"}}, {"model": "captcha.captchastore", "pk": 1, "fields": {"challenge": "EQEI", "response": "eqei", "hashkey": "c993e8e245252eb8ca40a57c67a63ee9c61dce5c", "expiration": "2017-12-12T08:17:50.235Z"}}, {"model": "users.user", "pk": "61c39c1f-5b57-4268-8180-b6dda235aadd", "fields": {"password": "pbkdf2_sha256$36000$yhYWUEo4DNqj$SpxtdIOm9nwRG+X76jUUlGvdDcLaMBl7Z+rJ8sfSMcU=", "last_login": null, "first_name": "", "last_name": "", "is_active": true, "date_joined": "2017-12-12T08:13:20.827Z", "username": "admin", "name": "Administrator", "email": "admin@jumpserver.org", "role": "Admin", "avatar": "", "wechat": "", "phone": null, "enable_otp": false, "secret_key_otp": "", "_private_key": "", "_public_key": "", "comment": "Administrator is the super user of system", "is_first_login": false, "date_expired": "2087-11-25T08:13:20.827Z", "created_by": "System", "user_permissions": [], "groups": ["f3c6b021-59a9-43e7-b022-c2e9bfac84d7"]}}] \ No newline at end of file diff --git a/apps/jumpserver/conf.py b/apps/jumpserver/conf.py index 757af26fe..ee6dcdbfd 100644 --- a/apps/jumpserver/conf.py +++ b/apps/jumpserver/conf.py @@ -193,7 +193,7 @@ class Config(dict): if self.root_path: filename = os.path.join(self.root_path, filename) try: - with open(filename) as f: + with open(filename, 'rt', encoding='utf8') as f: obj = yaml.load(f) except IOError as e: if silent and e.errno in (errno.ENOENT, errno.EISDIR): @@ -268,25 +268,36 @@ class Config(dict): rv[key] = v return rv + def convert_type(self, k, v): + default_value = self.defaults.get(k) + if default_value is None: + return v + tp = type(default_value) + try: + v = tp(v) + except Exception: + pass + return v + def __repr__(self): return '<%s %s>' % (self.__class__.__name__, dict.__repr__(self)) def __getitem__(self, item): + # 先从设置的来 try: value = super().__getitem__(item) except KeyError: value = None if value is not None: - return value + return self.convert_type(item, value) + # 其次从环境变量来 value = os.environ.get(item, None) if value is not None: - if value.isdigit(): - value = int(value) - elif value.lower() == 'false': + if value.lower() == 'false': value = False elif value.lower() == 'true': value = True - return value + return self.convert_type(item, value) return self.defaults.get(item) def __getattr__(self, item): @@ -311,6 +322,7 @@ defaults = { 'REDIS_PASSWORD': '', 'REDIS_DB_CELERY': 3, 'REDIS_DB_CACHE': 4, + 'REDIS_DB_SESSION': 5, 'CAPTCHA_TEST_MODE': None, 'TOKEN_EXPIRATION': 3600 * 24, 'DISPLAY_PER_PAGE': 25, @@ -347,6 +359,8 @@ defaults = { 'RADIUS_SECRET': '', 'HTTP_BIND_HOST': '0.0.0.0', 'HTTP_LISTEN_PORT': 8080, + 'LOGIN_LOG_KEEP_DAYS': 90, + 'ASSETS_PERM_CACHE_TIME': 3600, } diff --git a/apps/jumpserver/error_views.py b/apps/jumpserver/error_views.py new file mode 100644 index 000000000..0d154d52b --- /dev/null +++ b/apps/jumpserver/error_views.py @@ -0,0 +1,20 @@ +# -*- coding: utf-8 -*- +# +from django.shortcuts import render +from django.http import JsonResponse + + +def handler404(request, *args, **argv): + if request.content_type.find('application/json') > -1: + response = JsonResponse({'error': 'Not found'}, status=404) + else: + response = render(request, '404.html', status=404) + return response + + +def handler500(request, *args, **argv): + if request.content_type.find('application/json') > -1: + response = JsonResponse({'error': 'Server internal error'}, status=500) + else: + response = render(request, '500.html', status=500) + return response diff --git a/apps/jumpserver/settings.py b/apps/jumpserver/settings.py index 43bc3cc1a..02e48c3c4 100644 --- a/apps/jumpserver/settings.py +++ b/apps/jumpserver/settings.py @@ -22,6 +22,10 @@ from .conf import load_user_config # Build paths inside the project like this: os.path.join(BASE_DIR, ...) BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__))) PROJECT_DIR = os.path.dirname(BASE_DIR) +sys.path.append(PROJECT_DIR) +from apps import __version__ + +VERSION = __version__ CONFIG = load_user_config() LOG_DIR = os.path.join(PROJECT_DIR, 'logs') JUMPSERVER_LOG_FILE = os.path.join(LOG_DIR, 'jumpserver.log') @@ -59,6 +63,7 @@ INSTALLED_APPS = [ 'assets.apps.AssetsConfig', 'perms.apps.PermsConfig', 'ops.apps.OpsConfig', + 'settings.apps.SettingsConfig', 'common.apps.CommonConfig', 'terminal.apps.TerminalConfig', 'audits.apps.AuditsConfig', @@ -99,7 +104,7 @@ MIDDLEWARE = [ 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', - 'authentication.openid.middleware.OpenIDAuthenticationMiddleware', # openid + 'authentication.backends.openid.middleware.OpenIDAuthenticationMiddleware', 'jumpserver.middleware.TimezoneMiddleware', 'jumpserver.middleware.DemoMiddleware', 'jumpserver.middleware.RequestMiddleware', @@ -134,17 +139,28 @@ TEMPLATES = [ # WSGI_APPLICATION = 'jumpserver.wsgi.applications' LOGIN_REDIRECT_URL = reverse_lazy('index') -LOGIN_URL = reverse_lazy('users:login') +LOGIN_URL = reverse_lazy('authentication:login') SESSION_COOKIE_DOMAIN = CONFIG.SESSION_COOKIE_DOMAIN CSRF_COOKIE_DOMAIN = CONFIG.CSRF_COOKIE_DOMAIN SESSION_COOKIE_AGE = CONFIG.SESSION_COOKIE_AGE SESSION_EXPIRE_AT_BROWSER_CLOSE = CONFIG.SESSION_EXPIRE_AT_BROWSER_CLOSE +SESSION_ENGINE = 'redis_sessions.session' +SESSION_REDIS = { + 'host': CONFIG.REDIS_HOST, + 'port': CONFIG.REDIS_PORT, + 'password': CONFIG.REDIS_PASSWORD, + 'db': CONFIG.REDIS_DB_SESSION, + 'prefix': 'auth_session', + 'socket_timeout': 1, + 'retry_on_timeout': False +} MESSAGE_STORAGE = 'django.contrib.messages.storage.cookie.CookieStorage' # Database # https://docs.djangoproject.com/en/1.10/ref/settings/#databases +DB_OPTIONS = {} DATABASES = { 'default': { 'ENGINE': 'django.db.backends.{}'.format(CONFIG.DB_ENGINE), @@ -154,8 +170,13 @@ DATABASES = { 'USER': CONFIG.DB_USER, 'PASSWORD': CONFIG.DB_PASSWORD, 'ATOMIC_REQUESTS': True, + 'OPTIONS': DB_OPTIONS } } +DB_CA_PATH = os.path.join(PROJECT_DIR, 'data', 'ca.pem') +if CONFIG.DB_ENGINE == 'mysql' and os.path.isfile(DB_CA_PATH): + DB_OPTIONS['ssl'] = {'ca': DB_CA_PATH} + # Password validation # https://docs.djangoproject.com/en/1.10/ref/settings/#auth-password-validators @@ -342,10 +363,10 @@ REST_FRAMEWORK = { ), 'DEFAULT_AUTHENTICATION_CLASSES': ( # 'rest_framework.authentication.BasicAuthentication', - 'users.authentication.AccessKeyAuthentication', - 'users.authentication.AccessTokenAuthentication', - 'users.authentication.PrivateTokenAuthentication', - 'users.authentication.SessionAuthentication', + 'authentication.backends.api.AccessKeyAuthentication', + 'authentication.backends.api.AccessTokenAuthentication', + 'authentication.backends.api.PrivateTokenAuthentication', + 'authentication.backends.api.SessionAuthentication', ), 'DEFAULT_FILTER_BACKENDS': ( 'django_filters.rest_framework.DjangoFilterBackend', @@ -394,7 +415,7 @@ AUTH_LDAP_CONNECTION_OPTIONS = { } AUTH_LDAP_GROUP_CACHE_TIMEOUT = 1 AUTH_LDAP_ALWAYS_UPDATE_USER = True -AUTH_LDAP_BACKEND = 'authentication.ldap.backends.LDAPAuthorizationBackend' +AUTH_LDAP_BACKEND = 'authentication.backends.ldap.LDAPAuthorizationBackend' if AUTH_LDAP: AUTHENTICATION_BACKENDS.insert(0, AUTH_LDAP_BACKEND) @@ -408,18 +429,19 @@ AUTH_OPENID_REALM_NAME = CONFIG.AUTH_OPENID_REALM_NAME AUTH_OPENID_CLIENT_ID = CONFIG.AUTH_OPENID_CLIENT_ID AUTH_OPENID_CLIENT_SECRET = CONFIG.AUTH_OPENID_CLIENT_SECRET AUTH_OPENID_BACKENDS = [ - 'authentication.openid.backends.OpenIDAuthorizationPasswordBackend', - 'authentication.openid.backends.OpenIDAuthorizationCodeBackend', + 'authentication.backends.openid.backends.OpenIDAuthorizationPasswordBackend', + 'authentication.backends.openid.backends.OpenIDAuthorizationCodeBackend', ] if AUTH_OPENID: - LOGIN_URL = reverse_lazy("authentication:openid-login") + LOGIN_URL = reverse_lazy("authentication:openid:openid-login") + LOGIN_COMPLETE_URL = reverse_lazy("authentication:openid:openid-login-complete") AUTHENTICATION_BACKENDS.insert(0, AUTH_OPENID_BACKENDS[0]) AUTHENTICATION_BACKENDS.insert(0, AUTH_OPENID_BACKENDS[1]) # Radius Auth AUTH_RADIUS = CONFIG.AUTH_RADIUS -AUTH_RADIUS_BACKEND = 'authentication.radius.backends.RadiusBackend' +AUTH_RADIUS_BACKEND = 'authentication.backends.radius.RadiusBackend' RADIUS_SERVER = CONFIG.RADIUS_SERVER RADIUS_PORT = CONFIG.RADIUS_PORT RADIUS_SECRET = CONFIG.RADIUS_SECRET @@ -444,8 +466,8 @@ CELERY_ACCEPT_CONTENT = ['json', 'pickle'] CELERY_RESULT_EXPIRES = 3600 # CELERY_WORKER_LOG_FORMAT = '%(asctime)s [%(module)s %(levelname)s] %(message)s' # CELERY_WORKER_LOG_FORMAT = '%(message)s' -CELERY_WORKER_TASK_LOG_FORMAT = '%(task_id)s %(task_name)s %(message)s' -# CELERY_WORKER_TASK_LOG_FORMAT = '%(message)s' +# CELERY_WORKER_TASK_LOG_FORMAT = '%(task_id)s %(task_name)s %(message)s' +CELERY_WORKER_TASK_LOG_FORMAT = '%(message)s' # CELERY_WORKER_LOG_FORMAT = '%(asctime)s [%(module)s %(levelname)s] %(message)s' CELERY_WORKER_LOG_FORMAT = '%(message)s' CELERY_TASK_EAGER_PROPAGATES = True @@ -526,6 +548,7 @@ TERMINAL_ASSET_LIST_PAGE_SIZE = CONFIG.TERMINAL_ASSET_LIST_PAGE_SIZE TERMINAL_SESSION_KEEP_DURATION = CONFIG.TERMINAL_SESSION_KEEP_DURATION TERMINAL_HOST_KEY = CONFIG.TERMINAL_HOST_KEY TERMINAL_HEADER_TITLE = CONFIG.TERMINAL_HEADER_TITLE +TERMINAL_TELNET_REGEX = CONFIG.TERMINAL_TELNET_REGEX # Django bootstrap3 setting, more see http://django-bootstrap3.readthedocs.io/en/latest/settings.html BOOTSTRAP3 = { @@ -555,4 +578,10 @@ SWAGGER_SETTINGS = { # Default email suffix EMAIL_SUFFIX = CONFIG.EMAIL_SUFFIX -TERMINAL_TELNET_REGEX = CONFIG.TERMINAL_TELNET_REGEX +LOGIN_LOG_KEEP_DAYS = CONFIG.LOGIN_LOG_KEEP_DAYS + +# User or user group permission cache time, default 3600 seconds +ASSETS_PERM_CACHE_TIME = CONFIG.ASSETS_PERM_CACHE_TIME + +# Asset user auth external backend, default AuthBook backend +BACKEND_ASSET_USER_AUTH_VAULT = False diff --git a/apps/jumpserver/urls.py b/apps/jumpserver/urls.py index 8ddf5cae4..5ef225828 100644 --- a/apps/jumpserver/urls.py +++ b/apps/jumpserver/urls.py @@ -10,27 +10,24 @@ from django.views.i18n import JavaScriptCatalog from .views import IndexView, LunaView, I18NView from .swagger import get_swagger_view - -api_v1_patterns = [ - path('api/', include([ - path('users/v1/', include('users.urls.api_urls', namespace='api-users')), - path('assets/v1/', include('assets.urls.api_urls', namespace='api-assets')), - path('perms/v1/', include('perms.urls.api_urls', namespace='api-perms')), - path('terminal/v1/', include('terminal.urls.api_urls', namespace='api-terminal')), - path('ops/v1/', include('ops.urls.api_urls', namespace='api-ops')), - path('audits/v1/', include('audits.urls.api_urls', namespace='api-audits')), - path('orgs/v1/', include('orgs.urls.api_urls', namespace='api-orgs')), - path('common/v1/', include('common.urls.api_urls', namespace='api-common')), - ])) +api_v1 = [ + path('users/v1/', include('users.urls.api_urls', namespace='api-users')), + path('assets/v1/', include('assets.urls.api_urls', namespace='api-assets')), + path('perms/v1/', include('perms.urls.api_urls', namespace='api-perms')), + path('terminal/v1/', include('terminal.urls.api_urls', namespace='api-terminal')), + path('ops/v1/', include('ops.urls.api_urls', namespace='api-ops')), + path('audits/v1/', include('audits.urls.api_urls', namespace='api-audits')), + path('orgs/v1/', include('orgs.urls.api_urls', namespace='api-orgs')), + path('settings/v1/', include('settings.urls.api_urls', namespace='api-settings')), + path('authentication/v1/', include('authentication.urls.api_urls', namespace='api-auth')), ] -api_v2_patterns = [ - path('api/', include([ - path('terminal/v2/', include('terminal.urls.api_urls_v2', namespace='api-terminal-v2')), - path('users/v2/', include('users.urls.api_urls_v2', namespace='api-users-v2')), - ])) +api_v2 = [ + path('terminal/v2/', include('terminal.urls.api_urls_v2', namespace='api-terminal-v2')), + path('users/v2/', include('users.urls.api_urls_v2', namespace='api-users-v2')), ] + app_view_patterns = [ path('users/', include('users.urls.views_urls', namespace='users')), path('assets/', include('assets.urls.views_urls', namespace='assets')), @@ -44,30 +41,42 @@ app_view_patterns = [ if settings.XPACK_ENABLED: - app_view_patterns.append(path('xpack/', include('xpack.urls', namespace='xpack'))) + app_view_patterns.append(path('xpack/', include('xpack.urls.view_urls', namespace='xpack'))) + api_v1.append(path('xpack/v1/', include('xpack.urls.api_urls', namespace='api-xpack'))) js_i18n_patterns = i18n_patterns( path('jsi18n/', JavaScriptCatalog.as_view(), name='javascript-catalog'), ) +api_v1_patterns = [ + path('api/', include(api_v1)) +] + +api_v2_patterns = [ + path('api/', include(api_v2)) +] + urlpatterns = [ path('', IndexView.as_view(), name='index'), path('', include(api_v2_patterns)), path('', include(api_v1_patterns)), - path('luna/', LunaView.as_view(), name='luna-error'), + path('luna/', LunaView.as_view(), name='luna-view'), path('i18n//', I18NView.as_view(), name='i18n-switch'), - path('settings/', include('common.urls.view_urls', namespace='settings')), - path('common/', include('common.urls.view_urls', namespace='common')), + path('settings/', include('settings.urls.view_urls', namespace='settings')), # path('api/v2/', include(api_v2_patterns)), # External apps url path('captcha/', include('captcha.urls')), ] + urlpatterns += app_view_patterns urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT) \ + static(settings.STATIC_URL, document_root=settings.STATIC_ROOT) urlpatterns += js_i18n_patterns +handler404 = 'jumpserver.error_views.handler404' +handler500 = 'jumpserver.error_views.handler500' + if settings.DEBUG: urlpatterns += [ re_path('^swagger(?P\.json|\.yaml)$', diff --git a/apps/locale/zh/LC_MESSAGES/django.mo b/apps/locale/zh/LC_MESSAGES/django.mo index a9d91262d..7196bfa06 100644 Binary files a/apps/locale/zh/LC_MESSAGES/django.mo and b/apps/locale/zh/LC_MESSAGES/django.mo differ diff --git a/apps/locale/zh/LC_MESSAGES/django.po b/apps/locale/zh/LC_MESSAGES/django.po index 6f20978fb..9c40a44b2 100644 --- a/apps/locale/zh/LC_MESSAGES/django.po +++ b/apps/locale/zh/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: Jumpserver 0.3.3\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2019-02-21 19:23+0800\n" +"POT-Creation-Date: 2019-03-22 17:12+0800\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: ibuler \n" "Language-Team: Jumpserver team\n" @@ -30,49 +30,52 @@ msgid "Test if the assets under the node are connectable: {}" msgstr "测试节点下资产是否可连接: {}" #: assets/forms/asset.py:27 assets/models/asset.py:80 assets/models/user.py:133 -#: assets/templates/assets/asset_detail.html:191 -#: assets/templates/assets/asset_detail.html:199 -#: assets/templates/assets/system_user_asset.html:95 perms/models.py:32 +#: assets/templates/assets/asset_detail.html:194 +#: assets/templates/assets/asset_detail.html:202 +#: assets/templates/assets/system_user_asset.html:95 perms/models.py:31 +#: xpack/plugins/change_auth_plan/models.py:69 msgid "Nodes" msgstr "节点管理" -#: assets/forms/asset.py:30 assets/forms/asset.py:66 assets/forms/asset.py:105 -#: assets/forms/asset.py:109 assets/models/asset.py:84 +#: assets/forms/asset.py:30 assets/forms/asset.py:66 assets/models/asset.py:84 #: assets/models/cluster.py:19 assets/models/user.py:91 -#: assets/templates/assets/asset_detail.html:77 templates/_nav.html:24 +#: assets/templates/assets/asset_detail.html:80 templates/_nav.html:24 #: xpack/plugins/cloud/models.py:124 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:67 #: xpack/plugins/orgs/templates/orgs/org_list.html:18 msgid "Admin user" msgstr "管理用户" -#: assets/forms/asset.py:33 assets/forms/asset.py:69 assets/forms/asset.py:121 +#: assets/forms/asset.py:33 assets/forms/asset.py:69 assets/forms/asset.py:109 #: assets/templates/assets/asset_create.html:36 #: assets/templates/assets/asset_create.html:38 #: assets/templates/assets/asset_list.html:81 #: assets/templates/assets/asset_update.html:41 #: assets/templates/assets/asset_update.html:43 -#: assets/templates/assets/user_asset_list.html:34 +#: assets/templates/assets/user_asset_list.html:33 #: xpack/plugins/orgs/templates/orgs/org_list.html:20 msgid "Label" msgstr "标签" #: assets/forms/asset.py:37 assets/forms/asset.py:73 assets/models/asset.py:79 #: assets/models/domain.py:26 assets/models/domain.py:52 -#: assets/templates/assets/asset_detail.html:81 -#: assets/templates/assets/user_asset_list.html:157 +#: assets/templates/assets/asset_detail.html:84 +#: assets/templates/assets/user_asset_list.html:169 #: xpack/plugins/orgs/templates/orgs/org_list.html:17 msgid "Domain" msgstr "网域" #: assets/forms/asset.py:41 assets/forms/asset.py:63 assets/forms/asset.py:77 -#: assets/forms/asset.py:124 assets/models/node.py:31 +#: assets/forms/asset.py:112 assets/models/node.py:31 #: assets/templates/assets/asset_create.html:30 #: assets/templates/assets/asset_update.html:35 perms/forms.py:45 -#: perms/forms.py:52 perms/models.py:85 +#: perms/forms.py:52 perms/models.py:84 #: perms/templates/perms/asset_permission_list.html:57 #: perms/templates/perms/asset_permission_list.html:78 #: perms/templates/perms/asset_permission_list.html:128 +#: xpack/plugins/change_auth_plan/forms.py:101 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:55 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:15 #: xpack/plugins/cloud/models.py:123 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:63 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:66 @@ -99,28 +102,21 @@ msgstr "如果有多个的互相隔离的网络,设置资产属于的网域, #: assets/forms/asset.py:92 assets/forms/asset.py:96 assets/forms/domain.py:17 #: assets/forms/label.py:15 #: perms/templates/perms/asset_permission_asset.html:88 +#: xpack/plugins/change_auth_plan/forms.py:92 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:84 msgid "Select assets" msgstr "选择资产" -#: assets/forms/asset.py:101 assets/models/asset.py:77 -#: assets/models/domain.py:50 assets/templates/assets/admin_user_assets.html:50 -#: assets/templates/assets/asset_detail.html:69 -#: assets/templates/assets/domain_gateway_list.html:58 -#: assets/templates/assets/system_user_asset.html:52 -#: assets/templates/assets/user_asset_list.html:152 -#: common/templates/common/replay_storage_create.html:59 -msgid "Port" -msgstr "端口" - #: assets/forms/domain.py:15 assets/forms/label.py:13 -#: assets/models/asset.py:277 assets/templates/assets/admin_user_list.html:28 +#: assets/models/asset.py:279 assets/models/authbook.py:27 +#: assets/templates/assets/admin_user_list.html:28 #: assets/templates/assets/domain_detail.html:60 #: assets/templates/assets/domain_list.html:26 #: assets/templates/assets/label_list.html:16 -#: assets/templates/assets/system_user_list.html:33 audits/models.py:18 +#: assets/templates/assets/system_user_list.html:33 audits/models.py:19 #: audits/templates/audits/ftp_log_list.html:41 #: audits/templates/audits/ftp_log_list.html:71 perms/forms.py:42 -#: perms/models.py:31 +#: perms/models.py:30 #: perms/templates/perms/asset_permission_create_update.html:45 #: perms/templates/perms/asset_permission_list.html:56 #: perms/templates/perms/asset_permission_list.html:125 @@ -129,6 +125,12 @@ msgstr "端口" #: terminal/templates/terminal/command_list.html:73 #: terminal/templates/terminal/session_list.html:41 #: terminal/templates/terminal/session_list.html:72 +#: xpack/plugins/change_auth_plan/models.py:65 +#: xpack/plugins/change_auth_plan/models.py:401 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:40 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:54 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:13 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:14 #: xpack/plugins/cloud/models.py:187 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:65 #: xpack/plugins/orgs/templates/orgs/org_list.html:16 @@ -139,8 +141,12 @@ msgstr "资产" msgid "Password should not contain special characters" msgstr "不能包含特殊字符" -#: assets/forms/domain.py:70 assets/forms/user.py:80 assets/forms/user.py:142 -#: assets/models/base.py:22 assets/models/cluster.py:18 +#: assets/forms/domain.py:70 +msgid "SSH gateway support proxy SSH,RDP,VNC" +msgstr "SSH网关,支持代理SSH,RDP和VNC" + +#: assets/forms/domain.py:73 assets/forms/user.py:84 assets/forms/user.py:146 +#: assets/models/base.py:26 assets/models/cluster.py:18 #: assets/models/cmd_filter.py:20 assets/models/domain.py:20 #: assets/models/group.py:20 assets/models/label.py:18 #: assets/templates/assets/admin_user_detail.html:56 @@ -148,30 +154,35 @@ msgstr "不能包含特殊字符" #: assets/templates/assets/cmd_filter_detail.html:61 #: assets/templates/assets/cmd_filter_list.html:24 #: assets/templates/assets/domain_detail.html:56 -#: assets/templates/assets/domain_gateway_list.html:56 +#: assets/templates/assets/domain_gateway_list.html:67 #: assets/templates/assets/domain_list.html:25 #: assets/templates/assets/label_list.html:14 #: assets/templates/assets/system_user_detail.html:58 -#: assets/templates/assets/system_user_list.html:29 common/models.py:29 -#: common/templates/common/command_storage_create.html:41 -#: common/templates/common/replay_storage_create.html:44 -#: common/templates/common/terminal_setting.html:80 -#: common/templates/common/terminal_setting.html:102 ops/models/adhoc.py:37 -#: ops/templates/ops/task_detail.html:60 ops/templates/ops/task_list.html:35 -#: orgs/models.py:12 perms/models.py:28 +#: assets/templates/assets/system_user_list.html:29 ops/models/adhoc.py:37 +#: ops/templates/ops/task_detail.html:60 ops/templates/ops/task_list.html:27 +#: orgs/models.py:12 perms/models.py:27 #: perms/templates/perms/asset_permission_detail.html:62 #: perms/templates/perms/asset_permission_list.html:53 #: perms/templates/perms/asset_permission_list.html:72 -#: perms/templates/perms/asset_permission_user.html:54 terminal/models.py:22 -#: terminal/models.py:233 terminal/templates/terminal/terminal_detail.html:43 +#: perms/templates/perms/asset_permission_user.html:54 settings/models.py:29 +#: settings/templates/settings/_ldap_list_users_modal.html:35 +#: settings/templates/settings/command_storage_create.html:41 +#: settings/templates/settings/replay_storage_create.html:44 +#: settings/templates/settings/terminal_setting.html:80 +#: settings/templates/settings/terminal_setting.html:102 terminal/models.py:22 +#: terminal/models.py:241 terminal/templates/terminal/terminal_detail.html:43 #: terminal/templates/terminal/terminal_list.html:29 users/models/group.py:14 -#: users/models/user.py:55 users/templates/users/_select_user_modal.html:13 +#: users/models/user.py:54 users/templates/users/_select_user_modal.html:13 #: users/templates/users/user_detail.html:63 #: users/templates/users/user_group_detail.html:55 #: users/templates/users/user_group_list.html:12 #: users/templates/users/user_list.html:23 #: users/templates/users/user_profile.html:51 #: users/templates/users/user_pubkey_update.html:53 +#: xpack/plugins/change_auth_plan/forms.py:84 +#: xpack/plugins/change_auth_plan/models.py:58 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:61 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:12 #: xpack/plugins/cloud/models.py:49 xpack/plugins/cloud/models.py:119 #: xpack/plugins/cloud/templates/cloud/account_detail.html:52 #: xpack/plugins/cloud/templates/cloud/account_list.html:12 @@ -182,18 +193,21 @@ msgstr "不能包含特殊字符" msgid "Name" msgstr "名称" -#: assets/forms/domain.py:71 assets/forms/user.py:81 assets/forms/user.py:143 -#: assets/models/base.py:23 assets/templates/assets/admin_user_detail.html:60 +#: assets/forms/domain.py:74 assets/forms/user.py:85 assets/forms/user.py:147 +#: assets/models/base.py:27 +#: assets/templates/assets/_asset_user_auth_modal.html:15 +#: assets/templates/assets/admin_user_detail.html:60 #: assets/templates/assets/admin_user_list.html:27 -#: assets/templates/assets/domain_gateway_list.html:60 +#: assets/templates/assets/asset_asset_user_list.html:48 +#: assets/templates/assets/domain_gateway_list.html:71 #: assets/templates/assets/system_user_detail.html:62 -#: assets/templates/assets/system_user_list.html:30 -#: audits/templates/audits/login_log_list.html:49 -#: perms/templates/perms/asset_permission_list.html:74 -#: perms/templates/perms/asset_permission_user.html:55 users/forms.py:15 -#: users/forms.py:33 users/models/authentication.py:77 users/models/user.py:53 -#: users/templates/users/_select_user_modal.html:14 -#: users/templates/users/login.html:64 users/templates/users/new_login.html:85 +#: assets/templates/assets/system_user_list.html:30 audits/models.py:94 +#: audits/templates/audits/login_log_list.html:51 authentication/forms.py:11 +#: ops/models/adhoc.py:164 perms/templates/perms/asset_permission_list.html:74 +#: perms/templates/perms/asset_permission_user.html:55 +#: settings/templates/settings/_ldap_list_users_modal.html:34 users/forms.py:13 +#: users/models/user.py:52 users/templates/users/_select_user_modal.html:14 +#: users/templates/users/login.html:64 users/templates/users/new_login.html:110 #: users/templates/users/user_detail.html:67 #: users/templates/users/user_list.html:24 #: users/templates/users/user_profile.html:47 @@ -204,9 +218,12 @@ msgstr "用户名" msgid "Password or private key passphrase" msgstr "密码或密钥密码" -#: assets/forms/user.py:26 assets/models/base.py:24 common/forms.py:102 -#: users/forms.py:17 users/forms.py:35 users/forms.py:47 -#: users/templates/users/login.html:67 users/templates/users/new_login.html:90 +#: assets/forms/user.py:26 assets/models/base.py:28 +#: assets/serializers/asset_user.py:19 +#: assets/templates/assets/_asset_user_auth_modal.html:21 +#: authentication/forms.py:13 settings/forms.py:103 users/forms.py:15 +#: users/forms.py:27 users/templates/users/login.html:67 +#: users/templates/users/new_login.html:113 #: users/templates/users/reset_password.html:53 #: users/templates/users/user_create.html:10 #: users/templates/users/user_password_authentication.html:18 @@ -214,36 +231,39 @@ msgstr "密码或密钥密码" #: users/templates/users/user_profile_update.html:40 #: users/templates/users/user_pubkey_update.html:40 #: users/templates/users/user_update.html:20 +#: xpack/plugins/change_auth_plan/models.py:90 +#: xpack/plugins/change_auth_plan/models.py:252 msgid "Password" msgstr "密码" -#: assets/forms/user.py:29 users/models/user.py:82 +#: assets/forms/user.py:29 assets/serializers/asset_user.py:27 +#: users/models/user.py:81 msgid "Private key" msgstr "ssh私钥" -#: assets/forms/user.py:39 -msgid "Invalid private key" -msgstr "ssh密钥不合法" +#: assets/forms/user.py:41 +msgid "Invalid private key, Only support RSA/DSA format key" +msgstr "不合法的密钥,仅支持RSA/DSA格式的密钥" -#: assets/forms/user.py:48 +#: assets/forms/user.py:52 msgid "Password and private key file must be input one" msgstr "密码和私钥, 必须输入一个" -#: assets/forms/user.py:130 +#: assets/forms/user.py:134 msgid "* Automatic login mode must fill in the username." msgstr "自动登录模式,必须填写用户名" -#: assets/forms/user.py:145 assets/models/cmd_filter.py:31 +#: assets/forms/user.py:149 assets/models/cmd_filter.py:31 #: assets/models/user.py:141 assets/templates/assets/_system_user.html:66 #: assets/templates/assets/system_user_detail.html:165 msgid "Command filter" msgstr "命令过滤器" -#: assets/forms/user.py:149 +#: assets/forms/user.py:153 msgid "Auto push system user to asset" msgstr "自动推送系统用户到资产" -#: assets/forms/user.py:150 +#: assets/forms/user.py:154 msgid "" "1-100, High level will be using login asset as default, if user was granted " "more than 2 system user" @@ -251,81 +271,98 @@ msgstr "" "1-100, 1最低优先级,100最高优先级。授权多个用户时,高优先级的系统用户将会作为" "默认登录用户" -#: assets/forms/user.py:152 +#: assets/forms/user.py:156 msgid "" "If you choose manual login mode, you do not need to fill in the username and " "password." msgstr "如果选择手动登录模式,用户名和密码可以不填写" +#: assets/forms/user.py:158 +msgid "Use comma split multi command, ex: /bin/whoami,/bin/ifconfig" +msgstr "使用逗号分隔多个命令,如: /bin/whoami,/sbin/ifconfig" + #: assets/models/asset.py:74 assets/models/domain.py:49 #: assets/templates/assets/_asset_list_modal.html:46 #: assets/templates/assets/admin_user_assets.html:49 -#: assets/templates/assets/asset_detail.html:61 +#: assets/templates/assets/asset_detail.html:64 #: assets/templates/assets/asset_list.html:93 -#: assets/templates/assets/domain_gateway_list.html:57 +#: assets/templates/assets/domain_gateway_list.html:68 #: assets/templates/assets/system_user_asset.html:51 -#: assets/templates/assets/user_asset_list.html:46 -#: assets/templates/assets/user_asset_list.html:151 -#: audits/templates/audits/login_log_list.html:52 common/forms.py:131 -#: perms/templates/perms/asset_permission_asset.html:55 +#: assets/templates/assets/user_asset_list.html:45 +#: assets/templates/assets/user_asset_list.html:163 +#: audits/templates/audits/login_log_list.html:54 +#: perms/templates/perms/asset_permission_asset.html:55 settings/forms.py:133 #: users/templates/users/user_granted_asset.html:45 #: users/templates/users/user_group_granted_asset.html:45 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:51 msgid "IP" msgstr "IP" #: assets/models/asset.py:75 assets/templates/assets/_asset_list_modal.html:45 +#: assets/templates/assets/_asset_user_auth_modal.html:9 #: assets/templates/assets/admin_user_assets.html:48 -#: assets/templates/assets/asset_detail.html:57 +#: assets/templates/assets/asset_detail.html:60 #: assets/templates/assets/asset_list.html:92 #: assets/templates/assets/system_user_asset.html:50 -#: assets/templates/assets/user_asset_list.html:45 -#: assets/templates/assets/user_asset_list.html:150 common/forms.py:130 +#: assets/templates/assets/user_asset_list.html:44 +#: assets/templates/assets/user_asset_list.html:162 #: perms/templates/perms/asset_permission_asset.html:54 -#: perms/templates/perms/asset_permission_list.html:77 +#: perms/templates/perms/asset_permission_list.html:77 settings/forms.py:132 #: users/templates/users/user_granted_asset.html:44 #: users/templates/users/user_group_granted_asset.html:44 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:50 msgid "Hostname" msgstr "主机名" #: assets/models/asset.py:76 assets/models/domain.py:51 -#: assets/models/user.py:136 assets/templates/assets/asset_detail.html:73 -#: assets/templates/assets/domain_gateway_list.html:59 +#: assets/models/user.py:136 assets/templates/assets/asset_detail.html:76 +#: assets/templates/assets/domain_gateway_list.html:70 #: assets/templates/assets/system_user_detail.html:70 #: assets/templates/assets/system_user_list.html:31 -#: assets/templates/assets/user_asset_list.html:153 +#: assets/templates/assets/user_asset_list.html:165 #: terminal/templates/terminal/session_list.html:75 msgid "Protocol" msgstr "协议" -#: assets/models/asset.py:78 assets/templates/assets/asset_detail.html:105 -#: assets/templates/assets/user_asset_list.html:154 +#: assets/models/asset.py:77 assets/models/domain.py:50 +#: assets/templates/assets/admin_user_assets.html:50 +#: assets/templates/assets/asset_detail.html:72 +#: assets/templates/assets/domain_gateway_list.html:69 +#: assets/templates/assets/system_user_asset.html:52 +#: assets/templates/assets/user_asset_list.html:164 +#: settings/templates/settings/replay_storage_create.html:59 +msgid "Port" +msgstr "端口" + +#: assets/models/asset.py:78 assets/templates/assets/asset_detail.html:108 +#: assets/templates/assets/user_asset_list.html:166 msgid "Platform" msgstr "系统平台" #: assets/models/asset.py:81 assets/models/cmd_filter.py:21 #: assets/models/domain.py:54 assets/models/label.py:22 -#: assets/templates/assets/asset_detail.html:113 -#: assets/templates/assets/user_asset_list.html:158 +#: assets/templates/assets/asset_detail.html:116 +#: assets/templates/assets/user_asset_list.html:170 msgid "Is active" msgstr "激活" -#: assets/models/asset.py:87 assets/templates/assets/asset_detail.html:65 +#: assets/models/asset.py:87 assets/templates/assets/asset_detail.html:68 msgid "Public IP" msgstr "公网IP" -#: assets/models/asset.py:88 assets/templates/assets/asset_detail.html:121 +#: assets/models/asset.py:88 assets/templates/assets/asset_detail.html:124 msgid "Asset number" msgstr "资产编号" -#: assets/models/asset.py:91 assets/templates/assets/asset_detail.html:85 +#: assets/models/asset.py:91 assets/templates/assets/asset_detail.html:88 msgid "Vendor" msgstr "制造商" -#: assets/models/asset.py:92 assets/templates/assets/asset_detail.html:89 +#: assets/models/asset.py:92 assets/templates/assets/asset_detail.html:92 msgid "Model" msgstr "型号" -#: assets/models/asset.py:93 assets/templates/assets/asset_detail.html:117 +#: assets/models/asset.py:93 assets/templates/assets/asset_detail.html:120 msgid "Serial number" msgstr "序列号" @@ -334,6 +371,7 @@ msgid "CPU model" msgstr "CPU型号" #: assets/models/asset.py:96 +#: xpack/plugins/license/templates/license/license_detail.html:71 msgid "CPU count" msgstr "CPU数量" @@ -345,7 +383,7 @@ msgstr "CPU核数" msgid "CPU vcpus" msgstr "CPU总数" -#: assets/models/asset.py:99 assets/templates/assets/asset_detail.html:97 +#: assets/models/asset.py:99 assets/templates/assets/asset_detail.html:100 msgid "Memory" msgstr "内存" @@ -357,8 +395,8 @@ msgstr "硬盘大小" msgid "Disk info" msgstr "硬盘信息" -#: assets/models/asset.py:103 assets/templates/assets/asset_detail.html:109 -#: assets/templates/assets/user_asset_list.html:155 +#: assets/models/asset.py:103 assets/templates/assets/asset_detail.html:112 +#: assets/templates/assets/user_asset_list.html:167 msgid "OS" msgstr "操作系统" @@ -375,22 +413,24 @@ msgid "Hostname raw" msgstr "主机名原始" #: assets/models/asset.py:108 assets/templates/assets/asset_create.html:34 -#: assets/templates/assets/asset_detail.html:228 +#: assets/templates/assets/asset_detail.html:231 #: assets/templates/assets/asset_update.html:39 templates/_nav.html:26 msgid "Labels" msgstr "标签管理" -#: assets/models/asset.py:109 assets/models/base.py:30 +#: assets/models/asset.py:109 assets/models/base.py:34 #: assets/models/cluster.py:28 assets/models/cmd_filter.py:25 #: assets/models/cmd_filter.py:58 assets/models/group.py:21 #: assets/templates/assets/admin_user_detail.html:68 -#: assets/templates/assets/asset_detail.html:125 +#: assets/templates/assets/asset_detail.html:128 #: assets/templates/assets/cmd_filter_detail.html:77 #: assets/templates/assets/domain_detail.html:72 #: assets/templates/assets/system_user_detail.html:100 -#: ops/templates/ops/adhoc_detail.html:86 orgs/models.py:15 perms/models.py:37 -#: perms/models.py:90 perms/templates/perms/asset_permission_detail.html:98 -#: users/models/user.py:96 users/templates/users/user_detail.html:111 +#: ops/templates/ops/adhoc_detail.html:86 orgs/models.py:15 perms/models.py:36 +#: perms/models.py:89 perms/templates/perms/asset_permission_detail.html:98 +#: users/models/user.py:95 users/templates/users/user_detail.html:111 +#: xpack/plugins/change_auth_plan/models.py:103 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:113 #: xpack/plugins/cloud/models.py:55 xpack/plugins/cloud/models.py:127 msgid "Created by" msgstr "创建者" @@ -402,10 +442,11 @@ msgstr "创建者" #: assets/templates/assets/domain_detail.html:68 #: assets/templates/assets/system_user_detail.html:96 #: ops/templates/ops/adhoc_detail.html:90 ops/templates/ops/task_detail.html:64 -#: orgs/models.py:16 perms/models.py:38 perms/models.py:91 +#: orgs/models.py:16 perms/models.py:37 perms/models.py:90 #: perms/templates/perms/asset_permission_detail.html:94 #: terminal/templates/terminal/terminal_detail.html:59 users/models/group.py:17 #: users/templates/users/user_group_detail.html:63 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:105 #: xpack/plugins/cloud/models.py:56 xpack/plugins/cloud/models.py:128 #: xpack/plugins/cloud/templates/cloud/account_detail.html:68 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:79 @@ -413,31 +454,34 @@ msgstr "创建者" msgid "Date created" msgstr "创建日期" -#: assets/models/asset.py:111 assets/models/base.py:27 +#: assets/models/asset.py:111 assets/models/base.py:31 #: assets/models/cluster.py:29 assets/models/cmd_filter.py:22 #: assets/models/cmd_filter.py:55 assets/models/domain.py:21 #: assets/models/domain.py:53 assets/models/group.py:23 #: assets/models/label.py:23 assets/templates/assets/admin_user_detail.html:72 #: assets/templates/assets/admin_user_list.html:32 -#: assets/templates/assets/asset_detail.html:133 +#: assets/templates/assets/asset_detail.html:136 #: assets/templates/assets/cmd_filter_detail.html:65 #: assets/templates/assets/cmd_filter_list.html:27 #: assets/templates/assets/cmd_filter_rule_list.html:62 #: assets/templates/assets/domain_detail.html:76 -#: assets/templates/assets/domain_gateway_list.html:61 +#: assets/templates/assets/domain_gateway_list.html:72 #: assets/templates/assets/domain_list.html:28 #: assets/templates/assets/system_user_detail.html:104 #: assets/templates/assets/system_user_list.html:37 -#: assets/templates/assets/user_asset_list.html:159 common/models.py:34 -#: ops/models/adhoc.py:43 orgs/models.py:17 perms/models.py:39 -#: perms/models.py:92 perms/templates/perms/asset_permission_detail.html:102 +#: assets/templates/assets/user_asset_list.html:171 ops/models/adhoc.py:43 +#: orgs/models.py:17 perms/models.py:38 perms/models.py:91 +#: perms/templates/perms/asset_permission_detail.html:102 settings/models.py:34 #: terminal/models.py:32 terminal/templates/terminal/terminal_detail.html:63 -#: users/models/group.py:15 users/models/user.py:88 +#: users/models/group.py:15 users/models/user.py:87 #: users/templates/users/user_detail.html:127 #: users/templates/users/user_group_detail.html:67 #: users/templates/users/user_group_list.html:14 -#: users/templates/users/user_profile.html:134 xpack/plugins/cloud/models.py:54 -#: xpack/plugins/cloud/models.py:125 +#: users/templates/users/user_profile.html:134 +#: xpack/plugins/change_auth_plan/models.py:99 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:117 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:19 +#: xpack/plugins/cloud/models.py:54 xpack/plugins/cloud/models.py:125 #: xpack/plugins/cloud/templates/cloud/account_detail.html:72 #: xpack/plugins/cloud/templates/cloud/account_list.html:15 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:71 @@ -447,15 +491,16 @@ msgstr "创建日期" msgid "Comment" msgstr "备注" -#: assets/models/asset.py:117 assets/models/base.py:34 +#: assets/models/asset.py:117 assets/models/base.py:38 #: assets/templates/assets/admin_user_list.html:30 #: assets/templates/assets/system_user_list.html:35 msgid "Unreachable" msgstr "不可达" -#: assets/models/asset.py:118 assets/models/base.py:35 +#: assets/models/asset.py:118 assets/models/base.py:39 #: assets/templates/assets/admin_user_assets.html:51 #: assets/templates/assets/admin_user_list.html:29 +#: assets/templates/assets/asset_asset_user_list.html:50 #: assets/templates/assets/asset_list.html:95 #: assets/templates/assets/system_user_asset.html:53 #: assets/templates/assets/system_user_list.html:34 @@ -463,16 +508,34 @@ msgstr "不可达" msgid "Reachable" msgstr "可连接" -#: assets/models/asset.py:119 assets/models/base.py:36 -#: xpack/plugins/license/models.py:78 +#: assets/models/asset.py:119 assets/models/base.py:40 +#: authentication/utils.py:9 xpack/plugins/license/models.py:78 msgid "Unknown" msgstr "未知" -#: assets/models/base.py:25 +#: assets/models/authbook.py:28 ops/templates/ops/task_detail.html:72 +msgid "Latest version" +msgstr "最新版本" + +#: assets/models/authbook.py:29 +#: assets/templates/assets/asset_asset_user_list.html:49 +#: ops/templates/ops/adhoc_history.html:58 +#: ops/templates/ops/adhoc_history_detail.html:57 +#: ops/templates/ops/task_adhoc.html:58 ops/templates/ops/task_history.html:64 +msgid "Version" +msgstr "版本" + +#: assets/models/authbook.py:34 +msgid "AuthBook" +msgstr "" + +#: assets/models/base.py:29 xpack/plugins/change_auth_plan/models.py:94 +#: xpack/plugins/change_auth_plan/models.py:259 msgid "SSH private key" msgstr "ssh密钥" -#: assets/models/base.py:26 +#: assets/models/base.py:30 xpack/plugins/change_auth_plan/models.py:97 +#: xpack/plugins/change_auth_plan/models.py:255 msgid "SSH public key" msgstr "ssh公钥" @@ -484,7 +547,7 @@ msgstr "带宽" msgid "Contact" msgstr "联系人" -#: assets/models/cluster.py:22 users/models/user.py:74 +#: assets/models/cluster.py:22 users/models/user.py:73 #: users/templates/users/user_detail.html:76 msgid "Phone" msgstr "手机" @@ -510,7 +573,7 @@ msgid "Default" msgstr "默认" #: assets/models/cluster.py:36 assets/models/label.py:14 -#: users/models/user.py:441 +#: users/models/user.py:457 msgid "System" msgstr "系统" @@ -539,7 +602,7 @@ msgid "Regex" msgstr "正则表达式" #: assets/models/cmd_filter.py:39 ops/models/command.py:21 -#: ops/templates/ops/command_execution_list.html:60 terminal/models.py:161 +#: ops/templates/ops/command_execution_list.html:61 terminal/models.py:161 #: terminal/templates/terminal/command_list.html:55 #: terminal/templates/terminal/command_list.html:71 #: terminal/templates/terminal/session_detail.html:48 @@ -561,11 +624,11 @@ msgstr "过滤器" #: assets/models/cmd_filter.py:50 #: assets/templates/assets/cmd_filter_rule_list.html:58 -#: audits/templates/audits/login_log_list.html:50 -#: common/templates/common/command_storage_create.html:31 -#: common/templates/common/replay_storage_create.html:31 -#: common/templates/common/terminal_setting.html:81 -#: common/templates/common/terminal_setting.html:103 +#: audits/templates/audits/login_log_list.html:52 +#: settings/templates/settings/command_storage_create.html:31 +#: settings/templates/settings/replay_storage_create.html:31 +#: settings/templates/settings/terminal_setting.html:81 +#: settings/templates/settings/terminal_setting.html:103 msgid "Type" msgstr "类型" @@ -591,25 +654,30 @@ msgstr "每行一个命令" #: assets/models/cmd_filter.py:54 #: assets/templates/assets/admin_user_assets.html:52 #: assets/templates/assets/admin_user_list.html:33 +#: assets/templates/assets/asset_asset_user_list.html:52 #: assets/templates/assets/asset_list.html:96 #: assets/templates/assets/cmd_filter_list.html:28 #: assets/templates/assets/cmd_filter_rule_list.html:63 -#: assets/templates/assets/domain_gateway_list.html:62 +#: assets/templates/assets/domain_gateway_list.html:73 #: assets/templates/assets/domain_list.html:29 #: assets/templates/assets/label_list.html:17 #: assets/templates/assets/system_user_asset.html:54 -#: assets/templates/assets/system_user_list.html:38 audits/models.py:37 +#: assets/templates/assets/system_user_list.html:38 +#: assets/templates/assets/user_asset_list.html:48 audits/models.py:38 #: audits/templates/audits/operate_log_list.html:41 #: audits/templates/audits/operate_log_list.html:67 -#: common/templates/common/terminal_setting.html:82 -#: common/templates/common/terminal_setting.html:104 #: ops/templates/ops/adhoc_history.html:59 ops/templates/ops/task_adhoc.html:64 -#: ops/templates/ops/task_history.html:65 ops/templates/ops/task_list.html:42 +#: ops/templates/ops/task_history.html:65 ops/templates/ops/task_list.html:34 #: perms/templates/perms/asset_permission_list.html:60 +#: settings/templates/settings/terminal_setting.html:82 +#: settings/templates/settings/terminal_setting.html:104 #: terminal/templates/terminal/session_list.html:81 #: terminal/templates/terminal/terminal_list.html:36 #: users/templates/users/user_group_list.html:15 #: users/templates/users/user_list.html:29 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:60 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:18 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:20 #: xpack/plugins/cloud/templates/cloud/account_list.html:16 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_list.html:18 #: xpack/plugins/orgs/templates/orgs/org_list.html:23 @@ -622,7 +690,7 @@ msgstr "命令过滤规则" #: assets/models/domain.py:61 assets/templates/assets/domain_detail.html:21 #: assets/templates/assets/domain_detail.html:64 -#: assets/templates/assets/domain_gateway_list.html:21 +#: assets/templates/assets/domain_gateway_list.html:26 #: assets/templates/assets/domain_list.html:27 msgid "Gateway" msgstr "网关" @@ -635,16 +703,16 @@ msgstr "资产组" msgid "Default asset group" msgstr "默认资产组" -#: assets/models/label.py:15 audits/models.py:16 audits/models.py:36 -#: audits/models.py:49 audits/templates/audits/ftp_log_list.html:33 +#: assets/models/label.py:15 audits/models.py:17 audits/models.py:37 +#: audits/models.py:50 audits/templates/audits/ftp_log_list.html:33 #: audits/templates/audits/ftp_log_list.html:70 #: audits/templates/audits/operate_log_list.html:33 #: audits/templates/audits/operate_log_list.html:66 #: audits/templates/audits/password_change_log_list.html:33 #: audits/templates/audits/password_change_log_list.html:50 -#: ops/templates/ops/command_execution_list.html:34 -#: ops/templates/ops/command_execution_list.html:59 perms/forms.py:36 -#: perms/models.py:29 +#: ops/templates/ops/command_execution_list.html:35 +#: ops/templates/ops/command_execution_list.html:60 perms/forms.py:36 +#: perms/models.py:28 #: perms/templates/perms/asset_permission_create_update.html:41 #: perms/templates/perms/asset_permission_list.html:54 #: perms/templates/perms/asset_permission_list.html:119 templates/index.html:87 @@ -652,8 +720,8 @@ msgstr "默认资产组" #: terminal/templates/terminal/command_list.html:32 #: terminal/templates/terminal/command_list.html:72 #: terminal/templates/terminal/session_list.html:33 -#: terminal/templates/terminal/session_list.html:71 users/forms.py:303 -#: users/models/user.py:33 users/models/user.py:429 +#: terminal/templates/terminal/session_list.html:71 users/forms.py:283 +#: users/models/user.py:32 users/models/user.py:445 #: users/templates/users/user_group_detail.html:78 #: users/templates/users/user_group_list.html:13 users/views/user.py:386 #: xpack/plugins/orgs/forms.py:26 @@ -663,7 +731,7 @@ msgid "User" msgstr "用户" #: assets/models/label.py:19 assets/models/node.py:21 -#: assets/templates/assets/label_list.html:15 common/models.py:30 +#: assets/templates/assets/label_list.html:15 settings/models.py:30 msgid "Value" msgstr "值" @@ -675,7 +743,7 @@ msgstr "分类" msgid "Key" msgstr "键" -#: assets/models/node.py:127 +#: assets/models/node.py:128 msgid "New node" msgstr "新节点" @@ -694,18 +762,19 @@ msgstr "手动登录" #: assets/views/admin_user.py:29 assets/views/admin_user.py:47 #: assets/views/admin_user.py:63 assets/views/admin_user.py:78 #: assets/views/admin_user.py:102 assets/views/asset.py:50 -#: assets/views/asset.py:89 assets/views/asset.py:133 assets/views/asset.py:150 -#: assets/views/asset.py:174 assets/views/cmd_filter.py:30 -#: assets/views/cmd_filter.py:46 assets/views/cmd_filter.py:62 -#: assets/views/cmd_filter.py:78 assets/views/cmd_filter.py:97 -#: assets/views/cmd_filter.py:130 assets/views/cmd_filter.py:163 -#: assets/views/domain.py:29 assets/views/domain.py:45 -#: assets/views/domain.py:61 assets/views/domain.py:74 -#: assets/views/domain.py:98 assets/views/domain.py:126 -#: assets/views/domain.py:145 assets/views/label.py:26 assets/views/label.py:43 -#: assets/views/label.py:69 assets/views/system_user.py:28 -#: assets/views/system_user.py:44 assets/views/system_user.py:60 -#: assets/views/system_user.py:74 templates/_nav.html:19 +#: assets/views/asset.py:66 assets/views/asset.py:103 assets/views/asset.py:147 +#: assets/views/asset.py:164 assets/views/asset.py:188 +#: assets/views/cmd_filter.py:30 assets/views/cmd_filter.py:46 +#: assets/views/cmd_filter.py:62 assets/views/cmd_filter.py:78 +#: assets/views/cmd_filter.py:97 assets/views/cmd_filter.py:130 +#: assets/views/cmd_filter.py:163 assets/views/domain.py:29 +#: assets/views/domain.py:45 assets/views/domain.py:61 +#: assets/views/domain.py:74 assets/views/domain.py:98 +#: assets/views/domain.py:126 assets/views/domain.py:145 +#: assets/views/label.py:26 assets/views/label.py:43 assets/views/label.py:69 +#: assets/views/system_user.py:28 assets/views/system_user.py:44 +#: assets/views/system_user.py:60 assets/views/system_user.py:74 +#: templates/_nav.html:19 msgid "Assets" msgstr "资产管理" @@ -728,10 +797,10 @@ msgstr "Shell" msgid "Login mode" msgstr "登录模式" -#: assets/models/user.py:247 assets/templates/assets/user_asset_list.html:156 -#: audits/models.py:19 audits/templates/audits/ftp_log_list.html:49 +#: assets/models/user.py:247 assets/templates/assets/user_asset_list.html:168 +#: audits/models.py:20 audits/templates/audits/ftp_log_list.html:49 #: audits/templates/audits/ftp_log_list.html:72 perms/forms.py:48 -#: perms/models.py:33 perms/models.py:87 +#: perms/models.py:32 perms/models.py:86 #: perms/templates/perms/asset_permission_detail.html:140 #: perms/templates/perms/asset_permission_list.html:58 #: perms/templates/perms/asset_permission_list.html:79 @@ -750,71 +819,84 @@ msgstr "系统用户" msgid "%(value)s is not an even number" msgstr "%(value)s is not an even number" -#: assets/tasks.py:33 +#: assets/serializers/asset_user.py:23 users/forms.py:230 +#: users/models/user.py:84 users/templates/users/first_login.html:42 +#: users/templates/users/user_password_update.html:46 +#: users/templates/users/user_profile.html:68 +#: users/templates/users/user_profile_update.html:43 +#: users/templates/users/user_pubkey_update.html:43 +msgid "Public key" +msgstr "ssh公钥" + +#: assets/tasks.py:31 msgid "Asset has been disabled, skipped: {}" msgstr "资产或许不支持ansible, 跳过: {}" -#: assets/tasks.py:37 +#: assets/tasks.py:35 msgid "Asset may not be support ansible, skipped: {}" msgstr "资产或许不支持ansible, 跳过: {}" -#: assets/tasks.py:42 +#: assets/tasks.py:48 msgid "No assets matched, stop task" msgstr "没有匹配到资产,结束任务" -#: assets/tasks.py:67 +#: assets/tasks.py:73 msgid "Get asset info failed: {}" msgstr "获取资产信息失败:{}" -#: assets/tasks.py:117 +#: assets/tasks.py:123 msgid "Update some assets hardware info" msgstr "更新资产硬件信息" -#: assets/tasks.py:134 +#: assets/tasks.py:140 msgid "Update asset hardware info: {}" msgstr "更新资产硬件信息: {}" -#: assets/tasks.py:159 +#: assets/tasks.py:165 msgid "Test assets connectivity" msgstr "测试资产可连接性" -#: assets/tasks.py:183 +#: assets/tasks.py:189 msgid "Test assets connectivity: {}" msgstr "测试资产可连接性: {}" -#: assets/tasks.py:225 +#: assets/tasks.py:231 msgid "Test admin user connectivity period: {}" msgstr "定期测试管理账号可连接性: {}" -#: assets/tasks.py:232 +#: assets/tasks.py:238 msgid "Test admin user connectivity: {}" msgstr "测试管理行号可连接性: {}" -#: assets/tasks.py:271 +#: assets/tasks.py:277 msgid "Test system user connectivity: {}" msgstr "测试系统用户可连接性: {}" -#: assets/tasks.py:278 +#: assets/tasks.py:284 msgid "Test system user connectivity: {} => {}" msgstr "测试系统用户可连接性: {} => {}" -#: assets/tasks.py:291 +#: assets/tasks.py:297 msgid "Test system user connectivity period: {}" msgstr "定期测试系统用户可连接性: {}" -#: assets/tasks.py:363 +#: assets/tasks.py:374 msgid "" "Push system user task skip, auto push not enable or protocol is not ssh: {}" msgstr "推送系统用户任务跳过,自动推送没有打开,或协议不是ssh: {}" -#: assets/tasks.py:383 assets/tasks.py:397 +#: assets/tasks.py:396 assets/tasks.py:410 msgid "Push system users to assets: {}" msgstr "推送系统用户到入资产: {}" -#: assets/tasks.py:389 +#: assets/tasks.py:402 msgid "Push system users to asset: {} => {}" msgstr "推送系统用户到入资产: {} => {}" +#: assets/tasks.py:459 +msgid "Test asset user connectivity: {}" +msgstr "测试资产用户可连接性: {}" + #: assets/templates/assets/_asset_group_bulk_update_modal.html:5 msgid "Update asset group" msgstr "更新用户组" @@ -830,7 +912,7 @@ msgstr "选择资产" #: assets/templates/assets/_asset_group_bulk_update_modal.html:21 #: assets/templates/assets/cmd_filter_detail.html:89 #: assets/templates/assets/cmd_filter_list.html:26 -#: assets/templates/assets/user_asset_list.html:48 +#: assets/templates/assets/user_asset_list.html:47 #: users/templates/users/user_granted_asset.html:47 msgid "System users" msgstr "系统用户" @@ -870,11 +952,33 @@ msgstr "如果设置了id,则会使用该行信息更新该id的资产" msgid "Asset list" msgstr "资产列表" +#: assets/templates/assets/_asset_user_auth_modal.html:4 +msgid "Update asset user auth" +msgstr "更新资产用户认证信息" + +#: assets/templates/assets/_asset_user_auth_modal.html:23 +#: xpack/plugins/change_auth_plan/forms.py:88 +msgid "Please input password" +msgstr "请输入密码" + +#: assets/templates/assets/_gateway_test_modal.html:4 +msgid "Test gateway test connection" +msgstr "测试连接网关" + +#: assets/templates/assets/_gateway_test_modal.html:10 terminal/models.py:24 +msgid "SSH Port" +msgstr "SSH端口" + +#: assets/templates/assets/_gateway_test_modal.html:13 +msgid "If use nat, set the ssh real port" +msgstr "如果使用了nat端口映射,请设置为ssh真实监听的端口" + #: assets/templates/assets/_system_user.html:37 #: assets/templates/assets/asset_create.html:16 #: assets/templates/assets/asset_update.html:21 #: assets/templates/assets/gateway_create_update.html:37 #: perms/templates/perms/asset_permission_create_update.html:38 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:37 msgid "Basic" msgstr "基本" @@ -896,6 +1000,7 @@ msgstr "自动生成密钥" #: assets/templates/assets/gateway_create_update.html:53 #: perms/templates/perms/asset_permission_create_update.html:50 #: terminal/templates/terminal/terminal_update.html:40 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:61 msgid "Other" msgstr "其它" @@ -909,14 +1014,14 @@ msgstr "其它" #: assets/templates/assets/domain_create_update.html:16 #: assets/templates/assets/gateway_create_update.html:58 #: assets/templates/assets/label_create_update.html:18 -#: common/templates/common/basic_setting.html:61 -#: common/templates/common/command_storage_create.html:79 -#: common/templates/common/email_setting.html:62 -#: common/templates/common/ldap_setting.html:62 -#: common/templates/common/replay_storage_create.html:151 -#: common/templates/common/security_setting.html:70 -#: common/templates/common/terminal_setting.html:68 #: perms/templates/perms/asset_permission_create_update.html:80 +#: settings/templates/settings/basic_setting.html:61 +#: settings/templates/settings/command_storage_create.html:79 +#: settings/templates/settings/email_setting.html:62 +#: settings/templates/settings/ldap_setting.html:62 +#: settings/templates/settings/replay_storage_create.html:151 +#: settings/templates/settings/security_setting.html:70 +#: settings/templates/settings/terminal_setting.html:68 #: terminal/templates/terminal/terminal_update.html:45 #: users/templates/users/_user.html:50 #: users/templates/users/user_bulk_update.html:23 @@ -926,6 +1031,7 @@ msgstr "其它" #: users/templates/users/user_profile_update.html:63 #: users/templates/users/user_pubkey_update.html:70 #: users/templates/users/user_pubkey_update.html:76 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:65 #: xpack/plugins/cloud/templates/cloud/account_create_update.html:33 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_create.html:35 #: xpack/plugins/interface/templates/interface/interface.html:88 @@ -943,16 +1049,17 @@ msgstr "重置" #: assets/templates/assets/domain_create_update.html:17 #: assets/templates/assets/gateway_create_update.html:59 #: assets/templates/assets/label_create_update.html:19 -#: common/templates/common/basic_setting.html:62 -#: common/templates/common/command_storage_create.html:80 -#: common/templates/common/email_setting.html:63 -#: common/templates/common/ldap_setting.html:63 -#: common/templates/common/replay_storage_create.html:152 -#: common/templates/common/security_setting.html:71 -#: common/templates/common/terminal_setting.html:70 +#: audits/templates/audits/login_log_list.html:89 #: perms/templates/perms/asset_permission_create_update.html:81 +#: settings/templates/settings/basic_setting.html:62 +#: settings/templates/settings/command_storage_create.html:80 +#: settings/templates/settings/email_setting.html:63 +#: settings/templates/settings/ldap_setting.html:63 +#: settings/templates/settings/replay_storage_create.html:152 +#: settings/templates/settings/security_setting.html:71 +#: settings/templates/settings/terminal_setting.html:70 #: terminal/templates/terminal/command_list.html:103 -#: terminal/templates/terminal/session_list.html:127 +#: terminal/templates/terminal/session_list.html:126 #: terminal/templates/terminal/terminal_update.html:46 #: users/templates/users/_user.html:51 #: users/templates/users/forgot_password.html:49 @@ -961,12 +1068,14 @@ msgstr "重置" #: users/templates/users/user_password_update.html:72 #: users/templates/users/user_profile_update.html:64 #: users/templates/users/user_pubkey_update.html:77 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:66 #: xpack/plugins/interface/templates/interface/interface.html:89 msgid "Submit" msgstr "提交" #: assets/templates/assets/_user_asset_detail_modal.html:11 -#: assets/templates/assets/asset_detail.html:20 assets/views/asset.py:175 +#: assets/templates/assets/asset_asset_user_list.html:17 +#: assets/templates/assets/asset_detail.html:20 assets/views/asset.py:189 msgid "Asset detail" msgstr "资产详情" @@ -980,7 +1089,7 @@ msgstr "关闭" #: assets/templates/assets/cmd_filter_detail.html:19 #: assets/templates/assets/cmd_filter_rule_list.html:19 #: assets/templates/assets/domain_detail.html:18 -#: assets/templates/assets/domain_gateway_list.html:18 +#: assets/templates/assets/domain_gateway_list.html:20 #: assets/templates/assets/system_user_asset.html:18 #: assets/templates/assets/system_user_detail.html:18 #: ops/templates/ops/adhoc_history.html:130 @@ -989,6 +1098,7 @@ msgstr "关闭" #: perms/templates/perms/asset_permission_asset.html:18 #: perms/templates/perms/asset_permission_detail.html:18 #: perms/templates/perms/asset_permission_user.html:18 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:106 msgid "Detail" msgstr "详情" @@ -999,6 +1109,7 @@ msgstr "资产列表" #: assets/templates/assets/admin_user_assets.html:29 #: perms/templates/perms/asset_permission_asset.html:35 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:31 msgid "Asset list of " msgstr "资产列表" @@ -1010,33 +1121,58 @@ msgid "Quick update" msgstr "快速更新" #: assets/templates/assets/admin_user_assets.html:70 -#: assets/templates/assets/asset_detail.html:176 +#: assets/templates/assets/asset_asset_user_list.html:71 +#: assets/templates/assets/asset_detail.html:179 msgid "Test connective" msgstr "测试可连接性" #: assets/templates/assets/admin_user_assets.html:73 -#: assets/templates/assets/admin_user_assets.html:113 -#: assets/templates/assets/asset_detail.html:179 +#: assets/templates/assets/admin_user_assets.html:114 +#: assets/templates/assets/asset_asset_user_list.html:74 +#: assets/templates/assets/asset_asset_user_list.html:122 +#: assets/templates/assets/asset_detail.html:182 #: assets/templates/assets/system_user_asset.html:75 -#: assets/templates/assets/system_user_asset.html:163 +#: assets/templates/assets/system_user_asset.html:164 #: assets/templates/assets/system_user_detail.html:151 msgid "Test" msgstr "测试" +#: assets/templates/assets/admin_user_assets.html:115 +#: assets/templates/assets/asset_asset_user_list.html:120 +#: assets/templates/assets/system_user_asset.html:166 +msgid "Update auth" +msgstr "更新认证" + +#: assets/templates/assets/admin_user_assets.html:191 +#: assets/templates/assets/asset_asset_user_list.html:176 +#: assets/templates/assets/asset_detail.html:311 +#: assets/templates/assets/system_user_asset.html:350 +#: users/templates/users/user_detail.html:307 +#: users/templates/users/user_detail.html:334 +#: xpack/plugins/interface/views.py:31 +msgid "Update successfully!" +msgstr "更新成功" + +#: assets/templates/assets/admin_user_assets.html:194 +#: assets/templates/assets/asset_asset_user_list.html:179 +#: assets/templates/assets/system_user_asset.html:353 +msgid "Update failed!" +msgstr "更新失败" + #: assets/templates/assets/admin_user_detail.html:24 #: assets/templates/assets/admin_user_list.html:88 -#: assets/templates/assets/asset_detail.html:24 +#: assets/templates/assets/asset_detail.html:27 #: assets/templates/assets/asset_list.html:177 #: assets/templates/assets/cmd_filter_detail.html:29 #: assets/templates/assets/cmd_filter_list.html:57 #: assets/templates/assets/cmd_filter_rule_list.html:86 #: assets/templates/assets/domain_detail.html:24 #: assets/templates/assets/domain_detail.html:103 -#: assets/templates/assets/domain_gateway_list.html:85 +#: assets/templates/assets/domain_gateway_list.html:97 #: assets/templates/assets/domain_list.html:53 #: assets/templates/assets/label_list.html:38 #: assets/templates/assets/system_user_detail.html:26 -#: assets/templates/assets/system_user_list.html:92 audits/models.py:32 +#: assets/templates/assets/system_user_list.html:92 audits/models.py:33 #: perms/templates/perms/asset_permission_detail.html:30 #: perms/templates/perms/asset_permission_list.html:177 #: terminal/templates/terminal/terminal_detail.html:16 @@ -1048,6 +1184,8 @@ msgstr "测试" #: users/templates/users/user_profile.html:177 #: users/templates/users/user_profile.html:187 #: users/templates/users/user_profile.html:196 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:29 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:54 #: xpack/plugins/cloud/templates/cloud/account_detail.html:25 #: xpack/plugins/cloud/templates/cloud/account_list.html:38 #: xpack/plugins/orgs/templates/orgs/org_detail.html:25 @@ -1057,29 +1195,31 @@ msgstr "更新" #: assets/templates/assets/admin_user_detail.html:28 #: assets/templates/assets/admin_user_list.html:89 -#: assets/templates/assets/asset_detail.html:28 +#: assets/templates/assets/asset_detail.html:31 #: assets/templates/assets/asset_list.html:178 #: assets/templates/assets/cmd_filter_detail.html:33 #: assets/templates/assets/cmd_filter_list.html:58 #: assets/templates/assets/cmd_filter_rule_list.html:87 #: assets/templates/assets/domain_detail.html:28 #: assets/templates/assets/domain_detail.html:104 -#: assets/templates/assets/domain_gateway_list.html:86 +#: assets/templates/assets/domain_gateway_list.html:98 #: assets/templates/assets/domain_list.html:54 #: assets/templates/assets/label_list.html:39 #: assets/templates/assets/system_user_detail.html:30 -#: assets/templates/assets/system_user_list.html:93 audits/models.py:33 -#: common/templates/common/terminal_setting.html:90 -#: common/templates/common/terminal_setting.html:112 -#: ops/templates/ops/task_list.html:72 +#: assets/templates/assets/system_user_list.html:93 audits/models.py:34 +#: ops/templates/ops/task_list.html:64 #: perms/templates/perms/asset_permission_detail.html:34 #: perms/templates/perms/asset_permission_list.html:178 +#: settings/templates/settings/terminal_setting.html:90 +#: settings/templates/settings/terminal_setting.html:112 #: terminal/templates/terminal/terminal_list.html:73 #: users/templates/users/user_detail.html:30 #: users/templates/users/user_group_detail.html:32 #: users/templates/users/user_group_list.html:45 #: users/templates/users/user_list.html:84 #: users/templates/users/user_list.html:88 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:33 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:56 #: xpack/plugins/cloud/templates/cloud/account_detail.html:29 #: xpack/plugins/cloud/templates/cloud/account_list.html:40 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:32 @@ -1095,18 +1235,20 @@ msgstr "替换资产的管理员" #: assets/templates/assets/admin_user_detail.html:91 #: perms/templates/perms/asset_permission_asset.html:116 +#: xpack/plugins/change_auth_plan/forms.py:96 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:112 msgid "Select nodes" msgstr "选择节点" #: assets/templates/assets/admin_user_detail.html:100 -#: assets/templates/assets/asset_detail.html:208 +#: assets/templates/assets/asset_detail.html:211 #: assets/templates/assets/asset_list.html:636 #: assets/templates/assets/cmd_filter_detail.html:106 #: assets/templates/assets/system_user_asset.html:112 #: assets/templates/assets/system_user_detail.html:182 #: assets/templates/assets/system_user_list.html:143 -#: common/templates/common/terminal_setting.html:165 templates/_modal.html:22 -#: terminal/templates/terminal/session_detail.html:108 +#: settings/templates/settings/terminal_setting.html:165 +#: templates/_modal.html:22 terminal/templates/terminal/session_detail.html:108 #: users/templates/users/user_detail.html:388 #: users/templates/users/user_detail.html:414 #: users/templates/users/user_detail.html:437 @@ -1150,6 +1292,31 @@ msgstr "创建管理用户" msgid "Ratio" msgstr "比例" +#: assets/templates/assets/asset_asset_user_list.html:20 +#: assets/templates/assets/asset_detail.html:23 assets/views/asset.py:67 +msgid "Asset user list" +msgstr "资产用户列表" + +#: assets/templates/assets/asset_asset_user_list.html:28 +msgid "Asset users of" +msgstr "资产用户" + +#: assets/templates/assets/asset_asset_user_list.html:51 +#: assets/templates/assets/cmd_filter_detail.html:73 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:109 +msgid "Date updated" +msgstr "更新日期" + +#: assets/templates/assets/asset_asset_user_list.html:64 +#: assets/templates/assets/asset_detail.html:148 +#: terminal/templates/terminal/session_detail.html:81 +#: users/templates/users/user_detail.html:138 +#: users/templates/users/user_profile.html:146 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:128 +#: xpack/plugins/license/templates/license/license_detail.html:93 +msgid "Quick modify" +msgstr "快速修改" + #: assets/templates/assets/asset_bulk_update.html:8 #: users/templates/users/user_bulk_update.html:8 msgid "Select properties that need to be modified" @@ -1160,31 +1327,23 @@ msgstr "选择需要修改属性" msgid "Select all" msgstr "全选" -#: assets/templates/assets/asset_detail.html:93 +#: assets/templates/assets/asset_detail.html:96 msgid "CPU" msgstr "CPU" -#: assets/templates/assets/asset_detail.html:101 +#: assets/templates/assets/asset_detail.html:104 msgid "Disk" msgstr "硬盘" -#: assets/templates/assets/asset_detail.html:129 +#: assets/templates/assets/asset_detail.html:132 #: users/templates/users/user_detail.html:115 #: users/templates/users/user_profile.html:104 msgid "Date joined" msgstr "创建日期" -#: assets/templates/assets/asset_detail.html:145 -#: terminal/templates/terminal/session_detail.html:81 -#: users/templates/users/user_detail.html:138 -#: users/templates/users/user_profile.html:146 -#: xpack/plugins/license/templates/license/license_detail.html:93 -msgid "Quick modify" -msgstr "快速修改" - -#: assets/templates/assets/asset_detail.html:151 -#: assets/templates/assets/user_asset_list.html:47 perms/models.py:34 -#: perms/models.py:88 +#: assets/templates/assets/asset_detail.html:154 +#: assets/templates/assets/user_asset_list.html:46 perms/models.py:33 +#: perms/models.py:87 #: perms/templates/perms/asset_permission_create_update.html:52 #: perms/templates/perms/asset_permission_detail.html:120 #: terminal/templates/terminal/terminal_list.html:34 @@ -1196,21 +1355,14 @@ msgstr "快速修改" msgid "Active" msgstr "激活中" -#: assets/templates/assets/asset_detail.html:168 +#: assets/templates/assets/asset_detail.html:171 msgid "Refresh hardware" msgstr "更新硬件信息" -#: assets/templates/assets/asset_detail.html:171 +#: assets/templates/assets/asset_detail.html:174 msgid "Refresh" msgstr "刷新" -#: assets/templates/assets/asset_detail.html:308 -#: users/templates/users/user_detail.html:307 -#: users/templates/users/user_detail.html:334 -#: xpack/plugins/interface/views.py:31 -msgid "Update successfully!" -msgstr "更新成功" - #: assets/templates/assets/asset_list.html:8 msgid "" "The left side is the asset tree, right click to create, delete, and change " @@ -1220,7 +1372,7 @@ msgstr "" "左侧是资产树,右击可以新建、删除、更改树节点,授权资产也是以节点方式组织的," "右侧是属于该节点下的资产" -#: assets/templates/assets/asset_list.html:69 assets/views/asset.py:90 +#: assets/templates/assets/asset_list.html:69 assets/views/asset.py:104 msgid "Create asset" msgstr "创建资产" @@ -1231,6 +1383,7 @@ msgid "Import" msgstr "导入" #: assets/templates/assets/asset_list.html:76 +#: audits/templates/audits/login_log_list.html:85 #: users/templates/users/user_list.html:10 msgid "Export" msgstr "导出" @@ -1339,7 +1492,7 @@ msgstr "删除选择资产" #: assets/templates/assets/asset_list.html:634 #: assets/templates/assets/system_user_list.html:141 -#: common/templates/common/terminal_setting.html:163 +#: settings/templates/settings/terminal_setting.html:163 #: users/templates/users/user_detail.html:386 #: users/templates/users/user_detail.html:412 #: users/templates/users/user_detail.html:480 @@ -1373,10 +1526,6 @@ msgstr "配置" msgid "Rules" msgstr "规则" -#: assets/templates/assets/cmd_filter_detail.html:73 -msgid "Date updated" -msgstr "更新日期" - #: assets/templates/assets/cmd_filter_detail.html:97 msgid "Binding to system user" msgstr "绑定到系统用户" @@ -1435,27 +1584,27 @@ msgstr "确认删除" msgid "Are you sure delete" msgstr "您确定删除吗?" -#: assets/templates/assets/domain_gateway_list.html:31 +#: assets/templates/assets/domain_gateway_list.html:37 msgid "Gateway list" msgstr "网关列表" -#: assets/templates/assets/domain_gateway_list.html:48 +#: assets/templates/assets/domain_gateway_list.html:56 #: assets/views/domain.py:127 msgid "Create gateway" msgstr "创建网关" -#: assets/templates/assets/domain_gateway_list.html:87 -#: assets/templates/assets/domain_gateway_list.html:89 -#: common/templates/common/email_setting.html:61 -#: common/templates/common/ldap_setting.html:61 +#: assets/templates/assets/domain_gateway_list.html:99 +#: assets/templates/assets/domain_gateway_list.html:101 +#: settings/templates/settings/email_setting.html:61 +#: settings/templates/settings/ldap_setting.html:61 msgid "Test connection" msgstr "测试连接" -#: assets/templates/assets/domain_gateway_list.html:123 +#: assets/templates/assets/domain_gateway_list.html:141 msgid "Can be connected" msgstr "可连接" -#: assets/templates/assets/domain_gateway_list.html:124 +#: assets/templates/assets/domain_gateway_list.html:142 msgid "The connection fails" msgstr "连接失败" @@ -1495,7 +1644,7 @@ msgid "Push system user now" msgstr "立刻推送系统" #: assets/templates/assets/system_user_asset.html:84 -#: assets/templates/assets/system_user_asset.html:161 +#: assets/templates/assets/system_user_asset.html:162 #: assets/templates/assets/system_user_detail.html:142 msgid "Push" msgstr "推送" @@ -1568,6 +1717,10 @@ msgstr "删除系统用户" msgid "System Users Deleting failed." msgstr "系统用户删除失败" +#: assets/templates/assets/user_asset_list.html:100 +msgid "Connect" +msgstr "连接" + #: assets/views/admin_user.py:30 msgid "Admin user list" msgstr "管理用户列表" @@ -1580,23 +1733,23 @@ msgstr "更新管理用户" msgid "Admin user detail" msgstr "管理用户详情" -#: assets/views/asset.py:64 templates/_nav_user.html:4 +#: assets/views/asset.py:78 templates/_nav_user.html:4 msgid "My assets" msgstr "我的资产" -#: assets/views/asset.py:104 +#: assets/views/asset.py:118 msgid "Bulk update asset success" msgstr "批量更新资产成功" -#: assets/views/asset.py:134 +#: assets/views/asset.py:148 msgid "Bulk update asset" msgstr "批量更新资产" -#: assets/views/asset.py:151 +#: assets/views/asset.py:165 msgid "Update asset" msgstr "更新资产" -#: assets/views/asset.py:292 +#: assets/views/asset.py:306 msgid "already exists" msgstr "已经存在" @@ -1672,7 +1825,7 @@ msgstr "资产管理" msgid "System user asset" msgstr "系统用户资产" -#: audits/models.py:17 audits/models.py:40 audits/models.py:51 +#: audits/models.py:18 audits/models.py:41 audits/models.py:52 #: audits/templates/audits/ftp_log_list.html:73 #: audits/templates/audits/operate_log_list.html:70 #: audits/templates/audits/password_change_log_list.html:52 @@ -1681,46 +1834,128 @@ msgstr "系统用户资产" msgid "Remote addr" msgstr "远端地址" -#: audits/models.py:20 audits/templates/audits/ftp_log_list.html:74 +#: audits/models.py:21 audits/templates/audits/ftp_log_list.html:74 msgid "Operate" msgstr "操作" -#: audits/models.py:21 audits/templates/audits/ftp_log_list.html:56 +#: audits/models.py:22 audits/templates/audits/ftp_log_list.html:56 #: audits/templates/audits/ftp_log_list.html:75 msgid "Filename" msgstr "文件名" -#: audits/models.py:22 audits/templates/audits/ftp_log_list.html:76 -#: ops/templates/ops/command_execution_list.html:64 -#: ops/templates/ops/task_list.html:39 users/models/authentication.py:73 -#: users/templates/users/user_detail.html:458 xpack/plugins/cloud/api.py:62 +#: audits/models.py:23 audits/models.py:90 +#: audits/templates/audits/ftp_log_list.html:76 +#: ops/templates/ops/command_execution_list.html:65 +#: ops/templates/ops/task_list.html:31 +#: users/templates/users/user_detail.html:458 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:14 +#: xpack/plugins/cloud/api.py:62 msgid "Success" msgstr "成功" -#: audits/models.py:31 +#: audits/models.py:32 msgid "Create" msgstr "创建" -#: audits/models.py:38 audits/templates/audits/operate_log_list.html:49 +#: audits/models.py:39 audits/templates/audits/operate_log_list.html:49 #: audits/templates/audits/operate_log_list.html:68 msgid "Resource Type" msgstr "资源类型" -#: audits/models.py:39 audits/templates/audits/operate_log_list.html:69 +#: audits/models.py:40 audits/templates/audits/operate_log_list.html:69 msgid "Resource" msgstr "资源" -#: audits/models.py:50 audits/templates/audits/password_change_log_list.html:51 +#: audits/models.py:51 audits/templates/audits/password_change_log_list.html:51 msgid "Change by" msgstr "修改者" +#: audits/models.py:70 users/templates/users/user_detail.html:98 +msgid "Disabled" +msgstr "禁用" + +#: audits/models.py:71 settings/models.py:33 +#: users/templates/users/user_detail.html:96 +msgid "Enabled" +msgstr "启用" + +#: audits/models.py:72 audits/models.py:82 +msgid "-" +msgstr "" + +#: audits/models.py:83 +msgid "Username/password check failed" +msgstr "用户名/密码 校验失败" + +#: audits/models.py:84 +msgid "MFA authentication failed" +msgstr "MFA 认证失败" + +#: audits/models.py:85 +msgid "Username does not exist" +msgstr "用户名不存在" + +#: audits/models.py:86 +msgid "Password expired" +msgstr "密码过期" + +#: audits/models.py:91 xpack/plugins/cloud/models.py:164 +#: xpack/plugins/cloud/models.py:178 +msgid "Failed" +msgstr "失败" + +#: audits/models.py:95 +msgid "Login type" +msgstr "登录方式" + +#: audits/models.py:96 +msgid "Login ip" +msgstr "登录IP" + +#: audits/models.py:97 +msgid "Login city" +msgstr "登录城市" + +#: audits/models.py:98 +msgid "User agent" +msgstr "Agent" + +#: audits/models.py:99 audits/templates/audits/login_log_list.html:56 +#: users/forms.py:142 users/models/user.py:76 +#: users/templates/users/first_login.html:45 +msgid "MFA" +msgstr "MFA" + +#: audits/models.py:100 audits/templates/audits/login_log_list.html:57 +#: xpack/plugins/change_auth_plan/models.py:405 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:15 +#: xpack/plugins/cloud/models.py:172 +#: xpack/plugins/cloud/templates/cloud/sync_instance_task_history.html:69 +msgid "Reason" +msgstr "原因" + +#: audits/models.py:101 audits/templates/audits/login_log_list.html:58 +#: xpack/plugins/cloud/models.py:171 xpack/plugins/cloud/models.py:188 +#: xpack/plugins/cloud/templates/cloud/sync_instance_task_history.html:70 +#: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:67 +msgid "Status" +msgstr "状态" + +#: audits/models.py:102 +msgid "Date login" +msgstr "登录日期" + #: audits/templates/audits/ftp_log_list.html:77 #: ops/templates/ops/adhoc_history.html:52 #: ops/templates/ops/adhoc_history_detail.html:61 -#: ops/templates/ops/command_execution_list.html:65 -#: ops/templates/ops/task_history.html:58 perms/models.py:35 +#: ops/templates/ops/command_execution_list.html:66 +#: ops/templates/ops/task_history.html:58 perms/models.py:34 #: perms/templates/perms/asset_permission_detail.html:86 terminal/models.py:165 #: terminal/templates/terminal/session_list.html:78 +#: xpack/plugins/change_auth_plan/models.py:238 +#: xpack/plugins/change_auth_plan/models.py:408 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:59 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:17 msgid "Date start" msgstr "开始日期" @@ -1733,9 +1968,9 @@ msgstr "选择用户" #: audits/templates/audits/login_log_list.html:40 #: audits/templates/audits/operate_log_list.html:58 #: audits/templates/audits/password_change_log_list.html:42 -#: ops/templates/ops/command_execution_list.html:42 -#: ops/templates/ops/command_execution_list.html:47 -#: ops/templates/ops/task_list.html:21 ops/templates/ops/task_list.html:26 +#: ops/templates/ops/command_execution_list.html:43 +#: ops/templates/ops/command_execution_list.html:48 +#: ops/templates/ops/task_list.html:13 ops/templates/ops/task_list.html:18 #: templates/_base_list.html:43 templates/_header_bar.html:8 #: terminal/templates/terminal/command_list.html:60 #: terminal/templates/terminal/session_list.html:61 @@ -1744,7 +1979,7 @@ msgstr "选择用户" msgid "Search" msgstr "搜索" -#: audits/templates/audits/login_log_list.html:48 +#: audits/templates/audits/login_log_list.html:50 #: ops/templates/ops/adhoc_detail.html:49 #: ops/templates/ops/adhoc_history_detail.html:49 #: ops/templates/ops/task_detail.html:56 @@ -1754,36 +1989,16 @@ msgstr "搜索" msgid "ID" msgstr "ID" -#: audits/templates/audits/login_log_list.html:51 +#: audits/templates/audits/login_log_list.html:53 msgid "UA" msgstr "Agent" -#: audits/templates/audits/login_log_list.html:53 +#: audits/templates/audits/login_log_list.html:55 msgid "City" msgstr "城市" -#: audits/templates/audits/login_log_list.html:54 users/forms.py:162 -#: users/models/authentication.py:82 users/models/user.py:77 -#: users/templates/users/first_login.html:45 -msgid "MFA" -msgstr "MFA" - -#: audits/templates/audits/login_log_list.html:55 -#: users/models/authentication.py:83 xpack/plugins/cloud/models.py:172 -#: xpack/plugins/cloud/templates/cloud/sync_instance_task_history.html:69 -msgid "Reason" -msgstr "原因" - -#: audits/templates/audits/login_log_list.html:56 -#: users/models/authentication.py:84 xpack/plugins/cloud/models.py:171 -#: xpack/plugins/cloud/models.py:188 -#: xpack/plugins/cloud/templates/cloud/sync_instance_task_history.html:70 -#: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:67 -msgid "Status" -msgstr "状态" - -#: audits/templates/audits/login_log_list.html:57 -#: ops/templates/ops/task_list.html:40 +#: audits/templates/audits/login_log_list.html:59 +#: ops/templates/ops/task_list.html:32 msgid "Date" msgstr "日期" @@ -1795,61 +2010,127 @@ msgstr "日期" msgid "Datetime" msgstr "日期" -#: audits/views.py:71 audits/views.py:115 audits/views.py:151 -#: audits/views.py:195 audits/views.py:226 templates/_nav.html:72 +#: audits/views.py:85 audits/views.py:129 audits/views.py:165 +#: audits/views.py:209 audits/views.py:241 templates/_nav.html:72 msgid "Audits" msgstr "日志审计" -#: audits/views.py:72 templates/_nav.html:76 +#: audits/views.py:86 templates/_nav.html:76 msgid "FTP log" msgstr "FTP日志" -#: audits/views.py:116 templates/_nav.html:77 +#: audits/views.py:130 templates/_nav.html:77 msgid "Operate log" msgstr "操作日志" -#: audits/views.py:152 templates/_nav.html:78 +#: audits/views.py:166 templates/_nav.html:78 msgid "Password change log" msgstr "改密日志" -#: audits/views.py:196 templates/_nav.html:75 +#: audits/views.py:210 templates/_nav.html:75 msgid "Login log" msgstr "登录日志" -#: audits/views.py:227 ops/views/command.py:44 -msgid "Command execution list" -msgstr "命令执行列表" +#: audits/views.py:242 +msgid "Command execution log" +msgstr "命令执行" -#: common/api.py:27 -msgid "Test mail sent to {}, please check" -msgstr "邮件已经发送{}, 请检查" +#: authentication/api/auth.py:46 users/templates/users/login.html:52 +#: users/templates/users/new_login.html:97 +msgid "Log in frequently and try again later" +msgstr "登录频繁, 稍后重试" -#: common/api.py:51 -msgid "Test ldap success" -msgstr "连接LDAP成功" +#: authentication/api/auth.py:64 +msgid "The user {} password has expired, please update." +msgstr "用户 {} 密码已经过期,请更新。" -#: common/api.py:81 -msgid "Search no entry matched in ou {}" -msgstr "在ou:{}中没有匹配条目" +#: authentication/api/auth.py:83 +msgid "Please carry seed value and conduct MFA secondary certification" +msgstr "请携带seed值, 进行MFA二次认证" -#: common/api.py:90 -msgid "Match {} s users" -msgstr "匹配 {} 个用户" +#: authentication/api/auth.py:163 +msgid "Please verify the user name and password first" +msgstr "请先进行用户名和密码验证" -#: common/api.py:113 common/api.py:149 +#: authentication/api/auth.py:168 +msgid "MFA certification failed" +msgstr "MFA认证失败" + +#: authentication/backends/api.py:52 +msgid "Invalid signature header. No credentials provided." +msgstr "" + +#: authentication/backends/api.py:55 +msgid "Invalid signature header. Signature string should not contain spaces." +msgstr "" + +#: authentication/backends/api.py:62 +msgid "Invalid signature header. Format like AccessKeyId:Signature" +msgstr "" + +#: authentication/backends/api.py:66 msgid "" -"Error: Account invalid (Please make sure the information such as Access key " -"or Secret key is correct)" -msgstr "错误:账户无效 (请确保 Access key 或 Secret key 等信息正确)" +"Invalid signature header. Signature string should not contain invalid " +"characters." +msgstr "" -#: common/api.py:119 common/api.py:155 -msgid "Create succeed" -msgstr "创建成功" +#: authentication/backends/api.py:86 authentication/backends/api.py:102 +msgid "Invalid signature." +msgstr "" -#: common/api.py:137 common/api.py:175 -#: common/templates/common/terminal_setting.html:151 -msgid "Delete succeed" -msgstr "删除成功" +#: authentication/backends/api.py:93 +msgid "HTTP header: Date not provide or not %a, %d %b %Y %H:%M:%S GMT" +msgstr "" + +#: authentication/backends/api.py:98 +msgid "Expired, more than 15 minutes" +msgstr "" + +#: authentication/backends/api.py:105 +msgid "User disabled." +msgstr "用户已禁用" + +#: authentication/backends/api.py:120 +msgid "Invalid token header. No credentials provided." +msgstr "" + +#: authentication/backends/api.py:123 +msgid "Invalid token header. Sign string should not contain spaces." +msgstr "" + +#: authentication/backends/api.py:130 +msgid "" +"Invalid token header. Sign string should not contain invalid characters." +msgstr "" + +#: authentication/backends/api.py:140 +msgid "Invalid token or cache refreshed." +msgstr "" + +#: authentication/forms.py:29 users/forms.py:21 +msgid "MFA code" +msgstr "MFA 验证码" + +#: authentication/models.py:33 +msgid "Private Token" +msgstr "ssh密钥" + +#: authentication/views/login.py:75 +msgid "Please enable cookies and try again." +msgstr "设置你的浏览器支持cookie" + +#: authentication/views/login.py:167 users/views/user.py:532 +#: users/views/user.py:557 +msgid "MFA code invalid, or ntp sync server time" +msgstr "MFA验证码不正确,或者服务器端时间不对" + +#: authentication/views/login.py:198 +msgid "Logout success" +msgstr "退出登录成功" + +#: authentication/views/login.py:199 +msgid "Logout success, return login page" +msgstr "退出登录成功,返回到登录页面" #: common/const.py:6 #, python-format @@ -1861,260 +2142,42 @@ msgstr "%(name)s 创建成功" msgid "%(name)s was updated successfully" msgstr "%(name)s 更新成功" -#: common/fields.py:31 +#: common/fields/form.py:34 msgid "Not a valid json" msgstr "不是合法json" -#: common/fields.py:33 +#: common/fields/form.py:36 msgid "Not a string type" msgstr "不是字符类型" -#: common/fields.py:70 +#: common/fields/model.py:79 +msgid "Marshal dict data to char field" +msgstr "" + +#: common/fields/model.py:83 +msgid "Marshal dict data to text field" +msgstr "" + +#: common/fields/model.py:95 +msgid "Marshal list data to char field" +msgstr "" + +#: common/fields/model.py:99 +msgid "Marshal list data to text field" +msgstr "" + +#: common/fields/model.py:103 +msgid "Marshal data to char field" +msgstr "" + +#: common/fields/model.py:107 +msgid "Marshal data to text field" +msgstr "" + +#: common/fields/model.py:123 msgid "Encrypt field using Secret Key" msgstr "" -#: common/forms.py:59 -msgid "Current SITE URL" -msgstr "当前站点URL" - -#: common/forms.py:63 -msgid "User Guide URL" -msgstr "用户向导URL" - -#: common/forms.py:64 -msgid "User first login update profile done redirect to it" -msgstr "用户第一次登录,修改profile后重定向到地址" - -#: common/forms.py:67 -msgid "Email Subject Prefix" -msgstr "Email主题前缀" - -#: common/forms.py:68 -msgid "Tips: Some word will be intercept by mail provider" -msgstr "提示: 一些关键字可能会被邮件提供商拦截,如 跳板机、Jumpserver" - -#: common/forms.py:74 -msgid "SMTP host" -msgstr "SMTP主机" - -#: common/forms.py:76 -msgid "SMTP port" -msgstr "SMTP端口" - -#: common/forms.py:78 -msgid "SMTP user" -msgstr "SMTP账号" - -#: common/forms.py:81 -msgid "SMTP password" -msgstr "SMTP密码" - -#: common/forms.py:82 -msgid "Some provider use token except password" -msgstr "一些邮件提供商需要输入的是Token" - -#: common/forms.py:85 common/forms.py:123 -msgid "Use SSL" -msgstr "使用SSL" - -#: common/forms.py:86 -msgid "If SMTP port is 465, may be select" -msgstr "如果SMTP端口是465,通常需要启用SSL" - -#: common/forms.py:89 -msgid "Use TLS" -msgstr "使用TLS" - -#: common/forms.py:90 -msgid "If SMTP port is 587, may be select" -msgstr "如果SMTP端口是587,通常需要启用TLS" - -#: common/forms.py:96 -msgid "LDAP server" -msgstr "LDAP地址" - -#: common/forms.py:99 -msgid "Bind DN" -msgstr "绑定DN" - -#: common/forms.py:106 -msgid "User OU" -msgstr "用户OU" - -#: common/forms.py:107 -msgid "Use | split User OUs" -msgstr "使用|分隔各OU" - -#: common/forms.py:110 -msgid "User search filter" -msgstr "用户过滤器" - -#: common/forms.py:111 -#, python-format -msgid "Choice may be (cn|uid|sAMAccountName)=%(user)s)" -msgstr "可能的选项是(cn或uid或sAMAccountName=%(user)s)" - -#: common/forms.py:114 -msgid "User attr map" -msgstr "LDAP属性映射" - -#: common/forms.py:116 -msgid "" -"User attr map present how to map LDAP user attr to jumpserver, username,name," -"email is jumpserver attr" -msgstr "" -"用户属性映射代表怎样将LDAP中用户属性映射到jumpserver用户上,username, name," -"email 是jumpserver的属性" - -#: common/forms.py:125 -msgid "Enable LDAP auth" -msgstr "启用LDAP认证" - -#: common/forms.py:134 -msgid "All" -msgstr "全部" - -#: common/forms.py:135 -msgid "Auto" -msgstr "自动" - -#: common/forms.py:142 -msgid "Password auth" -msgstr "密码认证" - -#: common/forms.py:145 -msgid "Public key auth" -msgstr "密钥认证" - -#: common/forms.py:148 -msgid "Heartbeat interval" -msgstr "心跳间隔" - -#: common/forms.py:149 ops/models/adhoc.py:38 -msgid "Units: seconds" -msgstr "单位: 秒" - -#: common/forms.py:152 -msgid "List sort by" -msgstr "资产列表排序" - -#: common/forms.py:155 -msgid "List page size" -msgstr "资产分页每页数量" - -#: common/forms.py:158 -msgid "Session keep duration" -msgstr "会话保留时长" - -#: common/forms.py:159 -msgid "" -"Units: days, Session, record, command will be delete if more than duration, " -"only in database" -msgstr "" -"单位:天。 会话、录像、命令记录超过该时长将会被删除(仅影响数据库存储, oss等不" -"受影响)" - -#: common/forms.py:163 -msgid "Telnet login regex" -msgstr "Telnet 成功正则表达式" - -#: common/forms.py:164 -msgid "ex: Last\\s*login|success|成功" -msgstr "" -"登录telnet服务器成功后的提示正则表达式,如: Last\\s*login|success|成功 " - -#: common/forms.py:175 -msgid "MFA Secondary certification" -msgstr "MFA 二次认证" - -#: common/forms.py:177 -msgid "" -"After opening, the user login must use MFA secondary authentication (valid " -"for all users, including administrators)" -msgstr "开启后,用户登录必须使用MFA二次认证(对所有用户有效,包括管理员)" - -#: common/forms.py:183 -msgid "Limit the number of login failures" -msgstr "限制登录失败次数" - -#: common/forms.py:187 -msgid "No logon interval" -msgstr "禁止登录时间间隔" - -#: common/forms.py:189 -msgid "" -"Tip: (unit/minute) if the user has failed to log in for a limited number of " -"times, no login is allowed during this time interval." -msgstr "" -"提示:(单位:分)当用户登录失败次数达到限制后,那么在此时间间隔内禁止登录" - -#: common/forms.py:195 -msgid "Connection max idle time" -msgstr "SSH最大空闲时间" - -#: common/forms.py:197 -msgid "" -"If idle time more than it, disconnect connection(only ssh now) Unit: minute" -msgstr "提示:(单位:分)如果超过该配置没有操作,连接会被断开(仅ssh)" - -#: common/forms.py:203 -msgid "Password expiration time" -msgstr "密码过期时间" - -#: common/forms.py:206 -msgid "" -"Tip: (unit: day) If the user does not update the password during the time, " -"the user password will expire failure;The password expiration reminder mail " -"will be automatic sent to the user by system within 5 days (daily) before " -"the password expires" -msgstr "" -"提示:(单位:天)如果用户在此期间没有更新密码,用户密码将过期失效; 密码过期" -"提醒邮件将在密码过期前5天内由系统(每天)自动发送给用户" - -#: common/forms.py:215 -msgid "Password minimum length" -msgstr "密码最小长度 " - -#: common/forms.py:219 -msgid "Must contain capital letters" -msgstr "必须包含大写字母" - -#: common/forms.py:221 -msgid "" -"After opening, the user password changes and resets must contain uppercase " -"letters" -msgstr "开启后,用户密码修改、重置必须包含大写字母" - -#: common/forms.py:226 -msgid "Must contain lowercase letters" -msgstr "必须包含小写字母" - -#: common/forms.py:227 -msgid "" -"After opening, the user password changes and resets must contain lowercase " -"letters" -msgstr "开启后,用户密码修改、重置必须包含小写字母" - -#: common/forms.py:232 -msgid "Must contain numeric characters" -msgstr "必须包含数字字符" - -#: common/forms.py:233 -msgid "" -"After opening, the user password changes and resets must contain numeric " -"characters" -msgstr "开启后,用户密码修改、重置必须包含数字字符" - -#: common/forms.py:238 -msgid "Must contain special characters" -msgstr "必须包含特殊字符" - -#: common/forms.py:239 -msgid "" -"After opening, the user password changes and resets must contain special " -"characters" -msgstr "开启后,用户密码修改、重置必须包含特殊字符" - #: common/mixins.py:28 msgid "is discard" msgstr "" @@ -2123,217 +2186,10 @@ msgstr "" msgid "discard time" msgstr "" -#: common/models.py:33 users/models/authentication.py:54 -#: users/templates/users/user_detail.html:96 -msgid "Enabled" -msgstr "启用" - -#: common/models.py:126 users/templates/users/reset_password.html:68 -#: users/templates/users/user_profile.html:20 -msgid "Setting" -msgstr "设置" - -#: common/templates/common/basic_setting.html:15 -#: common/templates/common/email_setting.html:15 -#: common/templates/common/ldap_setting.html:15 -#: common/templates/common/security_setting.html:15 -#: common/templates/common/terminal_setting.html:16 -#: common/templates/common/terminal_setting.html:46 common/views.py:19 -msgid "Basic setting" -msgstr "基本设置" - -#: common/templates/common/basic_setting.html:18 -#: common/templates/common/email_setting.html:18 -#: common/templates/common/ldap_setting.html:18 -#: common/templates/common/security_setting.html:18 -#: common/templates/common/terminal_setting.html:20 common/views.py:45 -msgid "Email setting" -msgstr "邮件设置" - -#: common/templates/common/basic_setting.html:21 -#: common/templates/common/email_setting.html:21 -#: common/templates/common/ldap_setting.html:21 -#: common/templates/common/security_setting.html:21 -#: common/templates/common/terminal_setting.html:24 common/views.py:71 -msgid "LDAP setting" -msgstr "LDAP设置" - -#: common/templates/common/basic_setting.html:24 -#: common/templates/common/email_setting.html:24 -#: common/templates/common/ldap_setting.html:24 -#: common/templates/common/security_setting.html:24 -#: common/templates/common/terminal_setting.html:28 common/views.py:100 -msgid "Terminal setting" -msgstr "终端设置" - -#: common/templates/common/basic_setting.html:27 -#: common/templates/common/email_setting.html:27 -#: common/templates/common/ldap_setting.html:27 -#: common/templates/common/security_setting.html:27 -#: common/templates/common/security_setting.html:42 -#: common/templates/common/terminal_setting.html:31 common/views.py:152 -msgid "Security setting" -msgstr "安全设置" - -#: common/templates/common/command_storage_create.html:49 -#: ops/models/adhoc.py:161 ops/templates/ops/adhoc_detail.html:53 -#: ops/templates/ops/command_execution_list.html:58 -#: ops/templates/ops/task_adhoc.html:59 ops/templates/ops/task_list.html:38 -msgid "Hosts" -msgstr "主机" - -#: common/templates/common/command_storage_create.html:52 -msgid "Tips: If there are multiple hosts, separate them with a comma (,)" -msgstr "提示: 如果有多台主机,请使用逗号 ( , ) 进行分割" - -#: common/templates/common/command_storage_create.html:63 -msgid "Index" -msgstr "索引" - -#: common/templates/common/command_storage_create.html:70 -msgid "Doc type" -msgstr "文档类型" - -#: common/templates/common/replay_storage_create.html:52 -#: ops/models/adhoc.py:162 templates/index.html:91 -msgid "Host" -msgstr "主机" - -#: common/templates/common/replay_storage_create.html:66 -msgid "Bucket" -msgstr "桶名称" - -#: common/templates/common/replay_storage_create.html:73 -msgid "Access key" -msgstr "" - -#: common/templates/common/replay_storage_create.html:80 -msgid "Secret key" -msgstr "" - -#: common/templates/common/replay_storage_create.html:87 -msgid "Container name" -msgstr "容器名称" - -#: common/templates/common/replay_storage_create.html:94 -msgid "Account name" -msgstr "账户名称" - -#: common/templates/common/replay_storage_create.html:101 -msgid "Account key" -msgstr "账户密钥" - -#: common/templates/common/replay_storage_create.html:108 -msgid "Endpoint" -msgstr "端点" - -#: common/templates/common/replay_storage_create.html:113 -#, python-brace-format -msgid "OSS: http://{REGION_NAME}.aliyuncs.com" -msgstr "OSS: http://{REGION_NAME}.aliyuncs.com" - -#: common/templates/common/replay_storage_create.html:115 -msgid "Example: http://oss-cn-hangzhou.aliyuncs.com" -msgstr "如: http://oss-cn-hangzhou.aliyuncs.com" - -#: common/templates/common/replay_storage_create.html:117 -#, python-brace-format -msgid "S3: http://s3.{REGION_NAME}.amazonaws.com" -msgstr "S3: http://s3.{REGION_NAME}.amazonaws.com" - -#: common/templates/common/replay_storage_create.html:118 -#, python-brace-format -msgid "S3(China): http://s3.{REGION_NAME}.amazonaws.com.cn" -msgstr "S3(中国): http://s3.{REGION_NAME}.amazonaws.com.cn" - -#: common/templates/common/replay_storage_create.html:119 -msgid "Example: http://s3.cn-north-1.amazonaws.com.cn" -msgstr "如: http://s3.cn-north-1.amazonaws.com.cn" - -#: common/templates/common/replay_storage_create.html:125 -msgid "Endpoint suffix" -msgstr "端点后缀" - -#: common/templates/common/replay_storage_create.html:135 -#: xpack/plugins/cloud/models.py:186 -#: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:83 -#: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:64 -msgid "Region" -msgstr "地域" - -#: common/templates/common/replay_storage_create.html:140 -msgid "Beijing: cn-north-1" -msgstr "北京: cn-north-1" - -#: common/templates/common/replay_storage_create.html:141 -msgid "Ningxia: cn-northwest-1" -msgstr "宁夏: cn-northwest-1" - -#: common/templates/common/replay_storage_create.html:142 -msgid "More" -msgstr "更多" - -#: common/templates/common/replay_storage_create.html:246 -msgid "Submitting" -msgstr "提交中" - -#: common/templates/common/security_setting.html:46 -msgid "Password check rule" -msgstr "密码校验规则" - -#: common/templates/common/terminal_setting.html:76 terminal/forms.py:27 -#: terminal/models.py:26 -msgid "Command storage" -msgstr "命令存储" - -#: common/templates/common/terminal_setting.html:95 -#: common/templates/common/terminal_setting.html:117 -#: perms/templates/perms/asset_permission_asset.html:97 -#: perms/templates/perms/asset_permission_detail.html:157 -#: perms/templates/perms/asset_permission_user.html:97 -#: perms/templates/perms/asset_permission_user.html:125 -#: users/templates/users/user_group_detail.html:95 -#: xpack/plugins/orgs/templates/orgs/org_detail.html:93 -#: xpack/plugins/orgs/templates/orgs/org_detail.html:130 -msgid "Add" -msgstr "添加" - -#: common/templates/common/terminal_setting.html:98 terminal/forms.py:32 -#: terminal/models.py:27 -msgid "Replay storage" -msgstr "录像存储" - -#: common/templates/common/terminal_setting.html:154 -msgid "Delete failed" -msgstr "删除失败" - -#: common/templates/common/terminal_setting.html:159 -msgid "Are you sure about deleting it?" -msgstr "您确定删除吗?" - #: common/validators.py:7 msgid "Special char not allowed" msgstr "不能包含特殊字符" -#: common/views.py:18 common/views.py:44 common/views.py:70 common/views.py:99 -#: common/views.py:126 common/views.py:138 common/views.py:151 -#: templates/_nav.html:107 -msgid "Settings" -msgstr "系统设置" - -#: common/views.py:29 common/views.py:55 common/views.py:81 common/views.py:112 -#: common/views.py:162 -msgid "Update setting successfully" -msgstr "更新设置成功" - -#: common/views.py:127 -msgid "Create replay storage" -msgstr "创建录像存储" - -#: common/views.py:139 -msgid "Create command storage" -msgstr "创建命令存储" - #: jumpserver/views.py:185 msgid "" "
    Luna is a separately deployed program, you need to deploy Luna, coco, " @@ -2352,13 +2208,17 @@ msgstr "等待任务开始" msgid "Interval" msgstr "间隔" +#: ops/models/adhoc.py:38 settings/forms.py:151 +msgid "Units: seconds" +msgstr "单位: 秒" + #: ops/models/adhoc.py:39 msgid "Crontab" msgstr "Crontab" #: ops/models/adhoc.py:39 msgid "5 * * * *" -msgstr "" +msgstr "5 * * * *" #: ops/models/adhoc.py:41 msgid "Callback" @@ -2377,6 +2237,19 @@ msgstr "模式" msgid "Options" msgstr "选项" +#: ops/models/adhoc.py:161 ops/templates/ops/adhoc_detail.html:53 +#: ops/templates/ops/command_execution_list.html:59 +#: ops/templates/ops/task_adhoc.html:59 ops/templates/ops/task_list.html:30 +#: settings/templates/settings/command_storage_create.html:49 +msgid "Hosts" +msgstr "主机" + +#: ops/models/adhoc.py:162 +#: settings/templates/settings/replay_storage_create.html:52 +#: templates/index.html:91 +msgid "Host" +msgstr "主机" + #: ops/models/adhoc.py:163 msgid "Run as admin" msgstr "再次执行" @@ -2400,40 +2273,46 @@ msgstr "{} 任务开始: {}" msgid "{} Task finish" msgstr "{} 任务结束" -#: ops/models/adhoc.py:323 +#: ops/models/adhoc.py:324 msgid "Start time" msgstr "开始时间" -#: ops/models/adhoc.py:324 +#: ops/models/adhoc.py:325 msgid "End time" msgstr "完成时间" -#: ops/models/adhoc.py:325 ops/templates/ops/adhoc_history.html:57 -#: ops/templates/ops/task_history.html:63 ops/templates/ops/task_list.html:41 +#: ops/models/adhoc.py:326 ops/templates/ops/adhoc_history.html:57 +#: ops/templates/ops/task_history.html:63 ops/templates/ops/task_list.html:33 +#: xpack/plugins/change_auth_plan/models.py:241 +#: xpack/plugins/change_auth_plan/models.py:411 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:58 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:16 msgid "Time" msgstr "时间" -#: ops/models/adhoc.py:326 ops/templates/ops/adhoc_detail.html:106 +#: ops/models/adhoc.py:327 ops/templates/ops/adhoc_detail.html:106 #: ops/templates/ops/adhoc_history.html:55 #: ops/templates/ops/adhoc_history_detail.html:69 #: ops/templates/ops/task_detail.html:84 ops/templates/ops/task_history.html:61 msgid "Is finished" msgstr "是否完成" -#: ops/models/adhoc.py:327 ops/templates/ops/adhoc_history.html:56 +#: ops/models/adhoc.py:328 ops/templates/ops/adhoc_history.html:56 #: ops/templates/ops/task_history.html:62 msgid "Is success" msgstr "是否成功" -#: ops/models/adhoc.py:328 +#: ops/models/adhoc.py:329 msgid "Adhoc raw result" msgstr "结果" -#: ops/models/adhoc.py:329 +#: ops/models/adhoc.py:330 msgid "Adhoc result summary" msgstr "汇总" -#: ops/models/command.py:22 xpack/plugins/cloud/models.py:170 +#: ops/models/command.py:22 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:56 +#: xpack/plugins/cloud/models.py:170 msgid "Result" msgstr "结果" @@ -2455,18 +2334,19 @@ msgid "Version detail" msgstr "版本详情" #: ops/templates/ops/adhoc_detail.html:22 -#: ops/templates/ops/adhoc_history.html:22 ops/views/adhoc.py:127 +#: ops/templates/ops/adhoc_history.html:22 ops/views/adhoc.py:122 msgid "Version run history" msgstr "执行历史" #: ops/templates/ops/adhoc_detail.html:72 #: ops/templates/ops/adhoc_detail.html:77 -#: ops/templates/ops/command_execution_list.html:61 +#: ops/templates/ops/command_execution_list.html:62 #: ops/templates/ops/task_adhoc.html:61 msgid "Run as" msgstr "运行用户" -#: ops/templates/ops/adhoc_detail.html:94 ops/templates/ops/task_list.html:36 +#: ops/templates/ops/adhoc_detail.html:94 ops/templates/ops/task_list.html:28 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:18 msgid "Run times" msgstr "执行次数" @@ -2513,18 +2393,12 @@ msgstr "执行历史" msgid "F/S/T" msgstr "失败/成功/总" -#: ops/templates/ops/adhoc_history.html:58 -#: ops/templates/ops/adhoc_history_detail.html:57 -#: ops/templates/ops/task_adhoc.html:58 ops/templates/ops/task_history.html:64 -msgid "Version" -msgstr "版本" - -#: ops/templates/ops/adhoc_history_detail.html:19 ops/views/adhoc.py:140 +#: ops/templates/ops/adhoc_history_detail.html:19 ops/views/adhoc.py:135 msgid "Run history detail" msgstr "执行历史详情" #: ops/templates/ops/adhoc_history_detail.html:22 -#: ops/templates/ops/command_execution_list.html:62 +#: ops/templates/ops/command_execution_list.html:63 #: terminal/backends/command/models.py:16 msgid "Output" msgstr "输出" @@ -2590,17 +2464,17 @@ msgstr "没有选择系统用户" msgid "Pending" msgstr "" -#: ops/templates/ops/command_execution_list.html:63 +#: ops/templates/ops/command_execution_list.html:64 msgid "Finished" msgstr "结束" #: ops/templates/ops/task_adhoc.html:19 ops/templates/ops/task_detail.html:20 -#: ops/templates/ops/task_history.html:19 ops/views/adhoc.py:75 +#: ops/templates/ops/task_history.html:19 ops/views/adhoc.py:70 msgid "Task detail" msgstr "任务详情" #: ops/templates/ops/task_adhoc.html:22 ops/templates/ops/task_detail.html:23 -#: ops/templates/ops/task_history.html:22 ops/views/adhoc.py:88 +#: ops/templates/ops/task_history.html:22 ops/views/adhoc.py:83 msgid "Task versions" msgstr "任务各版本" @@ -2622,24 +2496,22 @@ msgstr "版本" msgid "Total versions" msgstr "版本数量" -#: ops/templates/ops/task_detail.html:72 -msgid "Latest version" -msgstr "最新版本" - #: ops/templates/ops/task_detail.html:92 msgid "Contents" msgstr "内容" -#: ops/templates/ops/task_list.html:37 +#: ops/templates/ops/task_list.html:29 msgid "Versions" msgstr "版本" -#: ops/templates/ops/task_list.html:71 +#: ops/templates/ops/task_list.html:63 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:137 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:52 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_list.html:52 msgid "Run" msgstr "执行" -#: ops/templates/ops/task_list.html:125 +#: ops/templates/ops/task_list.html:117 msgid "Task start: " msgstr "任务开始: " @@ -2647,22 +2519,25 @@ msgstr "任务开始: " msgid "Update task content: {}" msgstr "更新任务内容: {}" -#: ops/views/adhoc.py:49 ops/views/adhoc.py:74 ops/views/adhoc.py:87 -#: ops/views/adhoc.py:100 ops/views/adhoc.py:113 ops/views/adhoc.py:126 -#: ops/views/adhoc.py:139 ops/views/command.py:43 ops/views/command.py:67 +#: ops/views/adhoc.py:44 ops/views/adhoc.py:69 ops/views/adhoc.py:82 +#: ops/views/adhoc.py:95 ops/views/adhoc.py:108 ops/views/adhoc.py:121 +#: ops/views/adhoc.py:134 ops/views/command.py:43 ops/views/command.py:67 msgid "Ops" msgstr "作业中心" -#: ops/views/adhoc.py:50 templates/_nav.html:66 +#: ops/views/adhoc.py:45 templates/_nav.html:66 msgid "Task list" msgstr "任务列表" -#: ops/views/adhoc.py:101 +#: ops/views/adhoc.py:96 msgid "Task run history" msgstr "执行历史" -#: ops/views/command.py:68 templates/_nav.html:67 templates/_nav.html:79 -#: templates/_nav_user.html:9 +#: ops/views/command.py:44 +msgid "Command execution list" +msgstr "命令执行列表" + +#: ops/views/command.py:68 templates/_nav_user.html:9 msgid "Command execution" msgstr "命令执行" @@ -2670,11 +2545,11 @@ msgstr "命令执行" msgid "Organization" msgstr "组织管理" -#: perms/forms.py:39 perms/models.py:30 perms/models.py:86 +#: perms/forms.py:39 perms/models.py:29 perms/models.py:85 #: perms/templates/perms/asset_permission_list.html:55 #: perms/templates/perms/asset_permission_list.html:75 #: perms/templates/perms/asset_permission_list.html:122 templates/_nav.html:14 -#: users/forms.py:273 users/models/group.py:26 users/models/user.py:61 +#: users/forms.py:253 users/models/group.py:26 users/models/user.py:60 #: users/templates/users/_select_user_modal.html:16 #: users/templates/users/user_detail.html:213 #: users/templates/users/user_list.html:26 @@ -2690,14 +2565,14 @@ msgstr "用户和用户组至少选一个" msgid "Asset or group at least one required" msgstr "资产和节点至少选一个" -#: perms/models.py:36 perms/models.py:89 +#: perms/models.py:35 perms/models.py:88 #: perms/templates/perms/asset_permission_detail.html:90 -#: users/models/user.py:93 users/templates/users/user_detail.html:107 +#: users/models/user.py:92 users/templates/users/user_detail.html:107 #: users/templates/users/user_profile.html:116 msgid "Date expired" msgstr "失效日期" -#: perms/models.py:45 perms/models.py:98 templates/_nav.html:34 +#: perms/models.py:44 perms/models.py:97 templates/_nav.html:34 msgid "Asset permission" msgstr "资产授权" @@ -2710,6 +2585,9 @@ msgstr "用户或用户组" #: perms/templates/perms/asset_permission_asset.html:27 #: perms/templates/perms/asset_permission_detail.html:27 #: perms/templates/perms/asset_permission_user.html:27 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:20 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:23 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:20 msgid "Assets and node" msgstr "资产或节点" @@ -2717,12 +2595,26 @@ msgstr "资产或节点" msgid "Add asset to this permission" msgstr "添加资产" +#: perms/templates/perms/asset_permission_asset.html:97 +#: perms/templates/perms/asset_permission_detail.html:157 +#: perms/templates/perms/asset_permission_user.html:97 +#: perms/templates/perms/asset_permission_user.html:125 +#: settings/templates/settings/terminal_setting.html:95 +#: settings/templates/settings/terminal_setting.html:117 +#: users/templates/users/user_group_detail.html:95 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:93 +#: xpack/plugins/orgs/templates/orgs/org_detail.html:93 +#: xpack/plugins/orgs/templates/orgs/org_detail.html:130 +msgid "Add" +msgstr "添加" + #: perms/templates/perms/asset_permission_asset.html:108 msgid "Add node to this permission" msgstr "添加节点" #: perms/templates/perms/asset_permission_asset.html:125 #: users/templates/users/user_detail.html:230 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:121 msgid "Join" msgstr "加入" @@ -2810,6 +2702,515 @@ msgstr "资产授权用户列表" msgid "Asset permission asset list" msgstr "资产授权资产列表" +#: settings/api.py:23 +msgid "Test mail sent to {}, please check" +msgstr "邮件已经发送{}, 请检查" + +#: settings/api.py:47 +msgid "Test ldap success" +msgstr "连接LDAP成功" + +#: settings/api.py:77 settings/utils.py:23 +msgid "Search no entry matched in ou {}" +msgstr "在ou:{}中没有匹配条目" + +#: settings/api.py:86 +msgid "Match {} s users" +msgstr "匹配 {} 个用户" + +#: settings/api.py:109 +msgid "" +"User is not currently selected, please check the user you want to import" +msgstr "当前无勾选用户,请勾选你想要导入的用户" + +#: settings/api.py:139 settings/api.py:175 +msgid "" +"Error: Account invalid (Please make sure the information such as Access key " +"or Secret key is correct)" +msgstr "错误:账户无效 (请确保 Access key 或 Secret key 等信息正确)" + +#: settings/api.py:145 settings/api.py:181 +msgid "Create succeed" +msgstr "创建成功" + +#: settings/api.py:163 settings/api.py:201 +#: settings/templates/settings/terminal_setting.html:151 +msgid "Delete succeed" +msgstr "删除成功" + +#: settings/forms.py:60 +msgid "Current SITE URL" +msgstr "当前站点URL" + +#: settings/forms.py:64 +msgid "User Guide URL" +msgstr "用户向导URL" + +#: settings/forms.py:65 +msgid "User first login update profile done redirect to it" +msgstr "用户第一次登录,修改profile后重定向到地址" + +#: settings/forms.py:68 +msgid "Email Subject Prefix" +msgstr "Email主题前缀" + +#: settings/forms.py:69 +msgid "Tips: Some word will be intercept by mail provider" +msgstr "提示: 一些关键字可能会被邮件提供商拦截,如 跳板机、Jumpserver" + +#: settings/forms.py:75 +msgid "SMTP host" +msgstr "SMTP主机" + +#: settings/forms.py:77 +msgid "SMTP port" +msgstr "SMTP端口" + +#: settings/forms.py:79 +msgid "SMTP user" +msgstr "SMTP账号" + +#: settings/forms.py:82 +msgid "SMTP password" +msgstr "SMTP密码" + +#: settings/forms.py:83 +msgid "Some provider use token except password" +msgstr "一些邮件提供商需要输入的是Token" + +#: settings/forms.py:86 settings/forms.py:125 +msgid "Use SSL" +msgstr "使用SSL" + +#: settings/forms.py:87 +msgid "If SMTP port is 465, may be select" +msgstr "如果SMTP端口是465,通常需要启用SSL" + +#: settings/forms.py:90 +msgid "Use TLS" +msgstr "使用TLS" + +#: settings/forms.py:91 +msgid "If SMTP port is 587, may be select" +msgstr "如果SMTP端口是587,通常需要启用TLS" + +#: settings/forms.py:97 +msgid "LDAP server" +msgstr "LDAP地址" + +#: settings/forms.py:100 +msgid "Bind DN" +msgstr "绑定DN" + +#: settings/forms.py:107 +msgid "User OU" +msgstr "用户OU" + +#: settings/forms.py:108 +msgid "Use | split User OUs" +msgstr "使用|分隔各OU" + +#: settings/forms.py:112 +msgid "User search filter" +msgstr "用户过滤器" + +#: settings/forms.py:113 +#, python-format +msgid "Choice may be (cn|uid|sAMAccountName)=%(user)s)" +msgstr "可能的选项是(cn或uid或sAMAccountName=%(user)s)" + +#: settings/forms.py:116 +msgid "User attr map" +msgstr "LDAP属性映射" + +#: settings/forms.py:118 +msgid "" +"User attr map present how to map LDAP user attr to jumpserver, username,name," +"email is jumpserver attr" +msgstr "" +"用户属性映射代表怎样将LDAP中用户属性映射到jumpserver用户上,username, name," +"email 是jumpserver的属性" + +#: settings/forms.py:127 +msgid "Enable LDAP auth" +msgstr "启用LDAP认证" + +#: settings/forms.py:136 +msgid "All" +msgstr "全部" + +#: settings/forms.py:137 +msgid "Auto" +msgstr "自动" + +#: settings/forms.py:144 +msgid "Password auth" +msgstr "密码认证" + +#: settings/forms.py:147 +msgid "Public key auth" +msgstr "密钥认证" + +#: settings/forms.py:150 +msgid "Heartbeat interval" +msgstr "心跳间隔" + +#: settings/forms.py:154 +msgid "List sort by" +msgstr "资产列表排序" + +#: settings/forms.py:157 +msgid "List page size" +msgstr "资产分页每页数量" + +#: settings/forms.py:160 +msgid "Session keep duration" +msgstr "会话保留时长" + +#: settings/forms.py:161 +msgid "" +"Units: days, Session, record, command will be delete if more than duration, " +"only in database" +msgstr "" +"单位:天。 会话、录像、命令记录超过该时长将会被删除(仅影响数据库存储, oss等不" +"受影响)" + +#: settings/forms.py:165 +msgid "Telnet login regex" +msgstr "Telnet 成功正则表达式" + +#: settings/forms.py:166 +msgid "ex: Last\\s*login|success|成功" +msgstr "" +"登录telnet服务器成功后的提示正则表达式,如: Last\\s*login|success|成功 " + +#: settings/forms.py:177 +msgid "MFA Secondary certification" +msgstr "MFA 二次认证" + +#: settings/forms.py:179 +msgid "" +"After opening, the user login must use MFA secondary authentication (valid " +"for all users, including administrators)" +msgstr "开启后,用户登录必须使用MFA二次认证(对所有用户有效,包括管理员)" + +#: settings/forms.py:185 +msgid "Limit the number of login failures" +msgstr "限制登录失败次数" + +#: settings/forms.py:189 +msgid "No logon interval" +msgstr "禁止登录时间间隔" + +#: settings/forms.py:191 +msgid "" +"Tip: (unit/minute) if the user has failed to log in for a limited number of " +"times, no login is allowed during this time interval." +msgstr "" +"提示:(单位:分)当用户登录失败次数达到限制后,那么在此时间间隔内禁止登录" + +#: settings/forms.py:197 +msgid "Connection max idle time" +msgstr "SSH最大空闲时间" + +#: settings/forms.py:199 +msgid "" +"If idle time more than it, disconnect connection(only ssh now) Unit: minute" +msgstr "提示:(单位:分)如果超过该配置没有操作,连接会被断开(仅ssh)" + +#: settings/forms.py:205 +msgid "Password expiration time" +msgstr "密码过期时间" + +#: settings/forms.py:208 +msgid "" +"Tip: (unit: day) If the user does not update the password during the time, " +"the user password will expire failure;The password expiration reminder mail " +"will be automatic sent to the user by system within 5 days (daily) before " +"the password expires" +msgstr "" +"提示:(单位:天)如果用户在此期间没有更新密码,用户密码将过期失效; 密码过期" +"提醒邮件将在密码过期前5天内由系统(每天)自动发送给用户" + +#: settings/forms.py:217 +msgid "Password minimum length" +msgstr "密码最小长度 " + +#: settings/forms.py:221 +msgid "Must contain capital letters" +msgstr "必须包含大写字母" + +#: settings/forms.py:223 +msgid "" +"After opening, the user password changes and resets must contain uppercase " +"letters" +msgstr "开启后,用户密码修改、重置必须包含大写字母" + +#: settings/forms.py:228 +msgid "Must contain lowercase letters" +msgstr "必须包含小写字母" + +#: settings/forms.py:229 +msgid "" +"After opening, the user password changes and resets must contain lowercase " +"letters" +msgstr "开启后,用户密码修改、重置必须包含小写字母" + +#: settings/forms.py:234 +msgid "Must contain numeric characters" +msgstr "必须包含数字字符" + +#: settings/forms.py:235 +msgid "" +"After opening, the user password changes and resets must contain numeric " +"characters" +msgstr "开启后,用户密码修改、重置必须包含数字字符" + +#: settings/forms.py:240 +msgid "Must contain special characters" +msgstr "必须包含特殊字符" + +#: settings/forms.py:241 +msgid "" +"After opening, the user password changes and resets must contain special " +"characters" +msgstr "开启后,用户密码修改、重置必须包含特殊字符" + +#: settings/models.py:126 users/templates/users/reset_password.html:68 +#: users/templates/users/user_profile.html:20 +msgid "Setting" +msgstr "设置" + +#: settings/templates/settings/_ldap_list_users_modal.html:7 +msgid "Ldap users" +msgstr "Ldap 用户列表" + +#: settings/templates/settings/_ldap_list_users_modal.html:36 +#: users/models/user.py:56 users/templates/users/user_detail.html:71 +#: users/templates/users/user_profile.html:59 +msgid "Email" +msgstr "邮件" + +#: settings/templates/settings/_ldap_list_users_modal.html:37 +msgid "Is imported" +msgstr "是否已经导入" + +#: settings/templates/settings/basic_setting.html:15 +#: settings/templates/settings/email_setting.html:15 +#: settings/templates/settings/ldap_setting.html:15 +#: settings/templates/settings/security_setting.html:15 +#: settings/templates/settings/terminal_setting.html:16 +#: settings/templates/settings/terminal_setting.html:46 settings/views.py:19 +msgid "Basic setting" +msgstr "基本设置" + +#: settings/templates/settings/basic_setting.html:18 +#: settings/templates/settings/email_setting.html:18 +#: settings/templates/settings/ldap_setting.html:18 +#: settings/templates/settings/security_setting.html:18 +#: settings/templates/settings/terminal_setting.html:20 settings/views.py:45 +msgid "Email setting" +msgstr "邮件设置" + +#: settings/templates/settings/basic_setting.html:21 +#: settings/templates/settings/email_setting.html:21 +#: settings/templates/settings/ldap_setting.html:21 +#: settings/templates/settings/security_setting.html:21 +#: settings/templates/settings/terminal_setting.html:24 settings/views.py:71 +msgid "LDAP setting" +msgstr "LDAP设置" + +#: settings/templates/settings/basic_setting.html:24 +#: settings/templates/settings/email_setting.html:24 +#: settings/templates/settings/ldap_setting.html:24 +#: settings/templates/settings/security_setting.html:24 +#: settings/templates/settings/terminal_setting.html:28 settings/views.py:100 +msgid "Terminal setting" +msgstr "终端设置" + +#: settings/templates/settings/basic_setting.html:27 +#: settings/templates/settings/email_setting.html:27 +#: settings/templates/settings/ldap_setting.html:27 +#: settings/templates/settings/security_setting.html:27 +#: settings/templates/settings/security_setting.html:42 +#: settings/templates/settings/terminal_setting.html:31 settings/views.py:152 +msgid "Security setting" +msgstr "安全设置" + +#: settings/templates/settings/command_storage_create.html:52 +msgid "Tips: If there are multiple hosts, separate them with a comma (,)" +msgstr "提示: 如果有多台主机,请使用逗号 ( , ) 进行分割" + +#: settings/templates/settings/command_storage_create.html:63 +msgid "Index" +msgstr "索引" + +#: settings/templates/settings/command_storage_create.html:70 +msgid "Doc type" +msgstr "文档类型" + +#: settings/templates/settings/ldap_setting.html:65 +msgid "Sync User" +msgstr "同步用户" + +#: settings/templates/settings/replay_storage_create.html:66 +msgid "Bucket" +msgstr "桶名称" + +#: settings/templates/settings/replay_storage_create.html:73 +msgid "Access key" +msgstr "" + +#: settings/templates/settings/replay_storage_create.html:80 +msgid "Secret key" +msgstr "" + +#: settings/templates/settings/replay_storage_create.html:87 +msgid "Container name" +msgstr "容器名称" + +#: settings/templates/settings/replay_storage_create.html:94 +msgid "Account name" +msgstr "账户名称" + +#: settings/templates/settings/replay_storage_create.html:101 +msgid "Account key" +msgstr "账户密钥" + +#: settings/templates/settings/replay_storage_create.html:108 +msgid "Endpoint" +msgstr "端点" + +#: settings/templates/settings/replay_storage_create.html:113 +#, python-brace-format +msgid "OSS: http://{REGION_NAME}.aliyuncs.com" +msgstr "OSS: http://{REGION_NAME}.aliyuncs.com" + +#: settings/templates/settings/replay_storage_create.html:115 +msgid "Example: http://oss-cn-hangzhou.aliyuncs.com" +msgstr "如: http://oss-cn-hangzhou.aliyuncs.com" + +#: settings/templates/settings/replay_storage_create.html:117 +#, python-brace-format +msgid "S3: http://s3.{REGION_NAME}.amazonaws.com" +msgstr "S3: http://s3.{REGION_NAME}.amazonaws.com" + +#: settings/templates/settings/replay_storage_create.html:118 +#, python-brace-format +msgid "S3(China): http://s3.{REGION_NAME}.amazonaws.com.cn" +msgstr "S3(中国): http://s3.{REGION_NAME}.amazonaws.com.cn" + +#: settings/templates/settings/replay_storage_create.html:119 +msgid "Example: http://s3.cn-north-1.amazonaws.com.cn" +msgstr "如: http://s3.cn-north-1.amazonaws.com.cn" + +#: settings/templates/settings/replay_storage_create.html:125 +msgid "Endpoint suffix" +msgstr "端点后缀" + +#: settings/templates/settings/replay_storage_create.html:135 +#: xpack/plugins/cloud/models.py:186 +#: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:83 +#: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:64 +msgid "Region" +msgstr "地域" + +#: settings/templates/settings/replay_storage_create.html:140 +msgid "Beijing: cn-north-1" +msgstr "北京: cn-north-1" + +#: settings/templates/settings/replay_storage_create.html:141 +msgid "Ningxia: cn-northwest-1" +msgstr "宁夏: cn-northwest-1" + +#: settings/templates/settings/replay_storage_create.html:142 +msgid "More" +msgstr "更多" + +#: settings/templates/settings/replay_storage_create.html:246 +msgid "Submitting" +msgstr "提交中" + +#: settings/templates/settings/security_setting.html:46 +msgid "Password check rule" +msgstr "密码校验规则" + +#: settings/templates/settings/terminal_setting.html:76 terminal/forms.py:27 +#: terminal/models.py:26 +msgid "Command storage" +msgstr "命令存储" + +#: settings/templates/settings/terminal_setting.html:98 terminal/forms.py:32 +#: terminal/models.py:27 +msgid "Replay storage" +msgstr "录像存储" + +#: settings/templates/settings/terminal_setting.html:154 +msgid "Delete failed" +msgstr "删除失败" + +#: settings/templates/settings/terminal_setting.html:159 +msgid "Are you sure about deleting it?" +msgstr "您确定删除吗?" + +#: settings/utils.py:30 +msgid "Have user but attr mapping error" +msgstr "有用户但attr映射错误" + +#: settings/utils.py:60 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:86 +msgid "No" +msgstr "否" + +#: settings/utils.py:69 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:84 +msgid "Yes" +msgstr "是" + +#: settings/utils.py:137 +msgid "" +"Import {} users successfully; import {} users failed, the database already " +"exists with the same name" +msgstr "导入 {} 个用户成功; 导入 {} 这些用户失败,数据库已经存在同名的用户" + +#: settings/utils.py:142 +msgid "" +"Import {} users successfully; import {} users failed, the database already " +"exists with the same name; import {}users failed, Because’TypeError' object " +"has no attribute 'keys'" +msgstr "" +"导入 {} 个用户成功; 导入 {} 这些用户失败,数据库已经存在同名的用户; 导入 {} " +"这些用户失败,因为对象没有属性'keys'" + +#: settings/utils.py:148 +msgid "Import {} users successfully" +msgstr "导入 {} 个用户成功" + +#: settings/utils.py:151 +msgid "" +"Import {} users successfully;import {} users failed, Because’TypeError' " +"object has no attribute 'keys'" +msgstr "导入 {} 个用户成功; 导入 {} 这些用户失败,因为对象没有属性'keys'" + +#: settings/views.py:18 settings/views.py:44 settings/views.py:70 +#: settings/views.py:99 settings/views.py:126 settings/views.py:138 +#: settings/views.py:151 templates/_nav.html:107 +msgid "Settings" +msgstr "系统设置" + +#: settings/views.py:29 settings/views.py:55 settings/views.py:81 +#: settings/views.py:112 settings/views.py:162 +msgid "Update setting successfully" +msgstr "更新设置成功" + +#: settings/views.py:127 +msgid "Create replay storage" +msgstr "创建录像存储" + +#: settings/views.py:139 +msgid "Create command storage" +msgstr "创建命令存储" + #: templates/_copyright.html:2 templates/_footer.html:8 msgid " Beijing Duizhan Tech, Inc. " msgstr " 北京堆栈科技有限公司 " @@ -2826,7 +3227,7 @@ msgstr "文档" msgid "Commercial support" msgstr "商业支持" -#: templates/_header_bar.html:89 templates/_nav_user.html:14 users/forms.py:141 +#: templates/_header_bar.html:89 templates/_nav_user.html:14 users/forms.py:121 #: users/templates/users/_user.html:43 #: users/templates/users/first_login.html:39 #: users/templates/users/user_password_update.html:40 @@ -2850,7 +3251,7 @@ msgid "Logout" msgstr "注销登录" #: templates/_header_bar.html:101 users/templates/users/login.html:46 -#: users/templates/users/login.html:72 users/templates/users/new_login.html:96 +#: users/templates/users/login.html:72 users/templates/users/new_login.html:119 msgid "Login" msgstr "登录" @@ -2920,7 +3321,7 @@ msgstr "" #: templates/_nav.html:10 users/views/group.py:27 users/views/group.py:43 #: users/views/group.py:59 users/views/group.py:75 users/views/group.py:91 -#: users/views/login.py:360 users/views/user.py:68 users/views/user.py:83 +#: users/views/login.py:151 users/views/user.py:68 users/views/user.py:83 #: users/views/user.py:113 users/views/user.py:194 users/views/user.py:355 #: users/views/user.py:405 users/views/user.py:445 msgid "Users" @@ -2969,6 +3370,10 @@ msgstr "终端管理" msgid "Job Center" msgstr "作业中心" +#: templates/_nav.html:67 templates/_nav.html:79 +msgid "Batch command" +msgstr "批量命令" + #: templates/_nav.html:85 msgid "XPack" msgstr "" @@ -2996,7 +3401,7 @@ msgstr "验证码" #: templates/flash_message_standalone.html:35 #: users/templates/users/login.html:27 users/templates/users/login_otp.html:27 -#: users/templates/users/new_login.html:56 +#: users/templates/users/new_login.html:82 #: users/templates/users/reset_password.html:25 #: xpack/plugins/interface/models.py:36 msgid "Welcome to the Jumpserver open source fortress" @@ -3187,10 +3592,6 @@ msgstr "" msgid "Remote Address" msgstr "远端地址" -#: terminal/models.py:24 -msgid "SSH Port" -msgstr "SSH端口" - #: terminal/models.py:25 msgid "HTTP Port" msgstr "HTTP端口" @@ -3231,7 +3632,7 @@ msgstr "最后活跃日期" msgid "Date end" msgstr "结束日期" -#: terminal/models.py:234 +#: terminal/models.py:242 msgid "Args" msgstr "参数" @@ -3277,28 +3678,24 @@ msgstr "登录来源" msgid "Duration" msgstr "时长" -#: terminal/templates/terminal/session_list.html:106 -msgid "Monitor" -msgstr "监控" - -#: terminal/templates/terminal/session_list.html:108 -#: terminal/templates/terminal/session_list.html:110 +#: terminal/templates/terminal/session_list.html:107 +#: terminal/templates/terminal/session_list.html:109 msgid "Terminate" msgstr "终断" -#: terminal/templates/terminal/session_list.html:122 +#: terminal/templates/terminal/session_list.html:121 msgid "Terminate selected" msgstr "终断所选" -#: terminal/templates/terminal/session_list.html:123 +#: terminal/templates/terminal/session_list.html:122 msgid "Confirm finished" msgstr "确认已完成" -#: terminal/templates/terminal/session_list.html:143 +#: terminal/templates/terminal/session_list.html:142 msgid "Terminate task send, waiting ..." msgstr "终断任务已发送,请等待" -#: terminal/templates/terminal/session_list.html:156 +#: terminal/templates/terminal/session_list.html:155 msgid "Finish session success" msgstr "标记会话完成成功" @@ -3368,87 +3765,11 @@ msgid "" "You should use your ssh client tools connect terminal: {}

    {}" msgstr "你可以使用ssh客户端工具连接终端" -#: users/api/auth.py:40 users/templates/users/login.html:52 -#: users/templates/users/new_login.html:71 -msgid "Log in frequently and try again later" -msgstr "登录频繁, 稍后重试" - -#: users/api/auth.py:67 -msgid "The user {} password has expired, please update." -msgstr "用户 {} 密码已经过期,请更新。" - -#: users/api/auth.py:92 -msgid "Please carry seed value and conduct MFA secondary certification" -msgstr "请携带seed值, 进行MFA二次认证" - -#: users/api/auth.py:204 -msgid "Please verify the user name and password first" -msgstr "请先进行用户名和密码验证" - -#: users/api/auth.py:216 -msgid "MFA certification failed" -msgstr "MFA认证失败" - -#: users/api/user.py:145 +#: users/api/user.py:146 msgid "Could not reset self otp, use profile reset instead" msgstr "不能再该页面重置MFA, 请去个人信息页面重置" -#: users/authentication.py:53 -msgid "Invalid signature header. No credentials provided." -msgstr "" - -#: users/authentication.py:56 -msgid "Invalid signature header. Signature string should not contain spaces." -msgstr "" - -#: users/authentication.py:63 -msgid "Invalid signature header. Format like AccessKeyId:Signature" -msgstr "" - -#: users/authentication.py:67 -msgid "" -"Invalid signature header. Signature string should not contain invalid " -"characters." -msgstr "" - -#: users/authentication.py:87 users/authentication.py:103 -msgid "Invalid signature." -msgstr "" - -#: users/authentication.py:94 -msgid "HTTP header: Date not provide or not %a, %d %b %Y %H:%M:%S GMT" -msgstr "" - -#: users/authentication.py:99 -msgid "Expired, more than 15 minutes" -msgstr "" - -#: users/authentication.py:106 -msgid "User disabled." -msgstr "用户已禁用" - -#: users/authentication.py:121 -msgid "Invalid token header. No credentials provided." -msgstr "" - -#: users/authentication.py:124 -msgid "Invalid token header. Sign string should not contain spaces." -msgstr "" - -#: users/authentication.py:131 -msgid "" -"Invalid token header. Sign string should not contain invalid characters." -msgstr "" - -#: users/authentication.py:142 -msgid "Invalid token or cache refreshed." -msgstr "" - -#: users/forms.py:41 -msgid "MFA code" -msgstr "MFA 验证码" - -#: users/forms.py:52 users/models/user.py:65 +#: users/forms.py:32 users/models/user.py:64 #: users/templates/users/_select_user_modal.html:15 #: users/templates/users/user_detail.html:87 #: users/templates/users/user_list.html:25 @@ -3456,31 +3777,31 @@ msgstr "MFA 验证码" msgid "Role" msgstr "角色" -#: users/forms.py:55 users/forms.py:220 +#: users/forms.py:35 users/forms.py:200 msgid "ssh public key" msgstr "ssh公钥" -#: users/forms.py:56 users/forms.py:221 +#: users/forms.py:36 users/forms.py:201 msgid "ssh-rsa AAAA..." msgstr "" -#: users/forms.py:57 +#: users/forms.py:37 msgid "Paste user id_rsa.pub here." msgstr "复制用户公钥到这里" -#: users/forms.py:71 users/templates/users/user_detail.html:221 +#: users/forms.py:51 users/templates/users/user_detail.html:221 msgid "Join user groups" msgstr "添加到用户组" -#: users/forms.py:105 users/forms.py:235 +#: users/forms.py:85 users/forms.py:215 msgid "Public key should not be the same as your old one." msgstr "不能和原来的密钥相同" -#: users/forms.py:109 users/forms.py:239 users/serializers/v1.py:38 +#: users/forms.py:89 users/forms.py:219 users/serializers/v1.py:38 msgid "Not a valid ssh public key" msgstr "ssh密钥不合法" -#: users/forms.py:147 +#: users/forms.py:127 msgid "" "Tip: when enabled, you will enter the MFA binding process the next time you " "log in. you can also directly bind in \"personal information -> quick " @@ -3489,11 +3810,11 @@ msgstr "" "提示:启用之后您将会在下次登录时进入MFA绑定流程;您也可以在(个人信息->快速修" "改->更改MFA设置)中直接绑定!" -#: users/forms.py:157 +#: users/forms.py:137 msgid "* Enable MFA authentication to make the account more secure." msgstr "* 启用MFA认证,使账号更加安全." -#: users/forms.py:167 +#: users/forms.py:147 msgid "" "In order to protect you and your company, please keep your account, password " "and key sensitive information properly. (for example: setting complex " @@ -3502,163 +3823,96 @@ msgstr "" "为了保护您和公司的安全,请妥善保管您的账户、密码和密钥等重要敏感信息;(如:" "设置复杂密码,启用MFA认证)" -#: users/forms.py:174 users/templates/users/first_login.html:48 +#: users/forms.py:154 users/templates/users/first_login.html:48 #: users/templates/users/first_login.html:107 #: users/templates/users/first_login.html:130 msgid "Finish" msgstr "完成" -#: users/forms.py:180 +#: users/forms.py:160 msgid "Old password" msgstr "原来密码" -#: users/forms.py:185 +#: users/forms.py:165 msgid "New password" msgstr "新密码" -#: users/forms.py:190 +#: users/forms.py:170 msgid "Confirm password" msgstr "确认密码" -#: users/forms.py:200 +#: users/forms.py:180 msgid "Old password error" msgstr "原来密码错误" -#: users/forms.py:208 +#: users/forms.py:188 msgid "Password does not match" msgstr "密码不一致" -#: users/forms.py:218 +#: users/forms.py:198 msgid "Automatically configure and download the SSH key" msgstr "自动配置并下载SSH密钥" -#: users/forms.py:222 +#: users/forms.py:202 msgid "Paste your id_rsa.pub here." msgstr "复制你的公钥到这里" -#: users/forms.py:250 users/models/user.py:85 -#: users/templates/users/first_login.html:42 -#: users/templates/users/user_password_update.html:46 -#: users/templates/users/user_profile.html:68 -#: users/templates/users/user_profile_update.html:43 -#: users/templates/users/user_pubkey_update.html:43 -msgid "Public key" -msgstr "ssh公钥" - -#: users/forms.py:256 users/forms.py:261 users/forms.py:307 +#: users/forms.py:236 users/forms.py:241 users/forms.py:287 #: xpack/plugins/orgs/forms.py:30 msgid "Select users" msgstr "选择用户" -#: users/models/authentication.py:39 -msgid "Private Token" -msgstr "ssh密钥" - -#: users/models/authentication.py:53 users/templates/users/user_detail.html:98 -msgid "Disabled" -msgstr "禁用" - -#: users/models/authentication.py:55 users/models/authentication.py:65 -msgid "-" -msgstr "" - -#: users/models/authentication.py:66 -msgid "Username/password check failed" -msgstr "用户名/密码 校验失败" - -#: users/models/authentication.py:67 -msgid "MFA authentication failed" -msgstr "MFA 认证失败" - -#: users/models/authentication.py:68 -msgid "Username does not exist" -msgstr "用户名不存在" - -#: users/models/authentication.py:69 -msgid "Password expired" -msgstr "密码过期" - -#: users/models/authentication.py:74 xpack/plugins/cloud/models.py:164 -#: xpack/plugins/cloud/models.py:178 -msgid "Failed" -msgstr "失败" - -#: users/models/authentication.py:78 -msgid "Login type" -msgstr "登录方式" - -#: users/models/authentication.py:79 -msgid "Login ip" -msgstr "登录IP" - -#: users/models/authentication.py:80 -msgid "Login city" -msgstr "登录城市" - -#: users/models/authentication.py:81 -msgid "User agent" -msgstr "Agent" - -#: users/models/authentication.py:85 -msgid "Date login" -msgstr "登录日期" - -#: users/models/user.py:32 users/models/user.py:437 +#: users/models/user.py:31 users/models/user.py:453 msgid "Administrator" msgstr "管理员" -#: users/models/user.py:34 +#: users/models/user.py:33 msgid "Application" msgstr "应用程序" -#: users/models/user.py:37 users/templates/users/user_profile.html:92 +#: users/models/user.py:36 users/templates/users/user_profile.html:92 #: users/templates/users/user_profile.html:159 #: users/templates/users/user_profile.html:162 msgid "Disable" msgstr "禁用" -#: users/models/user.py:38 users/templates/users/user_profile.html:90 +#: users/models/user.py:37 users/templates/users/user_profile.html:90 #: users/templates/users/user_profile.html:166 msgid "Enable" msgstr "启用" -#: users/models/user.py:39 users/templates/users/user_profile.html:88 +#: users/models/user.py:38 users/templates/users/user_profile.html:88 msgid "Force enable" msgstr "强制启用" -#: users/models/user.py:57 users/templates/users/user_detail.html:71 -#: users/templates/users/user_profile.html:59 -msgid "Email" -msgstr "邮件" - -#: users/models/user.py:68 +#: users/models/user.py:67 msgid "Avatar" msgstr "头像" -#: users/models/user.py:71 users/templates/users/user_detail.html:82 +#: users/models/user.py:70 users/templates/users/user_detail.html:82 msgid "Wechat" msgstr "微信" -#: users/models/user.py:100 users/templates/users/user_detail.html:103 +#: users/models/user.py:99 users/templates/users/user_detail.html:103 #: users/templates/users/user_list.html:27 #: users/templates/users/user_profile.html:100 msgid "Source" msgstr "用户来源" -#: users/models/user.py:104 +#: users/models/user.py:103 msgid "Date password last updated" msgstr "最后更新密码日期" -#: users/models/user.py:128 users/templates/users/user_update.html:22 -#: users/views/login.py:254 users/views/login.py:313 users/views/user.py:418 +#: users/models/user.py:129 users/templates/users/user_update.html:22 +#: users/views/login.py:45 users/views/login.py:104 users/views/user.py:418 msgid "User auth from {}, go there change password" msgstr "用户认证源来自 {}, 请去相应系统修改密码" -#: users/models/user.py:440 +#: users/models/user.py:456 msgid "Administrator is the super user of system" msgstr "Administrator是初始的超级管理员" -#: users/serializers/v2.py:40 +#: users/serializers_v2/user.py:36 msgid "name not unique" msgstr "名称重复" @@ -3754,7 +4008,7 @@ msgstr "获取更多信息" #: users/templates/users/forgot_password.html:11 #: users/templates/users/forgot_password.html:31 -#: users/templates/users/login.html:83 users/templates/users/new_login.html:100 +#: users/templates/users/login.html:83 users/templates/users/new_login.html:123 msgid "Forgot password" msgstr "忘记密码" @@ -3794,11 +4048,11 @@ msgstr "" msgid "Changes the world, starting with a little bit." msgstr "改变世界,从一点点开始。" -#: users/templates/users/login.html:54 users/templates/users/new_login.html:73 +#: users/templates/users/login.html:54 users/templates/users/new_login.html:99 msgid "The user password has expired" msgstr "用户密码已过期" -#: users/templates/users/login.html:57 users/templates/users/new_login.html:76 +#: users/templates/users/login.html:57 users/templates/users/new_login.html:102 msgid "Captcha invalid" msgstr "验证码错误" @@ -3838,7 +4092,7 @@ msgstr "6位数字" msgid "Can't provide security? Please contact the administrator!" msgstr "如果不能提供MFA验证码,请联系管理员!" -#: users/templates/users/new_login.html:61 +#: users/templates/users/new_login.html:87 msgid "Welcome back, please enter username and password to login" msgstr "欢迎回来,请输入用户名和密码登录" @@ -3874,7 +4128,7 @@ msgid "Always young, always with tears in my eyes. Stay foolish Stay hungry" msgstr "永远年轻,永远热泪盈眶 stay foolish stay hungry" #: users/templates/users/reset_password.html:46 -#: users/templates/users/user_detail.html:373 users/utils.py:81 +#: users/templates/users/user_detail.html:373 users/utils.py:77 msgid "Reset password" msgstr "重置密码" @@ -4198,11 +4452,11 @@ msgstr "新的公钥已设置成功,请下载对应的私钥" msgid "Update user" msgstr "更新用户" -#: users/utils.py:42 +#: users/utils.py:38 msgid "Create account successfully" msgstr "创建账户成功" -#: users/utils.py:44 +#: users/utils.py:40 #, python-format msgid "" "\n" @@ -4247,7 +4501,7 @@ msgstr "" "
    \n" " " -#: users/utils.py:83 +#: users/utils.py:79 #, python-format msgid "" "\n" @@ -4291,11 +4545,11 @@ msgstr "" "
    \n" " " -#: users/utils.py:114 +#: users/utils.py:110 msgid "Security notice" msgstr "安全通知" -#: users/utils.py:116 +#: users/utils.py:112 #, python-format msgid "" "\n" @@ -4344,11 +4598,11 @@ msgstr "" "
    \n" " " -#: users/utils.py:152 +#: users/utils.py:148 msgid "SSH Key Reset" msgstr "重置ssh密钥" -#: users/utils.py:154 +#: users/utils.py:150 #, python-format msgid "" "\n" @@ -4373,15 +4627,15 @@ msgstr "" "
    \n" " " -#: users/utils.py:187 +#: users/utils.py:183 msgid "User not exist" msgstr "用户不存在" -#: users/utils.py:189 +#: users/utils.py:185 msgid "Disabled or expired" msgstr "禁用或失效" -#: users/utils.py:202 +#: users/utils.py:198 msgid "Password or SSH public key invalid" msgstr "密码或密钥不合法" @@ -4397,56 +4651,40 @@ msgstr "更新用户组" msgid "User group granted asset" msgstr "用户组授权资产" -#: users/views/login.py:80 -msgid "Please enable cookies and try again." -msgstr "设置你的浏览器支持cookie" - -#: users/views/login.py:202 users/views/user.py:532 users/views/user.py:557 -msgid "MFA code invalid, or ntp sync server time" -msgstr "MFA验证码不正确,或者服务器端时间不对" - -#: users/views/login.py:234 -msgid "Logout success" -msgstr "退出登录成功" - -#: users/views/login.py:235 -msgid "Logout success, return login page" -msgstr "退出登录成功,返回到登录页面" - -#: users/views/login.py:251 +#: users/views/login.py:42 msgid "Email address invalid, please input again" msgstr "邮箱地址错误,重新输入" -#: users/views/login.py:267 +#: users/views/login.py:58 msgid "Send reset password message" msgstr "发送重置密码邮件" -#: users/views/login.py:268 +#: users/views/login.py:59 msgid "Send reset password mail success, login your mail box and follow it " msgstr "" "发送重置邮件成功, 请登录邮箱查看, 按照提示操作 (如果没收到,请等待3-5分钟)" -#: users/views/login.py:281 +#: users/views/login.py:72 msgid "Reset password success" msgstr "重置密码成功" -#: users/views/login.py:282 +#: users/views/login.py:73 msgid "Reset password success, return to login page" msgstr "重置密码成功,返回到登录页面" -#: users/views/login.py:297 users/views/login.py:316 +#: users/views/login.py:88 users/views/login.py:107 msgid "Token invalid or expired" msgstr "Token错误或失效" -#: users/views/login.py:309 +#: users/views/login.py:100 msgid "Password not same" msgstr "密码不一致" -#: users/views/login.py:322 users/views/user.py:128 users/views/user.py:428 +#: users/views/login.py:113 users/views/user.py:128 users/views/user.py:428 msgid "* Your password does not meet the requirements" msgstr "* 您的密码不符合要求" -#: users/views/login.py:360 +#: users/views/login.py:151 msgid "First login" msgstr "首次登录" @@ -4498,6 +4736,193 @@ msgstr "MFA 解绑成功" msgid "MFA disable success, return login page" msgstr "MFA 解绑成功,返回登录页面" +#: xpack/plugins/change_auth_plan/forms.py:20 +msgid "Password length" +msgstr "密码长度" + +#: xpack/plugins/change_auth_plan/forms.py:40 +msgid "* Please enter custom password" +msgstr "* 请输入自定义密码" + +#: xpack/plugins/change_auth_plan/forms.py:50 +msgid "* Please enter a valid crontab expression" +msgstr "* 请输入有效的 crontab 表达式" + +#: xpack/plugins/change_auth_plan/forms.py:86 +#: xpack/plugins/change_auth_plan/models.py:60 +#: xpack/plugins/change_auth_plan/models.py:397 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:65 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:53 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:12 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:13 +msgid "Asset username" +msgstr "资产用户名" + +#: xpack/plugins/change_auth_plan/forms.py:102 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:54 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:81 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:17 +msgid "Periodic perform" +msgstr "定时执行" + +#: xpack/plugins/change_auth_plan/forms.py:106 +msgid "Tips: (Units: hour)" +msgstr "提示:(单位: 时)" + +#: xpack/plugins/change_auth_plan/forms.py:107 +msgid "" +"eg: Every Sunday 03:05 run (5 3 * * 0)
    Tips: Using 5 digits linux " +"crontab expressions (Online tools)
    Note: If both Regularly perform and " +"Cycle perform are set, give priority to Regularly perform" +msgstr "" +"eg:每周日 03:05 执行(5 3 * * 0)
    提示: 使用5位 Linux crontab 表达式" +"(在线工具
    注" +"意: 如果同时设置了定期执行和周期执行,优先使用定期执行" + +#: xpack/plugins/change_auth_plan/meta.py:9 +#: xpack/plugins/change_auth_plan/models.py:110 +#: xpack/plugins/change_auth_plan/models.py:245 +#: xpack/plugins/change_auth_plan/views.py:31 +#: xpack/plugins/change_auth_plan/views.py:47 +#: xpack/plugins/change_auth_plan/views.py:68 +#: xpack/plugins/change_auth_plan/views.py:82 +#: xpack/plugins/change_auth_plan/views.py:109 +#: xpack/plugins/change_auth_plan/views.py:125 +#: xpack/plugins/change_auth_plan/views.py:139 +msgid "Change auth plan" +msgstr "改密计划" + +#: xpack/plugins/change_auth_plan/models.py:52 +msgid "Custom password" +msgstr "自定义密码" + +#: xpack/plugins/change_auth_plan/models.py:53 +msgid "All assets use the same random password" +msgstr "所有资产使用相同的随机密码" + +#: xpack/plugins/change_auth_plan/models.py:54 +msgid "All assets use different random password" +msgstr "所有资产使用不同的随机密码" + +#: xpack/plugins/change_auth_plan/models.py:73 +#: xpack/plugins/change_auth_plan/models.py:141 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:100 +msgid "Cycle perform" +msgstr "周期执行" + +#: xpack/plugins/change_auth_plan/models.py:78 +#: xpack/plugins/change_auth_plan/models.py:139 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:92 +msgid "Regularly perform" +msgstr "定期执行" + +#: xpack/plugins/change_auth_plan/models.py:83 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_create_update.html:45 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:69 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:57 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:16 +msgid "Password strategy" +msgstr "密码策略" + +#: xpack/plugins/change_auth_plan/models.py:87 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:74 +msgid "Password rules" +msgstr "密码规则" + +#: xpack/plugins/change_auth_plan/models.py:249 +msgid "Change auth plan snapshot" +msgstr "改密计划快照" + +#: xpack/plugins/change_auth_plan/models.py:264 +#: xpack/plugins/change_auth_plan/models.py:415 +msgid "Change auth plan execution" +msgstr "改密计划执行" + +#: xpack/plugins/change_auth_plan/models.py:424 +msgid "Change auth plan execution subtask" +msgstr "改密计划执行子任务" + +#: xpack/plugins/change_auth_plan/models.py:442 +msgid "Authentication failed" +msgstr "认证失败" + +#: xpack/plugins/change_auth_plan/models.py:444 +msgid "Connection timeout" +msgstr "连接超时" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:17 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:20 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:17 +#: xpack/plugins/change_auth_plan/views.py:83 +msgid "Plan detail" +msgstr "计划详情" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:23 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:26 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:23 +#: xpack/plugins/change_auth_plan/views.py:126 +msgid "Plan execution list" +msgstr "执行列表" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:76 +msgid "Add asset to this plan" +msgstr "添加资产" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_asset_list.html:104 +msgid "Add node to this plan" +msgstr "添加节点" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:76 +msgid "Length" +msgstr "长度" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:134 +msgid "Execute plan" +msgstr "执行计划" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_detail.html:179 +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:101 +msgid "Execute failed" +msgstr "执行失败" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:31 +msgid "Execution list of plan" +msgstr "执行列表" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_list.html:104 +msgid "Log" +msgstr "日志" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:61 +msgid "Retry" +msgstr "重试" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_execution_subtask_list.html:96 +msgid "Run failed" +msgstr "执行失败" + +#: xpack/plugins/change_auth_plan/templates/change_auth_plan/plan_list.html:5 +#: xpack/plugins/change_auth_plan/views.py:48 +msgid "Create plan" +msgstr "创建计划" + +#: xpack/plugins/change_auth_plan/views.py:32 +msgid "Plan list" +msgstr "计划列表" + +#: xpack/plugins/change_auth_plan/views.py:69 +msgid "Update plan" +msgstr "更新计划" + +#: xpack/plugins/change_auth_plan/views.py:110 +msgid "plan asset list" +msgstr "计划资产列表" + +#: xpack/plugins/change_auth_plan/views.py:140 +msgid "Plan execution task list" +msgstr "执行任务列表" + #: xpack/plugins/cloud/api.py:61 xpack/plugins/cloud/providers/base.py:84 msgid "Account unavailable" msgstr "账户无效" @@ -4534,7 +4959,7 @@ msgstr "选择管理员" #: xpack/plugins/cloud/views.py:41 xpack/plugins/cloud/views.py:57 #: xpack/plugins/cloud/views.py:71 xpack/plugins/cloud/views.py:84 #: xpack/plugins/cloud/views.py:100 xpack/plugins/cloud/views.py:121 -#: xpack/plugins/cloud/views.py:136 xpack/plugins/cloud/views.py:179 +#: xpack/plugins/cloud/views.py:136 xpack/plugins/cloud/views.py:187 msgid "Cloud center" msgstr "云管中心" @@ -4665,7 +5090,7 @@ msgstr "同步历史列表" #: xpack/plugins/cloud/templates/cloud/sync_instance_task_detail.html:28 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_history.html:31 #: xpack/plugins/cloud/templates/cloud/sync_instance_task_instance.html:29 -#: xpack/plugins/cloud/views.py:180 +#: xpack/plugins/cloud/views.py:188 msgid "Sync instance list" msgstr "同步实例列表" @@ -4713,49 +5138,49 @@ msgstr "同步实例任务列表" msgid "Create sync Instance task" msgstr "创建同步实例任务" -#: xpack/plugins/interface/forms.py:16 xpack/plugins/interface/models.py:15 +#: xpack/plugins/interface/forms.py:17 xpack/plugins/interface/models.py:15 msgid "Title of login page" msgstr "登录页面标题" -#: xpack/plugins/interface/forms.py:18 +#: xpack/plugins/interface/forms.py:19 msgid "" "Tips: This will be displayed on the enterprise user login page. (eg: Welcome " "to the Jumpserver open source fortress)" msgstr "提示:将会显示在企业版用户登录页面(eg: 欢迎使用Jumpserver开源堡垒机)" -#: xpack/plugins/interface/forms.py:24 xpack/plugins/interface/models.py:19 +#: xpack/plugins/interface/forms.py:25 xpack/plugins/interface/models.py:19 msgid "Image of login page" msgstr "登录页面图片" -#: xpack/plugins/interface/forms.py:26 +#: xpack/plugins/interface/forms.py:27 msgid "" "Tips: This will be displayed on the enterprise user login page. (suggest " -"image size: 635px*472px)" -msgstr "提示:将会显示在企业版用户登录页面(建议图片大小为: 635px*472px)" +"image size: 492px*472px)" +msgstr "提示:将会显示在企业版用户登录页面(建议图片大小为: 492*472px)" -#: xpack/plugins/interface/forms.py:32 xpack/plugins/interface/models.py:23 +#: xpack/plugins/interface/forms.py:33 xpack/plugins/interface/models.py:23 msgid "Website icon" msgstr "网站图标" -#: xpack/plugins/interface/forms.py:34 +#: xpack/plugins/interface/forms.py:35 msgid "Tips: website icon. (suggest image size: 16px*16px)" msgstr "提示:网站图标(建议图片大小为: 16px*16px)" -#: xpack/plugins/interface/forms.py:39 xpack/plugins/interface/models.py:27 +#: xpack/plugins/interface/forms.py:40 xpack/plugins/interface/models.py:27 msgid "Logo of management page" msgstr "管理页面logo" -#: xpack/plugins/interface/forms.py:41 +#: xpack/plugins/interface/forms.py:42 msgid "" "Tips: This will appear at the top left of the administration page. (suggest " "image size: 185px*55px)" msgstr "提示:将会显示在管理页面左上方(建议图片大小为: 185px*55px)" -#: xpack/plugins/interface/forms.py:47 xpack/plugins/interface/models.py:31 +#: xpack/plugins/interface/forms.py:48 xpack/plugins/interface/models.py:31 msgid "Logo of logout page" msgstr "退出页面logo" -#: xpack/plugins/interface/forms.py:49 +#: xpack/plugins/interface/forms.py:50 msgid "" "Tips: This will be displayed on the enterprise user logout page. (suggest " "image size: 82px*82px)" @@ -4774,7 +5199,7 @@ msgstr "界面设置" msgid "Interface" msgstr "界面" -#: xpack/plugins/license/meta.py:11 xpack/plugins/license/models.py:95 +#: xpack/plugins/license/meta.py:11 xpack/plugins/license/models.py:94 #: xpack/plugins/license/templates/license/license_detail.html:50 #: xpack/plugins/license/views.py:31 msgid "License" @@ -4837,12 +5262,6 @@ msgstr "过期时间" msgid "Unlimited" msgstr "无限制" -#: xpack/plugins/license/templates/license/license_detail.html:71 -#, fuzzy -#| msgid "CPU count" -msgid "Cpu count" -msgstr "CPU数量" - #: xpack/plugins/license/templates/license/license_detail.html:75 msgid "Concurrent connections" msgstr "并发连接" @@ -4911,6 +5330,17 @@ msgstr "创建组织" msgid "Update org" msgstr "更新组织" +#~ msgid "Monitor" +#~ msgstr "监控" + +#~ msgid "Invalid private key" +#~ msgstr "ssh密钥不合法" + +#, fuzzy +#~| msgid "CPU count" +#~ msgid "Cpu count" +#~ msgstr "CPU数量" + #~ msgid "Login Jumpserver" #~ msgstr "登录 Jumpserver" @@ -5023,9 +5453,6 @@ msgstr "更新组织" #~ msgid "* required Must set exact system platform, Windows, Linux ..." #~ msgstr "* required 必须准确设置操作系统平台,如Windows, Linux ..." -#~ msgid "Unblock user successfully. " -#~ msgstr "解除登录限制成功" - #~ msgid "Clear" #~ msgstr "清除" diff --git a/apps/ops/celery/__init__.py b/apps/ops/celery/__init__.py index 04f48299e..b64e20f01 100644 --- a/apps/ops/celery/__init__.py +++ b/apps/ops/celery/__init__.py @@ -6,12 +6,15 @@ from celery import Celery # set the default Django settings module for the 'celery' program. os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'jumpserver.settings') - -from django.conf import settings +from jumpserver import settings +# from django.conf import settings app = Celery('jumpserver') +configs = {k: v for k, v in settings.__dict__.items() if k.startswith('CELERY')} # Using a string here means the worker will not have to # pickle the object when using Windows. -app.config_from_object('django.conf:settings', namespace='CELERY') +# app.config_from_object('django.conf:settings', namespace='CELERY') +app.namespace = 'CELERY' +app.conf.update(configs) app.autodiscover_tasks(lambda: [app_config.split('.')[0] for app_config in settings.INSTALLED_APPS]) diff --git a/apps/ops/celery/logger.py b/apps/ops/celery/logger.py index bfe713d6d..1dd517200 100644 --- a/apps/ops/celery/logger.py +++ b/apps/ops/celery/logger.py @@ -143,7 +143,7 @@ class CeleryTaskFileHandler(CeleryTaskLoggerHandler): def emit(self, record): msg = self.format(record) - if not self.f: + if not self.f or self.f.closed: return self.f.write(msg) self.f.write(self.terminator) diff --git a/apps/ops/celery/utils.py b/apps/ops/celery/utils.py index 1fc2fc103..ea975af78 100644 --- a/apps/ops/celery/utils.py +++ b/apps/ops/celery/utils.py @@ -4,6 +4,7 @@ import json import os from django.conf import settings +from django.utils.timezone import get_current_timezone from django.db.utils import ProgrammingError, OperationalError from django_celery_beat.models import PeriodicTask, IntervalSchedule, CrontabSchedule @@ -49,7 +50,7 @@ def create_or_update_celery_periodic_tasks(tasks): raise SyntaxError("crontab is not valid") kwargs = dict( minute=minute, hour=hour, day_of_week=week, - day_of_month=day, month_of_year=month, + day_of_month=day, month_of_year=month, timezone=get_current_timezone() ) contabs = CrontabSchedule.objects.filter( **kwargs diff --git a/apps/ops/inventory.py b/apps/ops/inventory.py index 7e21d156d..e4f11bec1 100644 --- a/apps/ops/inventory.py +++ b/apps/ops/inventory.py @@ -4,43 +4,17 @@ from .ansible.inventory import BaseInventory from assets.utils import get_assets_by_id_list, get_system_user_by_id +from common.utils import get_logger + __all__ = [ - 'JMSInventory' + 'JMSInventory', 'JMSCustomInventory', ] -class JMSInventory(BaseInventory): - """ - JMS Inventory is the manager with jumpserver assets, so you can - write you own manager, construct you inventory - """ - def __init__(self, assets, run_as_admin=False, run_as=None, become_info=None): - """ - :param host_id_list: ["test1", ] - :param run_as_admin: True 是否使用管理用户去执行, 每台服务器的管理用户可能不同 - :param run_as: 是否统一使用某个系统用户去执行 - :param become_info: 是否become成某个用户去执行 - """ - self.assets = assets - self.using_admin = run_as_admin - self.run_as = run_as - self.become_info = become_info +logger = get_logger(__file__) - host_list = [] - for asset in assets: - info = self.convert_to_ansible(asset, run_as_admin=run_as_admin) - host_list.append(info) - - if run_as: - run_user_info = self.get_run_user_info() - for host in host_list: - host.update(run_user_info) - - if become_info: - for host in host_list: - host.update(become_info) - super().__init__(host_list=host_list) +class JMSBaseInventory(BaseInventory): def convert_to_ansible(self, asset, run_as_admin=False): info = { @@ -69,13 +43,6 @@ class JMSInventory(BaseInventory): info["groups"].append("domain_"+asset.domain.name) return info - def get_run_user_info(self): - system_user = self.run_as - if not system_user: - return {} - else: - return system_user._to_secret_json() - @staticmethod def make_proxy_command(asset): gateway = asset.domain.random_gateway() @@ -97,3 +64,89 @@ class JMSInventory(BaseInventory): " ".join(proxy_command_list) ) return {"ansible_ssh_common_args": proxy_command} + + +class JMSInventory(JMSBaseInventory): + """ + JMS Inventory is the manager with jumpserver assets, so you can + write you own manager, construct you inventory, + user_info is obtained from admin_user or asset_user + """ + def __init__(self, assets, run_as_admin=False, run_as=None, become_info=None): + """ + :param host_id_list: ["test1", ] + :param run_as_admin: True 是否使用管理用户去执行, 每台服务器的管理用户可能不同 + :param run_as: 用户名(添加了统一的资产用户管理器之后AssetUserManager加上之后修改为username) + :param become_info: 是否become成某个用户去执行 + """ + self.assets = assets + self.using_admin = run_as_admin + self.run_as = run_as + self.become_info = become_info + + host_list = [] + + for asset in assets: + info = self.convert_to_ansible(asset, run_as_admin=run_as_admin) + host_list.append(info) + + if run_as: + for host in host_list: + run_user_info = self.get_run_user_info(host) + host.update(run_user_info) + + if become_info: + for host in host_list: + host.update(become_info) + super().__init__(host_list=host_list) + + def get_run_user_info(self, host): + from assets.backends.multi import AssetUserManager + + if not self.run_as: + return {} + + try: + asset = self.assets.get(id=host.get('id')) + run_user = AssetUserManager.get(self.run_as, asset) + except Exception as e: + logger.error(e, exc_info=True) + return {} + else: + return run_user._to_secret_json() + + +class JMSCustomInventory(JMSBaseInventory): + """ + JMS Custom Inventory is the manager with jumpserver assets, + user_info is obtained from custom parameter + """ + + def __init__(self, assets, username, password=None, public_key=None, private_key=None): + """ + """ + self.assets = assets + self.username = username + self.password = password + self.public_key = public_key + self.private_key = private_key + + host_list = [] + + for asset in assets: + info = self.convert_to_ansible(asset) + host_list.append(info) + + for host in host_list: + run_user_info = self.get_run_user_info() + host.update(run_user_info) + + super().__init__(host_list=host_list) + + def get_run_user_info(self): + return { + 'username': self.username, + 'password': self.password, + 'public_key': self.public_key, + 'private_key': self.private_key + } diff --git a/apps/ops/migrations/0006_auto_20190318_1023.py b/apps/ops/migrations/0006_auto_20190318_1023.py new file mode 100644 index 000000000..f0d88081a --- /dev/null +++ b/apps/ops/migrations/0006_auto_20190318_1023.py @@ -0,0 +1,18 @@ +# Generated by Django 2.1.7 on 2019-03-18 02:23 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('ops', '0005_auto_20181219_1807'), + ] + + operations = [ + migrations.AlterField( + model_name='adhoc', + name='run_as', + field=models.CharField(default='', max_length=64, null=True, verbose_name='Username'), + ), + ] diff --git a/apps/ops/models/adhoc.py b/apps/ops/models/adhoc.py index e9d264ed1..2f1adc355 100644 --- a/apps/ops/models/adhoc.py +++ b/apps/ops/models/adhoc.py @@ -149,7 +149,7 @@ class AdHoc(models.Model): _options: ansible options, more see ops.ansible.runner.Options _hosts: ["hostname1", "hostname2"], hostname must be unique key of cmdb run_as_admin: if true, then need get every host admin user run it, because every host may be have different admin user, so we choise host level - run_as: if not run as admin, it run it as a system/common user from cmdb + run_as: username(Add the uniform AssetUserManager and change it to username) _become: May be using become [sudo, su] options. {method: "sudo", user: "user", pass: "pass"] pattern: Even if we set _hosts, We only use that to make inventory, We also can set `patter` to run task on match hosts """ @@ -161,7 +161,7 @@ class AdHoc(models.Model): _hosts = models.TextField(blank=True, verbose_name=_('Hosts')) # ['hostname1', 'hostname2'] hosts = models.ManyToManyField('assets.Asset', verbose_name=_("Host")) run_as_admin = models.BooleanField(default=False, verbose_name=_('Run as admin')) - run_as = models.ForeignKey('assets.SystemUser', null=True, on_delete=models.CASCADE) + run_as = models.CharField(max_length=64, default='', null=True, verbose_name=_('Username')) _become = models.CharField(max_length=1024, default='', verbose_name=_("Become")) created_by = models.CharField(max_length=64, default='', null=True, verbose_name=_('Create by')) date_created = models.DateTimeField(auto_now_add=True, db_index=True) @@ -233,6 +233,7 @@ class AdHoc(models.Model): history.summary = summary return raw, summary except Exception as e: + logger.error(e, exc_info=True) return {}, {"dark": {"all": str(e)}, "contacted": []} finally: history.date_finished = timezone.now() diff --git a/apps/ops/models/command.py b/apps/ops/models/command.py index 623dd39bb..dfa1dbe4d 100644 --- a/apps/ops/models/command.py +++ b/apps/ops/models/command.py @@ -31,7 +31,7 @@ class CommandExecution(models.Model): @property def inventory(self): - return JMSInventory(self.hosts.all(), run_as=self.run_as) + return JMSInventory(self.hosts.all(), run_as=self.run_as.username) @property def result(self): diff --git a/apps/ops/serializers.py b/apps/ops/serializers.py index 5eb16c5a8..d5da08306 100644 --- a/apps/ops/serializers.py +++ b/apps/ops/serializers.py @@ -75,7 +75,7 @@ class CommandExecutionSerializer(serializers.ModelSerializer): 'is_finished', 'date_created', 'date_finished' ] read_only_fields = [ - 'id', 'result', 'is_finished', 'log_url', 'date_created', + 'result', 'is_finished', 'log_url', 'date_created', 'date_finished' ] diff --git a/apps/ops/tasks.py b/apps/ops/tasks.py index 07a86a3be..9de1d0437 100644 --- a/apps/ops/tasks.py +++ b/apps/ops/tasks.py @@ -81,6 +81,8 @@ def clean_celery_tasks_period(): settings.CELERY_LOG_DIR, expire_days ) subprocess.call(command, shell=True) + command = "echo > {}".format(os.path.join(settings.LOG_DIR, 'celery.log')) + subprocess.call(command, shell=True) @shared_task diff --git a/apps/ops/templates/ops/command_execution_create.html b/apps/ops/templates/ops/command_execution_create.html index bffdfdaef..378acba9d 100644 --- a/apps/ops/templates/ops/command_execution_create.html +++ b/apps/ops/templates/ops/command_execution_create.html @@ -110,9 +110,9 @@ function initTree() { onCheck: onCheck } }; - var url = "{% url 'api-perms:my-nodes-assets-as-tree' %}"; + var url = "{% url 'api-perms:my-nodes-assets-as-tree' %}?cache_policy=1"; if (systemUserId) { - url += '?system_user=' + systemUserId + url += '&system_user=' + systemUserId } $.get(url, function(data, status){ diff --git a/apps/ops/templates/ops/command_execution_list.html b/apps/ops/templates/ops/command_execution_list.html index 4c38aa2d1..fe8b7122c 100644 --- a/apps/ops/templates/ops/command_execution_list.html +++ b/apps/ops/templates/ops/command_execution_list.html @@ -9,6 +9,7 @@ + +
    +
    +
    +
    +
    - + {% trans 'Name' %} {% trans 'IP' %} {% trans 'IP' %} {% trans 'Active' %} {% trans 'System users' %}{% trans 'Action' %}
    + + + + + + + + + + + +
    {% trans 'Username' %}{% trans 'Name' %}{% trans 'Email' %}{% trans 'Is imported' %}
    +
    +
    +
    +
    + + +{% endblock %} + +{% block modal_button %} + {{ block.super }} +{% endblock %} +{% block modal_confirm_id %}btn_ldap_modal_confirm{% endblock %} + + + diff --git a/apps/common/templates/common/basic_setting.html b/apps/settings/templates/settings/basic_setting.html similarity index 100% rename from apps/common/templates/common/basic_setting.html rename to apps/settings/templates/settings/basic_setting.html diff --git a/apps/common/templates/common/command_storage_create.html b/apps/settings/templates/settings/command_storage_create.html similarity index 98% rename from apps/common/templates/common/command_storage_create.html rename to apps/settings/templates/settings/command_storage_create.html index 671b11c94..9c60e2d85 100644 --- a/apps/common/templates/common/command_storage_create.html +++ b/apps/settings/templates/settings/command_storage_create.html @@ -159,10 +159,10 @@ $(document).ready(function() { data[name] = value } }); - var url = "{% url 'api-common:command-storage-create' %}"; + var url = "{% url 'api-settings:command-storage-create' %}"; var success = function(data, textStatus) { console.log(data, textStatus); - location = "{% url 'common:terminal-setting' %}"; + location = "{% url 'settings:terminal-setting' %}"; }; var error = function(data, textStatus) { var error_msg = data.responseJSON.error; diff --git a/apps/common/templates/common/email_setting.html b/apps/settings/templates/settings/email_setting.html similarity index 98% rename from apps/common/templates/common/email_setting.html rename to apps/settings/templates/settings/email_setting.html index 2f0951e00..46846d7dc 100644 --- a/apps/common/templates/common/email_setting.html +++ b/apps/settings/templates/settings/email_setting.html @@ -84,7 +84,7 @@ $(document).ready(function () { data[field.name] = field.value; }); - var the_url = "{% url 'api-common:mail-testing' %}"; + var the_url = "{% url 'api-settings:mail-testing' %}"; function error(message) { toastr.error(message) diff --git a/apps/common/templates/common/ldap_setting.html b/apps/settings/templates/settings/ldap_setting.html similarity index 80% rename from apps/common/templates/common/ldap_setting.html rename to apps/settings/templates/settings/ldap_setting.html index e55da5a8f..1983f4883 100644 --- a/apps/common/templates/common/ldap_setting.html +++ b/apps/settings/templates/settings/ldap_setting.html @@ -31,7 +31,7 @@
    -
    + {% if form.non_field_errors %}
    {{ form.non_field_errors }} @@ -61,6 +61,8 @@ +{# #} +
    @@ -72,10 +74,12 @@
    + {% include 'settings/_ldap_list_users_modal.html' %} {% endblock %} {% block custom_foot_js %} {% endblock %} diff --git a/apps/common/templates/common/replay_storage_create.html b/apps/settings/templates/settings/replay_storage_create.html similarity index 99% rename from apps/common/templates/common/replay_storage_create.html rename to apps/settings/templates/settings/replay_storage_create.html index c8f99240a..69a1ba9fc 100644 --- a/apps/common/templates/common/replay_storage_create.html +++ b/apps/settings/templates/settings/replay_storage_create.html @@ -251,9 +251,9 @@ $(document).ready(function() { var name = $(id_field).attr('name'); data[name] = $(id_field).val(); }); - var url = "{% url 'api-common:replay-storage-create' %}"; + var url = "{% url 'api-settings:replay-storage-create' %}"; var success = function(data, textStatus) { - location = "{% url 'common:terminal-setting' %}"; + location = "{% url 'settings:terminal-setting' %}"; submitBtn.removeClass('disabled'); submitBtn.html(origin_text); }; diff --git a/apps/common/templates/common/security_setting.html b/apps/settings/templates/settings/security_setting.html similarity index 100% rename from apps/common/templates/common/security_setting.html rename to apps/settings/templates/settings/security_setting.html diff --git a/apps/common/templates/common/terminal_setting.html b/apps/settings/templates/settings/terminal_setting.html similarity index 95% rename from apps/common/templates/common/terminal_setting.html rename to apps/settings/templates/settings/terminal_setting.html index 994d1714b..e6eb72982 100644 --- a/apps/common/templates/common/terminal_setting.html +++ b/apps/settings/templates/settings/terminal_setting.html @@ -92,7 +92,7 @@ {% endfor %} - {% trans 'Add' %} + {% trans 'Add' %}

    {% trans "Replay storage" %}

    @@ -114,7 +114,7 @@ {% endfor %} - {% trans 'Add' %} + {% trans 'Add' %}
    @@ -174,12 +174,12 @@ $(document).ready(function () { }) .on('click', '.btn-del-replay', function(){ var $this = $(this); - var the_url = "{% url 'api-common:replay-storage-delete' %}"; + var the_url = "{% url 'api-settings:replay-storage-delete' %}"; deleteStorage($this, the_url); }) .on('click', '.btn-del-command', function() { var $this = $(this); - var the_url = "{% url 'api-common:command-storage-delete' %}"; + var the_url = "{% url 'api-settings:command-storage-delete' %}"; deleteStorage($this, the_url) }); diff --git a/apps/settings/tests.py b/apps/settings/tests.py new file mode 100644 index 000000000..7ce503c2d --- /dev/null +++ b/apps/settings/tests.py @@ -0,0 +1,3 @@ +from django.test import TestCase + +# Create your tests here. diff --git a/apps/common/urls/api_urls.py b/apps/settings/urls/api_urls.py similarity index 83% rename from apps/common/urls/api_urls.py rename to apps/settings/urls/api_urls.py index a4ae8f9f1..157c48f70 100644 --- a/apps/common/urls/api_urls.py +++ b/apps/settings/urls/api_urls.py @@ -9,6 +9,8 @@ app_name = 'common' urlpatterns = [ path('mail/testing/', api.MailTestingAPI.as_view(), name='mail-testing'), path('ldap/testing/', api.LDAPTestingAPI.as_view(), name='ldap-testing'), + path('ldap/sync/', api.LDAPSyncAPI.as_view(), name='ldap-sync'), + path('ldap/comfirm/sync/', api.LDAPConfirmSyncAPI.as_view(), name='ldap-comfirm-sync'), path('terminal/replay-storage/create/', api.ReplayStorageCreateAPI.as_view(), name='replay-storage-create'), path('terminal/replay-storage/delete/', api.ReplayStorageDeleteAPI.as_view(), name='replay-storage-delete'), path('terminal/command-storage/create/', api.CommandStorageCreateAPI.as_view(), name='command-storage-create'), diff --git a/apps/common/urls/view_urls.py b/apps/settings/urls/view_urls.py similarity index 100% rename from apps/common/urls/view_urls.py rename to apps/settings/urls/view_urls.py diff --git a/apps/settings/utils.py b/apps/settings/utils.py new file mode 100644 index 000000000..c7dcf45b6 --- /dev/null +++ b/apps/settings/utils.py @@ -0,0 +1,154 @@ +# -*- coding: utf-8 -*- +# + +from ldap3 import Server, Connection +from django.utils.translation import ugettext_lazy as _ + +from .models import settings +from users.models import User + + +def ldap_conn(host, use_ssl, bind_dn, password): + server = Server(host, use_ssl=use_ssl) + conn = Connection(server, bind_dn, password) + return conn + + +def ldap_search(conn, search_ougroup, search_filter, attr_map, user_names=None): + users_list = [] + for search_ou in str(search_ougroup).split("|"): + ok = conn.search(search_ou, search_filter % ({"user": "*"}), + attributes=list(attr_map.values())) + if not ok: + error = _("Search no entry matched in ou {}").format(search_ou) + return {"error": error} + + ldap_map_users(conn, attr_map, users_list, user_names) + + if len(users_list) > 0: + return users_list + return {"error": _("Have user but attr mapping error")} + + +def get_ldap_users_list(user_names=None): + ldap_setting = get_ldap_setting() + conn = ldap_conn(ldap_setting['host'], ldap_setting['use_ssl'], + ldap_setting['bind_dn'], ldap_setting['password']) + try: + conn.bind() + except Exception as e: + return {"error": str(e)} + + result_search = ldap_search(conn, ldap_setting['search_ougroup'], + ldap_setting['search_filter'], + ldap_setting['attr_map'], user_names=user_names) + return result_search + + +def ldap_map_users(conn, attr_map, users, user_names=None): + for entry in conn.entries: + user = entry_user(entry, attr_map) + if user_names: + if user.get('username', '') in user_names: + users.append(user) + else: + users.append(user) + + +def entry_user(entry, attr_map): + user = {} + user['is_imported'] = _('No') + for attr, mapping in attr_map.items(): + if not hasattr(entry, mapping): + continue + value = getattr(entry, mapping).value + user[attr] = value if value else '' + if attr != 'username': + continue + if User.objects.filter(username=user[attr]): + user['is_imported'] = _('Yes') + return user + + +def get_ldap_setting(): + host = settings.AUTH_LDAP_SERVER_URI + bind_dn = settings.AUTH_LDAP_BIND_DN + password = settings.AUTH_LDAP_BIND_PASSWORD + use_ssl = settings.AUTH_LDAP_START_TLS + search_ougroup = settings.AUTH_LDAP_SEARCH_OU + search_filter = settings.AUTH_LDAP_SEARCH_FILTER + attr_map = settings.AUTH_LDAP_USER_ATTR_MAP + auth_ldap = settings.AUTH_LDAP + + ldap_setting = { + 'host': host, 'bind_dn': bind_dn, 'password': password, + 'search_ougroup': search_ougroup, 'search_filter': search_filter, + 'attr_map': attr_map, 'auth_ldap': auth_ldap, 'use_ssl': use_ssl, + } + return ldap_setting + + +def save_user(users): + exist = [] + username_list = [item.get('username') for item in users] + for name in username_list: + if User.objects.filter(username=name).exclude(source='ldap'): + exist.append(name) + users = [user for user in users if (user.get('username') not in exist)] + + result_save = save(users, exist) + return result_save + + +def save(users, exist): + fail_user = [] + for item in users: + item = set_default_item(item) + user = User.objects.filter(username=item['username'], source='ldap') + user = user.first() + if not user: + try: + user = User.objects.create(**item) + except Exception as e: + fail_user.append(item.get('username')) + continue + for key, value in item.items(): + user.key = value + user.save() + + get_msg = get_messages(users, exist, fail_user) + return get_msg + + +def set_default_item(item): + item['source'] = 'ldap' + if not item.get('email', ''): + if '@' in item['username']: + item['email'] = item['username'] + else: + item['email'] = item['username'] + '@' + settings.EMAIL_SUFFIX + if 'is_imported' in item.keys(): + item.pop('is_imported') + return item + + +def get_messages(users, exist, fail_user): + if exist: + info = _("Import {} users successfully; import {} users failed, the " + "database already exists with the same name") + msg = info.format(len(users), str(exist)) + + if fail_user: + info = _("Import {} users successfully; import {} users failed, " + "the database already exists with the same name; import {}" + "users failed, Because’TypeError' object has no attribute " + "'keys'") + msg = info.format(len(users)-len(fail_user), str(exist), str(fail_user)) + else: + msg = _("Import {} users successfully").format(len(users)) + + if fail_user: + info = _("Import {} users successfully;import {} users failed, " + "Because’TypeError' object has no attribute 'keys'") + msg = info.format(len(users)-len(fail_user), str(fail_user)) + return {'msg': msg} \ No newline at end of file diff --git a/apps/common/views.py b/apps/settings/views.py similarity index 92% rename from apps/common/views.py rename to apps/settings/views.py index 2500d96a3..b6ac0bd89 100644 --- a/apps/common/views.py +++ b/apps/settings/views.py @@ -3,15 +3,15 @@ from django.shortcuts import render, redirect from django.contrib import messages from django.utils.translation import ugettext as _ +from common.permissions import SuperUserRequiredMixin +from common import utils from .forms import EmailSettingForm, LDAPSettingForm, BasicSettingForm, \ TerminalSettingForm, SecuritySettingForm -from common.permissions import SuperUserRequiredMixin -from . import utils class BasicSettingView(SuperUserRequiredMixin, TemplateView): form_class = BasicSettingForm - template_name = "common/basic_setting.html" + template_name = "settings/basic_setting.html" def get_context_data(self, **kwargs): context = { @@ -37,7 +37,7 @@ class BasicSettingView(SuperUserRequiredMixin, TemplateView): class EmailSettingView(SuperUserRequiredMixin, TemplateView): form_class = EmailSettingForm - template_name = "common/email_setting.html" + template_name = "settings/email_setting.html" def get_context_data(self, **kwargs): context = { @@ -63,7 +63,7 @@ class EmailSettingView(SuperUserRequiredMixin, TemplateView): class LDAPSettingView(SuperUserRequiredMixin, TemplateView): form_class = LDAPSettingForm - template_name = "common/ldap_setting.html" + template_name = "settings/ldap_setting.html" def get_context_data(self, **kwargs): context = { @@ -89,7 +89,7 @@ class LDAPSettingView(SuperUserRequiredMixin, TemplateView): class TerminalSettingView(SuperUserRequiredMixin, TemplateView): form_class = TerminalSettingForm - template_name = "common/terminal_setting.html" + template_name = "settings/terminal_setting.html" def get_context_data(self, **kwargs): command_storage = utils.get_command_storage_setting() @@ -119,7 +119,7 @@ class TerminalSettingView(SuperUserRequiredMixin, TemplateView): class ReplayStorageCreateView(SuperUserRequiredMixin, TemplateView): - template_name = 'common/replay_storage_create.html' + template_name = 'settings/replay_storage_create.html' def get_context_data(self, **kwargs): context = { @@ -131,7 +131,7 @@ class ReplayStorageCreateView(SuperUserRequiredMixin, TemplateView): class CommandStorageCreateView(SuperUserRequiredMixin, TemplateView): - template_name = 'common/command_storage_create.html' + template_name = 'settings/command_storage_create.html' def get_context_data(self, **kwargs): context = { @@ -144,7 +144,7 @@ class CommandStorageCreateView(SuperUserRequiredMixin, TemplateView): class SecuritySettingView(SuperUserRequiredMixin, TemplateView): form_class = SecuritySettingForm - template_name = "common/security_setting.html" + template_name = "settings/security_setting.html" def get_context_data(self, **kwargs): context = { diff --git a/apps/static/css/jumpserver.css b/apps/static/css/jumpserver.css index 3945258b0..c3dcfb386 100644 --- a/apps/static/css/jumpserver.css +++ b/apps/static/css/jumpserver.css @@ -450,3 +450,7 @@ div.dataTables_wrapper div.dataTables_filter { content:"*"; color:red; } + +#tree-refresh .fa-refresh { + font: normal normal normal 14px/1 FontAwesome !important; +} \ No newline at end of file diff --git a/apps/static/img/login/login-image.jpg b/apps/static/img/login/login-image.jpg deleted file mode 100644 index 794f98b7f..000000000 Binary files a/apps/static/img/login/login-image.jpg and /dev/null differ diff --git a/apps/static/img/login/login_image_1.png b/apps/static/img/login/login_image_1.png new file mode 100644 index 000000000..11a19957e Binary files /dev/null and b/apps/static/img/login/login_image_1.png differ diff --git a/apps/static/js/jumpserver.js b/apps/static/js/jumpserver.js index 5e602dd4f..8740a6508 100644 --- a/apps/static/js/jumpserver.js +++ b/apps/static/js/jumpserver.js @@ -555,6 +555,17 @@ jumpserver.initServerSideDataTable = function (options) { processing: true, ajax: { url: options.ajax_url , + error: function(jqXHR, textStatus, errorThrown) { + var msg = gettext("Unknown error occur"); + if (jqXHR.responseJSON) { + if (jqXHR.responseJSON.error) { + msg = jqXHR.responseJSON.error + } else if (jqXHR.responseJSON.msg) { + msg = jqXHR.responseJSON.msg + } + } + alert(msg) + }, data: function (data) { delete data.columns; if (data.length !== null){ @@ -922,3 +933,16 @@ function initSelectedAssets2Table(){ }); } } + + +function rootNodeAddDom(ztree, callback) { + var refreshIcon = ""; + var rootNode = ztree.getNodes()[0]; + var $rootNodeRef = $("#" + rootNode.tId + "_a"); + $rootNodeRef.after(refreshIcon); + var refreshIconRef = $('#tree-refresh'); + refreshIconRef.bind('click', function () { + ztree.destroy(); + callback() + }) +} \ No newline at end of file diff --git a/apps/static/js/plugins/echarts/echarts.min.js b/apps/static/js/plugins/echarts/echarts.min.js new file mode 100644 index 000000000..7c8b12aaf --- /dev/null +++ b/apps/static/js/plugins/echarts/echarts.min.js @@ -0,0 +1,22 @@ + +/* +* Licensed to the Apache Software Foundation (ASF) under one +* or more contributor license agreements. See the NOTICE file +* distributed with this work for additional information +* regarding copyright ownership. The ASF licenses this file +* to you under the Apache License, Version 2.0 (the +* "License"); you may not use this file except in compliance +* with the License. You may obtain a copy of the License at +* +* http://www.apache.org/licenses/LICENSE-2.0 +* +* Unless required by applicable law or agreed to in writing, +* software distributed under the License is distributed on an +* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +* KIND, either express or implied. See the License for the +* specific language governing permissions and limitations +* under the License. +*/ + + +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(t.echarts={})}(this,function(t){"use strict";function e(t,e){"createCanvas"===t&&(nw=null),ew[t]=e}function i(t){if(null==t||"object"!=typeof t)return t;var e=t,n=Y_.call(t);if("[object Array]"===n){if(!O(t)){e=[];for(var o=0,a=t.length;o=0){var o="touchend"!==n?e.targetTouches[0]:e.changedTouches[0];o&&st(t,o,e,i)}else st(t,e,e,i),e.zrDelta=e.wheelDelta?e.wheelDelta/120:-(e.detail||0)/3;var a=e.button;return null==e.which&&void 0!==a&&gw.test(e.type)&&(e.which=1&a?1:2&a?3:4&a?2:0),e}function ht(t,e,i){pw?t.addEventListener(e,i):t.attachEvent("on"+e,i)}function ct(t,e,i){pw?t.removeEventListener(e,i):t.detachEvent("on"+e,i)}function dt(t){return 2===t.which||3===t.which}function ft(t){var e=t[1][0]-t[0][0],i=t[1][1]-t[0][1];return Math.sqrt(e*e+i*i)}function pt(t){return[(t[0][0]+t[1][0])/2,(t[0][1]+t[1][1])/2]}function gt(t,e,i){return{type:t,event:i,target:e.target,topTarget:e.topTarget,cancelBubble:!1,offsetX:i.zrX,offsetY:i.zrY,gestureEvent:i.gestureEvent,pinchX:i.pinchX,pinchY:i.pinchY,pinchScale:i.pinchScale,wheelDelta:i.zrDelta,zrByTouch:i.zrByTouch,which:i.which,stop:mt}}function mt(t){mw(this.event)}function vt(){}function yt(t,e,i){if(t[t.rectHover?"rectContain":"contain"](e,i)){for(var n,o=t;o;){if(o.clipPath&&!o.clipPath.contain(e,i))return!1;o.silent&&(n=!0),o=o.parent}return!n||xw}return!1}function xt(){var t=new bw(6);return _t(t),t}function _t(t){return t[0]=1,t[1]=0,t[2]=0,t[3]=1,t[4]=0,t[5]=0,t}function wt(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t}function bt(t,e,i){var n=e[0]*i[0]+e[2]*i[1],o=e[1]*i[0]+e[3]*i[1],a=e[0]*i[2]+e[2]*i[3],r=e[1]*i[2]+e[3]*i[3],s=e[0]*i[4]+e[2]*i[5]+e[4],l=e[1]*i[4]+e[3]*i[5]+e[5];return t[0]=n,t[1]=o,t[2]=a,t[3]=r,t[4]=s,t[5]=l,t}function St(t,e,i){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4]+i[0],t[5]=e[5]+i[1],t}function Mt(t,e,i){var n=e[0],o=e[2],a=e[4],r=e[1],s=e[3],l=e[5],u=Math.sin(i),h=Math.cos(i);return t[0]=n*h+r*u,t[1]=-n*u+r*h,t[2]=o*h+s*u,t[3]=-o*u+h*s,t[4]=h*a+u*l,t[5]=h*l-u*a,t}function It(t,e,i){var n=i[0],o=i[1];return t[0]=e[0]*n,t[1]=e[1]*o,t[2]=e[2]*n,t[3]=e[3]*o,t[4]=e[4]*n,t[5]=e[5]*o,t}function Tt(t,e){var i=e[0],n=e[2],o=e[4],a=e[1],r=e[3],s=e[5],l=i*r-a*n;return l?(l=1/l,t[0]=r*l,t[1]=-a*l,t[2]=-n*l,t[3]=i*l,t[4]=(n*s-r*o)*l,t[5]=(a*o-i*s)*l,t):null}function At(t){var e=xt();return wt(e,t),e}function Dt(t){return t>Iw||t<-Iw}function Ct(t){this._target=t.target,this._life=t.life||1e3,this._delay=t.delay||0,this._initialized=!1,this.loop=null!=t.loop&&t.loop,this.gap=t.gap||0,this.easing=t.easing||"Linear",this.onframe=t.onframe,this.ondestroy=t.ondestroy,this.onrestart=t.onrestart,this._pausedTime=0,this._paused=!1}function Lt(t){return(t=Math.round(t))<0?0:t>255?255:t}function kt(t){return(t=Math.round(t))<0?0:t>360?360:t}function Pt(t){return t<0?0:t>1?1:t}function Nt(t){return Lt(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100*255:parseInt(t,10))}function Ot(t){return Pt(t.length&&"%"===t.charAt(t.length-1)?parseFloat(t)/100:parseFloat(t))}function Et(t,e,i){return i<0?i+=1:i>1&&(i-=1),6*i<1?t+(e-t)*i*6:2*i<1?e:3*i<2?t+(e-t)*(2/3-i)*6:t}function Rt(t,e,i){return t+(e-t)*i}function zt(t,e,i,n,o){return t[0]=e,t[1]=i,t[2]=n,t[3]=o,t}function Bt(t,e){return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t}function Vt(t,e){Vw&&Bt(Vw,e),Vw=Bw.put(t,Vw||e.slice())}function Gt(t,e){if(t){e=e||[];var i=Bw.get(t);if(i)return Bt(e,i);var n=(t+="").replace(/ /g,"").toLowerCase();if(n in zw)return Bt(e,zw[n]),Vt(t,e),e;if("#"!==n.charAt(0)){var o=n.indexOf("("),a=n.indexOf(")");if(-1!==o&&a+1===n.length){var r=n.substr(0,o),s=n.substr(o+1,a-(o+1)).split(","),l=1;switch(r){case"rgba":if(4!==s.length)return void zt(e,0,0,0,1);l=Ot(s.pop());case"rgb":return 3!==s.length?void zt(e,0,0,0,1):(zt(e,Nt(s[0]),Nt(s[1]),Nt(s[2]),l),Vt(t,e),e);case"hsla":return 4!==s.length?void zt(e,0,0,0,1):(s[3]=Ot(s[3]),Ft(s,e),Vt(t,e),e);case"hsl":return 3!==s.length?void zt(e,0,0,0,1):(Ft(s,e),Vt(t,e),e);default:return}}zt(e,0,0,0,1)}else{if(4===n.length)return(u=parseInt(n.substr(1),16))>=0&&u<=4095?(zt(e,(3840&u)>>4|(3840&u)>>8,240&u|(240&u)>>4,15&u|(15&u)<<4,1),Vt(t,e),e):void zt(e,0,0,0,1);if(7===n.length){var u=parseInt(n.substr(1),16);return u>=0&&u<=16777215?(zt(e,(16711680&u)>>16,(65280&u)>>8,255&u,1),Vt(t,e),e):void zt(e,0,0,0,1)}}}}function Ft(t,e){var i=(parseFloat(t[0])%360+360)%360/360,n=Ot(t[1]),o=Ot(t[2]),a=o<=.5?o*(n+1):o+n-o*n,r=2*o-a;return e=e||[],zt(e,Lt(255*Et(r,a,i+1/3)),Lt(255*Et(r,a,i)),Lt(255*Et(r,a,i-1/3)),1),4===t.length&&(e[3]=t[3]),e}function Wt(t){if(t){var e,i,n=t[0]/255,o=t[1]/255,a=t[2]/255,r=Math.min(n,o,a),s=Math.max(n,o,a),l=s-r,u=(s+r)/2;if(0===l)e=0,i=0;else{i=u<.5?l/(s+r):l/(2-s-r);var h=((s-n)/6+l/2)/l,c=((s-o)/6+l/2)/l,d=((s-a)/6+l/2)/l;n===s?e=d-c:o===s?e=1/3+h-d:a===s&&(e=2/3+c-h),e<0&&(e+=1),e>1&&(e-=1)}var f=[360*e,i,u];return null!=t[3]&&f.push(t[3]),f}}function Ht(t,e){var i=Gt(t);if(i){for(var n=0;n<3;n++)i[n]=e<0?i[n]*(1-e)|0:(255-i[n])*e+i[n]|0,i[n]>255?i[n]=255:t[n]<0&&(i[n]=0);return qt(i,4===i.length?"rgba":"rgb")}}function Zt(t){var e=Gt(t);if(e)return((1<<24)+(e[0]<<16)+(e[1]<<8)+ +e[2]).toString(16).slice(1)}function Ut(t,e,i){if(e&&e.length&&t>=0&&t<=1){i=i||[];var n=t*(e.length-1),o=Math.floor(n),a=Math.ceil(n),r=e[o],s=e[a],l=n-o;return i[0]=Lt(Rt(r[0],s[0],l)),i[1]=Lt(Rt(r[1],s[1],l)),i[2]=Lt(Rt(r[2],s[2],l)),i[3]=Pt(Rt(r[3],s[3],l)),i}}function Xt(t,e,i){if(e&&e.length&&t>=0&&t<=1){var n=t*(e.length-1),o=Math.floor(n),a=Math.ceil(n),r=Gt(e[o]),s=Gt(e[a]),l=n-o,u=qt([Lt(Rt(r[0],s[0],l)),Lt(Rt(r[1],s[1],l)),Lt(Rt(r[2],s[2],l)),Pt(Rt(r[3],s[3],l))],"rgba");return i?{color:u,leftIndex:o,rightIndex:a,value:n}:u}}function jt(t,e,i,n){if(t=Gt(t))return t=Wt(t),null!=e&&(t[0]=kt(e)),null!=i&&(t[1]=Ot(i)),null!=n&&(t[2]=Ot(n)),qt(Ft(t),"rgba")}function Yt(t,e){if((t=Gt(t))&&null!=e)return t[3]=Pt(e),qt(t,"rgba")}function qt(t,e){if(t&&t.length){var i=t[0]+","+t[1]+","+t[2];return"rgba"!==e&&"hsva"!==e&&"hsla"!==e||(i+=","+t[3]),e+"("+i+")"}}function Kt(t,e){return t[e]}function $t(t,e,i){t[e]=i}function Jt(t,e,i){return(e-t)*i+t}function Qt(t,e,i){return i>.5?e:t}function te(t,e,i,n,o){var a=t.length;if(1===o)for(s=0;so)t.length=o;else for(r=n;r=0&&!(m[i]<=e);i--);i=Math.min(i,u-2)}else{for(i=L;ie);i++);i=Math.min(i-1,u-2)}L=i,k=e;var n=m[i+1]-m[i];if(0!==n)if(I=(e-m[i])/n,l)if(A=v[i],T=v[0===i?i:i-1],D=v[i>u-2?u-1:i+1],C=v[i>u-3?u-1:i+2],d)ne(T,A,D,C,I,I*I,I*I*I,r(t,o),g);else{if(f)a=ne(T,A,D,C,I,I*I,I*I*I,P,1),a=re(P);else{if(p)return Qt(A,D,I);a=oe(T,A,D,C,I,I*I,I*I*I)}s(t,o,a)}else if(d)te(v[i],v[i+1],I,r(t,o),g);else{var a;if(f)te(v[i],v[i+1],I,P,1),a=re(P);else{if(p)return Qt(v[i],v[i+1],I);a=Jt(v[i],v[i+1],I)}s(t,o,a)}},ondestroy:i});return e&&"spline"!==e&&(N.easing=e),N}}}function ue(t,e,i,n,o,a,r,s){_(n)?(a=o,o=n,n=0):x(o)?(a=o,o="linear",n=0):x(n)?(a=n,n=0):x(i)?(a=i,i=500):i||(i=500),t.stopAnimation(),he(t,"",t,e,i,n,s);var l=t.animators.slice(),u=l.length;u||a&&a();for(var h=0;h0&&t.animate(e,!1).when(null==o?500:o,s).delay(a||0)}function ce(t,e,i,n){if(e){var o={};o[e]={},o[e][i]=n,t.attr(o)}else t.attr(i,n)}function de(t,e,i,n){i<0&&(t+=i,i=-i),n<0&&(e+=n,n=-n),this.x=t,this.y=e,this.width=i,this.height=n}function fe(t){for(var e=0;t>=eb;)e|=1&t,t>>=1;return t+e}function pe(t,e,i,n){var o=e+1;if(o===i)return 1;if(n(t[o++],t[e])<0){for(;o=0;)o++;return o-e}function ge(t,e,i){for(i--;e>>1])<0?l=a:s=a+1;var u=n-s;switch(u){case 3:t[s+3]=t[s+2];case 2:t[s+2]=t[s+1];case 1:t[s+1]=t[s];break;default:for(;u>0;)t[s+u]=t[s+u-1],u--}t[s]=r}}function ve(t,e,i,n,o,a){var r=0,s=0,l=1;if(a(t,e[i+o])>0){for(s=n-o;l0;)r=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),r+=o,l+=o}else{for(s=o+1;ls&&(l=s);var u=r;r=o-l,l=o-u}for(r++;r>>1);a(t,e[i+h])>0?r=h+1:l=h}return l}function ye(t,e,i,n,o,a){var r=0,s=0,l=1;if(a(t,e[i+o])<0){for(s=o+1;ls&&(l=s);var u=r;r=o-l,l=o-u}else{for(s=n-o;l=0;)r=l,(l=1+(l<<1))<=0&&(l=s);l>s&&(l=s),r+=o,l+=o}for(r++;r>>1);a(t,e[i+h])<0?l=h:r=h+1}return l}function xe(t,e){function i(i){var s=a[i],u=r[i],h=a[i+1],c=r[i+1];r[i]=u+c,i===l-3&&(a[i+1]=a[i+2],r[i+1]=r[i+2]),l--;var d=ye(t[h],t,s,u,0,e);s+=d,0!==(u-=d)&&0!==(c=ve(t[s+u-1],t,h,c,c-1,e))&&(u<=c?n(s,u,h,c):o(s,u,h,c))}function n(i,n,o,a){var r=0;for(r=0;r=ib||f>=ib);if(p)break;g<0&&(g=0),g+=2}if((s=g)<1&&(s=1),1===n){for(r=0;r=0;r--)t[f+r]=t[d+r];if(0===n){v=!0;break}}if(t[c--]=u[h--],1==--a){v=!0;break}if(0!=(m=a-ve(t[l],u,0,a,a-1,e))){for(a-=m,f=(c-=m)+1,d=(h-=m)+1,r=0;r=ib||m>=ib);if(v)break;p<0&&(p=0),p+=2}if((s=p)<1&&(s=1),1===a){for(f=(c-=n)+1,d=(l-=n)+1,r=n-1;r>=0;r--)t[f+r]=t[d+r];t[c]=u[h]}else{if(0===a)throw new Error;for(d=c-(a-1),r=0;r=0;r--)t[f+r]=t[d+r];t[c]=u[h]}else for(d=c-(a-1),r=0;r1;){var t=l-2;if(t>=1&&r[t-1]<=r[t]+r[t+1]||t>=2&&r[t-2]<=r[t]+r[t-1])r[t-1]r[t+1])break;i(t)}},this.forceMergeRuns=function(){for(;l>1;){var t=l-2;t>0&&r[t-1]s&&(l=s),me(t,i,i+l,i+a,e),a=l}r.pushRun(i,a),r.mergeRuns(),o-=a,i+=a}while(0!==o);r.forceMergeRuns()}}function we(t,e){return t.zlevel===e.zlevel?t.z===e.z?t.z2-e.z2:t.z-e.z:t.zlevel-e.zlevel}function be(t,e,i){var n=null==e.x?0:e.x,o=null==e.x2?1:e.x2,a=null==e.y?0:e.y,r=null==e.y2?0:e.y2;return e.global||(n=n*i.width+i.x,o=o*i.width+i.x,a=a*i.height+i.y,r=r*i.height+i.y),n=isNaN(n)?0:n,o=isNaN(o)?1:o,a=isNaN(a)?0:a,r=isNaN(r)?0:r,t.createLinearGradient(n,a,o,r)}function Se(t,e,i){var n=i.width,o=i.height,a=Math.min(n,o),r=null==e.x?.5:e.x,s=null==e.y?.5:e.y,l=null==e.r?.5:e.r;return e.global||(r=r*n+i.x,s=s*o+i.y,l*=a),t.createRadialGradient(r,s,0,r,s,l)}function Me(){return!1}function Ie(t,e,i){var n=iw(),o=e.getWidth(),a=e.getHeight(),r=n.style;return r&&(r.position="absolute",r.left=0,r.top=0,r.width=o+"px",r.height=a+"px",n.setAttribute("data-zr-dom-id",t)),n.width=o*i,n.height=a*i,n}function Te(t){if("string"==typeof t){var e=mb.get(t);return e&&e.image}return t}function Ae(t,e,i,n,o){if(t){if("string"==typeof t){if(e&&e.__zrImageSrc===t||!i)return e;var a=mb.get(t),r={hostEl:i,cb:n,cbPayload:o};return a?!Ce(e=a.image)&&a.pending.push(r):((e=new Image).onload=e.onerror=De,mb.put(t,e.__cachedImgObj={image:e,pending:[r]}),e.src=e.__zrImageSrc=t),e}return t}return e}function De(){var t=this.__cachedImgObj;this.onload=this.onerror=this.__cachedImgObj=null;for(var e=0;exb&&(yb=0,vb={}),yb++,vb[i]=o,o}function ke(t,e,i,n,o,a,r,s){return r?Ne(t,e,i,n,o,r,a,s):Pe(t,e,i,n,o,a,s)}function Pe(t,e,i,n,o,a,r){var s=He(t,e,o,a,r),l=Le(t,e);o&&(l+=o[1]+o[3]);var u=s.outerHeight,h=new de(Oe(0,l,i),Ee(0,u,n),l,u);return h.lineHeight=s.lineHeight,h}function Ne(t,e,i,n,o,a,r,s){var l=Ze(t,{rich:r,truncate:s,font:e,textAlign:i,textPadding:o,textLineHeight:a}),u=l.outerWidth,h=l.outerHeight;return new de(Oe(0,u,i),Ee(0,h,n),u,h)}function Oe(t,e,i){return"right"===i?t-=e:"center"===i&&(t-=e/2),t}function Ee(t,e,i){return"middle"===i?t-=e/2:"bottom"===i&&(t-=e),t}function Re(t,e,i){var n=e.x,o=e.y,a=e.height,r=e.width,s=a/2,l="left",u="top";switch(t){case"left":n-=i,o+=s,l="right",u="middle";break;case"right":n+=i+r,o+=s,u="middle";break;case"top":n+=r/2,o-=i,l="center",u="bottom";break;case"bottom":n+=r/2,o+=a+i,l="center";break;case"inside":n+=r/2,o+=s,l="center",u="middle";break;case"insideLeft":n+=i,o+=s,u="middle";break;case"insideRight":n+=r-i,o+=s,l="right",u="middle";break;case"insideTop":n+=r/2,o+=i,l="center";break;case"insideBottom":n+=r/2,o+=a-i,l="center",u="bottom";break;case"insideTopLeft":n+=i,o+=i;break;case"insideTopRight":n+=r-i,o+=i,l="right";break;case"insideBottomLeft":n+=i,o+=a-i,u="bottom";break;case"insideBottomRight":n+=r-i,o+=a-i,l="right",u="bottom"}return{x:n,y:o,textAlign:l,textVerticalAlign:u}}function ze(t,e,i,n,o){if(!e)return"";var a=(t+"").split("\n");o=Be(e,i,n,o);for(var r=0,s=a.length;r=r;l++)s-=r;var u=Le(i,e);return u>s&&(i="",u=0),s=t-u,n.ellipsis=i,n.ellipsisWidth=u,n.contentWidth=s,n.containerWidth=t,n}function Ve(t,e){var i=e.containerWidth,n=e.font,o=e.contentWidth;if(!i)return"";var a=Le(t,n);if(a<=i)return t;for(var r=0;;r++){if(a<=o||r>=e.maxIterations){t+=e.ellipsis;break}var s=0===r?Ge(t,o,e.ascCharWidth,e.cnCharWidth):a>0?Math.floor(t.length*o/a):0;a=Le(t=t.substr(0,s),n)}return""===t&&(t=e.placeholder),t}function Ge(t,e,i,n){for(var o=0,a=0,r=t.length;au)t="",r=[];else if(null!=h)for(var c=Be(h-(i?i[1]+i[3]:0),e,o.ellipsis,{minChar:o.minChar,placeholder:o.placeholder}),d=0,f=r.length;do&&Ue(i,t.substring(o,a)),Ue(i,n[2],n[1]),o=_b.lastIndex}of)return{lines:[],width:0,height:0};k.textWidth=Le(k.text,_);var b=y.textWidth,S=null==b||"auto"===b;if("string"==typeof b&&"%"===b.charAt(b.length-1))k.percentWidth=b,u.push(k),b=0;else{if(S){b=k.textWidth;var M=y.textBackgroundColor,I=M&&M.image;I&&Ce(I=Te(I))&&(b=Math.max(b,I.width*w/I.height))}var T=x?x[1]+x[3]:0;b+=T;var C=null!=d?d-m:null;null!=C&&Cl&&(i*=l/(c=i+n),n*=l/c),o+a>l&&(o*=l/(c=o+a),a*=l/c),n+o>u&&(n*=u/(c=n+o),o*=u/c),i+a>u&&(i*=u/(c=i+a),a*=u/c),t.moveTo(r+i,s),t.lineTo(r+l-n,s),0!==n&&t.arc(r+l-n,s+n,n,-Math.PI/2,0),t.lineTo(r+l,s+u-o),0!==o&&t.arc(r+l-o,s+u-o,o,0,Math.PI/2),t.lineTo(r+a,s+u),0!==a&&t.arc(r+a,s+u-a,a,Math.PI/2,Math.PI),t.lineTo(r,s+i),0!==i&&t.arc(r+i,s+i,i,Math.PI,1.5*Math.PI)}function Ye(t){return qe(t),d(t.rich,qe),t}function qe(t){if(t){t.font=Xe(t);var e=t.textAlign;"middle"===e&&(e="center"),t.textAlign=null==e||Mb[e]?e:"left";var i=t.textVerticalAlign||t.textBaseline;"center"===i&&(i="middle"),t.textVerticalAlign=null==i||Ib[i]?i:"top",t.textPadding&&(t.textPadding=L(t.textPadding))}}function Ke(t,e,i,n,o,a){n.rich?Je(t,e,i,n,o,a):$e(t,e,i,n,o,a)}function $e(t,e,i,n,o,a){var r,s=ii(n),l=!1,u=e.__attrCachedBy===rb.PLAIN_TEXT;a!==sb?(a&&(r=a.style,l=!s&&u&&r),e.__attrCachedBy=s?rb.NONE:rb.PLAIN_TEXT):u&&(e.__attrCachedBy=rb.NONE);var h=n.font||Sb;l&&h===(r.font||Sb)||(e.font=h);var c=t.__computedFont;t.__styleFont!==h&&(t.__styleFont=h,c=t.__computedFont=e.font);var d=n.textPadding,f=n.textLineHeight,p=t.__textCotentBlock;p&&!t.__dirtyText||(p=t.__textCotentBlock=He(i,c,d,f,n.truncate));var g=p.outerHeight,m=p.lines,v=p.lineHeight,y=ai(g,n,o),x=y.baseX,_=y.baseY,w=y.textAlign||"left",b=y.textVerticalAlign;ti(e,n,o,x,_);var S=Ee(_,g,b),M=x,I=S;if(s||d){var T=Le(i,c);d&&(T+=d[1]+d[3]);var A=Oe(x,T,w);s&&ni(t,e,n,A,S,T,g),d&&(M=hi(x,w,d),I+=d[0])}e.textAlign=w,e.textBaseline="middle",e.globalAlpha=n.opacity||1;for(B=0;B=0&&"right"===(_=b[C]).textAlign;)ei(t,e,_,n,M,v,D,"right"),I-=_.width,D-=_.width,C--;for(A+=(a-(A-m)-(y-D)-I)/2;T<=C;)ei(t,e,_=b[T],n,M,v,A+_.width/2,"center"),A+=_.width,T++;v+=M}}function ti(t,e,i,n,o){if(i&&e.textRotation){var a=e.textOrigin;"center"===a?(n=i.width/2+i.x,o=i.height/2+i.y):a&&(n=a[0]+i.x,o=a[1]+i.y),t.translate(n,o),t.rotate(-e.textRotation),t.translate(-n,-o)}}function ei(t,e,i,n,o,a,r,s){var l=n.rich[i.styleName]||{};l.text=i.text;var u=i.textVerticalAlign,h=a+o/2;"top"===u?h=a+i.height/2:"bottom"===u&&(h=a+o-i.height/2),!i.isLineHolder&&ii(l)&&ni(t,e,l,"right"===s?r-i.width:"center"===s?r-i.width/2:r,h-i.height/2,i.width,i.height);var c=i.textPadding;c&&(r=hi(r,s,c),h-=i.height/2-c[2]-i.textHeight/2),ri(e,"shadowBlur",D(l.textShadowBlur,n.textShadowBlur,0)),ri(e,"shadowColor",l.textShadowColor||n.textShadowColor||"transparent"),ri(e,"shadowOffsetX",D(l.textShadowOffsetX,n.textShadowOffsetX,0)),ri(e,"shadowOffsetY",D(l.textShadowOffsetY,n.textShadowOffsetY,0)),ri(e,"textAlign",s),ri(e,"textBaseline","middle"),ri(e,"font",i.font||Sb);var d=si(l.textStroke||n.textStroke,p),f=li(l.textFill||n.textFill),p=A(l.textStrokeWidth,n.textStrokeWidth);d&&(ri(e,"lineWidth",p),ri(e,"strokeStyle",d),e.strokeText(i.text,r,h)),f&&(ri(e,"fillStyle",f),e.fillText(i.text,r,h))}function ii(t){return!!(t.textBackgroundColor||t.textBorderWidth&&t.textBorderColor)}function ni(t,e,i,n,o,a,r){var s=i.textBackgroundColor,l=i.textBorderWidth,u=i.textBorderColor,h=_(s);if(ri(e,"shadowBlur",i.textBoxShadowBlur||0),ri(e,"shadowColor",i.textBoxShadowColor||"transparent"),ri(e,"shadowOffsetX",i.textBoxShadowOffsetX||0),ri(e,"shadowOffsetY",i.textBoxShadowOffsetY||0),h||l&&u){e.beginPath();var c=i.textBorderRadius;c?je(e,{x:n,y:o,width:a,height:r,r:c}):e.rect(n,o,a,r),e.closePath()}if(h)if(ri(e,"fillStyle",s),null!=i.fillOpacity){f=e.globalAlpha;e.globalAlpha=i.fillOpacity*i.opacity,e.fill(),e.globalAlpha=f}else e.fill();else if(w(s)){var d=s.image;(d=Ae(d,null,t,oi,s))&&Ce(d)&&e.drawImage(d,n,o,a,r)}if(l&&u)if(ri(e,"lineWidth",l),ri(e,"strokeStyle",u),null!=i.strokeOpacity){var f=e.globalAlpha;e.globalAlpha=i.strokeOpacity*i.opacity,e.stroke(),e.globalAlpha=f}else e.stroke()}function oi(t,e){e.image=t}function ai(t,e,i){var n=e.x||0,o=e.y||0,a=e.textAlign,r=e.textVerticalAlign;if(i){var s=e.textPosition;if(s instanceof Array)n=i.x+ui(s[0],i.width),o=i.y+ui(s[1],i.height);else{var l=Re(s,i,e.textDistance);n=l.x,o=l.y,a=a||l.textAlign,r=r||l.textVerticalAlign}var u=e.textOffset;u&&(n+=u[0],o+=u[1])}return{baseX:n,baseY:o,textAlign:a,textVerticalAlign:r}}function ri(t,e,i){return t[e]=ab(t,e,i),t[e]}function si(t,e){return null==t||e<=0||"transparent"===t||"none"===t?null:t.image||t.colorStops?"#000":t}function li(t){return null==t||"none"===t?null:t.image||t.colorStops?"#000":t}function ui(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t}function hi(t,e,i){return"right"===e?t-i[1]:"center"===e?t+i[3]/2-i[1]/2:t+i[3]}function ci(t,e){return null!=t&&(t||e.textBackgroundColor||e.textBorderWidth&&e.textBorderColor||e.textPadding)}function di(t){t=t||{},Kw.call(this,t);for(var e in t)t.hasOwnProperty(e)&&"style"!==e&&(this[e]=t[e]);this.style=new ub(t.style,this),this._rect=null,this.__clipPaths=[]}function fi(t){di.call(this,t)}function pi(t){return parseInt(t,10)}function gi(t){return!!t&&(!!t.__builtin__||"function"==typeof t.resize&&"function"==typeof t.refresh)}function mi(t,e,i){return Cb.copy(t.getBoundingRect()),t.transform&&Cb.applyTransform(t.transform),Lb.width=e,Lb.height=i,!Cb.intersect(Lb)}function vi(t,e){if(t===e)return!1;if(!t||!e||t.length!==e.length)return!0;for(var i=0;i=i.length&&i.push({option:t})}}),i}function Ni(t){var e=R();Zb(t,function(t,i){var n=t.exist;n&&e.set(n.id,t)}),Zb(t,function(t,i){var n=t.option;k(!n||null==n.id||!e.get(n.id)||e.get(n.id)===t,"id duplicates: "+(n&&n.id)),n&&null!=n.id&&e.set(n.id,t),!t.keyInfo&&(t.keyInfo={})}),Zb(t,function(t,i){var n=t.exist,o=t.option,a=t.keyInfo;if(Ub(o)){if(a.name=null!=o.name?o.name+"":n?n.name:jb+i,n)a.id=n.id;else if(null!=o.id)a.id=o.id+"";else{var r=0;do{a.id="\0"+a.name+"\0"+r++}while(e.get(a.id))}e.set(a.id,t)}})}function Oi(t){var e=t.name;return!(!e||!e.indexOf(jb))}function Ei(t){return Ub(t)&&t.id&&0===(t.id+"").indexOf("\0_ec_\0")}function Ri(t,e){function i(t,e,i){for(var n=0,o=t.length;n-rS&&trS||t<-rS}function Qi(t,e,i,n,o){var a=1-o;return a*a*(a*t+3*o*e)+o*o*(o*n+3*a*i)}function tn(t,e,i,n,o){var a=1-o;return 3*(((e-t)*a+2*(i-e)*o)*a+(n-i)*o*o)}function en(t,e,i,n,o,a){var r=n+3*(e-i)-t,s=3*(i-2*e+t),l=3*(e-t),u=t-o,h=s*s-3*r*l,c=s*l-9*r*u,d=l*l-3*s*u,f=0;if($i(h)&&$i(c))$i(s)?a[0]=0:(M=-l/s)>=0&&M<=1&&(a[f++]=M);else{var p=c*c-4*h*d;if($i(p)){var g=c/h,m=-g/2;(M=-s/r+g)>=0&&M<=1&&(a[f++]=M),m>=0&&m<=1&&(a[f++]=m)}else if(p>0){var v=aS(p),y=h*s+1.5*r*(-c+v),x=h*s+1.5*r*(-c-v);(M=(-s-((y=y<0?-oS(-y,uS):oS(y,uS))+(x=x<0?-oS(-x,uS):oS(x,uS))))/(3*r))>=0&&M<=1&&(a[f++]=M)}else{var _=(2*h*s-3*r*c)/(2*aS(h*h*h)),w=Math.acos(_)/3,b=aS(h),S=Math.cos(w),M=(-s-2*b*S)/(3*r),m=(-s+b*(S+lS*Math.sin(w)))/(3*r),I=(-s+b*(S-lS*Math.sin(w)))/(3*r);M>=0&&M<=1&&(a[f++]=M),m>=0&&m<=1&&(a[f++]=m),I>=0&&I<=1&&(a[f++]=I)}}return f}function nn(t,e,i,n,o){var a=6*i-12*e+6*t,r=9*e+3*n-3*t-9*i,s=3*e-3*t,l=0;if($i(r))Ji(a)&&(c=-s/a)>=0&&c<=1&&(o[l++]=c);else{var u=a*a-4*r*s;if($i(u))o[0]=-a/(2*r);else if(u>0){var h=aS(u),c=(-a+h)/(2*r),d=(-a-h)/(2*r);c>=0&&c<=1&&(o[l++]=c),d>=0&&d<=1&&(o[l++]=d)}}return l}function on(t,e,i,n,o,a){var r=(e-t)*o+t,s=(i-e)*o+e,l=(n-i)*o+i,u=(s-r)*o+r,h=(l-s)*o+s,c=(h-u)*o+u;a[0]=t,a[1]=r,a[2]=u,a[3]=c,a[4]=c,a[5]=h,a[6]=l,a[7]=n}function an(t,e,i,n,o,a,r,s,l,u,h){var c,d,f,p,g,m=.005,v=1/0;hS[0]=l,hS[1]=u;for(var y=0;y<1;y+=.05)cS[0]=Qi(t,i,o,r,y),cS[1]=Qi(e,n,a,s,y),(p=hw(hS,cS))=0&&p=0&&c<=1&&(o[l++]=c);else{var u=r*r-4*a*s;if($i(u))(c=-r/(2*a))>=0&&c<=1&&(o[l++]=c);else if(u>0){var h=aS(u),c=(-r+h)/(2*a),d=(-r-h)/(2*a);c>=0&&c<=1&&(o[l++]=c),d>=0&&d<=1&&(o[l++]=d)}}return l}function un(t,e,i){var n=t+i-2*e;return 0===n?.5:(t-e)/n}function hn(t,e,i,n,o){var a=(e-t)*n+t,r=(i-e)*n+e,s=(r-a)*n+a;o[0]=t,o[1]=a,o[2]=s,o[3]=s,o[4]=r,o[5]=i}function cn(t,e,i,n,o,a,r,s,l){var u,h=.005,c=1/0;hS[0]=r,hS[1]=s;for(var d=0;d<1;d+=.05)cS[0]=rn(t,i,o,d),cS[1]=rn(e,n,a,d),(m=hw(hS,cS))=0&&m1e-4)return s[0]=t-i,s[1]=e-n,l[0]=t+i,void(l[1]=e+n);if(yS[0]=mS(o)*i+t,yS[1]=gS(o)*n+e,xS[0]=mS(a)*i+t,xS[1]=gS(a)*n+e,u(s,yS,xS),h(l,yS,xS),(o%=vS)<0&&(o+=vS),(a%=vS)<0&&(a+=vS),o>a&&!r?a+=vS:oo&&(_S[0]=mS(f)*i+t,_S[1]=gS(f)*n+e,u(s,_S,s),h(l,_S,l))}function vn(t,e,i,n,o,a,r){if(0===o)return!1;var s=o,l=0,u=t;if(r>e+s&&r>n+s||rt+s&&a>i+s||ae+c&&h>n+c&&h>a+c&&h>s+c||ht+c&&u>i+c&&u>o+c&&u>r+c||ue+u&&l>n+u&&l>a+u||lt+u&&s>i+u&&s>o+u||si||h+uo&&(o+=zS);var d=Math.atan2(l,s);return d<0&&(d+=zS),d>=n&&d<=o||d+zS>=n&&d+zS<=o}function bn(t,e,i,n,o,a){if(a>e&&a>n||ao?r:0}function Sn(t,e){return Math.abs(t-e)e&&u>n&&u>a&&u>s||u1&&Mn(),c=Qi(e,n,a,s,WS[0]),p>1&&(d=Qi(e,n,a,s,WS[1]))),2===p?me&&s>n&&s>a||s=0&&u<=1){for(var h=0,c=rn(e,n,a,u),d=0;di||s<-i)return 0;u=Math.sqrt(i*i-s*s);FS[0]=-u,FS[1]=u;var l=Math.abs(n-o);if(l<1e-4)return 0;if(l%VS<1e-4){n=0,o=VS;p=a?1:-1;return r>=FS[0]+t&&r<=FS[1]+t?p:0}if(a){var u=n;n=_n(o),o=_n(u)}else n=_n(n),o=_n(o);n>o&&(o+=VS);for(var h=0,c=0;c<2;c++){var d=FS[c];if(d+t>r){var f=Math.atan2(s,d),p=a?1:-1;f<0&&(f=VS+f),(f>=n&&f<=o||f+VS>=n&&f+VS<=o)&&(f>Math.PI/2&&f<1.5*Math.PI&&(p=-p),h+=p)}}return h}function Dn(t,e,i,n,o){for(var a=0,r=0,s=0,l=0,u=0,h=0;h1&&(i||(a+=bn(r,s,l,u,n,o))),1===h&&(l=r=t[h],u=s=t[h+1]),c){case BS.M:r=l=t[h++],s=u=t[h++];break;case BS.L:if(i){if(vn(r,s,t[h],t[h+1],e,n,o))return!0}else a+=bn(r,s,t[h],t[h+1],n,o)||0;r=t[h++],s=t[h++];break;case BS.C:if(i){if(yn(r,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],e,n,o))return!0}else a+=In(r,s,t[h++],t[h++],t[h++],t[h++],t[h],t[h+1],n,o)||0;r=t[h++],s=t[h++];break;case BS.Q:if(i){if(xn(r,s,t[h++],t[h++],t[h],t[h+1],e,n,o))return!0}else a+=Tn(r,s,t[h++],t[h++],t[h],t[h+1],n,o)||0;r=t[h++],s=t[h++];break;case BS.A:var d=t[h++],f=t[h++],p=t[h++],g=t[h++],m=t[h++],v=t[h++];h+=1;var y=1-t[h++],x=Math.cos(m)*p+d,_=Math.sin(m)*g+f;h>1?a+=bn(r,s,x,_,n,o):(l=x,u=_);var w=(n-d)*g/p+d;if(i){if(wn(d,f,g,m,m+v,y,e,w,o))return!0}else a+=An(d,f,g,m,m+v,y,w,o);r=Math.cos(m+v)*p+d,s=Math.sin(m+v)*g+f;break;case BS.R:l=r=t[h++],u=s=t[h++];var x=l+t[h++],_=u+t[h++];if(i){if(vn(l,u,x,u,e,n,o)||vn(x,u,x,_,e,n,o)||vn(x,_,l,_,e,n,o)||vn(l,_,l,u,e,n,o))return!0}else a+=bn(x,u,x,_,n,o),a+=bn(l,_,l,u,n,o);break;case BS.Z:if(i){if(vn(r,s,l,u,e,n,o))return!0}else a+=bn(r,s,l,u,n,o);r=l,s=u}}return i||Sn(s,u)||(a+=bn(r,s,l,u,n,o)||0),0!==a}function Cn(t,e,i){return Dn(t,0,!1,e,i)}function Ln(t,e,i,n){return Dn(t,e,!0,i,n)}function kn(t){di.call(this,t),this.path=null}function Pn(t,e,i,n,o,a,r,s,l,u,h){var c=l*(tM/180),d=QS(c)*(t-i)/2+JS(c)*(e-n)/2,f=-1*JS(c)*(t-i)/2+QS(c)*(e-n)/2,p=d*d/(r*r)+f*f/(s*s);p>1&&(r*=$S(p),s*=$S(p));var g=(o===a?-1:1)*$S((r*r*(s*s)-r*r*(f*f)-s*s*(d*d))/(r*r*(f*f)+s*s*(d*d)))||0,m=g*r*f/s,v=g*-s*d/r,y=(t+i)/2+QS(c)*m-JS(c)*v,x=(e+n)/2+JS(c)*m+QS(c)*v,_=nM([1,0],[(d-m)/r,(f-v)/s]),w=[(d-m)/r,(f-v)/s],b=[(-1*d-m)/r,(-1*f-v)/s],S=nM(w,b);iM(w,b)<=-1&&(S=tM),iM(w,b)>=1&&(S=0),0===a&&S>0&&(S-=2*tM),1===a&&S<0&&(S+=2*tM),h.addData(u,y,x,r,s,_,S,c,a)}function Nn(t){if(!t)return new ES;for(var e,i=0,n=0,o=i,a=n,r=new ES,s=ES.CMD,l=t.match(oM),u=0;u=2){if(o&&"spline"!==o){var a=fM(n,o,i,e.smoothConstraint);t.moveTo(n[0][0],n[0][1]);for(var r=n.length,s=0;s<(i?r:r-1);s++){var l=a[2*s],u=a[2*s+1],h=n[(s+1)%r];t.bezierCurveTo(l[0],l[1],u[0],u[1],h[0],h[1])}}else{"spline"===o&&(n=dM(n,i)),t.moveTo(n[0][0],n[0][1]);for(var s=1,c=n.length;s=0)?(i={textFill:null,textStroke:t.textStroke,textStrokeWidth:t.textStrokeWidth},t.textFill="#fff",null==t.textStroke&&(t.textStroke=a,null==t.textStrokeWidth&&(t.textStrokeWidth=2))):null!=a&&(i={textFill:null},t.textFill=a),i&&(t.insideRollback=i)}}function wo(t){var e=t.insideRollback;e&&(t.textFill=e.textFill,t.textStroke=e.textStroke,t.textStrokeWidth=e.textStrokeWidth,t.insideRollback=null)}function bo(t,e){var i=e||e.getModel("textStyle");return P([t.fontStyle||i&&i.getShallow("fontStyle")||"",t.fontWeight||i&&i.getShallow("fontWeight")||"",(t.fontSize||i&&i.getShallow("fontSize")||12)+"px",t.fontFamily||i&&i.getShallow("fontFamily")||"sans-serif"].join(" "))}function So(t,e,i,n,o,a){if("function"==typeof o&&(a=o,o=null),n&&n.isAnimationEnabled()){var r=t?"Update":"",s=n.getShallow("animationDuration"+r),l=n.getShallow("animationEasing"+r),u=n.getShallow("animationDelay"+r);"function"==typeof u&&(u=u(o,n.getAnimationDelayParams?n.getAnimationDelayParams(e,o):null)),"function"==typeof s&&(s=s(o)),s>0?e.animateTo(i,s,u||0,l,a,!!a):(e.stopAnimation(),e.attr(i),a&&a())}else e.stopAnimation(),e.attr(i),a&&a()}function Mo(t,e,i,n,o){So(!0,t,e,i,n,o)}function Io(t,e,i,n,o){So(!1,t,e,i,n,o)}function To(t,e){for(var i=_t([]);t&&t!==e;)bt(i,t.getLocalTransform(),i),t=t.parent;return i}function Ao(t,e,i){return e&&!c(e)&&(e=Tw.getLocalTransform(e)),i&&(e=Tt([],e)),Q([],t,e)}function Do(t,e,i){var n=0===e[4]||0===e[5]||0===e[0]?1:Math.abs(2*e[4]/e[0]),o=0===e[4]||0===e[5]||0===e[2]?1:Math.abs(2*e[4]/e[2]),a=["left"===t?-n:"right"===t?n:0,"top"===t?-o:"bottom"===t?o:0];return a=Ao(a,e,i),Math.abs(a[0])>Math.abs(a[1])?a[0]>0?"right":"left":a[1]>0?"bottom":"top"}function Co(t,e,i,n){function o(t){var e={position:F(t.position),rotation:t.rotation};return t.shape&&(e.shape=a({},t.shape)),e}if(t&&e){var r=function(t){var e={};return t.traverse(function(t){!t.isGroup&&t.anid&&(e[t.anid]=t)}),e}(t);e.traverse(function(t){if(!t.isGroup&&t.anid){var e=r[t.anid];if(e){var n=o(t);t.attr(o(e)),Mo(t,n,i,t.dataIndex)}}})}}function Lo(t,e){return f(t,function(t){var i=t[0];i=LM(i,e.x),i=kM(i,e.x+e.width);var n=t[1];return n=LM(n,e.y),n=kM(n,e.y+e.height),[i,n]})}function ko(t,e,i){var n=(e=a({rectHover:!0},e)).style={strokeNoScale:!0};if(i=i||{x:-1,y:-1,width:2,height:2},t)return 0===t.indexOf("image://")?(n.image=t.slice(8),r(n,i),new fi(e)):Un(t.replace("path://",""),e,i,"center")}function Po(t,e,i){this.parentModel=e,this.ecModel=i,this.option=t}function No(t,e,i){for(var n=0;n0){if(t<=e[0])return i[0];if(t>=e[1])return i[1]}else{if(t>=e[0])return i[0];if(t<=e[1])return i[1]}else{if(t===e[0])return i[0];if(t===e[1])return i[1]}return(t-e[0])/o*a+i[0]}function Bo(t,e){switch(t){case"center":case"middle":t="50%";break;case"left":case"top":t="0%";break;case"right":case"bottom":t="100%"}return"string"==typeof t?Ro(t).match(/%$/)?parseFloat(t)/100*e:parseFloat(t):null==t?NaN:+t}function Vo(t,e,i){return null==e&&(e=10),e=Math.min(Math.max(0,e),20),t=(+t).toFixed(e),i?t:+t}function Go(t){return t.sort(function(t,e){return t-e}),t}function Fo(t){if(t=+t,isNaN(t))return 0;for(var e=1,i=0;Math.round(t*e)/e!==t;)e*=10,i++;return i}function Wo(t){var e=t.toString(),i=e.indexOf("e");if(i>0){var n=+e.slice(i+1);return n<0?-n:0}var o=e.indexOf(".");return o<0?0:e.length-1-o}function Ho(t,e){var i=Math.log,n=Math.LN10,o=Math.floor(i(t[1]-t[0])/n),a=Math.round(i(Math.abs(e[1]-e[0]))/n),r=Math.min(Math.max(-o+a,0),20);return isFinite(r)?r:20}function Zo(t,e,i){if(!t[e])return 0;var n=p(t,function(t,e){return t+(isNaN(e)?0:e)},0);if(0===n)return 0;for(var o=Math.pow(10,i),a=f(t,function(t){return(isNaN(t)?0:t)/n*o*100}),r=100*o,s=f(a,function(t){return Math.floor(t)}),l=p(s,function(t,e){return t+e},0),u=f(a,function(t,e){return t-s[e]});lh&&(h=u[d],c=d);++s[c],u[c]=0,++l}return s[e]/o}function Uo(t){var e=2*Math.PI;return(t%e+e)%e}function Xo(t){return t>-UM&&t=-20?+t.toFixed(n<0?-n:0):t}function $o(t){function e(t,i,n){return t.interval[n]=0}function Qo(t){return isNaN(t)?"-":(t=(t+"").split("."))[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(t.length>1?"."+t[1]:"")}function ta(t,e){return t=(t||"").toLowerCase().replace(/-(.)/g,function(t,e){return e.toUpperCase()}),e&&t&&(t=t.charAt(0).toUpperCase()+t.slice(1)),t}function ea(t){return null==t?"":(t+"").replace(KM,function(t,e){return $M[e]})}function ia(t,e,i){y(e)||(e=[e]);var n=e.length;if(!n)return"";for(var o=e[0].$vars||[],a=0;a':'':{renderMode:o,content:"{marker"+a+"|} ",style:{color:i}}:""}function aa(t,e){return t+="","0000".substr(0,e-t.length)+t}function ra(t,e,i){"week"!==t&&"month"!==t&&"quarter"!==t&&"half-year"!==t&&"year"!==t||(t="MM-dd\nyyyy");var n=jo(e),o=i?"UTC":"",a=n["get"+o+"FullYear"](),r=n["get"+o+"Month"]()+1,s=n["get"+o+"Date"](),l=n["get"+o+"Hours"](),u=n["get"+o+"Minutes"](),h=n["get"+o+"Seconds"](),c=n["get"+o+"Milliseconds"]();return t=t.replace("MM",aa(r,2)).replace("M",r).replace("yyyy",a).replace("yy",a%100).replace("dd",aa(s,2)).replace("d",s).replace("hh",aa(l,2)).replace("h",l).replace("mm",aa(u,2)).replace("m",u).replace("ss",aa(h,2)).replace("s",h).replace("SSS",aa(c,3))}function sa(t){return t?t.charAt(0).toUpperCase()+t.substr(1):t}function la(t,e,i,n,o){var a=0,r=0;null==n&&(n=1/0),null==o&&(o=1/0);var s=0;e.eachChild(function(l,u){var h,c,d=l.position,f=l.getBoundingRect(),p=e.childAt(u+1),g=p&&p.getBoundingRect();if("horizontal"===t){var m=f.width+(g?-g.x+f.x:0);(h=a+m)>n||l.newline?(a=0,h=m,r+=s+i,s=f.height):s=Math.max(s,f.height)}else{var v=f.height+(g?-g.y+f.y:0);(c=r+v)>o||l.newline?(a+=s+i,r=0,c=v,s=f.width):s=Math.max(s,f.width)}l.newline||(d[0]=a,d[1]=r,"horizontal"===t?a=h+i:r=c+i)})}function ua(t,e,i){var n=e.width,o=e.height,a=Bo(t.x,n),r=Bo(t.y,o),s=Bo(t.x2,n),l=Bo(t.y2,o);return(isNaN(a)||isNaN(parseFloat(t.x)))&&(a=0),(isNaN(s)||isNaN(parseFloat(t.x2)))&&(s=n),(isNaN(r)||isNaN(parseFloat(t.y)))&&(r=0),(isNaN(l)||isNaN(parseFloat(t.y2)))&&(l=o),i=qM(i||0),{width:Math.max(s-a-i[1]-i[3],0),height:Math.max(l-r-i[0]-i[2],0)}}function ha(t,e,i){i=qM(i||0);var n=e.width,o=e.height,a=Bo(t.left,n),r=Bo(t.top,o),s=Bo(t.right,n),l=Bo(t.bottom,o),u=Bo(t.width,n),h=Bo(t.height,o),c=i[2]+i[0],d=i[1]+i[3],f=t.aspect;switch(isNaN(u)&&(u=n-s-d-a),isNaN(h)&&(h=o-l-c-r),null!=f&&(isNaN(u)&&isNaN(h)&&(f>n/o?u=.8*n:h=.8*o),isNaN(u)&&(u=f*h),isNaN(h)&&(h=u/f)),isNaN(a)&&(a=n-s-u-d),isNaN(r)&&(r=o-l-h-c),t.left||t.right){case"center":a=n/2-u/2-i[3];break;case"right":a=n-u-d}switch(t.top||t.bottom){case"middle":case"center":r=o/2-h/2-i[0];break;case"bottom":r=o-h-c}a=a||0,r=r||0,isNaN(u)&&(u=n-d-a-(s||0)),isNaN(h)&&(h=o-c-r-(l||0));var p=new de(a+i[3],r+i[0],u,h);return p.margin=i,p}function ca(t,e,i,n,o){var a=!o||!o.hv||o.hv[0],s=!o||!o.hv||o.hv[1],l=o&&o.boundingMode||"all";if(a||s){var u;if("raw"===l)u="group"===t.type?new de(0,0,+e.width||0,+e.height||0):t.getBoundingRect();else if(u=t.getBoundingRect(),t.needLocalTransform()){var h=t.getLocalTransform();(u=u.clone()).applyTransform(h)}e=ha(r({width:u.width,height:u.height},e),i,n);var c=t.position,d=a?e.x-u.x:0,f=s?e.y-u.y:0;t.attr("position","raw"===l?[d,f]:[c[0]+d,c[1]+f])}}function da(t,e){return null!=t[aI[e][0]]||null!=t[aI[e][1]]&&null!=t[aI[e][2]]}function fa(t,e,i){function n(i,n){var r={},l=0,u={},h=0;if(nI(i,function(e){u[e]=t[e]}),nI(i,function(t){o(e,t)&&(r[t]=u[t]=e[t]),a(r,t)&&l++,a(u,t)&&h++}),s[n])return a(e,i[1])?u[i[2]]=null:a(e,i[2])&&(u[i[1]]=null),u;if(2!==h&&l){if(l>=2)return r;for(var c=0;ce)return t[n];return t[i-1]}function va(t){var e=t.get("coordinateSystem"),i={coordSysName:e,coordSysDims:[],axisMap:R(),categoryAxisMap:R()},n=pI[e];if(n)return n(t,i,i.axisMap,i.categoryAxisMap),i}function ya(t){return"category"===t.get("type")}function xa(t){this.fromDataset=t.fromDataset,this.data=t.data||(t.sourceFormat===yI?{}:[]),this.sourceFormat=t.sourceFormat||xI,this.seriesLayoutBy=t.seriesLayoutBy||wI,this.dimensionsDefine=t.dimensionsDefine,this.encodeDefine=t.encodeDefine&&R(t.encodeDefine),this.startIndex=t.startIndex||0,this.dimensionsDetectCount=t.dimensionsDetectCount}function _a(t){var e=t.option.source,i=xI;if(S(e))i=_I;else if(y(e)){0===e.length&&(i=mI);for(var n=0,o=e.length;n=e:"max"===i?t<=e:t===e}function Ua(t,e){return t.join(",")===e.join(",")}function Xa(t,e){DI(e=e||{},function(e,i){if(null!=e){var n=t[i];if(uI.hasClass(i)){e=Di(e);var o=Pi(n=Di(n),e);t[i]=LI(o,function(t){return t.option&&t.exist?kI(t.exist,t.option,!0):t.exist||t.option})}else t[i]=kI(n,e,!0)}})}function ja(t){var e=t&&t.itemStyle;if(e)for(var i=0,o=EI.length;i=0;p--){var g=t[p];if(s||(d=g.data.rawIndexOf(g.stackedByDimension,c)),d>=0){var m=g.data.getByRawIndex(g.stackResultDimension,d);if(h>=0&&m>0||h<=0&&m<0){h+=m,f=m;break}}}return n[0]=h,n[1]=f,n});r.hostModel.setData(l),e.data=l})}function ar(t,e){xa.isInstance(t)||(t=xa.seriesDataToSource(t)),this._source=t;var i=this._data=t.data,n=t.sourceFormat;n===_I&&(this._offset=0,this._dimSize=e,this._data=i),a(this,FI[n===mI?n+"_"+t.seriesLayoutBy:n])}function rr(){return this._data.length}function sr(t){return this._data[t]}function lr(t){for(var e=0;ee.outputData.count()&&e.model.getRawData().cloneShallow(e.outputData)}function Sr(t,e){d(t.CHANGABLE_METHODS,function(i){t.wrapMethod(i,v(Mr,e))})}function Mr(t){var e=Ir(t);e&&e.setOutputEnd(this.count())}function Ir(t){var e=(t.ecModel||{}).scheduler,i=e&&e.getPipeline(t.uid);if(i){var n=i.currentTask;if(n){var o=n.agentStubMap;o&&(n=o.get(t.uid))}return n}}function Tr(){this.group=new tb,this.uid=Eo("viewChart"),this.renderTask=pr({plan:Cr,reset:Lr}),this.renderTask.context={view:this}}function Ar(t,e){if(t&&(t.trigger(e),"group"===t.type))for(var i=0;i=0?n():c=setTimeout(n,-a),u=o};return d.clear=function(){c&&(clearTimeout(c),c=null)},d.debounceNextCall=function(t){l=t},d}function Pr(t,e,i,n){var o=t[e];if(o){var a=o[nT]||o,r=o[aT];if(o[oT]!==i||r!==n){if(null==i||!n)return t[e]=a;(o=t[e]=kr(a,i,"debounce"===n))[nT]=a,o[aT]=n,o[oT]=i}return o}}function Nr(t,e){var i=t[e];i&&i[nT]&&(t[e]=i[nT])}function Or(t,e,i,n){this.ecInstance=t,this.api=e,this.unfinished;var i=this._dataProcessorHandlers=i.slice(),n=this._visualHandlers=n.slice();this._allHandlers=i.concat(n),this._stageTaskMap=R()}function Er(t,e,i,n,o){function a(t,e){return t.setDirty&&(!t.dirtyMap||t.dirtyMap.get(e.__pipeline.id))}o=o||{};var r;d(e,function(e,s){if(!o.visualType||o.visualType===e.visualType){var l=t._stageTaskMap.get(e.uid),u=l.seriesTaskMap,h=l.overallTask;if(h){var c,d=h.agentStubMap;d.each(function(t){a(o,t)&&(t.dirty(),c=!0)}),c&&h.dirty(),cT(h,n);var f=t.getPerformArgs(h,o.block);d.each(function(t){t.perform(f)}),r|=h.perform(f)}else u&&u.each(function(s,l){a(o,s)&&s.dirty();var u=t.getPerformArgs(s,o.block);u.skip=!e.performRawSeries&&i.isSeriesFiltered(s.context.model),cT(s,n),r|=s.perform(u)})}}),t.unfinished|=r}function Rr(t,e,i,n,o){function a(i){var a=i.uid,s=r.get(a)||r.set(a,pr({plan:Wr,reset:Hr,count:Ur}));s.context={model:i,ecModel:n,api:o,useClearVisual:e.isVisual&&!e.isLayout,plan:e.plan,reset:e.reset,scheduler:t},Xr(t,i,s)}var r=i.seriesTaskMap||(i.seriesTaskMap=R()),s=e.seriesType,l=e.getTargetSeries;e.createOnAllSeries?n.eachRawSeries(a):s?n.eachRawSeriesByType(s,a):l&&l(n,o).each(a);var u=t._pipelineMap;r.each(function(t,e){u.get(e)||(t.dispose(),r.removeKey(e))})}function zr(t,e,i,n,o){function a(e){var i=e.uid,n=s.get(i);n||(n=s.set(i,pr({reset:Vr,onDirty:Fr})),r.dirty()),n.context={model:e,overallProgress:h,modifyOutputEnd:c},n.agent=r,n.__block=h,Xr(t,e,n)}var r=i.overallTask=i.overallTask||pr({reset:Br});r.context={ecModel:n,api:o,overallReset:e.overallReset,scheduler:t};var s=r.agentStubMap=r.agentStubMap||R(),l=e.seriesType,u=e.getTargetSeries,h=!0,c=e.modifyOutputEnd;l?n.eachRawSeriesByType(l,a):u?u(n,o).each(a):(h=!1,d(n.getSeries(),a));var f=t._pipelineMap;s.each(function(t,e){f.get(e)||(t.dispose(),r.dirty(),s.removeKey(e))})}function Br(t){t.overallReset(t.ecModel,t.api,t.payload)}function Vr(t,e){return t.overallProgress&&Gr}function Gr(){this.agent.dirty(),this.getDownstream().dirty()}function Fr(){this.agent&&this.agent.dirty()}function Wr(t){return t.plan&&t.plan(t.model,t.ecModel,t.api,t.payload)}function Hr(t){t.useClearVisual&&t.data.clearAllVisual();var e=t.resetDefines=Di(t.reset(t.model,t.ecModel,t.api,t.payload));return e.length>1?f(e,function(t,e){return Zr(e)}):dT}function Zr(t){return function(e,i){var n=i.data,o=i.resetDefines[t];if(o&&o.dataEach)for(var a=e.start;a0?parseInt(n,10)/100:n?parseFloat(n):0;var o=i.getAttribute("stop-color")||"#000000";e.addColorStop(n,o)}i=i.nextSibling}}function Jr(t,e){t&&t.__inheritedStyle&&(e.__inheritedStyle||(e.__inheritedStyle={}),r(e.__inheritedStyle,t.__inheritedStyle))}function Qr(t){for(var e=P(t).split(wT),i=[],n=0;n0;a-=2){var r=o[a],s=o[a-1];switch(n=n||xt(),s){case"translate":r=P(r).split(wT),St(n,n,[parseFloat(r[0]),parseFloat(r[1]||0)]);break;case"scale":r=P(r).split(wT),It(n,n,[parseFloat(r[0]),parseFloat(r[1]||r[0])]);break;case"rotate":r=P(r).split(wT),Mt(n,n,parseFloat(r[0]));break;case"skew":r=P(r).split(wT),console.warn("Skew transform is not supported yet");break;case"matrix":r=P(r).split(wT);n[0]=parseFloat(r[0]),n[1]=parseFloat(r[1]),n[2]=parseFloat(r[2]),n[3]=parseFloat(r[3]),n[4]=parseFloat(r[4]),n[5]=parseFloat(r[5])}}e.setLocalTransform(n)}}function ns(t){var e=t.getAttribute("style"),i={};if(!e)return i;var n={};AT.lastIndex=0;for(var o;null!=(o=AT.exec(e));)n[o[1]]=o[2];for(var a in MT)MT.hasOwnProperty(a)&&null!=n[a]&&(i[MT[a]]=n[a]);return i}function os(t,e,i){var n=e/t.width,o=i/t.height,a=Math.min(n,o);return{scale:[a,a],position:[-(t.x+t.width/2)*a+e/2,-(t.y+t.height/2)*a+i/2]}}function as(t,e){return(new Kr).parse(t,e)}function rs(t){return function(e,i,n){e=e&&e.toLowerCase(),fw.prototype[t].call(this,e,i,n)}}function ss(){fw.call(this)}function ls(t,e,n){function o(t,e){return t.__prio-e.__prio}n=n||{},"string"==typeof e&&(e=QT[e]),this.id,this.group,this._dom=t;var a=this._zr=Ii(t,{renderer:n.renderer||"canvas",devicePixelRatio:n.devicePixelRatio,width:n.width,height:n.height});this._throttledZrFlush=kr(m(a.flush,a),17),(e=i(e))&&VI(e,!0),this._theme=e,this._chartsViews=[],this._chartsMap={},this._componentsViews=[],this._componentsMap={},this._coordSysMgr=new Ga;var r=this._api=Ts(this);_e(JT,o),_e(qT,o),this._scheduler=new Or(this,r,qT,JT),fw.call(this,this._ecEventProcessor=new As),this._messageCenter=new ss,this._initEvents(),this.resize=m(this.resize,this),this._pendingActions=[],a.animation.on("frame",this._onframe,this),ms(a,this),N(this)}function us(t,e,i){var n,o=this._model,a=this._coordSysMgr.getCoordinateSystems();e=Vi(o,e);for(var r=0;re.get("hoverLayerThreshold")&&!U_.node&&i.traverse(function(t){t.isGroup||(t.useHoverLayer=!0)})}function Ms(t,e){var i=t.get("blendMode")||null;e.group.traverse(function(t){t.isGroup||t.style.blend!==i&&t.setStyle("blend",i),t.eachPendingDisplayable&&t.eachPendingDisplayable(function(t){t.setStyle("blend",i)})})}function Is(t,e){var i=t.get("z"),n=t.get("zlevel");e.group.traverse(function(t){"group"!==t.type&&(null!=i&&(t.z=i),null!=n&&(t.zlevel=n))})}function Ts(t){var e=t._coordSysMgr;return a(new Va(t),{getCoordinateSystems:m(e.getCoordinateSystems,e),getComponentByElement:function(e){for(;e;){var i=e.__ecComponentInfo;if(null!=i)return t._model.getComponent(i.mainType,i.index);e=e.parent}}})}function As(){this.eventInfo}function Ds(t){function e(t,e){for(var n=0;n65535?fA:gA}function $s(t){var e=t.constructor;return e===Array?t.slice():new e(t)}function Js(t,e){d(mA.concat(e.__wrappedMethods||[]),function(i){e.hasOwnProperty(i)&&(t[i]=e[i])}),t.__wrappedMethods=e.__wrappedMethods,d(vA,function(n){t[n]=i(e[n])}),t._calculationInfo=a(e._calculationInfo)}function Qs(t,e,i,n,o){var a=dA[e.type],r=n-1,s=e.name,l=t[s][r];if(l&&l.length=0?this._indices[t]:-1}function ol(t,e){var i=t._idList[e];return null==i&&(i=el(t,t._idDimIdx,e)),null==i&&(i=cA+e),i}function al(t){return y(t)||(t=[t]),t}function rl(t,e){var i=t.dimensions,n=new yA(f(i,t.getDimensionInfo,t),t.hostModel);Js(n,t);for(var o=n._storage={},a=t._storage,r=0;r=0?(o[s]=sl(a[s]),n._rawExtent[s]=ll(),n._extent[s]=null):o[s]=a[s])}return n}function sl(t){for(var e=new Array(t.length),i=0;in&&(r=o.interval=n);var s=o.intervalPrecision=Sl(r);return Il(o.niceTickExtent=[IA(Math.ceil(t[0]/r)*r,s),IA(Math.floor(t[1]/r)*r,s)],t),o}function Sl(t){return Wo(t)+2}function Ml(t,e,i){t[e]=Math.max(Math.min(t[e],i[1]),i[0])}function Il(t,e){!isFinite(t[0])&&(t[0]=e[0]),!isFinite(t[1])&&(t[1]=e[1]),Ml(t,0,e),Ml(t,1,e),t[0]>t[1]&&(t[0]=t[1])}function Tl(t,e,i,n){var o=[];if(!t)return o;e[0]1e4)return[];return e[1]>(o.length?o[o.length-1]:i[1])&&o.push(e[1]),o}function Al(t){return t.get("stack")||DA+t.seriesIndex}function Dl(t){return t.dim+t.index}function Cl(t){var e=[],i=t.axis;if("category"===i.type){for(var n=i.getBandWidth(),o=0;o=0?"p":"n",b=m;p&&(o[r][_]||(o[r][_]={p:m,n:m}),b=o[r][_][w]);var S,M,I,T;if(g)S=b,M=(A=i.dataToPoint([x,_]))[1]+l,I=A[0]-m,T=u,Math.abs(I)a[1]?(n=a[1],o=a[0]):(n=a[0],o=a[1]);var r=e.toGlobalCoord(e.dataToCoord(0));return ro&&(r=o),r}function Bl(t,e){return GA(t,VA(e))}function Vl(t,e){var i,n,o,a=t.type,r=e.getMin(),s=e.getMax(),l=null!=r,u=null!=s,h=t.getExtent();"ordinal"===a?i=e.getCategories().length:(y(n=e.get("boundaryGap"))||(n=[n||0,n||0]),"boolean"==typeof n[0]&&(n=[0,0]),n[0]=Bo(n[0],1),n[1]=Bo(n[1],1),o=h[1]-h[0]||Math.abs(h[0])),null==r&&(r="ordinal"===a?i?0:NaN:h[0]-n[0]*o),null==s&&(s="ordinal"===a?i?i-1:NaN:h[1]+n[1]*o),"dataMin"===r?r=h[0]:"function"==typeof r&&(r=r({min:h[0],max:h[1]})),"dataMax"===s?s=h[1]:"function"==typeof s&&(s=s({min:h[0],max:h[1]})),(null==r||!isFinite(r))&&(r=NaN),(null==s||!isFinite(s))&&(s=NaN),t.setBlank(I(r)||I(s)||"ordinal"===a&&!t.getOrdinalMeta().categories.length),e.getNeedCrossZero()&&(r>0&&s>0&&!l&&(r=0),r<0&&s<0&&!u&&(s=0));var c=e.ecModel;if(c&&"time"===a){var f,p=Ll("bar",c);if(d(p,function(t){f|=t.getBaseAxis()===e.axis}),f){var g=kl(p),m=Gl(r,s,e,g);r=m.min,s=m.max}}return[r,s]}function Gl(t,e,i,n){var o=i.axis.getExtent(),a=o[1]-o[0],r=Nl(n,i.axis);if(void 0===r)return{min:t,max:e};var s=1/0;d(r,function(t){s=Math.min(t.offset,s)});var l=-1/0;d(r,function(t){l=Math.max(t.offset+t.width,l)}),s=Math.abs(s),l=Math.abs(l);var u=s+l,h=e-t,c=h/(1-(s+l)/a)-h;return e+=c*(l/u),t-=c*(s/u),{min:t,max:e}}function Fl(t,e){var i=Vl(t,e),n=null!=e.getMin(),o=null!=e.getMax(),a=e.get("splitNumber");"log"===t.type&&(t.base=e.get("logBase"));var r=t.type;t.setExtent(i[0],i[1]),t.niceExtent({splitNumber:a,fixMin:n,fixMax:o,minInterval:"interval"===r||"time"===r?e.get("minInterval"):null,maxInterval:"interval"===r||"time"===r?e.get("maxInterval"):null});var s=e.get("interval");null!=s&&t.setInterval&&t.setInterval(s)}function Wl(t,e){if(e=e||t.get("type"))switch(e){case"category":return new MA(t.getOrdinalMeta?t.getOrdinalMeta():t.getCategories(),[1/0,-1/0]);case"value":return new AA;default:return(yl.getClass(e)||AA).create(t)}}function Hl(t){var e=t.scale.getExtent(),i=e[0],n=e[1];return!(i>0&&n>0||i<0&&n<0)}function Zl(t){var e=t.getLabelModel().get("formatter"),i="category"===t.type?t.scale.getExtent()[0]:null;return"string"==typeof e?e=function(e){return function(i){return i=t.scale.getLabel(i),e.replace("{value}",null!=i?i:"")}}(e):"function"==typeof e?function(n,o){return null!=i&&(o=n-i),e(Ul(t,n),o)}:function(e){return t.scale.getLabel(e)}}function Ul(t,e){return"category"===t.type?t.scale.getLabel(e):e}function Xl(t){var e=t.model,i=t.scale;if(e.get("axisLabel.show")&&!i.isBlank()){var n,o,a="category"===t.type,r=i.getExtent();o=a?i.count():(n=i.getTicks()).length;var s,l=t.getLabelModel(),u=Zl(t),h=1;o>40&&(h=Math.ceil(o/40));for(var c=0;c>1^-(1&s),l=l>>1^-(1&l),o=s+=o,a=l+=a,n.push([s/i,l/i])}return n}function nu(t){return"category"===t.type?au(t):lu(t)}function ou(t,e){return"category"===t.type?su(t,e):{ticks:t.scale.getTicks()}}function au(t){var e=t.getLabelModel(),i=ru(t,e);return!e.get("show")||t.scale.isBlank()?{labels:[],labelCategoryInterval:i.labelCategoryInterval}:i}function ru(t,e){var i=uu(t,"labels"),n=Yl(e),o=hu(i,n);if(o)return o;var a,r;return a=x(n)?mu(t,n):gu(t,r="auto"===n?du(t):n),cu(i,n,{labels:a,labelCategoryInterval:r})}function su(t,e){var i=uu(t,"ticks"),n=Yl(e),o=hu(i,n);if(o)return o;var a,r;if(e.get("show")&&!t.scale.isBlank()||(a=[]),x(n))a=mu(t,n,!0);else if("auto"===n){var s=ru(t,t.getLabelModel());r=s.labelCategoryInterval,a=f(s.labels,function(t){return t.tickValue})}else a=gu(t,r=n,!0);return cu(i,n,{ticks:a,tickCategoryInterval:r})}function lu(t){var e=t.scale.getTicks(),i=Zl(t);return{labels:f(e,function(e,n){return{formattedLabel:i(e,n),rawLabel:t.scale.getLabel(e),tickValue:e}})}}function uu(t,e){return oD(t)[e]||(oD(t)[e]=[])}function hu(t,e){for(var i=0;i40&&(s=Math.max(1,Math.floor(r/40)));for(var l=a[0],u=t.dataToCoord(l+1)-t.dataToCoord(l),h=Math.abs(u*Math.cos(n)),c=Math.abs(u*Math.sin(n)),d=0,f=0;l<=a[1];l+=s){var p=0,g=0,m=ke(i(l),e.font,"center","top");p=1.3*m.width,g=1.3*m.height,d=Math.max(d,p,7),f=Math.max(f,g,7)}var v=d/h,y=f/c;isNaN(v)&&(v=1/0),isNaN(y)&&(y=1/0);var x=Math.max(0,Math.floor(Math.min(v,y))),_=oD(t.model),w=_.lastAutoInterval,b=_.lastTickCount;return null!=w&&null!=b&&Math.abs(w-x)<=1&&Math.abs(b-r)<=1&&w>x?x=w:(_.lastTickCount=r,_.lastAutoInterval=x),x}function pu(t){var e=t.getLabelModel();return{axisRotate:t.getRotate?t.getRotate():t.isHorizontal&&!t.isHorizontal()?90:0,labelRotate:e.get("rotate")||0,font:e.getFont()}}function gu(t,e,i){function n(t){l.push(i?t:{formattedLabel:o(t),rawLabel:a.getLabel(t),tickValue:t})}var o=Zl(t),a=t.scale,r=a.getExtent(),s=t.getLabelModel(),l=[],u=Math.max((e||0)+1,1),h=r[0],c=a.count();0!==h&&u>1&&c/u>2&&(h=Math.round(Math.ceil(h/u)*u));var d=ql(t),f=s.get("showMinLabel")||d,p=s.get("showMaxLabel")||d;f&&h!==r[0]&&n(r[0]);for(var g=h;g<=r[1];g+=u)n(g);return p&&g!==r[1]&&n(r[1]),l}function mu(t,e,i){var n=t.scale,o=Zl(t),a=[];return d(n.getTicks(),function(t){var r=n.getLabel(t);e(t,r)&&a.push(i?t:{formattedLabel:o(t),rawLabel:r,tickValue:t})}),a}function vu(t,e){var i=(t[1]-t[0])/e/2;t[0]+=i,t[1]-=i}function yu(t,e,i,n,o){function a(t,e){return h?t>e:t0&&(t.coord-=u/(2*(e+1)))}),s={coord:e[r-1].coord+u},e.push(s)}var h=l[0]>l[1];a(e[0].coord,l[0])&&(o?e[0].coord=l[0]:e.shift()),o&&a(l[0],e[0].coord)&&e.unshift({coord:l[0]}),a(l[1],s.coord)&&(o?s.coord=l[1]:e.pop()),o&&a(s.coord,l[1])&&e.push({coord:l[1]})}}function xu(t,e){var i=t.mapDimension("defaultedLabel",!0),n=i.length;if(1===n)return dr(t,e,i[0]);if(n){for(var o=[],a=0;a0?i=n[0]:n[1]<0&&(i=n[1]),i}function Nu(t,e,i,n){var o=NaN;t.stacked&&(o=i.get(i.getCalculationInfo("stackedOverDimension"),n)),isNaN(o)&&(o=t.valueStart);var a=t.baseDataOffset,r=[];return r[a]=i.get(t.baseDim,n),r[1-a]=o,e.dataToPoint(r)}function Ou(t,e){var i=[];return e.diff(t).add(function(t){i.push({cmd:"+",idx:t})}).update(function(t,e){i.push({cmd:"=",idx:e,idx1:t})}).remove(function(t){i.push({cmd:"-",idx:t})}).execute(),i}function Eu(t){return isNaN(t[0])||isNaN(t[1])}function Ru(t,e,i,n,o,a,r,s,l,u,h){return"none"!==u&&u?zu.apply(this,arguments):Bu.apply(this,arguments)}function zu(t,e,i,n,o,a,r,s,l,u,h){for(var c=0,d=i,f=0;f=o||d<0)break;if(Eu(p)){if(h){d+=a;continue}break}if(d===i)t[a>0?"moveTo":"lineTo"](p[0],p[1]);else if(l>0){var g=e[c],m="y"===u?1:0,v=(p[m]-g[m])*l;wD(SD,g),SD[m]=g[m]+v,wD(MD,p),MD[m]=p[m]-v,t.bezierCurveTo(SD[0],SD[1],MD[0],MD[1],p[0],p[1])}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}function Bu(t,e,i,n,o,a,r,s,l,u,h){for(var c=0,d=i,f=0;f=o||d<0)break;if(Eu(p)){if(h){d+=a;continue}break}if(d===i)t[a>0?"moveTo":"lineTo"](p[0],p[1]),wD(SD,p);else if(l>0){var g=d+a,m=e[g];if(h)for(;m&&Eu(e[g]);)m=e[g+=a];var v=.5,y=e[c];if(!(m=e[g])||Eu(m))wD(MD,p);else{Eu(m)&&!h&&(m=p),U(bD,m,y);var x,_;if("x"===u||"y"===u){var w="x"===u?0:1;x=Math.abs(p[w]-y[w]),_=Math.abs(p[w]-m[w])}else x=uw(p,y),_=uw(p,m);_D(MD,p,bD,-l*(1-(v=_/(_+x))))}yD(SD,SD,s),xD(SD,SD,r),yD(MD,MD,s),xD(MD,MD,r),t.bezierCurveTo(SD[0],SD[1],MD[0],MD[1],p[0],p[1]),_D(SD,p,bD,l*v)}else t.lineTo(p[0],p[1]);c=d,d+=a}return f}function Vu(t,e){var i=[1/0,1/0],n=[-1/0,-1/0];if(e)for(var o=0;on[0]&&(n[0]=a[0]),a[1]>n[1]&&(n[1]=a[1])}return{min:e?i:n,max:e?n:i}}function Gu(t,e){if(t.length===e.length){for(var i=0;ie[0]?1:-1;e[0]+=n*i,e[1]-=n*i}return e}function Hu(t,e,i){if(!i.valueDim)return[];for(var n=[],o=0,a=e.count();oa[1]&&a.reverse();var r=o.getExtent(),s=Math.PI/180;i&&(a[0]-=.5,a[1]+=.5);var l=new hM({shape:{cx:Vo(t.cx,1),cy:Vo(t.cy,1),r0:Vo(a[0],1),r:Vo(a[1],1),startAngle:-r[0]*s,endAngle:-r[1]*s,clockwise:o.inverse}});return e&&(l.shape.endAngle=-r[0]*s,Io(l,{shape:{endAngle:-r[1]*s}},n)),l}function Xu(t,e,i,n){return"polar"===t.type?Uu(t,e,i,n):Zu(t,e,i,n)}function ju(t,e,i){for(var n=e.getBaseAxis(),o="x"===n.dim||"radius"===n.dim?0:1,a=[],r=0;r=0;a--){var r=i[a].dimension,s=t.dimensions[r],l=t.getDimensionInfo(s);if("x"===(n=l&&l.coordDim)||"y"===n){o=i[a];break}}if(o){var u=e.getAxis(n),h=f(o.stops,function(t){return{coord:u.toGlobalCoord(u.dataToCoord(t.value)),color:t.color}}),c=h.length,p=o.outerColors.slice();c&&h[0].coord>h[c-1].coord&&(h.reverse(),p.reverse());var g=h[0].coord-10,m=h[c-1].coord+10,v=m-g;if(v<.001)return"transparent";d(h,function(t){t.offset=(t.coord-g)/v}),h.push({offset:c?h[c-1].offset:.5,color:p[1]||"transparent"}),h.unshift({offset:c?h[0].offset:.5,color:p[0]||"transparent"});var y=new TM(0,0,0,0,h,!0);return y[n]=g,y[n+"2"]=m,y}}}function qu(t,e,i){var n=t.get("showAllSymbol"),o="auto"===n;if(!n||o){var a=i.getAxesByScale("ordinal")[0];if(a&&(!o||!Ku(a,e))){var r=e.mapDimension(a.dim),s={};return d(a.getViewLabels(),function(t){s[t.tickValue]=1}),function(t){return!s.hasOwnProperty(e.get(r,t))}}}}function Ku(t,e){var i=t.getExtent(),n=Math.abs(i[1]-i[0])/t.scale.count();isNaN(n)&&(n=0);for(var o=e.count(),a=Math.max(1,Math.round(o/5)),r=0;rn)return!1;return!0}function $u(t){return this._axes[t]}function Ju(t){kD.call(this,t)}function Qu(t,e){return e.type||(e.data?"category":"value")}function th(t,e,i){return t.getCoordSysModel()===e}function eh(t,e,i){this._coordsMap={},this._coordsList=[],this._axesMap={},this._axesList=[],this._initCartesian(t,e,i),this.model=t}function ih(t,e,i,n){function o(t){return t.dim+"_"+t.index}i.getAxesOnZeroOf=function(){return a?[a]:[]};var a,r=t[e],s=i.model,l=s.get("axisLine.onZero"),u=s.get("axisLine.onZeroAxisIndex");if(l){if(null!=u)nh(r[u])&&(a=r[u]);else for(var h in r)if(r.hasOwnProperty(h)&&nh(r[h])&&!n[o(r[h])]){a=r[h];break}a&&(n[o(a)]=!0)}}function nh(t){return t&&"category"!==t.type&&"time"!==t.type&&Hl(t)}function oh(t,e){var i=t.getExtent(),n=i[0]+i[1];t.toGlobalCoord="x"===t.dim?function(t){return t+e}:function(t){return n-t+e},t.toLocalCoord="x"===t.dim?function(t){return t-e}:function(t){return n-t+e}}function ah(t,e){return f(GD,function(e){return t.getReferringComponents(e)[0]})}function rh(t){return"cartesian2d"===t.get("coordinateSystem")}function sh(t){var e={componentType:t.mainType,componentIndex:t.componentIndex};return e[t.mainType+"Index"]=t.componentIndex,e}function lh(t,e,i,n){var o,a,r=Uo(i-t.rotation),s=n[0]>n[1],l="start"===e&&!s||"start"!==e&&s;return Xo(r-FD/2)?(a=l?"bottom":"top",o="center"):Xo(r-1.5*FD)?(a=l?"top":"bottom",o="center"):(a="middle",o=r<1.5*FD&&r>FD/2?l?"left":"right":l?"right":"left"),{rotation:r,textAlign:o,textVerticalAlign:a}}function uh(t){var e=t.get("tooltip");return t.get("silent")||!(t.get("triggerEvent")||e&&e.show)}function hh(t,e,i){if(!ql(t.axis)){var n=t.get("axisLabel.showMinLabel"),o=t.get("axisLabel.showMaxLabel");e=e||[],i=i||[];var a=e[0],r=e[1],s=e[e.length-1],l=e[e.length-2],u=i[0],h=i[1],c=i[i.length-1],d=i[i.length-2];!1===n?(ch(a),ch(u)):dh(a,r)&&(n?(ch(r),ch(h)):(ch(a),ch(u))),!1===o?(ch(s),ch(c)):dh(l,s)&&(o?(ch(l),ch(d)):(ch(s),ch(c)))}}function ch(t){t&&(t.ignore=!0)}function dh(t,e,i){var n=t&&t.getBoundingRect().clone(),o=e&&e.getBoundingRect().clone();if(n&&o){var a=_t([]);return Mt(a,a,-t.rotation),n.applyTransform(bt([],a,t.getLocalTransform())),o.applyTransform(bt([],a,e.getLocalTransform())),n.intersect(o)}}function fh(t){return"middle"===t||"center"===t}function ph(t,e,i){var n=e.axis;if(e.get("axisTick.show")&&!n.scale.isBlank()){for(var o=e.getModel("axisTick"),a=o.getModel("lineStyle"),s=o.get("length"),l=n.getTicksCoords(),u=[],h=[],c=t._transform,d=[],f=0;f=0||t===e}function bh(t){var e=Sh(t);if(e){var i=e.axisPointerModel,n=e.axis.scale,o=i.option,a=i.get("status"),r=i.get("value");null!=r&&(r=n.parse(r));var s=Ih(i);null==a&&(o.status=s?"show":"hide");var l=n.getExtent().slice();l[0]>l[1]&&l.reverse(),(null==r||r>l[1])&&(r=l[1]),r0?"bottom":"top":o.width>0?"left":"right";l||Lh(t.style,d,n,u,a,i,p),co(t,d)}function Eh(t,e){var i=t.get(eC)||0;return Math.min(i,Math.abs(e.width),Math.abs(e.height))}function Rh(t,e,i){var n=t.getData(),o=[],a=n.getLayout("valueAxisHorizontal")?1:0;o[1-a]=n.getLayout("valueAxisStart");var r=new oC({shape:{points:n.getLayout("largePoints")},incremental:!!i,__startPoint:o,__valueIdx:a});e.add(r),zh(r,t,n)}function zh(t,e,i){var n=i.getVisual("borderColor")||i.getVisual("color"),o=e.getModel("itemStyle").getItemStyle(["color","borderColor"]);t.useStyle(o),t.style.fill=null,t.style.stroke=n,t.style.lineWidth=i.getLayout("barWidth")}function Bh(t,e,i,n){var o=e.getData(),a=this.dataIndex,r=o.getName(a),s=e.get("selectedOffset");n.dispatchAction({type:"pieToggleSelect",from:t,name:r,seriesId:e.id}),o.each(function(t){Vh(o.getItemGraphicEl(t),o.getItemLayout(t),e.isSelected(o.getName(t)),s,i)})}function Vh(t,e,i,n,o){var a=(e.startAngle+e.endAngle)/2,r=Math.cos(a),s=Math.sin(a),l=i?n:0,u=[r*l,s*l];o?t.animate().when(200,{position:u}).start("bounceOut"):t.attr("position",u)}function Gh(t,e){function i(){a.ignore=a.hoverIgnore,r.ignore=r.hoverIgnore}function n(){a.ignore=a.normalIgnore,r.ignore=r.normalIgnore}tb.call(this);var o=new hM({z2:2}),a=new gM,r=new rM;this.add(o),this.add(a),this.add(r),this.updateData(t,e,!0),this.on("emphasis",i).on("normal",n).on("mouseover",i).on("mouseout",n)}function Fh(t,e,i,n,o,a,r){function s(e,i){for(var n=e;n>=0&&(t[n].y-=i,!(n>0&&t[n].y>t[n-1].y+t[n-1].height));n--);}function l(t,e,i,n,o,a){for(var r=e?Number.MAX_VALUE:0,s=0,l=t.length;s=r&&(d=r-10),!e&&d<=r&&(d=r+10),t[s].x=i+d*a,r=d}}t.sort(function(t,e){return t.y-e.y});for(var u,h=0,c=t.length,d=[],f=[],p=0;pe&&a+1t[a].y+t[a].height)return void s(a,n/2);s(i-1,n/2)}(p,c,-u),h=t[p].y+t[p].height;r-h<0&&s(c-1,h-r);for(p=0;p=i?f.push(t[p]):d.push(t[p]);l(d,!1,e,i,n,o),l(f,!0,e,i,n,o)}function Wh(t,e,i,n,o,a){for(var r=[],s=[],l=0;l3?1.4:o>1?1.2:1.1;uc(this,"zoom","zoomOnMouseWheel",t,{scale:n>0?s:1/s,originX:a,originY:r})}if(i){var l=Math.abs(n);uc(this,"scrollMove","moveOnMouseWheel",t,{scrollDelta:(n>0?1:-1)*(l>3?.4:l>1?.15:.05),originX:a,originY:r})}}}function lc(t){ec(this._zr,"globalPan")||uc(this,"zoom",null,t,{scale:t.pinchScale>1?1.1:1/1.1,originX:t.pinchX,originY:t.pinchY})}function uc(t,e,i,n,o){t.pointerChecker&&t.pointerChecker(n,o.originX,o.originY)&&(mw(n.event),hc(t,e,i,n,o))}function hc(t,e,i,n,o){o.isAvailableBehavior=m(cc,null,i,n),t.trigger(e,o)}function cc(t,e,i){var n=i[t];return!t||n&&(!_(n)||e.event[n+"Key"])}function dc(t,e,i){var n=t.target,o=n.position;o[0]+=e,o[1]+=i,n.dirty()}function fc(t,e,i,n){var o=t.target,a=t.zoomLimit,r=o.position,s=o.scale,l=t.zoom=t.zoom||1;if(l*=e,a){var u=a.min||0,h=a.max||1/0;l=Math.max(Math.min(h,l),u)}var c=l/t.zoom;t.zoom=l,r[0]-=(i-r[0])*(c-1),r[1]-=(n-r[1])*(c-1),s[0]*=c,s[1]*=c,o.dirty()}function pc(t,e,i){var n=e.getComponentByElement(t.topTarget),o=n&&n.coordinateSystem;return n&&n!==i&&!zC[n.mainType]&&o&&o.model!==i}function gc(t,e){var i=t.getItemStyle(),n=t.get("areaColor");return null!=n&&(i.fill=n),i}function mc(t,e,i,n,o){i.off("click"),i.off("mousedown"),e.get("selectedMode")&&(i.on("mousedown",function(){t._mouseDownFlag=!0}),i.on("click",function(a){if(t._mouseDownFlag){t._mouseDownFlag=!1;for(var r=a.target;!r.__regions;)r=r.parent;if(r){var s={type:("geo"===e.mainType?"geo":"map")+"ToggleSelect",batch:f(r.__regions,function(t){return{name:t.name,from:o.uid}})};s[e.mainType+"Id"]=e.id,n.dispatchAction(s),vc(e,i)}}}))}function vc(t,e){e.eachChild(function(e){d(e.__regions,function(i){e.trigger(t.isSelected(i.name)?"emphasis":"normal")})})}function yc(t,e){var i=new tb;this.uid=Eo("ec_map_draw"),this._controller=new nc(t.getZr()),this._controllerHost={target:e?i:null},this.group=i,this._updateGroup=e,this._mouseDownFlag,this._mapName,this._initialized,i.add(this._regionsGroup=new tb),i.add(this._backgroundGroup=new tb)}function xc(t){var e=this[BC];e&&e.recordVersion===this[VC]&&_c(e,t)}function _c(t,e){var i=t.circle,n=t.labelModel,o=t.hoverLabelModel,a=t.emphasisText,r=t.normalText;e?(i.style.extendFrom(go({},o,{text:o.get("show")?a:null},{isRectText:!0,useInsideStyle:!1},!0)),i.__mapOriginalZ2=i.z2,i.z2+=NM):(go(i.style,n,{text:n.get("show")?r:null,textPosition:n.getShallow("position")||"bottom"},{isRectText:!0,useInsideStyle:!1}),i.dirty(!1),null!=i.__mapOriginalZ2&&(i.z2=i.__mapOriginalZ2,i.__mapOriginalZ2=null))}function wc(t,e,i){var n=t.getZoom(),o=t.getCenter(),a=e.zoom,r=t.dataToPoint(o);if(null!=e.dx&&null!=e.dy){r[0]-=e.dx,r[1]-=e.dy;o=t.pointToData(r);t.setCenter(o)}if(null!=a){if(i){var s=i.min||0,l=i.max||1/0;a=Math.max(Math.min(n*a,l),s)/n}t.scale[0]*=a,t.scale[1]*=a;var u=t.position,h=(e.originX-u[0])*(a-1),c=(e.originY-u[1])*(a-1);u[0]-=h,u[1]-=c,t.updateTransform();o=t.pointToData(r);t.setCenter(o),t.setZoom(a*n)}return{center:t.getCenter(),zoom:t.getZoom()}}function bc(){Tw.call(this)}function Sc(t){this.name=t,this.zoomLimit,Tw.call(this),this._roamTransformable=new bc,this._rawTransformable=new bc,this._center,this._zoom}function Mc(t,e,i,n){var o=i.seriesModel,a=o?o.coordinateSystem:null;return a===this?a[t](n):null}function Ic(t,e,i,n){Sc.call(this,t),this.map=e;var o=EC.load(e,i);this._nameCoordMap=o.nameCoordMap,this._regionsMap=o.regionsMap,this._invertLongitute=null==n||n,this.regions=o.regions,this._rect=o.boundingRect}function Tc(t,e,i,n){var o=i.geoModel,a=i.seriesModel,r=o?o.coordinateSystem:a?a.coordinateSystem||(a.getReferringComponents("geo")[0]||{}).coordinateSystem:null;return r===this?r[t](n):null}function Ac(t,e){var i=t.get("boundingCoords");if(null!=i){var n=i[0],o=i[1];isNaN(n[0])||isNaN(n[1])||isNaN(o[0])||isNaN(o[1])||this.setBoundingRect(n[0],n[1],o[0]-n[0],o[1]-n[1])}var a,r=this.getBoundingRect(),s=t.get("layoutCenter"),l=t.get("layoutSize"),u=e.getWidth(),h=e.getHeight(),c=r.width/r.height*this.aspectScale,d=!1;s&&l&&(s=[Bo(s[0],u),Bo(s[1],h)],l=Bo(l,Math.min(u,h)),isNaN(s[0])||isNaN(s[1])||isNaN(l)||(d=!0));if(d){var f={};c>1?(f.width=l,f.height=l/c):(f.height=l,f.width=l*c),f.y=s[1]-f.height/2,f.x=s[0]-f.width/2}else(a=t.getBoxLayoutParams()).aspect=c,f=ha(a,{width:u,height:h});this.setViewRect(f.x,f.y,f.width,f.height),this.setCenter(t.get("center")),this.setZoom(t.get("zoom"))}function Dc(t,e){d(e.get("geoCoord"),function(e,i){t.addGeoCoord(i,e)})}function Cc(t,e){var i={};return d(t,function(t){t.each(t.mapDimension("value"),function(e,n){var o="ec-"+t.getName(n);i[o]=i[o]||[],isNaN(e)||i[o].push(e)})}),t[0].map(t[0].mapDimension("value"),function(n,o){for(var a="ec-"+t[0].getName(o),r=0,s=1/0,l=-1/0,u=i[a].length,h=0;h=0;o--){var a=i[o];a.hierNode={defaultAncestor:null,ancestor:a,prelim:0,modifier:0,change:0,shift:0,i:o,thread:null},n.push(a)}}function Fc(t,e){var i=t.isExpand?t.children:[],n=t.parentNode.children,o=t.hierNode.i?n[t.hierNode.i-1]:null;if(i.length){Xc(t);var a=(i[0].hierNode.prelim+i[i.length-1].hierNode.prelim)/2;o?(t.hierNode.prelim=o.hierNode.prelim+e(t,o),t.hierNode.modifier=t.hierNode.prelim-a):t.hierNode.prelim=a}else o&&(t.hierNode.prelim=o.hierNode.prelim+e(t,o));t.parentNode.hierNode.defaultAncestor=jc(t,o,t.parentNode.hierNode.defaultAncestor||n[0],e)}function Wc(t){var e=t.hierNode.prelim+t.parentNode.hierNode.modifier;t.setLayout({x:e},!0),t.hierNode.modifier+=t.parentNode.hierNode.modifier}function Hc(t){return arguments.length?t:Jc}function Zc(t,e){var i={};return t-=Math.PI/2,i.x=e*Math.cos(t),i.y=e*Math.sin(t),i}function Uc(t,e){return ha(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function Xc(t){for(var e=t.children,i=e.length,n=0,o=0;--i>=0;){var a=e[i];a.hierNode.prelim+=n,a.hierNode.modifier+=n,o+=a.hierNode.change,n+=a.hierNode.shift+o}}function jc(t,e,i,n){if(e){for(var o=t,a=t,r=a.parentNode.children[0],s=e,l=o.hierNode.modifier,u=a.hierNode.modifier,h=r.hierNode.modifier,c=s.hierNode.modifier;s=Yc(s),a=qc(a),s&&a;){o=Yc(o),r=qc(r),o.hierNode.ancestor=t;var d=s.hierNode.prelim+c-a.hierNode.prelim-u+n(s,a);d>0&&($c(Kc(s,t,i),t,d),u+=d,l+=d),c+=s.hierNode.modifier,u+=a.hierNode.modifier,l+=o.hierNode.modifier,h+=r.hierNode.modifier}s&&!Yc(o)&&(o.hierNode.thread=s,o.hierNode.modifier+=c-l),a&&!qc(r)&&(r.hierNode.thread=a,r.hierNode.modifier+=u-h,i=t)}return i}function Yc(t){var e=t.children;return e.length&&t.isExpand?e[e.length-1]:t.hierNode.thread}function qc(t){var e=t.children;return e.length&&t.isExpand?e[0]:t.hierNode.thread}function Kc(t,e,i){return t.hierNode.ancestor.parentNode===e.parentNode?t.hierNode.ancestor:i}function $c(t,e,i){var n=i/(e.hierNode.i-t.hierNode.i);e.hierNode.change-=n,e.hierNode.shift+=i,e.hierNode.modifier+=i,e.hierNode.prelim+=i,t.hierNode.change+=n}function Jc(t,e){return t.parentNode===e.parentNode?1:2}function Qc(t,e){var i=t.getItemLayout(e);return i&&!isNaN(i.x)&&!isNaN(i.y)&&"none"!==t.getItemVisual(e,"symbol")}function td(t,e,i){return i.itemModel=e,i.itemStyle=e.getModel("itemStyle").getItemStyle(),i.hoverItemStyle=e.getModel("emphasis.itemStyle").getItemStyle(),i.lineStyle=e.getModel("lineStyle").getLineStyle(),i.labelModel=e.getModel("label"),i.hoverLabelModel=e.getModel("emphasis.label"),!1===t.isExpand&&0!==t.children.length?i.symbolInnerColor=i.itemStyle.fill:i.symbolInnerColor="#fff",i}function ed(t,e,i,n,o,a){var s=!i,l=t.tree.getNodeByDataIndex(e),a=td(l,l.getModel(),a),u=t.tree.root,h=l.parentNode===u?l:l.parentNode||l,c=t.getItemGraphicEl(h.dataIndex),d=h.getLayout(),f=c?{x:c.position[0],y:c.position[1],rawX:c.__radialOldRawX,rawY:c.__radialOldRawY}:d,p=l.getLayout();s?(i=new _u(t,e,a)).attr("position",[f.x,f.y]):i.updateData(t,e,a),i.__radialOldRawX=i.__radialRawX,i.__radialOldRawY=i.__radialRawY,i.__radialRawX=p.rawX,i.__radialRawY=p.rawY,n.add(i),t.setItemGraphicEl(e,i),Mo(i,{position:[p.x,p.y]},o);var g=i.getSymbolPath();if("radial"===a.layout){var m,v,y=u.children[0],x=y.getLayout(),_=y.children.length;if(p.x===x.x&&!0===l.isExpand){var w={};w.x=(y.children[0].getLayout().x+y.children[_-1].getLayout().x)/2,w.y=(y.children[0].getLayout().y+y.children[_-1].getLayout().y)/2,(m=Math.atan2(w.y-x.y,w.x-x.x))<0&&(m=2*Math.PI+m),(v=w.xx.x)||(m-=Math.PI);var b=v?"left":"right";g.setStyle({textPosition:b,textRotation:-m,textOrigin:"center",verticalAlign:"middle"})}if(l.parentNode&&l.parentNode!==u){var S=i.__edge;S||(S=i.__edge=new bM({shape:nd(a,f,f),style:r({opacity:0,strokeNoScale:!0},a.lineStyle)})),Mo(S,{shape:nd(a,d,p),style:{opacity:1}},o),n.add(S)}}function id(t,e,i,n,o,a){for(var r,s=t.tree.getNodeByDataIndex(e),l=t.tree.root,a=td(s,s.getModel(),a),u=s.parentNode===l?s:s.parentNode||s;null==(r=u.getLayout());)u=u.parentNode===l?u:u.parentNode||u;Mo(i,{position:[r.x+1,r.y+1]},o,function(){n.remove(i),t.setItemGraphicEl(e,null)}),i.fadeOut(null,{keepLabel:!0});var h=i.__edge;h&&Mo(h,{shape:nd(a,r,r),style:{opacity:0}},o,function(){n.remove(h)})}function nd(t,e,i){var n,o,a,r,s,l,u,h,c=t.orient;if("radial"===t.layout){s=e.rawX,u=e.rawY,l=i.rawX,h=i.rawY;var d=Zc(s,u),f=Zc(s,u+(h-u)*t.curvature),p=Zc(l,h+(u-h)*t.curvature),g=Zc(l,h);return{x1:d.x,y1:d.y,x2:g.x,y2:g.y,cpx1:f.x,cpy1:f.y,cpx2:p.x,cpy2:p.y}}return s=e.x,u=e.y,l=i.x,h=i.y,"LR"!==c&&"RL"!==c||(n=s+(l-s)*t.curvature,o=u,a=l+(s-l)*t.curvature,r=h),"TB"!==c&&"BT"!==c||(n=s,o=u+(h-u)*t.curvature,a=l,r=h+(u-h)*t.curvature),{x1:s,y1:u,x2:l,y2:h,cpx1:n,cpy1:o,cpx2:a,cpy2:r}}function od(t,e,i){for(var n,o=[t],a=[];n=o.pop();)if(a.push(n),n.isExpand){var r=n.children;if(r.length)for(var s=0;s=0;a--)n.push(o[a])}}function rd(t,e){var i=Uc(t,e);t.layoutInfo=i;var n=t.get("layout"),o=0,a=0,r=null;"radial"===n?(o=2*Math.PI,a=Math.min(i.height,i.width)/2,r=Hc(function(t,e){return(t.parentNode===e.parentNode?1:2)/t.depth})):(o=i.width,a=i.height,r=Hc());var s=t.getData().tree.root,l=s.children[0];if(l){Gc(s),od(l,Fc,r),s.hierNode.modifier=-l.hierNode.prelim,ad(l,Wc);var u=l,h=l,c=l;ad(l,function(t){var e=t.getLayout().x;eh.getLayout().x&&(h=t),t.depth>c.depth&&(c=t)});var d=u===h?1:r(u,h)/2,f=d-u.getLayout().x,p=0,g=0,m=0,v=0;if("radial"===n)p=o/(h.getLayout().x+d+f),g=a/(c.depth-1||1),ad(l,function(t){m=(t.getLayout().x+f)*p,v=(t.depth-1)*g;var e=Zc(m,v);t.setLayout({x:e.x,y:e.y,rawX:m,rawY:v},!0)});else{var y=t.getOrient();"RL"===y||"LR"===y?(g=a/(h.getLayout().x+d+f),p=o/(c.depth-1||1),ad(l,function(t){v=(t.getLayout().x+f)*g,m="LR"===y?(t.depth-1)*p:o-(t.depth-1)*p,t.setLayout({x:m,y:v},!0)})):"TB"!==y&&"BT"!==y||(p=o/(h.getLayout().x+d+f),g=a/(c.depth-1||1),ad(l,function(t){m=(t.getLayout().x+f)*p,v="TB"===y?(t.depth-1)*g:a-(t.depth-1)*g,t.setLayout({x:m,y:v},!0)}))}}}function sd(t,e,i){if(t&&l(e,t.type)>=0){var n=i.getData().tree.root,o=t.targetNode;if("string"==typeof o&&(o=n.getNodeById(o)),o&&n.contains(o))return{node:o};var a=t.targetNodeId;if(null!=a&&(o=n.getNodeById(a)))return{node:o}}}function ld(t){for(var e=[];t;)(t=t.parentNode)&&e.push(t);return e.reverse()}function ud(t,e){return l(ld(t),e)>=0}function hd(t,e){for(var i=[];t;){var n=t.dataIndex;i.push({name:t.name,dataIndex:n,value:e.getRawValue(n)}),t=t.parentNode}return i.reverse(),i}function cd(t){var e=0;d(t.children,function(t){cd(t);var i=t.value;y(i)&&(i=i[0]),e+=i});var i=t.value;y(i)&&(i=i[0]),(null==i||isNaN(i))&&(i=e),i<0&&(i=0),y(t.value)?t.value[0]=i:t.value=i}function dd(t,e){var i=e.get("color");if(i){var n;return d(t=t||[],function(t){var e=new Po(t),i=e.get("color");(e.get("itemStyle.color")||i&&"none"!==i)&&(n=!0)}),n||((t[0]||(t[0]={})).color=i.slice()),t}}function fd(t){this.group=new tb,t.add(this.group)}function pd(t,e,i,n,o,a){var r=[[o?t:t-XC,e],[t+i,e],[t+i,e+n],[o?t:t-XC,e+n]];return!a&&r.splice(2,0,[t+i+XC,e+n/2]),!o&&r.push([t,e+n/2]),r}function gd(t,e,i){t.eventData={componentType:"series",componentSubType:"treemap",componentIndex:e.componentIndex,seriesIndex:e.componentIndex,seriesName:e.name,seriesType:"treemap",selfType:"breadcrumb",nodeData:{dataIndex:i&&i.dataIndex,name:i&&i.name},treePathInfo:i&&hd(i,e)}}function md(){var t,e=[],i={};return{add:function(t,n,o,a,r){return _(a)&&(r=a,a=0),!i[t.id]&&(i[t.id]=1,e.push({el:t,target:n,time:o,delay:a,easing:r}),!0)},done:function(e){return t=e,this},start:function(){for(var n=e.length,o=0,a=e.length;o=0;a--)null==i[a]&&(delete n[e[a]],e.pop())}function wd(t,e){var i=t.visual,n=[];w(i)?lL(i,function(t){n.push(t)}):null!=i&&n.push(i);var o={color:1,symbol:1};e||1!==n.length||o.hasOwnProperty(t.type)||(n[1]=n[0]),Cd(t,n)}function bd(t){return{applyVisual:function(e,i,n){e=this.mapValueToVisual(e),n("color",t(i("color"),e))},_doMap:Ad([0,1])}}function Sd(t){var e=this.option.visual;return e[Math.round(zo(t,[0,1],[0,e.length-1],!0))]||{}}function Md(t){return function(e,i,n){n(t,this.mapValueToVisual(e))}}function Id(t){var e=this.option.visual;return e[this.option.loop&&t!==hL?t%e.length:t]}function Td(){return this.option.visual[0]}function Ad(t){return{linear:function(e){return zo(e,t,this.option.visual,!0)},category:Id,piecewise:function(e,i){var n=Dd.call(this,i);return null==n&&(n=zo(e,t,this.option.visual,!0)),n},fixed:Td}}function Dd(t){var e=this.option,i=e.pieceList;if(e.hasSpecialVisual){var n=i[cL.findPieceIndex(t,i)];if(n&&n.visual)return n.visual[this.type]}}function Cd(t,e){return t.visual=e,"color"===t.type&&(t.parsedVisual=f(e,function(t){return Gt(t)})),e}function Ld(t,e,i){return t?e<=i:e=o.length||t===o[t.depth])&&kd(t,Bd(r,h,t,e,g,a),i,n,o,a)})}else l=Nd(h),t.setVisual("color",l)}}function Pd(t,e,i,n){var o=a({},e);return d(["color","colorAlpha","colorSaturation"],function(a){var r=t.get(a,!0);null==r&&i&&(r=i[a]),null==r&&(r=e[a]),null==r&&(r=n.get(a)),null!=r&&(o[a]=r)}),o}function Nd(t){var e=Ed(t,"color");if(e){var i=Ed(t,"colorAlpha"),n=Ed(t,"colorSaturation");return n&&(e=jt(e,null,null,n)),i&&(e=Yt(e,i)),e}}function Od(t,e){return null!=e?jt(e,null,null,t):null}function Ed(t,e){var i=t[e];if(null!=i&&"none"!==i)return i}function Rd(t,e,i,n,o,a){if(a&&a.length){var r=zd(e,"color")||null!=o.color&&"none"!==o.color&&(zd(e,"colorAlpha")||zd(e,"colorSaturation"));if(r){var s=e.get("visualMin"),l=e.get("visualMax"),u=i.dataExtent.slice();null!=s&&su[1]&&(u[1]=l);var h=e.get("colorMappingBy"),c={type:r.name,dataExtent:u,visual:r.range};"color"!==c.type||"index"!==h&&"id"!==h?c.mappingMethod="linear":(c.mappingMethod="category",c.loop=!0);var d=new cL(c);return d.__drColorMappingBy=h,d}}}function zd(t,e){var i=t.get(e);return pL(i)&&i.length?{name:e,range:i}:null}function Bd(t,e,i,n,o,r){var s=a({},e);if(o){var l=o.type,u="color"===l&&o.__drColorMappingBy,h="index"===u?n:"id"===u?r.mapIdToIndex(i.getId()):i.getValue(t.get("visualDimension"));s[l]=o.mapValueToVisual(h)}return s}function Vd(t,e,i,n){var o,a;if(!t.isRemoved()){var r=t.getLayout();o=r.width,a=r.height;var s=(f=t.getModel()).get(wL),l=f.get(bL)/2,u=qd(f),h=Math.max(s,u),c=s-l,d=h-l,f=t.getModel();t.setLayout({borderWidth:s,upperHeight:h,upperLabelHeight:u},!0);var p=(o=vL(o-2*c,0))*(a=vL(a-c-d,0)),g=Gd(t,f,p,e,i,n);if(g.length){var m={x:c,y:d,width:o,height:a},v=yL(o,a),y=1/0,x=[];x.area=0;for(var _=0,w=g.length;_=0;l--){var u=o["asc"===n?r-l-1:l].getValue();u/i*es[1]&&(s[1]=e)})}else s=[NaN,NaN];return{sum:n,dataExtent:s}}function Zd(t,e,i){for(var n,o=0,a=1/0,r=0,s=t.length;ro&&(o=n));var l=t.area*t.area,u=e*e*i;return l?vL(u*o/l,l/(u*a)):1/0}function Ud(t,e,i,n,o){var a=e===i.width?0:1,r=1-a,s=["x","y"],l=["width","height"],u=i[s[a]],h=e?t.area/e:0;(o||h>i[l[r]])&&(h=i[l[r]]);for(var c=0,d=t.length;cXM&&(u=XM),a=s}u=0?n+=u:n-=u:p>=0?n-=u:n+=u}return n}function ff(t,e){return t.getVisual("opacity")||t.getModel().get(e)}function pf(t,e,i){var n=t.getGraphicEl(),o=ff(t,e);null!=i&&(null==o&&(o=1),o*=i),n.downplay&&n.downplay(),n.traverse(function(t){if("group"!==t.type){var e=t.lineLabelOriginalOpacity;null!=e&&null==i||(e=o),t.setStyle("opacity",e)}})}function gf(t,e){var i=ff(t,e),n=t.getGraphicEl();n.highlight&&n.highlight(),n.traverse(function(t){"group"!==t.type&&t.setStyle("opacity",i)})}function mf(t){return t instanceof Array||(t=[t,t]),t}function vf(t){var e=t.coordinateSystem;if(!e||"view"===e.type){var i=t.getGraph();i.eachNode(function(t){var e=t.getModel();t.setLayout([+e.get("x"),+e.get("y")])}),yf(i)}}function yf(t){t.eachEdge(function(t){var e=t.getModel().get("lineStyle.curveness")||0,i=F(t.node1.getLayout()),n=F(t.node2.getLayout()),o=[i,n];+e&&o.push([(i[0]+n[0])/2-(i[1]-n[1])*e,(i[1]+n[1])/2-(n[0]-i[0])*e]),t.setLayout(o)})}function xf(t){var e=t.coordinateSystem;if(!e||"view"===e.type){var i=e.getBoundingRect(),n=t.getData(),o=n.graph,a=0,r=n.getSum("value"),s=2*Math.PI/(r||n.count()),l=i.width/2+i.x,u=i.height/2+i.y,h=Math.min(i.width,i.height)/2;o.eachNode(function(t){var e=t.getValue("value");a+=s*(r?e:1)/2,t.setLayout([h*Math.cos(a)+l,h*Math.sin(a)+u]),a+=s*(r?e:1)/2}),n.setLayout({cx:l,cy:u}),o.eachEdge(function(t){var e,i=t.getModel().get("lineStyle.curveness")||0,n=F(t.node1.getLayout()),o=F(t.node2.getLayout()),a=(n[0]+o[0])/2,r=(n[1]+o[1])/2;+i&&(e=[l*(i*=3)+a*(1-i),u*i+r*(1-i)]),t.setLayout([n,o,e])})}}function _f(t,e,i){for(var n=i.rect,o=n.width,a=n.height,r=[n.x+o/2,n.y+a/2],s=null==i.gravity?.1:i.gravity,l=0;l0?-1:i<0?1:e?-1:1}}function kf(t,e){return Math.min(e[1],Math.max(e[0],t))}function Pf(t,e,i){this._axesMap=R(),this._axesLayout={},this.dimensions=t.dimensions,this._rect,this._model=t,this._init(t,e,i)}function Nf(t,e){return ik(nk(t,e[0]),e[1])}function Of(t,e){var i=e.layoutLength/(e.axisCount-1);return{position:i*t,axisNameAvailableWidth:i,axisLabelShow:!0}}function Ef(t,e){var i,n,o=e.layoutLength,a=e.axisExpandWidth,r=e.axisCount,s=e.axisCollapseWidth,l=e.winInnerIndices,u=s,h=!1;return tvk}function Kf(t){var e=t.length-1;return e<0&&(e=0),[t[0],t[e]]}function $f(t,e,i,n){var o=new tb;return o.add(new yM({name:"main",style:ep(i),silent:!0,draggable:!0,cursor:"move",drift:hk(t,e,o,"nswe"),ondragend:hk(Yf,e,{isEnd:!0})})),ck(n,function(i){o.add(new yM({name:i,style:{opacity:0},draggable:!0,silent:!0,invisible:!0,drift:hk(t,e,o,i),ondragend:hk(Yf,e,{isEnd:!0})}))}),o}function Jf(t,e,i,n){var o=n.brushStyle.lineWidth||0,a=pk(o,yk),r=i[0][0],s=i[1][0],l=r-o/2,u=s-o/2,h=i[0][1],c=i[1][1],d=h-a+o/2,f=c-a+o/2,p=h-r,g=c-s,m=p+o,v=g+o;tp(t,e,"main",r,s,p,g),n.transformable&&(tp(t,e,"w",l,u,a,v),tp(t,e,"e",d,u,a,v),tp(t,e,"n",l,u,m,a),tp(t,e,"s",l,f,m,a),tp(t,e,"nw",l,u,a,a),tp(t,e,"ne",d,u,a,a),tp(t,e,"sw",l,f,a,a),tp(t,e,"se",d,f,a,a))}function Qf(t,e){var i=e.__brushOption,n=i.transformable,o=e.childAt(0);o.useStyle(ep(i)),o.attr({silent:!n,cursor:n?"move":"default"}),ck(["w","e","n","s","se","sw","ne","nw"],function(i){var o=e.childOfName(i),a=op(t,i);o&&o.attr({silent:!n,invisible:!n,cursor:n?wk[a]+"-resize":null})})}function tp(t,e,i,n,o,a,r){var s=e.childOfName(i);s&&s.setShape(up(lp(t,e,[[n,o],[n+a,o+r]])))}function ep(t){return r({strokeNoScale:!0},t.brushStyle)}function ip(t,e,i,n){var o=[fk(t,i),fk(e,n)],a=[pk(t,i),pk(e,n)];return[[o[0],a[0]],[o[1],a[1]]]}function np(t){return To(t.group)}function op(t,e){if(e.length>1)return("e"===(n=[op(t,(e=e.split(""))[0]),op(t,e[1])])[0]||"w"===n[0])&&n.reverse(),n.join("");var i={left:"w",right:"e",top:"n",bottom:"s"},n=Do({w:"left",e:"right",n:"top",s:"bottom"}[e],np(t));return i[n]}function ap(t,e,i,n,o,a,r,s){var l=n.__brushOption,u=t(l.range),h=sp(i,a,r);ck(o.split(""),function(t){var e=_k[t];u[e[0]][e[1]]+=h[e[0]]}),l.range=e(ip(u[0][0],u[1][0],u[0][1],u[1][1])),Hf(i,n),Yf(i,{isEnd:!1})}function rp(t,e,i,n,o){var a=e.__brushOption.range,r=sp(t,i,n);ck(a,function(t){t[0]+=r[0],t[1]+=r[1]}),Hf(t,e),Yf(t,{isEnd:!1})}function sp(t,e,i){var n=t.group,o=n.transformCoordToLocal(e,i),a=n.transformCoordToLocal(0,0);return[o[0]-a[0],o[1]-a[1]]}function lp(t,e,n){var o=Xf(t,e);return o&&!0!==o?o.clipPath(n,t._transform):i(n)}function up(t){var e=fk(t[0][0],t[1][0]),i=fk(t[0][1],t[1][1]);return{x:e,y:i,width:pk(t[0][0],t[1][0])-e,height:pk(t[0][1],t[1][1])-i}}function hp(t,e,i){if(t._brushType){var n=t._zr,o=t._covers,a=Uf(t,e,i);if(!t._dragging)for(var r=0;r=i.length)return e;for(var o=-1,a=e.length,r=i[n++],s={},l={};++o=i.length)return t;var a=[],r=n[o++];return d(t,function(t,i){a.push({key:i,values:e(t,o)})}),r?a.sort(function(t,e){return r(t.key,e.key)}):a}var i=[],n=[];return{key:function(t){return i.push(t),this},sortKeys:function(t){return n[i.length-1]=t,this},entries:function(i){return e(t(i,0),0)}}}function Bp(t,e){return ha(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()})}function Vp(t,e,i,n,o,a,r,s){Fp(t,e,i,o,a,s),Zp(t,e,a,o,n,r,s),eg(t,s)}function Gp(t){d(t,function(t){var e=Qp(t.outEdges,Jp),i=Qp(t.inEdges,Jp),n=Math.max(e,i);t.setLayout({value:n},!0)})}function Fp(t,e,i,n,o,a){for(var r=[],s=[],l=[],u=[],h=0,c=0;c0;a--)Yp(s,l*=.99,r),jp(s,o,i,n,r),tg(s,l,r),jp(s,o,i,n,r)}function Up(t){return"vertical"===t?function(t){return t.getLayout().y}:function(t){return t.getLayout().x}}function Xp(t,e,i,n,o,a,r){var s=[];d(e,function(t){var e=t.length,i=0,l=0;d(t,function(t){i+=t.getLayout().value}),l="vertical"===r?(o-(e-1)*a)/i:(n-(e-1)*a)/i,s.push(l)}),s.sort(function(t,e){return t-e});var l=s[0];d(e,function(t){d(t,function(t,e){var i=t.getLayout().value*l;"vertical"===r?(t.setLayout({x:e},!0),t.setLayout({dx:i},!0)):(t.setLayout({y:e},!0),t.setLayout({dy:i},!0))})}),d(i,function(t){var e=+t.getValue()*l;t.setLayout({dy:e},!0)})}function jp(t,e,i,n,o){d(t,function(t){var a,r,s,l=0,u=t.length;if("vertical"===o){var h;for(t.sort(function(t,e){return t.getLayout().x-e.getLayout().x}),s=0;s0&&(h=a.getLayout().x+r,a.setLayout({x:h},!0)),l=a.getLayout().x+a.getLayout().dx+e;if((r=l-e-n)>0)for(h=a.getLayout().x-r,a.setLayout({x:h},!0),l=h,s=u-2;s>=0;--s)(r=(a=t[s]).getLayout().x+a.getLayout().dx+e-l)>0&&(h=a.getLayout().x-r,a.setLayout({x:h},!0)),l=a.getLayout().x}else{var c;for(t.sort(function(t,e){return t.getLayout().y-e.getLayout().y}),s=0;s0&&(c=a.getLayout().y+r,a.setLayout({y:c},!0)),l=a.getLayout().y+a.getLayout().dy+e;if((r=l-e-i)>0)for(c=a.getLayout().y-r,a.setLayout({y:c},!0),l=c,s=u-2;s>=0;--s)(r=(a=t[s]).getLayout().y+a.getLayout().dy+e-l)>0&&(c=a.getLayout().y-r,a.setLayout({y:c},!0)),l=a.getLayout().y}})}function Yp(t,e,i){d(t.slice().reverse(),function(t){d(t,function(t){if(t.outEdges.length){var n=Qp(t.outEdges,qp,i)/Qp(t.outEdges,Jp,i);if("vertical"===i){var o=t.getLayout().x+(n-$p(t,i))*e;t.setLayout({x:o},!0)}else{var a=t.getLayout().y+(n-$p(t,i))*e;t.setLayout({y:a},!0)}}})})}function qp(t,e){return $p(t.node2,e)*t.getValue()}function Kp(t,e){return $p(t.node1,e)*t.getValue()}function $p(t,e){return"vertical"===e?t.getLayout().x+t.getLayout().dx/2:t.getLayout().y+t.getLayout().dy/2}function Jp(t){return t.getValue()}function Qp(t,e,i){for(var n=0,o=t.length,a=-1;++a0?"P":"N",a=n.getVisual("borderColor"+o)||n.getVisual("color"+o),r=i.getModel(Fk).getItemStyle(Hk);e.useStyle(r),e.style.fill=null,e.style.stroke=a}function fg(t,e,i,n,o){return i>n?-1:i0?t.get(o,e-1)<=n?1:-1:1}function pg(t,e){var i,n=t.getBaseAxis(),o="category"===n.type?n.getBandWidth():(i=n.getExtent(),Math.abs(i[1]-i[0])/e.count()),a=Bo(A(t.get("barMaxWidth"),o),o),r=Bo(A(t.get("barMinWidth"),1),o),s=t.get("barWidth");return null!=s?Bo(s,o):Math.max(Math.min(o/2,a),r)}function gg(t){return y(t)||(t=[+t,+t]),t}function mg(t,e){t.eachChild(function(t){t.attr({z:e.z,zlevel:e.zlevel,style:{stroke:"stroke"===e.brushType?e.color:null,fill:"fill"===e.brushType?e.color:null}})})}function vg(t,e){tb.call(this);var i=new _u(t,e),n=new tb;this.add(i),this.add(n),n.beforeUpdate=function(){this.attr(i.getScale())},this.updateData(t,e)}function yg(t){var e=t.data;e&&e[0]&&e[0][0]&&e[0][0].coord&&(t.data=f(e,function(t){var e={coords:[t[0].coord,t[1].coord]};return t[0].name&&(e.fromName=t[0].name),t[1].name&&(e.toName=t[1].name),o([e,t[0],t[1]])}))}function xg(t,e,i){tb.call(this),this.add(this.createLine(t,e,i)),this._updateEffectSymbol(t,e)}function _g(t,e,i){tb.call(this),this._createPolyline(t,e,i)}function wg(t,e,i){xg.call(this,t,e,i),this._lastFrame=0,this._lastFramePercent=0}function bg(){this.group=new tb}function Sg(t){return t instanceof Array||(t=[t,t]),t}function Mg(){var t=iw();this.canvas=t,this.blurSize=30,this.pointSize=20,this.maxOpacity=1,this.minOpacity=0,this._gradientPixels={}}function Ig(t,e,i){var n=t[1]-t[0],o=(e=f(e,function(e){return{interval:[(e.interval[0]-t[0])/n,(e.interval[1]-t[0])/n]}})).length,a=0;return function(t){for(n=a;n=0;n--){var r=e[n].interval;if(r[0]<=t&&t<=r[1]){a=n;break}}return n>=0&&n=e[0]&&t<=e[1]}}function Ag(t){var e=t.dimensions;return"lng"===e[0]&&"lat"===e[1]}function Dg(t,e,i,n){var o=t.getItemLayout(e),a=i.get("symbolRepeat"),r=i.get("symbolClip"),s=i.get("symbolPosition")||"start",l=(i.get("symbolRotate")||0)*Math.PI/180||0,u=i.get("symbolPatternSize")||2,h=i.isAnimationEnabled(),c={dataIndex:e,layout:o,itemModel:i,symbolType:t.getItemVisual(e,"symbol")||"circle",color:t.getItemVisual(e,"color"),symbolClip:r,symbolRepeat:a,symbolRepeatDirection:i.get("symbolRepeatDirection"),symbolPatternSize:u,rotation:l,animationModel:h?i:null,hoverAnimation:h&&i.get("hoverAnimation"),z2:i.getShallow("z",!0)||0};Cg(i,a,o,n,c),kg(t,e,o,a,r,c.boundingLength,c.pxSign,u,n,c),Pg(i,c.symbolScale,l,n,c);var d=c.symbolSize,f=i.get("symbolOffset");return y(f)&&(f=[Bo(f[0],d[0]),Bo(f[1],d[1])]),Ng(i,d,o,a,r,f,s,c.valueLineWidth,c.boundingLength,c.repeatCutLength,n,c),c}function Cg(t,e,i,n,o){var a,r=n.valueDim,s=t.get("symbolBoundingData"),l=n.coordSys.getOtherAxis(n.coordSys.getBaseAxis()),u=l.toGlobalCoord(l.dataToCoord(0)),h=1-+(i[r.wh]<=0);if(y(s)){var c=[Lg(l,s[0])-u,Lg(l,s[1])-u];c[1]0?1:a<0?-1:0}function Lg(t,e){return t.toGlobalCoord(t.dataToCoord(t.scale.parse(e)))}function kg(t,e,i,n,o,a,r,s,l,u){var h=l.valueDim,c=l.categoryDim,d=Math.abs(i[c.wh]),f=t.getItemVisual(e,"symbolSize");y(f)?f=f.slice():(null==f&&(f="100%"),f=[f,f]),f[c.index]=Bo(f[c.index],d),f[h.index]=Bo(f[h.index],n?d:Math.abs(a)),u.symbolSize=f,(u.symbolScale=[f[0]/s,f[1]/s])[h.index]*=(l.isHorizontal?-1:1)*r}function Pg(t,e,i,n,o){var a=t.get(dP)||0;a&&(pP.attr({scale:e.slice(),rotation:i}),pP.updateTransform(),a/=pP.getLineScale(),a*=e[n.valueDim.index]),o.valueLineWidth=a}function Ng(t,e,i,n,o,r,s,l,u,h,c,d){var f=c.categoryDim,p=c.valueDim,g=d.pxSign,m=Math.max(e[p.index]+l,0),v=m;if(n){var y=Math.abs(u),x=T(t.get("symbolMargin"),"15%")+"",_=!1;x.lastIndexOf("!")===x.length-1&&(_=!0,x=x.slice(0,x.length-1)),x=Bo(x,e[p.index]);var w=Math.max(m+2*x,0),b=_?0:2*x,S=Jo(n),M=S?n:Kg((y+b)/w);w=m+2*(x=(y-M*m)/2/(_?M:M-1)),b=_?0:2*x,S||"fixed"===n||(M=h?Kg((Math.abs(h)+b)/w):0),v=M*w-b,d.repeatTimes=M,d.symbolMargin=x}var I=g*(v/2),A=d.pathPosition=[];A[f.index]=i[f.wh]/2,A[p.index]="start"===s?I:"end"===s?u-I:u/2,r&&(A[0]+=r[0],A[1]+=r[1]);var D=d.bundlePosition=[];D[f.index]=i[f.xy],D[p.index]=i[p.xy];var C=d.barRectShape=a({},i);C[p.wh]=g*Math.max(Math.abs(i[p.wh]),Math.abs(A[p.index]+I)),C[f.wh]=i[f.wh];var L=d.clipShape={};L[f.xy]=-i[f.xy],L[f.wh]=c.ecSize[f.wh],L[p.xy]=0,L[p.wh]=i[p.wh]}function Og(t){var e=t.symbolPatternSize,i=$l(t.symbolType,-e/2,-e/2,e,e,t.color);return i.attr({culling:!0}),"image"!==i.type&&i.setStyle({strokeNoScale:!0}),i}function Eg(t,e,i,n){function o(t){var e=l.slice(),n=i.pxSign,o=t;return("start"===i.symbolRepeatDirection?n>0:n<0)&&(o=h-1-t),e[u.index]=d*(o-h/2+.5)+l[u.index],{position:e,scale:i.symbolScale.slice(),rotation:i.rotation}}var a=t.__pictorialBundle,r=i.symbolSize,s=i.valueLineWidth,l=i.pathPosition,u=e.valueDim,h=i.repeatTimes||0,c=0,d=r[e.valueDim.index]+s+2*i.symbolMargin;for(jg(t,function(t){t.__pictorialAnimationIndex=c,t.__pictorialRepeatTimes=h,c0)],d=t.__pictorialBarRect;Lh(d.style,h,a,n,e.seriesModel,o,c),co(d,h)}function Kg(t){var e=Math.round(t);return Math.abs(t-e)<1e-4?e:Math.ceil(t)}function $g(t,e,i){this.dimension="single",this.dimensions=["single"],this._axis=null,this._rect,this._init(t,e,i),this.model=t}function Jg(t,e){e=e||{};var i=t.coordinateSystem,n=t.axis,o={},a=n.position,r=n.orient,s=i.getRect(),l=[s.x,s.x+s.width,s.y,s.y+s.height],u={horizontal:{top:l[2],bottom:l[3]},vertical:{left:l[0],right:l[1]}};o.position=["vertical"===r?u.vertical[a]:l[0],"horizontal"===r?u.horizontal[a]:l[3]];var h={horizontal:0,vertical:1};o.rotation=Math.PI/2*h[r];var c={top:-1,bottom:1,right:1,left:-1};o.labelDirection=o.tickDirection=o.nameDirection=c[a],t.get("axisTick.inside")&&(o.tickDirection=-o.tickDirection),T(e.labelInside,t.get("axisLabel.inside"))&&(o.labelDirection=-o.labelDirection);var d=e.rotate;return null==d&&(d=t.get("axisLabel.rotate")),o.labelRotation="top"===a?-d:d,o.z2=1,o}function Qg(t,e,i,n,o){var r=t.axis;if(!r.scale.isBlank()&&r.containData(e))if(t.involveSeries){var s=tm(e,t),l=s.payloadBatch,u=s.snapToValue;l[0]&&null==o.seriesIndex&&a(o,l[0]),!n&&t.snap&&r.containData(u)&&null!=u&&(e=u),i.showPointer(t,e,l,o),i.showTooltip(t,s,u)}else i.showPointer(t,e)}function tm(t,e){var i=e.axis,n=i.dim,o=t,a=[],r=Number.MAX_VALUE,s=-1;return wP(e.seriesModels,function(e,l){var u,h,c=e.getData().mapDimension(n,!0);if(e.getAxisTooltipData){var d=e.getAxisTooltipData(c,t,i);h=d.dataIndices,u=d.nestestValue}else{if(!(h=e.getData().indicesOfNearest(c[0],t,"category"===i.type?.5:null)).length)return;u=e.getData().get(c[0],h[0])}if(null!=u&&isFinite(u)){var f=t-u,p=Math.abs(f);p<=r&&((p=0&&s<0)&&(r=p,s=f,o=u,a.length=0),wP(h,function(t){a.push({seriesIndex:e.seriesIndex,dataIndexInside:t,dataIndex:e.getData().getRawIndex(t)})}))}}),{payloadBatch:a,snapToValue:o}}function em(t,e,i,n){t[e.key]={value:i,payloadBatch:n}}function im(t,e,i,n){var o=i.payloadBatch,a=e.axis,r=a.model,s=e.axisPointerModel;if(e.triggerTooltip&&o.length){var l=e.coordSys.model,u=Th(l),h=t.map[u];h||(h=t.map[u]={coordSysId:l.id,coordSysIndex:l.componentIndex,coordSysType:l.type,coordSysMainType:l.mainType,dataByAxis:[]},t.list.push(h)),h.dataByAxis.push({axisDim:a.dim,axisIndex:r.componentIndex,axisType:r.type,axisId:r.id,value:n,valueLabelOpt:{precision:s.get("label.precision"),formatter:s.get("label.formatter")},seriesDataIndices:o.slice()})}}function nm(t,e,i){var n=i.axesInfo=[];wP(e,function(e,i){var o=e.axisPointerModel.option,a=t[i];a?(!e.useHandle&&(o.status="show"),o.value=a.value,o.seriesDataIndices=(a.payloadBatch||[]).slice()):!e.useHandle&&(o.status="hide"),"show"===o.status&&n.push({axisDim:e.axis.dim,axisIndex:e.axis.model.componentIndex,value:o.value})})}function om(t,e,i,n){if(!lm(e)&&t.list.length){var o=((t.list[0].dataByAxis[0]||{}).seriesDataIndices||[])[0]||{};n({type:"showTip",escapeConnect:!0,x:e[0],y:e[1],tooltipOption:i.tooltipOption,position:i.position,dataIndexInside:o.dataIndexInside,dataIndex:o.dataIndex,seriesIndex:o.seriesIndex,dataByCoordSys:t.list})}else n({type:"hideTip"})}function am(t,e,i){var n=i.getZr(),o=SP(n).axisPointerLastHighlights||{},a=SP(n).axisPointerLastHighlights={};wP(t,function(t,e){var i=t.axisPointerModel.option;"show"===i.status&&wP(i.seriesDataIndices,function(t){var e=t.seriesIndex+" | "+t.dataIndex;a[e]=t})});var r=[],s=[];d(o,function(t,e){!a[e]&&s.push(t)}),d(a,function(t,e){!o[e]&&r.push(t)}),s.length&&i.dispatchAction({type:"downplay",escapeConnect:!0,batch:s}),r.length&&i.dispatchAction({type:"highlight",escapeConnect:!0,batch:r})}function rm(t,e){for(var i=0;i<(t||[]).length;i++){var n=t[i];if(e.axis.dim===n.axisDim&&e.axis.model.componentIndex===n.axisIndex)return n}}function sm(t){var e=t.axis.model,i={},n=i.axisDim=t.axis.dim;return i.axisIndex=i[n+"AxisIndex"]=e.componentIndex,i.axisName=i[n+"AxisName"]=e.name,i.axisId=i[n+"AxisId"]=e.id,i}function lm(t){return!t||null==t[0]||isNaN(t[0])||null==t[1]||isNaN(t[1])}function um(t,e,i){if(!U_.node){var n=e.getZr();MP(n).records||(MP(n).records={}),hm(n,e),(MP(n).records[t]||(MP(n).records[t]={})).handler=i}}function hm(t,e){function i(i,n){t.on(i,function(i){var o=pm(e);IP(MP(t).records,function(t){t&&n(t,i,o.dispatchAction)}),cm(o.pendings,e)})}MP(t).initialized||(MP(t).initialized=!0,i("click",v(fm,"click")),i("mousemove",v(fm,"mousemove")),i("globalout",dm))}function cm(t,e){var i,n=t.showTip.length,o=t.hideTip.length;n?i=t.showTip[n-1]:o&&(i=t.hideTip[o-1]),i&&(i.dispatchAction=null,e.dispatchAction(i))}function dm(t,e,i){t.handler("leave",null,i)}function fm(t,e,i,n){e.handler(t,i,n)}function pm(t){var e={showTip:[],hideTip:[]},i=function(n){var o=e[n.type];o?o.push(n):(n.dispatchAction=i,t.dispatchAction(n))};return{dispatchAction:i,pendings:e}}function gm(t,e){if(!U_.node){var i=e.getZr();(MP(i).records||{})[t]&&(MP(i).records[t]=null)}}function mm(){}function vm(t,e,i,n){ym(AP(i).lastProp,n)||(AP(i).lastProp=n,e?Mo(i,n,t):(i.stopAnimation(),i.attr(n)))}function ym(t,e){if(w(t)&&w(e)){var i=!0;return d(e,function(e,n){i=i&&ym(t[n],e)}),!!i}return t===e}function xm(t,e){t[e.get("label.show")?"show":"hide"]()}function _m(t){return{position:t.position.slice(),rotation:t.rotation||0}}function wm(t,e,i){var n=e.get("z"),o=e.get("zlevel");t&&t.traverse(function(t){"group"!==t.type&&(null!=n&&(t.z=n),null!=o&&(t.zlevel=o),t.silent=i)})}function bm(t){var e,i=t.get("type"),n=t.getModel(i+"Style");return"line"===i?(e=n.getLineStyle()).fill=null:"shadow"===i&&((e=n.getAreaStyle()).stroke=null),e}function Sm(t,e,i,n,o){var a=Im(i.get("value"),e.axis,e.ecModel,i.get("seriesDataIndices"),{precision:i.get("label.precision"),formatter:i.get("label.formatter")}),r=i.getModel("label"),s=qM(r.get("padding")||0),l=r.getFont(),u=ke(a,l),h=o.position,c=u.width+s[1]+s[3],d=u.height+s[0]+s[2],f=o.align;"right"===f&&(h[0]-=c),"center"===f&&(h[0]-=c/2);var p=o.verticalAlign;"bottom"===p&&(h[1]-=d),"middle"===p&&(h[1]-=d/2),Mm(h,c,d,n);var g=r.get("backgroundColor");g&&"auto"!==g||(g=e.get("axisLine.lineStyle.color")),t.label={shape:{x:0,y:0,width:c,height:d,r:r.get("borderRadius")},position:h.slice(),style:{text:a,textFont:l,textFill:r.getTextColor(),textPosition:"inside",fill:g,stroke:r.get("borderColor")||"transparent",lineWidth:r.get("borderWidth")||0,shadowBlur:r.get("shadowBlur"),shadowColor:r.get("shadowColor"),shadowOffsetX:r.get("shadowOffsetX"),shadowOffsetY:r.get("shadowOffsetY")},z2:10}}function Mm(t,e,i,n){var o=n.getWidth(),a=n.getHeight();t[0]=Math.min(t[0]+e,o)-e,t[1]=Math.min(t[1]+i,a)-i,t[0]=Math.max(t[0],0),t[1]=Math.max(t[1],0)}function Im(t,e,i,n,o){t=e.scale.parse(t);var a=e.scale.getLabel(t,{precision:o.precision}),r=o.formatter;if(r){var s={value:Ul(e,t),seriesData:[]};d(n,function(t){var e=i.getSeriesByIndex(t.seriesIndex),n=t.dataIndexInside,o=e&&e.getDataParams(n);o&&s.seriesData.push(o)}),_(r)?a=r.replace("{value}",a):x(r)&&(a=r(s))}return a}function Tm(t,e,i){var n=xt();return Mt(n,n,i.rotation),St(n,n,i.position),Ao([t.dataToCoord(e),(i.labelOffset||0)+(i.labelDirection||1)*(i.labelMargin||0)],n)}function Am(t,e,i,n,o,a){var r=WD.innerTextLayout(i.rotation,0,i.labelDirection);i.labelMargin=o.get("label.margin"),Sm(e,n,o,a,{position:Tm(n.axis,t,i),align:r.textAlign,verticalAlign:r.textVerticalAlign})}function Dm(t,e,i){return i=i||0,{x1:t[i],y1:t[1-i],x2:e[i],y2:e[1-i]}}function Cm(t,e,i){return i=i||0,{x:t[i],y:t[1-i],width:e[i],height:e[1-i]}}function Lm(t,e,i,n,o,a){return{cx:t,cy:e,r0:i,r:n,startAngle:o,endAngle:a,clockwise:!0}}function km(t,e){var i={};return i[e.dim+"AxisIndex"]=e.index,t.getCartesian(i)}function Pm(t){return"x"===t.dim?0:1}function Nm(t){return t.isHorizontal()?0:1}function Om(t,e){var i=t.getRect();return[i[PP[e]],i[PP[e]]+i[NP[e]]]}function Em(t,e,i){var n=new yM({shape:{x:t.x-10,y:t.y-10,width:0,height:t.height+20}});return Io(n,{shape:{width:t.width+20,height:t.height+20}},e,i),n}function Rm(t,e,i){if(t.count())for(var n,o=e.coordinateSystem,a=e.getLayerSeries(),r=t.mapDimension("single"),s=t.mapDimension("value"),l=f(a,function(e){return f(e.indices,function(e){var i=o.dataToPoint(t.get(r,e));return i[1]=t.get(s,e),i})}),u=zm(l),h=u.y0,c=i/u.max,d=a.length,p=a[0].indices.length,g=0;ga&&(a=u),n.push(u)}for(var h=0;ha&&(a=d)}return r.y0=o,r.max=a,r}function Bm(t){var e=0;d(t.children,function(t){Bm(t);var i=t.value;y(i)&&(i=i[0]),e+=i});var i=t.value;y(i)&&(i=i[0]),(null==i||isNaN(i))&&(i=e),i<0&&(i=0),y(t.value)?t.value[0]=i:t.value=i}function Vm(t,e,i){function n(){r.ignore=r.hoverIgnore}function o(){r.ignore=r.normalIgnore}tb.call(this);var a=new hM({z2:BP});a.seriesIndex=e.seriesIndex;var r=new rM({z2:VP,silent:t.getModel("label").get("silent")});this.add(a),this.add(r),this.updateData(!0,t,"normal",e,i),this.on("emphasis",n).on("normal",o).on("mouseover",n).on("mouseout",o)}function Gm(t,e,i){var n=t.getVisual("color"),o=t.getVisual("visualMeta");o&&0!==o.length||(n=null);var a=t.getModel("itemStyle").get("color");if(a)return a;if(n)return n;if(0===t.depth)return i.option.color[0];var r=i.option.color.length;return a=i.option.color[Fm(t)%r]}function Fm(t){for(var e=t;e.depth>1;)e=e.parentNode;return l(t.getAncestors()[0].children,e)}function Wm(t,e,i){return i!==zP.NONE&&(i===zP.SELF?t===e:i===zP.ANCESTOR?t===e||t.isAncestorOf(e):t===e||t.isDescendantOf(e))}function Hm(t,e,i){e.getData().setItemVisual(t.dataIndex,"color",i)}function Zm(t,e){var i=t.children||[];t.children=Um(i,e),i.length&&d(t.children,function(t){Zm(t,e)})}function Um(t,e){if("function"==typeof e)return t.sort(e);var i="asc"===e;return t.sort(function(t,e){var n=(t.getValue()-e.getValue())*(i?1:-1);return 0===n?(t.dataIndex-e.dataIndex)*(i?-1:1):n})}function Xm(t,e){return e=e||[0,0],f(["x","y"],function(i,n){var o=this.getAxis(i),a=e[n],r=t[n]/2;return"category"===o.type?o.getBandWidth():Math.abs(o.dataToCoord(a-r)-o.dataToCoord(a+r))},this)}function jm(t,e){return e=e||[0,0],f([0,1],function(i){var n=e[i],o=t[i]/2,a=[],r=[];return a[i]=n-o,r[i]=n+o,a[1-i]=r[1-i]=e[1-i],Math.abs(this.dataToPoint(a)[i]-this.dataToPoint(r)[i])},this)}function Ym(t,e){var i=this.getAxis(),n=e instanceof Array?e[0]:e,o=(t instanceof Array?t[0]:t)/2;return"category"===i.type?i.getBandWidth():Math.abs(i.dataToCoord(n-o)-i.dataToCoord(n+o))}function qm(t,e){return f(["Radius","Angle"],function(i,n){var o=this["get"+i+"Axis"](),a=e[n],r=t[n]/2,s="dataTo"+i,l="category"===o.type?o.getBandWidth():Math.abs(o[s](a-r)-o[s](a+r));return"Angle"===i&&(l=l*Math.PI/180),l},this)}function Km(t){var e,i=t.type;if("path"===i){var n=t.shape,o=null!=n.width&&null!=n.height?{x:n.x||0,y:n.y||0,width:n.width,height:n.height}:null,a=lv(n);(e=Un(a,null,o,n.layout||"center")).__customPathData=a}else"image"===i?(e=new fi({})).__customImagePath=t.style.image:"text"===i?(e=new rM({})).__customText=t.style.text:e=new(0,zM[i.charAt(0).toUpperCase()+i.slice(1)]);return e.__customGraphicType=i,e.name=t.name,e}function $m(t,e,n,o,a,r,s){var l={},u=n.style||{};if(n.shape&&(l.shape=i(n.shape)),n.position&&(l.position=n.position.slice()),n.scale&&(l.scale=n.scale.slice()),n.origin&&(l.origin=n.origin.slice()),n.rotation&&(l.rotation=n.rotation),"image"===t.type&&n.style){h=l.style={};d(["x","y","width","height"],function(e){Jm(e,h,u,t.style,r)})}if("text"===t.type&&n.style){var h=l.style={};d(["x","y"],function(e){Jm(e,h,u,t.style,r)}),!u.hasOwnProperty("textFill")&&u.fill&&(u.textFill=u.fill),!u.hasOwnProperty("textStroke")&&u.stroke&&(u.textStroke=u.stroke)}if("group"!==t.type&&(t.useStyle(u),r)){t.style.opacity=0;var c=u.opacity;null==c&&(c=1),Io(t,{style:{opacity:c}},o,e)}r?t.attr(l):Mo(t,l,o,e),n.hasOwnProperty("z2")&&t.attr("z2",n.z2||0),n.hasOwnProperty("silent")&&t.attr("silent",n.silent),n.hasOwnProperty("invisible")&&t.attr("invisible",n.invisible),n.hasOwnProperty("ignore")&&t.attr("ignore",n.ignore),n.hasOwnProperty("info")&&t.attr("info",n.info);var f=n.styleEmphasis,p=!1===f;t.__cusHasEmphStl&&null==f||!t.__cusHasEmphStl&&p||(ao(t,f),t.__cusHasEmphStl=!p),s&&fo(t,!p)}function Jm(t,e,i,n,o){null==i[t]||o||(e[t]=i[t],i[t]=n[t])}function Qm(t,e,i,n){function o(t){null==t&&(t=h),v&&(c=e.getItemModel(t),d=c.getModel(XP),f=c.getModel(jP),p=e.getItemVisual(t,"color"),v=!1)}var s=t.get("renderItem"),l=t.coordinateSystem,u={};l&&(u=l.prepareCustoms?l.prepareCustoms():qP[l.type](l));var h,c,d,f,p,g=r({getWidth:n.getWidth,getHeight:n.getHeight,getZr:n.getZr,getDevicePixelRatio:n.getDevicePixelRatio,value:function(t,i){return null==i&&(i=h),e.get(e.getDimension(t||0),i)},style:function(i,n){null==n&&(n=h),o(n);var r=c.getModel(ZP).getItemStyle();null!=p&&(r.fill=p);var s=e.getItemVisual(n,"opacity");return null!=s&&(r.opacity=s),go(r,d,null,{autoColor:p,isRectText:!0}),r.text=d.getShallow("show")?A(t.getFormattedLabel(n,"normal"),xu(e,n)):null,i&&a(r,i),r},styleEmphasis:function(i,n){null==n&&(n=h),o(n);var r=c.getModel(UP).getItemStyle();return go(r,f,null,{isRectText:!0},!0),r.text=f.getShallow("show")?D(t.getFormattedLabel(n,"emphasis"),t.getFormattedLabel(n,"normal"),xu(e,n)):null,i&&a(r,i),r},visual:function(t,i){return null==i&&(i=h),e.getItemVisual(i,t)},barLayout:function(t){if(l.getBaseAxis)return Cl(r({axis:l.getBaseAxis()},t),n)},currentSeriesIndices:function(){return i.getCurrentSeriesIndices()},font:function(t){return bo(t,i)}},u.api||{}),m={context:{},seriesId:t.id,seriesName:t.name,seriesIndex:t.seriesIndex,coordSys:u.coordSys,dataInsideLength:e.count(),encode:tv(t.getData())},v=!0;return function(t,i){return h=t,v=!0,s&&s(r({dataIndexInside:t,dataIndex:e.getRawIndex(t),actionType:i?i.type:null},m),g)}}function tv(t){var e={};return d(t.dimensions,function(i,n){var o=t.getDimensionInfo(i);if(!o.isExtraCoord){var a=o.coordDim;(e[a]=e[a]||[])[o.coordDimIndex]=n}}),e}function ev(t,e,i,n,o,a){return(t=iv(t,e,i,n,o,a,!0))&&a.setItemGraphicEl(e,t),t}function iv(t,e,i,n,o,a,r){var s=!i,l=(i=i||{}).type,u=i.shape,h=i.style;if(t&&(s||null!=l&&l!==t.__customGraphicType||"path"===l&&uv(u)&&lv(u)!==t.__customPathData||"image"===l&&hv(h,"image")&&h.image!==t.__customImagePath||"text"===l&&hv(u,"text")&&h.text!==t.__customText)&&(o.remove(t),t=null),!s){var c=!t;return!t&&(t=Km(i)),$m(t,e,i,n,a,c,r),"group"===l&&nv(t,e,i,n,a),o.add(t),t}}function nv(t,e,i,n,o){var a=i.children,r=a?a.length:0,s=i.$mergeChildren,l="byName"===s||i.diffChildrenByName,u=!1===s;if(r||l||u)if(l)ov({oldChildren:t.children()||[],newChildren:a||[],dataIndex:e,animatableModel:n,group:t,data:o});else{u&&t.removeAll();for(var h=0;hn?t-=l+a:t+=a),null!=r&&(e+u+r>o?e-=u+r:e+=r),[t,e]}function Ov(t,e,i,n,o){var a=i.getOuterSize(),r=a.width,s=a.height;return t=Math.min(t+r,n)-r,e=Math.min(e+s,o)-s,t=Math.max(t,0),e=Math.max(e,0),[t,e]}function Ev(t,e,i){var n=i[0],o=i[1],a=0,r=0,s=e.width,l=e.height;switch(t){case"inside":a=e.x+s/2-n/2,r=e.y+l/2-o/2;break;case"top":a=e.x+s/2-n/2,r=e.y-o-5;break;case"bottom":a=e.x+s/2-n/2,r=e.y+l+5;break;case"left":a=e.x-n-5,r=e.y+l/2-o/2;break;case"right":a=e.x+s+5,r=e.y+l/2-o/2}return[a,r]}function Rv(t){return"center"===t||"middle"===t}function zv(t){return t.get("stack")||"__ec_stack_"+t.seriesIndex}function Bv(t){return t.dim}function Vv(t,e){var i={};d(t,function(t,e){var n=t.getData(),o=t.coordinateSystem.getBaseAxis(),a=o.getExtent(),r="category"===o.type?o.getBandWidth():Math.abs(a[1]-a[0])/n.count(),s=i[Bv(o)]||{bandWidth:r,remainedWidth:r,autoWidthCount:0,categoryGap:"20%",gap:"30%",stacks:{}},l=s.stacks;i[Bv(o)]=s;var u=zv(t);l[u]||s.autoWidthCount++,l[u]=l[u]||{width:0,maxWidth:0};var h=Bo(t.get("barWidth"),r),c=Bo(t.get("barMaxWidth"),r),d=t.get("barGap"),f=t.get("barCategoryGap");h&&!l[u].width&&(h=Math.min(s.remainedWidth,h),l[u].width=h,s.remainedWidth-=h),c&&(l[u].maxWidth=c),null!=d&&(s.gap=d),null!=f&&(s.categoryGap=f)});var n={};return d(i,function(t,e){n[e]={};var i=t.stacks,o=t.bandWidth,a=Bo(t.categoryGap,o),r=Bo(t.gap,1),s=t.remainedWidth,l=t.autoWidthCount,u=(s-a)/(l+(l-1)*r);u=Math.max(u,0),d(i,function(t,e){var i=t.maxWidth;i&&ie[0]&&(e=e.slice().reverse());var n=t.coordToPoint([e[0],i]),o=t.coordToPoint([e[1],i]);return{x1:n[0],y1:n[1],x2:o[0],y2:o[1]}}function jv(t){return t.getRadiusAxis().inverse?0:1}function Yv(t){var e=t[0],i=t[t.length-1];e&&i&&Math.abs(Math.abs(e.coord-i.coord)-360)<1e-4&&t.pop()}function qv(t,e,i){return{position:[t.cx,t.cy],rotation:i/180*Math.PI,labelDirection:-1,tickDirection:-1,nameDirection:1,labelRotate:e.getModel("axisLabel").get("rotate"),z2:1}}function Kv(t,e,i,n,o){var a=e.axis,r=a.dataToCoord(t),s=n.getAngleAxis().getExtent()[0];s=s/180*Math.PI;var l,u,h,c=n.getRadiusAxis().getExtent();if("radius"===a.dim){var d=xt();Mt(d,d,s),St(d,d,[n.cx,n.cy]),l=Ao([r,-o],d);var f=e.getModel("axisLabel").get("rotate")||0,p=WD.innerTextLayout(s,f*Math.PI/180,-1);u=p.textAlign,h=p.textVerticalAlign}else{var g=c[1];l=n.coordToPoint([g+o,r]);var m=n.cx,v=n.cy;u=Math.abs(l[0]-m)/g<.3?"center":l[0]>m?"left":"right",h=Math.abs(l[1]-v)/g<.3?"middle":l[1]>v?"top":"bottom"}return{position:l,align:u,verticalAlign:h}}function $v(t,e){e.update="updateView",Os(e,function(e,i){var n={};return i.eachComponent({mainType:"geo",query:e},function(i){i[t](e.name),d(i.coordinateSystem.regions,function(t){n[t.name]=i.isSelected(t.name)||!1})}),{selected:n,name:e.name}})}function Jv(t){var e={};d(t,function(t){e[t]=1}),t.length=0,d(e,function(e,i){t.push(i)})}function Qv(t){if(t)for(var e in t)if(t.hasOwnProperty(e))return!0}function ty(t,e,n){function o(){var t=function(){};return t.prototype.__hidden=t.prototype,new t}var a={};return IN(e,function(e){var r=a[e]=o();IN(t[e],function(t,o){if(cL.isValidType(o)){var a={type:o,visual:t};n&&n(a,e),r[o]=new cL(a),"opacity"===o&&((a=i(a)).type="colorAlpha",r.__hidden.__alphaForOpacity=new cL(a))}})}),a}function ey(t,e,n){var o;d(n,function(t){e.hasOwnProperty(t)&&Qv(e[t])&&(o=!0)}),o&&d(n,function(n){e.hasOwnProperty(n)&&Qv(e[n])?t[n]=i(e[n]):delete t[n]})}function iy(t,e,i,n,o,a){function r(t){return i.getItemVisual(h,t)}function s(t,e){i.setItemVisual(h,t,e)}function l(t,l){h=null==a?t:l;var c=i.getRawDataItem(h);if(!c||!1!==c.visualMap)for(var d=n.call(o,t),f=e[d],p=u[d],g=0,m=p.length;g1)return!1;var h=uy(i-t,o-t,n-e,a-e)/l;return!(h<0||h>1)}function ly(t){return t<=1e-6&&t>=-1e-6}function uy(t,e,i,n){return t*n-e*i}function hy(t,e,i){var n=this._targetInfoList=[],o={},a=dy(e,t);AN(NN,function(t,e){(!i||!i.include||DN(i.include,e)>=0)&&t(a,n,o)})}function cy(t){return t[0]>t[1]&&t.reverse(),t}function dy(t,e){return Vi(t,e,{includeMainTypes:kN})}function fy(t,e,i,n){var o=i.getAxis(["x","y"][t]),a=cy(f([0,1],function(t){return e?o.coordToData(o.toLocalCoord(n[t])):o.toGlobalCoord(o.dataToCoord(n[t]))})),r=[];return r[t]=a,r[1-t]=[NaN,NaN],{values:a,xyMinMax:r}}function py(t,e,i,n){return[e[0]-n[t]*i[0],e[1]-n[t]*i[1]]}function gy(t,e){var i=my(t),n=my(e),o=[i[0]/n[0],i[1]/n[1]];return isNaN(o[0])&&(o[0]=1),isNaN(o[1])&&(o[1]=1),o}function my(t){return t?[t[0][1]-t[0][0],t[1][1]-t[1][0]]:[NaN,NaN]}function vy(t,e,i,n,o){if(o){var a=t.getZr();a[GN]||(a[VN]||(a[VN]=yy),Pr(a,VN,i,e)(t,n))}}function yy(t,e){if(!t.isDisposed()){var i=t.getZr();i[GN]=!0,t.dispatchAction({type:"brushSelect",batch:e}),i[GN]=!1}}function xy(t,e,i,n){for(var o=0,a=e.length;o=0}function Ny(t,e,i){function n(t,e){return l(e.nodes,t)>=0}function o(t,n){var o=!1;return e(function(e){d(i(t,e)||[],function(t){n.records[e.name][t]&&(o=!0)})}),o}function a(t,n){n.nodes.push(t),e(function(e){d(i(t,e)||[],function(t){n.records[e.name][t]=!0})})}return function(i){var r={nodes:[],records:{}};if(e(function(t){r.records[t.name]={}}),!i)return r;a(i,r);var s;do{s=!1,t(function(t){!n(t,r)&&o(t,r)&&(a(t,r),s=!0)})}while(s);return r}}function Oy(t,e,i){var n=[1/0,-1/0];return JN(i,function(t){var i=t.getData();i&&JN(i.mapDimension(e,!0),function(t){var e=i.getApproximateExtent(t);e[0]n[1]&&(n[1]=e[1])})}),n[1]0?0:NaN);var r=i.getMax(!0);return null!=r&&"dataMax"!==r&&"function"!=typeof r?e[1]=r:o&&(e[1]=a>0?a-1:NaN),i.get("scale",!0)||(e[0]>0&&(e[0]=0),e[1]<0&&(e[1]=0)),e}function Ry(t,e){var i=t.getAxisModel(),n=t._percentWindow,o=t._valueWindow;if(n){var a=Ho(o,[0,500]);a=Math.min(a,20);var r=e||0===n[0]&&100===n[1];i.setRange(r?null:+o[0].toFixed(a),r?null:+o[1].toFixed(a))}}function zy(t){var e=t._minMaxSpan={},i=t._dataZoomModel;JN(["min","max"],function(n){e[n+"Span"]=i.get(n+"Span");var o=i.get(n+"ValueSpan");if(null!=o&&(e[n+"ValueSpan"]=o,null!=(o=t.getAxisModel().axis.scale.parse(o)))){var a=t._dataExtent;e[n+"Span"]=zo(a[0]+o,a,[0,100],!0)}})}function By(t){var e={};return eO(["start","end","startValue","endValue","throttle"],function(i){t.hasOwnProperty(i)&&(e[i]=t[i])}),e}function Vy(t,e){var i=t._rangePropMode,n=t.get("rangeMode");eO([["start","startValue"],["end","endValue"]],function(t,o){var a=null!=e[t[0]],r=null!=e[t[1]];a&&!r?i[o]="percent":!a&&r?i[o]="value":n?i[o]=n[o]:a&&(i[o]="percent")})}function Gy(t){return{x:"y",y:"x",radius:"angle",angle:"radius"}[t]}function Fy(t){return"vertical"===t?"ns-resize":"ew-resize"}function Wy(t,e){var i=Uy(t),n=e.dataZoomId,o=e.coordId;d(i,function(t,i){var a=t.dataZoomInfos;a[n]&&l(e.allCoordIds,o)<0&&(delete a[n],t.count--)}),jy(i);var a=i[o];a||((a=i[o]={coordId:o,dataZoomInfos:{},count:0}).controller=Xy(t,a),a.dispatchAction=v(Yy,t)),!a.dataZoomInfos[n]&&a.count++,a.dataZoomInfos[n]=e;var r=qy(a.dataZoomInfos);a.controller.enable(r.controlType,r.opt),a.controller.setPointerChecker(e.containsPoint),Pr(a,"dispatchAction",e.dataZoomModel.get("throttle",!0),"fixRate")}function Hy(t,e){var i=Uy(t);d(i,function(t){t.controller.dispose();var i=t.dataZoomInfos;i[e]&&(delete i[e],t.count--)}),jy(i)}function Zy(t){return t.type+"\0_"+t.id}function Uy(t){var e=t.getZr();return e[pO]||(e[pO]={})}function Xy(t,e){var i=new nc(t.getZr());return d(["pan","zoom","scrollMove"],function(t){i.on(t,function(i){var n=[];d(e.dataZoomInfos,function(o){if(i.isAvailableBehavior(o.dataZoomModel.option)){var a=(o.getRange||{})[t],r=a&&a(e.controller,i);!o.dataZoomModel.get("disabled",!0)&&r&&n.push({dataZoomId:o.dataZoomId,start:r[0],end:r[1]})}}),n.length&&e.dispatchAction(n)})}),i}function jy(t){d(t,function(e,i){e.count||(e.controller.dispose(),delete t[i])})}function Yy(t,e){t.dispatchAction({type:"dataZoom",batch:e})}function qy(t){var e,i={type_true:2,type_move:1,type_false:0,type_undefined:-1},n=!0;return d(t,function(t){var o=t.dataZoomModel,a=!o.get("disabled",!0)&&(!o.get("zoomLock",!0)||"move");i["type_"+a]>i["type_"+e]&&(e=a),n&=o.get("preventDefaultMouseMove",!0)}),{controlType:e,opt:{zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!0,preventDefaultMouseMove:!!n}}}function Ky(t){return function(e,i,n,o){var a=this._range,r=a.slice(),s=e.axisModels[0];if(s){var l=t(r,s,e,i,n,o);return tk(l,r,[0,100],"all"),this._range=r,a[0]!==r[0]||a[1]!==r[1]?r:void 0}}}function $y(t,e){return t&&t.hasOwnProperty&&t.hasOwnProperty(e)}function Jy(t,e,i,n){for(var o=e.targetVisuals[n],a=cL.prepareVisualTypes(o),r={color:t.getData().getVisual("color")},s=0,l=a.length;s=0&&(r[a]=+r[a].toFixed(h)),r}function fx(t,e){var n=t.getData(),o=t.coordinateSystem;if(e&&!cx(e)&&!y(e.coord)&&o){var a=o.dimensions,r=px(e,n,o,t);if((e=i(e)).type&&qO[e.type]&&r.baseAxis&&r.valueAxis){var s=jO(a,r.baseAxis.dim),l=jO(a,r.valueAxis.dim);e.coord=qO[e.type](n,r.baseDataDim,r.valueDataDim,s,l),e.value=e.coord[l]}else{for(var u=[null!=e.xAxis?e.xAxis:e.radiusAxis,null!=e.yAxis?e.yAxis:e.angleAxis],h=0;h<2;h++)qO[u[h]]&&(u[h]=yx(n,n.mapDimension(a[h]),u[h]));e.coord=u}}return e}function px(t,e,i,n){var o={};return null!=t.valueIndex||null!=t.valueDim?(o.valueDataDim=null!=t.valueIndex?e.getDimension(t.valueIndex):t.valueDim,o.valueAxis=i.getAxis(gx(n,o.valueDataDim)),o.baseAxis=i.getOtherAxis(o.valueAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim)):(o.baseAxis=n.getBaseAxis(),o.valueAxis=i.getOtherAxis(o.baseAxis),o.baseDataDim=e.mapDimension(o.baseAxis.dim),o.valueDataDim=e.mapDimension(o.valueAxis.dim)),o}function gx(t,e){var i=t.getData(),n=i.dimensions;e=i.getDimension(e);for(var o=0;o=0)return!0}function Yx(t){for(var e=t.split(/\n+/g),i=[],n=f(Xx(e.shift()).split(gE),function(t){return{name:t,data:[]}}),o=0;o=0&&!i[o][n];o--);if(o<0){var a=t.queryComponents({mainType:"dataZoom",subType:"select",id:n})[0];if(a){var r=a.getPercentRange();i[0][n]={dataZoomId:n,start:r[0],end:r[1]}}}}),i.push(e)}function t_(t){var e=n_(t),i=e[e.length-1];e.length>1&&e.pop();var n={};return mE(i,function(t,i){for(var o=e.length-1;o>=0;o--)if(t=e[o][i]){n[i]=t;break}}),n}function e_(t){t[vE]=null}function i_(t){return n_(t).length}function n_(t){var e=t[vE];return e||(e=t[vE]=[{}]),e}function o_(t,e,i){(this._brushController=new Rf(i.getZr())).on("brush",m(this._onBrush,this)).mount(),this._isZoomActive}function a_(t){var e={};return d(["xAxisIndex","yAxisIndex"],function(i){e[i]=t[i],null==e[i]&&(e[i]="all"),(!1===e[i]||"none"===e[i])&&(e[i]=[])}),e}function r_(t,e){t.setIconStatus("back",i_(e)>1?"emphasis":"normal")}function s_(t,e,i,n,o){var a=i._isZoomActive;n&&"takeGlobalCursor"===n.type&&(a="dataZoomSelect"===n.key&&n.dataZoomSelectActive),i._isZoomActive=a,t.setIconStatus("zoom",a?"emphasis":"normal");var r=new hy(a_(t.option),e,{include:["grid"]});i._brushController.setPanels(r.makePanelOpts(o,function(t){return t.xAxisDeclared&&!t.yAxisDeclared?"lineX":!t.xAxisDeclared&&t.yAxisDeclared?"lineY":"rect"})).enableBrush(!!a&&{brushType:"auto",brushStyle:{lineWidth:0,fill:"rgba(0,0,0,0.2)"}})}function l_(t){this.model=t}function u_(t){return ME(t)}function h_(){if(!AE&&DE){AE=!0;var t=DE.styleSheets;t.length<31?DE.createStyleSheet().addRule(".zrvml","behavior:url(#default#VML)"):t[0].addRule(".zrvml","behavior:url(#default#VML)")}}function c_(t){return parseInt(t,10)}function d_(t,e){h_(),this.root=t,this.storage=e;var i=document.createElement("div"),n=document.createElement("div");i.style.cssText="display:inline-block;overflow:hidden;position:relative;width:300px;height:150px;",n.style.cssText="position:absolute;left:0;top:0;",t.appendChild(i),this._vmlRoot=n,this._vmlViewport=i,this.resize();var o=e.delFromStorage,a=e.addToStorage;e.delFromStorage=function(t){o.call(e,t),t&&t.onRemove&&t.onRemove(n)},e.addToStorage=function(t){t.onAdd&&t.onAdd(n),a.call(e,t)},this._firstPaint=!0}function f_(t){return function(){Yw('In IE8.0 VML mode painter not support method "'+t+'"')}}function p_(t){return document.createElementNS(lR,t)}function g_(t){return dR(1e4*t)/1e4}function m_(t){return t-yR}function v_(t,e){var i=e?t.textFill:t.fill;return null!=i&&i!==cR}function y_(t,e){var i=e?t.textStroke:t.stroke;return null!=i&&i!==cR}function x_(t,e){e&&__(t,"transform","matrix("+hR.call(e,",")+")")}function __(t,e,i){(!i||"linear"!==i.type&&"radial"!==i.type)&&t.setAttribute(e,i)}function w_(t,e,i){t.setAttributeNS("http://www.w3.org/1999/xlink",e,i)}function b_(t,e,i,n){if(v_(e,i)){var o=i?e.textFill:e.fill;o="transparent"===o?cR:o,"none"!==t.getAttribute("clip-path")&&o===cR&&(o="rgba(0, 0, 0, 0.002)"),__(t,"fill",o),__(t,"fill-opacity",null!=e.fillOpacity?e.fillOpacity*e.opacity:e.opacity)}else __(t,"fill",cR);if(y_(e,i)){var a=i?e.textStroke:e.stroke;__(t,"stroke",a="transparent"===a?cR:a),__(t,"stroke-width",(i?e.textStrokeWidth:e.lineWidth)/(!i&&e.strokeNoScale?n.getLineScale():1)),__(t,"paint-order",i?"stroke":"fill"),__(t,"stroke-opacity",null!=e.strokeOpacity?e.strokeOpacity:e.opacity),e.lineDash?(__(t,"stroke-dasharray",e.lineDash.join(",")),__(t,"stroke-dashoffset",dR(e.lineDashOffset||0))):__(t,"stroke-dasharray",""),e.lineCap&&__(t,"stroke-linecap",e.lineCap),e.lineJoin&&__(t,"stroke-linejoin",e.lineJoin),e.miterLimit&&__(t,"stroke-miterlimit",e.miterLimit)}else __(t,"stroke",cR)}function S_(t){for(var e=[],i=t.data,n=t.len(),o=0;o=mR||!m_(g)&&(d>-gR&&d<0||d>gR)==!!p;var y=g_(s+u*pR(c)),x=g_(l+h*fR(c));m&&(d=p?mR-1e-4:1e-4-mR,v=!0,9===o&&e.push("M",y,x));var _=g_(s+u*pR(c+d)),w=g_(l+h*fR(c+d));e.push("A",g_(u),g_(h),dR(f*vR),+v,+p,_,w);break;case uR.Z:a="Z";break;case uR.R:var _=g_(i[o++]),w=g_(i[o++]),b=g_(i[o++]),S=g_(i[o++]);e.push("M",_,w,"L",_+b,w,"L",_+b,w+S,"L",_,w+S,"L",_,w)}a&&e.push(a);for(var M=0;M=11),domSupported:"undefined"!=typeof document}}(navigator.userAgent),X_={"[object Function]":1,"[object RegExp]":1,"[object Date]":1,"[object Error]":1,"[object CanvasGradient]":1,"[object CanvasPattern]":1,"[object Image]":1,"[object Canvas]":1},j_={"[object Int8Array]":1,"[object Uint8Array]":1,"[object Uint8ClampedArray]":1,"[object Int16Array]":1,"[object Uint16Array]":1,"[object Int32Array]":1,"[object Uint32Array]":1,"[object Float32Array]":1,"[object Float64Array]":1},Y_=Object.prototype.toString,q_=Array.prototype,K_=q_.forEach,$_=q_.filter,J_=q_.slice,Q_=q_.map,tw=q_.reduce,ew={},iw=function(){return ew.createCanvas()};ew.createCanvas=function(){return document.createElement("canvas")};var nw,ow="__ec_primitive__";E.prototype={constructor:E,get:function(t){return this.data.hasOwnProperty(t)?this.data[t]:null},set:function(t,e){return this.data[t]=e},each:function(t,e){void 0!==e&&(t=m(t,e));for(var i in this.data)this.data.hasOwnProperty(i)&&t(this.data[i],i)},removeKey:function(t){delete this.data[t]}};var aw=(Object.freeze||Object)({$override:e,clone:i,merge:n,mergeAll:o,extend:a,defaults:r,createCanvas:iw,getContext:s,indexOf:l,inherits:u,mixin:h,isArrayLike:c,each:d,map:f,reduce:p,filter:g,find:function(t,e,i){if(t&&e)for(var n=0,o=t.length;n3&&(n=dw.call(n,1));for(var a=e.length,r=0;r4&&(n=dw.call(n,1,n.length-1));for(var a=n[n.length-1],r=e.length,s=0;s1&&n&&n.length>1){var a=ft(n)/ft(o);!isFinite(a)&&(a=1),e.pinchScale=a;var r=pt(n);return e.pinchX=r[0],e.pinchY=r[1],{type:"pinch",target:t[0].target,event:e}}}}},xw="silent";vt.prototype.dispose=function(){};var _w=["click","dblclick","mousewheel","mouseout","mouseup","mousedown","mousemove","contextmenu"],ww=function(t,e,i,n){fw.call(this),this.storage=t,this.painter=e,this.painterRoot=n,i=i||new vt,this.proxy=null,this._hovered={},this._lastTouchMoment,this._lastX,this._lastY,this._gestureMgr,it.call(this),this.setHandlerProxy(i)};ww.prototype={constructor:ww,setHandlerProxy:function(t){this.proxy&&this.proxy.dispose(),t&&(d(_w,function(e){t.on&&t.on(e,this[e],this)},this),t.handler=this),this.proxy=t},mousemove:function(t){var e=t.zrX,i=t.zrY,n=this._hovered,o=n.target;o&&!o.__zr&&(o=(n=this.findHover(n.x,n.y)).target);var a=this._hovered=this.findHover(e,i),r=a.target,s=this.proxy;s.setCursor&&s.setCursor(r?r.cursor:"default"),o&&r!==o&&this.dispatchToElement(n,"mouseout",t),this.dispatchToElement(a,"mousemove",t),r&&r!==o&&this.dispatchToElement(a,"mouseover",t)},mouseout:function(t){this.dispatchToElement(this._hovered,"mouseout",t);var e,i=t.toElement||t.relatedTarget;do{i=i&&i.parentNode}while(i&&9!==i.nodeType&&!(e=i===this.painterRoot));!e&&this.trigger("globalout",{event:t})},resize:function(t){this._hovered={}},dispatch:function(t,e){var i=this[t];i&&i.call(this,e)},dispose:function(){this.proxy.dispose(),this.storage=this.proxy=this.painter=null},setCursorStyle:function(t){var e=this.proxy;e.setCursor&&e.setCursor(t)},dispatchToElement:function(t,e,i){var n=(t=t||{}).target;if(!n||!n.silent){for(var o="on"+e,a=gt(e,t,i);n&&(n[o]&&(a.cancelBubble=n[o].call(n,a)),n.trigger(e,a),n=n.parent,!a.cancelBubble););a.cancelBubble||(this.trigger(e,a),this.painter&&this.painter.eachOtherLayer(function(t){"function"==typeof t[o]&&t[o].call(t,a),t.trigger&&t.trigger(e,a)}))}},findHover:function(t,e,i){for(var n=this.storage.getDisplayList(),o={x:t,y:e},a=n.length-1;a>=0;a--){var r;if(n[a]!==i&&!n[a].ignore&&(r=yt(n[a],t,e))&&(!o.topTarget&&(o.topTarget=n[a]),r!==xw)){o.target=n[a];break}}return o},processGesture:function(t,e){this._gestureMgr||(this._gestureMgr=new vw);var i=this._gestureMgr;"start"===e&&i.clear();var n=i.recognize(t,this.findHover(t.zrX,t.zrY,null).target,this.proxy.dom);if("end"===e&&i.clear(),n){var o=n.type;t.gestureEvent=o,this.dispatchToElement({target:n.target},o,n.event)}}},d(["click","mousedown","mouseup","mousewheel","dblclick","contextmenu"],function(t){ww.prototype[t]=function(e){var i=this.findHover(e.zrX,e.zrY),n=i.target;if("mousedown"===t)this._downEl=n,this._downPoint=[e.zrX,e.zrY],this._upEl=n;else if("mouseup"===t)this._upEl=n;else if("click"===t){if(this._downEl!==this._upEl||!this._downPoint||uw(this._downPoint,[e.zrX,e.zrY])>4)return;this._downPoint=null}this.dispatchToElement(i,t,e)}}),h(ww,fw),h(ww,it);var bw="undefined"==typeof Float32Array?Array:Float32Array,Sw=(Object.freeze||Object)({create:xt,identity:_t,copy:wt,mul:bt,translate:St,rotate:Mt,scale:It,invert:Tt,clone:At}),Mw=_t,Iw=5e-5,Tw=function(t){(t=t||{}).position||(this.position=[0,0]),null==t.rotation&&(this.rotation=0),t.scale||(this.scale=[1,1]),this.origin=this.origin||null},Aw=Tw.prototype;Aw.transform=null,Aw.needLocalTransform=function(){return Dt(this.rotation)||Dt(this.position[0])||Dt(this.position[1])||Dt(this.scale[0]-1)||Dt(this.scale[1]-1)};var Dw=[];Aw.updateTransform=function(){var t=this.parent,e=t&&t.transform,i=this.needLocalTransform(),n=this.transform;if(i||e){n=n||xt(),i?this.getLocalTransform(n):Mw(n),e&&(i?bt(n,t.transform,n):wt(n,t.transform)),this.transform=n;var o=this.globalScaleRatio;if(null!=o&&1!==o){this.getGlobalScale(Dw);var a=Dw[0]<0?-1:1,r=Dw[1]<0?-1:1,s=((Dw[0]-a)*o+a)/Dw[0]||0,l=((Dw[1]-r)*o+r)/Dw[1]||0;n[0]*=s,n[1]*=s,n[2]*=l,n[3]*=l}this.invTransform=this.invTransform||xt(),Tt(this.invTransform,n)}else n&&Mw(n)},Aw.getLocalTransform=function(t){return Tw.getLocalTransform(this,t)},Aw.setTransform=function(t){var e=this.transform,i=t.dpr||1;e?t.setTransform(i*e[0],i*e[1],i*e[2],i*e[3],i*e[4],i*e[5]):t.setTransform(i,0,0,i,0,0)},Aw.restoreTransform=function(t){var e=t.dpr||1;t.setTransform(e,0,0,e,0,0)};var Cw=[],Lw=xt();Aw.setLocalTransform=function(t){if(t){var e=t[0]*t[0]+t[1]*t[1],i=t[2]*t[2]+t[3]*t[3],n=this.position,o=this.scale;Dt(e-1)&&(e=Math.sqrt(e)),Dt(i-1)&&(i=Math.sqrt(i)),t[0]<0&&(e=-e),t[3]<0&&(i=-i),n[0]=t[4],n[1]=t[5],o[0]=e,o[1]=i,this.rotation=Math.atan2(-t[1]/i,t[0]/e)}},Aw.decomposeTransform=function(){if(this.transform){var t=this.parent,e=this.transform;t&&t.transform&&(bt(Cw,t.invTransform,e),e=Cw);var i=this.origin;i&&(i[0]||i[1])&&(Lw[4]=i[0],Lw[5]=i[1],bt(Cw,e,Lw),Cw[4]-=i[0],Cw[5]-=i[1],e=Cw),this.setLocalTransform(e)}},Aw.getGlobalScale=function(t){var e=this.transform;return t=t||[],e?(t[0]=Math.sqrt(e[0]*e[0]+e[1]*e[1]),t[1]=Math.sqrt(e[2]*e[2]+e[3]*e[3]),e[0]<0&&(t[0]=-t[0]),e[3]<0&&(t[1]=-t[1]),t):(t[0]=1,t[1]=1,t)},Aw.transformCoordToLocal=function(t,e){var i=[t,e],n=this.invTransform;return n&&Q(i,i,n),i},Aw.transformCoordToGlobal=function(t,e){var i=[t,e],n=this.transform;return n&&Q(i,i,n),i},Tw.getLocalTransform=function(t,e){Mw(e=e||[]);var i=t.origin,n=t.scale||[1,1],o=t.rotation||0,a=t.position||[0,0];return i&&(e[4]-=i[0],e[5]-=i[1]),It(e,e,n),o&&Mt(e,e,o),i&&(e[4]+=i[0],e[5]+=i[1]),e[4]+=a[0],e[5]+=a[1],e};var kw={linear:function(t){return t},quadraticIn:function(t){return t*t},quadraticOut:function(t){return t*(2-t)},quadraticInOut:function(t){return(t*=2)<1?.5*t*t:-.5*(--t*(t-2)-1)},cubicIn:function(t){return t*t*t},cubicOut:function(t){return--t*t*t+1},cubicInOut:function(t){return(t*=2)<1?.5*t*t*t:.5*((t-=2)*t*t+2)},quarticIn:function(t){return t*t*t*t},quarticOut:function(t){return 1- --t*t*t*t},quarticInOut:function(t){return(t*=2)<1?.5*t*t*t*t:-.5*((t-=2)*t*t*t-2)},quinticIn:function(t){return t*t*t*t*t},quinticOut:function(t){return--t*t*t*t*t+1},quinticInOut:function(t){return(t*=2)<1?.5*t*t*t*t*t:.5*((t-=2)*t*t*t*t+2)},sinusoidalIn:function(t){return 1-Math.cos(t*Math.PI/2)},sinusoidalOut:function(t){return Math.sin(t*Math.PI/2)},sinusoidalInOut:function(t){return.5*(1-Math.cos(Math.PI*t))},exponentialIn:function(t){return 0===t?0:Math.pow(1024,t-1)},exponentialOut:function(t){return 1===t?1:1-Math.pow(2,-10*t)},exponentialInOut:function(t){return 0===t?0:1===t?1:(t*=2)<1?.5*Math.pow(1024,t-1):.5*(2-Math.pow(2,-10*(t-1)))},circularIn:function(t){return 1-Math.sqrt(1-t*t)},circularOut:function(t){return Math.sqrt(1- --t*t)},circularInOut:function(t){return(t*=2)<1?-.5*(Math.sqrt(1-t*t)-1):.5*(Math.sqrt(1-(t-=2)*t)+1)},elasticIn:function(t){var e,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,e=.1):e=.4*Math.asin(1/i)/(2*Math.PI),-i*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4))},elasticOut:function(t){var e,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,e=.1):e=.4*Math.asin(1/i)/(2*Math.PI),i*Math.pow(2,-10*t)*Math.sin((t-e)*(2*Math.PI)/.4)+1)},elasticInOut:function(t){var e,i=.1;return 0===t?0:1===t?1:(!i||i<1?(i=1,e=.1):e=.4*Math.asin(1/i)/(2*Math.PI),(t*=2)<1?i*Math.pow(2,10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*-.5:i*Math.pow(2,-10*(t-=1))*Math.sin((t-e)*(2*Math.PI)/.4)*.5+1)},backIn:function(t){var e=1.70158;return t*t*((e+1)*t-e)},backOut:function(t){var e=1.70158;return--t*t*((e+1)*t+e)+1},backInOut:function(t){var e=2.5949095;return(t*=2)<1?t*t*((e+1)*t-e)*.5:.5*((t-=2)*t*((e+1)*t+e)+2)},bounceIn:function(t){return 1-kw.bounceOut(1-t)},bounceOut:function(t){return t<1/2.75?7.5625*t*t:t<2/2.75?7.5625*(t-=1.5/2.75)*t+.75:t<2.5/2.75?7.5625*(t-=2.25/2.75)*t+.9375:7.5625*(t-=2.625/2.75)*t+.984375},bounceInOut:function(t){return t<.5?.5*kw.bounceIn(2*t):.5*kw.bounceOut(2*t-1)+.5}};Ct.prototype={constructor:Ct,step:function(t,e){if(this._initialized||(this._startTime=t+this._delay,this._initialized=!0),this._paused)this._pausedTime+=e;else{var i=(t-this._startTime-this._pausedTime)/this._life;if(!(i<0)){i=Math.min(i,1);var n=this.easing,o="string"==typeof n?kw[n]:n,a="function"==typeof o?o(i):i;return this.fire("frame",a),1===i?this.loop?(this.restart(t),"restart"):(this._needsRemove=!0,"destroy"):null}}},restart:function(t){var e=(t-this._startTime-this._pausedTime)%this._life;this._startTime=t-e+this.gap,this._pausedTime=0,this._needsRemove=!1},fire:function(t,e){this[t="on"+t]&&this[t](this._target,e)},pause:function(){this._paused=!0},resume:function(){this._paused=!1}};var Pw=function(){this.head=null,this.tail=null,this._len=0},Nw=Pw.prototype;Nw.insert=function(t){var e=new Ow(t);return this.insertEntry(e),e},Nw.insertEntry=function(t){this.head?(this.tail.next=t,t.prev=this.tail,t.next=null,this.tail=t):this.head=this.tail=t,this._len++},Nw.remove=function(t){var e=t.prev,i=t.next;e?e.next=i:this.head=i,i?i.prev=e:this.tail=e,t.next=t.prev=null,this._len--},Nw.len=function(){return this._len},Nw.clear=function(){this.head=this.tail=null,this._len=0};var Ow=function(t){this.value=t,this.next,this.prev},Ew=function(t){this._list=new Pw,this._map={},this._maxSize=t||10,this._lastRemovedEntry=null},Rw=Ew.prototype;Rw.put=function(t,e){var i=this._list,n=this._map,o=null;if(null==n[t]){var a=i.len(),r=this._lastRemovedEntry;if(a>=this._maxSize&&a>0){var s=i.head;i.remove(s),delete n[s.key],o=s.value,this._lastRemovedEntry=s}r?r.value=e:r=new Ow(e),r.key=t,i.insertEntry(r),n[t]=r}return o},Rw.get=function(t){var e=this._map[t],i=this._list;if(null!=e)return e!==i.tail&&(i.remove(e),i.insertEntry(e)),e.value},Rw.clear=function(){this._list.clear(),this._map={}};var zw={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]},Bw=new Ew(20),Vw=null,Gw=Ut,Fw=Xt,Ww=(Object.freeze||Object)({parse:Gt,lift:Ht,toHex:Zt,fastLerp:Ut,fastMapToColor:Gw,lerp:Xt,mapToColor:Fw,modifyHSL:jt,modifyAlpha:Yt,stringify:qt}),Hw=Array.prototype.slice,Zw=function(t,e,i,n){this._tracks={},this._target=t,this._loop=e||!1,this._getter=i||Kt,this._setter=n||$t,this._clipCount=0,this._delay=0,this._doneList=[],this._onframeList=[],this._clipList=[]};Zw.prototype={when:function(t,e){var i=this._tracks;for(var n in e)if(e.hasOwnProperty(n)){if(!i[n]){i[n]=[];var o=this._getter(this._target,n);if(null==o)continue;0!==t&&i[n].push({time:0,value:ae(o)})}i[n].push({time:t,value:e[n]})}return this},during:function(t){return this._onframeList.push(t),this},pause:function(){for(var t=0;t=i.x&&t<=i.x+i.width&&e>=i.y&&e<=i.y+i.height},clone:function(){return new de(this.x,this.y,this.width,this.height)},copy:function(t){this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height},plain:function(){return{x:this.x,y:this.y,width:this.width,height:this.height}}},de.create=function(t){return new de(t.x,t.y,t.width,t.height)};var tb=function(t){t=t||{},Kw.call(this,t);for(var e in t)t.hasOwnProperty(e)&&(this[e]=t[e]);this._children=[],this.__storage=null,this.__dirty=!0};tb.prototype={constructor:tb,isGroup:!0,type:"group",silent:!1,children:function(){return this._children.slice()},childAt:function(t){return this._children[t]},childOfName:function(t){for(var e=this._children,i=0;i=0&&(i.splice(n,0,t),this._doAdd(t))}return this},_doAdd:function(t){t.parent&&t.parent.remove(t),t.parent=this;var e=this.__storage,i=this.__zr;e&&e!==t.__storage&&(e.addToStorage(t),t instanceof tb&&t.addChildrenToStorage(e)),i&&i.refresh()},remove:function(t){var e=this.__zr,i=this.__storage,n=this._children,o=l(n,t);return o<0?this:(n.splice(o,1),t.parent=null,i&&(i.delFromStorage(t),t instanceof tb&&t.delChildrenFromStorage(i)),e&&e.refresh(),this)},removeAll:function(){var t,e,i=this._children,n=this.__storage;for(e=0;e=0&&(this.delFromStorage(t),this._roots.splice(o,1),t instanceof tb&&t.delChildrenFromStorage(this))}},addToStorage:function(t){return t&&(t.__storage=this,t.dirty(!1)),this},delFromStorage:function(t){return t&&(t.__storage=null),this},dispose:function(){this._renderList=this._roots=null},displayableSortFunc:we};var ob={shadowBlur:1,shadowOffsetX:1,shadowOffsetY:1,textShadowBlur:1,textShadowOffsetX:1,textShadowOffsetY:1,textBoxShadowBlur:1,textBoxShadowOffsetX:1,textBoxShadowOffsetY:1},ab=function(t,e,i){return ob.hasOwnProperty(e)?i*=t.dpr:i},rb={NONE:0,STYLE_BIND:1,PLAIN_TEXT:2},sb=9,lb=[["shadowBlur",0],["shadowOffsetX",0],["shadowOffsetY",0],["shadowColor","#000"],["lineCap","butt"],["lineJoin","miter"],["miterLimit",10]],ub=function(t){this.extendFrom(t,!1)};ub.prototype={constructor:ub,fill:"#000",stroke:null,opacity:1,fillOpacity:null,strokeOpacity:null,lineDash:null,lineDashOffset:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,lineWidth:1,strokeNoScale:!1,text:null,font:null,textFont:null,fontStyle:null,fontWeight:null,fontSize:null,fontFamily:null,textTag:null,textFill:"#000",textStroke:null,textWidth:null,textHeight:null,textStrokeWidth:0,textLineHeight:null,textPosition:"inside",textRect:null,textOffset:null,textAlign:null,textVerticalAlign:null,textDistance:5,textShadowColor:"transparent",textShadowBlur:0,textShadowOffsetX:0,textShadowOffsetY:0,textBoxShadowColor:"transparent",textBoxShadowBlur:0,textBoxShadowOffsetX:0,textBoxShadowOffsetY:0,transformText:!1,textRotation:0,textOrigin:null,textBackgroundColor:null,textBorderColor:null,textBorderWidth:0,textBorderRadius:0,textPadding:null,rich:null,truncate:null,blend:null,bind:function(t,e,i){var n=this,o=i&&i.style,a=!o||t.__attrCachedBy!==rb.STYLE_BIND;t.__attrCachedBy=rb.STYLE_BIND;for(var r=0;r0},extendFrom:function(t,e){if(t)for(var i in t)!t.hasOwnProperty(i)||!0!==e&&(!1===e?this.hasOwnProperty(i):null==t[i])||(this[i]=t[i])},set:function(t,e){"string"==typeof t?this[t]=e:this.extendFrom(t,!0)},clone:function(){var t=new this.constructor;return t.extendFrom(this,!0),t},getGradient:function(t,e,i){for(var n=("radial"===e.type?Se:be)(t,e,i),o=e.colorStops,a=0;a=0&&i.splice(n,1),t.__hoverMir=null},clearHover:function(t){for(var e=this._hoverElements,i=0;i15)break}s.__drawIndex=m,s.__drawIndex0&&t>n[0]){for(r=0;rt);r++);a=i[n[r]]}if(n.splice(r+1,0,t),i[t]=e,!e.virtual)if(a){var l=a.dom;l.nextSibling?s.insertBefore(e.dom,l.nextSibling):s.appendChild(e.dom)}else s.firstChild?s.insertBefore(e.dom,s.firstChild):s.appendChild(e.dom)}else Yw("Layer of zlevel "+t+" is not valid")},eachLayer:function(t,e){var i,n,o=this._zlevelList;for(n=0;n0?.01:0),this._needsManuallyCompositing),a.__builtin__||Yw("ZLevel "+s+" has been used by unkown layer "+a.id),a!==i&&(a.__used=!0,a.__startIndex!==o&&(a.__dirty=!0),a.__startIndex=o,a.incremental?a.__drawIndex=-1:a.__drawIndex=o,e(o),i=a),r.__dirty&&(a.__dirty=!0,a.incremental&&a.__drawIndex<0&&(a.__drawIndex=o))}e(o),this.eachBuiltinLayer(function(t,e){!t.__used&&t.getElementCount()>0&&(t.__dirty=!0,t.__startIndex=t.__endIndex=t.__drawIndex=0),t.__dirty&&t.__drawIndex<0&&(t.__drawIndex=t.__startIndex)})},clear:function(){return this.eachBuiltinLayer(this._clearLayer),this},_clearLayer:function(t){t.clear()},setBackgroundColor:function(t){this._backgroundColor=t},configLayer:function(t,e){if(e){var i=this._layerConfig;i[t]?n(i[t],e,!0):i[t]=e;for(var o=0;o=0&&this._clips.splice(e,1)},removeAnimator:function(t){for(var e=t.getClips(),i=0;i=0||n&&l(n,r)<0)){var s=e.getShallow(r);null!=s&&(o[t[a][0]]=s)}}return o}},tS=Qb([["lineWidth","width"],["stroke","color"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),eS={getLineStyle:function(t){var e=tS(this,t),i=this.getLineDash(e.lineWidth);return i&&(e.lineDash=i),e},getLineDash:function(t){null==t&&(t=1);var e=this.get("type"),i=Math.max(t,2),n=4*t;return"solid"===e||null==e?null:"dashed"===e?[n,n]:[i,i]}},iS=Qb([["fill","color"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["opacity"],["shadowColor"]]),nS={getAreaStyle:function(t,e){return iS(this,t,e)}},oS=Math.pow,aS=Math.sqrt,rS=1e-8,sS=1e-4,lS=aS(3),uS=1/3,hS=V(),cS=V(),dS=V(),fS=Math.min,pS=Math.max,gS=Math.sin,mS=Math.cos,vS=2*Math.PI,yS=V(),xS=V(),_S=V(),wS=[],bS=[],SS={M:1,L:2,C:3,Q:4,A:5,Z:6,R:7},MS=[],IS=[],TS=[],AS=[],DS=Math.min,CS=Math.max,LS=Math.cos,kS=Math.sin,PS=Math.sqrt,NS=Math.abs,OS="undefined"!=typeof Float32Array,ES=function(t){this._saveData=!t,this._saveData&&(this.data=[]),this._ctx=null};ES.prototype={constructor:ES,_xi:0,_yi:0,_x0:0,_y0:0,_ux:0,_uy:0,_len:0,_lineDash:null,_dashOffset:0,_dashIdx:0,_dashSum:0,setScale:function(t,e){this._ux=NS(1/Xw/t)||0,this._uy=NS(1/Xw/e)||0},getContext:function(){return this._ctx},beginPath:function(t){return this._ctx=t,t&&t.beginPath(),t&&(this.dpr=t.dpr),this._saveData&&(this._len=0),this._lineDash&&(this._lineDash=null,this._dashOffset=0),this},moveTo:function(t,e){return this.addData(SS.M,t,e),this._ctx&&this._ctx.moveTo(t,e),this._x0=t,this._y0=e,this._xi=t,this._yi=e,this},lineTo:function(t,e){var i=NS(t-this._xi)>this._ux||NS(e-this._yi)>this._uy||this._len<5;return this.addData(SS.L,t,e),this._ctx&&i&&(this._needsDash()?this._dashedLineTo(t,e):this._ctx.lineTo(t,e)),i&&(this._xi=t,this._yi=e),this},bezierCurveTo:function(t,e,i,n,o,a){return this.addData(SS.C,t,e,i,n,o,a),this._ctx&&(this._needsDash()?this._dashedBezierTo(t,e,i,n,o,a):this._ctx.bezierCurveTo(t,e,i,n,o,a)),this._xi=o,this._yi=a,this},quadraticCurveTo:function(t,e,i,n){return this.addData(SS.Q,t,e,i,n),this._ctx&&(this._needsDash()?this._dashedQuadraticTo(t,e,i,n):this._ctx.quadraticCurveTo(t,e,i,n)),this._xi=i,this._yi=n,this},arc:function(t,e,i,n,o,a){return this.addData(SS.A,t,e,i,i,n,o-n,0,a?0:1),this._ctx&&this._ctx.arc(t,e,i,n,o,a),this._xi=LS(o)*i+t,this._yi=kS(o)*i+e,this},arcTo:function(t,e,i,n,o){return this._ctx&&this._ctx.arcTo(t,e,i,n,o),this},rect:function(t,e,i,n){return this._ctx&&this._ctx.rect(t,e,i,n),this.addData(SS.R,t,e,i,n),this},closePath:function(){this.addData(SS.Z);var t=this._ctx,e=this._x0,i=this._y0;return t&&(this._needsDash()&&this._dashedLineTo(e,i),t.closePath()),this._xi=e,this._yi=i,this},fill:function(t){t&&t.fill(),this.toStatic()},stroke:function(t){t&&t.stroke(),this.toStatic()},setLineDash:function(t){if(t instanceof Array){this._lineDash=t,this._dashIdx=0;for(var e=0,i=0;ie.length&&(this._expandData(),e=this.data);for(var i=0;i0&&f<=t||h<0&&f>=t||0===h&&(c>0&&p<=e||c<0&&p>=e);)f+=h*(i=r[n=this._dashIdx]),p+=c*i,this._dashIdx=(n+1)%g,h>0&&fl||c>0&&pu||s[n%2?"moveTo":"lineTo"](h>=0?DS(f,t):CS(f,t),c>=0?DS(p,e):CS(p,e));h=f-t,c=p-e,this._dashOffset=-PS(h*h+c*c)},_dashedBezierTo:function(t,e,i,n,o,a){var r,s,l,u,h,c=this._dashSum,d=this._dashOffset,f=this._lineDash,p=this._ctx,g=this._xi,m=this._yi,v=Qi,y=0,x=this._dashIdx,_=f.length,w=0;for(d<0&&(d=c+d),d%=c,r=0;r<1;r+=.1)s=v(g,t,i,o,r+.1)-v(g,t,i,o,r),l=v(m,e,n,a,r+.1)-v(m,e,n,a,r),y+=PS(s*s+l*l);for(;x<_&&!((w+=f[x])>d);x++);for(r=(w-d)/y;r<=1;)u=v(g,t,i,o,r),h=v(m,e,n,a,r),x%2?p.moveTo(u,h):p.lineTo(u,h),r+=f[x]/y,x=(x+1)%_;x%2!=0&&p.lineTo(o,a),s=o-u,l=a-h,this._dashOffset=-PS(s*s+l*l)},_dashedQuadraticTo:function(t,e,i,n){var o=i,a=n;i=(i+2*t)/3,n=(n+2*e)/3,t=(this._xi+2*t)/3,e=(this._yi+2*e)/3,this._dashedBezierTo(t,e,i,n,o,a)},toStatic:function(){var t=this.data;t instanceof Array&&(t.length=this._len,OS&&(this.data=new Float32Array(t)))},getBoundingRect:function(){MS[0]=MS[1]=TS[0]=TS[1]=Number.MAX_VALUE,IS[0]=IS[1]=AS[0]=AS[1]=-Number.MAX_VALUE;for(var t=this.data,e=0,i=0,n=0,o=0,a=0;al||NS(r-o)>u||c===h-1)&&(t.lineTo(a,r),n=a,o=r);break;case SS.C:t.bezierCurveTo(s[c++],s[c++],s[c++],s[c++],s[c++],s[c++]),n=s[c-2],o=s[c-1];break;case SS.Q:t.quadraticCurveTo(s[c++],s[c++],s[c++],s[c++]),n=s[c-2],o=s[c-1];break;case SS.A:var f=s[c++],p=s[c++],g=s[c++],m=s[c++],v=s[c++],y=s[c++],x=s[c++],_=s[c++],w=g>m?g:m,b=g>m?1:g/m,S=g>m?m/g:1,M=v+y;Math.abs(g-m)>.001?(t.translate(f,p),t.rotate(x),t.scale(b,S),t.arc(0,0,w,v,M,1-_),t.scale(1/b,1/S),t.rotate(-x),t.translate(-f,-p)):t.arc(f,p,w,v,M,1-_),1===c&&(e=LS(v)*g+f,i=kS(v)*m+p),n=LS(M)*g+f,o=kS(M)*m+p;break;case SS.R:e=n=s[c],i=o=s[c+1],t.rect(s[c++],s[c++],s[c++],s[c++]);break;case SS.Z:t.closePath(),n=e,o=i}}}},ES.CMD=SS;var RS=2*Math.PI,zS=2*Math.PI,BS=ES.CMD,VS=2*Math.PI,GS=1e-4,FS=[-1,-1,-1],WS=[-1,-1],HS=fb.prototype.getCanvasPattern,ZS=Math.abs,US=new ES(!0);kn.prototype={constructor:kn,type:"path",__dirtyPath:!0,strokeContainThreshold:5,subPixelOptimize:!1,brush:function(t,e){var i=this.style,n=this.path||US,o=i.hasStroke(),a=i.hasFill(),r=i.fill,s=i.stroke,l=a&&!!r.colorStops,u=o&&!!s.colorStops,h=a&&!!r.image,c=o&&!!s.image;if(i.bind(t,this,e),this.setTransform(t),this.__dirty){var d;l&&(d=d||this.getBoundingRect(),this._fillGradient=i.getGradient(t,r,d)),u&&(d=d||this.getBoundingRect(),this._strokeGradient=i.getGradient(t,s,d))}l?t.fillStyle=this._fillGradient:h&&(t.fillStyle=HS.call(r,t)),u?t.strokeStyle=this._strokeGradient:c&&(t.strokeStyle=HS.call(s,t));var f=i.lineDash,p=i.lineDashOffset,g=!!t.setLineDash,m=this.getGlobalScale();if(n.setScale(m[0],m[1]),this.__dirtyPath||f&&!g&&o?(n.beginPath(t),f&&!g&&(n.setLineDash(f),n.setLineDashOffset(p)),this.buildPath(n,this.shape,!1),this.path&&(this.__dirtyPath=!1)):(t.beginPath(),this.path.rebuildPath(t)),a)if(null!=i.fillOpacity){v=t.globalAlpha;t.globalAlpha=i.fillOpacity*i.opacity,n.fill(t),t.globalAlpha=v}else n.fill(t);if(f&&g&&(t.setLineDash(f),t.lineDashOffset=p),o)if(null!=i.strokeOpacity){var v=t.globalAlpha;t.globalAlpha=i.strokeOpacity*i.opacity,n.stroke(t),t.globalAlpha=v}else n.stroke(t);f&&g&&t.setLineDash([]),null!=i.text&&(this.restoreTransform(t),this.drawRectText(t,this.getBoundingRect()))},buildPath:function(t,e,i){},createPathProxy:function(){this.path=new ES},getBoundingRect:function(){var t=this._rect,e=this.style,i=!t;if(i){var n=this.path;n||(n=this.path=new ES),this.__dirtyPath&&(n.beginPath(),this.buildPath(n,this.shape,!1)),t=n.getBoundingRect()}if(this._rect=t,e.hasStroke()){var o=this._rectWithStroke||(this._rectWithStroke=t.clone());if(this.__dirty||i){o.copy(t);var a=e.lineWidth,r=e.strokeNoScale?this.getLineScale():1;e.hasFill()||(a=Math.max(a,this.strokeContainThreshold||4)),r>1e-10&&(o.width+=a/r,o.height+=a/r,o.x-=a/r/2,o.y-=a/r/2)}return o}return t},contain:function(t,e){var i=this.transformCoordToLocal(t,e),n=this.getBoundingRect(),o=this.style;if(t=i[0],e=i[1],n.contain(t,e)){var a=this.path.data;if(o.hasStroke()){var r=o.lineWidth,s=o.strokeNoScale?this.getLineScale():1;if(s>1e-10&&(o.hasFill()||(r=Math.max(r,this.strokeContainThreshold)),Ln(a,r/s,t,e)))return!0}if(o.hasFill())return Cn(a,t,e)}return!1},dirty:function(t){null==t&&(t=!0),t&&(this.__dirtyPath=t,this._rect=null),this.__dirty=this.__dirtyText=!0,this.__zr&&this.__zr.refresh(),this.__clipTarget&&this.__clipTarget.dirty()},animateShape:function(t){return this.animate("shape",t)},attrKV:function(t,e){"shape"===t?(this.setShape(e),this.__dirtyPath=!0,this._rect=null):di.prototype.attrKV.call(this,t,e)},setShape:function(t,e){var i=this.shape;if(i){if(w(t))for(var n in t)t.hasOwnProperty(n)&&(i[n]=t[n]);else i[t]=e;this.dirty(!0)}return this},getLineScale:function(){var t=this.transform;return t&&ZS(t[0]-1)>1e-10&&ZS(t[3]-1)>1e-10?Math.sqrt(ZS(t[0]*t[3]-t[2]*t[1])):1}},kn.extend=function(t){var e=function(e){kn.call(this,e),t.style&&this.style.extendFrom(t.style,!1);var i=t.shape;if(i){this.shape=this.shape||{};var n=this.shape;for(var o in i)!n.hasOwnProperty(o)&&i.hasOwnProperty(o)&&(n[o]=i[o])}t.init&&t.init.call(this,e)};u(e,kn);for(var i in t)"style"!==i&&"shape"!==i&&(e.prototype[i]=t[i]);return e},u(kn,di);var XS=ES.CMD,jS=[[],[],[]],YS=Math.sqrt,qS=Math.atan2,KS=function(t,e){var i,n,o,a,r,s,l=t.data,u=XS.M,h=XS.C,c=XS.L,d=XS.R,f=XS.A,p=XS.Q;for(o=0,a=0;o=11?function(){var e,i=this.__clipPaths,n=this.style;if(i)for(var o=0;oi-2?i-1:c+1],u=t[c>i-3?i-1:c+2]);var p=d*d,g=d*p;n.push([zn(s[0],f[0],l[0],u[0],d,p,g),zn(s[1],f[1],l[1],u[1],d,p,g)])}return n},fM=function(t,e,i,n){var o,a,r,s,l=[],u=[],h=[],c=[];if(n){r=[1/0,1/0],s=[-1/0,-1/0];for(var d=0,f=t.length;d=i&&a>=o)return{x:i,y:o,width:n-i,height:a-o}},createIcon:ko,Group:tb,Image:fi,Text:rM,Circle:sM,Sector:hM,Ring:cM,Polygon:pM,Polyline:gM,Rect:yM,Line:_M,BezierCurve:bM,Arc:SM,IncrementalDisplayable:Hn,CompoundPath:MM,LinearGradient:TM,RadialGradient:AM,BoundingRect:de}),BM=["textStyle","color"],VM={getTextColor:function(t){var e=this.ecModel;return this.getShallow("color")||(!t&&e?e.get(BM):null)},getFont:function(){return bo({fontStyle:this.getShallow("fontStyle"),fontWeight:this.getShallow("fontWeight"),fontSize:this.getShallow("fontSize"),fontFamily:this.getShallow("fontFamily")},this.ecModel)},getTextRect:function(t){return ke(t,this.getFont(),this.getShallow("align"),this.getShallow("verticalAlign")||this.getShallow("baseline"),this.getShallow("padding"),this.getShallow("rich"),this.getShallow("truncateText"))}},GM=Qb([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"],["textPosition"],["textAlign"]]),FM={getItemStyle:function(t,e){var i=GM(this,t,e),n=this.getBorderLineDash();return n&&(i.lineDash=n),i},getBorderLineDash:function(){var t=this.get("borderType");return"solid"===t||null==t?null:"dashed"===t?[5,5]:[1,1]}},WM=h,HM=Bi();Po.prototype={constructor:Po,init:null,mergeOption:function(t){n(this.option,t,!0)},get:function(t,e){return null==t?this.option:No(this.option,this.parsePath(t),!e&&Oo(this,t))},getShallow:function(t,e){var i=this.option,n=null==i?i:i[t],o=!e&&Oo(this,t);return null==n&&o&&(n=o.getShallow(t)),n},getModel:function(t,e){var i,n=null==t?this.option:No(this.option,t=this.parsePath(t));return e=e||(i=Oo(this,t))&&i.getModel(t),new Po(n,e,this.ecModel)},isEmpty:function(){return null==this.option},restoreData:function(){},clone:function(){return new(0,this.constructor)(i(this.option))},setReadOnly:function(t){},parsePath:function(t){return"string"==typeof t&&(t=t.split(".")),t},customizeGetParent:function(t){HM(this).getParent=t},isAnimationEnabled:function(){if(!U_.node){if(null!=this.option.animation)return!!this.option.animation;if(this.parentModel)return this.parentModel.isAnimationEnabled()}}},Xi(Po),ji(Po),WM(Po,eS),WM(Po,nS),WM(Po,VM),WM(Po,FM);var ZM=0,UM=1e-4,XM=9007199254740991,jM=/^(?:(\d{4})(?:[-\/](\d{1,2})(?:[-\/](\d{1,2})(?:[T ](\d{1,2})(?::(\d\d)(?::(\d\d)(?:[.,](\d+))?)?)?(Z|[\+\-]\d\d:?\d\d)?)?)?)?)?$/,YM=(Object.freeze||Object)({linearMap:zo,parsePercent:Bo,round:Vo,asc:Go,getPrecision:Fo,getPrecisionSafe:Wo,getPixelPrecision:Ho,getPercentWithPrecision:Zo,MAX_SAFE_INTEGER:XM,remRadian:Uo,isRadianAroundZero:Xo,parseDate:jo,quantity:Yo,nice:Ko,quantile:function(t,e){var i=(t.length-1)*e+1,n=Math.floor(i),o=+t[n-1],a=i-n;return a?o+a*(t[n]-o):o},reformIntervals:$o,isNumeric:Jo}),qM=L,KM=/([&<>"'])/g,$M={"&":"&","<":"<",">":">",'"':""","'":"'"},JM=["a","b","c","d","e","f","g"],QM=function(t,e){return"{"+t+(null==e?"":e)+"}"},tI=ze,eI=ke,iI=(Object.freeze||Object)({addCommas:Qo,toCamelCase:ta,normalizeCssArray:qM,encodeHTML:ea,formatTpl:ia,formatTplSimple:na,getTooltipMarker:oa,formatTime:ra,capitalFirst:sa,truncateText:tI,getTextRect:eI}),nI=d,oI=["left","right","top","bottom","width","height"],aI=[["width","left","right"],["height","top","bottom"]],rI=la,sI=(v(la,"vertical"),v(la,"horizontal"),{getBoxLayoutParams:function(){return{left:this.get("left"),top:this.get("top"),right:this.get("right"),bottom:this.get("bottom"),width:this.get("width"),height:this.get("height")}}}),lI=Bi(),uI=Po.extend({type:"component",id:"",name:"",mainType:"",subType:"",componentIndex:0,defaultOption:null,ecModel:null,dependentModels:[],uid:null,layoutMode:null,$constructor:function(t,e,i,n){Po.call(this,t,e,i,n),this.uid=Eo("ec_cpt_model")},init:function(t,e,i,n){this.mergeDefaultAndTheme(t,i)},mergeDefaultAndTheme:function(t,e){var i=this.layoutMode,o=i?pa(t):{};n(t,e.getTheme().get(this.mainType)),n(t,this.getDefaultOption()),i&&fa(t,o,i)},mergeOption:function(t,e){n(this.option,t,!0);var i=this.layoutMode;i&&fa(this.option,t,i)},optionUpdated:function(t,e){},getDefaultOption:function(){var t=lI(this);if(!t.defaultOption){for(var e=[],i=this.constructor;i;){var o=i.prototype.defaultOption;o&&e.push(o),i=i.superClass}for(var a={},r=e.length-1;r>=0;r--)a=n(a,e[r],!0);t.defaultOption=a}return t.defaultOption},getReferringComponents:function(t){return this.ecModel.queryComponents({mainType:t,index:this.get(t+"Index",!0),id:this.get(t+"Id",!0)})}});Ki(uI,{registerWhenExtend:!0}),function(t){var e={};t.registerSubTypeDefaulter=function(t,i){t=Zi(t),e[t.main]=i},t.determineSubType=function(i,n){var o=n.type;if(!o){var a=Zi(i).main;t.hasSubTypes(i)&&e[a]&&(o=e[a](n))}return o}}(uI),function(t,e){function i(t){var i={},a=[];return d(t,function(r){var s=n(i,r),u=o(s.originalDeps=e(r),t);s.entryCount=u.length,0===s.entryCount&&a.push(r),d(u,function(t){l(s.predecessor,t)<0&&s.predecessor.push(t);var e=n(i,t);l(e.successor,t)<0&&e.successor.push(r)})}),{graph:i,noEntryList:a}}function n(t,e){return t[e]||(t[e]={predecessor:[],successor:[]}),t[e]}function o(t,e){var i=[];return d(t,function(t){l(e,t)>=0&&i.push(t)}),i}t.topologicalTravel=function(t,e,n,o){function a(t){s[t].entryCount--,0===s[t].entryCount&&l.push(t)}if(t.length){var r=i(e),s=r.graph,l=r.noEntryList,u={};for(d(t,function(t){u[t]=!0});l.length;){var h=l.pop(),c=s[h],f=!!u[h];f&&(n.call(o,h,c.originalDeps.slice()),delete u[h]),d(c.successor,f?function(t){u[t]=!0,a(t)}:a)}d(u,function(){throw new Error("Circle dependency may exists")})}}}(uI,function(t){var e=[];return d(uI.getClassesByMainType(t),function(t){e=e.concat(t.prototype.dependencies||[])}),e=f(e,function(t){return Zi(t).main}),"dataset"!==t&&l(e,"dataset")<=0&&e.unshift("dataset"),e}),h(uI,sI);var hI="";"undefined"!=typeof navigator&&(hI=navigator.platform||"");var cI={color:["#c23531","#2f4554","#61a0a8","#d48265","#91c7ae","#749f83","#ca8622","#bda29a","#6e7074","#546570","#c4ccd3"],gradientColor:["#f6efa6","#d88273","#bf444c"],textStyle:{fontFamily:hI.match(/^Win/)?"Microsoft YaHei":"sans-serif",fontSize:12,fontStyle:"normal",fontWeight:"normal"},blendMode:null,animation:"auto",animationDuration:1e3,animationDurationUpdate:300,animationEasing:"exponentialOut",animationEasingUpdate:"cubicOut",animationThreshold:2e3,progressiveThreshold:3e3,progressive:400,hoverLayerThreshold:3e3,useUTC:!1},dI=Bi(),fI={clearColorPalette:function(){dI(this).colorIdx=0,dI(this).colorNameMap={}},getColorFromPalette:function(t,e,i){var n=dI(e=e||this),o=n.colorIdx||0,a=n.colorNameMap=n.colorNameMap||{};if(a.hasOwnProperty(t))return a[t];var r=Di(this.get("color",!0)),s=this.get("colorLayer",!0),l=null!=i&&s?ma(s,i):r;if((l=l||r)&&l.length){var u=l[o];return t&&(a[t]=u),n.colorIdx=(o+1)%l.length,u}}},pI={cartesian2d:function(t,e,i,n){var o=t.getReferringComponents("xAxis")[0],a=t.getReferringComponents("yAxis")[0];e.coordSysDims=["x","y"],i.set("x",o),i.set("y",a),ya(o)&&(n.set("x",o),e.firstCategoryDimIndex=0),ya(a)&&(n.set("y",a),e.firstCategoryDimIndex=1)},singleAxis:function(t,e,i,n){var o=t.getReferringComponents("singleAxis")[0];e.coordSysDims=["single"],i.set("single",o),ya(o)&&(n.set("single",o),e.firstCategoryDimIndex=0)},polar:function(t,e,i,n){var o=t.getReferringComponents("polar")[0],a=o.findAxisModel("radiusAxis"),r=o.findAxisModel("angleAxis");e.coordSysDims=["radius","angle"],i.set("radius",a),i.set("angle",r),ya(a)&&(n.set("radius",a),e.firstCategoryDimIndex=0),ya(r)&&(n.set("angle",r),e.firstCategoryDimIndex=1)},geo:function(t,e,i,n){e.coordSysDims=["lng","lat"]},parallel:function(t,e,i,n){var o=t.ecModel,a=o.getComponent("parallel",t.get("parallelIndex")),r=e.coordSysDims=a.dimensions.slice();d(a.parallelAxisIndex,function(t,a){var s=o.getComponent("parallelAxis",t),l=r[a];i.set(l,s),ya(s)&&null==e.firstCategoryDimIndex&&(n.set(l,s),e.firstCategoryDimIndex=a)})}},gI="original",mI="arrayRows",vI="objectRows",yI="keyedColumns",xI="unknown",_I="typedArray",wI="column",bI="row";xa.seriesDataToSource=function(t){return new xa({data:t,sourceFormat:S(t)?_I:gI,fromDataset:!1})},ji(xa);var SI=Bi(),MI="\0_ec_inner",II=Po.extend({init:function(t,e,i,n){i=i||{},this.option=null,this._theme=new Po(i),this._optionManager=n},setOption:function(t,e){k(!(MI in t),"please use chart.getOption()"),this._optionManager.setOption(t,e),this.resetOption(null)},resetOption:function(t){var e=!1,i=this._optionManager;if(!t||"recreate"===t){var n=i.mountOption("recreate"===t);this.option&&"recreate"!==t?(this.restoreData(),this.mergeOption(n)):Oa.call(this,n),e=!0}if("timeline"!==t&&"media"!==t||this.restoreData(),!t||"recreate"===t||"timeline"===t){var o=i.getTimelineOption(this);o&&(this.mergeOption(o),e=!0)}if(!t||"recreate"===t||"media"===t){var a=i.getMediaOption(this,this._api);a.length&&d(a,function(t){this.mergeOption(t,e=!0)},this)}return e},mergeOption:function(t){var e=this.option,o=this._componentsMap,r=[];ba(this),d(t,function(t,o){null!=t&&(uI.hasClass(o)?o&&r.push(o):e[o]=null==e[o]?i(t):n(e[o],t,!0))}),uI.topologicalTravel(r,uI.getAllClassMainTypes(),function(i,n){var r=Di(t[i]),s=Pi(o.get(i),r);Ni(s),d(s,function(t,e){var n=t.option;w(n)&&(t.keyInfo.mainType=i,t.keyInfo.subType=Ra(i,n,t.exist))});var l=Ea(o,n);e[i]=[],o.set(i,[]),d(s,function(t,n){var r=t.exist,s=t.option;if(k(w(s)||r,"Empty component definition"),s){var u=uI.getClass(i,t.keyInfo.subType,!0);if(r&&r instanceof u)r.name=t.keyInfo.name,r.mergeOption(s,this),r.optionUpdated(s,!1);else{var h=a({dependentModels:l,componentIndex:n},t.keyInfo);a(r=new u(s,this,this,h),h),r.init(s,this,this,h),r.optionUpdated(null,!0)}}else r.mergeOption({},this),r.optionUpdated({},!1);o.get(i)[n]=r,e[i][n]=r.option},this),"series"===i&&za(this,o.get("series"))},this),this._seriesIndicesMap=R(this._seriesIndices=this._seriesIndices||[])},getOption:function(){var t=i(this.option);return d(t,function(e,i){if(uI.hasClass(i)){for(var n=(e=Di(e)).length-1;n>=0;n--)Ei(e[n])&&e.splice(n,1);t[i]=e}}),delete t[MI],t},getTheme:function(){return this._theme},getComponent:function(t,e){var i=this._componentsMap.get(t);if(i)return i[e||0]},queryComponents:function(t){var e=t.mainType;if(!e)return[];var i=t.index,n=t.id,o=t.name,a=this._componentsMap.get(e);if(!a||!a.length)return[];var r;if(null!=i)y(i)||(i=[i]),r=g(f(i,function(t){return a[t]}),function(t){return!!t});else if(null!=n){var s=y(n);r=g(a,function(t){return s&&l(n,t.id)>=0||!s&&t.id===n})}else if(null!=o){var u=y(o);r=g(a,function(t){return u&&l(o,t.name)>=0||!u&&t.name===o})}else r=a.slice();return Ba(r,t)},findComponents:function(t){var e=t.query,i=t.mainType,n=function(t){var e=i+"Index",n=i+"Id",o=i+"Name";return!t||null==t[e]&&null==t[n]&&null==t[o]?null:{mainType:i,index:t[e],id:t[n],name:t[o]}}(e);return function(e){return t.filter?g(e,t.filter):e}(Ba(n?this.queryComponents(n):this._componentsMap.get(i),t))},eachComponent:function(t,e,i){var n=this._componentsMap;"function"==typeof t?(i=e,e=t,n.each(function(t,n){d(t,function(t,o){e.call(i,n,t,o)})})):_(t)?d(n.get(t),e,i):w(t)&&d(this.findComponents(t),e,i)},getSeriesByName:function(t){return g(this._componentsMap.get("series"),function(e){return e.name===t})},getSeriesByIndex:function(t){return this._componentsMap.get("series")[t]},getSeriesByType:function(t){return g(this._componentsMap.get("series"),function(e){return e.subType===t})},getSeries:function(){return this._componentsMap.get("series").slice()},getSeriesCount:function(){return this._componentsMap.get("series").length},eachSeries:function(t,e){d(this._seriesIndices,function(i){var n=this._componentsMap.get("series")[i];t.call(e,n,i)},this)},eachRawSeries:function(t,e){d(this._componentsMap.get("series"),t,e)},eachSeriesByType:function(t,e,i){d(this._seriesIndices,function(n){var o=this._componentsMap.get("series")[n];o.subType===t&&e.call(i,o,n)},this)},eachRawSeriesByType:function(t,e,i){return d(this.getSeriesByType(t),e,i)},isSeriesFiltered:function(t){return null==this._seriesIndicesMap.get(t.componentIndex)},getCurrentSeriesIndices:function(){return(this._seriesIndices||[]).slice()},filterSeries:function(t,e){za(this,g(this._componentsMap.get("series"),t,e))},restoreData:function(t){var e=this._componentsMap;za(this,e.get("series"));var i=[];e.each(function(t,e){i.push(e)}),uI.topologicalTravel(i,uI.getAllClassMainTypes(),function(i,n){d(e.get(i),function(e){("series"!==i||!Pa(e,t))&&e.restoreData()})})}});h(II,fI);var TI=["getDom","getZr","getWidth","getHeight","getDevicePixelRatio","dispatchAction","isDisposed","on","off","getDataURL","getConnectedDataURL","getModel","getOption","getViewOfComponentModel","getViewOfSeriesModel"],AI={};Ga.prototype={constructor:Ga,create:function(t,e){var i=[];d(AI,function(n,o){var a=n.create(t,e);i=i.concat(a||[])}),this._coordinateSystems=i},update:function(t,e){d(this._coordinateSystems,function(i){i.update&&i.update(t,e)})},getCoordinateSystems:function(){return this._coordinateSystems.slice()}},Ga.register=function(t,e){AI[t]=e},Ga.get=function(t){return AI[t]};var DI=d,CI=i,LI=f,kI=n,PI=/^(min|max)?(.+)$/;Fa.prototype={constructor:Fa,setOption:function(t,e){t&&d(Di(t.series),function(t){t&&t.data&&S(t.data)&&N(t.data)}),t=CI(t,!0);var i=this._optionBackup,n=Wa.call(this,t,e,!i);this._newBaseOption=n.baseOption,i?(Xa(i.baseOption,n.baseOption),n.timelineOptions.length&&(i.timelineOptions=n.timelineOptions),n.mediaList.length&&(i.mediaList=n.mediaList),n.mediaDefault&&(i.mediaDefault=n.mediaDefault)):this._optionBackup=n},mountOption:function(t){var e=this._optionBackup;return this._timelineOptions=LI(e.timelineOptions,CI),this._mediaList=LI(e.mediaList,CI),this._mediaDefault=CI(e.mediaDefault),this._currentMediaIndices=[],CI(t?e.baseOption:this._newBaseOption)},getTimelineOption:function(t){var e,i=this._timelineOptions;if(i.length){var n=t.getComponent("timeline");n&&(e=CI(i[n.getCurrentIndex()],!0))}return e},getMediaOption:function(t){var e=this._api.getWidth(),i=this._api.getHeight(),n=this._mediaList,o=this._mediaDefault,a=[],r=[];if(!n.length&&!o)return r;for(var s=0,l=n.length;s=1)&&(t=1),t}var i=this._upstream,n=t&&t.skip;if(this._dirty&&i){var o=this.context;o.data=o.outputData=i.context.outputData}this.__pipeline&&(this.__pipeline.currentTask=this);var a;this._plan&&!n&&(a=this._plan(this.context));var r=e(this._modBy),s=this._modDataCount||0,l=e(t&&t.modBy),u=t&&t.modDataCount||0;r===l&&s===u||(a="reset");var h;(this._dirty||"reset"===a)&&(this._dirty=!1,h=vr(this,n)),this._modBy=l,this._modDataCount=u;var c=t&&t.step;if(this._dueEnd=i?i._outputDueEnd:this._count?this._count(this.context):1/0,this._progress){var d=this._dueIndex,f=Math.min(null!=c?this._dueIndex+c:1/0,this._dueEnd);if(!n&&(h||d=i?null:t1&&a>0?e:t}};return s}();XI.dirty=function(){this._dirty=!0,this._onDirty&&this._onDirty(this.context)},XI.unfinished=function(){return this._progress&&this._dueIndex":"\n",s="richText"===n,l={},u=0,h=this.getData(),c=h.mapDimension("defaultedTooltip",!0),f=c.length,g=this.getRawValue(t),m=y(g),v=h.getItemVisual(t,"color");w(v)&&v.colorStops&&(v=(v.colorStops[0]||{}).color),v=v||"transparent";var x=(f>1||m&&!f?function(i){function o(t,i){var o=h.getDimensionInfo(i);if(o&&!1!==o.otherDims.tooltip){var c=o.type,d="sub"+a.seriesIndex+"at"+u,p=oa({color:v,type:"subItem",renderMode:n,markerId:d}),g="string"==typeof p?p:p.content,m=(r?g+ea(o.displayName||"-")+": ":"")+ea("ordinal"===c?t+"":"time"===c?e?"":ra("yyyy/MM/dd hh:mm:ss",t):Qo(t));m&&f.push(m),s&&(l[d]=v,++u)}}var r=p(i,function(t,e,i){var n=h.getDimensionInfo(i);return t|=n&&!1!==n.tooltip&&null!=n.displayName},0),f=[];c.length?d(c,function(e){o(dr(h,t,e),e)}):d(i,o);var g=r?s?"\n":"
    ":"",m=g+f.join(g||", ");return{renderMode:n,content:m,style:l}}(g):o(f?dr(h,t,c[0]):m?g[0]:g)).content,_=a.seriesIndex+"at"+u,b=oa({color:v,type:"item",renderMode:n,markerId:_});l[_]=v,++u;var S=h.getName(t),M=this.name;Oi(this)||(M=""),M=M?ea(M)+(e?": ":r):"";var I="string"==typeof b?b:b.content;return{html:e?I+M+x:M+I+(S?ea(S)+": "+x:x),markers:l}},isAnimationEnabled:function(){if(U_.node)return!1;var t=this.getShallow("animation");return t&&this.getData().count()>this.getShallow("animationThreshold")&&(t=!1),t},restoreData:function(){this.dataTask.dirty()},getColorFromPalette:function(t,e,i){var n=this.ecModel,o=fI.getColorFromPalette.call(this,t,e,i);return o||(o=n.getColorFromPalette(t,e,i)),o},coordDimToDataDim:function(t){return this.getRawData().mapDimension(t,!0)},getProgressive:function(){return this.get("progressive")},getProgressiveThreshold:function(){return this.get("progressiveThreshold")},getAxisTooltipData:null,getTooltipPosition:null,pipeTask:null,preventIncremental:null,pipelineContext:null});h(qI,UI),h(qI,fI);var KI=function(){this.group=new tb,this.uid=Eo("viewComponent")};KI.prototype={constructor:KI,init:function(t,e){},render:function(t,e,i,n){},dispose:function(){},filterForExposedEvent:null};var $I=KI.prototype;$I.updateView=$I.updateLayout=$I.updateVisual=function(t,e,i,n){},Xi(KI),Ki(KI,{registerWhenExtend:!0});var JI=function(){var t=Bi();return function(e){var i=t(e),n=e.pipelineContext,o=i.large,a=i.progressiveRender,r=i.large=n.large,s=i.progressiveRender=n.progressiveRender;return!!(o^r||a^s)&&"reset"}},QI=Bi(),tT=JI();Tr.prototype={type:"chart",init:function(t,e){},render:function(t,e,i,n){},highlight:function(t,e,i,n){Dr(t.getData(),n,"emphasis")},downplay:function(t,e,i,n){Dr(t.getData(),n,"normal")},remove:function(t,e){this.group.removeAll()},dispose:function(){},incrementalPrepareRender:null,incrementalRender:null,updateTransform:null,filterForExposedEvent:null};var eT=Tr.prototype;eT.updateView=eT.updateLayout=eT.updateVisual=function(t,e,i,n){this.render(t,e,i,n)},Xi(Tr),Ki(Tr,{registerWhenExtend:!0}),Tr.markUpdateMethod=function(t,e){QI(t).updateMethod=e};var iT={incrementalPrepareRender:{progress:function(t,e){e.view.incrementalRender(t,e.model,e.ecModel,e.api,e.payload)}},render:{forceFirstProgress:!0,progress:function(t,e){e.view.render(e.model,e.ecModel,e.api,e.payload)}}},nT="\0__throttleOriginMethod",oT="\0__throttleRate",aT="\0__throttleType",rT={createOnAllSeries:!0,performRawSeries:!0,reset:function(t,e){var i=t.getData(),n=(t.visualColorAccessPath||"itemStyle.color").split("."),o=t.get(n)||t.getColorFromPalette(t.name,null,e.getSeriesCount());if(i.setVisual("color",o),!e.isSeriesFiltered(t)){"function"!=typeof o||o instanceof IM||i.each(function(e){i.setItemVisual(e,"color",o(t.getDataParams(e)))});return{dataEach:i.hasItemOption?function(t,e){var i=t.getItemModel(e).get(n,!0);null!=i&&t.setItemVisual(e,"color",i)}:null}}}},sT={toolbox:{brush:{title:{rect:"矩形选择",polygon:"圈选",lineX:"横向选择",lineY:"纵向选择",keep:"保持选择",clear:"清除选择"}},dataView:{title:"数据视图",lang:["数据视图","关闭","刷新"]},dataZoom:{title:{zoom:"区域缩放",back:"区域缩放还原"}},magicType:{title:{line:"切换为折线图",bar:"切换为柱状图",stack:"切换为堆叠",tiled:"切换为平铺"}},restore:{title:"还原"},saveAsImage:{title:"保存为图片",lang:["右键另存为图片"]}},series:{typeNames:{pie:"饼图",bar:"柱状图",line:"折线图",scatter:"散点图",effectScatter:"涟漪散点图",radar:"雷达图",tree:"树图",treemap:"矩形树图",boxplot:"箱型图",candlestick:"K线图",k:"K线图",heatmap:"热力图",map:"地图",parallel:"平行坐标图",lines:"线图",graph:"关系图",sankey:"桑基图",funnel:"漏斗图",gauge:"仪表盘图",pictorialBar:"象形柱图",themeRiver:"主题河流图",sunburst:"旭日图"}},aria:{general:{withTitle:"这是一个关于“{title}”的图表。",withoutTitle:"这是一个图表,"},series:{single:{prefix:"",withName:"图表类型是{seriesType},表示{seriesName}。",withoutName:"图表类型是{seriesType}。"},multiple:{prefix:"它由{seriesCount}个图表系列组成。",withName:"第{seriesId}个系列是一个表示{seriesName}的{seriesType},",withoutName:"第{seriesId}个系列是一个{seriesType},",separator:{middle:";",end:"。"}}},data:{allData:"其数据是——",partialData:"其中,前{displayCnt}项是——",withName:"{name}的数据是{value}",withoutName:"{value}",separator:{middle:",",end:""}}}},lT=function(t,e){function i(t,e){if("string"!=typeof t)return t;var i=t;return d(e,function(t,e){i=i.replace(new RegExp("\\{\\s*"+e+"\\s*\\}","g"),t)}),i}function n(t){var e=a.get(t);if(null==e){for(var i=t.split("."),n=sT.aria,o=0;o1?"series.multiple.prefix":"series.single.prefix"),{seriesCount:r}),e.eachSeries(function(t,e){if(e1?"multiple":"single")+".";a=i(a=n(s?u+"withName":u+"withoutName"),{seriesId:t.seriesIndex,seriesName:t.get("name"),seriesType:o(t.subType)});var c=t.getData();window.data=c,c.count()>l?a+=i(n("data.partialData"),{displayCnt:l}):a+=n("data.allData");for(var d=[],p=0;pi.blockIndex?i.step:null,a=n&&n.modDataCount;return{step:o,modBy:null!=a?Math.ceil(a/o):null,modDataCount:a}}},hT.getPipeline=function(t){return this._pipelineMap.get(t)},hT.updateStreamModes=function(t,e){var i=this._pipelineMap.get(t.uid),n=t.getData().count(),o=i.progressiveEnabled&&e.incrementalPrepareRender&&n>=i.threshold,a=t.get("large")&&n>=t.get("largeThreshold"),r="mod"===t.get("progressiveChunkMode")?n:null;t.pipelineContext=i.context={progressiveRender:o,modDataCount:r,large:a}},hT.restorePipelines=function(t){var e=this,i=e._pipelineMap=R();t.eachSeries(function(t){var n=t.getProgressive(),o=t.uid;i.set(o,{id:o,head:null,tail:null,threshold:t.getProgressiveThreshold(),progressiveEnabled:n&&!(t.preventIncremental&&t.preventIncremental()),blockIndex:-1,step:Math.round(n||700),count:0}),Xr(e,t,t.dataTask)})},hT.prepareStageTasks=function(){var t=this._stageTaskMap,e=this.ecInstance.getModel(),i=this.api;d(this._allHandlers,function(n){var o=t.get(n.uid)||t.set(n.uid,[]);n.reset&&Rr(this,n,o,e,i),n.overallReset&&zr(this,n,o,e,i)},this)},hT.prepareView=function(t,e,i,n){var o=t.renderTask,a=o.context;a.model=e,a.ecModel=i,a.api=n,o.__block=!t.incrementalPrepareRender,Xr(this,e,o)},hT.performDataProcessorTasks=function(t,e){Er(this,this._dataProcessorHandlers,t,e,{block:!0})},hT.performVisualTasks=function(t,e,i){Er(this,this._visualHandlers,t,e,i)},hT.performSeriesTasks=function(t){var e;t.eachSeries(function(t){e|=t.dataTask.perform()}),this.unfinished|=e},hT.plan=function(){this._pipelineMap.each(function(t){var e=t.tail;do{if(e.__block){t.blockIndex=e.__idxInPipeline;break}e=e.getUpstream()}while(e)})};var cT=hT.updatePayload=function(t,e){"remain"!==e&&(t.context.payload=e)},dT=Zr(0);Or.wrapStageHandler=function(t,e){return x(t)&&(t={overallReset:t,seriesType:jr(t)}),t.uid=Eo("stageHandler"),e&&(t.visualType=e),t};var fT,pT={},gT={};Yr(pT,II),Yr(gT,Va),pT.eachSeriesByType=pT.eachRawSeriesByType=function(t){fT=t},pT.eachComponent=function(t){"series"===t.mainType&&t.subType&&(fT=t.subType)};var mT=["#37A2DA","#32C5E9","#67E0E3","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#E062AE","#E690D1","#e7bcf3","#9d96f5","#8378EA","#96BFFF"],vT={color:mT,colorLayer:[["#37A2DA","#ffd85c","#fd7b5f"],["#37A2DA","#67E0E3","#FFDB5C","#ff9f7f","#E062AE","#9d96f5"],["#37A2DA","#32C5E9","#9FE6B8","#FFDB5C","#ff9f7f","#fb7293","#e7bcf3","#8378EA","#96BFFF"],mT]},yT=["#dd6b66","#759aa0","#e69d87","#8dc1a9","#ea7e53","#eedd78","#73a373","#73b9bc","#7289ab","#91ca8c","#f49f42"],xT={color:yT,backgroundColor:"#333",tooltip:{axisPointer:{lineStyle:{color:"#eee"},crossStyle:{color:"#eee"}}},legend:{textStyle:{color:"#eee"}},textStyle:{color:"#eee"},title:{textStyle:{color:"#eee"}},toolbox:{iconStyle:{normal:{borderColor:"#eee"}}},dataZoom:{textStyle:{color:"#eee"}},visualMap:{textStyle:{color:"#eee"}},timeline:{lineStyle:{color:"#eee"},itemStyle:{normal:{color:yT[1]}},label:{normal:{textStyle:{color:"#eee"}}},controlStyle:{normal:{color:"#eee",borderColor:"#eee"}}},timeAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},logAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},valueAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},categoryAxis:{axisLine:{lineStyle:{color:"#eee"}},axisTick:{lineStyle:{color:"#eee"}},axisLabel:{textStyle:{color:"#eee"}},splitLine:{lineStyle:{type:"dashed",color:"#aaa"}},splitArea:{areaStyle:{color:"#eee"}}},line:{symbol:"circle"},graph:{color:yT},gauge:{title:{textStyle:{color:"#eee"}}},candlestick:{itemStyle:{normal:{color:"#FD1050",color0:"#0CF49B",borderColor:"#FD1050",borderColor0:"#0CF49B"}}}};xT.categoryAxis.splitLine.show=!1,uI.extend({type:"dataset",defaultOption:{seriesLayoutBy:wI,sourceHeader:null,dimensions:null,source:null},optionUpdated:function(){_a(this)}}),KI.extend({type:"dataset"});var _T=kn.extend({type:"ellipse",shape:{cx:0,cy:0,rx:0,ry:0},buildPath:function(t,e){var i=.5522848,n=e.cx,o=e.cy,a=e.rx,r=e.ry,s=a*i,l=r*i;t.moveTo(n-a,o),t.bezierCurveTo(n-a,o-l,n-s,o-r,n,o-r),t.bezierCurveTo(n+s,o-r,n+a,o-l,n+a,o),t.bezierCurveTo(n+a,o+l,n+s,o+r,n,o+r),t.bezierCurveTo(n-s,o+r,n-a,o+l,n-a,o),t.closePath()}}),wT=/[\s,]+/;Kr.prototype.parse=function(t,e){e=e||{};var i=qr(t);if(!i)throw new Error("Illegal svg");var n=new tb;this._root=n;var o=i.getAttribute("viewBox")||"",a=parseFloat(i.getAttribute("width")||e.width),r=parseFloat(i.getAttribute("height")||e.height);isNaN(a)&&(a=null),isNaN(r)&&(r=null),ts(i,n,null,!0);for(var s=i.firstChild;s;)this._parseNode(s,n),s=s.nextSibling;var l,u;if(o){var h=P(o).split(wT);h.length>=4&&(l={x:parseFloat(h[0]||0),y:parseFloat(h[1]||0),width:parseFloat(h[2]),height:parseFloat(h[3])})}if(l&&null!=a&&null!=r&&(u=os(l,a,r),!e.ignoreViewBox)){var c=n;(n=new tb).add(c),c.scale=u.scale.slice(),c.position=u.position.slice()}return e.ignoreRootClip||null==a||null==r||n.setClipPath(new yM({shape:{x:0,y:0,width:a,height:r}})),{root:n,width:a,height:r,viewBoxRect:l,viewBoxTransform:u}},Kr.prototype._parseNode=function(t,e){var i=t.nodeName.toLowerCase();"defs"===i?this._isDefine=!0:"text"===i&&(this._isText=!0);var n;if(this._isDefine){if(r=ST[i]){var o=r.call(this,t),a=t.getAttribute("id");a&&(this._defs[a]=o)}}else{var r=bT[i];r&&(n=r.call(this,t,e),e.add(n))}for(var s=t.firstChild;s;)1===s.nodeType&&this._parseNode(s,n),3===s.nodeType&&this._isText&&this._parseText(s,n),s=s.nextSibling;"defs"===i?this._isDefine=!1:"text"===i&&(this._isText=!1)},Kr.prototype._parseText=function(t,e){if(1===t.nodeType){var i=t.getAttribute("dx")||0,n=t.getAttribute("dy")||0;this._textX+=parseFloat(i),this._textY+=parseFloat(n)}var o=new rM({style:{text:t.textContent,transformText:!0},position:[this._textX||0,this._textY||0]});Jr(e,o),ts(t,o,this._defs);var a=o.style.fontSize;a&&a<9&&(o.style.fontSize=9,o.scale=o.scale||[1,1],o.scale[0]*=a/9,o.scale[1]*=a/9);var r=o.getBoundingRect();return this._textX+=r.width,e.add(o),o};var bT={g:function(t,e){var i=new tb;return Jr(e,i),ts(t,i,this._defs),i},rect:function(t,e){var i=new yM;return Jr(e,i),ts(t,i,this._defs),i.setShape({x:parseFloat(t.getAttribute("x")||0),y:parseFloat(t.getAttribute("y")||0),width:parseFloat(t.getAttribute("width")||0),height:parseFloat(t.getAttribute("height")||0)}),i},circle:function(t,e){var i=new sM;return Jr(e,i),ts(t,i,this._defs),i.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),r:parseFloat(t.getAttribute("r")||0)}),i},line:function(t,e){var i=new _M;return Jr(e,i),ts(t,i,this._defs),i.setShape({x1:parseFloat(t.getAttribute("x1")||0),y1:parseFloat(t.getAttribute("y1")||0),x2:parseFloat(t.getAttribute("x2")||0),y2:parseFloat(t.getAttribute("y2")||0)}),i},ellipse:function(t,e){var i=new _T;return Jr(e,i),ts(t,i,this._defs),i.setShape({cx:parseFloat(t.getAttribute("cx")||0),cy:parseFloat(t.getAttribute("cy")||0),rx:parseFloat(t.getAttribute("rx")||0),ry:parseFloat(t.getAttribute("ry")||0)}),i},polygon:function(t,e){var i=t.getAttribute("points");i&&(i=Qr(i));var n=new pM({shape:{points:i||[]}});return Jr(e,n),ts(t,n,this._defs),n},polyline:function(t,e){var i=new kn;Jr(e,i),ts(t,i,this._defs);var n=t.getAttribute("points");return n&&(n=Qr(n)),new gM({shape:{points:n||[]}})},image:function(t,e){var i=new fi;return Jr(e,i),ts(t,i,this._defs),i.setStyle({image:t.getAttribute("xlink:href"),x:t.getAttribute("x"),y:t.getAttribute("y"),width:t.getAttribute("width"),height:t.getAttribute("height")}),i},text:function(t,e){var i=t.getAttribute("x")||0,n=t.getAttribute("y")||0,o=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0;this._textX=parseFloat(i)+parseFloat(o),this._textY=parseFloat(n)+parseFloat(a);var r=new tb;return Jr(e,r),ts(t,r,this._defs),r},tspan:function(t,e){var i=t.getAttribute("x"),n=t.getAttribute("y");null!=i&&(this._textX=parseFloat(i)),null!=n&&(this._textY=parseFloat(n));var o=t.getAttribute("dx")||0,a=t.getAttribute("dy")||0,r=new tb;return Jr(e,r),ts(t,r,this._defs),this._textX+=o,this._textY+=a,r},path:function(t,e){var i=En(t.getAttribute("d")||"");return Jr(e,i),ts(t,i,this._defs),i}},ST={lineargradient:function(t){var e=parseInt(t.getAttribute("x1")||0,10),i=parseInt(t.getAttribute("y1")||0,10),n=parseInt(t.getAttribute("x2")||10,10),o=parseInt(t.getAttribute("y2")||0,10),a=new TM(e,i,n,o);return $r(t,a),a},radialgradient:function(t){}},MT={fill:"fill",stroke:"stroke","stroke-width":"lineWidth",opacity:"opacity","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","stroke-dasharray":"lineDash","stroke-dashoffset":"lineDashOffset","stroke-linecap":"lineCap","stroke-linejoin":"lineJoin","stroke-miterlimit":"miterLimit","font-family":"fontFamily","font-size":"fontSize","font-style":"fontStyle","font-weight":"fontWeight","text-align":"textAlign","alignment-baseline":"textBaseline"},IT=/url\(\s*#(.*?)\)/,TT=/(translate|scale|rotate|skewX|skewY|matrix)\(([\-\s0-9\.e,]*)\)/g,AT=/([^\s:;]+)\s*:\s*([^:;]+)/g,DT=R(),CT={registerMap:function(t,e,i){var n;return y(e)?n=e:e.svg?n=[{type:"svg",source:e.svg,specialAreas:e.specialAreas}]:(e.geoJson&&!e.features&&(i=e.specialAreas,e=e.geoJson),n=[{type:"geoJSON",source:e,specialAreas:i}]),d(n,function(t){var e=t.type;"geoJson"===e&&(e=t.type="geoJSON"),(0,LT[e])(t)}),DT.set(t,n)},retrieveMap:function(t){return DT.get(t)}},LT={geoJSON:function(t){var e=t.source;t.geoJSON=_(e)?"undefined"!=typeof JSON&&JSON.parse?JSON.parse(e):new Function("return ("+e+");")():e},svg:function(t){t.svgXML=qr(t.source)}},kT=k,PT=d,NT=x,OT=w,ET=uI.parseClassType,RT={zrender:"4.0.6"},zT=1e3,BT=1e3,VT=3e3,GT={PROCESSOR:{FILTER:zT,STATISTIC:5e3},VISUAL:{LAYOUT:BT,GLOBAL:2e3,CHART:VT,COMPONENT:4e3,BRUSH:5e3}},FT="__flagInMainProcess",WT="__optionUpdated",HT=/^[a-zA-Z0-9_]+$/;ss.prototype.on=rs("on"),ss.prototype.off=rs("off"),ss.prototype.one=rs("one"),h(ss,fw);var ZT=ls.prototype;ZT._onframe=function(){if(!this._disposed){var t=this._scheduler;if(this[WT]){var e=this[WT].silent;this[FT]=!0,hs(this),UT.update.call(this),this[FT]=!1,this[WT]=!1,ps.call(this,e),gs.call(this,e)}else if(t.unfinished){var i=1,n=this._model;this._api;t.unfinished=!1;do{var o=+new Date;t.performSeriesTasks(n),t.performDataProcessorTasks(n),ds(this,n),t.performVisualTasks(n),ws(this,this._model,0,"remain"),i-=+new Date-o}while(i>0&&t.unfinished);t.unfinished||this._zr.flush()}}},ZT.getDom=function(){return this._dom},ZT.getZr=function(){return this._zr},ZT.setOption=function(t,e,i){var n;if(OT(e)&&(i=e.lazyUpdate,n=e.silent,e=e.notMerge),this[FT]=!0,!this._model||e){var o=new Fa(this._api),a=this._theme,r=this._model=new II(null,null,a,o);r.scheduler=this._scheduler,r.init(null,null,a,o)}this._model.setOption(t,KT),i?(this[WT]={silent:n},this[FT]=!1):(hs(this),UT.update.call(this),this._zr.flush(),this[WT]=!1,this[FT]=!1,ps.call(this,n),gs.call(this,n))},ZT.setTheme=function(){console.error("ECharts#setTheme() is DEPRECATED in ECharts 3.0")},ZT.getModel=function(){return this._model},ZT.getOption=function(){return this._model&&this._model.getOption()},ZT.getWidth=function(){return this._zr.getWidth()},ZT.getHeight=function(){return this._zr.getHeight()},ZT.getDevicePixelRatio=function(){return this._zr.painter.dpr||window.devicePixelRatio||1},ZT.getRenderedCanvas=function(t){if(U_.canvasSupported)return(t=t||{}).pixelRatio=t.pixelRatio||1,t.backgroundColor=t.backgroundColor||this._model.get("backgroundColor"),this._zr.painter.getRenderedCanvas(t)},ZT.getSvgDataUrl=function(){if(U_.svgSupported){var t=this._zr;return d(t.storage.getDisplayList(),function(t){t.stopAnimation(!0)}),t.painter.pathToDataUrl()}},ZT.getDataURL=function(t){var e=(t=t||{}).excludeComponents,i=this._model,n=[],o=this;PT(e,function(t){i.eachComponent({mainType:t},function(t){var e=o._componentsMap[t.__viewId];e.group.ignore||(n.push(e),e.group.ignore=!0)})});var a="svg"===this._zr.painter.getType()?this.getSvgDataUrl():this.getRenderedCanvas(t).toDataURL("image/"+(t&&t.type||"png"));return PT(n,function(t){t.group.ignore=!1}),a},ZT.getConnectedDataURL=function(t){if(U_.canvasSupported){var e=this.group,n=Math.min,o=Math.max;if(iA[e]){var a=1/0,r=1/0,s=-1/0,l=-1/0,u=[],h=t&&t.pixelRatio||1;d(eA,function(h,c){if(h.group===e){var d=h.getRenderedCanvas(i(t)),f=h.getDom().getBoundingClientRect();a=n(f.left,a),r=n(f.top,r),s=o(f.right,s),l=o(f.bottom,l),u.push({dom:d,left:f.left,top:f.top})}});var c=(s*=h)-(a*=h),f=(l*=h)-(r*=h),p=iw();p.width=c,p.height=f;var g=Ii(p);return PT(u,function(t){var e=new fi({style:{x:t.left*h-a,y:t.top*h-r,image:t.dom}});g.add(e)}),g.refreshImmediately(),p.toDataURL("image/"+(t&&t.type||"png"))}return this.getDataURL(t)}},ZT.convertToPixel=v(us,"convertToPixel"),ZT.convertFromPixel=v(us,"convertFromPixel"),ZT.containPixel=function(t,e){var i;return t=Vi(this._model,t),d(t,function(t,n){n.indexOf("Models")>=0&&d(t,function(t){var o=t.coordinateSystem;if(o&&o.containPoint)i|=!!o.containPoint(e);else if("seriesModels"===n){var a=this._chartsMap[t.__viewId];a&&a.containPoint&&(i|=a.containPoint(e,t))}},this)},this),!!i},ZT.getVisual=function(t,e){var i=(t=Vi(this._model,t,{defaultMainType:"series"})).seriesModel.getData(),n=t.hasOwnProperty("dataIndexInside")?t.dataIndexInside:t.hasOwnProperty("dataIndex")?i.indexOfRawIndex(t.dataIndex):null;return null!=n?i.getItemVisual(n,e):i.getVisual(e)},ZT.getViewOfComponentModel=function(t){return this._componentsMap[t.__viewId]},ZT.getViewOfSeriesModel=function(t){return this._chartsMap[t.__viewId]};var UT={prepareAndUpdate:function(t){hs(this),UT.update.call(this,t)},update:function(t){var e=this._model,i=this._api,n=this._zr,o=this._coordSysMgr,a=this._scheduler;if(e){a.restoreData(e,t),a.performSeriesTasks(e),o.create(e,i),a.performDataProcessorTasks(e,t),ds(this,e),o.update(e,i),ys(e),a.performVisualTasks(e,t),xs(this,e,i,t);var r=e.get("backgroundColor")||"transparent";if(U_.canvasSupported)n.setBackgroundColor(r);else{var s=Gt(r);r=qt(s,"rgb"),0===s[3]&&(r="transparent")}bs(e,i)}},updateTransform:function(t){var e=this._model,i=this,n=this._api;if(e){var o=[];e.eachComponent(function(a,r){var s=i.getViewOfComponentModel(r);if(s&&s.__alive)if(s.updateTransform){var l=s.updateTransform(r,e,n,t);l&&l.update&&o.push(s)}else o.push(s)});var a=R();e.eachSeries(function(o){var r=i._chartsMap[o.__viewId];if(r.updateTransform){var s=r.updateTransform(o,e,n,t);s&&s.update&&a.set(o.uid,1)}else a.set(o.uid,1)}),ys(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0,dirtyMap:a}),ws(i,e,0,t,a),bs(e,this._api)}},updateView:function(t){var e=this._model;e&&(Tr.markUpdateMethod(t,"updateView"),ys(e),this._scheduler.performVisualTasks(e,t,{setDirty:!0}),xs(this,this._model,this._api,t),bs(e,this._api))},updateVisual:function(t){UT.update.call(this,t)},updateLayout:function(t){UT.update.call(this,t)}};ZT.resize=function(t){this._zr.resize(t);var e=this._model;if(this._loadingFX&&this._loadingFX.resize(),e){var i=e.resetOption("media"),n=t&&t.silent;this[FT]=!0,i&&hs(this),UT.update.call(this),this[FT]=!1,ps.call(this,n),gs.call(this,n)}},ZT.showLoading=function(t,e){if(OT(t)&&(e=t,t=""),t=t||"default",this.hideLoading(),tA[t]){var i=tA[t](this._api,e),n=this._zr;this._loadingFX=i,n.add(i)}},ZT.hideLoading=function(){this._loadingFX&&this._zr.remove(this._loadingFX),this._loadingFX=null},ZT.makeActionFromEvent=function(t){var e=a({},t);return e.type=YT[t.type],e},ZT.dispatchAction=function(t,e){OT(e)||(e={silent:!!e}),jT[t.type]&&this._model&&(this[FT]?this._pendingActions.push(t):(fs.call(this,t,e.silent),e.flush?this._zr.flush(!0):!1!==e.flush&&U_.browser.weChat&&this._throttledZrFlush(),ps.call(this,e.silent),gs.call(this,e.silent)))},ZT.appendData=function(t){var e=t.seriesIndex;this.getModel().getSeriesByIndex(e).appendData(t),this._scheduler.unfinished=!0},ZT.on=rs("on"),ZT.off=rs("off"),ZT.one=rs("one");var XT=["click","dblclick","mouseover","mouseout","mousemove","mousedown","mouseup","globalout","contextmenu"];ZT._initEvents=function(){PT(XT,function(t){var e=function(e){var i,n=this.getModel(),o=e.target;if("globalout"===t)i={};else if(o&&null!=o.dataIndex){var r=o.dataModel||n.getSeriesByIndex(o.seriesIndex);i=r&&r.getDataParams(o.dataIndex,o.dataType,o)||{}}else o&&o.eventData&&(i=a({},o.eventData));if(i){var s=i.componentType,l=i.componentIndex;"markLine"!==s&&"markPoint"!==s&&"markArea"!==s||(s="series",l=i.seriesIndex);var u=s&&null!=l&&n.getComponent(s,l),h=u&&this["series"===u.mainType?"_chartsMap":"_componentsMap"][u.__viewId];i.event=e,i.type=t,this._ecEventProcessor.eventInfo={targetEl:o,packedEvent:i,model:u,view:h},this.trigger(t,i)}};e.zrEventfulCallAtLast=!0,this._zr.on(t,e,this)},this),PT(YT,function(t,e){this._messageCenter.on(e,function(t){this.trigger(e,t)},this)},this)},ZT.isDisposed=function(){return this._disposed},ZT.clear=function(){this.setOption({series:[]},!0)},ZT.dispose=function(){if(!this._disposed){this._disposed=!0,Fi(this.getDom(),aA,"");var t=this._api,e=this._model;PT(this._componentsViews,function(i){i.dispose(e,t)}),PT(this._chartsViews,function(i){i.dispose(e,t)}),this._zr.dispose(),delete eA[this.id]}},h(ls,fw),As.prototype={constructor:As,normalizeQuery:function(t){var e={},i={},n={};if(_(t)){var o=ET(t);e.mainType=o.main||null,e.subType=o.sub||null}else{var a=["Index","Name","Id"],r={name:1,dataIndex:1,dataType:1};d(t,function(t,o){for(var s=!1,l=0;l0&&h===o.length-u.length){var c=o.slice(0,h);"data"!==c&&(e.mainType=c,e[u.toLowerCase()]=t,s=!0)}}r.hasOwnProperty(o)&&(i[o]=t,s=!0),s||(n[o]=t)})}return{cptQuery:e,dataQuery:i,otherQuery:n}},filter:function(t,e,i){function n(t,e,i,n){return null==t[i]||e[n||i]===t[i]}var o=this.eventInfo;if(!o)return!0;var a=o.targetEl,r=o.packedEvent,s=o.model,l=o.view;if(!s||!l)return!0;var u=e.cptQuery,h=e.dataQuery;return n(u,s,"mainType")&&n(u,s,"subType")&&n(u,s,"index","componentIndex")&&n(u,s,"name")&&n(u,s,"id")&&n(h,r,"name")&&n(h,r,"dataIndex")&&n(h,r,"dataType")&&(!l.filterForExposedEvent||l.filterForExposedEvent(t,e.otherQuery,a,r))},afterTrigger:function(){this.eventInfo=null}};var jT={},YT={},qT=[],KT=[],$T=[],JT=[],QT={},tA={},eA={},iA={},nA=new Date-0,oA=new Date-0,aA="_echarts_instance_",rA=Cs;zs(2e3,rT),Ps(VI),Ns(5e3,function(t){var e=R();t.eachSeries(function(t){var i=t.get("stack");if(i){var n=e.get(i)||e.set(i,[]),o=t.getData(),a={stackResultDimension:o.getCalculationInfo("stackResultDimension"),stackedOverDimension:o.getCalculationInfo("stackedOverDimension"),stackedDimension:o.getCalculationInfo("stackedDimension"),stackedByDimension:o.getCalculationInfo("stackedByDimension"),isStackedByIndex:o.getCalculationInfo("isStackedByIndex"),data:o,seriesModel:t};if(!a.stackedDimension||!a.isStackedByIndex&&!a.stackedByDimension)return;n.length&&o.setCalculationInfo("stackedOnSeries",n[n.length-1].seriesModel),n.push(a)}}),e.each(or)}),Vs("default",function(t,e){r(e=e||{},{text:"loading",color:"#c23531",textColor:"#000",maskColor:"rgba(255, 255, 255, 0.8)",zlevel:0});var i=new yM({style:{fill:e.maskColor},zlevel:e.zlevel,z:1e4}),n=new SM({shape:{startAngle:-uT/2,endAngle:-uT/2+.1,r:10},style:{stroke:e.color,lineCap:"round",lineWidth:5},zlevel:e.zlevel,z:10001}),o=new yM({style:{fill:"none",text:e.text,textPosition:"right",textDistance:10,textFill:e.textColor},zlevel:e.zlevel,z:10001});n.animateShape(!0).when(1e3,{endAngle:3*uT/2}).start("circularInOut"),n.animateShape(!0).when(1e3,{startAngle:3*uT/2}).delay(300).start("circularInOut");var a=new tb;return a.add(n),a.add(o),a.add(i),a.resize=function(){var e=t.getWidth()/2,a=t.getHeight()/2;n.setShape({cx:e,cy:a});var r=n.shape.r;o.setShape({x:e-r,y:a-r,width:2*r,height:2*r}),i.setShape({x:0,y:0,width:t.getWidth(),height:t.getHeight()})},a.resize(),a}),Os({type:"highlight",event:"highlight",update:"highlight"},B),Os({type:"downplay",event:"downplay",update:"downplay"},B),ks("light",vT),ks("dark",xT);var sA={};Us.prototype={constructor:Us,add:function(t){return this._add=t,this},update:function(t){return this._update=t,this},remove:function(t){return this._remove=t,this},execute:function(){var t=this._old,e=this._new,i={},n=[],o=[];for(Xs(t,{},n,"_oldKeyGetter",this),Xs(e,i,o,"_newKeyGetter",this),a=0;ax[1]&&(x[1]=y)}e&&(this._nameList[d]=e[f])}this._rawCount=this._count=l,this._extent={},tl(this)},xA._initDataFromProvider=function(t,e){if(!(t>=e)){for(var i,n=this._chunkSize,o=this._rawData,a=this._storage,r=this.dimensions,s=r.length,l=this._dimensionInfos,u=this._nameList,h=this._idList,c=this._rawExtent,d=this._nameRepeatCount={},f=this._chunkCount,p=0;pM[1]&&(M[1]=S)}if(!o.pure){var I=u[v];if(m&&null==I)if(null!=m.name)u[v]=I=m.name;else if(null!=i){var T=r[i],A=a[T][y];if(A){I=A[x];var D=l[T].ordinalMeta;D&&D.categories.length&&(I=D.categories[I])}}var C=null==m?null:m.id;null==C&&null!=I&&(d[I]=d[I]||0,C=I,d[I]>0&&(C+="__ec__"+d[I]),d[I]++),null!=C&&(h[v]=C)}}!o.persistent&&o.clean&&o.clean(),this._rawCount=this._count=e,this._extent={},tl(this)}},xA.count=function(){return this._count},xA.getIndices=function(){var t=this._indices;if(t){var e=t.constructor,i=this._count;if(e===Array){n=new e(i);for(o=0;o=0&&e=0&&ea&&(a=s)}return i=[o,a],this._extent[t]=i,i},xA.getApproximateExtent=function(t){return t=this.getDimension(t),this._approximateExtent[t]||this.getDataExtent(t)},xA.setApproximateExtent=function(t,e){e=this.getDimension(e),this._approximateExtent[e]=t.slice()},xA.getCalculationInfo=function(t){return this._calculationInfo[t]},xA.setCalculationInfo=function(t,e){uA(t)?a(this._calculationInfo,t):this._calculationInfo[t]=e},xA.getSum=function(t){var e=0;if(this._storage[t])for(var i=0,n=this.count();i=this._rawCount||t<0)return-1;var e=this._indices,i=e[t];if(null!=i&&it))return a;o=a-1}}return-1},xA.indicesOfNearest=function(t,e,i){var n=[];if(!this._storage[t])return n;null==i&&(i=1/0);for(var o=Number.MAX_VALUE,a=-1,r=0,s=this.count();r=0&&a<0)&&(o=u,a=l,n.length=0),n.push(r))}return n},xA.getRawIndex=il,xA.getRawDataItem=function(t){if(this._rawData.persistent)return this._rawData.getItem(this.getRawIndex(t));for(var e=[],i=0;i=l&&w<=u||isNaN(w))&&(a[r++]=c),c++;h=!0}else if(2===n){for(var d=this._storage[s],v=this._storage[e[1]],y=t[e[1]][0],x=t[e[1]][1],f=0;f=l&&w<=u||isNaN(w))&&(b>=y&&b<=x||isNaN(b))&&(a[r++]=c),c++}h=!0}}if(!h)if(1===n)for(m=0;m=l&&w<=u||isNaN(w))&&(a[r++]=M)}else for(m=0;mt[I][1])&&(S=!1)}S&&(a[r++]=this.getRawIndex(m))}return rb[1]&&(b[1]=w)}}}return o},xA.downSample=function(t,e,i,n){for(var o=rl(this,[t]),a=o._storage,r=[],s=Math.floor(1/e),l=a[t],u=this.count(),h=this._chunkSize,c=o._rawExtent[t],d=new(Ks(this))(u),f=0,p=0;pu-p&&(s=u-p,r.length=s);for(var g=0;gc[1]&&(c[1]=x),d[f++]=_}return o._count=f,o._indices=d,o.getRawIndex=nl,o},xA.getItemModel=function(t){var e=this.hostModel;return new Po(this.getRawDataItem(t),e,e&&e.ecModel)},xA.diff=function(t){var e=this;return new Us(t?t.getIndices():[],this.getIndices(),function(e){return ol(t,e)},function(t){return ol(e,t)})},xA.getVisual=function(t){var e=this._visual;return e&&e[t]},xA.setVisual=function(t,e){if(uA(t))for(var i in t)t.hasOwnProperty(i)&&this.setVisual(i,t[i]);else this._visual=this._visual||{},this._visual[t]=e},xA.setLayout=function(t,e){if(uA(t))for(var i in t)t.hasOwnProperty(i)&&this.setLayout(i,t[i]);else this._layout[t]=e},xA.getLayout=function(t){return this._layout[t]},xA.getItemLayout=function(t){return this._itemLayouts[t]},xA.setItemLayout=function(t,e,i){this._itemLayouts[t]=i?a(this._itemLayouts[t]||{},e):e},xA.clearItemLayouts=function(){this._itemLayouts.length=0},xA.getItemVisual=function(t,e,i){var n=this._itemVisuals[t],o=n&&n[e];return null!=o||i?o:this.getVisual(e)},xA.setItemVisual=function(t,e,i){var n=this._itemVisuals[t]||{},o=this.hasItemVisual;if(this._itemVisuals[t]=n,uA(e))for(var a in e)e.hasOwnProperty(a)&&(n[a]=e[a],o[a]=!0);else n[e]=i,o[e]=!0},xA.clearAllVisual=function(){this._visual={},this._itemVisuals=[],this.hasItemVisual={}};var _A=function(t){t.seriesIndex=this.seriesIndex,t.dataIndex=this.dataIndex,t.dataType=this.dataType};xA.setItemGraphicEl=function(t,e){var i=this.hostModel;e&&(e.dataIndex=t,e.dataType=this.dataType,e.seriesIndex=i&&i.seriesIndex,"group"===e.type&&e.traverse(_A,e)),this._graphicEls[t]=e},xA.getItemGraphicEl=function(t){return this._graphicEls[t]},xA.eachItemGraphicEl=function(t,e){d(this._graphicEls,function(i,n){i&&t&&t.call(e,i,n)})},xA.cloneShallow=function(t){if(!t){var e=f(this.dimensions,this.getDimensionInfo,this);t=new yA(e,this.hostModel)}if(t._storage=this._storage,Js(t,this),this._indices){var i=this._indices.constructor;t._indices=new i(this._indices)}else t._indices=null;return t.getRawIndex=t._indices?nl:il,t},xA.wrapMethod=function(t,e){var i=this[t];"function"==typeof i&&(this.__wrappedMethods=this.__wrappedMethods||[],this.__wrappedMethods.push(t),this[t]=function(){var t=i.apply(this,arguments);return e.apply(this,[t].concat(C(arguments)))})},xA.TRANSFERABLE_METHODS=["cloneShallow","downSample","map"],xA.CHANGABLE_METHODS=["filterSelf","selectRange"];var wA=function(t,e){return e=e||{},ul(e.coordDimensions||[],t,{dimsDef:e.dimensionsDefine||t.dimensionsDefine,encodeDef:e.encodeDefine||t.encodeDefine,dimCount:e.dimensionsCount,generateCoord:e.generateCoord,generateCoordCount:e.generateCoordCount})};yl.prototype.parse=function(t){return t},yl.prototype.getSetting=function(t){return this._setting[t]},yl.prototype.contain=function(t){var e=this._extent;return t>=e[0]&&t<=e[1]},yl.prototype.normalize=function(t){var e=this._extent;return e[1]===e[0]?.5:(t-e[0])/(e[1]-e[0])},yl.prototype.scale=function(t){var e=this._extent;return t*(e[1]-e[0])+e[0]},yl.prototype.unionExtent=function(t){var e=this._extent;t[0]e[1]&&(e[1]=t[1])},yl.prototype.unionExtentFromData=function(t,e){this.unionExtent(t.getApproximateExtent(e))},yl.prototype.getExtent=function(){return this._extent.slice()},yl.prototype.setExtent=function(t,e){var i=this._extent;isNaN(t)||(i[0]=t),isNaN(e)||(i[1]=e)},yl.prototype.isBlank=function(){return this._isBlank},yl.prototype.setBlank=function(t){this._isBlank=t},yl.prototype.getLabel=null,Xi(yl),Ki(yl,{registerWhenExtend:!0}),xl.createByAxisModel=function(t){var e=t.option,i=e.data,n=i&&f(i,wl);return new xl({categories:n,needCollect:!n,deduplication:!1!==e.dedplication})};var bA=xl.prototype;bA.getOrdinal=function(t){return _l(this).get(t)},bA.parseAndCollect=function(t){var e,i=this._needCollect;if("string"!=typeof t&&!i)return t;if(i&&!this._deduplication)return e=this.categories.length,this.categories[e]=t,e;var n=_l(this);return null==(e=n.get(t))&&(i?(e=this.categories.length,this.categories[e]=t,n.set(t,e)):e=NaN),e};var SA=yl.prototype,MA=yl.extend({type:"ordinal",init:function(t,e){t&&!y(t)||(t=new xl({categories:t})),this._ordinalMeta=t,this._extent=e||[0,t.categories.length-1]},parse:function(t){return"string"==typeof t?this._ordinalMeta.getOrdinal(t):Math.round(t)},contain:function(t){return t=this.parse(t),SA.contain.call(this,t)&&null!=this._ordinalMeta.categories[t]},normalize:function(t){return SA.normalize.call(this,this.parse(t))},scale:function(t){return Math.round(SA.scale.call(this,t))},getTicks:function(){for(var t=[],e=this._extent,i=e[0];i<=e[1];)t.push(i),i++;return t},getLabel:function(t){if(!this.isBlank())return this._ordinalMeta.categories[t]},count:function(){return this._extent[1]-this._extent[0]+1},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},getOrdinalMeta:function(){return this._ordinalMeta},niceTicks:B,niceExtent:B});MA.create=function(){return new MA};var IA=Vo,TA=Vo,AA=yl.extend({type:"interval",_interval:0,_intervalPrecision:2,setExtent:function(t,e){var i=this._extent;isNaN(t)||(i[0]=parseFloat(t)),isNaN(e)||(i[1]=parseFloat(e))},unionExtent:function(t){var e=this._extent;t[0]e[1]&&(e[1]=t[1]),AA.prototype.setExtent.call(this,e[0],e[1])},getInterval:function(){return this._interval},setInterval:function(t){this._interval=t,this._niceExtent=this._extent.slice(),this._intervalPrecision=Sl(t)},getTicks:function(){return Tl(this._interval,this._extent,this._niceExtent,this._intervalPrecision)},getLabel:function(t,e){if(null==t)return"";var i=e&&e.precision;return null==i?i=Wo(t)||0:"auto"===i&&(i=this._intervalPrecision),t=TA(t,i,!0),Qo(t)},niceTicks:function(t,e,i){t=t||5;var n=this._extent,o=n[1]-n[0];if(isFinite(o)){o<0&&(o=-o,n.reverse());var a=bl(n,t,e,i);this._intervalPrecision=a.intervalPrecision,this._interval=a.interval,this._niceExtent=a.niceTickExtent}},niceExtent:function(t){var e=this._extent;if(e[0]===e[1])if(0!==e[0]){var i=e[0];t.fixMax?e[0]-=i/2:(e[1]+=i/2,e[0]-=i/2)}else e[1]=1;var n=e[1]-e[0];isFinite(n)||(e[0]=0,e[1]=1),this.niceTicks(t.splitNumber,t.minInterval,t.maxInterval);var o=this._interval;t.fixMin||(e[0]=TA(Math.floor(e[0]/o)*o)),t.fixMax||(e[1]=TA(Math.ceil(e[1]/o)*o))}});AA.create=function(){return new AA};var DA="__ec_stack_",CA="undefined"!=typeof Float32Array?Float32Array:Array,LA={seriesType:"bar",plan:JI(),reset:function(t){if(El(t)&&Rl(t)){var e=t.getData(),i=t.coordinateSystem,n=i.getBaseAxis(),o=i.getOtherAxis(n),a=e.mapDimension(o.dim),r=e.mapDimension(n.dim),s=o.isHorizontal(),l=s?0:1,u=Nl(kl([t]),n,t).width;return u>.5||(u=.5),{progress:function(t,e){for(var n,h=new CA(2*t.count),c=[],d=[],f=0;null!=(n=t.next());)d[l]=e.get(a,n),d[1-l]=e.get(r,n),c=i.dataToPoint(d,null,c),h[f++]=c[0],h[f++]=c[1];e.setLayout({largePoints:h,barWidth:u,valueAxisStart:zl(0,o),valueAxisHorizontal:s})}}}}},kA=AA.prototype,PA=Math.ceil,NA=Math.floor,OA=function(t,e,i,n){for(;i>>1;t[o][1]i&&(a=i);var r=RA.length,s=OA(RA,a,0,r),l=RA[Math.min(s,r-1)],u=l[1];"year"===l[0]&&(u*=Ko(o/u/t,!0));var h=this.getSetting("useUTC")?0:60*new Date(+n[0]||+n[1]).getTimezoneOffset()*1e3,c=[Math.round(PA((n[0]-h)/u)*u+h),Math.round(NA((n[1]-h)/u)*u+h)];Il(c,n),this._stepLvl=l,this._interval=u,this._niceExtent=c},parse:function(t){return+jo(t)}});d(["contain","normalize"],function(t){EA.prototype[t]=function(e){return kA[t].call(this,this.parse(e))}});var RA=[["hh:mm:ss",1e3],["hh:mm:ss",5e3],["hh:mm:ss",1e4],["hh:mm:ss",15e3],["hh:mm:ss",3e4],["hh:mm\nMM-dd",6e4],["hh:mm\nMM-dd",3e5],["hh:mm\nMM-dd",6e5],["hh:mm\nMM-dd",9e5],["hh:mm\nMM-dd",18e5],["hh:mm\nMM-dd",36e5],["hh:mm\nMM-dd",72e5],["hh:mm\nMM-dd",216e5],["hh:mm\nMM-dd",432e5],["MM-dd\nyyyy",864e5],["MM-dd\nyyyy",1728e5],["MM-dd\nyyyy",2592e5],["MM-dd\nyyyy",3456e5],["MM-dd\nyyyy",432e6],["MM-dd\nyyyy",5184e5],["week",6048e5],["MM-dd\nyyyy",864e6],["week",12096e5],["week",18144e5],["month",26784e5],["week",36288e5],["month",53568e5],["week",6048e6],["quarter",8208e6],["month",107136e5],["month",13392e6],["half-year",16416e6],["month",214272e5],["month",26784e6],["year",32832e6]];EA.create=function(t){return new EA({useUTC:t.ecModel.get("useUTC")})};var zA=yl.prototype,BA=AA.prototype,VA=Wo,GA=Vo,FA=Math.floor,WA=Math.ceil,HA=Math.pow,ZA=Math.log,UA=yl.extend({type:"log",base:10,$constructor:function(){yl.apply(this,arguments),this._originalScale=new AA},getTicks:function(){var t=this._originalScale,e=this._extent,i=t.getExtent();return f(BA.getTicks.call(this),function(n){var o=Vo(HA(this.base,n));return o=n===e[0]&&t.__fixMin?Bl(o,i[0]):o,o=n===e[1]&&t.__fixMax?Bl(o,i[1]):o},this)},getLabel:BA.getLabel,scale:function(t){return t=zA.scale.call(this,t),HA(this.base,t)},setExtent:function(t,e){var i=this.base;t=ZA(t)/ZA(i),e=ZA(e)/ZA(i),BA.setExtent.call(this,t,e)},getExtent:function(){var t=this.base,e=zA.getExtent.call(this);e[0]=HA(t,e[0]),e[1]=HA(t,e[1]);var i=this._originalScale,n=i.getExtent();return i.__fixMin&&(e[0]=Bl(e[0],n[0])),i.__fixMax&&(e[1]=Bl(e[1],n[1])),e},unionExtent:function(t){this._originalScale.unionExtent(t);var e=this.base;t[0]=ZA(t[0])/ZA(e),t[1]=ZA(t[1])/ZA(e),zA.unionExtent.call(this,t)},unionExtentFromData:function(t,e){this.unionExtent(t.getApproximateExtent(e))},niceTicks:function(t){t=t||10;var e=this._extent,i=e[1]-e[0];if(!(i===1/0||i<=0)){var n=Yo(i);for(t/i*n<=.5&&(n*=10);!isNaN(n)&&Math.abs(n)<1&&Math.abs(n)>0;)n*=10;var o=[Vo(WA(e[0]/n)*n),Vo(FA(e[1]/n)*n)];this._interval=n,this._niceExtent=o}},niceExtent:function(t){BA.niceExtent.call(this,t);var e=this._originalScale;e.__fixMin=t.fixMin,e.__fixMax=t.fixMax}});d(["contain","normalize"],function(t){UA.prototype[t]=function(e){return e=ZA(e)/ZA(this.base),zA[t].call(this,e)}}),UA.create=function(){return new UA};var XA={getMin:function(t){var e=this.option,i=t||null==e.rangeStart?e.min:e.rangeStart;return this.axis&&null!=i&&"dataMin"!==i&&"function"!=typeof i&&!I(i)&&(i=this.axis.scale.parse(i)),i},getMax:function(t){var e=this.option,i=t||null==e.rangeEnd?e.max:e.rangeEnd;return this.axis&&null!=i&&"dataMax"!==i&&"function"!=typeof i&&!I(i)&&(i=this.axis.scale.parse(i)),i},getNeedCrossZero:function(){var t=this.option;return null==t.rangeStart&&null==t.rangeEnd&&!t.scale},getCoordSysModel:B,setRange:function(t,e){this.option.rangeStart=t,this.option.rangeEnd=e},resetRange:function(){this.option.rangeStart=this.option.rangeEnd=null}},jA=Zn({type:"triangle",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var i=e.cx,n=e.cy,o=e.width/2,a=e.height/2;t.moveTo(i,n-a),t.lineTo(i+o,n+a),t.lineTo(i-o,n+a),t.closePath()}}),YA=Zn({type:"diamond",shape:{cx:0,cy:0,width:0,height:0},buildPath:function(t,e){var i=e.cx,n=e.cy,o=e.width/2,a=e.height/2;t.moveTo(i,n-a),t.lineTo(i+o,n),t.lineTo(i,n+a),t.lineTo(i-o,n),t.closePath()}}),qA=Zn({type:"pin",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var i=e.x,n=e.y,o=e.width/5*3,a=Math.max(o,e.height),r=o/2,s=r*r/(a-r),l=n-a+r+s,u=Math.asin(s/r),h=Math.cos(u)*r,c=Math.sin(u),d=Math.cos(u),f=.6*r,p=.7*r;t.moveTo(i-h,l+s),t.arc(i,l,r,Math.PI-u,2*Math.PI+u),t.bezierCurveTo(i+h-c*f,l+s+d*f,i,n-p,i,n),t.bezierCurveTo(i,n-p,i-h+c*f,l+s+d*f,i-h,l+s),t.closePath()}}),KA=Zn({type:"arrow",shape:{x:0,y:0,width:0,height:0},buildPath:function(t,e){var i=e.height,n=e.width,o=e.x,a=e.y,r=n/3*2;t.moveTo(o,a),t.lineTo(o+r,a+i),t.lineTo(o,a+i/4*3),t.lineTo(o-r,a+i),t.lineTo(o,a),t.closePath()}}),$A={line:function(t,e,i,n,o){o.x1=t,o.y1=e+n/2,o.x2=t+i,o.y2=e+n/2},rect:function(t,e,i,n,o){o.x=t,o.y=e,o.width=i,o.height=n},roundRect:function(t,e,i,n,o){o.x=t,o.y=e,o.width=i,o.height=n,o.r=Math.min(i,n)/4},square:function(t,e,i,n,o){var a=Math.min(i,n);o.x=t,o.y=e,o.width=a,o.height=a},circle:function(t,e,i,n,o){o.cx=t+i/2,o.cy=e+n/2,o.r=Math.min(i,n)/2},diamond:function(t,e,i,n,o){o.cx=t+i/2,o.cy=e+n/2,o.width=i,o.height=n},pin:function(t,e,i,n,o){o.x=t+i/2,o.y=e+n/2,o.width=i,o.height=n},arrow:function(t,e,i,n,o){o.x=t+i/2,o.y=e+n/2,o.width=i,o.height=n},triangle:function(t,e,i,n,o){o.cx=t+i/2,o.cy=e+n/2,o.width=i,o.height=n}},JA={};d({line:_M,rect:yM,roundRect:yM,square:yM,circle:sM,diamond:YA,pin:qA,arrow:KA,triangle:jA},function(t,e){JA[e]=new t});var QA=Zn({type:"symbol",shape:{symbolType:"",x:0,y:0,width:0,height:0},beforeBrush:function(){var t=this.style;"pin"===this.shape.symbolType&&"inside"===t.textPosition&&(t.textPosition=["50%","40%"],t.textAlign="center",t.textVerticalAlign="middle")},buildPath:function(t,e,i){var n=e.symbolType,o=JA[n];"none"!==e.symbolType&&(o||(o=JA[n="rect"]),$A[n](e.x,e.y,e.width,e.height,o.shape),o.buildPath(t,o.shape,i))}}),tD={isDimensionStacked:fl,enableDataStack:dl,getStackedDimension:pl},eD=(Object.freeze||Object)({createList:function(t){return gl(t.getSource(),t)},getLayoutRect:ha,dataStack:tD,createScale:function(t,e){var i=e;Po.isInstance(e)||h(i=new Po(e),XA);var n=Wl(i);return n.setExtent(t[0],t[1]),Fl(n,i),n},mixinAxisModelCommonMethods:function(t){h(t,XA)},completeDimensions:ul,createDimensions:wA,createSymbol:$l}),iD=1e-8;tu.prototype={constructor:tu,properties:null,getBoundingRect:function(){var t=this._rect;if(t)return t;for(var e=Number.MAX_VALUE,i=[e,e],n=[-e,-e],o=[],a=[],r=this.geometries,s=0;s0}),function(t){var e=t.properties,i=t.geometry,n=i.coordinates,o=[];"Polygon"===i.type&&o.push({type:"polygon",exterior:n[0],interiors:n.slice(1)}),"MultiPolygon"===i.type&&d(n,function(t){t[0]&&o.push({type:"polygon",exterior:t[0],interiors:t.slice(1)})});var a=new tu(e.name,o,e.cp);return a.properties=e,a})},oD=Bi(),aD=[0,1],rD=function(t,e,i){this.dim=t,this.scale=e,this._extent=i||[0,0],this.inverse=!1,this.onBand=!1};rD.prototype={constructor:rD,contain:function(t){var e=this._extent,i=Math.min(e[0],e[1]),n=Math.max(e[0],e[1]);return t>=i&&t<=n},containData:function(t){return this.contain(this.dataToCoord(t))},getExtent:function(){return this._extent.slice()},getPixelPrecision:function(t){return Ho(t||this.scale.getExtent(),this._extent)},setExtent:function(t,e){var i=this._extent;i[0]=t,i[1]=e},dataToCoord:function(t,e){var i=this._extent,n=this.scale;return t=n.normalize(t),this.onBand&&"ordinal"===n.type&&vu(i=i.slice(),n.count()),zo(t,aD,i,e)},coordToData:function(t,e){var i=this._extent,n=this.scale;this.onBand&&"ordinal"===n.type&&vu(i=i.slice(),n.count());var o=zo(t,i,aD,e);return this.scale.scale(o)},pointToData:function(t,e){},getTicksCoords:function(t){var e=(t=t||{}).tickModel||this.getTickModel(),i=ou(this,e),n=f(i.ticks,function(t){return{coord:this.dataToCoord(t),tickValue:t}},this),o=e.get("alignWithLabel");return yu(this,n,i.tickCategoryInterval,o,t.clamp),n},getViewLabels:function(){return nu(this).labels},getLabelModel:function(){return this.model.getModel("axisLabel")},getTickModel:function(){return this.model.getModel("axisTick")},getBandWidth:function(){var t=this._extent,e=this.scale.getExtent(),i=e[1]-e[0]+(this.onBand?1:0);0===i&&(i=1);var n=Math.abs(t[1]-t[0]);return Math.abs(n)/i},isHorizontal:null,getRotate:null,calculateCategoryInterval:function(){return fu(this)}};var sD=nD,lD={};d(["map","each","filter","indexOf","inherits","reduce","filter","bind","curry","isArray","isString","isObject","isFunction","extend","defaults","clone","merge"],function(t){lD[t]=aw[t]});var uD={};d(["extendShape","extendPath","makePath","makeImage","mergePath","resizePath","createIcon","setHoverStyle","setLabelStyle","setTextStyle","setText","getFont","updateProps","initProps","getTransform","clipPointsByRect","clipRectByRect","Group","Image","Text","Circle","Sector","Ring","Polygon","Polyline","Rect","Line","BezierCurve","Arc","IncrementalDisplayable","CompoundPath","LinearGradient","RadialGradient","BoundingRect"],function(t){uD[t]=zM[t]}),qI.extend({type:"series.line",dependencies:["grid","polar"],getInitialData:function(t,e){return gl(this.getSource(),this)},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,clipOverflow:!0,label:{position:"top"},lineStyle:{width:2,type:"solid"},step:!1,smooth:!1,smoothMonotone:null,symbol:"emptyCircle",symbolSize:4,symbolRotate:null,showSymbol:!0,showAllSymbol:"auto",connectNulls:!1,sampling:"none",animationEasing:"linear",progressive:0,hoverLayerThreshold:1/0}});var hD=_u.prototype,cD=_u.getSymbolSize=function(t,e){var i=t.getItemVisual(e,"symbolSize");return i instanceof Array?i.slice():[+i,+i]};hD._createSymbol=function(t,e,i,n,o){this.removeAll();var a=$l(t,-1,-1,2,2,e.getItemVisual(i,"color"),o);a.attr({z2:100,culling:!0,scale:wu(n)}),a.drift=bu,this._symbolType=t,this.add(a)},hD.stopSymbolAnimation=function(t){this.childAt(0).stopAnimation(t)},hD.getSymbolPath=function(){return this.childAt(0)},hD.getScale=function(){return this.childAt(0).scale},hD.highlight=function(){this.childAt(0).trigger("emphasis")},hD.downplay=function(){this.childAt(0).trigger("normal")},hD.setZ=function(t,e){var i=this.childAt(0);i.zlevel=t,i.z=e},hD.setDraggable=function(t){var e=this.childAt(0);e.draggable=t,e.cursor=t?"move":"pointer"},hD.updateData=function(t,e,i){this.silent=!1;var n=t.getItemVisual(e,"symbol")||"circle",o=t.hostModel,a=cD(t,e),r=n!==this._symbolType;if(r){var s=t.getItemVisual(e,"symbolKeepAspect");this._createSymbol(n,t,e,a,s)}else(l=this.childAt(0)).silent=!1,Mo(l,{scale:wu(a)},o,e);if(this._updateCommon(t,e,a,i),r){var l=this.childAt(0),u=i&&i.fadeIn,h={scale:l.scale.slice()};u&&(h.style={opacity:l.style.opacity}),l.scale=[0,0],u&&(l.style.opacity=0),Io(l,h,o,e)}this._seriesModel=o};var dD=["itemStyle"],fD=["emphasis","itemStyle"],pD=["label"],gD=["emphasis","label"];hD._updateCommon=function(t,e,i,n){var o=this.childAt(0),r=t.hostModel,s=t.getItemVisual(e,"color");"image"!==o.type&&o.useStyle({strokeNoScale:!0});var l=n&&n.itemStyle,u=n&&n.hoverItemStyle,h=n&&n.symbolRotate,c=n&&n.symbolOffset,d=n&&n.labelModel,f=n&&n.hoverLabelModel,p=n&&n.hoverAnimation,g=n&&n.cursorStyle;if(!n||t.hasItemOption){var m=n&&n.itemModel?n.itemModel:t.getItemModel(e);l=m.getModel(dD).getItemStyle(["color"]),u=m.getModel(fD).getItemStyle(),h=m.getShallow("symbolRotate"),c=m.getShallow("symbolOffset"),d=m.getModel(pD),f=m.getModel(gD),p=m.getShallow("hoverAnimation"),g=m.getShallow("cursor")}else u=a({},u);var v=o.style;o.attr("rotation",(h||0)*Math.PI/180||0),c&&o.attr("position",[Bo(c[0],i[0]),Bo(c[1],i[1])]),g&&o.attr("cursor",g),o.setColor(s,n&&n.symbolInnerColor),o.setStyle(l);var y=t.getItemVisual(e,"opacity");null!=y&&(v.opacity=y);var x=t.getItemVisual(e,"liftZ"),_=o.__z2Origin;null!=x?null==_&&(o.__z2Origin=o.z2,o.z2+=x):null!=_&&(o.z2=_,o.__z2Origin=null);var w=n&&n.useNameLabel;po(v,u,d,f,{labelFetcher:r,labelDataIndex:e,defaultText:function(e,i){return w?t.getName(e):xu(t,e)},isRectText:!0,autoColor:s}),o.off("mouseover").off("mouseout").off("emphasis").off("normal"),o.hoverStyle=u,co(o),o.__symbolOriginalScale=wu(i),p&&r.isAnimationEnabled()&&o.on("mouseover",Su).on("mouseout",Mu).on("emphasis",Iu).on("normal",Tu)},hD.fadeOut=function(t,e){var i=this.childAt(0);this.silent=i.silent=!0,!(e&&e.keepLabel)&&(i.style.text=null),Mo(i,{style:{opacity:0},scale:[0,0]},this._seriesModel,this.dataIndex,t)},u(_u,tb);var mD=Au.prototype;mD.updateData=function(t,e){e=Cu(e);var i=this.group,n=t.hostModel,o=this._data,a=this._symbolCtor,r=Lu(t);o||i.removeAll(),t.diff(o).add(function(n){var o=t.getItemLayout(n);if(Du(t,o,n,e)){var s=new a(t,n,r);s.attr("position",o),t.setItemGraphicEl(n,s),i.add(s)}}).update(function(s,l){var u=o.getItemGraphicEl(l),h=t.getItemLayout(s);Du(t,h,s,e)?(u?(u.updateData(t,s,r),Mo(u,{position:h},n)):(u=new a(t,s)).attr("position",h),i.add(u),t.setItemGraphicEl(s,u)):i.remove(u)}).remove(function(t){var e=o.getItemGraphicEl(t);e&&e.fadeOut(function(){i.remove(e)})}).execute(),this._data=t},mD.isPersistent=function(){return!0},mD.updateLayout=function(){var t=this._data;t&&t.eachItemGraphicEl(function(e,i){var n=t.getItemLayout(i);e.attr("position",n)})},mD.incrementalPrepareUpdate=function(t){this._seriesScope=Lu(t),this._data=null,this.group.removeAll()},mD.incrementalUpdate=function(t,e,i){i=Cu(i);for(var n=t.start;n0&&Eu(i[o-1]);o--);for(;n0&&Eu(i[a-1]);a--);for(;o=0){var r=o.getItemGraphicEl(a);if(!r){var s=o.getItemLayout(a);if(!s)return;(r=new _u(o,a)).position=s,r.setZ(t.get("zlevel"),t.get("z")),r.ignore=isNaN(s[0])||isNaN(s[1]),r.__temp=!0,o.setItemGraphicEl(a,r),r.stopSymbolAnimation(!0),this.group.add(r)}r.highlight()}else Tr.prototype.highlight.call(this,t,e,i,n)},downplay:function(t,e,i,n){var o=t.getData(),a=zi(o,n);if(null!=a&&a>=0){var r=o.getItemGraphicEl(a);r&&(r.__temp?(o.setItemGraphicEl(a,null),this.group.remove(r)):r.downplay())}else Tr.prototype.downplay.call(this,t,e,i,n)},_newPolyline:function(t){var e=this._polyline;return e&&this._lineGroup.remove(e),e=new ID({shape:{points:t},silent:!0,z2:10}),this._lineGroup.add(e),this._polyline=e,e},_newPolygon:function(t,e){var i=this._polygon;return i&&this._lineGroup.remove(i),i=new TD({shape:{points:t,stackedOnPoints:e},silent:!0}),this._lineGroup.add(i),this._polygon=i,i},_updateAnimation:function(t,e,i,n,o,a){var r=this._polyline,s=this._polygon,l=t.hostModel,u=vD(this._data,t,this._stackedOnPoints,e,this._coordSys,i,this._valueOrigin,a),h=u.current,c=u.stackedOnCurrent,d=u.next,f=u.stackedOnNext;o&&(h=ju(u.current,i,o),c=ju(u.stackedOnCurrent,i,o),d=ju(u.next,i,o),f=ju(u.stackedOnNext,i,o)),r.shape.__points=u.current,r.shape.points=h,Mo(r,{shape:{points:d}},l),s&&(s.setShape({points:h,stackedOnPoints:c}),Mo(s,{shape:{points:d,stackedOnPoints:f}},l));for(var p=[],g=u.status,m=0;me&&(e=t[i]);return isFinite(e)?e:NaN},min:function(t){for(var e=1/0,i=0;ie[1]&&e.reverse(),e},getOtherAxis:function(){this.grid.getOtherAxis()},pointToData:function(t,e){return this.coordToData(this.toLocalCoord(t["x"===this.dim?0:1]),e)},toLocalCoord:null,toGlobalCoord:null},u(PD,rD);var ND={show:!0,zlevel:0,z:0,inverse:!1,name:"",nameLocation:"end",nameRotate:null,nameTruncate:{maxWidth:null,ellipsis:"...",placeholder:"."},nameTextStyle:{},nameGap:15,silent:!1,triggerEvent:!1,tooltip:{show:!1},axisPointer:{},axisLine:{show:!0,onZero:!0,onZeroAxisIndex:null,lineStyle:{color:"#333",width:1,type:"solid"},symbol:["none","none"],symbolSize:[10,15]},axisTick:{show:!0,inside:!1,length:5,lineStyle:{width:1}},axisLabel:{show:!0,inside:!1,rotate:0,showMinLabel:null,showMaxLabel:null,margin:8,fontSize:12},splitLine:{show:!0,lineStyle:{color:["#ccc"],width:1,type:"solid"}},splitArea:{show:!1,areaStyle:{color:["rgba(250,250,250,0.3)","rgba(200,200,200,0.3)"]}}},OD={};OD.categoryAxis=n({boundaryGap:!0,deduplication:null,splitLine:{show:!1},axisTick:{alignWithLabel:!1,interval:"auto"},axisLabel:{interval:"auto"}},ND),OD.valueAxis=n({boundaryGap:[0,0],splitNumber:5},ND),OD.timeAxis=r({scale:!0,min:"dataMin",max:"dataMax"},OD.valueAxis),OD.logAxis=r({scale:!0,logBase:10},OD.valueAxis);var ED=["value","category","time","log"],RD=function(t,e,i,a){d(ED,function(r){e.extend({type:t+"Axis."+r,mergeDefaultAndTheme:function(e,o){var a=this.layoutMode,s=a?pa(e):{};n(e,o.getTheme().get(r+"Axis")),n(e,this.getDefaultOption()),e.type=i(t,e),a&&fa(e,s,a)},optionUpdated:function(){"category"===this.option.type&&(this.__ordinalMeta=xl.createByAxisModel(this))},getCategories:function(t){var e=this.option;if("category"===e.type)return t?e.data:this.__ordinalMeta.categories},getOrdinalMeta:function(){return this.__ordinalMeta},defaultOption:o([{},OD[r+"Axis"],a],!0)})}),uI.registerSubTypeDefaulter(t+"Axis",v(i,t))},zD=uI.extend({type:"cartesian2dAxis",axis:null,init:function(){zD.superApply(this,"init",arguments),this.resetRange()},mergeOption:function(){zD.superApply(this,"mergeOption",arguments),this.resetRange()},restoreData:function(){zD.superApply(this,"restoreData",arguments),this.resetRange()},getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"grid",index:this.option.gridIndex,id:this.option.gridId})[0]}});n(zD.prototype,XA);var BD={offset:0};RD("x",zD,Qu,BD),RD("y",zD,Qu,BD),uI.extend({type:"grid",dependencies:["xAxis","yAxis"],layoutMode:"box",coordinateSystem:null,defaultOption:{show:!1,zlevel:0,z:0,left:"10%",top:60,right:"10%",bottom:60,containLabel:!1,backgroundColor:"rgba(0,0,0,0)",borderWidth:1,borderColor:"#ccc"}});var VD=eh.prototype;VD.type="grid",VD.axisPointerEnabled=!0,VD.getRect=function(){return this._rect},VD.update=function(t,e){var i=this._axesMap;this._updateScale(t,this.model),d(i.x,function(t){Fl(t.scale,t.model)}),d(i.y,function(t){Fl(t.scale,t.model)});var n={};d(i.x,function(t){ih(i,"y",t,n)}),d(i.y,function(t){ih(i,"x",t,n)}),this.resize(this.model,e)},VD.resize=function(t,e,i){function n(){d(a,function(t){var e=t.isHorizontal(),i=e?[0,o.width]:[0,o.height],n=t.inverse?1:0;t.setExtent(i[n],i[1-n]),oh(t,e?o.x:o.y)})}var o=ha(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()});this._rect=o;var a=this._axesList;n(),!i&&t.get("containLabel")&&(d(a,function(t){if(!t.model.get("axisLabel.inside")){var e=Xl(t);if(e){var i=t.isHorizontal()?"height":"width",n=t.model.get("axisLabel.margin");o[i]-=e[i]+n,"top"===t.position?o.y+=e.height+n:"left"===t.position&&(o.x+=e.width+n)}}}),n())},VD.getAxis=function(t,e){var i=this._axesMap[t];if(null!=i){if(null==e)for(var n in i)if(i.hasOwnProperty(n))return i[n];return i[e]}},VD.getAxes=function(){return this._axesList.slice()},VD.getCartesian=function(t,e){if(null!=t&&null!=e){var i="x"+t+"y"+e;return this._coordsMap[i]}w(t)&&(e=t.yAxisIndex,t=t.xAxisIndex);for(var n=0,o=this._coordsList;nu[1]?-1:1,c=["start"===o?u[0]-h*l:"end"===o?u[1]+h*l:(u[0]+u[1])/2,fh(o)?t.labelOffset+r*l:0],d=e.get("nameRotate");null!=d&&(d=d*FD/180);var f;fh(o)?n=ZD(t.rotation,null!=d?d:t.rotation,r):(n=lh(t,o,d||0,u),null!=(f=t.axisNameAvailableWidth)&&(f=Math.abs(f/Math.sin(n.rotation)),!isFinite(f)&&(f=null)));var p=s.getFont(),g=e.get("nameTruncate",!0)||{},m=g.ellipsis,v=T(t.nameTruncateMaxWidth,g.maxWidth,f),y=null!=m&&null!=v?tI(i,v,p,m,{minChar:2,placeholder:g.placeholder}):i,x=e.get("tooltip",!0),_=e.mainType,w={componentType:_,name:i,$vars:["name"]};w[_+"Index"]=e.componentIndex;var b=new rM({anid:"name",__fullText:i,__truncatedText:y,position:c,rotation:n.rotation,silent:uh(e),z2:1,tooltip:x&&x.show?a({content:i,formatter:function(){return i},formatterParams:w},x):null});go(b.style,s,{text:y,textFont:p,textFill:s.getTextColor()||e.get("axisLine.lineStyle.color"),textAlign:n.textAlign,textVerticalAlign:n.textVerticalAlign}),e.get("triggerEvent")&&(b.eventData=sh(e),b.eventData.targetType="axisName",b.eventData.name=i),this._dumbGroup.add(b),b.updateTransform(),this.group.add(b),b.decomposeTransform()}}},ZD=WD.innerTextLayout=function(t,e,i){var n,o,a=Uo(e-t);return Xo(a)?(o=i>0?"top":"bottom",n="center"):Xo(a-FD)?(o=i>0?"bottom":"top",n="center"):(o="middle",n=a>0&&a0?"right":"left":i>0?"left":"right"),{rotation:a,textAlign:n,textVerticalAlign:o}},UD=d,XD=v,jD=Fs({type:"axis",_axisPointer:null,axisPointerClass:null,render:function(t,e,i,n){this.axisPointerClass&&bh(t),jD.superApply(this,"render",arguments),Ah(this,t,0,i,0,!0)},updateAxisPointer:function(t,e,i,n,o){Ah(this,t,0,i,0,!1)},remove:function(t,e){var i=this._axisPointer;i&&i.remove(e),jD.superApply(this,"remove",arguments)},dispose:function(t,e){Dh(this,e),jD.superApply(this,"dispose",arguments)}}),YD=[];jD.registerAxisPointerClass=function(t,e){YD[t]=e},jD.getAxisPointerClass=function(t){return t&&YD[t]};var qD=["axisLine","axisTickLabel","axisName"],KD=["splitArea","splitLine"],$D=jD.extend({type:"cartesianAxis",axisPointerClass:"CartesianAxisPointer",render:function(t,e,i,n){this.group.removeAll();var o=this._axisGroup;if(this._axisGroup=new tb,this.group.add(this._axisGroup),t.get("show")){var a=t.getCoordSysModel(),r=Ch(a,t),s=new WD(t,r);d(qD,s.add,s),this._axisGroup.add(s.getGroup()),d(KD,function(e){t.get(e+".show")&&this["_"+e](t,a)},this),Co(o,this._axisGroup,t),$D.superCall(this,"render",t,e,i,n)}},remove:function(){this._splitAreaColors=null},_splitLine:function(t,e){var i=t.axis;if(!i.scale.isBlank()){var n=t.getModel("splitLine"),o=n.getModel("lineStyle"),a=o.get("color");a=y(a)?a:[a];for(var s=e.coordinateSystem.getRect(),l=i.isHorizontal(),u=0,h=i.getTicksCoords({tickModel:n}),c=[],d=[],f=o.getLineStyle(),p=0;p1){var c;"string"==typeof o?c=CD[o]:"function"==typeof o&&(c=o),c&&t.setData(n.downSample(n.mapDimension(s.dim),1/h,c,LD))}}}}}("line"));var JD=qI.extend({type:"series.__base_bar__",getInitialData:function(t,e){return gl(this.getSource(),this)},getMarkerPosition:function(t){var e=this.coordinateSystem;if(e){var i=e.dataToPoint(e.clampData(t)),n=this.getData(),o=n.getLayout("offset"),a=n.getLayout("size");return i[e.getBaseAxis().isHorizontal()?0:1]+=o+a/2,i}return[NaN,NaN]},defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,barMinHeight:0,barMinAngle:0,large:!1,largeThreshold:400,progressive:3e3,progressiveChunkMode:"mod",itemStyle:{},emphasis:{}}});JD.extend({type:"series.bar",dependencies:["grid","polar"],brushSelector:"rect",getProgressive:function(){return!!this.get("large")&&this.get("progressive")},getProgressiveThreshold:function(){var t=this.get("progressiveThreshold"),e=this.get("largeThreshold");return e>t&&(t=e),t}});var QD=Qb([["fill","color"],["stroke","borderColor"],["lineWidth","borderWidth"],["stroke","barBorderColor"],["lineWidth","barBorderWidth"],["opacity"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),tC={getBarItemStyle:function(t){var e=QD(this,t);if(this.getBorderLineDash){var i=this.getBorderLineDash();i&&(e.lineDash=i)}return e}},eC=["itemStyle","barBorderWidth"];a(Po.prototype,tC),Hs({type:"bar",render:function(t,e,i){this._updateDrawMode(t);var n=t.get("coordinateSystem");return"cartesian2d"!==n&&"polar"!==n||(this._isLargeDraw?this._renderLarge(t,e,i):this._renderNormal(t,e,i)),this.group},incrementalPrepareRender:function(t,e,i){this._clear(),this._updateDrawMode(t)},incrementalRender:function(t,e,i,n){this._incrementalRenderLarge(t,e)},_updateDrawMode:function(t){var e=t.pipelineContext.large;(null==this._isLargeDraw||e^this._isLargeDraw)&&(this._isLargeDraw=e,this._clear())},_renderNormal:function(t,e,i){var n,o=this.group,a=t.getData(),r=this._data,s=t.coordinateSystem,l=s.getBaseAxis();"cartesian2d"===s.type?n=l.isHorizontal():"polar"===s.type&&(n="angle"===l.dim);var u=t.isAnimationEnabled()?t:null;a.diff(r).add(function(e){if(a.hasValue(e)){var i=a.getItemModel(e),r=nC[s.type](a,e,i),l=iC[s.type](a,e,i,r,n,u);a.setItemGraphicEl(e,l),o.add(l),Oh(l,a,e,i,r,t,n,"polar"===s.type)}}).update(function(e,i){var l=r.getItemGraphicEl(i);if(a.hasValue(e)){var h=a.getItemModel(e),c=nC[s.type](a,e,h);l?Mo(l,{shape:c},u,e):l=iC[s.type](a,e,h,c,n,u,!0),a.setItemGraphicEl(e,l),o.add(l),Oh(l,a,e,h,c,t,n,"polar"===s.type)}else o.remove(l)}).remove(function(t){var e=r.getItemGraphicEl(t);"cartesian2d"===s.type?e&&Ph(t,u,e):e&&Nh(t,u,e)}).execute(),this._data=a},_renderLarge:function(t,e,i){this._clear(),Rh(t,this.group)},_incrementalRenderLarge:function(t,e){Rh(e,this.group,!0)},dispose:B,remove:function(t){this._clear(t)},_clear:function(t){var e=this.group,i=this._data;t&&t.get("animation")&&i&&!this._isLargeDraw?i.eachItemGraphicEl(function(e){"sector"===e.type?Nh(e.dataIndex,t,e):Ph(e.dataIndex,t,e)}):e.removeAll(),this._data=null}});var iC={cartesian2d:function(t,e,i,n,o,r,s){var l=new yM({shape:a({},n)});if(r){var u=l.shape,h=o?"height":"width",c={};u[h]=0,c[h]=n[h],zM[s?"updateProps":"initProps"](l,{shape:c},r,e)}return l},polar:function(t,e,i,n,o,a,s){var l=n.startAngle0?1:-1,r=n.height>0?1:-1;return{x:n.x+a*o/2,y:n.y+r*o/2,width:n.width-a*o,height:n.height-r*o}},polar:function(t,e,i){var n=t.getItemLayout(e);return{cx:n.cx,cy:n.cy,r0:n.r0,r:n.r,startAngle:n.startAngle,endAngle:n.endAngle}}},oC=kn.extend({type:"largeBar",shape:{points:[]},buildPath:function(t,e){for(var i=e.points,n=this.__startPoint,o=this.__valueIdx,a=0;a0&&"scale"!==u){var d=o.getItemLayout(0),f=Math.max(i.getWidth(),i.getHeight())/2,p=m(r.removeClipPath,r);r.setClipPath(this._createClipPath(d.cx,d.cy,f,d.startAngle,d.clockwise,p,t))}else r.removeClipPath();this._data=o}},dispose:function(){},_createClipPath:function(t,e,i,n,o,a,r){var s=new hM({shape:{cx:t,cy:e,r0:0,r:i,startAngle:n,endAngle:n,clockwise:o}});return Io(s,{shape:{endAngle:n+(o?1:-1)*Math.PI*2}},r,a),s},containPoint:function(t,e){var i=e.getData().getItemLayout(0);if(i){var n=t[0]-i.cx,o=t[1]-i.cy,a=Math.sqrt(n*n+o*o);return a<=i.r&&a>=i.r0}}});var uC=function(t,e){d(e,function(e){e.update="updateView",Os(e,function(i,n){var o={};return n.eachComponent({mainType:"series",subType:t,query:i},function(t){t[e.method]&&t[e.method](i.name,i.dataIndex);var n=t.getData();n.each(function(e){var i=n.getName(e);o[i]=t.isSelected(i)||!1})}),{name:i.name,selected:o}})})},hC=function(t){return{getTargetSeries:function(e){var i={},n=R();return e.eachSeriesByType(t,function(t){t.__paletteScope=i,n.set(t.uid,t)}),n},reset:function(t,e){var i=t.getRawData(),n={},o=t.getData();o.each(function(t){var e=o.getRawIndex(t);n[e]=t}),i.each(function(e){var a=n[e],r=null!=a&&o.getItemVisual(a,"color",!0);if(r)i.setItemVisual(e,"color",r);else{var s=i.getItemModel(e).get("itemStyle.color")||t.getColorFromPalette(i.getName(e)||e+"",t.__paletteScope,i.count());i.setItemVisual(e,"color",s),null!=a&&o.setItemVisual(a,"color",s)}})}}},cC=function(t,e,i,n){var o,a,r=t.getData(),s=[],l=!1;r.each(function(i){var n,u,h,c,d=r.getItemLayout(i),f=r.getItemModel(i),p=f.getModel("label"),g=p.get("position")||f.get("emphasis.label.position"),m=f.getModel("labelLine"),v=m.get("length"),y=m.get("length2"),x=(d.startAngle+d.endAngle)/2,_=Math.cos(x),w=Math.sin(x);o=d.cx,a=d.cy;var b="inside"===g||"inner"===g;if("center"===g)n=d.cx,u=d.cy,c="center";else{var S=(b?(d.r+d.r0)/2*_:d.r*_)+o,M=(b?(d.r+d.r0)/2*w:d.r*w)+a;if(n=S+3*_,u=M+3*w,!b){var I=S+_*(v+e-d.r),T=M+w*(v+e-d.r),A=I+(_<0?-1:1)*y,D=T;n=A+(_<0?-5:5),u=D,h=[[S,M],[I,T],[A,D]]}c=b?"center":_>0?"left":"right"}var C=p.getFont(),L=p.get("rotate")?_<0?-x+Math.PI:-x:0,k=ke(t.getFormattedLabel(i,"normal")||r.getName(i),C,c,"top");l=!!L,d.label={x:n,y:u,position:g,height:k.height,len:v,len2:y,linePoints:h,textAlign:c,verticalAlign:"middle",rotation:L,inside:b},b||s.push(d.label)}),!l&&t.get("avoidLabelOverlap")&&Wh(s,o,a,e,i,n)},dC=2*Math.PI,fC=Math.PI/180,pC=function(t){return{seriesType:t,reset:function(t,e){var i=e.findComponents({mainType:"legend"});if(i&&i.length){var n=t.getData();n.filterSelf(function(t){for(var e=n.getName(t),o=0;o=0;s--){var l=2*s,u=n[l]-a/2,h=n[l+1]-r/2;if(t>=u&&e>=h&&t<=u+a&&e<=h+r)return s}return-1}}),mC=Zh.prototype;mC.isPersistent=function(){return!this._incremental},mC.updateData=function(t){this.group.removeAll();var e=new gC({rectHover:!0,cursor:"default"});e.setShape({points:t.getLayout("symbolPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},mC.updateLayout=function(t){if(!this._incremental){var e=t.getLayout("symbolPoints");this.group.eachChild(function(t){if(null!=t.startIndex){var i=2*(t.endIndex-t.startIndex),n=4*t.startIndex*2;e=new Float32Array(e.buffer,n,i)}t.setShape("points",e)})}},mC.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),t.count()>2e6?(this._incremental||(this._incremental=new Hn({silent:!0})),this.group.add(this._incremental)):this._incremental=null},mC.incrementalUpdate=function(t,e){var i;this._incremental?(i=new gC,this._incremental.addDisplayable(i,!0)):((i=new gC({rectHover:!0,cursor:"default",startIndex:t.start,endIndex:t.end})).incremental=!0,this.group.add(i)),i.setShape({points:e.getLayout("symbolPoints")}),this._setCommon(i,e,!!this._incremental)},mC._setCommon=function(t,e,i){var n=e.hostModel,o=e.getVisual("symbolSize");t.setShape("size",o instanceof Array?o:[o,o]),t.symbolProxy=$l(e.getVisual("symbol"),0,0,0,0),t.setColor=t.symbolProxy.setColor;var a=t.shape.size[0]<4;t.useStyle(n.getModel("itemStyle").getItemStyle(a?["color","shadowBlur","shadowColor"]:["color"]));var r=e.getVisual("color");r&&t.setColor(r),i||(t.seriesIndex=n.seriesIndex,t.on("mousemove",function(e){t.dataIndex=null;var i=t.findDataIndex(e.offsetX,e.offsetY);i>=0&&(t.dataIndex=i+(t.startIndex||0))}))},mC.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},mC._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()},Hs({type:"scatter",render:function(t,e,i){var n=t.getData();this._updateSymbolDraw(n,t).updateData(n),this._finished=!0},incrementalPrepareRender:function(t,e,i){var n=t.getData();this._updateSymbolDraw(n,t).incrementalPrepareUpdate(n),this._finished=!1},incrementalRender:function(t,e,i){this._symbolDraw.incrementalUpdate(t,e.getData()),this._finished=t.end===e.getData().count()},updateTransform:function(t,e,i){var n=t.getData();if(this.group.dirty(),!this._finished||n.count()>1e4||!this._symbolDraw.isPersistent())return{update:!0};var o=DD().reset(t);o.progress&&o.progress({start:0,end:n.count()},n),this._symbolDraw.updateLayout(n)},_updateSymbolDraw:function(t,e){var i=this._symbolDraw,n=e.pipelineContext.large;return i&&n===this._isLargeDraw||(i&&i.remove(),i=this._symbolDraw=n?new Zh:new Au,this._isLargeDraw=n,this.group.removeAll()),this.group.add(i.group),i},remove:function(t,e){this._symbolDraw&&this._symbolDraw.remove(!0),this._symbolDraw=null},dispose:function(){}}),zs(AD("scatter","circle")),Rs(DD("scatter")),u(Uh,rD),Xh.prototype.getIndicatorAxes=function(){return this._indicatorAxes},Xh.prototype.dataToPoint=function(t,e){var i=this._indicatorAxes[e];return this.coordToPoint(i.dataToCoord(t),e)},Xh.prototype.coordToPoint=function(t,e){var i=this._indicatorAxes[e].angle;return[this.cx+t*Math.cos(i),this.cy-t*Math.sin(i)]},Xh.prototype.pointToData=function(t){var e=t[0]-this.cx,i=t[1]-this.cy,n=Math.sqrt(e*e+i*i);e/=n,i/=n;for(var o,a=Math.atan2(-i,e),r=1/0,s=-1,l=0;ln[0]&&isFinite(c)&&isFinite(n[0]))}else{r.getTicks().length-1>a&&(u=i(u));var d=Math.round((n[0]+n[1])/2/u)*u,f=Math.round(a/2);r.setExtent(Vo(d-f*u),Vo(d+(a-f)*u)),r.setInterval(u)}})},Xh.dimensions=[],Xh.create=function(t,e){var i=[];return t.eachComponent("radar",function(n){var o=new Xh(n,t,e);i.push(o),n.coordinateSystem=o}),t.eachSeriesByType("radar",function(t){"radar"===t.get("coordinateSystem")&&(t.coordinateSystem=i[t.get("radarIndex")||0])}),i},Ga.register("radar",Xh);var vC=OD.valueAxis,yC=(Gs({type:"radar",optionUpdated:function(){var t=this.get("boundaryGap"),e=this.get("splitNumber"),o=this.get("scale"),s=this.get("axisLine"),l=this.get("axisTick"),u=this.get("axisLabel"),h=this.get("name"),c=this.get("name.show"),d=this.get("name.formatter"),p=this.get("nameGap"),g=this.get("triggerEvent"),m=f(this.get("indicator")||[],function(f){null!=f.max&&f.max>0&&!f.min?f.min=0:null!=f.min&&f.min<0&&!f.max&&(f.max=0);var m=h;if(null!=f.color&&(m=r({color:f.color},h)),f=n(i(f),{boundaryGap:t,splitNumber:e,scale:o,axisLine:s,axisTick:l,axisLabel:u,name:f.text,nameLocation:"end",nameGap:p,nameTextStyle:m,triggerEvent:g},!1),c||(f.name=""),"string"==typeof d){var v=f.name;f.name=d.replace("{value}",null!=v?v:"")}else"function"==typeof d&&(f.name=d(f.name,f));var y=a(new Po(f,null,this.ecModel),XA);return y.mainType="radar",y.componentIndex=this.componentIndex,y},this);this.getIndicatorModels=function(){return m}},defaultOption:{zlevel:0,z:0,center:["50%","50%"],radius:"75%",startAngle:90,name:{show:!0},boundaryGap:[0,0],splitNumber:5,nameGap:15,scale:!1,shape:"polygon",axisLine:n({lineStyle:{color:"#bbb"}},vC.axisLine),axisLabel:jh(vC.axisLabel,!1),axisTick:jh(vC.axisTick,!1),splitLine:jh(vC.splitLine,!0),splitArea:jh(vC.splitArea,!0),indicator:[]}}),["axisLine","axisTickLabel","axisName"]);Fs({type:"radar",render:function(t,e,i){this.group.removeAll(),this._buildAxes(t),this._buildSplitLineAndArea(t)},_buildAxes:function(t){var e=t.coordinateSystem;d(f(e.getIndicatorAxes(),function(t){return new WD(t.model,{position:[e.cx,e.cy],rotation:t.angle,labelDirection:-1,tickDirection:-1,nameDirection:1})}),function(t){d(yC,t.add,t),this.group.add(t.getGroup())},this)},_buildSplitLineAndArea:function(t){function e(t,e,i){var n=i%e.length;return t[n]=t[n]||[],n}var i=t.coordinateSystem,n=i.getIndicatorAxes();if(n.length){var o=t.get("shape"),a=t.getModel("splitLine"),s=t.getModel("splitArea"),l=a.getModel("lineStyle"),u=s.getModel("areaStyle"),h=a.get("show"),c=s.get("show"),p=l.get("color"),g=u.get("color");p=y(p)?p:[p],g=y(g)?g:[g];var m=[],v=[];if("circle"===o)for(var x=n[0].getTicksCoords(),_=i.cx,w=i.cy,b=0;b"+f(i,function(i,n){var o=e.get(e.mapDimension(i.dim),t);return ea(i.name+" : "+o)}).join("
    ")},defaultOption:{zlevel:0,z:2,coordinateSystem:"radar",legendHoverLink:!0,radarIndex:0,lineStyle:{width:2,type:"solid"},label:{position:"top"},symbol:"emptyCircle",symbolSize:4}});Hs({type:"radar",render:function(t,e,n){function o(t,e){var i=t.getItemVisual(e,"symbol")||"circle",n=t.getItemVisual(e,"color");if("none"!==i){var o=Yh(t.getItemVisual(e,"symbolSize")),a=$l(i,-1,-1,2,2,n);return a.attr({style:{strokeNoScale:!0},z2:100,scale:[o[0]/2,o[1]/2]}),a}}function a(e,i,n,a,r,s){n.removeAll();for(var l=0;l"+ea(n+" : "+i)},getTooltipPosition:function(t){if(null!=t){var e=this.getData().getName(t),i=this.coordinateSystem,n=i.getRegion(e);return n&&i.dataToPoint(n.center)}},setZoom:function(t){this.option.zoom=t},setCenter:function(t){this.option.center=t},defaultOption:{zlevel:0,z:2,coordinateSystem:"geo",map:"",left:"center",top:"center",aspectScale:.75,showLegendSymbol:!0,dataRangeHoverLink:!0,boundingCoords:null,center:null,zoom:1,scaleLimit:null,label:{show:!1,color:"#000"},itemStyle:{borderWidth:.5,borderColor:"#444",areaColor:"#eee"},emphasis:{label:{show:!0,color:"rgb(100,0,0)"},itemStyle:{areaColor:"rgba(255,215,0,0.8)"}}}}),rC);var RC="\0_ec_interaction_mutex";Os({type:"takeGlobalCursor",event:"globalCursorTaken",update:"update"},function(){}),h(nc,fw);var zC={axisPointer:1,tooltip:1,brush:1};yc.prototype={constructor:yc,draw:function(t,e,i,n,o){var a="geo"===t.mainType,r=t.getData&&t.getData();a&&e.eachComponent({mainType:"series",subType:"map"},function(e){r||e.getHostGeoModel()!==t||(r=e.getData())});var s=t.coordinateSystem;this._updateBackground(s);var l=this._regionsGroup,u=this.group,h=s.scale,c={position:s.position,scale:h};!l.childAt(0)||o?u.attr(c):Mo(u,c,t),l.removeAll();var f=["itemStyle"],p=["emphasis","itemStyle"],g=["label"],m=["emphasis","label"],v=R();d(s.regions,function(e){var i=v.get(e.name)||v.set(e.name,new tb),n=new MM({shape:{paths:[]}});i.add(n);var o,s=(C=t.getRegionModel(e.name)||t).getModel(f),u=C.getModel(p),c=gc(s),y=gc(u),x=C.getModel(g),_=C.getModel(m);if(r){o=r.indexOfName(e.name);var w=r.getItemVisual(o,"color",!0);w&&(c.fill=w)}d(e.geometries,function(t){if("polygon"===t.type){n.shape.paths.push(new pM({shape:{points:t.exterior}}));for(var e=0;e<(t.interiors?t.interiors.length:0);e++)n.shape.paths.push(new pM({shape:{points:t.interiors[e]}}))}}),n.setStyle(c),n.style.strokeNoScale=!0,n.culling=!0;var b=x.get("show"),S=_.get("show"),M=r&&isNaN(r.get(r.mapDimension("value"),o)),I=r&&r.getItemLayout(o);if(a||M&&(b||S)||I&&I.showLabel){var T,A=a?e.name:o;(!r||o>=0)&&(T=t);var D=new rM({position:e.center.slice(),scale:[1/h[0],1/h[1]],z2:10,silent:!0});po(D.style,D.hoverStyle={},x,_,{labelFetcher:T,labelDataIndex:A,defaultText:e.name,useInsideStyle:!1},{textAlign:"center",textVerticalAlign:"middle"}),i.add(D)}if(r)r.setItemGraphicEl(o,i);else{var C=t.getRegionModel(e.name);n.eventData={componentType:"geo",componentIndex:t.componentIndex,geoIndex:t.componentIndex,name:e.name,region:C&&C.option||{}}}(i.__regions||(i.__regions=[])).push(e),co(i,y,{hoverSilentOnTouch:!!t.get("selectedMode")}),l.add(i)}),this._updateController(t,e,i),mc(this,t,l,i,n),vc(t,l)},remove:function(){this._regionsGroup.removeAll(),this._backgroundGroup.removeAll(),this._controller.dispose(),this._mapName&&EC.removeGraphic(this._mapName,this.uid),this._mapName=null,this._controllerHost={}},_updateBackground:function(t){var e=t.map;this._mapName!==e&&d(EC.makeGraphic(e,this.uid),function(t){this._backgroundGroup.add(t)},this),this._mapName=e},_updateController:function(t,e,i){function n(){var e={type:"geoRoam",componentType:l};return e[l+"Id"]=t.id,e}var o=t.coordinateSystem,r=this._controller,s=this._controllerHost;s.zoomLimit=t.get("scaleLimit"),s.zoom=o.getZoom(),r.enable(t.get("roam")||!1);var l=t.mainType;r.off("pan").on("pan",function(t){this._mouseDownFlag=!1,dc(s,t.dx,t.dy),i.dispatchAction(a(n(),{dx:t.dx,dy:t.dy}))},this),r.off("zoom").on("zoom",function(t){if(this._mouseDownFlag=!1,fc(s,t.scale,t.originX,t.originY),i.dispatchAction(a(n(),{zoom:t.scale,originX:t.originX,originY:t.originY})),this._updateGroup){var e=this.group.scale;this._regionsGroup.traverse(function(t){"text"===t.type&&t.attr("scale",[1/e[0],1/e[1]])})}},this),r.setPointerChecker(function(e,n,a){return o.getViewRectAfterRoam().contain(n,a)&&!pc(e,i,t)})}};var BC="__seriesMapHighDown",VC="__seriesMapCallKey";Hs({type:"map",render:function(t,e,i,n){if(!n||"mapToggleSelect"!==n.type||n.from!==this.uid){var o=this.group;if(o.removeAll(),!t.getHostGeoModel()){if(n&&"geoRoam"===n.type&&"series"===n.componentType&&n.seriesId===t.id)(a=this._mapDraw)&&o.add(a.group);else if(t.needsDrawMap){var a=this._mapDraw||new yc(i,!0);o.add(a.group),a.draw(t,e,i,this,n),this._mapDraw=a}else this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null;t.get("showLegendSymbol")&&e.getComponent("legend")&&this._renderSymbols(t,e,i)}}},remove:function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null,this.group.removeAll()},dispose:function(){this._mapDraw&&this._mapDraw.remove(),this._mapDraw=null},_renderSymbols:function(t,e,i){var n=t.originalData,o=this.group;n.each(n.mapDimension("value"),function(e,i){if(!isNaN(e)){var r=n.getItemLayout(i);if(r&&r.point){var s=r.point,l=r.offset,u=new sM({style:{fill:t.getData().getVisual("color")},shape:{cx:s[0]+9*l,cy:s[1],r:3},silent:!0,z2:8+(l?0:NM+1)});if(!l){var h=t.mainSeries.getData(),c=n.getName(i),d=h.indexOfName(c),f=n.getItemModel(i),p=f.getModel("label"),g=f.getModel("emphasis.label"),m=h.getItemGraphicEl(d),y=A(t.getFormattedLabel(d,"normal"),c),x=A(t.getFormattedLabel(d,"emphasis"),y),_=m[BC],w=Math.random();if(!_){_=m[BC]={};var b=v(xc,!0),S=v(xc,!1);m.on("mouseover",b).on("mouseout",S).on("emphasis",b).on("normal",S)}m[VC]=w,a(_,{recordVersion:w,circle:u,labelModel:p,hoverLabelModel:g,emphasisText:x,normalText:y}),_c(_,!1)}o.add(u)}}})}}),Os({type:"geoRoam",event:"geoRoam",update:"updateTransform"},function(t,e){var i=t.componentType||"series";e.eachComponent({mainType:i,query:t},function(e){var n=e.coordinateSystem;if("geo"===n.type){var o=wc(n,t,e.get("scaleLimit"));e.setCenter&&e.setCenter(o.center),e.setZoom&&e.setZoom(o.zoom),"series"===i&&d(e.seriesGroup,function(t){t.setCenter(o.center),t.setZoom(o.zoom)})}})});var GC=Q;h(bc,Tw),Sc.prototype={constructor:Sc,type:"view",dimensions:["x","y"],setBoundingRect:function(t,e,i,n){return this._rect=new de(t,e,i,n),this._rect},getBoundingRect:function(){return this._rect},setViewRect:function(t,e,i,n){this.transformTo(t,e,i,n),this._viewRect=new de(t,e,i,n)},transformTo:function(t,e,i,n){var o=this.getBoundingRect(),a=this._rawTransformable;a.transform=o.calculateTransform(new de(t,e,i,n)),a.decomposeTransform(),this._updateTransform()},setCenter:function(t){t&&(this._center=t,this._updateCenterAndZoom())},setZoom:function(t){t=t||1;var e=this.zoomLimit;e&&(null!=e.max&&(t=Math.min(e.max,t)),null!=e.min&&(t=Math.max(e.min,t))),this._zoom=t,this._updateCenterAndZoom()},getDefaultCenter:function(){var t=this.getBoundingRect();return[t.x+t.width/2,t.y+t.height/2]},getCenter:function(){return this._center||this.getDefaultCenter()},getZoom:function(){return this._zoom||1},getRoamTransform:function(){return this._roamTransformable.getLocalTransform()},_updateCenterAndZoom:function(){var t=this._rawTransformable.getLocalTransform(),e=this._roamTransformable,i=this.getDefaultCenter(),n=this.getCenter(),o=this.getZoom();n=Q([],n,t),i=Q([],i,t),e.origin=n,e.position=[i[0]-n[0],i[1]-n[1]],e.scale=[o,o],this._updateTransform()},_updateTransform:function(){var t=this._roamTransformable,e=this._rawTransformable;e.parent=t,t.updateTransform(),e.updateTransform(),wt(this.transform||(this.transform=[]),e.transform||xt()),this._rawTransform=e.getLocalTransform(),this.invTransform=this.invTransform||[],Tt(this.invTransform,this.transform),this.decomposeTransform()},getViewRect:function(){return this._viewRect},getViewRectAfterRoam:function(){var t=this.getBoundingRect().clone();return t.applyTransform(this.transform),t},dataToPoint:function(t,e,i){var n=e?this._rawTransform:this.transform;return i=i||[],n?GC(i,t,n):G(i,t)},pointToData:function(t){var e=this.invTransform;return e?GC([],t,e):[t[0],t[1]]},convertToPixel:v(Mc,"dataToPoint"),convertFromPixel:v(Mc,"pointToData"),containPoint:function(t){return this.getViewRectAfterRoam().contain(t[0],t[1])}},h(Sc,Tw),Ic.prototype={constructor:Ic,type:"geo",dimensions:["lng","lat"],containCoord:function(t){for(var e=this.regions,i=0;ie&&(e=n.height)}this.height=e+1},getNodeById:function(t){if(this.getId()===t)return this;for(var e=0,i=this.children,n=i.length;e=0&&this.hostTree.data.setItemLayout(this.dataIndex,t,e)},getLayout:function(){return this.hostTree.data.getItemLayout(this.dataIndex)},getModel:function(t){if(!(this.dataIndex<0)){var e,i=this.hostTree,n=i.data.getItemModel(this.dataIndex),o=this.getLevelModel();return o||0!==this.children.length&&(0===this.children.length||!1!==this.isExpand)||(e=this.getLeavesModel()),n.getModel(t,(o||e||i.hostModel).getModel(t))}},getLevelModel:function(){return(this.hostTree.levelModels||[])[this.depth]},getLeavesModel:function(){return this.hostTree.leavesModel},setVisual:function(t,e){this.dataIndex>=0&&this.hostTree.data.setItemVisual(this.dataIndex,t,e)},getVisual:function(t,e){return this.hostTree.data.getItemVisual(this.dataIndex,t,e)},getRawIndex:function(){return this.hostTree.data.getRawIndex(this.dataIndex)},getId:function(){return this.hostTree.data.getId(this.dataIndex)},isAncestorOf:function(t){for(var e=t.parentNode;e;){if(e===this)return!0;e=e.parentNode}return!1},isDescendantOf:function(t){return t!==this&&t.isAncestorOf(this)}},Bc.prototype={constructor:Bc,type:"tree",eachNode:function(t,e,i){this.root.eachNode(t,e,i)},getNodeByDataIndex:function(t){var e=this.data.getRawIndex(t);return this._nodes[e]},getNodeByName:function(t){return this.root.getNodeByName(t)},update:function(){for(var t=this.data,e=this._nodes,i=0,n=e.length;ia&&(a=t.depth)});var r=t.expandAndCollapse&&t.initialTreeDepth>=0?t.initialTreeDepth:a;return o.root.eachNode("preorder",function(t){var e=t.hostTree.data.getRawDataItem(t.dataIndex);t.isExpand=e&&null!=e.collapsed?!e.collapsed:t.depth<=r}),o.data},getOrient:function(){var t=this.get("orient");return"horizontal"===t?t="LR":"vertical"===t&&(t="TB"),t},setZoom:function(t){this.option.zoom=t},setCenter:function(t){this.option.center=t},formatTooltip:function(t){for(var e=this.getData().tree,i=e.root.children[0],n=e.getNodeByDataIndex(t),o=n.getValue(),a=n.name;n&&n!==i;)a=n.parentNode.name+"."+a,n=n.parentNode;return ea(a+(isNaN(o)||null==o?"":" : "+o))},defaultOption:{zlevel:0,z:2,coordinateSystem:"view",left:"12%",top:"12%",right:"12%",bottom:"12%",layout:"orthogonal",roam:!1,nodeScaleRatio:.4,center:null,zoom:1,orient:"LR",symbol:"emptyCircle",symbolSize:7,expandAndCollapse:!0,initialTreeDepth:2,lineStyle:{color:"#ccc",width:1.5,curveness:.5},itemStyle:{color:"lightsteelblue",borderColor:"#c23531",borderWidth:1.5},label:{show:!0,color:"#555"},leaves:{label:{show:!0}},animationEasing:"linear",animationDuration:700,animationDurationUpdate:1e3}}),Hs({type:"tree",init:function(t,e){this._oldTree,this._mainGroup=new tb,this._controller=new nc(e.getZr()),this._controllerHost={target:this.group},this.group.add(this._mainGroup)},render:function(t,e,i,n){var o=t.getData(),a=t.layoutInfo,r=this._mainGroup,s=t.get("layout");"radial"===s?r.attr("position",[a.x+a.width/2,a.y+a.height/2]):r.attr("position",[a.x,a.y]),this._updateViewCoordSys(t),this._updateController(t,e,i);var l=this._data,u={expandAndCollapse:t.get("expandAndCollapse"),layout:s,orient:t.getOrient(),curvature:t.get("lineStyle.curveness"),symbolRotate:t.get("symbolRotate"),symbolOffset:t.get("symbolOffset"),hoverAnimation:t.get("hoverAnimation"),useNameLabel:!0,fadeIn:!0};o.diff(l).add(function(e){Qc(o,e)&&ed(o,e,null,r,t,u)}).update(function(e,i){var n=l.getItemGraphicEl(i);Qc(o,e)?ed(o,e,n,r,t,u):n&&id(l,i,n,r,t,u)}).remove(function(e){var i=l.getItemGraphicEl(e);i&&id(l,e,i,r,t,u)}).execute(),this._nodeScaleRatio=t.get("nodeScaleRatio"),this._updateNodeAndLinkScale(t),!0===u.expandAndCollapse&&o.eachItemGraphicEl(function(e,n){e.off("click").on("click",function(){i.dispatchAction({type:"treeExpandAndCollapse",seriesId:t.id,dataIndex:n})})}),this._data=o},_updateViewCoordSys:function(t){var e=t.getData(),i=[];e.each(function(t){var n=e.getItemLayout(t);!n||isNaN(n.x)||isNaN(n.y)||i.push([+n.x,+n.y])});var n=[],o=[];dn(i,n,o),o[0]-n[0]==0&&(o[0]+=1,n[0]-=1),o[1]-n[1]==0&&(o[1]+=1,n[1]-=1);var a=t.coordinateSystem=new Sc;a.zoomLimit=t.get("scaleLimit"),a.setBoundingRect(n[0],n[1],o[0]-n[0],o[1]-n[1]),a.setCenter(t.get("center")),a.setZoom(t.get("zoom")),this.group.attr({position:a.position,scale:a.scale}),this._viewCoordSys=a},_updateController:function(t,e,i){var n=this._controller,o=this._controllerHost,a=this.group;n.setPointerChecker(function(e,n,o){var r=a.getBoundingRect();return r.applyTransform(a.transform),r.contain(n,o)&&!pc(e,i,t)}),n.enable(t.get("roam")),o.zoomLimit=t.get("scaleLimit"),o.zoom=t.coordinateSystem.getZoom(),n.off("pan").off("zoom").on("pan",function(e){dc(o,e.dx,e.dy),i.dispatchAction({seriesId:t.id,type:"treeRoam",dx:e.dx,dy:e.dy})},this).on("zoom",function(e){fc(o,e.scale,e.originX,e.originY),i.dispatchAction({seriesId:t.id,type:"treeRoam",zoom:e.scale,originX:e.originX,originY:e.originY}),this._updateNodeAndLinkScale(t)},this)},_updateNodeAndLinkScale:function(t){var e=t.getData(),i=this._getNodeGlobalScale(t),n=[i,i];e.eachItemGraphicEl(function(t,e){t.attr("scale",n)})},_getNodeGlobalScale:function(t){var e=t.coordinateSystem;if("view"!==e.type)return 1;var i=this._nodeScaleRatio,n=e.scale,o=n&&n[0]||1;return((e.getZoom()-1)*i+1)/o},dispose:function(){this._controller&&this._controller.dispose(),this._controllerHost={}},remove:function(){this._mainGroup.removeAll(),this._data=null}}),Os({type:"treeExpandAndCollapse",event:"treeExpandAndCollapse",update:"update"},function(t,e){e.eachComponent({mainType:"series",subType:"tree",query:t},function(e){var i=t.dataIndex,n=e.getData().tree.getNodeByDataIndex(i);n.isExpand=!n.isExpand})}),Os({type:"treeRoam",event:"treeRoam",update:"none"},function(t,e){e.eachComponent({mainType:"series",subType:"tree",query:t},function(e){var i=wc(e.coordinateSystem,t);e.setCenter&&e.setCenter(i.center),e.setZoom&&e.setZoom(i.zoom)})});zs(AD("tree","circle")),Rs(function(t,e){t.eachSeriesByType("tree",function(t){rd(t,e)})}),qI.extend({type:"series.treemap",layoutMode:"box",dependencies:["grid","polar"],_viewRoot:null,defaultOption:{progressive:0,hoverLayerThreshold:1/0,left:"center",top:"middle",right:null,bottom:null,width:"80%",height:"80%",sort:!0,clipWindow:"origin",squareRatio:.5*(1+Math.sqrt(5)),leafDepth:null,drillDownIcon:"▶",zoomToNodeRatio:.1024,roam:!0,nodeClick:"zoomToNode",animation:!0,animationDurationUpdate:900,animationEasing:"quinticInOut",breadcrumb:{show:!0,height:22,left:"center",top:"bottom",emptyItemWidth:25,itemStyle:{color:"rgba(0,0,0,0.7)",borderColor:"rgba(255,255,255,0.7)",borderWidth:1,shadowColor:"rgba(150,150,150,1)",shadowBlur:3,shadowOffsetX:0,shadowOffsetY:0,textStyle:{color:"#fff"}},emphasis:{textStyle:{}}},label:{show:!0,distance:0,padding:5,position:"inside",color:"#fff",ellipsis:!0},upperLabel:{show:!1,position:[0,"50%"],height:20,color:"#fff",ellipsis:!0,verticalAlign:"middle"},itemStyle:{color:null,colorAlpha:null,colorSaturation:null,borderWidth:0,gapWidth:0,borderColor:"#fff",borderColorSaturation:null},emphasis:{upperLabel:{show:!0,position:[0,"50%"],color:"#fff",ellipsis:!0,verticalAlign:"middle"}},visualDimension:0,visualMin:null,visualMax:null,color:[],colorAlpha:null,colorSaturation:null,colorMappingBy:"index",visibleMin:10,childrenVisibleMin:null,levels:[]},getInitialData:function(t,e){var i={name:t.name,children:t.data};cd(i);var n=t.levels||[];n=t.levels=dd(n,e);var o={};return o.levels=n,Bc.createTree(i,this,o).data},optionUpdated:function(){this.resetViewRoot()},formatTooltip:function(t){var e=this.getData(),i=this.getRawValue(t),n=Qo(y(i)?i[0]:i);return ea(e.getName(t)+": "+n)},getDataParams:function(t){var e=qI.prototype.getDataParams.apply(this,arguments),i=this.getData().tree.getNodeByDataIndex(t);return e.treePathInfo=hd(i,this),e},setLayoutInfo:function(t){this.layoutInfo=this.layoutInfo||{},a(this.layoutInfo,t)},mapIdToIndex:function(t){var e=this._idIndexMap;e||(e=this._idIndexMap=R(),this._idIndexMapCount=0);var i=e.get(t);return null==i&&e.set(t,i=this._idIndexMapCount++),i},getViewRoot:function(){return this._viewRoot},resetViewRoot:function(t){t?this._viewRoot=t:t=this._viewRoot;var e=this.getRawData().tree.root;t&&(t===e||e.contains(t))||(this._viewRoot=e)}});var XC=5;fd.prototype={constructor:fd,render:function(t,e,i,n){var o=t.getModel("breadcrumb"),a=this.group;if(a.removeAll(),o.get("show")&&i){var r=o.getModel("itemStyle"),s=r.getModel("textStyle"),l={pos:{left:o.get("left"),right:o.get("right"),top:o.get("top"),bottom:o.get("bottom")},box:{width:e.getWidth(),height:e.getHeight()},emptyItemWidth:o.get("emptyItemWidth"),totalWidth:0,renderList:[]};this._prepare(i,l,s),this._renderContent(t,l,r,s,n),ca(a,l.pos,l.box)}},_prepare:function(t,e,i){for(var n=t;n;n=n.parentNode){var o=n.getModel().get("name"),a=i.getTextRect(o),r=Math.max(a.width+16,e.emptyItemWidth);e.totalWidth+=r+8,e.renderList.push({node:n,text:o,width:r})}},_renderContent:function(t,e,i,n,o){for(var a=0,s=e.emptyItemWidth,l=t.get("breadcrumb.height"),u=ua(e.pos,e.box),h=e.totalWidth,c=e.renderList,d=c.length-1;d>=0;d--){var f=c[d],p=f.node,g=f.width,m=f.text;h>u.width&&(h-=g-s,g=s,m=null);var y=new pM({shape:{points:pd(a,0,g,l,d===c.length-1,0===d)},style:r(i.getItemStyle(),{lineJoin:"bevel",text:m,textFill:n.getTextColor(),textFont:n.getFont()}),z:10,onclick:v(o,p)});this.group.add(y),gd(y,t,p),a+=g+8}},remove:function(){this.group.removeAll()}};var jC=m,YC=tb,qC=yM,KC=d,$C=["label"],JC=["emphasis","label"],QC=["upperLabel"],tL=["emphasis","upperLabel"],eL=10,iL=1,nL=2,oL=Qb([["fill","color"],["stroke","strokeColor"],["lineWidth","strokeWidth"],["shadowBlur"],["shadowOffsetX"],["shadowOffsetY"],["shadowColor"]]),aL=function(t){var e=oL(t);return e.stroke=e.fill=e.lineWidth=null,e};Hs({type:"treemap",init:function(t,e){this._containerGroup,this._storage={nodeGroup:[],background:[],content:[]},this._oldTree,this._breadcrumb,this._controller,this._state="ready"},render:function(t,e,i,n){if(!(l(e.findComponents({mainType:"series",subType:"treemap",query:n}),t)<0)){this.seriesModel=t,this.api=i,this.ecModel=e;var o=sd(n,["treemapZoomToNode","treemapRootToNode"],t),a=n&&n.type,r=t.layoutInfo,s=!this._oldTree,u=this._storage,h="treemapRootToNode"===a&&o&&u?{rootNodeGroup:u.nodeGroup[o.node.getRawIndex()],direction:n.direction}:null,c=this._giveContainerGroup(r),d=this._doRender(c,t,h);s||a&&"treemapZoomToNode"!==a&&"treemapRootToNode"!==a?d.renderFinally():this._doAnimation(c,d,t,h),this._resetController(i),this._renderBreadcrumb(t,i,o)}},_giveContainerGroup:function(t){var e=this._containerGroup;return e||(e=this._containerGroup=new YC,this._initEvents(e),this.group.add(e)),e.attr("position",[t.x,t.y]),e},_doRender:function(t,e,i){function n(t,e,i,o,a){function r(t){return t.getId()}function s(r,s){var l=null!=r?t[r]:null,u=null!=s?e[s]:null,c=h(l,u,i,a);c&&n(l&&l.viewChildren||[],u&&u.viewChildren||[],c,o,a+1)}o?(e=t,KC(t,function(t,e){!t.isRemoved()&&s(e,e)})):new Us(e,t,r,r).add(s).update(s).remove(v(s,null)).execute()}var o=e.getData().tree,a=this._oldTree,r={nodeGroup:[],background:[],content:[]},s={nodeGroup:[],background:[],content:[]},l=this._storage,u=[],h=v(vd,e,s,l,i,r,u);n(o.root?[o.root]:[],a&&a.root?[a.root]:[],t,o===a||!a,0);var c=function(t){var e={nodeGroup:[],background:[],content:[]};return t&&KC(t,function(t,i){var n=e[i];KC(t,function(t){t&&(n.push(t),t.__tmWillDelete=1)})}),e}(l);return this._oldTree=o,this._storage=s,{lastsForAnimation:r,willDeleteEls:c,renderFinally:function(){KC(c,function(t){KC(t,function(t){t.parent&&t.parent.remove(t)})}),KC(u,function(t){t.invisible=!0,t.dirty()})}}},_doAnimation:function(t,e,i,n){if(i.get("animation")){var o=i.get("animationDurationUpdate"),r=i.get("animationEasing"),s=md();KC(e.willDeleteEls,function(t,e){KC(t,function(t,i){if(!t.invisible){var a,l=t.parent;if(n&&"drillDown"===n.direction)a=l===n.rootNodeGroup?{shape:{x:0,y:0,width:l.__tmNodeWidth,height:l.__tmNodeHeight},style:{opacity:0}}:{style:{opacity:0}};else{var u=0,h=0;l.__tmWillDelete||(u=l.__tmNodeWidth/2,h=l.__tmNodeHeight/2),a="nodeGroup"===e?{position:[u,h],style:{opacity:0}}:{shape:{x:u,y:h,width:0,height:0},style:{opacity:0}}}a&&s.add(t,a,o,r)}})}),KC(this._storage,function(t,i){KC(t,function(t,n){var l=e.lastsForAnimation[i][n],u={};l&&("nodeGroup"===i?l.old&&(u.position=t.position.slice(),t.attr("position",l.old)):(l.old&&(u.shape=a({},t.shape),t.setShape(l.old)),l.fadein?(t.setStyle("opacity",0),u.style={opacity:1}):1!==t.style.opacity&&(u.style={opacity:1})),s.add(t,u,o,r))})},this),this._state="animating",s.done(jC(function(){this._state="ready",e.renderFinally()},this)).start()}},_resetController:function(t){var e=this._controller;e||((e=this._controller=new nc(t.getZr())).enable(this.seriesModel.get("roam")),e.on("pan",jC(this._onPan,this)),e.on("zoom",jC(this._onZoom,this)));var i=new de(0,0,t.getWidth(),t.getHeight());e.setPointerChecker(function(t,e,n){return i.contain(e,n)})},_clearController:function(){var t=this._controller;t&&(t.dispose(),t=null)},_onPan:function(t){if("animating"!==this._state&&(Math.abs(t.dx)>3||Math.abs(t.dy)>3)){var e=this.seriesModel.getData().tree.root;if(!e)return;var i=e.getLayout();if(!i)return;this.api.dispatchAction({type:"treemapMove",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:i.x+t.dx,y:i.y+t.dy,width:i.width,height:i.height}})}},_onZoom:function(t){var e=t.originX,i=t.originY;if("animating"!==this._state){var n=this.seriesModel.getData().tree.root;if(!n)return;var o=n.getLayout();if(!o)return;var a=new de(o.x,o.y,o.width,o.height),r=this.seriesModel.layoutInfo;e-=r.x,i-=r.y;var s=xt();St(s,s,[-e,-i]),It(s,s,[t.scale,t.scale]),St(s,s,[e,i]),a.applyTransform(s),this.api.dispatchAction({type:"treemapRender",from:this.uid,seriesId:this.seriesModel.id,rootRect:{x:a.x,y:a.y,width:a.width,height:a.height}})}},_initEvents:function(t){t.on("click",function(t){if("ready"===this._state){var e=this.seriesModel.get("nodeClick",!0);if(e){var i=this.findTarget(t.offsetX,t.offsetY);if(i){var n=i.node;if(n.getLayout().isLeafRoot)this._rootToNode(i);else if("zoomToNode"===e)this._zoomToNode(i);else if("link"===e){var o=n.hostTree.data.getItemModel(n.dataIndex),a=o.get("link",!0),r=o.get("target",!0)||"blank";a&&window.open(a,r)}}}}},this)},_renderBreadcrumb:function(t,e,i){i||(i=null!=t.get("leafDepth",!0)?{node:t.getViewRoot()}:this.findTarget(e.getWidth()/2,e.getHeight()/2))||(i={node:t.getData().tree.root}),(this._breadcrumb||(this._breadcrumb=new fd(this.group))).render(t,e,i.node,jC(function(e){"animating"!==this._state&&(ud(t.getViewRoot(),e)?this._rootToNode({node:e}):this._zoomToNode({node:e}))},this))},remove:function(){this._clearController(),this._containerGroup&&this._containerGroup.removeAll(),this._storage={nodeGroup:[],background:[],content:[]},this._state="ready",this._breadcrumb&&this._breadcrumb.remove()},dispose:function(){this._clearController()},_zoomToNode:function(t){this.api.dispatchAction({type:"treemapZoomToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},_rootToNode:function(t){this.api.dispatchAction({type:"treemapRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t.node})},findTarget:function(t,e){var i;return this.seriesModel.getViewRoot().eachNode({attr:"viewChildren",order:"preorder"},function(n){var o=this._storage.background[n.getRawIndex()];if(o){var a=o.transformCoordToLocal(t,e),r=o.shape;if(!(r.x<=a[0]&&a[0]<=r.x+r.width&&r.y<=a[1]&&a[1]<=r.y+r.height))return!1;i={node:n,offsetX:a[0],offsetY:a[1]}}},this),i}});for(var rL=["treemapZoomToNode","treemapRender","treemapMove"],sL=0;sL=0&&t.call(e,i[o],o)},AL.eachEdge=function(t,e){for(var i=this.edges,n=i.length,o=0;o=0&&i[o].node1.dataIndex>=0&&i[o].node2.dataIndex>=0&&t.call(e,i[o],o)},AL.breadthFirstTraverse=function(t,e,i,n){if($d.isInstance(e)||(e=this._nodesMap[Kd(e)]),e){for(var o="out"===i?"outEdges":"in"===i?"inEdges":"edges",a=0;a=0&&i.node2.dataIndex>=0});for(var o=0,a=n.length;o=0&&this[t][e].setItemVisual(this.dataIndex,i,n)},getVisual:function(i,n){return this[t][e].getItemVisual(this.dataIndex,i,n)},setLayout:function(i,n){this.dataIndex>=0&&this[t][e].setItemLayout(this.dataIndex,i,n)},getLayout:function(){return this[t][e].getItemLayout(this.dataIndex)},getGraphicEl:function(){return this[t][e].getItemGraphicEl(this.dataIndex)},getRawIndex:function(){return this[t][e].getRawIndex(this.dataIndex)}}};h($d,DL("hostGraph","data")),h(Jd,DL("hostGraph","edgeData")),TL.Node=$d,TL.Edge=Jd,ji($d),ji(Jd);var CL=function(t,e,i,n,o){for(var a=new TL(n),r=0;r "+f)),h++)}var p,g=i.get("coordinateSystem");if("cartesian2d"===g||"polar"===g)p=gl(t,i);else{var m=Ga.get(g),v=m&&"view"!==m.type?m.dimensions||[]:[];l(v,"value")<0&&v.concat(["value"]);var y=wA(t,{coordDimensions:v});(p=new yA(y,i)).initData(t)}var x=new yA(["value"],i);return x.initData(u,s),o&&o(p,x),Lc({mainData:p,struct:a,structAttr:"graph",datas:{node:p,edge:x},datasAttr:{node:"data",edge:"edgeData"}}),a.update(),a},LL=Ws({type:"series.graph",init:function(t){LL.superApply(this,"init",arguments),this.legendDataProvider=function(){return this._categoriesData},this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},mergeOption:function(t){LL.superApply(this,"mergeOption",arguments),this.fillDataTextStyle(t.edges||t.links),this._updateCategoriesData()},mergeDefaultAndTheme:function(t){LL.superApply(this,"mergeDefaultAndTheme",arguments),Ci(t,["edgeLabel"],["show"])},getInitialData:function(t,e){var i=t.edges||t.links||[],n=t.data||t.nodes||[],o=this;if(n&&i)return CL(n,i,this,!0,function(t,i){function n(t){return(t=this.parsePath(t))&&"label"===t[0]?r:t&&"emphasis"===t[0]&&"label"===t[1]?l:this.parentModel}t.wrapMethod("getItemModel",function(t){var e=o._categoriesModels[t.getShallow("category")];return e&&(e.parentModel=t.parentModel,t.parentModel=e),t});var a=o.getModel("edgeLabel"),r=new Po({label:a.option},a.parentModel,e),s=o.getModel("emphasis.edgeLabel"),l=new Po({emphasis:{label:s.option}},s.parentModel,e);i.wrapMethod("getItemModel",function(t){return t.customizeGetParent(n),t})}).data},getGraph:function(){return this.getData().graph},getEdgeData:function(){return this.getGraph().edgeData},getCategoriesData:function(){return this._categoriesData},formatTooltip:function(t,e,i){if("edge"===i){var n=this.getData(),o=this.getDataParams(t,i),a=n.graph.getEdgeByIndex(t),r=n.getName(a.node1.dataIndex),s=n.getName(a.node2.dataIndex),l=[];return null!=r&&l.push(r),null!=s&&l.push(s),l=ea(l.join(" > ")),o.value&&(l+=" : "+ea(o.value)),l}return LL.superApply(this,"formatTooltip",arguments)},_updateCategoriesData:function(){var t=f(this.option.categories||[],function(t){return null!=t.value?t:a({value:0},t)}),e=new yA(["value"],this);e.initData(t),this._categoriesData=e,this._categoriesModels=e.mapArray(function(t){return e.getItemModel(t,!0)})},setZoom:function(t){this.option.zoom=t},setCenter:function(t){this.option.center=t},isAnimationEnabled:function(){return LL.superCall(this,"isAnimationEnabled")&&!("force"===this.get("layout")&&this.get("force.layoutAnimation"))},defaultOption:{zlevel:0,z:2,coordinateSystem:"view",legendHoverLink:!0,hoverAnimation:!0,layout:null,focusNodeAdjacency:!1,circular:{rotateLabel:!1},force:{initLayout:null,repulsion:[0,50],gravity:.1,edgeLength:30,layoutAnimation:!0},left:"center",top:"center",symbol:"circle",symbolSize:10,edgeSymbol:["none","none"],edgeSymbolSize:10,edgeLabel:{position:"middle"},draggable:!1,roam:!1,center:null,zoom:1,nodeScaleRatio:.6,label:{show:!1,formatter:"{b}"},itemStyle:{},lineStyle:{color:"#aaa",width:1,curveness:0,opacity:.5},emphasis:{label:{show:!0}}}}),kL=_M.prototype,PL=bM.prototype,NL=Zn({type:"ec-line",style:{stroke:"#000",fill:null},shape:{x1:0,y1:0,x2:0,y2:0,percent:1,cpx1:null,cpy1:null},buildPath:function(t,e){(Qd(e)?kL:PL).buildPath(t,e)},pointAt:function(t){return Qd(this.shape)?kL.pointAt.call(this,t):PL.pointAt.call(this,t)},tangentAt:function(t){var e=this.shape,i=Qd(e)?[e.x2-e.x1,e.y2-e.y1]:PL.tangentAt.call(this,t);return q(i,i)}}),OL=["fromSymbol","toSymbol"],EL=af.prototype;EL.beforeUpdate=function(){var t=this,e=t.childOfName("fromSymbol"),i=t.childOfName("toSymbol"),n=t.childOfName("label");if(e||i||!n.ignore){for(var o=1,a=this.parent;a;)a.scale&&(o/=a.scale[0]),a=a.parent;var r=t.childOfName("line");if(this.__dirty||r.__dirty){var s=r.shape.percent,l=r.pointAt(0),u=r.pointAt(s),h=U([],u,l);if(q(h,h),e&&(e.attr("position",l),c=r.tangentAt(0),e.attr("rotation",Math.PI/2-Math.atan2(c[1],c[0])),e.attr("scale",[o*s,o*s])),i){i.attr("position",u);var c=r.tangentAt(1);i.attr("rotation",-Math.PI/2-Math.atan2(c[1],c[0])),i.attr("scale",[o*s,o*s])}if(!n.ignore){n.attr("position",u);var d,f,p,g=5*o;if("end"===n.__position)d=[h[0]*g+u[0],h[1]*g+u[1]],f=h[0]>.8?"left":h[0]<-.8?"right":"center",p=h[1]>.8?"top":h[1]<-.8?"bottom":"middle";else if("middle"===n.__position){var m=s/2,v=[(c=r.tangentAt(m))[1],-c[0]],y=r.pointAt(m);v[1]>0&&(v[0]=-v[0],v[1]=-v[1]),d=[y[0]+v[0]*g,y[1]+v[1]*g],f="center",p="bottom";var x=-Math.atan2(c[1],c[0]);u[0].8?"right":h[0]<-.8?"left":"center",p=h[1]>.8?"bottom":h[1]<-.8?"top":"middle";n.attr({style:{textVerticalAlign:n.__verticalAlign||p,textAlign:n.__textAlign||f},position:d,scale:[o,o]})}}}},EL._createLine=function(t,e,i){var n=t.hostModel,o=nf(t.getItemLayout(e));o.shape.percent=0,Io(o,{shape:{percent:1}},n,e),this.add(o);var a=new rM({name:"label",lineLabelOriginalOpacity:1});this.add(a),d(OL,function(i){var n=ef(i,t,e);this.add(n),this[tf(i)]=t.getItemVisual(e,i)},this),this._updateCommonStl(t,e,i)},EL.updateData=function(t,e,i){var n=t.hostModel,o=this.childOfName("line"),a=t.getItemLayout(e),r={shape:{}};of(r.shape,a),Mo(o,r,n,e),d(OL,function(i){var n=t.getItemVisual(e,i),o=tf(i);if(this[o]!==n){this.remove(this.childOfName(i));var a=ef(i,t,e);this.add(a)}this[o]=n},this),this._updateCommonStl(t,e,i)},EL._updateCommonStl=function(t,e,i){var n=t.hostModel,o=this.childOfName("line"),a=i&&i.lineStyle,s=i&&i.hoverLineStyle,l=i&&i.labelModel,u=i&&i.hoverLabelModel;if(!i||t.hasItemOption){var h=t.getItemModel(e);a=h.getModel("lineStyle").getLineStyle(),s=h.getModel("emphasis.lineStyle").getLineStyle(),l=h.getModel("label"),u=h.getModel("emphasis.label")}var c=t.getItemVisual(e,"color"),f=D(t.getItemVisual(e,"opacity"),a.opacity,1);o.useStyle(r({strokeNoScale:!0,fill:"none",stroke:c,opacity:f},a)),o.hoverStyle=s,d(OL,function(t){var e=this.childOfName(t);e&&(e.setColor(c),e.setStyle({opacity:f}))},this);var p,g,m=l.getShallow("show"),v=u.getShallow("show"),y=this.childOfName("label");if((m||v)&&(p=c||"#000",null==(g=n.getFormattedLabel(e,"normal",t.dataType)))){var x=n.getRawValue(e);g=null==x?t.getName(e):isFinite(x)?Vo(x):x}var _=m?g:null,w=v?A(n.getFormattedLabel(e,"emphasis",t.dataType),g):null,b=y.style;null==_&&null==w||(go(y.style,l,{text:_},{autoColor:p}),y.__textAlign=b.textAlign,y.__verticalAlign=b.textVerticalAlign,y.__position=l.get("position")||"middle"),y.hoverStyle=null!=w?{text:w,textFill:u.getTextColor(!0),fontStyle:u.getShallow("fontStyle"),fontWeight:u.getShallow("fontWeight"),fontSize:u.getShallow("fontSize"),fontFamily:u.getShallow("fontFamily")}:{text:null},y.ignore=!m&&!v,co(this)},EL.highlight=function(){this.trigger("emphasis")},EL.downplay=function(){this.trigger("normal")},EL.updateLayout=function(t,e){this.setLinePoints(t.getItemLayout(e))},EL.setLinePoints=function(t){var e=this.childOfName("line");of(e.shape,t),e.dirty()},u(af,tb);var RL=rf.prototype;RL.isPersistent=function(){return!0},RL.updateData=function(t){var e=this,i=e.group,n=e._lineData;e._lineData=t,n||i.removeAll();var o=uf(t);t.diff(n).add(function(i){sf(e,t,i,o)}).update(function(i,a){lf(e,n,t,a,i,o)}).remove(function(t){i.remove(n.getItemGraphicEl(t))}).execute()},RL.updateLayout=function(){var t=this._lineData;t&&t.eachItemGraphicEl(function(e,i){e.updateLayout(t,i)},this)},RL.incrementalPrepareUpdate=function(t){this._seriesScope=uf(t),this._lineData=null,this.group.removeAll()},RL.incrementalUpdate=function(t,e){for(var i=t.start;i=o/3?1:2),l=e.y-n(r)*a*(a>=o/3?1:2);r=e.angle-Math.PI/2,t.moveTo(s,l),t.lineTo(e.x+i(r)*a,e.y+n(r)*a),t.lineTo(e.x+i(e.angle)*o,e.y+n(e.angle)*o),t.lineTo(e.x-i(r)*a,e.y-n(r)*a),t.lineTo(s,l)}}),qL=2*Math.PI,KL=(Tr.extend({type:"gauge",render:function(t,e,i){this.group.removeAll();var n=t.get("axisLine.lineStyle.color"),o=bf(t,i);this._renderMain(t,e,i,n,o)},dispose:function(){},_renderMain:function(t,e,i,n,o){for(var a=this.group,r=t.getModel("axisLine").getModel("lineStyle"),s=t.get("clockwise"),l=-t.get("startAngle")/180*Math.PI,u=-t.get("endAngle")/180*Math.PI,h=(u-l)%qL,c=l,d=r.get("width"),f=0;f=t&&(0===e?0:n[e-1][0]).4?"bottom":"middle",textAlign:A<-.4?"left":A>.4?"right":"center"},{autoColor:P}),silent:!0}))}if(g.get("show")&&T!==v){for(var N=0;N<=y;N++){var A=Math.cos(w),D=Math.sin(w),O=new _M({shape:{x1:A*c+u,y1:D*c+h,x2:A*(c-_)+u,y2:D*(c-_)+h},silent:!0,style:I});"auto"===I.stroke&&O.setStyle({stroke:n((T+N/y)/v)}),l.add(O),w+=S}w-=S}else w+=b}},_renderPointer:function(t,e,i,n,o,a,r,s){var l=this.group,u=this._data;if(t.get("pointer.show")){var h=[+t.get("min"),+t.get("max")],c=[a,r],d=t.getData(),f=d.mapDimension("value");d.diff(u).add(function(e){var i=new YL({shape:{angle:a}});Io(i,{shape:{angle:zo(d.get(f,e),h,c,!0)}},t),l.add(i),d.setItemGraphicEl(e,i)}).update(function(e,i){var n=u.getItemGraphicEl(i);Mo(n,{shape:{angle:zo(d.get(f,e),h,c,!0)}},t),l.add(n),d.setItemGraphicEl(e,n)}).remove(function(t){var e=u.getItemGraphicEl(t);l.remove(e)}).execute(),d.eachItemGraphicEl(function(t,e){var i=d.getItemModel(e),a=i.getModel("pointer");t.setShape({x:o.cx,y:o.cy,width:Bo(a.get("width"),o.r),r:Bo(a.get("length"),o.r)}),t.useStyle(i.getModel("itemStyle").getItemStyle()),"auto"===t.style.fill&&t.setStyle("fill",n(zo(d.get(f,e),h,[0,1],!0))),co(t,i.getModel("emphasis.itemStyle").getItemStyle())}),this._data=d}else u&&u.eachItemGraphicEl(function(t){l.remove(t)})},_renderTitle:function(t,e,i,n,o){var a=t.getData(),r=a.mapDimension("value"),s=t.getModel("title");if(s.get("show")){var l=s.get("offsetCenter"),u=o.cx+Bo(l[0],o.r),h=o.cy+Bo(l[1],o.r),c=+t.get("min"),d=+t.get("max"),f=n(zo(t.getData().get(r,0),[c,d],[0,1],!0));this.group.add(new rM({silent:!0,style:go({},s,{x:u,y:h,text:a.getName(0),textAlign:"center",textVerticalAlign:"middle"},{autoColor:f,forceRich:!0})}))}},_renderDetail:function(t,e,i,n,o){var a=t.getModel("detail"),r=+t.get("min"),s=+t.get("max");if(a.get("show")){var l=a.get("offsetCenter"),u=o.cx+Bo(l[0],o.r),h=o.cy+Bo(l[1],o.r),c=Bo(a.get("width"),o.r),d=Bo(a.get("height"),o.r),f=t.getData(),p=f.get(f.mapDimension("value"),0),g=n(zo(p,[r,s],[0,1],!0));this.group.add(new rM({silent:!0,style:go({},a,{x:u,y:h,text:Sf(p,a.get("formatter")),textWidth:isNaN(c)?null:c,textHeight:isNaN(d)?null:d,textAlign:"center",textVerticalAlign:"middle"},{autoColor:g,forceRich:!0})}))}}}),Ws({type:"series.funnel",init:function(t){KL.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()},this._defaultLabelLine(t)},getInitialData:function(t,e){return aC(this,["value"])},_defaultLabelLine:function(t){Ci(t,"labelLine",["show"]);var e=t.labelLine,i=t.emphasis.labelLine;e.show=e.show&&t.label.show,i.show=i.show&&t.emphasis.label.show},getDataParams:function(t){var e=this.getData(),i=KL.superCall(this,"getDataParams",t),n=e.mapDimension("value"),o=e.getSum(n);return i.percent=o?+(e.get(n,t)/o*100).toFixed(2):0,i.$vars.push("percent"),i},defaultOption:{zlevel:0,z:2,legendHoverLink:!0,left:80,top:60,right:80,bottom:60,minSize:"0%",maxSize:"100%",sort:"descending",gap:0,funnelAlign:"center",label:{show:!0,position:"outer"},labelLine:{show:!0,length:20,lineStyle:{width:1,type:"solid"}},itemStyle:{borderColor:"#fff",borderWidth:1},emphasis:{label:{show:!0}}}})),$L=Mf.prototype,JL=["itemStyle","opacity"];$L.updateData=function(t,e,i){var n=this.childAt(0),o=t.hostModel,a=t.getItemModel(e),s=t.getItemLayout(e),l=t.getItemModel(e).get(JL);l=null==l?1:l,n.useStyle({}),i?(n.setShape({points:s.points}),n.setStyle({opacity:0}),Io(n,{style:{opacity:l}},o,e)):Mo(n,{style:{opacity:l},shape:{points:s.points}},o,e);var u=a.getModel("itemStyle"),h=t.getItemVisual(e,"color");n.setStyle(r({lineJoin:"round",fill:h},u.getItemStyle(["opacity"]))),n.hoverStyle=u.getModel("emphasis").getItemStyle(),this._updateLabel(t,e),co(this)},$L._updateLabel=function(t,e){var i=this.childAt(1),n=this.childAt(2),o=t.hostModel,a=t.getItemModel(e),r=t.getItemLayout(e).label,s=t.getItemVisual(e,"color");Mo(i,{shape:{points:r.linePoints||r.linePoints}},o,e),Mo(n,{style:{x:r.x,y:r.y}},o,e),n.attr({rotation:r.rotation,origin:[r.x,r.y],z2:10});var l=a.getModel("label"),u=a.getModel("emphasis.label"),h=a.getModel("labelLine"),c=a.getModel("emphasis.labelLine"),s=t.getItemVisual(e,"color");po(n.style,n.hoverStyle={},l,u,{labelFetcher:t.hostModel,labelDataIndex:e,defaultText:t.getName(e),autoColor:s,useInsideStyle:!!r.inside},{textAlign:r.textAlign,textVerticalAlign:r.verticalAlign}),n.ignore=n.normalIgnore=!l.get("show"),n.hoverIgnore=!u.get("show"),i.ignore=i.normalIgnore=!h.get("show"),i.hoverIgnore=!c.get("show"),i.setStyle({stroke:s}),i.setStyle(h.getModel("lineStyle").getLineStyle()),i.hoverStyle=c.getModel("lineStyle").getLineStyle()},u(Mf,tb);Tr.extend({type:"funnel",render:function(t,e,i){var n=t.getData(),o=this._data,a=this.group;n.diff(o).add(function(t){var e=new Mf(n,t);n.setItemGraphicEl(t,e),a.add(e)}).update(function(t,e){var i=o.getItemGraphicEl(e);i.updateData(n,t),a.add(i),n.setItemGraphicEl(t,i)}).remove(function(t){var e=o.getItemGraphicEl(t);a.remove(e)}).execute(),this._data=n},remove:function(){this.group.removeAll(),this._data=null},dispose:function(){}});zs(hC("funnel")),Rs(function(t,e,i){t.eachSeriesByType("funnel",function(t){var i=t.getData(),n=i.mapDimension("value"),o=t.get("sort"),a=If(t,e),r=Tf(i,o),s=[Bo(t.get("minSize"),a.width),Bo(t.get("maxSize"),a.width)],l=i.getDataExtent(n),u=t.get("min"),h=t.get("max");null==u&&(u=Math.min(l[0],0)),null==h&&(h=l[1]);var c=t.get("funnelAlign"),d=t.get("gap"),f=(a.height-d*(i.count()-1))/i.count(),p=a.y,g=function(t,e){var o,r=zo(i.get(n,t)||0,[u,h],s,!0);switch(c){case"left":o=a.x;break;case"center":o=a.x+(a.width-r)/2;break;case"right":o=a.x+a.width-r}return[[o,e],[o+r,e]]};"ascending"===o&&(f=-f,d=-d,p+=a.height,r=r.reverse());for(var m=0;ma&&(e[1-n]=e[n]+h.sign*a),e},ek=d,ik=Math.min,nk=Math.max,ok=Math.floor,ak=Math.ceil,rk=Vo,sk=Math.PI;Pf.prototype={type:"parallel",constructor:Pf,_init:function(t,e,i){var n=t.dimensions,o=t.parallelAxisIndex;ek(n,function(t,i){var n=o[i],a=e.getComponent("parallelAxis",n),r=this._axesMap.set(t,new QL(t,Wl(a),[0,0],a.get("type"),n)),s="category"===r.type;r.onBand=s&&a.get("boundaryGap"),r.inverse=a.get("inverse"),a.axis=r,r.model=a,r.coordinateSystem=a.coordinateSystem=this},this)},update:function(t,e){this._updateAxesFromSeries(this._model,t)},containPoint:function(t){var e=this._makeLayoutInfo(),i=e.axisBase,n=e.layoutBase,o=e.pixelDimIndex,a=t[1-o],r=t[o];return a>=i&&a<=i+e.axisLength&&r>=n&&r<=n+e.layoutLength},getModel:function(){return this._model},_updateAxesFromSeries:function(t,e){e.eachSeries(function(i){if(t.contains(i,e)){var n=i.getData();ek(this.dimensions,function(t){var e=this._axesMap.get(t);e.scale.unionExtentFromData(n,n.mapDimension(t)),Fl(e.scale,e.model)},this)}},this)},resize:function(t,e){this._rect=ha(t.getBoxLayoutParams(),{width:e.getWidth(),height:e.getHeight()}),this._layoutAxes()},getRect:function(){return this._rect},_makeLayoutInfo:function(){var t,e=this._model,i=this._rect,n=["x","y"],o=["width","height"],a=e.get("layout"),r="horizontal"===a?0:1,s=i[o[r]],l=[0,s],u=this.dimensions.length,h=Nf(e.get("axisExpandWidth"),l),c=Nf(e.get("axisExpandCount")||0,[0,u]),d=e.get("axisExpandable")&&u>3&&u>c&&c>1&&h>0&&s>0,f=e.get("axisExpandWindow");f?(t=Nf(f[1]-f[0],l),f[1]=f[0]+t):(t=Nf(h*(c-1),l),(f=[h*(e.get("axisExpandCenter")||ok(u/2))-t/2])[1]=f[0]+t);var p=(s-t)/(u-c);p<3&&(p=0);var g=[ok(rk(f[0]/h,1))+1,ak(rk(f[1]/h,1))-1],m=p/h*f[0];return{layout:a,pixelDimIndex:r,layoutBase:i[n[r]],layoutLength:s,axisBase:i[n[1-r]],axisLength:i[o[1-r]],axisExpandable:d,axisExpandWidth:h,axisCollapseWidth:p,axisExpandWindow:f,axisCount:u,winInnerIndices:g,axisExpandWindow0Pos:m}},_layoutAxes:function(){var t=this._rect,e=this._axesMap,i=this.dimensions,n=this._makeLayoutInfo(),o=n.layout;e.each(function(t){var e=[0,n.axisLength],i=t.inverse?1:0;t.setExtent(e[i],e[1-i])}),ek(i,function(e,i){var a=(n.axisExpandable?Ef:Of)(i,n),r={horizontal:{x:a.position,y:n.axisLength},vertical:{x:0,y:a.position}},s={horizontal:sk/2,vertical:0},l=[r[o].x+t.x,r[o].y+t.y],u=s[o],h=xt();Mt(h,h,u),St(h,h,l),this._axesLayout[e]={position:l,rotation:u,transform:h,axisNameAvailableWidth:a.axisNameAvailableWidth,axisLabelShow:a.axisLabelShow,nameTruncateMaxWidth:a.nameTruncateMaxWidth,tickDirection:1,labelDirection:1}},this)},getAxis:function(t){return this._axesMap.get(t)},dataToPoint:function(t,e){return this.axisCoordToPoint(this._axesMap.get(e).dataToCoord(t),e)},eachActiveState:function(t,e,i,n){null==i&&(i=0),null==n&&(n=t.count());var o=this._axesMap,a=this.dimensions,r=[],s=[];d(a,function(e){r.push(t.mapDimension(e)),s.push(o.get(e).model)});for(var l=this.hasAxisBrushed(),u=i;uo*(1-h[0])?(l="jump",r=s-o*(1-h[2])):(r=s-o*h[1])>=0&&(r=s-o*(1-h[1]))<=0&&(r=0),(r*=e.axisExpandWidth/u)?tk(r,n,a,"all"):l="none";else{o=n[1]-n[0];(n=[nk(0,a[1]*s/o-o/2)])[1]=ik(a[1],n[0]+o),n[0]=n[1]-o}return{axisExpandWindow:n,behavior:l}}},Ga.register("parallel",{create:function(t,e){var i=[];return t.eachComponent("parallel",function(n,o){var a=new Pf(n,t,e);a.name="parallel_"+o,a.resize(n,e),n.coordinateSystem=a,a.model=n,i.push(a)}),t.eachSeries(function(e){if("parallel"===e.get("coordinateSystem")){var i=t.queryComponents({mainType:"parallel",index:e.get("parallelIndex"),id:e.get("parallelId")})[0];e.coordinateSystem=i.coordinateSystem}}),i}});var lk=uI.extend({type:"baseParallelAxis",axis:null,activeIntervals:[],getAreaSelectStyle:function(){return Qb([["fill","color"],["lineWidth","borderWidth"],["stroke","borderColor"],["width","width"],["opacity","opacity"]])(this.getModel("areaSelectStyle"))},setActiveIntervals:function(t){var e=this.activeIntervals=i(t);if(e)for(var n=e.length-1;n>=0;n--)Go(e[n])},getActiveState:function(t){var e=this.activeIntervals;if(!e.length)return"normal";if(null==t||isNaN(t))return"inactive";if(1===e.length){var i=e[0];if(i[0]<=t&&t<=i[1])return"active"}else for(var n=0,o=e.length;n5)return;var n=this._model.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]);"none"!==n.behavior&&this._dispatchExpand({axisExpandWindow:n.axisExpandWindow})}this._mouseDownPoint=null},mousemove:function(t){if(!this._mouseDownPoint&&Mp(this,"mousemove")){var e=this._model,i=e.coordinateSystem.getSlidedAxisExpandWindow([t.offsetX,t.offsetY]),n=i.behavior;"jump"===n&&this._throttledDispatchExpand.debounceNextCall(e.get("axisExpandDebounce")),this._throttledDispatchExpand("none"===n?null:{axisExpandWindow:i.axisExpandWindow,animation:"jump"===n&&null})}}};Ps(function(t){Df(t),Cf(t)}),qI.extend({type:"series.parallel",dependencies:["parallel"],visualColorAccessPath:"lineStyle.color",getInitialData:function(t,e){var i=this.getSource();return Ip(i,this),gl(i,this)},getRawIndicesByActiveState:function(t){var e=this.coordinateSystem,i=this.getData(),n=[];return e.eachActiveState(i,function(e,o){t===e&&n.push(i.getRawIndex(o))}),n},defaultOption:{zlevel:0,z:2,coordinateSystem:"parallel",parallelIndex:0,label:{show:!1},inactiveOpacity:.05,activeOpacity:1,lineStyle:{width:1,opacity:.45,type:"solid"},emphasis:{label:{show:!1}},progressive:500,smooth:!1,animationEasing:"linear"}});var Ck=.3,Lk=(Tr.extend({type:"parallel",init:function(){this._dataGroup=new tb,this.group.add(this._dataGroup),this._data,this._initialized},render:function(t,e,i,n){var o=this._dataGroup,a=t.getData(),r=this._data,s=t.coordinateSystem,l=s.dimensions,u=Lp(t);if(a.diff(r).add(function(t){kp(Cp(a,o,t,l,s),a,t,u)}).update(function(e,i){var o=r.getItemGraphicEl(i),h=Dp(a,e,l,s);a.setItemGraphicEl(e,o),Mo(o,{shape:{points:h}},n&&!1===n.animation?null:t,e),kp(o,a,e,u)}).remove(function(t){var e=r.getItemGraphicEl(t);o.remove(e)}).execute(),!this._initialized){this._initialized=!0;var h=Ap(s,t,function(){setTimeout(function(){o.removeClipPath()})});o.setClipPath(h)}this._data=a},incrementalPrepareRender:function(t,e,i){this._initialized=!0,this._data=null,this._dataGroup.removeAll()},incrementalRender:function(t,e,i){for(var n=e.getData(),o=e.coordinateSystem,a=o.dimensions,r=Lp(e),s=t.start;sn&&(n=e)}),d(e,function(e){var o=new cL({type:"color",mappingMethod:"linear",dataExtent:[i,n],visual:t.get("color")}).mapValueToVisual(e.getLayout().value);e.setVisual("color",o);var a=e.getModel().get("itemStyle.color");null!=a&&e.setVisual("color",a)})}})});var Ek={_baseAxisDim:null,getInitialData:function(t,e){var i,n,o=e.getComponent("xAxis",this.get("xAxisIndex")),a=e.getComponent("yAxis",this.get("yAxisIndex")),r=o.get("type"),s=a.get("type");"category"===r?(t.layout="horizontal",i=o.getOrdinalMeta(),n=!0):"category"===s?(t.layout="vertical",i=a.getOrdinalMeta(),n=!0):t.layout=t.layout||"horizontal";var l=["x","y"],u="horizontal"===t.layout?0:1,h=this._baseAxisDim=l[u],c=l[1-u],f=[o,a],p=f[u].get("type"),g=f[1-u].get("type"),m=t.data;if(m&&n){var v=[];d(m,function(t,e){var i;t.value&&y(t.value)?(i=t.value.slice(),t.value.unshift(e)):y(t)?(i=t.slice(),t.unshift(e)):i=t,v.push(i)}),t.data=v}var x=this.defaultValueDimensions;return aC(this,{coordDimensions:[{name:h,type:Ys(p),ordinalMeta:i,otherDims:{tooltip:!1,itemName:0},dimsDef:["base"]},{name:c,type:Ys(g),dimsDef:x.slice()}],dimensionsCount:x.length+1})},getBaseAxis:function(){var t=this._baseAxisDim;return this.ecModel.getComponent(t+"Axis",this.get(t+"AxisIndex")).axis}};h(qI.extend({type:"series.boxplot",dependencies:["xAxis","yAxis","grid"],defaultValueDimensions:[{name:"min",defaultTooltip:!0},{name:"Q1",defaultTooltip:!0},{name:"median",defaultTooltip:!0},{name:"Q3",defaultTooltip:!0},{name:"max",defaultTooltip:!0}],dimensions:null,defaultOption:{zlevel:0,z:2,coordinateSystem:"cartesian2d",legendHoverLink:!0,hoverAnimation:!0,layout:null,boxWidth:[7,50],itemStyle:{color:"#fff",borderWidth:1},emphasis:{itemStyle:{borderWidth:2,shadowBlur:5,shadowOffsetX:2,shadowOffsetY:2,shadowColor:"rgba(0,0,0,0.4)"}},animationEasing:"elasticOut",animationDuration:800}}),Ek,!0);var Rk=["itemStyle"],zk=["emphasis","itemStyle"],Bk=(Tr.extend({type:"boxplot",render:function(t,e,i){var n=t.getData(),o=this.group,a=this._data;this._data||o.removeAll();var r="horizontal"===t.get("layout")?1:0;n.diff(a).add(function(t){if(n.hasValue(t)){var e=ig(n.getItemLayout(t),n,t,r,!0);n.setItemGraphicEl(t,e),o.add(e)}}).update(function(t,e){var i=a.getItemGraphicEl(e);if(n.hasValue(t)){var s=n.getItemLayout(t);i?ng(s,i,n,t):i=ig(s,n,t,r),o.add(i),n.setItemGraphicEl(t,i)}else o.remove(i)}).remove(function(t){var e=a.getItemGraphicEl(t);e&&o.remove(e)}).execute(),this._data=n},remove:function(t){var e=this.group,i=this._data;this._data=null,i&&i.eachItemGraphicEl(function(t){t&&e.remove(t)})},dispose:B}),kn.extend({type:"boxplotBoxPath",shape:{},buildPath:function(t,e){var i=e.points,n=0;for(t.moveTo(i[n][0],i[n][1]),n++;n<4;n++)t.lineTo(i[n][0],i[n][1]);for(t.closePath();n0?Yk:qk)}function n(t,e){return e.get(t>0?Xk:jk)}var o=t.getData(),a=t.pipelineContext.large;if(o.setVisual({legendSymbol:"roundRect",colorP:i(1,t),colorN:i(-1,t),borderColorP:n(1,t),borderColorN:n(-1,t)}),!e.isSeriesFiltered(t))return!a&&{progress:function(t,e){for(var o;null!=(o=t.next());){var a=e.getItemModel(o),r=e.getItemLayout(o).sign;e.setItemVisual(o,{color:i(r,a),borderColor:n(r,a)})}}}}},$k="undefined"!=typeof Float32Array?Float32Array:Array,Jk={seriesType:"candlestick",plan:JI(),reset:function(t){var e=t.coordinateSystem,i=t.getData(),n=pg(t,i),o=0,a=1,r=["x","y"],s=i.mapDimension(r[o]),l=i.mapDimension(r[a],!0),u=l[0],h=l[1],c=l[2],d=l[3];if(i.setLayout({candleWidth:n,isSimpleBox:n<=1.3}),!(null==s||l.length<4))return{progress:t.pipelineContext.large?function(t,i){for(var n,r,l=new $k(5*t.count),f=0,p=[],g=[];null!=(r=t.next());){var m=i.get(s,r),v=i.get(u,r),y=i.get(h,r),x=i.get(c,r),_=i.get(d,r);isNaN(m)||isNaN(x)||isNaN(_)?(l[f++]=NaN,f+=4):(l[f++]=fg(i,r,v,y,h),p[o]=m,p[a]=x,n=e.dataToPoint(p,null,g),l[f++]=n?n[0]:NaN,l[f++]=n?n[1]:NaN,p[a]=_,n=e.dataToPoint(p,null,g),l[f++]=n?n[1]:NaN)}i.setLayout("largePoints",l)}:function(t,i){function r(t,i){var n=[];return n[o]=i,n[a]=t,isNaN(i)||isNaN(t)?[NaN,NaN]:e.dataToPoint(n)}function l(t,e,i){var a=e.slice(),r=e.slice();a[o]=$n(a[o]+n/2,1,!1),r[o]=$n(r[o]-n/2,1,!0),i?t.push(a,r):t.push(r,a)}function f(t){return t[o]=$n(t[o],1),t}for(var p;null!=(p=t.next());){var g=i.get(s,p),m=i.get(u,p),v=i.get(h,p),y=i.get(c,p),x=i.get(d,p),_=Math.min(m,v),w=Math.max(m,v),b=r(_,g),S=r(w,g),M=r(y,g),I=r(x,g),T=[];l(T,S,0),l(T,b,1),T.push(f(I),f(S),f(M),f(b)),i.setItemLayout(p,{sign:fg(i,p,m,v,h),initBaseline:m>v?S[a]:b[a],ends:T,brushRect:function(t,e,i){var s=r(t,i),l=r(e,i);return s[o]-=n/2,l[o]-=n/2,{x:s[0],y:s[1],width:a?n:l[0]-s[0],height:a?l[1]-s[1]:n}}(y,x,g)})}}}}};Ps(function(t){t&&y(t.series)&&d(t.series,function(t){w(t)&&"k"===t.type&&(t.type="candlestick")})}),zs(Kk),Rs(Jk),qI.extend({type:"series.effectScatter",dependencies:["grid","polar"],getInitialData:function(t,e){return gl(this.getSource(),this)},brushSelector:"point",defaultOption:{coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,effectType:"ripple",progressive:0,showEffectOn:"render",rippleEffect:{period:4,scale:2.5,brushType:"fill"},symbolSize:10}});var Qk=vg.prototype;Qk.stopEffectAnimation=function(){this.childAt(1).removeAll()},Qk.startEffectAnimation=function(t){for(var e=t.symbolType,i=t.color,n=this.childAt(1),o=0;o<3;o++){var a=$l(e,-1,-1,2,2,i);a.attr({style:{strokeNoScale:!0},z2:99,silent:!0,scale:[.5,.5]});var r=-o/3*t.period+t.effectOffset;a.animate("",!0).when(t.period,{scale:[t.rippleScale/2,t.rippleScale/2]}).delay(r).start(),a.animateStyle(!0).when(t.period,{opacity:0}).delay(r).start(),n.add(a)}mg(n,t)},Qk.updateEffectAnimation=function(t){for(var e=this._effectCfg,i=this.childAt(1),n=["symbolType","period","rippleScale"],o=0;o "))},preventIncremental:function(){return!!this.get("effect.show")},getProgressive:function(){var t=this.option.progressive;return null==t?this.option.large?1e4:this.get("progressive"):t},getProgressiveThreshold:function(){var t=this.option.progressiveThreshold;return null==t?this.option.large?2e4:this.get("progressiveThreshold"):t},defaultOption:{coordinateSystem:"geo",zlevel:0,z:2,legendHoverLink:!0,hoverAnimation:!0,xAxisIndex:0,yAxisIndex:0,symbol:["none","none"],symbolSize:[10,10],geoIndex:0,effect:{show:!1,period:4,constantSpeed:0,symbol:"circle",symbolSize:3,loop:!0,trailLength:.2},large:!1,largeThreshold:2e3,polyline:!1,label:{show:!1,position:"end"},lineStyle:{opacity:.5}}}),nP=xg.prototype;nP.createLine=function(t,e,i){return new af(t,e,i)},nP._updateEffectSymbol=function(t,e){var i=t.getItemModel(e).getModel("effect"),n=i.get("symbolSize"),o=i.get("symbol");y(n)||(n=[n,n]);var a=i.get("color")||t.getItemVisual(e,"color"),r=this.childAt(1);this._symbolType!==o&&(this.remove(r),(r=$l(o,-.5,-.5,1,1,a)).z2=100,r.culling=!0,this.add(r)),r&&(r.setStyle("shadowColor",a),r.setStyle(i.getItemStyle(["color"])),r.attr("scale",n),r.setColor(a),r.attr("scale",n),this._symbolType=o,this._updateEffectAnimation(t,i,e))},nP._updateEffectAnimation=function(t,e,i){var n=this.childAt(1);if(n){var o=this,a=t.getItemLayout(i),r=1e3*e.get("period"),s=e.get("loop"),l=e.get("constantSpeed"),u=T(e.get("delay"),function(e){return e/t.count()*r/3}),h="function"==typeof u;if(n.ignore=!0,this.updateAnimationPoints(n,a),l>0&&(r=this.getLineLength(n)/l*1e3),r!==this._period||s!==this._loop){n.stopAnimation();var c=u;h&&(c=u(i)),n.__t>0&&(c=-r*n.__t),n.__t=0;var d=n.animate("",s).when(r,{__t:1}).delay(c).during(function(){o.updateSymbolPosition(n)});s||d.done(function(){o.remove(n)}),d.start()}this._period=r,this._loop=s}},nP.getLineLength=function(t){return uw(t.__p1,t.__cp1)+uw(t.__cp1,t.__p2)},nP.updateAnimationPoints=function(t,e){t.__p1=e[0],t.__p2=e[1],t.__cp1=e[2]||[(e[0][0]+e[1][0])/2,(e[0][1]+e[1][1])/2]},nP.updateData=function(t,e,i){this.childAt(0).updateData(t,e,i),this._updateEffectSymbol(t,e)},nP.updateSymbolPosition=function(t){var e=t.__p1,i=t.__p2,n=t.__cp1,o=t.__t,a=t.position,r=rn,s=sn;a[0]=r(e[0],n[0],i[0],o),a[1]=r(e[1],n[1],i[1],o);var l=s(e[0],n[0],i[0],o),u=s(e[1],n[1],i[1],o);t.rotation=-Math.atan2(u,l)-Math.PI/2,t.ignore=!1},nP.updateLayout=function(t,e){this.childAt(0).updateLayout(t,e);var i=t.getItemModel(e).getModel("effect");this._updateEffectAnimation(t,i,e)},u(xg,tb);var oP=_g.prototype;oP._createPolyline=function(t,e,i){var n=t.getItemLayout(e),o=new gM({shape:{points:n}});this.add(o),this._updateCommonStl(t,e,i)},oP.updateData=function(t,e,i){var n=t.hostModel;Mo(this.childAt(0),{shape:{points:t.getItemLayout(e)}},n,e),this._updateCommonStl(t,e,i)},oP._updateCommonStl=function(t,e,i){var n=this.childAt(0),o=t.getItemModel(e),a=t.getItemVisual(e,"color"),s=i&&i.lineStyle,l=i&&i.hoverLineStyle;i&&!t.hasItemOption||(s=o.getModel("lineStyle").getLineStyle(),l=o.getModel("emphasis.lineStyle").getLineStyle()),n.useStyle(r({strokeNoScale:!0,fill:"none",stroke:a},s)),n.hoverStyle=l,co(this)},oP.updateLayout=function(t,e){this.childAt(0).setShape("points",t.getItemLayout(e))},u(_g,tb);var aP=wg.prototype;aP.createLine=function(t,e,i){return new _g(t,e,i)},aP.updateAnimationPoints=function(t,e){this._points=e;for(var i=[0],n=0,o=1;o=0&&!(n[r]<=e);r--);r=Math.min(r,o-2)}else{for(var r=a;re);r++);r=Math.min(r-1,o-2)}J(t.position,i[r],i[r+1],(e-n[r])/(n[r+1]-n[r]));var s=i[r+1][0]-i[r][0],l=i[r+1][1]-i[r][1];t.rotation=-Math.atan2(l,s)-Math.PI/2,this._lastFrame=r,this._lastFramePercent=e,t.ignore=!1}},u(wg,xg);var rP=Zn({shape:{polyline:!1,curveness:0,segs:[]},buildPath:function(t,e){var i=e.segs,n=e.curveness;if(e.polyline)for(r=0;r0){t.moveTo(i[r++],i[r++]);for(var a=1;a0){var c=(s+u)/2-(l-h)*n,d=(l+h)/2-(u-s)*n;t.quadraticCurveTo(c,d,u,h)}else t.lineTo(u,h)}},findDataIndex:function(t,e){var i=this.shape,n=i.segs,o=i.curveness;if(i.polyline)for(var a=0,r=0;r0)for(var l=n[r++],u=n[r++],h=1;h0){if(xn(l,u,(l+c)/2-(u-d)*o,(u+d)/2-(c-l)*o,c,d))return a}else if(vn(l,u,c,d))return a;a++}return-1}}),sP=bg.prototype;sP.isPersistent=function(){return!this._incremental},sP.updateData=function(t){this.group.removeAll();var e=new rP({rectHover:!0,cursor:"default"});e.setShape({segs:t.getLayout("linesPoints")}),this._setCommon(e,t),this.group.add(e),this._incremental=null},sP.incrementalPrepareUpdate=function(t){this.group.removeAll(),this._clearIncremental(),t.count()>5e5?(this._incremental||(this._incremental=new Hn({silent:!0})),this.group.add(this._incremental)):this._incremental=null},sP.incrementalUpdate=function(t,e){var i=new rP;i.setShape({segs:e.getLayout("linesPoints")}),this._setCommon(i,e,!!this._incremental),this._incremental?this._incremental.addDisplayable(i,!0):(i.rectHover=!0,i.cursor="default",i.__startIndex=t.start,this.group.add(i))},sP.remove=function(){this._clearIncremental(),this._incremental=null,this.group.removeAll()},sP._setCommon=function(t,e,i){var n=e.hostModel;t.setShape({polyline:n.get("polyline"),curveness:n.get("lineStyle.curveness")}),t.useStyle(n.getModel("lineStyle").getLineStyle()),t.style.strokeNoScale=!0;var o=e.getVisual("color");o&&t.setStyle("stroke",o),t.setStyle("fill"),i||(t.seriesIndex=n.seriesIndex,t.on("mousemove",function(e){t.dataIndex=null;var i=t.findDataIndex(e.offsetX,e.offsetY);i>0&&(t.dataIndex=i+t.__startIndex)}))},sP._clearIncremental=function(){var t=this._incremental;t&&t.clearDisplaybles()};var lP={seriesType:"lines",plan:JI(),reset:function(t){var e=t.coordinateSystem,i=t.get("polyline"),n=t.pipelineContext.large;return{progress:function(o,a){var r=[];if(n){var s,l=o.end-o.start;if(i){for(var u=0,h=o.start;h0){var I=a(v)?s:l;v>0&&(v=v*S+b),x[_++]=I[M],x[_++]=I[M+1],x[_++]=I[M+2],x[_++]=I[M+3]*v*256}else _+=4}return c.putImageData(y,0,0),h},_getBrush:function(){var t=this._brushCanvas||(this._brushCanvas=iw()),e=this.pointSize+this.blurSize,i=2*e;t.width=i,t.height=i;var n=t.getContext("2d");return n.clearRect(0,0,i,i),n.shadowOffsetX=i,n.shadowBlur=this.blurSize,n.shadowColor="#000",n.beginPath(),n.arc(-e,e,this.pointSize,0,2*Math.PI,!0),n.closePath(),n.fill(),t},_getGradient:function(t,e,i){for(var n=this._gradientPixels,o=n[i]||(n[i]=new Uint8ClampedArray(1024)),a=[0,0,0,0],r=0,s=0;s<256;s++)e[i](s/255,!0,a),o[r++]=a[0],o[r++]=a[1],o[r++]=a[2],o[r++]=a[3];return o}},Hs({type:"heatmap",render:function(t,e,i){var n;e.eachComponent("visualMap",function(e){e.eachTargetSeries(function(i){i===t&&(n=e)})}),this.group.removeAll(),this._incrementalDisplayable=null;var o=t.coordinateSystem;"cartesian2d"===o.type||"calendar"===o.type?this._renderOnCartesianAndCalendar(t,i,0,t.getData().count()):Ag(o)&&this._renderOnGeo(o,t,n,i)},incrementalPrepareRender:function(t,e,i){this.group.removeAll()},incrementalRender:function(t,e,i,n){e.coordinateSystem&&this._renderOnCartesianAndCalendar(e,n,t.start,t.end,!0)},_renderOnCartesianAndCalendar:function(t,e,i,n,o){var r,s,l=t.coordinateSystem;if("cartesian2d"===l.type){var u=l.getAxis("x"),h=l.getAxis("y");r=u.getBandWidth(),s=h.getBandWidth()}for(var c=this.group,d=t.getData(),f=t.getModel("itemStyle").getItemStyle(["color"]),p=t.getModel("emphasis.itemStyle").getItemStyle(),g=t.getModel("label"),m=t.getModel("emphasis.label"),v=l.type,y="cartesian2d"===v?[d.mapDimension("x"),d.mapDimension("y"),d.mapDimension("value")]:[d.mapDimension("time"),d.mapDimension("value")],x=i;x=e.y&&t[1]<=e.y+e.height:i.contain(i.toLocalCoord(t[1]))&&t[0]>=e.y&&t[0]<=e.y+e.height},pointToData:function(t){var e=this.getAxis();return[e.coordToData(e.toLocalCoord(t["horizontal"===e.orient?0:1]))]},dataToPoint:function(t){var e=this.getAxis(),i=this.getRect(),n=[],o="horizontal"===e.orient?0:1;return t instanceof Array&&(t=t[0]),n[o]=e.toGlobalCoord(e.dataToCoord(+t)),n[1-o]=0===o?i.y+i.height/2:i.x+i.width/2,n}},Ga.register("single",{create:function(t,e){var i=[];return t.eachComponent("singleAxis",function(n,o){var a=new $g(n,t,e);a.name="single_"+o,a.resize(n,e),n.coordinateSystem=a,i.push(a)}),t.eachSeries(function(e){if("singleAxis"===e.get("coordinateSystem")){var i=t.queryComponents({mainType:"singleAxis",index:e.get("singleAxisIndex"),id:e.get("singleAxisId")})[0];e.coordinateSystem=i&&i.coordinateSystem}}),i},dimensions:$g.prototype.dimensions});var mP=["axisLine","axisTickLabel","axisName"],vP=jD.extend({type:"singleAxis",axisPointerClass:"SingleAxisPointer",render:function(t,e,i,n){var o=this.group;o.removeAll();var a=Jg(t),r=new WD(t,a);d(mP,r.add,r),o.add(r.getGroup()),t.get("splitLine.show")&&this._splitLine(t),vP.superCall(this,"render",t,e,i,n)},_splitLine:function(t){var e=t.axis;if(!e.scale.isBlank()){var i=t.getModel("splitLine"),n=i.getModel("lineStyle"),o=n.get("width"),a=n.get("color");a=a instanceof Array?a:[a];for(var r=t.coordinateSystem.getRect(),s=e.isHorizontal(),l=[],u=0,h=e.getTicksCoords({tickModel:i}),c=[],d=[],f=0;f=0)&&i({type:"updateAxisPointer",currTrigger:t,x:e&&e.offsetX,y:e&&e.offsetY})})},remove:function(t,e){gm(e.getZr(),"axisPointer"),TP.superApply(this._model,"remove",arguments)},dispose:function(t,e){gm("axisPointer",e),TP.superApply(this._model,"dispose",arguments)}}),AP=Bi(),DP=i,CP=m;(mm.prototype={_group:null,_lastGraphicKey:null,_handle:null,_dragging:!1,_lastValue:null,_lastStatus:null,_payloadInfo:null,animationThreshold:15,render:function(t,e,i,n){var o=e.get("value"),a=e.get("status");if(this._axisModel=t,this._axisPointerModel=e,this._api=i,n||this._lastValue!==o||this._lastStatus!==a){this._lastValue=o,this._lastStatus=a;var r=this._group,s=this._handle;if(!a||"hide"===a)return r&&r.hide(),void(s&&s.hide());r&&r.show(),s&&s.show();var l={};this.makeElOption(l,o,t,e,i);var u=l.graphicKey;u!==this._lastGraphicKey&&this.clear(i),this._lastGraphicKey=u;var h=this._moveAnimation=this.determineAnimation(t,e);if(r){var c=v(vm,e,h);this.updatePointerEl(r,l,c,e),this.updateLabelEl(r,l,c,e)}else r=this._group=new tb,this.createPointerEl(r,l,t,e),this.createLabelEl(r,l,t,e),i.getZr().add(r);wm(r,e,!0),this._renderHandle(o)}},remove:function(t){this.clear(t)},dispose:function(t){this.clear(t)},determineAnimation:function(t,e){var i=e.get("animation"),n=t.axis,o="category"===n.type,a=e.get("snap");if(!a&&!o)return!1;if("auto"===i||null==i){var r=this.animationThreshold;if(o&&n.getBandWidth()>r)return!0;if(a){var s=Sh(t).seriesDataCount,l=n.getExtent();return Math.abs(l[0]-l[1])/s>r}return!1}return!0===i},makeElOption:function(t,e,i,n,o){},createPointerEl:function(t,e,i,n){var o=e.pointer;if(o){var a=AP(t).pointerEl=new zM[o.type](DP(e.pointer));t.add(a)}},createLabelEl:function(t,e,i,n){if(e.label){var o=AP(t).labelEl=new yM(DP(e.label));t.add(o),xm(o,n)}},updatePointerEl:function(t,e,i){var n=AP(t).pointerEl;n&&(n.setStyle(e.pointer.style),i(n,{shape:e.pointer.shape}))},updateLabelEl:function(t,e,i,n){var o=AP(t).labelEl;o&&(o.setStyle(e.label.style),i(o,{shape:e.label.shape,position:e.label.position}),xm(o,n))},_renderHandle:function(t){if(!this._dragging&&this.updateHandleTransform){var e=this._axisPointerModel,i=this._api.getZr(),n=this._handle,o=e.getModel("handle"),a=e.get("status");if(!o.get("show")||!a||"hide"===a)return n&&i.remove(n),void(this._handle=null);var r;this._handle||(r=!0,n=this._handle=ko(o.get("icon"),{cursor:"move",draggable:!0,onmousemove:function(t){mw(t.event)},onmousedown:CP(this._onHandleDragMove,this,0,0),drift:CP(this._onHandleDragMove,this),ondragend:CP(this._onHandleDragEnd,this)}),i.add(n)),wm(n,e,!1);var s=["color","borderColor","borderWidth","opacity","shadowColor","shadowBlur","shadowOffsetX","shadowOffsetY"];n.setStyle(o.getItemStyle(null,s));var l=o.get("size");y(l)||(l=[l,l]),n.attr("scale",[l[0]/2,l[1]/2]),Pr(this,"_doDispatchAxisPointer",o.get("throttle")||0,"fixRate"),this._moveHandleToValue(t,r)}},_moveHandleToValue:function(t,e){vm(this._axisPointerModel,!e&&this._moveAnimation,this._handle,_m(this.getHandleTransform(t,this._axisModel,this._axisPointerModel)))},_onHandleDragMove:function(t,e){var i=this._handle;if(i){this._dragging=!0;var n=this.updateHandleTransform(_m(i),[t,e],this._axisModel,this._axisPointerModel);this._payloadInfo=n,i.stopAnimation(),i.attr(_m(n)),AP(i).lastProp=null,this._doDispatchAxisPointer()}},_doDispatchAxisPointer:function(){if(this._handle){var t=this._payloadInfo,e=this._axisModel;this._api.dispatchAction({type:"updateAxisPointer",x:t.cursorPoint[0],y:t.cursorPoint[1],tooltipOption:t.tooltipOption,axesInfo:[{axisDim:e.axis.dim,axisIndex:e.componentIndex}]})}},_onHandleDragEnd:function(t){if(this._dragging=!1,this._handle){var e=this._axisPointerModel.get("value");this._moveHandleToValue(e),this._api.dispatchAction({type:"hideTip"})}},getHandleTransform:null,updateHandleTransform:null,clear:function(t){this._lastValue=null,this._lastStatus=null;var e=t.getZr(),i=this._group,n=this._handle;e&&i&&(this._lastGraphicKey=null,i&&e.remove(i),n&&e.remove(n),this._group=null,this._handle=null,this._payloadInfo=null)},doClear:function(){},buildLabel:function(t,e,i){return i=i||0,{x:t[i],y:t[1-i],width:e[i],height:e[1-i]}}}).constructor=mm,Xi(mm);var LP=mm.extend({makeElOption:function(t,e,i,n,o){var a=i.axis,r=a.grid,s=n.get("type"),l=km(r,a).getOtherAxis(a).getGlobalExtent(),u=a.toGlobalCoord(a.dataToCoord(e,!0));if(s&&"none"!==s){var h=bm(n),c=kP[s](a,u,l,h);c.style=h,t.graphicKey=c.type,t.pointer=c}Am(e,t,Ch(r.model,i),i,n,o)},getHandleTransform:function(t,e,i){var n=Ch(e.axis.grid.model,e,{labelInside:!1});return n.labelMargin=i.get("handle.margin"),{position:Tm(e.axis,t,n),rotation:n.rotation+(n.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,i,n){var o=i.axis,a=o.grid,r=o.getGlobalExtent(!0),s=km(a,o).getOtherAxis(o).getGlobalExtent(),l="x"===o.dim?0:1,u=t.position;u[l]+=e[l],u[l]=Math.min(r[1],u[l]),u[l]=Math.max(r[0],u[l]);var h=(s[1]+s[0])/2,c=[h,h];c[l]=u[l];var d=[{verticalAlign:"middle"},{align:"center"}];return{position:u,rotation:t.rotation,cursorPoint:c,tooltipOption:d[l]}}}),kP={line:function(t,e,i,n){var o=Dm([e,i[0]],[e,i[1]],Pm(t));return qn({shape:o,style:n}),{type:"Line",shape:o}},shadow:function(t,e,i,n){var o=Math.max(1,t.getBandWidth()),a=i[1]-i[0];return{type:"Rect",shape:Cm([e-o/2,i[0]],[o,a],Pm(t))}}};jD.registerAxisPointerClass("CartesianAxisPointer",LP),Ps(function(t){if(t){(!t.axisPointer||0===t.axisPointer.length)&&(t.axisPointer={});var e=t.axisPointer.link;e&&!y(e)&&(t.axisPointer.link=[e])}}),Ns(GT.PROCESSOR.STATISTIC,function(t,e){t.getComponent("axisPointer").coordSysAxesInfo=mh(t,e)}),Os({type:"updateAxisPointer",event:"updateAxisPointer",update:":updateAxisPointer"},function(t,e,i){var n=t.currTrigger,o=[t.x,t.y],a=t,r=t.dispatchAction||m(i.dispatchAction,i),s=e.getComponent("axisPointer").coordSysAxesInfo;if(s){lm(o)&&(o=_P({seriesIndex:a.seriesIndex,dataIndex:a.dataIndex},e).point);var l=lm(o),u=a.axesInfo,h=s.axesInfo,c="leave"===n||lm(o),d={},f={},p={list:[],map:{}},g={showPointer:bP(em,f),showTooltip:bP(im,p)};wP(s.coordSysMap,function(t,e){var i=l||t.containPoint(o);wP(s.coordSysAxesInfo[e],function(t,e){var n=t.axis,a=rm(u,t);if(!c&&i&&(!u||a)){var r=a&&a.value;null!=r||l||(r=n.pointToData(o)),null!=r&&Qg(t,r,g,!1,d)}})});var v={};return wP(h,function(t,e){var i=t.linkGroup;i&&!f[e]&&wP(i.axesInfo,function(e,n){var o=f[n];if(e!==t&&o){var a=o.value;i.mapper&&(a=t.axis.scale.parse(i.mapper(a,sm(e),sm(t)))),v[t.key]=a}})}),wP(v,function(t,e){Qg(h[e],t,g,!0,d)}),nm(f,h,d),om(p,o,t,r),am(h,0,i),d}});var PP=["x","y"],NP=["width","height"],OP=mm.extend({makeElOption:function(t,e,i,n,o){var a=i.axis,r=a.coordinateSystem,s=Om(r,1-Nm(a)),l=r.dataToPoint(e)[0],u=n.get("type");if(u&&"none"!==u){var h=bm(n),c=EP[u](a,l,s,h);c.style=h,t.graphicKey=c.type,t.pointer=c}Am(e,t,Jg(i),i,n,o)},getHandleTransform:function(t,e,i){var n=Jg(e,{labelInside:!1});return n.labelMargin=i.get("handle.margin"),{position:Tm(e.axis,t,n),rotation:n.rotation+(n.labelDirection<0?Math.PI:0)}},updateHandleTransform:function(t,e,i,n){var o=i.axis,a=o.coordinateSystem,r=Nm(o),s=Om(a,r),l=t.position;l[r]+=e[r],l[r]=Math.min(s[1],l[r]),l[r]=Math.max(s[0],l[r]);var u=Om(a,1-r),h=(u[1]+u[0])/2,c=[h,h];return c[r]=l[r],{position:l,rotation:t.rotation,cursorPoint:c,tooltipOption:{verticalAlign:"middle"}}}}),EP={line:function(t,e,i,n){var o=Dm([e,i[0]],[e,i[1]],Nm(t));return qn({shape:o,style:n}),{type:"Line",shape:o}},shadow:function(t,e,i,n){var o=t.getBandWidth(),a=i[1]-i[0];return{type:"Rect",shape:Cm([e-o/2,i[0]],[o,a],Nm(t))}}};jD.registerAxisPointerClass("SingleAxisPointer",OP),Fs({type:"single"});var RP=qI.extend({type:"series.themeRiver",dependencies:["singleAxis"],nameMap:null,init:function(t){RP.superApply(this,"init",arguments),this.legendDataProvider=function(){return this.getRawData()}},fixData:function(t){for(var e=t.length,i=f(zp().key(function(t){return t[2]}).entries(t),function(t){return{name:t.key,dataList:t.values}}),n=i.length,o=-1,a=-1,r=0;ro&&(o=s,a=r)}for(var l=0;lMath.PI/2?"right":"left"):x&&"center"!==x?"left"===x?(f=u.r0+y,p>Math.PI/2&&(x="right")):"right"===x&&(f=u.r-y,p>Math.PI/2&&(x="left")):(f=(u.r+u.r0)/2,x="center"),d.attr("style",{text:l,textAlign:x,textVerticalAlign:n("verticalAlign")||"middle",opacity:n("opacity")});var _=f*g+u.cx,w=f*m+u.cy;d.attr("position",[_,w]);var b=n("rotate"),S=0;"radial"===b?(S=-p)<-Math.PI/2&&(S+=Math.PI):"tangential"===b?(S=Math.PI/2-p)>Math.PI/2?S-=Math.PI:S<-Math.PI/2&&(S+=Math.PI):"number"==typeof b&&(S=b*Math.PI/180),d.attr("rotation",S)},GP._initEvents=function(t,e,i,n){t.off("mouseover").off("mouseout").off("emphasis").off("normal");var o=this,a=function(){o.onEmphasis(n)},r=function(){o.onNormal()};i.isAnimationEnabled()&&t.on("mouseover",a).on("mouseout",r).on("emphasis",a).on("normal",r).on("downplay",function(){o.onDownplay()}).on("highlight",function(){o.onHighlight()})},u(Vm,tb);Tr.extend({type:"sunburst",init:function(){},render:function(t,e,i,n){function o(i,n){if(c||!i||i.getValue()||(i=null),i!==l&&n!==l)if(n&&n.piece)i?(n.piece.updateData(!1,i,"normal",t,e),s.setItemGraphicEl(i.dataIndex,n.piece)):a(n);else if(i){var o=new Vm(i,t,e);h.add(o),s.setItemGraphicEl(i.dataIndex,o)}}function a(t){t&&t.piece&&(h.remove(t.piece),t.piece=null)}var r=this;this.seriesModel=t,this.api=i,this.ecModel=e;var s=t.getData(),l=s.tree.root,u=t.getViewRoot(),h=this.group,c=t.get("renderLabelForZeroData"),d=[];u.eachNode(function(t){d.push(t)});var f=this._oldChildren||[];if(function(t,e){function i(t){return t.getId()}function n(i,n){o(null==i?null:t[i],null==n?null:e[n])}0===t.length&&0===e.length||new Us(e,t,i,i).add(n).update(n).remove(v(n,null)).execute()}(d,f),function(i,n){if(n.depth>0){r.virtualPiece?r.virtualPiece.updateData(!1,i,"normal",t,e):(r.virtualPiece=new Vm(i,t,e),h.add(r.virtualPiece)),n.piece._onclickEvent&&n.piece.off("click",n.piece._onclickEvent);var o=function(t){r._rootToNode(n.parentNode)};n.piece._onclickEvent=o,r.virtualPiece.on("click",o)}else r.virtualPiece&&(h.remove(r.virtualPiece),r.virtualPiece=null)}(l,u),n&&n.highlight&&n.highlight.piece){var p=t.getShallow("highlightPolicy");n.highlight.piece.onEmphasis(p)}else if(n&&n.unhighlight){var g=this.virtualPiece;!g&&l.children.length&&(g=l.children[0].piece),g&&g.onNormal()}this._initEvents(),this._oldChildren=d},dispose:function(){},_initEvents:function(){var t=this,e=function(e){var i=!1;t.seriesModel.getViewRoot().eachNode(function(n){if(!i&&n.piece&&n.piece.childAt(0)===e.target){var o=n.getModel().get("nodeClick");if("rootToNode"===o)t._rootToNode(n);else if("link"===o){var a=n.getModel(),r=a.get("link");if(r){var s=a.get("target",!0)||"_blank";window.open(r,s)}}i=!0}})};this.group._onclickEvent&&this.group.off("click",this.group._onclickEvent),this.group.on("click",e),this.group._onclickEvent=e},_rootToNode:function(t){t!==this.seriesModel.getViewRoot()&&this.api.dispatchAction({type:"sunburstRootToNode",from:this.uid,seriesId:this.seriesModel.id,targetNode:t})},containPoint:function(t,e){var i=e.getData().getItemLayout(0);if(i){var n=t[0]-i.cx,o=t[1]-i.cy,a=Math.sqrt(n*n+o*o);return a<=i.r&&a>=i.r0}}});var FP="sunburstRootToNode";Os({type:FP,update:"updateView"},function(t,e){e.eachComponent({mainType:"series",subType:"sunburst",query:t},function(e,i){var n=sd(t,[FP],e);if(n){var o=e.getViewRoot();o&&(t.direction=ud(o,n.node)?"rollUp":"drillDown"),e.resetViewRoot(n.node)}})});var WP="sunburstHighlight";Os({type:WP,update:"updateView"},function(t,e){e.eachComponent({mainType:"series",subType:"sunburst",query:t},function(e,i){var n=sd(t,[WP],e);n&&(t.highlight=n.node)})});Os({type:"sunburstUnhighlight",update:"updateView"},function(t,e){e.eachComponent({mainType:"series",subType:"sunburst",query:t},function(e,i){t.unhighlight=!0})});var HP=Math.PI/180;zs(v(hC,"sunburst")),Rs(v(function(t,e,i,n){e.eachSeriesByType(t,function(t){var e=t.get("center"),n=t.get("radius");y(n)||(n=[0,n]),y(e)||(e=[e,e]);var o=i.getWidth(),a=i.getHeight(),r=Math.min(o,a),s=Bo(e[0],o),l=Bo(e[1],a),u=Bo(n[0],r/2),h=Bo(n[1],r/2),c=-t.get("startAngle")*HP,f=t.get("minAngle")*HP,p=t.getData().tree.root,g=t.getViewRoot(),m=g.depth,v=t.get("sort");null!=v&&Zm(g,v);var x=0;d(g.children,function(t){!isNaN(t.getValue())&&x++});var _=g.getValue(),w=Math.PI/(_||x)*2,b=g.depth>0,S=g.height-(b?-1:1),M=(h-u)/(S||1),I=t.get("clockwise"),T=t.get("stillShowZeroSum"),A=I?1:-1,D=function(t,e){if(t){var i=e;if(t!==p){var n=t.getValue(),o=0===_&&T?w:n*w;on[1]&&n.reverse(),{coordSys:{type:"polar",cx:t.cx,cy:t.cy,r:n[1],r0:n[0]},api:{coord:m(function(n){var o=e.dataToRadius(n[0]),a=i.dataToAngle(n[1]),r=t.coordToPoint([o,a]);return r.push(o,a*Math.PI/180),r}),size:m(qm,t)}}},calendar:function(t){var e=t.getRect(),i=t.getRangeInfo();return{coordSys:{type:"calendar",x:e.x,y:e.y,width:e.width,height:e.height,cellWidth:t.getCellWidth(),cellHeight:t.getCellHeight(),rangeInfo:{start:i.start,end:i.end,weeks:i.weeks,dayCount:i.allDay}},api:{coord:function(e,i){return t.dataToPoint(e,i)}}}}};qI.extend({type:"series.custom",dependencies:["grid","polar","geo","singleAxis","calendar"],defaultOption:{coordinateSystem:"cartesian2d",zlevel:0,z:2,legendHoverLink:!0,useTransform:!0},getInitialData:function(t,e){return gl(this.getSource(),this)},getDataParams:function(t,e,i){var n=qI.prototype.getDataParams.apply(this,arguments);return i&&(n.info=i.info),n}}),Tr.extend({type:"custom",_data:null,render:function(t,e,i,n){var o=this._data,a=t.getData(),r=this.group,s=Qm(t,a,e,i);a.diff(o).add(function(e){ev(null,e,s(e,n),t,r,a)}).update(function(e,i){ev(o.getItemGraphicEl(i),e,s(e,n),t,r,a)}).remove(function(t){var e=o.getItemGraphicEl(t);e&&r.remove(e)}).execute(),this._data=a},incrementalPrepareRender:function(t,e,i){this.group.removeAll(),this._data=null},incrementalRender:function(t,e,i,n,o){for(var a=e.getData(),r=Qm(e,a,i,n),s=t.start;s=0;l--)null==o[l]?o.splice(l,1):delete o[l].$action},_flatten:function(t,e,i){d(t,function(t){if(t){i&&(t.parentOption=i),e.push(t);var n=t.children;"group"===t.type&&n&&this._flatten(n,e,t),delete t.children}},this)},useElOptionsToUpdate:function(){var t=this._elOptionsToUpdate;return this._elOptionsToUpdate=null,t}});Fs({type:"graphic",init:function(t,e){this._elMap=R(),this._lastGraphicModel},render:function(t,e,i){t!==this._lastGraphicModel&&this._clear(),this._lastGraphicModel=t,this._updateElements(t),this._relocate(t,i)},_updateElements:function(t){var e=t.useElOptionsToUpdate();if(e){var i=this._elMap,n=this.group;d(e,function(e){var o=e.$action,a=e.id,r=i.get(a),s=e.parentId,l=null!=s?i.get(s):n,u=e.style;"text"===e.type&&u&&(e.hv&&e.hv[1]&&(u.textVerticalAlign=u.textBaseline=null),!u.hasOwnProperty("textFill")&&u.fill&&(u.textFill=u.fill),!u.hasOwnProperty("textStroke")&&u.stroke&&(u.textStroke=u.stroke));var h=fv(e);o&&"merge"!==o?"replace"===o?(dv(r,i),cv(a,l,h,i)):"remove"===o&&dv(r,i):r?r.attr(h):cv(a,l,h,i);var c=i.get(a);c&&(c.__ecGraphicWidth=e.width,c.__ecGraphicHeight=e.height,yv(c,t))})}},_relocate:function(t,e){for(var i=t.option.elements,n=this.group,o=this._elMap,a=i.length-1;a>=0;a--){var r=i[a],s=o.get(r.id);if(s){var l=s.parent;ca(s,r,l===n?{width:e.getWidth(),height:e.getHeight()}:{width:l.__ecGraphicWidth||0,height:l.__ecGraphicHeight||0},null,{hv:r.hv,boundingMode:r.bounding})}}},_clear:function(){var t=this._elMap;t.each(function(e){dv(e,t)}),this._elMap=R()},dispose:function(){this._clear()}});var $P=Gs({type:"legend.plain",dependencies:["series"],layoutMode:{type:"box",ignoreSize:!0},init:function(t,e,i){this.mergeDefaultAndTheme(t,i),t.selected=t.selected||{}},mergeOption:function(t){$P.superCall(this,"mergeOption",t)},optionUpdated:function(){this._updateData(this.ecModel);var t=this._data;if(t[0]&&"single"===this.get("selectedMode")){for(var e=!1,i=0;i=0},defaultOption:{zlevel:0,z:4,show:!0,orient:"horizontal",left:"center",top:0,align:"auto",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderRadius:0,borderWidth:0,padding:5,itemGap:10,itemWidth:25,itemHeight:14,inactiveColor:"#ccc",textStyle:{color:"#333"},selectedMode:!0,tooltip:{show:!1}}});Os("legendToggleSelect","legendselectchanged",v(xv,"toggleSelected")),Os("legendSelect","legendselected",v(xv,"select")),Os("legendUnSelect","legendunselected",v(xv,"unSelect"));var JP=v,QP=d,tN=tb,eN=Fs({type:"legend.plain",newlineDisabled:!1,init:function(){this.group.add(this._contentGroup=new tN),this._backgroundEl,this._isFirstRender=!0},getContentGroup:function(){return this._contentGroup},render:function(t,e,i){var n=this._isFirstRender;if(this._isFirstRender=!1,this.resetInner(),t.get("show",!0)){var o=t.get("align");o&&"auto"!==o||(o="right"===t.get("left")&&"vertical"===t.get("orient")?"right":"left"),this.renderInner(o,t,e,i);var a=t.getBoxLayoutParams(),s={width:i.getWidth(),height:i.getHeight()},l=t.get("padding"),u=ha(a,s,l),h=this.layoutInner(t,o,u,n),c=ha(r({width:h.width,height:h.height},a),s,l);this.group.attr("position",[c.x-h.x,c.y-h.y]),this.group.add(this._backgroundEl=wv(h,t))}},resetInner:function(){this.getContentGroup().removeAll(),this._backgroundEl&&this.group.remove(this._backgroundEl)},renderInner:function(t,e,i,n){var o=this.getContentGroup(),a=R(),r=e.get("selectedMode"),s=[];i.eachRawSeries(function(t){!t.get("legendHoverLink")&&s.push(t.id)}),QP(e.getData(),function(l,u){var h=l.get("name");if(this.newlineDisabled||""!==h&&"\n"!==h){var c=i.getSeriesByName(h)[0];if(!a.get(h))if(c){var d=c.getData(),f=d.getVisual("color");"function"==typeof f&&(f=f(c.getDataParams(0)));var p=d.getVisual("legendSymbol")||"roundRect",g=d.getVisual("symbol");this._createItem(h,u,l,e,p,g,t,f,r).on("click",JP(bv,h,n)).on("mouseover",JP(Sv,c.name,null,n,s)).on("mouseout",JP(Mv,c.name,null,n,s)),a.set(h,!0)}else i.eachRawSeries(function(i){if(!a.get(h)&&i.legendDataProvider){var o=i.legendDataProvider(),c=o.indexOfName(h);if(c<0)return;var d=o.getItemVisual(c,"color");this._createItem(h,u,l,e,"roundRect",null,t,d,r).on("click",JP(bv,h,n)).on("mouseover",JP(Sv,null,h,n,s)).on("mouseout",JP(Mv,null,h,n,s)),a.set(h,!0)}},this)}else o.add(new tN({newline:!0}))},this)},_createItem:function(t,e,i,n,o,r,s,l,u){var h=n.get("itemWidth"),c=n.get("itemHeight"),d=n.get("inactiveColor"),f=n.get("symbolKeepAspect"),p=n.isSelected(t),g=new tN,m=i.getModel("textStyle"),v=i.get("icon"),y=i.getModel("tooltip"),x=y.parentModel;if(o=v||o,g.add($l(o,0,0,h,c,p?l:d,null==f||f)),!v&&r&&(r!==o||"none"===r)){var _=.8*c;"none"===r&&(r="circle"),g.add($l(r,(h-_)/2,(c-_)/2,_,_,p?l:d,null==f||f))}var w="left"===s?h+5:-5,b=s,S=n.get("formatter"),M=t;"string"==typeof S&&S?M=S.replace("{name}",null!=t?t:""):"function"==typeof S&&(M=S(t)),g.add(new rM({style:go({},m,{text:M,x:w,y:c/2,textFill:p?m.getTextColor():d,textAlign:b,textVerticalAlign:"middle"})}));var I=new yM({shape:g.getBoundingRect(),invisible:!0,tooltip:y.get("show")?a({content:t,formatter:x.get("formatter",!0)||function(){return t},formatterParams:{componentType:"legend",legendIndex:n.componentIndex,name:t,$vars:["name"]}},y.option):null});return g.add(I),g.eachChild(function(t){t.silent=!0}),I.silent=!u,this.getContentGroup().add(g),co(g),g.__legendDataIndex=e,g},layoutInner:function(t,e,i){var n=this.getContentGroup();rI(t.get("orient"),n,t.get("itemGap"),i.width,i.height);var o=n.getBoundingRect();return n.attr("position",[-o.x,-o.y]),this.group.getBoundingRect()},remove:function(){this.getContentGroup().removeAll(),this._isFirstRender=!0}});Ns(function(t){var e=t.findComponents({mainType:"legend"});e&&e.length&&t.filterSeries(function(t){for(var i=0;ii[l],p=[-c.x,-c.y];n||(p[s]=o.position[s]);var g=[0,0],m=[-d.x,-d.y],v=A(t.get("pageButtonGap",!0),t.get("itemGap",!0));f&&("end"===t.get("pageButtonPosition",!0)?m[s]+=i[l]-d[l]:g[s]+=d[l]+v),m[1-s]+=c[u]/2-d[u]/2,o.attr("position",p),a.attr("position",g),r.attr("position",m);var y=this.group.getBoundingRect();if((y={x:0,y:0})[l]=f?i[l]:c[l],y[u]=Math.max(c[u],d[u]),y[h]=Math.min(0,d[h]+m[1-s]),a.__rectSize=i[l],f){var x={x:0,y:0};x[l]=Math.max(i[l]-d[l]-v,0),x[u]=y[u],a.setClipPath(new yM({shape:x})),a.__rectSize=x[l]}else r.eachChild(function(t){t.attr({invisible:!0,silent:!0})});var _=this._getPageInfo(t);return null!=_.pageIndex&&Mo(o,{position:_.contentPosition},!!f&&t),this._updatePageInfoView(t,_),y},_pageGo:function(t,e,i){var n=this._getPageInfo(e)[t];null!=n&&i.dispatchAction({type:"legendScroll",scrollDataIndex:n,legendId:e.id})},_updatePageInfoView:function(t,e){var i=this._controllerGroup;d(["pagePrev","pageNext"],function(n){var o=null!=e[n+"DataIndex"],a=i.childOfName(n);a&&(a.setStyle("fill",o?t.get("pageIconColor",!0):t.get("pageIconInactiveColor",!0)),a.cursor=o?"pointer":"default")});var n=i.childOfName("pageText"),o=t.get("pageFormatter"),a=e.pageIndex,r=null!=a?a+1:0,s=e.pageCount;n&&o&&n.setStyle("text",_(o)?o.replace("{current}",r).replace("{total}",s):o({current:r,total:s}))},_getPageInfo:function(t){function e(t){if(t){var e=t.getBoundingRect(),i=e[l]+t.position[r];return{s:i,e:i+e[s],i:t.__legendDataIndex}}}function i(t,e){return t.e>=e&&t.s<=e+a}var n=t.get("scrollDataIndex",!0),o=this.getContentGroup(),a=this._containerGroup.__rectSize,r=t.getOrient().index,s=oN[r],l=aN[r],u=this._findTargetItemIndex(n),h=o.children(),c=h[u],d=h.length,f=d?1:0,p={contentPosition:o.position.slice(),pageCount:f,pageIndex:f-1,pagePrevDataIndex:null,pageNextDataIndex:null};if(!c)return p;var g=e(c);p.contentPosition[r]=-g.s;for(var m=u+1,v=g,y=g,x=null;m<=d;++m)(!(x=e(h[m]))&&y.e>v.s+a||x&&!i(x,v.s))&&(v=y.i>v.i?y:x)&&(null==p.pageNextDataIndex&&(p.pageNextDataIndex=v.i),++p.pageCount),y=x;for(var m=u-1,v=g,y=g,x=null;m>=-1;--m)(x=e(h[m]))&&i(y,x.s)||!(v.i=0;){var r=o.indexOf("|}"),s=o.substr(a+"{marker".length,r-a-"{marker".length);s.indexOf("sub")>-1?n["marker"+s]={textWidth:4,textHeight:4,textBorderRadius:2,textBackgroundColor:e[s],textOffset:[3,0]}:n["marker"+s]={textWidth:10,textHeight:10,textBorderRadius:5,textBackgroundColor:e[s]},a=(o=o.substr(r+1)).indexOf("{marker")}this.el=new rM({style:{rich:n,text:t,textLineHeight:20,textBackgroundColor:i.get("backgroundColor"),textBorderRadius:i.get("borderRadius"),textFill:i.get("textStyle.color"),textPadding:i.get("padding")},z:i.get("z")}),this._zr.add(this.el);var l=this;this.el.on("mouseover",function(){l._enterable&&(clearTimeout(l._hideTimeout),l._show=!0),l._inContent=!0}),this.el.on("mouseout",function(){l._enterable&&l._show&&l.hideLater(l._hideDelay),l._inContent=!1})},setEnterable:function(t){this._enterable=t},getSize:function(){var t=this.el.getBoundingRect();return[t.width,t.height]},moveTo:function(t,e){this.el&&this.el.attr("position",[t,e])},hide:function(){this.el.hide(),this._show=!1},hideLater:function(t){!this._show||this._inContent&&this._enterable||(t?(this._hideDelay=t,this._show=!1,this._hideTimeout=setTimeout(m(this.hide,this),t)):this.hide())},isShow:function(){return this._show},getOuterSize:function(){return this.getSize()}};var hN=m,cN=d,dN=Bo,fN=new yM({shape:{x:-1,y:-1,width:2,height:2}});Fs({type:"tooltip",init:function(t,e){if(!U_.node){var i=t.getComponent("tooltip").get("renderMode");this._renderMode=Hi(i);var n;"html"===this._renderMode?(n=new Cv(e.getDom(),e),this._newLine="
    "):(n=new Lv(e),this._newLine="\n"),this._tooltipContent=n}},render:function(t,e,i){if(!U_.node){this.group.removeAll(),this._tooltipModel=t,this._ecModel=e,this._api=i,this._lastDataByCoordSys=null,this._alwaysShowContent=t.get("alwaysShowContent");var n=this._tooltipContent;n.update(),n.setEnterable(t.get("enterable")),this._initGlobalListener(),this._keepShow()}},_initGlobalListener:function(){var t=this._tooltipModel.get("triggerOn");um("itemTooltip",this._api,hN(function(e,i,n){"none"!==t&&(t.indexOf(e)>=0?this._tryShow(i,n):"leave"===e&&this._hide(n))},this))},_keepShow:function(){var t=this._tooltipModel,e=this._ecModel,i=this._api;if(null!=this._lastX&&null!=this._lastY&&"none"!==t.get("triggerOn")){var n=this;clearTimeout(this._refreshUpdateTimeout),this._refreshUpdateTimeout=setTimeout(function(){n.manuallyShowTip(t,e,i,{x:n._lastX,y:n._lastY})})}},manuallyShowTip:function(t,e,i,n){if(n.from!==this.uid&&!U_.node){var o=Pv(n,i);this._ticket="";var a=n.dataByCoordSys;if(n.tooltip&&null!=n.x&&null!=n.y){var r=fN;r.position=[n.x,n.y],r.update(),r.tooltip=n.tooltip,this._tryShow({offsetX:n.x,offsetY:n.y,target:r},o)}else if(a)this._tryShow({offsetX:n.x,offsetY:n.y,position:n.position,event:{},dataByCoordSys:n.dataByCoordSys,tooltipOption:n.tooltipOption},o);else if(null!=n.seriesIndex){if(this._manuallyAxisShowTip(t,e,i,n))return;var s=_P(n,e),l=s.point[0],u=s.point[1];null!=l&&null!=u&&this._tryShow({offsetX:l,offsetY:u,position:n.position,target:s.el,event:{}},o)}else null!=n.x&&null!=n.y&&(i.dispatchAction({type:"updateAxisPointer",x:n.x,y:n.y}),this._tryShow({offsetX:n.x,offsetY:n.y,position:n.position,target:i.getZr().findHover(n.x,n.y).target,event:{}},o))}},manuallyHideTip:function(t,e,i,n){var o=this._tooltipContent;!this._alwaysShowContent&&this._tooltipModel&&o.hideLater(this._tooltipModel.get("hideDelay")),this._lastX=this._lastY=null,n.from!==this.uid&&this._hide(Pv(n,i))},_manuallyAxisShowTip:function(t,e,i,n){var o=n.seriesIndex,a=n.dataIndex,r=e.getComponent("axisPointer").coordSysAxesInfo;if(null!=o&&null!=a&&null!=r){var s=e.getSeriesByIndex(o);if(s&&"axis"===(t=kv([s.getData().getItemModel(a),s,(s.coordinateSystem||{}).model,t])).get("trigger"))return i.dispatchAction({type:"updateAxisPointer",seriesIndex:o,dataIndex:a,position:n.position}),!0}},_tryShow:function(t,e){var i=t.target;if(this._tooltipModel){this._lastX=t.offsetX,this._lastY=t.offsetY;var n=t.dataByCoordSys;n&&n.length?this._showAxisTooltip(n,t):i&&null!=i.dataIndex?(this._lastDataByCoordSys=null,this._showSeriesItemTooltip(t,i,e)):i&&i.tooltip?(this._lastDataByCoordSys=null,this._showComponentItemTooltip(t,i,e)):(this._lastDataByCoordSys=null,this._hide(e))}},_showOrMove:function(t,e){var i=t.get("showDelay");e=m(e,this),clearTimeout(this._showTimout),i>0?this._showTimout=setTimeout(e,i):e()},_showAxisTooltip:function(t,e){var i=this._ecModel,o=this._tooltipModel,a=[e.offsetX,e.offsetY],r=[],s=[],l=kv([e.tooltipOption,o]),u=this._renderMode,h=this._newLine,c={};cN(t,function(t){cN(t.dataByAxis,function(t){var e=i.getComponent(t.axisDim+"Axis",t.axisIndex),o=t.value,a=[];if(e&&null!=o){var l=Im(o,e.axis,i,t.seriesDataIndices,t.valueLabelOpt);d(t.seriesDataIndices,function(r){var h=i.getSeriesByIndex(r.seriesIndex),d=r.dataIndexInside,f=h&&h.getDataParams(d);if(f.axisDim=t.axisDim,f.axisIndex=t.axisIndex,f.axisType=t.axisType,f.axisId=t.axisId,f.axisValue=Ul(e.axis,o),f.axisValueLabel=l,f){s.push(f);var p,g=h.formatTooltip(d,!0,null,u);if(w(g)){p=g.html;var m=g.markers;n(c,m)}else p=g;a.push(p)}});var f=l;"html"!==u?r.push(a.join(h)):r.push((f?ea(f)+h:"")+a.join(h))}})},this),r.reverse(),r=r.join(this._newLine+this._newLine);var f=e.position;this._showOrMove(l,function(){this._updateContentNotChangedOnAxis(t)?this._updatePosition(l,f,a[0],a[1],this._tooltipContent,s):this._showTooltipContent(l,r,s,Math.random(),a[0],a[1],f,void 0,c)})},_showSeriesItemTooltip:function(t,e,i){var n=this._ecModel,o=e.seriesIndex,a=n.getSeriesByIndex(o),r=e.dataModel||a,s=e.dataIndex,l=e.dataType,u=r.getData(),h=kv([u.getItemModel(s),r,a&&(a.coordinateSystem||{}).model,this._tooltipModel]),c=h.get("trigger");if(null==c||"item"===c){var d,f,p=r.getDataParams(s,l),g=r.formatTooltip(s,!1,l,this._renderMode);w(g)?(d=g.html,f=g.markers):(d=g,f=null);var m="item_"+r.name+"_"+s;this._showOrMove(h,function(){this._showTooltipContent(h,d,p,m,t.offsetX,t.offsetY,t.position,t.target,f)}),i({type:"showTip",dataIndexInside:s,dataIndex:u.getRawIndex(s),seriesIndex:o,from:this.uid})}},_showComponentItemTooltip:function(t,e,i){var n=e.tooltip;if("string"==typeof n){var o=n;n={content:o,formatter:o}}var a=new Po(n,this._tooltipModel,this._ecModel),r=a.get("content"),s=Math.random();this._showOrMove(a,function(){this._showTooltipContent(a,r,a.get("formatterParams")||{},s,t.offsetX,t.offsetY,t.position,e)}),i({type:"showTip",from:this.uid})},_showTooltipContent:function(t,e,i,n,o,a,r,s,l){if(this._ticket="",t.get("showContent")&&t.get("show")){var u=this._tooltipContent,h=t.get("formatter");r=r||t.get("position");var c=e;if(h&&"string"==typeof h)c=ia(h,i,!0);else if("function"==typeof h){var d=hN(function(e,n){e===this._ticket&&(u.setContent(n,l,t),this._updatePosition(t,r,o,a,u,i,s))},this);this._ticket=n,c=h(i,n,d)}u.setContent(c,l,t),u.show(t),this._updatePosition(t,r,o,a,u,i,s)}},_updatePosition:function(t,e,i,n,o,a,r){var s=this._api.getWidth(),l=this._api.getHeight();e=e||t.get("position");var u=o.getSize(),h=t.get("align"),c=t.get("verticalAlign"),d=r&&r.getBoundingRect().clone();if(r&&d.applyTransform(r.transform),"function"==typeof e&&(e=e([i,n],a,o.el,d,{viewSize:[s,l],contentSize:u.slice()})),y(e))i=dN(e[0],s),n=dN(e[1],l);else if(w(e)){e.width=u[0],e.height=u[1];var f=ha(e,{width:s,height:l});i=f.x,n=f.y,h=null,c=null}else"string"==typeof e&&r?(i=(p=Ev(e,d,u))[0],n=p[1]):(i=(p=Nv(i,n,o,s,l,h?null:20,c?null:20))[0],n=p[1]);if(h&&(i-=Rv(h)?u[0]/2:"right"===h?u[0]:0),c&&(n-=Rv(c)?u[1]/2:"bottom"===c?u[1]:0),t.get("confine")){var p=Ov(i,n,o,s,l);i=p[0],n=p[1]}o.moveTo(i,n)},_updateContentNotChangedOnAxis:function(t){var e=this._lastDataByCoordSys,i=!!e&&e.length===t.length;return i&&cN(e,function(e,n){var o=e.dataByAxis||{},a=(t[n]||{}).dataByAxis||[];(i&=o.length===a.length)&&cN(o,function(t,e){var n=a[e]||{},o=t.seriesDataIndices||[],r=n.seriesDataIndices||[];(i&=t.value===n.value&&t.axisType===n.axisType&&t.axisId===n.axisId&&o.length===r.length)&&cN(o,function(t,e){var n=r[e];i&=t.seriesIndex===n.seriesIndex&&t.dataIndex===n.dataIndex})})}),this._lastDataByCoordSys=t,!!i},_hide:function(t){this._lastDataByCoordSys=null,t({type:"hideTip",from:this.uid})},dispose:function(t,e){U_.node||(this._tooltipContent.hide(),gm("itemTooltip",e))}}),Os({type:"showTip",event:"showTip",update:"tooltip:manuallyShowTip"},function(){}),Os({type:"hideTip",event:"hideTip",update:"tooltip:manuallyHideTip"},function(){}),Gv.prototype={constructor:Gv,pointToData:function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},dataToRadius:rD.prototype.dataToCoord,radiusToData:rD.prototype.coordToData},u(Gv,rD);var pN=Bi();Fv.prototype={constructor:Fv,pointToData:function(t,e){return this.polar.pointToData(t,e)["radius"===this.dim?0:1]},dataToAngle:rD.prototype.dataToCoord,angleToData:rD.prototype.coordToData,calculateCategoryInterval:function(){var t=this,e=t.getLabelModel(),i=t.scale,n=i.getExtent(),o=i.count();if(n[1]-n[0]<1)return 0;var a=n[0],r=t.dataToCoord(a+1)-t.dataToCoord(a),s=Math.abs(r),l=ke(a,e.getFont(),"center","top"),u=Math.max(l.height,7)/s;isNaN(u)&&(u=1/0);var h=Math.max(0,Math.floor(u)),c=pN(t.model),d=c.lastAutoInterval,f=c.lastTickCount;return null!=d&&null!=f&&Math.abs(d-h)<=1&&Math.abs(f-o)<=1&&d>h?h=d:(c.lastTickCount=o,c.lastAutoInterval=h),h}},u(Fv,rD);var gN=function(t){this.name=t||"",this.cx=0,this.cy=0,this._radiusAxis=new Gv,this._angleAxis=new Fv,this._radiusAxis.polar=this._angleAxis.polar=this};gN.prototype={type:"polar",axisPointerEnabled:!0,constructor:gN,dimensions:["radius","angle"],model:null,containPoint:function(t){var e=this.pointToCoord(t);return this._radiusAxis.contain(e[0])&&this._angleAxis.contain(e[1])},containData:function(t){return this._radiusAxis.containData(t[0])&&this._angleAxis.containData(t[1])},getAxis:function(t){return this["_"+t+"Axis"]},getAxes:function(){return[this._radiusAxis,this._angleAxis]},getAxesByScale:function(t){var e=[],i=this._angleAxis,n=this._radiusAxis;return i.scale.type===t&&e.push(i),n.scale.type===t&&e.push(n),e},getAngleAxis:function(){return this._angleAxis},getRadiusAxis:function(){return this._radiusAxis},getOtherAxis:function(t){var e=this._angleAxis;return t===e?this._radiusAxis:e},getBaseAxis:function(){return this.getAxesByScale("ordinal")[0]||this.getAxesByScale("time")[0]||this.getAngleAxis()},getTooltipAxes:function(t){var e=null!=t&&"auto"!==t?this.getAxis(t):this.getBaseAxis();return{baseAxes:[e],otherAxes:[this.getOtherAxis(e)]}},dataToPoint:function(t,e){return this.coordToPoint([this._radiusAxis.dataToRadius(t[0],e),this._angleAxis.dataToAngle(t[1],e)])},pointToData:function(t,e){var i=this.pointToCoord(t);return[this._radiusAxis.radiusToData(i[0],e),this._angleAxis.angleToData(i[1],e)]},pointToCoord:function(t){var e=t[0]-this.cx,i=t[1]-this.cy,n=this.getAngleAxis(),o=n.getExtent(),a=Math.min(o[0],o[1]),r=Math.max(o[0],o[1]);n.inverse?a=r-360:r=a+360;var s=Math.sqrt(e*e+i*i);e/=s,i/=s;for(var l=Math.atan2(-i,e)/Math.PI*180,u=lr;)l+=360*u;return[s,l]},coordToPoint:function(t){var e=t[0],i=t[1]/180*Math.PI;return[Math.cos(i)*e+this.cx,-Math.sin(i)*e+this.cy]}};var mN=uI.extend({type:"polarAxis",axis:null,getCoordSysModel:function(){return this.ecModel.queryComponents({mainType:"polar",index:this.option.polarIndex,id:this.option.polarId})[0]}});n(mN.prototype,XA);var vN={angle:{startAngle:90,clockwise:!0,splitNumber:12,axisLabel:{rotate:!1}},radius:{splitNumber:5}};RD("angle",mN,Wv,vN.angle),RD("radius",mN,Wv,vN.radius),Gs({type:"polar",dependencies:["polarAxis","angleAxis"],coordinateSystem:null,findAxisModel:function(t){var e;return this.ecModel.eachComponent(t,function(t){t.getCoordSysModel()===this&&(e=t)},this),e},defaultOption:{zlevel:0,z:0,center:["50%","50%"],radius:"80%"}});var yN={dimensions:gN.prototype.dimensions,create:function(t,e){var i=[];return t.eachComponent("polar",function(t,n){var o=new gN(n);o.update=Zv;var a=o.getRadiusAxis(),r=o.getAngleAxis(),s=t.findAxisModel("radiusAxis"),l=t.findAxisModel("angleAxis");Uv(a,s),Uv(r,l),Hv(o,t,e),i.push(o),t.coordinateSystem=o,o.model=t}),t.eachSeries(function(e){if("polar"===e.get("coordinateSystem")){var i=t.queryComponents({mainType:"polar",index:e.get("polarIndex"),id:e.get("polarId")})[0];e.coordinateSystem=i.coordinateSystem}}),i}};Ga.register("polar",yN);var xN=["axisLine","axisLabel","axisTick","splitLine","splitArea"];jD.extend({type:"angleAxis",axisPointerClass:"PolarAxisPointer",render:function(t,e){if(this.group.removeAll(),t.get("show")){var n=t.axis,o=n.polar,a=o.getRadiusAxis().getExtent(),r=n.getTicksCoords(),s=f(n.getViewLabels(),function(t){return(t=i(t)).coord=n.dataToCoord(t.tickValue),t});Yv(s),Yv(r),d(xN,function(e){!t.get(e+".show")||n.scale.isBlank()&&"axisLine"!==e||this["_"+e](t,o,r,a,s)},this)}},_axisLine:function(t,e,i,n){var o=t.getModel("axisLine.lineStyle"),a=new sM({shape:{cx:e.cx,cy:e.cy,r:n[jv(e)]},style:o.getLineStyle(),z2:1,silent:!0});a.style.fill=null,this.group.add(a)},_axisTick:function(t,e,i,n){var o=t.getModel("axisTick"),a=(o.get("inside")?-1:1)*o.get("length"),s=n[jv(e)],l=f(i,function(t){return new _M({shape:Xv(e,[s,s+a],t.coord)})});this.group.add(OM(l,{style:r(o.getModel("lineStyle").getLineStyle(),{stroke:t.get("axisLine.lineStyle.color")})}))},_axisLabel:function(t,e,i,n,o){var a=t.getCategories(!0),r=t.getModel("axisLabel"),s=r.get("margin");d(o,function(i,o){var l=r,u=i.tickValue,h=n[jv(e)],c=e.coordToPoint([h+s,i.coord]),d=e.cx,f=e.cy,p=Math.abs(c[0]-d)/h<.3?"center":c[0]>d?"left":"right",g=Math.abs(c[1]-f)/h<.3?"middle":c[1]>f?"top":"bottom";a&&a[u]&&a[u].textStyle&&(l=new Po(a[u].textStyle,r,r.ecModel));var m=new rM({silent:!0});this.group.add(m),go(m.style,l,{x:c[0],y:c[1],textFill:l.getTextColor()||t.get("axisLine.lineStyle.color"),text:i.formattedLabel,textAlign:p,textVerticalAlign:g})},this)},_splitLine:function(t,e,i,n){var o=t.getModel("splitLine").getModel("lineStyle"),a=o.get("color"),s=0;a=a instanceof Array?a:[a];for(var l=[],u=0;u=0?"p":"n",M=y;v&&(n[r][b]||(n[r][b]={p:y,n:y}),M=n[r][b][S]);var I,T,A,D;if("radius"===h.dim){var C=h.dataToRadius(w)-y,L=a.dataToAngle(b);Math.abs(C)=0},PN.findTargetInfo=function(t,e){for(var i=this._targetInfoList,n=dy(e,t),o=0;o=0||DN(n,t.getAxis("y").model)>=0)&&a.push(t)}),e.push({panelId:"grid--"+t.id,gridModel:t,coordSysModel:t,coordSys:a[0],coordSyses:a,getPanelRect:EN.grid,xAxisDeclared:r[t.id],yAxisDeclared:s[t.id]})}))},geo:function(t,e){AN(t.geoModels,function(t){var i=t.coordinateSystem;e.push({panelId:"geo--"+t.id,geoModel:t,coordSysModel:t,coordSys:i,coordSyses:[i],getPanelRect:EN.geo})})}},ON=[function(t,e){var i=t.xAxisModel,n=t.yAxisModel,o=t.gridModel;return!o&&i&&(o=i.axis.grid.model),!o&&n&&(o=n.axis.grid.model),o&&o===e.gridModel},function(t,e){var i=t.geoModel;return i&&i===e.geoModel}],EN={grid:function(){return this.coordSys.grid.getRect().clone()},geo:function(){var t=this.coordSys,e=t.getBoundingRect().clone();return e.applyTransform(To(t)),e}},RN={lineX:CN(fy,0),lineY:CN(fy,1),rect:function(t,e,i){var n=e[LN[t]]([i[0][0],i[1][0]]),o=e[LN[t]]([i[0][1],i[1][1]]),a=[cy([n[0],o[0]]),cy([n[1],o[1]])];return{values:a,xyMinMax:a}},polygon:function(t,e,i){var n=[[1/0,-1/0],[1/0,-1/0]];return{values:f(i,function(i){var o=e[LN[t]](i);return n[0][0]=Math.min(n[0][0],o[0]),n[1][0]=Math.min(n[1][0],o[1]),n[0][1]=Math.max(n[0][1],o[0]),n[1][1]=Math.max(n[1][1],o[1]),o}),xyMinMax:n}}},zN={lineX:CN(py,0),lineY:CN(py,1),rect:function(t,e,i){return[[t[0][0]-i[0]*e[0][0],t[0][1]-i[0]*e[0][1]],[t[1][0]-i[1]*e[1][0],t[1][1]-i[1]*e[1][1]]]},polygon:function(t,e,i){return f(t,function(t,n){return[t[0]-i[0]*e[n][0],t[1]-i[1]*e[n][1]]})}},BN=["inBrush","outOfBrush"],VN="__ecBrushSelect",GN="__ecInBrushSelectEvent",FN=GT.VISUAL.BRUSH;Rs(FN,function(t,e,i){t.eachComponent({mainType:"brush"},function(e){i&&"takeGlobalCursor"===i.type&&e.setBrushOption("brush"===i.key?i.brushOption:{brushType:!1}),(e.brushTargetManager=new hy(e.option,t)).setInputRanges(e.areas,t)})}),zs(FN,function(t,e,n){var o,a,s=[];t.eachComponent({mainType:"brush"},function(e,n){function l(t){return"all"===m||v[t]}function u(t){return!!t.length}function h(t,e){var i=t.coordinateSystem;w|=i.hasAxisBrushed(),l(e)&&i.eachActiveState(t.getData(),function(t,e){"active"===t&&(x[e]=1)})}function c(i,n,o){var a=_y(i);if(a&&!wy(e,n)&&(d(b,function(n){a[n.brushType]&&e.brushTargetManager.controlSeries(n,i,t)&&o.push(n),w|=u(o)}),l(n)&&u(o))){var r=i.getData();r.each(function(t){xy(a,o,r,t)&&(x[t]=1)})}}var p={brushId:e.id,brushIndex:n,brushName:e.name,areas:i(e.areas),selected:[]};s.push(p);var g=e.option,m=g.brushLink,v=[],x=[],_=[],w=0;n||(o=g.throttleType,a=g.throttleDelay);var b=f(e.areas,function(t){return by(r({boundingRect:WN[t.brushType](t)},t))}),S=ty(e.option,BN,function(t){t.mappingMethod="fixed"});y(m)&&d(m,function(t){v[t]=1}),t.eachSeries(function(t,e){var i=_[e]=[];"parallel"===t.subType?h(t,e):c(t,e,i)}),t.eachSeries(function(t,e){var i={seriesId:t.id,seriesIndex:e,seriesName:t.name,dataIndex:[]};p.selected.push(i);var n=_y(t),o=_[e],a=t.getData(),r=l(e)?function(t){return x[t]?(i.dataIndex.push(a.getRawIndex(t)),"inBrush"):"outOfBrush"}:function(t){return xy(n,o,a,t)?(i.dataIndex.push(a.getRawIndex(t)),"inBrush"):"outOfBrush"};(l(e)?w:u(o))&&iy(BN,S,a,r)})}),vy(e,o,a,s,n)});var WN={lineX:B,lineY:B,rect:function(t){return Sy(t.range)},polygon:function(t){for(var e,i=t.range,n=0,o=i.length;ne[0][1]&&(e[0][1]=a[0]),a[1]e[1][1]&&(e[1][1]=a[1])}return e&&Sy(e)}},HN=["#ddd"];Gs({type:"brush",dependencies:["geo","grid","xAxis","yAxis","parallel","series"],defaultOption:{toolbox:null,brushLink:null,seriesIndex:"all",geoIndex:null,xAxisIndex:null,yAxisIndex:null,brushType:"rect",brushMode:"single",transformable:!0,brushStyle:{borderWidth:1,color:"rgba(120,140,180,0.3)",borderColor:"rgba(120,140,180,0.8)"},throttleType:"fixRate",throttleDelay:0,removeOnClick:!0,z:1e4},areas:[],brushType:null,brushOption:{},coordInfoList:[],optionUpdated:function(t,e){var i=this.option;!e&&ey(i,t,["inBrush","outOfBrush"]);var n=i.inBrush=i.inBrush||{};i.outOfBrush=i.outOfBrush||{color:HN},n.hasOwnProperty("liftZ")||(n.liftZ=5)},setAreas:function(t){t&&(this.areas=f(t,function(t){return My(this.option,t)},this))},setBrushOption:function(t){this.brushOption=My(this.option,t),this.brushType=this.brushOption.brushType}});Fs({type:"brush",init:function(t,e){this.ecModel=t,this.api=e,this.model,(this._brushController=new Rf(e.getZr())).on("brush",m(this._onBrush,this)).mount()},render:function(t){return this.model=t,Iy.apply(this,arguments)},updateTransform:Iy,updateView:Iy,dispose:function(){this._brushController.dispose()},_onBrush:function(t,e){var n=this.model.id;this.model.brushTargetManager.setOutputRanges(t,this.ecModel),(!e.isEnd||e.removeOnClick)&&this.api.dispatchAction({type:"brush",brushId:n,areas:i(t),$from:n})}}),Os({type:"brush",event:"brush"},function(t,e){e.eachComponent({mainType:"brush",query:t},function(e){e.setAreas(t.areas)})}),Os({type:"brushSelect",event:"brushSelected",update:"none"},function(){});var ZN={},UN=sT.toolbox.brush;Dy.defaultOption={show:!0,type:["rect","polygon","lineX","lineY","keep","clear"],icon:{rect:"M7.3,34.7 M0.4,10V-0.2h9.8 M89.6,10V-0.2h-9.8 M0.4,60v10.2h9.8 M89.6,60v10.2h-9.8 M12.3,22.4V10.5h13.1 M33.6,10.5h7.8 M49.1,10.5h7.8 M77.5,22.4V10.5h-13 M12.3,31.1v8.2 M77.7,31.1v8.2 M12.3,47.6v11.9h13.1 M33.6,59.5h7.6 M49.1,59.5 h7.7 M77.5,47.6v11.9h-13",polygon:"M55.2,34.9c1.7,0,3.1,1.4,3.1,3.1s-1.4,3.1-3.1,3.1 s-3.1-1.4-3.1-3.1S53.5,34.9,55.2,34.9z M50.4,51c1.7,0,3.1,1.4,3.1,3.1c0,1.7-1.4,3.1-3.1,3.1c-1.7,0-3.1-1.4-3.1-3.1 C47.3,52.4,48.7,51,50.4,51z M55.6,37.1l1.5-7.8 M60.1,13.5l1.6-8.7l-7.8,4 M59,19l-1,5.3 M24,16.1l6.4,4.9l6.4-3.3 M48.5,11.6 l-5.9,3.1 M19.1,12.8L9.7,5.1l1.1,7.7 M13.4,29.8l1,7.3l6.6,1.6 M11.6,18.4l1,6.1 M32.8,41.9 M26.6,40.4 M27.3,40.2l6.1,1.6 M49.9,52.1l-5.6-7.6l-4.9-1.2",lineX:"M15.2,30 M19.7,15.6V1.9H29 M34.8,1.9H40.4 M55.3,15.6V1.9H45.9 M19.7,44.4V58.1H29 M34.8,58.1H40.4 M55.3,44.4 V58.1H45.9 M12.5,20.3l-9.4,9.6l9.6,9.8 M3.1,29.9h16.5 M62.5,20.3l9.4,9.6L62.3,39.7 M71.9,29.9H55.4",lineY:"M38.8,7.7 M52.7,12h13.2v9 M65.9,26.6V32 M52.7,46.3h13.2v-9 M24.9,12H11.8v9 M11.8,26.6V32 M24.9,46.3H11.8v-9 M48.2,5.1l-9.3-9l-9.4,9.2 M38.9-3.9V12 M48.2,53.3l-9.3,9l-9.4-9.2 M38.9,62.3V46.4",keep:"M4,10.5V1h10.3 M20.7,1h6.1 M33,1h6.1 M55.4,10.5V1H45.2 M4,17.3v6.6 M55.6,17.3v6.6 M4,30.5V40h10.3 M20.7,40 h6.1 M33,40h6.1 M55.4,30.5V40H45.2 M21,18.9h62.9v48.6H21V18.9z",clear:"M22,14.7l30.9,31 M52.9,14.7L22,45.7 M4.7,16.8V4.2h13.1 M26,4.2h7.8 M41.6,4.2h7.8 M70.3,16.8V4.2H57.2 M4.7,25.9v8.6 M70.3,25.9v8.6 M4.7,43.2v12.6h13.1 M26,55.8h7.8 M41.6,55.8h7.8 M70.3,43.2v12.6H57.2"},title:i(UN.title)};var XN=Dy.prototype;XN.render=XN.updateView=function(t,e,i){var n,o,a;e.eachComponent({mainType:"brush"},function(t){n=t.brushType,o=t.brushOption.brushMode||"single",a|=t.areas.length}),this._brushType=n,this._brushMode=o,d(t.get("type",!0),function(e){t.setIconStatus(e,("keep"===e?"multiple"===o:"clear"===e?a:e===n)?"emphasis":"normal")})},XN.getIcons=function(){var t=this.model,e=t.get("icon",!0),i={};return d(t.get("type",!0),function(t){e[t]&&(i[t]=e[t])}),i},XN.onclick=function(t,e,i){var n=this._brushType,o=this._brushMode;"clear"===i?(e.dispatchAction({type:"axisAreaSelect",intervals:[]}),e.dispatchAction({type:"brush",command:"clear",areas:[]})):e.dispatchAction({type:"takeGlobalCursor",key:"brush",brushOption:{brushType:"keep"===i?n:n!==i&&i,brushMode:"keep"===i?"multiple"===o?"single":"multiple":o}})},Ty("brush",Dy),Ps(function(t,e){var i=t&&t.brush;if(y(i)||(i=i?[i]:[]),i.length){var n=[];d(i,function(t){var e=t.hasOwnProperty("toolbox")?t.toolbox:[];e instanceof Array&&(n=n.concat(e))});var o=t&&t.toolbox;y(o)&&(o=o[0]),o||(o={feature:{}},t.toolbox=[o]);var a=o.feature||(o.feature={}),r=a.brush||(a.brush={}),s=r.type||(r.type=[]);s.push.apply(s,n),Jv(s),e&&!s.length&&s.push.apply(s,MN)}});Cy.prototype={constructor:Cy,type:"calendar",dimensions:["time","value"],getDimensionsInfo:function(){return[{name:"time",type:"time"},"value"]},getRangeInfo:function(){return this._rangeInfo},getModel:function(){return this._model},getRect:function(){return this._rect},getCellWidth:function(){return this._sw},getCellHeight:function(){return this._sh},getOrient:function(){return this._orient},getFirstDayOfWeek:function(){return this._firstDayOfWeek},getDateInfo:function(t){var e=(t=jo(t)).getFullYear(),i=t.getMonth()+1;i=i<10?"0"+i:i;var n=t.getDate();n=n<10?"0"+n:n;var o=t.getDay();return o=Math.abs((o+7-this.getFirstDayOfWeek())%7),{y:e,m:i,d:n,day:o,time:t.getTime(),formatedDate:e+"-"+i+"-"+n,date:t}},getNextNDay:function(t,e){return 0===(e=e||0)?this.getDateInfo(t):((t=new Date(this.getDateInfo(t).time)).setDate(t.getDate()+e),this.getDateInfo(t))},update:function(t,e){function i(t,e){return null!=t[e]&&"auto"!==t[e]}this._firstDayOfWeek=+this._model.getModel("dayLabel").get("firstDay"),this._orient=this._model.get("orient"),this._lineWidth=this._model.getModel("itemStyle").getItemStyle().lineWidth||0,this._rangeInfo=this._getRangeInfo(this._initRangeOption());var n=this._rangeInfo.weeks||1,o=["width","height"],a=this._model.get("cellSize").slice(),r=this._model.getBoxLayoutParams(),s="horizontal"===this._orient?[n,7]:[7,n];d([0,1],function(t){i(a,t)&&(r[o[t]]=a[t]*s[t])});var l={width:e.getWidth(),height:e.getHeight()},u=this._rect=ha(r,l);d([0,1],function(t){i(a,t)||(a[t]=u[o[t]]/s[t])}),this._sw=a[0],this._sh=a[1]},dataToPoint:function(t,e){y(t)&&(t=t[0]),null==e&&(e=!0);var i=this.getDateInfo(t),n=this._rangeInfo,o=i.formatedDate;if(e&&!(i.time>=n.start.time&&i.timea.end.time&&t.reverse(),t},_getRangeInfo:function(t){var e;(t=[this.getDateInfo(t[0]),this.getDateInfo(t[1])])[0].time>t[1].time&&(e=!0,t.reverse());var i=Math.floor(t[1].time/864e5)-Math.floor(t[0].time/864e5)+1,n=new Date(t[0].time),o=n.getDate(),a=t[1].date.getDate();if(n.setDate(o+i-1),n.getDate()!==a)for(var r=n.getTime()-t[1].time>0?1:-1;n.getDate()!==a&&(n.getTime()-t[1].time)*r>0;)i-=r,n.setDate(o+i-1);var s=Math.floor((i+t[0].day+6)/7),l=e?1-s:s-1;return e&&t.reverse(),{range:[t[0].formatedDate,t[1].formatedDate],start:t[0],end:t[1],allDay:i,weeks:s,nthWeek:l,fweek:t[0].day,lweek:t[1].day}},_getDateByWeeksAndDay:function(t,e,i){var n=this._getRangeInfo(i);if(t>n.weeks||0===t&&en.lweek)return!1;var o=7*(t-1)-n.fweek+e,a=new Date(n.start.time);return a.setDate(n.start.d+o),this.getDateInfo(a)}},Cy.dimensions=Cy.prototype.dimensions,Cy.getDimensionsInfo=Cy.prototype.getDimensionsInfo,Cy.create=function(t,e){var i=[];return t.eachComponent("calendar",function(n){var o=new Cy(n,t,e);i.push(o),n.coordinateSystem=o}),t.eachSeries(function(t){"calendar"===t.get("coordinateSystem")&&(t.coordinateSystem=i[t.get("calendarIndex")||0])}),i},Ga.register("calendar",Cy);var jN=uI.extend({type:"calendar",coordinateSystem:null,defaultOption:{zlevel:0,z:2,left:80,top:60,cellSize:20,orient:"horizontal",splitLine:{show:!0,lineStyle:{color:"#000",width:1,type:"solid"}},itemStyle:{color:"#fff",borderWidth:1,borderColor:"#ccc"},dayLabel:{show:!0,firstDay:0,position:"start",margin:"50%",nameMap:"en",color:"#000"},monthLabel:{show:!0,position:"start",margin:5,align:"center",nameMap:"en",formatter:null,color:"#000"},yearLabel:{show:!0,position:null,margin:30,formatter:null,color:"#ccc",fontFamily:"sans-serif",fontWeight:"bolder",fontSize:20}},init:function(t,e,i,n){var o=pa(t);jN.superApply(this,"init",arguments),ky(t,o)},mergeOption:function(t,e){jN.superApply(this,"mergeOption",arguments),ky(this.option,t)}}),YN={EN:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],CN:["一月","二月","三月","四月","五月","六月","七月","八月","九月","十月","十一月","十二月"]},qN={EN:["S","M","T","W","T","F","S"],CN:["日","一","二","三","四","五","六"]};Fs({type:"calendar",_tlpoints:null,_blpoints:null,_firstDayOfMonth:null,_firstDayPoints:null,render:function(t,e,i){var n=this.group;n.removeAll();var o=t.coordinateSystem,a=o.getRangeInfo(),r=o.getOrient();this._renderDayRect(t,a,n),this._renderLines(t,a,r,n),this._renderYearText(t,a,r,n),this._renderMonthText(t,r,n),this._renderWeekText(t,a,r,n)},_renderDayRect:function(t,e,i){for(var n=t.coordinateSystem,o=t.getModel("itemStyle").getItemStyle(),a=n.getCellWidth(),r=n.getCellHeight(),s=e.start.time;s<=e.end.time;s=n.getNextNDay(s,1).time){var l=n.dataToRect([s],!1).tl,u=new yM({shape:{x:l[0],y:l[1],width:a,height:r},cursor:"default",style:o});i.add(u)}},_renderLines:function(t,e,i,n){function o(e){a._firstDayOfMonth.push(r.getDateInfo(e)),a._firstDayPoints.push(r.dataToRect([e],!1).tl);var o=a._getLinePointsOfOneWeek(t,e,i);a._tlpoints.push(o[0]),a._blpoints.push(o[o.length-1]),l&&a._drawSplitline(o,s,n)}var a=this,r=t.coordinateSystem,s=t.getModel("splitLine.lineStyle").getLineStyle(),l=t.get("splitLine.show"),u=s.lineWidth;this._tlpoints=[],this._blpoints=[],this._firstDayOfMonth=[],this._firstDayPoints=[];for(var h=e.start,c=0;h.time<=e.end.time;c++){o(h.formatedDate),0===c&&(h=r.getDateInfo(e.start.y+"-"+e.start.m));var d=h.date;d.setMonth(d.getMonth()+1),h=r.getDateInfo(d)}o(r.getNextNDay(e.end.time,1).formatedDate),l&&this._drawSplitline(a._getEdgesPoints(a._tlpoints,u,i),s,n),l&&this._drawSplitline(a._getEdgesPoints(a._blpoints,u,i),s,n)},_getEdgesPoints:function(t,e,i){var n=[t[0].slice(),t[t.length-1].slice()],o="horizontal"===i?0:1;return n[0][o]=n[0][o]-e/2,n[1][o]=n[1][o]+e/2,n},_drawSplitline:function(t,e,i){var n=new gM({z2:20,shape:{points:t},style:e});i.add(n)},_getLinePointsOfOneWeek:function(t,e,i){var n=t.coordinateSystem;e=n.getDateInfo(e);for(var o=[],a=0;a<7;a++){var r=n.getNextNDay(e.time,a),s=n.dataToRect([r.time],!1);o[2*r.day]=s.tl,o[2*r.day+1]=s["horizontal"===i?"bl":"tr"]}return o},_formatterLabel:function(t,e){return"string"==typeof t&&t?na(t,e):"function"==typeof t?t(e):e.nameMap},_yearTextPositionControl:function(t,e,i,n,o){e=e.slice();var a=["center","bottom"];"bottom"===n?(e[1]+=o,a=["center","top"]):"left"===n?e[0]-=o:"right"===n?(e[0]+=o,a=["center","top"]):e[1]-=o;var r=0;return"left"!==n&&"right"!==n||(r=Math.PI/2),{rotation:r,position:e,style:{textAlign:a[0],textVerticalAlign:a[1]}}},_renderYearText:function(t,e,i,n){var o=t.getModel("yearLabel");if(o.get("show")){var a=o.get("margin"),r=o.get("position");r||(r="horizontal"!==i?"top":"left");var s=[this._tlpoints[this._tlpoints.length-1],this._blpoints[0]],l=(s[0][0]+s[1][0])/2,u=(s[0][1]+s[1][1])/2,h="horizontal"===i?0:1,c={top:[l,s[h][1]],bottom:[l,s[1-h][1]],left:[s[1-h][0],u],right:[s[h][0],u]},d=e.start.y;+e.end.y>+e.start.y&&(d=d+"-"+e.end.y);var f=o.get("formatter"),p={start:e.start.y,end:e.end.y,nameMap:d},g=this._formatterLabel(f,p),m=new rM({z2:30});go(m.style,o,{text:g}),m.attr(this._yearTextPositionControl(m,c[r],i,r,a)),n.add(m)}},_monthTextPositionControl:function(t,e,i,n,o){var a="left",r="top",s=t[0],l=t[1];return"horizontal"===i?(l+=o,e&&(a="center"),"start"===n&&(r="bottom")):(s+=o,e&&(r="middle"),"start"===n&&(a="right")),{x:s,y:l,textAlign:a,textVerticalAlign:r}},_renderMonthText:function(t,e,i){var n=t.getModel("monthLabel");if(n.get("show")){var o=n.get("nameMap"),r=n.get("margin"),s=n.get("position"),l=n.get("align"),u=[this._tlpoints,this._blpoints];_(o)&&(o=YN[o.toUpperCase()]||[]);var h="start"===s?0:1,c="horizontal"===e?0:1;r="start"===s?-r:r;for(var d="center"===l,f=0;f=r[0]&&t<=r[1]}if(t===this._dataZoomModel){var n=this._dimName,o=this.getTargetSeriesModels(),a=t.get("filterMode"),r=this._valueWindow;"none"!==a&&JN(o,function(t){var e=t.getData(),o=e.mapDimension(n,!0);o.length&&("weakFilter"===a?e.filterSelf(function(t){for(var i,n,a,s=0;sr[1];if(u&&!h&&!c)return!0;u&&(a=!0),h&&(i=!0),c&&(n=!0)}return a&&i&&n}):JN(o,function(n){if("empty"===a)t.setData(e.map(n,function(t){return i(t)?t:NaN}));else{var o={};o[n]=r,e.selectRange(o)}}),JN(o,function(t){e.setApproximateExtent(r,t)}))})}}};var eO=d,iO=$N,nO=Gs({type:"dataZoom",dependencies:["xAxis","yAxis","zAxis","radiusAxis","angleAxis","singleAxis","series"],defaultOption:{zlevel:0,z:4,orient:null,xAxisIndex:null,yAxisIndex:null,filterMode:"filter",throttle:null,start:0,end:100,startValue:null,endValue:null,minSpan:null,maxSpan:null,minValueSpan:null,maxValueSpan:null,rangeMode:null},init:function(t,e,i){this._dataIntervalByAxis={},this._dataInfo={},this._axisProxies={},this.textStyleModel,this._autoThrottle=!0,this._rangePropMode=["percent","percent"];var n=By(t);this.mergeDefaultAndTheme(t,i),this.doInit(n)},mergeOption:function(t){var e=By(t);n(this.option,t,!0),this.doInit(e)},doInit:function(t){var e=this.option;U_.canvasSupported||(e.realtime=!1),this._setDefaultThrottle(t),Vy(this,t),eO([["start","startValue"],["end","endValue"]],function(t,i){"value"===this._rangePropMode[i]&&(e[t[0]]=null)},this),this.textStyleModel=this.getModel("textStyle"),this._resetTarget(),this._giveAxisProxies()},_giveAxisProxies:function(){var t=this._axisProxies;this.eachTargetAxis(function(e,i,n,o){var a=this.dependentModels[e.axis][i],r=a.__dzAxisProxy||(a.__dzAxisProxy=new tO(e.name,i,this,o));t[e.name+"_"+i]=r},this)},_resetTarget:function(){var t=this.option,e=this._judgeAutoMode();iO(function(e){var i=e.axisIndex;t[i]=Di(t[i])},this),"axisIndex"===e?this._autoSetAxisIndex():"orient"===e&&this._autoSetOrient()},_judgeAutoMode:function(){var t=this.option,e=!1;iO(function(i){null!=t[i.axisIndex]&&(e=!0)},this);var i=t.orient;return null==i&&e?"orient":e?void 0:(null==i&&(t.orient="horizontal"),"axisIndex")},_autoSetAxisIndex:function(){var t=!0,e=this.get("orient",!0),i=this.option,n=this.dependentModels;if(t){var o="vertical"===e?"y":"x";n[o+"Axis"].length?(i[o+"AxisIndex"]=[0],t=!1):eO(n.singleAxis,function(n){t&&n.get("orient",!0)===e&&(i.singleAxisIndex=[n.componentIndex],t=!1)})}t&&iO(function(e){if(t){var n=[],o=this.dependentModels[e.axis];if(o.length&&!n.length)for(var a=0,r=o.length;a0?100:20}},getFirstTargetAxisModel:function(){var t;return iO(function(e){if(null==t){var i=this.get(e.axisIndex);i.length&&(t=this.dependentModels[e.axis][i[0]])}},this),t},eachTargetAxis:function(t,e){var i=this.ecModel;iO(function(n){eO(this.get(n.axisIndex),function(o){t.call(e,n,o,this,i)},this)},this)},getAxisProxy:function(t,e){return this._axisProxies[t+"_"+e]},getAxisModel:function(t,e){var i=this.getAxisProxy(t,e);return i&&i.getAxisModel()},setRawRange:function(t,e){var i=this.option;eO([["start","startValue"],["end","endValue"]],function(e){null==t[e[0]]&&null==t[e[1]]||(i[e[0]]=t[e[0]],i[e[1]]=t[e[1]])},this),!e&&Vy(this,t)},getPercentRange:function(){var t=this.findRepresentativeAxisProxy();if(t)return t.getDataPercentWindow()},getValueRange:function(t,e){if(null!=t||null!=e)return this.getAxisProxy(t,e).getDataValueWindow();var i=this.findRepresentativeAxisProxy();return i?i.getDataValueWindow():void 0},findRepresentativeAxisProxy:function(t){if(t)return t.__dzAxisProxy;var e=this._axisProxies;for(var i in e)if(e.hasOwnProperty(i)&&e[i].hostedBy(this))return e[i];for(var i in e)if(e.hasOwnProperty(i)&&!e[i].hostedBy(this))return e[i]},getRangePropMode:function(){return this._rangePropMode.slice()}}),oO=KI.extend({type:"dataZoom",render:function(t,e,i,n){this.dataZoomModel=t,this.ecModel=e,this.api=i},getTargetCoordInfo:function(){function t(t,e,i,n){for(var o,a=0;a0&&e%g)p+=f;else{var i=null==t||isNaN(t)||""===t,n=i?0:rO(t,a,u,!0);i&&!l&&e?(c.push([c[c.length-1][0],0]),d.push([d[d.length-1][0],0])):!i&&l&&(c.push([p,0]),d.push([p,0])),c.push([p,n]),d.push([p,n]),p+=f,l=i}});var m=this.dataZoomModel;this._displayables.barGroup.add(new pM({shape:{points:c},style:r({fill:m.get("dataBackgroundColor")},m.getModel("dataBackground.areaStyle").getAreaStyle()),silent:!0,z2:-20})),this._displayables.barGroup.add(new gM({shape:{points:d},style:m.getModel("dataBackground.lineStyle").getLineStyle(),silent:!0,z2:-19}))}}},_prepareDataShadowInfo:function(){var t=this.dataZoomModel,e=t.get("showDataShadow");if(!1!==e){var i,n=this.ecModel;return t.eachTargetAxis(function(o,a){d(t.getAxisProxy(o.name,a).getTargetSeriesModels(),function(t){if(!(i||!0!==e&&l(dO,t.get("type"))<0)){var r,s=n.getComponent(o.axis,a).axis,u=Gy(o.name),h=t.coordinateSystem;null!=u&&h.getOtherAxis&&(r=h.getOtherAxis(s).inverse),u=t.getData().mapDimension(u),i={thisAxis:s,series:t,thisDim:o.name,otherDim:u,otherAxisInverse:r}}},this)},this),i}},_renderHandle:function(){var t=this._displayables,e=t.handles=[],i=t.handleLabels=[],n=this._displayables.barGroup,o=this._size,a=this.dataZoomModel;n.add(t.filler=new aO({draggable:!0,cursor:Fy(this._orient),drift:lO(this._onDragMove,this,"all"),onmousemove:function(t){mw(t.event)},ondragstart:lO(this._showDataInfo,this,!0),ondragend:lO(this._onDragEnd,this),onmouseover:lO(this._showDataInfo,this,!0),onmouseout:lO(this._showDataInfo,this,!1),style:{fill:a.get("fillerColor"),textPosition:"inside"}})),n.add(new aO(Kn({silent:!0,shape:{x:0,y:0,width:o[0],height:o[1]},style:{stroke:a.get("dataBackgroundColor")||a.get("borderColor"),lineWidth:1,fill:"rgba(0,0,0,0)"}}))),uO([0,1],function(t){var o=ko(a.get("handleIcon"),{cursor:Fy(this._orient),draggable:!0,drift:lO(this._onDragMove,this,t),onmousemove:function(t){mw(t.event)},ondragend:lO(this._onDragEnd,this),onmouseover:lO(this._showDataInfo,this,!0),onmouseout:lO(this._showDataInfo,this,!1)},{x:-1,y:0,width:2,height:2}),r=o.getBoundingRect();this._handleHeight=Bo(a.get("handleSize"),this._size[1]),this._handleWidth=r.width/r.height*this._handleHeight,o.setStyle(a.getModel("handleStyle").getItemStyle());var s=a.get("handleColor");null!=s&&(o.style.fill=s),n.add(e[t]=o);var l=a.textStyleModel;this.group.add(i[t]=new rM({silent:!0,invisible:!0,style:{x:0,y:0,text:"",textVerticalAlign:"middle",textAlign:"center",textFill:l.getTextColor(),textFont:l.getFont()},z2:10}))},this)},_resetInterval:function(){var t=this._range=this.dataZoomModel.getPercentRange(),e=this._getViewExtent();this._handleEnds=[rO(t[0],[0,100],e,!0),rO(t[1],[0,100],e,!0)]},_updateInterval:function(t,e){var i=this.dataZoomModel,n=this._handleEnds,o=this._getViewExtent(),a=i.findRepresentativeAxisProxy().getMinMaxSpan(),r=[0,100];tk(e,n,o,i.get("zoomLock")?"all":t,null!=a.minSpan?rO(a.minSpan,r,o,!0):null,null!=a.maxSpan?rO(a.maxSpan,r,o,!0):null);var s=this._range,l=this._range=sO([rO(n[0],o,r,!0),rO(n[1],o,r,!0)]);return!s||s[0]!==l[0]||s[1]!==l[1]},_updateView:function(t){var e=this._displayables,i=this._handleEnds,n=sO(i.slice()),o=this._size;uO([0,1],function(t){var n=e.handles[t],a=this._handleHeight;n.attr({scale:[a/2,a/2],position:[i[t],o[1]/2-a/2]})},this),e.filler.setShape({x:n[0],y:0,width:n[1]-n[0],height:o[1]}),this._updateDataInfo(t)},_updateDataInfo:function(t){function e(t){var e=To(n.handles[t].parent,this.group),i=Do(0===t?"right":"left",e),s=this._handleWidth/2+cO,l=Ao([c[t]+(0===t?-s:s),this._size[1]/2],e);o[t].setStyle({x:l[0],y:l[1],textVerticalAlign:a===hO?"middle":i,textAlign:a===hO?i:"center",text:r[t]})}var i=this.dataZoomModel,n=this._displayables,o=n.handleLabels,a=this._orient,r=["",""];if(i.get("showDetail")){var s=i.findRepresentativeAxisProxy();if(s){var l=s.getAxisModel().axis,u=this._range,h=t?s.calculateDataWindow({start:u[0],end:u[1]}).valueWindow:s.getDataValueWindow();r=[this._formatLabel(h[0],l),this._formatLabel(h[1],l)]}}var c=sO(this._handleEnds.slice());e.call(this,0),e.call(this,1)},_formatLabel:function(t,e){var i=this.dataZoomModel,n=i.get("labelFormatter"),o=i.get("labelPrecision");null!=o&&"auto"!==o||(o=e.getPixelPrecision());var a=null==t||isNaN(t)?"":"category"===e.type||"time"===e.type?e.scale.getLabel(Math.round(t)):t.toFixed(Math.min(o,20));return x(n)?n(t,a):_(n)?n.replace("{value}",a):a},_showDataInfo:function(t){t=this._dragging||t;var e=this._displayables.handleLabels;e[0].attr("invisible",!t),e[1].attr("invisible",!t)},_onDragMove:function(t,e,i){this._dragging=!0;var n=Ao([e,i],this._displayables.barGroup.getLocalTransform(),!0),o=this._updateInterval(t,n[0]),a=this.dataZoomModel.get("realtime");this._updateView(!a),o&&a&&this._dispatchZoomAction()},_onDragEnd:function(){this._dragging=!1,this._showDataInfo(!1),!this.dataZoomModel.get("realtime")&&this._dispatchZoomAction()},_onClickPanelClick:function(t){var e=this._size,i=this._displayables.barGroup.transformCoordToLocal(t.offsetX,t.offsetY);if(!(i[0]<0||i[0]>e[0]||i[1]<0||i[1]>e[1])){var n=this._handleEnds,o=(n[0]+n[1])/2,a=this._updateInterval("all",i[0]-o);this._updateView(),a&&this._dispatchZoomAction()}},_dispatchZoomAction:function(){var t=this._range;this.api.dispatchAction({type:"dataZoom",from:this.uid,dataZoomId:this.dataZoomModel.id,start:t[0],end:t[1]})},_findCoordRect:function(){var t;if(uO(this.getTargetCoordInfo(),function(e){if(!t&&e.length){var i=e[0].model.coordinateSystem;t=i.getRect&&i.getRect()}}),!t){var e=this.api.getWidth(),i=this.api.getHeight();t={x:.2*e,y:.2*i,width:.6*e,height:.6*i}}return t}});nO.extend({type:"dataZoom.inside",defaultOption:{disabled:!1,zoomLock:!1,zoomOnMouseWheel:!0,moveOnMouseMove:!0,moveOnMouseWheel:!1,preventDefaultMouseMove:!0}});var pO="\0_ec_dataZoom_roams",gO=m,mO=oO.extend({type:"dataZoom.inside",init:function(t,e){this._range},render:function(t,e,i,n){mO.superApply(this,"render",arguments),this._range=t.getPercentRange(),d(this.getTargetCoordInfo(),function(e,n){var o=f(e,function(t){return Zy(t.model)});d(e,function(e){var a=e.model,r={};d(["pan","zoom","scrollMove"],function(t){r[t]=gO(vO[t],this,e,n)},this),Wy(i,{coordId:Zy(a),allCoordIds:o,containsPoint:function(t,e,i){return a.coordinateSystem.containPoint([e,i])},dataZoomId:t.id,dataZoomModel:t,getRange:r})},this)},this)},dispose:function(){Hy(this.api,this.dataZoomModel.id),mO.superApply(this,"dispose",arguments),this._range=null}}),vO={zoom:function(t,e,i,n){var o=this._range,a=o.slice(),r=t.axisModels[0];if(r){var s=yO[e](null,[n.originX,n.originY],r,i,t),l=(s.signal>0?s.pixelStart+s.pixelLength-s.pixel:s.pixel-s.pixelStart)/s.pixelLength*(a[1]-a[0])+a[0],u=Math.max(1/n.scale,0);a[0]=(a[0]-l)*u+l,a[1]=(a[1]-l)*u+l;var h=this.dataZoomModel.findRepresentativeAxisProxy().getMinMaxSpan();return tk(0,a,[0,100],0,h.minSpan,h.maxSpan),this._range=a,o[0]!==a[0]||o[1]!==a[1]?a:void 0}},pan:Ky(function(t,e,i,n,o,a){var r=yO[n]([a.oldX,a.oldY],[a.newX,a.newY],e,o,i);return r.signal*(t[1]-t[0])*r.pixel/r.pixelLength}),scrollMove:Ky(function(t,e,i,n,o,a){return yO[n]([0,0],[a.scrollDelta,a.scrollDelta],e,o,i).signal*(t[1]-t[0])*a.scrollDelta})},yO={grid:function(t,e,i,n,o){var a=i.axis,r={},s=o.model.coordinateSystem.getRect();return t=t||[0,0],"x"===a.dim?(r.pixel=e[0]-t[0],r.pixelLength=s.width,r.pixelStart=s.x,r.signal=a.inverse?1:-1):(r.pixel=e[1]-t[1],r.pixelLength=s.height,r.pixelStart=s.y,r.signal=a.inverse?-1:1),r},polar:function(t,e,i,n,o){var a=i.axis,r={},s=o.model.coordinateSystem,l=s.getRadiusAxis().getExtent(),u=s.getAngleAxis().getExtent();return t=t?s.pointToCoord(t):[0,0],e=s.pointToCoord(e),"radiusAxis"===i.mainType?(r.pixel=e[0]-t[0],r.pixelLength=l[1]-l[0],r.pixelStart=l[0],r.signal=a.inverse?1:-1):(r.pixel=e[1]-t[1],r.pixelLength=u[1]-u[0],r.pixelStart=u[0],r.signal=a.inverse?-1:1),r},singleAxis:function(t,e,i,n,o){var a=i.axis,r=o.model.coordinateSystem.getRect(),s={};return t=t||[0,0],"horizontal"===a.orient?(s.pixel=e[0]-t[0],s.pixelLength=r.width,s.pixelStart=r.x,s.signal=a.inverse?1:-1):(s.pixel=e[1]-t[1],s.pixelLength=r.height,s.pixelStart=r.y,s.signal=a.inverse?-1:1),s}};Ns({getTargetSeries:function(t){var e=R();return t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,i,n){d(n.getAxisProxy(t.name,i).getTargetSeriesModels(),function(t){e.set(t.uid,t)})})}),e},modifyOutputEnd:!0,overallReset:function(t,e){t.eachComponent("dataZoom",function(t){t.eachTargetAxis(function(t,i,n){n.getAxisProxy(t.name,i).reset(n,e)}),t.eachTargetAxis(function(t,i,n){n.getAxisProxy(t.name,i).filterData(n,e)})}),t.eachComponent("dataZoom",function(t){var e=t.findRepresentativeAxisProxy(),i=e.getDataPercentWindow(),n=e.getDataValueWindow();t.setRawRange({start:i[0],end:i[1],startValue:n[0],endValue:n[1]},!0)})}}),Os("dataZoom",function(t,e){var i=Ny(m(e.eachComponent,e,"dataZoom"),$N,function(t,e){return t.get(e.axisIndex)}),n=[];e.eachComponent({mainType:"dataZoom",query:t},function(t,e){n.push.apply(n,i(t).nodes)}),d(n,function(e,i){e.setRawRange({start:t.start,end:t.end,startValue:t.startValue,endValue:t.endValue})})});var xO=d,_O=function(t){var e=t&&t.visualMap;y(e)||(e=e?[e]:[]),xO(e,function(t){if(t){$y(t,"splitList")&&!$y(t,"pieces")&&(t.pieces=t.splitList,delete t.splitList);var e=t.pieces;e&&y(e)&&xO(e,function(t){w(t)&&($y(t,"start")&&!$y(t,"min")&&(t.min=t.start),$y(t,"end")&&!$y(t,"max")&&(t.max=t.end))})}})};uI.registerSubTypeDefaulter("visualMap",function(t){return t.categories||(t.pieces?t.pieces.length>0:t.splitNumber>0)&&!t.calculable?"piecewise":"continuous"});var wO=GT.VISUAL.COMPONENT;zs(wO,{createOnAllSeries:!0,reset:function(t,e){var i=[];return e.eachComponent("visualMap",function(e){var n=t.pipelineContext;!e.isTargetSeries(t)||n&&n.large||i.push(ny(e.stateList,e.targetVisuals,m(e.getValueState,e),e.getDataDimension(t.getData())))}),i}}),zs(wO,{createOnAllSeries:!0,reset:function(t,e){var i=t.getData(),n=[];e.eachComponent("visualMap",function(e){if(e.isTargetSeries(t)){var o=e.getVisualMeta(m(Jy,null,t,e))||{stops:[],outerColors:[]},a=e.getDataDimension(i),r=i.getDimensionInfo(a);null!=r&&(o.dimension=r.index,n.push(o))}}),t.getData().setVisual("visualMeta",n)}});var bO={get:function(t,e,n){var o=i((SO[t]||{})[e]);return n&&y(o)?o[o.length-1]:o}},SO={color:{active:["#006edd","#e0ffff"],inactive:["rgba(0,0,0,0)"]},colorHue:{active:[0,360],inactive:[0,0]},colorSaturation:{active:[.3,1],inactive:[0,0]},colorLightness:{active:[.9,.5],inactive:[0,0]},colorAlpha:{active:[.3,1],inactive:[0,0]},opacity:{active:[.3,1],inactive:[0,0]},symbol:{active:["circle","roundRect","diamond"],inactive:["none"]},symbolSize:{active:[10,50],inactive:[0,0]}},MO=cL.mapVisual,IO=cL.eachVisual,TO=y,AO=d,DO=Go,CO=zo,LO=B,kO=Gs({type:"visualMap",dependencies:["series"],stateList:["inRange","outOfRange"],replacableOptionKeys:["inRange","outOfRange","target","controller","color"],dataBound:[-1/0,1/0],layoutMode:{type:"box",ignoreSize:!0},defaultOption:{show:!0,zlevel:0,z:4,seriesIndex:"all",min:0,max:200,dimension:null,inRange:null,outOfRange:null,left:0,right:null,top:null,bottom:0,itemWidth:null,itemHeight:null,inverse:!1,orient:"vertical",backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",contentColor:"#5793f3",inactiveColor:"#aaa",borderWidth:0,padding:5,textGap:10,precision:0,color:null,formatter:null,text:null,textStyle:{color:"#333"}},init:function(t,e,i){this._dataExtent,this.targetVisuals={},this.controllerVisuals={},this.textStyleModel,this.itemSize,this.mergeDefaultAndTheme(t,i)},optionUpdated:function(t,e){var i=this.option;U_.canvasSupported||(i.realtime=!1),!e&&ey(i,t,this.replacableOptionKeys),this.textStyleModel=this.getModel("textStyle"),this.resetItemSize(),this.completeVisualOption()},resetVisual:function(t){var e=this.stateList;t=m(t,this),this.controllerVisuals=ty(this.option.controller,e,t),this.targetVisuals=ty(this.option.target,e,t)},getTargetSeriesIndices:function(){var t=this.option.seriesIndex,e=[];return null==t||"all"===t?this.ecModel.eachSeries(function(t,i){e.push(i)}):e=Di(t),e},eachTargetSeries:function(t,e){d(this.getTargetSeriesIndices(),function(i){t.call(e,this.ecModel.getSeriesByIndex(i))},this)},isTargetSeries:function(t){var e=!1;return this.eachTargetSeries(function(i){i===t&&(e=!0)}),e},formatValueText:function(t,e,i){function n(t){return t===l[0]?"min":t===l[1]?"max":(+t).toFixed(Math.min(s,20))}var o,a,r=this.option,s=r.precision,l=this.dataBound,u=r.formatter;return i=i||["<",">"],y(t)&&(t=t.slice(),o=!0),a=e?t:o?[n(t[0]),n(t[1])]:n(t),_(u)?u.replace("{value}",o?a[0]:a).replace("{value2}",o?a[1]:a):x(u)?o?u(t[0],t[1]):u(t):o?t[0]===l[0]?i[0]+" "+a[1]:t[1]===l[1]?i[1]+" "+a[0]:a[0]+" - "+a[1]:a},resetExtent:function(){var t=this.option,e=DO([t.min,t.max]);this._dataExtent=e},getDataDimension:function(t){var e=this.option.dimension,i=t.dimensions;if(null!=e||i.length){if(null!=e)return t.getDimension(e);for(var n=t.dimensions,o=n.length-1;o>=0;o--){var a=n[o];if(!t.getDimensionInfo(a).isCalculationCoord)return a}}},getExtent:function(){return this._dataExtent.slice()},completeVisualOption:function(){function t(t){TO(o.color)&&!t.inRange&&(t.inRange={color:o.color.slice().reverse()}),t.inRange=t.inRange||{color:e.get("gradientColor")},AO(this.stateList,function(e){var i=t[e];if(_(i)){var n=bO.get(i,"active",l);n?(t[e]={},t[e][i]=n):delete t[e]}},this)}var e=this.ecModel,o=this.option,a={inRange:o.inRange,outOfRange:o.outOfRange},r=o.target||(o.target={}),s=o.controller||(o.controller={});n(r,a),n(s,a);var l=this.isCategory();t.call(this,r),t.call(this,s),function(t,e,i){var n=t[e],o=t[i];n&&!o&&(o=t[i]={},AO(n,function(t,e){if(cL.isValidType(e)){var i=bO.get(e,"inactive",l);null!=i&&(o[e]=i,"color"!==e||o.hasOwnProperty("opacity")||o.hasOwnProperty("colorAlpha")||(o.opacity=[0,0]))}}))}.call(this,r,"inRange","outOfRange"),function(t){var e=(t.inRange||{}).symbol||(t.outOfRange||{}).symbol,n=(t.inRange||{}).symbolSize||(t.outOfRange||{}).symbolSize,o=this.get("inactiveColor");AO(this.stateList,function(a){var r=this.itemSize,s=t[a];s||(s=t[a]={color:l?o:[o]}),null==s.symbol&&(s.symbol=e&&i(e)||(l?"roundRect":["roundRect"])),null==s.symbolSize&&(s.symbolSize=n&&i(n)||(l?r[0]:[r[0],r[0]])),s.symbol=MO(s.symbol,function(t){return"none"===t||"square"===t?"roundRect":t});var u=s.symbolSize;if(null!=u){var h=-1/0;IO(u,function(t){t>h&&(h=t)}),s.symbolSize=MO(u,function(t){return CO(t,[0,h],[0,r[0]],!0)})}},this)}.call(this,s)},resetItemSize:function(){this.itemSize=[parseFloat(this.get("itemWidth")),parseFloat(this.get("itemHeight"))]},isCategory:function(){return!!this.option.categories},setSelected:LO,getValueState:LO,getVisualMeta:LO}),PO=[20,140],NO=kO.extend({type:"visualMap.continuous",defaultOption:{align:"auto",calculable:!1,range:null,realtime:!0,itemHeight:null,itemWidth:null,hoverLink:!0,hoverLinkDataSize:null,hoverLinkOnHandle:null},optionUpdated:function(t,e){NO.superApply(this,"optionUpdated",arguments),this.resetExtent(),this.resetVisual(function(t){t.mappingMethod="linear",t.dataExtent=this.getExtent()}),this._resetRange()},resetItemSize:function(){NO.superApply(this,"resetItemSize",arguments);var t=this.itemSize;"horizontal"===this._orient&&t.reverse(),(null==t[0]||isNaN(t[0]))&&(t[0]=PO[0]),(null==t[1]||isNaN(t[1]))&&(t[1]=PO[1])},_resetRange:function(){var t=this.getExtent(),e=this.option.range;!e||e.auto?(t.auto=1,this.option.range=t):y(e)&&(e[0]>e[1]&&e.reverse(),e[0]=Math.max(e[0],t[0]),e[1]=Math.min(e[1],t[1]))},completeVisualOption:function(){kO.prototype.completeVisualOption.apply(this,arguments),d(this.stateList,function(t){var e=this.option.controller[t].symbolSize;e&&e[0]!==e[1]&&(e[0]=0)},this)},setSelected:function(t){this.option.range=t.slice(),this._resetRange()},getSelected:function(){var t=this.getExtent(),e=Go((this.get("range")||[]).slice());return e[0]>t[1]&&(e[0]=t[1]),e[1]>t[1]&&(e[1]=t[1]),e[0]=i[1]||t<=e[1])?"inRange":"outOfRange"},findTargetDataIndices:function(t){var e=[];return this.eachTargetSeries(function(i){var n=[],o=i.getData();o.each(this.getDataDimension(o),function(e,i){t[0]<=e&&e<=t[1]&&n.push(i)},this),e.push({seriesId:i.id,dataIndex:n})},this),e},getVisualMeta:function(t){function e(e,i){o.push({value:e,color:t(e,i)})}for(var i=Qy(0,0,this.getExtent()),n=Qy(0,0,this.option.range.slice()),o=[],a=0,r=0,s=n.length,l=i.length;rt[1])break;i.push({color:this.getControllerVisual(a,"color",e),offset:o/100})}return i.push({color:this.getControllerVisual(t[1],"color",e),offset:1}),i},_createBarPoints:function(t,e){var i=this.visualMapModel.itemSize;return[[i[0]-e[0],t[0]],[i[0],t[0]],[i[0],t[1]],[i[0]-e[1],t[1]]]},_createBarGroup:function(t){var e=this._orient,i=this.visualMapModel.get("inverse");return new tb("horizontal"!==e||i?"horizontal"===e&&i?{scale:"bottom"===t?[-1,1]:[1,1],rotation:-Math.PI/2}:"vertical"!==e||i?{scale:"left"===t?[1,1]:[-1,1]}:{scale:"left"===t?[1,-1]:[-1,-1]}:{scale:"bottom"===t?[1,1]:[-1,1],rotation:Math.PI/2})},_updateHandle:function(t,e){if(this._useHandle){var i=this._shapes,n=this.visualMapModel,o=i.handleThumbs,a=i.handleLabels;RO([0,1],function(r){var s=o[r];s.setStyle("fill",e.handlesColor[r]),s.position[1]=t[r];var l=Ao(i.handleLabelPoints[r],To(s,this.group));a[r].setStyle({x:l[0],y:l[1],text:n.formatValueText(this._dataInterval[r]),textVerticalAlign:"middle",textAlign:this._applyTransform("horizontal"===this._orient?0===r?"bottom":"top":"left",i.barGroup)})},this)}},_showIndicator:function(t,e,i,n){var o=this.visualMapModel,a=o.getExtent(),r=o.itemSize,s=[0,r[1]],l=EO(t,a,s,!0),u=this._shapes,h=u.indicator;if(h){h.position[1]=l,h.attr("invisible",!1),h.setShape("points",ox(!!i,n,l,r[1]));var c={convertOpacityToAlpha:!0},d=this.getControllerVisual(t,"color",c);h.setStyle("fill",d);var f=Ao(u.indicatorLabelPoint,To(h,this.group)),p=u.indicatorLabel;p.attr("invisible",!1);var g=this._applyTransform("left",u.barGroup),m=this._orient;p.setStyle({text:(i||"")+o.formatValueText(e),textVerticalAlign:"horizontal"===m?g:"middle",textAlign:"horizontal"===m?"center":g,x:f[0],y:f[1]})}},_enableHoverLinkToSeries:function(){var t=this;this._shapes.barGroup.on("mousemove",function(e){if(t._hovering=!0,!t._dragging){var i=t.visualMapModel.itemSize,n=t._applyTransform([e.offsetX,e.offsetY],t._shapes.barGroup,!0,!0);n[1]=zO(BO(0,n[1]),i[1]),t._doHoverLinkToSeries(n[1],0<=n[0]&&n[0]<=i[0])}}).on("mouseout",function(){t._hovering=!1,!t._dragging&&t._clearHoverLinkToSeries()})},_enableHoverLinkFromSeries:function(){var t=this.api.getZr();this.visualMapModel.option.hoverLink?(t.on("mouseover",this._hoverLinkFromSeriesMouseOver,this),t.on("mouseout",this._hideIndicator,this)):this._clearHoverLinkFromSeries()},_doHoverLinkToSeries:function(t,e){var i=this.visualMapModel,n=i.itemSize;if(i.option.hoverLink){var o=[0,n[1]],a=i.getExtent();t=zO(BO(o[0],t),o[1]);var r=ax(i,a,o),s=[t-r,t+r],l=EO(t,o,a,!0),u=[EO(s[0],o,a,!0),EO(s[1],o,a,!0)];s[0]o[1]&&(u[1]=1/0),e&&(u[0]===-1/0?this._showIndicator(l,u[1],"< ",r):u[1]===1/0?this._showIndicator(l,u[0],"> ",r):this._showIndicator(l,l,"≈ ",r));var h=this._hoverLinkDataIndices,c=[];(e||rx(i))&&(c=this._hoverLinkDataIndices=i.findTargetDataIndices(u));var d=Ri(h,c);this._dispatchHighDown("downplay",ex(d[0])),this._dispatchHighDown("highlight",ex(d[1]))}},_hoverLinkFromSeriesMouseOver:function(t){var e=t.target,i=this.visualMapModel;if(e&&null!=e.dataIndex){var n=this.ecModel.getSeriesByIndex(e.seriesIndex);if(i.isTargetSeries(n)){var o=n.getData(e.dataType),a=o.get(i.getDataDimension(o),e.dataIndex,!0);isNaN(a)||this._showIndicator(a,a)}}},_hideIndicator:function(){var t=this._shapes;t.indicator&&t.indicator.attr("invisible",!0),t.indicatorLabel&&t.indicatorLabel.attr("invisible",!0)},_clearHoverLinkToSeries:function(){this._hideIndicator();var t=this._hoverLinkDataIndices;this._dispatchHighDown("downplay",ex(t)),t.length=0},_clearHoverLinkFromSeries:function(){this._hideIndicator();var t=this.api.getZr();t.off("mouseover",this._hoverLinkFromSeriesMouseOver),t.off("mouseout",this._hideIndicator)},_applyTransform:function(t,e,i,n){var o=To(e,n?null:this.group);return zM[y(t)?"applyTransform":"transformDirection"](t,o,i)},_dispatchHighDown:function(t,e){e&&e.length&&this.api.dispatchAction({type:t,batch:e})},dispose:function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()},remove:function(){this._clearHoverLinkFromSeries(),this._clearHoverLinkToSeries()}});Os({type:"selectDataRange",event:"dataRangeSelected",update:"update"},function(t,e){e.eachComponent({mainType:"visualMap",query:t},function(e){e.setSelected(t.selected)})}),Ps(_O);var WO=kO.extend({type:"visualMap.piecewise",defaultOption:{selected:null,minOpen:!1,maxOpen:!1,align:"auto",itemWidth:20,itemHeight:14,itemSymbol:"roundRect",pieceList:null,categories:null,splitNumber:5,selectedMode:"multiple",itemGap:10,hoverLink:!0,showLabel:null},optionUpdated:function(t,e){WO.superApply(this,"optionUpdated",arguments),this._pieceList=[],this.resetExtent();var n=this._mode=this._determineMode();HO[this._mode].call(this),this._resetSelected(t,e);var o=this.option.categories;this.resetVisual(function(t,e){"categories"===n?(t.mappingMethod="category",t.categories=i(o)):(t.dataExtent=this.getExtent(),t.mappingMethod="piecewise",t.pieceList=f(this._pieceList,function(t){var t=i(t);return"inRange"!==e&&(t.visual=null),t}))})},completeVisualOption:function(){function t(t,e,i){return t&&t[e]&&(w(t[e])?t[e].hasOwnProperty(i):t[e]===i)}var e=this.option,i={},n=cL.listVisualTypes(),o=this.isCategory();d(e.pieces,function(t){d(n,function(e){t.hasOwnProperty(e)&&(i[e]=1)})}),d(i,function(i,n){var a=0;d(this.stateList,function(i){a|=t(e,i,n)||t(e.target,i,n)},this),!a&&d(this.stateList,function(t){(e[t]||(e[t]={}))[n]=bO.get(n,"inRange"===t?"active":"inactive",o)})},this),kO.prototype.completeVisualOption.apply(this,arguments)},_resetSelected:function(t,e){var i=this.option,n=this._pieceList,o=(e?i:t).selected||{};if(i.selected=o,d(n,function(t,e){var i=this.getSelectedMapKey(t);o.hasOwnProperty(i)||(o[i]=!0)},this),"single"===i.selectedMode){var a=!1;d(n,function(t,e){var i=this.getSelectedMapKey(t);o[i]&&(a?o[i]=!1:a=!0)},this)}},getSelectedMapKey:function(t){return"categories"===this._mode?t.value+"":t.index+""},getPieceList:function(){return this._pieceList},_determineMode:function(){var t=this.option;return t.pieces&&t.pieces.length>0?"pieces":this.option.categories?"categories":"splitNumber"},setSelected:function(t){this.option.selected=i(t)},getValueState:function(t){var e=cL.findPieceIndex(t,this._pieceList);return null!=e&&this.option.selected[this.getSelectedMapKey(this._pieceList[e])]?"inRange":"outOfRange"},findTargetDataIndices:function(t){var e=[];return this.eachTargetSeries(function(i){var n=[],o=i.getData();o.each(this.getDataDimension(o),function(e,i){cL.findPieceIndex(e,this._pieceList)===t&&n.push(i)},this),e.push({seriesId:i.id,dataIndex:n})},this),e},getRepresentValue:function(t){var e;if(this.isCategory())e=t.value;else if(null!=t.value)e=t.value;else{var i=t.interval||[];e=i[0]===-1/0&&i[1]===1/0?0:(i[0]+i[1])/2}return e},getVisualMeta:function(t){function e(e,a){var r=o.getRepresentValue({interval:e});a||(a=o.getValueState(r));var s=t(r,a);e[0]===-1/0?n[0]=s:e[1]===1/0?n[1]=s:i.push({value:e[0],color:s},{value:e[1],color:s})}if(!this.isCategory()){var i=[],n=[],o=this,a=this._pieceList.slice();if(a.length){var r=a[0].interval[0];r!==-1/0&&a.unshift({interval:[-1/0,r]}),(r=a[a.length-1].interval[1])!==1/0&&a.push({interval:[r,1/0]})}else a.push({interval:[-1/0,1/0]});var s=-1/0;return d(a,function(t){var i=t.interval;i&&(i[0]>s&&e([s,i[0]],"outOfRange"),e(i.slice()),s=i[1])},this),{stops:i,outerColors:n}}}}),HO={splitNumber:function(){var t=this.option,e=this._pieceList,i=Math.min(t.precision,20),n=this.getExtent(),o=t.splitNumber;o=Math.max(parseInt(o,10),1),t.splitNumber=o;for(var a=(n[1]-n[0])/o;+a.toFixed(i)!==a&&i<5;)i++;t.precision=i,a=+a.toFixed(i);var r=0;t.minOpen&&e.push({index:r++,interval:[-1/0,n[0]],close:[0,0]});for(var s=n[0],l=r+o;r","≥"][e[0]]];t.text=t.text||this.formatValueText(null!=t.value?t.value:t.interval,!1,i)},this)}};OO.extend({type:"visualMap.piecewise",doRender:function(){var t=this.group;t.removeAll();var e=this.visualMapModel,i=e.get("textGap"),n=e.textStyleModel,o=n.getFont(),a=n.getTextColor(),r=this._getItemAlign(),s=e.itemSize,l=this._getViewData(),u=l.endsText,h=T(e.get("showLabel",!0),!u);u&&this._renderEndsText(t,u[0],s,h,r),d(l.viewPieceList,function(n){var l=n.piece,u=new tb;u.onclick=m(this._onItemClick,this,l),this._enableHoverLink(u,n.indexInModelPieceList);var c=e.getRepresentValue(l);if(this._createItemSymbol(u,c,[0,0,s[0],s[1]]),h){var d=this.visualMapModel.getValueState(c);u.add(new rM({style:{x:"right"===r?-i:s[0]+i,y:s[1]/2,text:l.text,textVerticalAlign:"middle",textAlign:r,textFont:o,textFill:a,opacity:"outOfRange"===d?.5:1}}))}t.add(u)},this),u&&this._renderEndsText(t,u[1],s,h,r),rI(e.get("orient"),t,e.get("itemGap")),this.renderBackground(t),this.positionGroup(t)},_enableHoverLink:function(t,e){function i(t){var i=this.visualMapModel;i.option.hoverLink&&this.api.dispatchAction({type:t,batch:ex(i.findTargetDataIndices(e))})}t.on("mouseover",m(i,this,"highlight")).on("mouseout",m(i,this,"downplay"))},_getItemAlign:function(){var t=this.visualMapModel,e=t.option;if("vertical"===e.orient)return tx(t,this.api,t.itemSize);var i=e.align;return i&&"auto"!==i||(i="left"),i},_renderEndsText:function(t,e,i,n,o){if(e){var a=new tb,r=this.visualMapModel.textStyleModel;a.add(new rM({style:{x:n?"right"===o?i[0]:0:i[0]/2,y:i[1]/2,textVerticalAlign:"middle",textAlign:n?o:"center",text:e,textFont:r.getFont(),textFill:r.getTextColor()}})),t.add(a)}},_getViewData:function(){var t=this.visualMapModel,e=f(t.getPieceList(),function(t,e){return{piece:t,indexInModelPieceList:e}}),i=t.get("text"),n=t.get("orient"),o=t.get("inverse");return("horizontal"===n?o:!o)?e.reverse():i&&(i=i.slice().reverse()),{viewPieceList:e,endsText:i}},_createItemSymbol:function(t,e,i){t.add($l(this.getControllerVisual(e,"symbol"),i[0],i[1],i[2],i[3],this.getControllerVisual(e,"color")))},_onItemClick:function(t){var e=this.visualMapModel,n=e.option,o=i(n.selected),a=e.getSelectedMapKey(t);"single"===n.selectedMode?(o[a]=!0,d(o,function(t,e){o[e]=e===a})):o[a]=!o[a],this.api.dispatchAction({type:"selectDataRange",from:this.uid,visualMapId:this.visualMapModel.id,selected:o})}});Ps(_O);var ZO=Qo,UO=ea,XO=Gs({type:"marker",dependencies:["series","grid","polar","geo"],init:function(t,e,i,n){this.mergeDefaultAndTheme(t,i),this.mergeOption(t,i,n.createdBySelf,!0)},isAnimationEnabled:function(){if(U_.node)return!1;var t=this.__hostSeries;return this.getShallow("animation")&&t&&t.isAnimationEnabled()},mergeOption:function(t,e,i,n){var o=this.constructor,r=this.mainType+"Model";i||e.eachSeries(function(t){var i=t.get(this.mainType,!0),s=t[r];i&&i.data?(s?s.mergeOption(i,e,!0):(n&&ux(i),d(i.data,function(t){t instanceof Array?(ux(t[0]),ux(t[1])):ux(t)}),a(s=new o(i,this,e),{mainType:this.mainType,seriesIndex:t.seriesIndex,name:t.name,createdBySelf:!0}),s.__hostSeries=t),t[r]=s):t[r]=null},this)},formatTooltip:function(t){var e=this.getData(),i=this.getRawValue(t),n=y(i)?f(i,ZO).join(", "):ZO(i),o=e.getName(t),a=UO(this.name);return(null!=i||o)&&(a+="
    "),o&&(a+=UO(o),null!=i&&(a+=" : ")),null!=i&&(a+=UO(n)),a},getData:function(){return this._data},setData:function(t){this._data=t}});h(XO,UI),XO.extend({type:"markPoint",defaultOption:{zlevel:0,z:5,symbol:"pin",symbolSize:50,tooltip:{trigger:"item"},label:{show:!0,position:"inside"},itemStyle:{borderWidth:2},emphasis:{label:{show:!0}}}});var jO=l,YO=v,qO={min:YO(dx,"min"),max:YO(dx,"max"),average:YO(dx,"average")},KO=Fs({type:"marker",init:function(){this.markerGroupMap=R()},render:function(t,e,i){var n=this.markerGroupMap;n.each(function(t){t.__keep=!1});var o=this.type+"Model";e.eachSeries(function(t){var n=t[o];n&&this.renderSeries(t,n,e,i)},this),n.each(function(t){!t.__keep&&this.group.remove(t.group)},this)},renderSeries:function(){}});KO.extend({type:"markPoint",updateTransform:function(t,e,i){e.eachSeries(function(t){var e=t.markPointModel;e&&(xx(e.getData(),t,i),this.markerGroupMap.get(t.id).updateLayout(e))},this)},renderSeries:function(t,e,i,n){var o=t.coordinateSystem,a=t.id,r=t.getData(),s=this.markerGroupMap,l=s.get(a)||s.set(a,new Au),u=_x(o,t,e);e.setData(u),xx(e.getData(),t,n),u.each(function(t){var i=u.getItemModel(t),n=i.getShallow("symbolSize");"function"==typeof n&&(n=n(e.getRawValue(t),e.getDataParams(t))),u.setItemVisual(t,{symbolSize:n,color:i.get("itemStyle.color")||r.getVisual("color"),symbol:i.getShallow("symbol")})}),l.updateData(u),this.group.add(l.group),u.eachItemGraphicEl(function(t){t.traverse(function(t){t.dataModel=e})}),l.__keep=!0,l.group.silent=e.get("silent")||t.get("silent")}}),Ps(function(t){t.markPoint=t.markPoint||{}}),XO.extend({type:"markLine",defaultOption:{zlevel:0,z:5,symbol:["circle","arrow"],symbolSize:[8,16],precision:2,tooltip:{trigger:"item"},label:{show:!0,position:"end"},lineStyle:{type:"dashed"},emphasis:{label:{show:!0},lineStyle:{width:3}},animationEasing:"linear"}});var $O=function(t,e,o,r){var s=t.getData(),l=r.type;if(!y(r)&&("min"===l||"max"===l||"average"===l||"median"===l||null!=r.xAxis||null!=r.yAxis)){var u,h;if(null!=r.yAxis||null!=r.xAxis)u=null!=r.yAxis?"y":"x",e.getAxis(u),h=T(r.yAxis,r.xAxis);else{var c=px(r,s,e,t);u=c.valueDataDim,c.valueAxis,h=yx(s,u,l)}var d="x"===u?0:1,f=1-d,p=i(r),g={};p.type=null,p.coord=[],g.coord=[],p.coord[f]=-1/0,g.coord[f]=1/0;var m=o.get("precision");m>=0&&"number"==typeof h&&(h=+h.toFixed(Math.min(m,20))),p.coord[d]=g.coord[d]=h,r=[p,g,{type:l,valueIndex:r.valueIndex,value:h}]}return r=[fx(t,r[0]),fx(t,r[1]),a({},r[2])],r[2].type=r[2].type||"",n(r[2],r[0]),n(r[2],r[1]),r};KO.extend({type:"markLine",updateTransform:function(t,e,i){e.eachSeries(function(t){var e=t.markLineModel;if(e){var n=e.getData(),o=e.__from,a=e.__to;o.each(function(e){Ix(o,e,!0,t,i),Ix(a,e,!1,t,i)}),n.each(function(t){n.setItemLayout(t,[o.getItemLayout(t),a.getItemLayout(t)])}),this.markerGroupMap.get(t.id).updateLayout()}},this)},renderSeries:function(t,e,i,n){function o(e,i,o){var a=e.getItemModel(i);Ix(e,i,o,t,n),e.setItemVisual(i,{symbolSize:a.get("symbolSize")||g[o?0:1],symbol:a.get("symbol",!0)||p[o?0:1],color:a.get("itemStyle.color")||s.getVisual("color")})}var a=t.coordinateSystem,r=t.id,s=t.getData(),l=this.markerGroupMap,u=l.get(r)||l.set(r,new rf);this.group.add(u.group);var h=Tx(a,t,e),c=h.from,d=h.to,f=h.line;e.__from=c,e.__to=d,e.setData(f);var p=e.get("symbol"),g=e.get("symbolSize");y(p)||(p=[p,p]),"number"==typeof g&&(g=[g,g]),h.from.each(function(t){o(c,t,!0),o(d,t,!1)}),f.each(function(t){var e=f.getItemModel(t).get("lineStyle.color");f.setItemVisual(t,{color:e||c.getItemVisual(t,"color")}),f.setItemLayout(t,[c.getItemLayout(t),d.getItemLayout(t)]),f.setItemVisual(t,{fromSymbolSize:c.getItemVisual(t,"symbolSize"),fromSymbol:c.getItemVisual(t,"symbol"),toSymbolSize:d.getItemVisual(t,"symbolSize"),toSymbol:d.getItemVisual(t,"symbol")})}),u.updateData(f),h.line.eachItemGraphicEl(function(t,i){t.traverse(function(t){t.dataModel=e})}),u.__keep=!0,u.group.silent=e.get("silent")||t.get("silent")}}),Ps(function(t){t.markLine=t.markLine||{}}),XO.extend({type:"markArea",defaultOption:{zlevel:0,z:1,tooltip:{trigger:"item"},animation:!1,label:{show:!0,position:"top"},itemStyle:{borderWidth:0},emphasis:{label:{show:!0,position:"top"}}}});var JO=function(t,e,i,n){var a=fx(t,n[0]),r=fx(t,n[1]),s=T,l=a.coord,u=r.coord;l[0]=s(l[0],-1/0),l[1]=s(l[1],-1/0),u[0]=s(u[0],1/0),u[1]=s(u[1],1/0);var h=o([{},a,r]);return h.coord=[a.coord,r.coord],h.x0=a.x,h.y0=a.y,h.x1=r.x,h.y1=r.y,h},QO=[["x0","y0"],["x1","y0"],["x1","y1"],["x0","y1"]];KO.extend({type:"markArea",updateTransform:function(t,e,i){e.eachSeries(function(t){var e=t.markAreaModel;if(e){var n=e.getData();n.each(function(e){var o=f(QO,function(o){return Lx(n,e,o,t,i)});n.setItemLayout(e,o),n.getItemGraphicEl(e).setShape("points",o)})}},this)},renderSeries:function(t,e,i,n){var o=t.coordinateSystem,a=t.id,s=t.getData(),l=this.markerGroupMap,u=l.get(a)||l.set(a,{group:new tb});this.group.add(u.group),u.__keep=!0;var h=kx(o,t,e);e.setData(h),h.each(function(e){h.setItemLayout(e,f(QO,function(i){return Lx(h,e,i,t,n)})),h.setItemVisual(e,{color:s.getVisual("color")})}),h.diff(u.__data).add(function(t){var e=new pM({shape:{points:h.getItemLayout(t)}});h.setItemGraphicEl(t,e),u.group.add(e)}).update(function(t,i){var n=u.__data.getItemGraphicEl(i);Mo(n,{shape:{points:h.getItemLayout(t)}},e,t),u.group.add(n),h.setItemGraphicEl(t,n)}).remove(function(t){var e=u.__data.getItemGraphicEl(t);u.group.remove(e)}).execute(),h.eachItemGraphicEl(function(t,i){var n=h.getItemModel(i),o=n.getModel("label"),a=n.getModel("emphasis.label"),s=h.getItemVisual(i,"color");t.useStyle(r(n.getModel("itemStyle").getItemStyle(),{fill:Yt(s,.4),stroke:s})),t.hoverStyle=n.getModel("emphasis.itemStyle").getItemStyle(),po(t.style,t.hoverStyle,o,a,{labelFetcher:e,labelDataIndex:i,defaultText:h.getName(i)||"",isRectText:!0,autoColor:s}),co(t,{}),t.dataModel=e}),u.__data=h,u.group.silent=e.get("silent")||t.get("silent")}}),Ps(function(t){t.markArea=t.markArea||{}});uI.registerSubTypeDefaulter("timeline",function(){return"slider"}),Os({type:"timelineChange",event:"timelineChanged",update:"prepareAndUpdate"},function(t,e){var i=e.getComponent("timeline");return i&&null!=t.currentIndex&&(i.setCurrentIndex(t.currentIndex),!i.get("loop",!0)&&i.isIndexMax()&&i.setPlayState(!1)),e.resetOption("timeline"),r({currentIndex:i.option.currentIndex},t)}),Os({type:"timelinePlayChange",event:"timelinePlayChanged",update:"update"},function(t,e){var i=e.getComponent("timeline");i&&null!=t.playState&&i.setPlayState(t.playState)});var tE=uI.extend({type:"timeline",layoutMode:"box",defaultOption:{zlevel:0,z:4,show:!0,axisType:"time",realtime:!0,left:"20%",top:null,right:"20%",bottom:0,width:null,height:40,padding:5,controlPosition:"left",autoPlay:!1,rewind:!1,loop:!0,playInterval:2e3,currentIndex:0,itemStyle:{},label:{color:"#000"},data:[]},init:function(t,e,i){this._data,this._names,this.mergeDefaultAndTheme(t,i),this._initData()},mergeOption:function(t){tE.superApply(this,"mergeOption",arguments),this._initData()},setCurrentIndex:function(t){null==t&&(t=this.option.currentIndex);var e=this._data.count();this.option.loop?t=(t%e+e)%e:(t>=e&&(t=e-1),t<0&&(t=0)),this.option.currentIndex=t},getCurrentIndex:function(){return this.option.currentIndex},isIndexMax:function(){return this.getCurrentIndex()>=this._data.count()-1},setPlayState:function(t){this.option.autoPlay=!!t},getPlayState:function(){return!!this.option.autoPlay},_initData:function(){var t=this.option,e=t.data||[],n=t.axisType,o=this._names=[];if("category"===n){var a=[];d(e,function(t,e){var n,r=Li(t);w(t)?(n=i(t)).value=e:n=e,a.push(n),_(r)||null!=r&&!isNaN(r)||(r=""),o.push(r+"")}),e=a}var r={category:"ordinal",time:"time"}[n]||"number";(this._data=new yA([{name:"value",type:r}],this)).initData(e,o)},getData:function(){return this._data},getCategories:function(){if("category"===this.get("axisType"))return this._names.slice()}});h(tE.extend({type:"timeline.slider",defaultOption:{backgroundColor:"rgba(0,0,0,0)",borderColor:"#ccc",borderWidth:0,orient:"horizontal",inverse:!1,tooltip:{trigger:"item"},symbol:"emptyCircle",symbolSize:10,lineStyle:{show:!0,width:2,color:"#304654"},label:{position:"auto",show:!0,interval:"auto",rotate:0,color:"#304654"},itemStyle:{color:"#304654",borderWidth:1},checkpointStyle:{symbol:"circle",symbolSize:13,color:"#c23531",borderWidth:5,borderColor:"rgba(194,53,49, 0.5)",animation:!0,animationDuration:300,animationEasing:"quinticInOut"},controlStyle:{show:!0,showPlayBtn:!0,showPrevBtn:!0,showNextBtn:!0,itemSize:22,itemGap:12,position:"left",playIcon:"path://M31.6,53C17.5,53,6,41.5,6,27.4S17.5,1.8,31.6,1.8C45.7,1.8,57.2,13.3,57.2,27.4S45.7,53,31.6,53z M31.6,3.3 C18.4,3.3,7.5,14.1,7.5,27.4c0,13.3,10.8,24.1,24.1,24.1C44.9,51.5,55.7,40.7,55.7,27.4C55.7,14.1,44.9,3.3,31.6,3.3z M24.9,21.3 c0-2.2,1.6-3.1,3.5-2l10.5,6.1c1.899,1.1,1.899,2.9,0,4l-10.5,6.1c-1.9,1.1-3.5,0.2-3.5-2V21.3z",stopIcon:"path://M30.9,53.2C16.8,53.2,5.3,41.7,5.3,27.6S16.8,2,30.9,2C45,2,56.4,13.5,56.4,27.6S45,53.2,30.9,53.2z M30.9,3.5C17.6,3.5,6.8,14.4,6.8,27.6c0,13.3,10.8,24.1,24.101,24.1C44.2,51.7,55,40.9,55,27.6C54.9,14.4,44.1,3.5,30.9,3.5z M36.9,35.8c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H36c0.5,0,0.9,0.4,0.9,1V35.8z M27.8,35.8 c0,0.601-0.4,1-0.9,1h-1.3c-0.5,0-0.9-0.399-0.9-1V19.5c0-0.6,0.4-1,0.9-1H27c0.5,0,0.9,0.4,0.9,1L27.8,35.8L27.8,35.8z",nextIcon:"path://M18.6,50.8l22.5-22.5c0.2-0.2,0.3-0.4,0.3-0.7c0-0.3-0.1-0.5-0.3-0.7L18.7,4.4c-0.1-0.1-0.2-0.3-0.2-0.5 c0-0.4,0.3-0.8,0.8-0.8c0.2,0,0.5,0.1,0.6,0.3l23.5,23.5l0,0c0.2,0.2,0.3,0.4,0.3,0.7c0,0.3-0.1,0.5-0.3,0.7l-0.1,0.1L19.7,52 c-0.1,0.1-0.3,0.2-0.5,0.2c-0.4,0-0.8-0.3-0.8-0.8C18.4,51.2,18.5,51,18.6,50.8z",prevIcon:"path://M43,52.8L20.4,30.3c-0.2-0.2-0.3-0.4-0.3-0.7c0-0.3,0.1-0.5,0.3-0.7L42.9,6.4c0.1-0.1,0.2-0.3,0.2-0.5 c0-0.4-0.3-0.8-0.8-0.8c-0.2,0-0.5,0.1-0.6,0.3L18.3,28.8l0,0c-0.2,0.2-0.3,0.4-0.3,0.7c0,0.3,0.1,0.5,0.3,0.7l0.1,0.1L41.9,54 c0.1,0.1,0.3,0.2,0.5,0.2c0.4,0,0.8-0.3,0.8-0.8C43.2,53.2,43.1,53,43,52.8z",color:"#304654",borderColor:"#304654",borderWidth:1},emphasis:{label:{show:!0,color:"#c23531"},itemStyle:{color:"#c23531"},controlStyle:{color:"#c23531",borderColor:"#c23531",borderWidth:2}},data:[]}}),UI);var eE=KI.extend({type:"timeline"}),iE=function(t,e,i,n){rD.call(this,t,e,i),this.type=n||"value",this.model=null};iE.prototype={constructor:iE,getLabelModel:function(){return this.model.getModel("label")},isHorizontal:function(){return"horizontal"===this.model.get("orient")}},u(iE,rD);var nE=m,oE=d,aE=Math.PI;eE.extend({type:"timeline.slider",init:function(t,e){this.api=e,this._axis,this._viewRect,this._timer,this._currentPointer,this._mainGroup,this._labelGroup},render:function(t,e,i,n){if(this.model=t,this.api=i,this.ecModel=e,this.group.removeAll(),t.get("show",!0)){var o=this._layout(t,i),a=this._createGroup("mainGroup"),r=this._createGroup("labelGroup"),s=this._axis=this._createAxis(o,t);t.formatTooltip=function(t){return ea(s.scale.getLabel(t))},oE(["AxisLine","AxisTick","Control","CurrentPointer"],function(e){this["_render"+e](o,a,s,t)},this),this._renderAxisLabel(o,r,s,t),this._position(o,t)}this._doPlayStop()},remove:function(){this._clearTimer(),this.group.removeAll()},dispose:function(){this._clearTimer()},_layout:function(t,e){var i=t.get("label.position"),n=t.get("orient"),o=Ex(t,e);null==i||"auto"===i?i="horizontal"===n?o.y+o.height/2=0||"+"===i?"left":"right"},r={horizontal:i>=0||"+"===i?"top":"bottom",vertical:"middle"},s={horizontal:0,vertical:aE/2},l="vertical"===n?o.height:o.width,u=t.getModel("controlStyle"),h=u.get("show",!0),c=h?u.get("itemSize"):0,d=h?u.get("itemGap"):0,f=c+d,p=t.get("label.rotate")||0;p=p*aE/180;var g,m,v,y,x=u.get("position",!0),_=h&&u.get("showPlayBtn",!0),w=h&&u.get("showPrevBtn",!0),b=h&&u.get("showNextBtn",!0),S=0,M=l;return"left"===x||"bottom"===x?(_&&(g=[0,0],S+=f),w&&(m=[S,0],S+=f),b&&(v=[M-c,0],M-=f)):(_&&(g=[M-c,0],M-=f),w&&(m=[0,0],S+=f),b&&(v=[M-c,0],M-=f)),y=[S,M],t.get("inverse")&&y.reverse(),{viewRect:o,mainLength:l,orient:n,rotation:s[n],labelRotation:p,labelPosOpt:i,labelAlign:t.get("label.align")||a[n],labelBaseline:t.get("label.verticalAlign")||t.get("label.baseline")||r[n],playPosition:g,prevBtnPosition:m,nextBtnPosition:v,axisExtent:y,controlSize:c,controlGap:d}},_position:function(t,e){function i(t){var e=t.position;t.origin=[c[0][0]-e[0],c[1][0]-e[1]]}function n(t){return[[t.x,t.x+t.width],[t.y,t.y+t.height]]}function o(t,e,i,n,o){t[n]+=i[n][o]-e[n][o]}var a=this._mainGroup,r=this._labelGroup,s=t.viewRect;if("vertical"===t.orient){var l=xt(),u=s.x,h=s.y+s.height;St(l,l,[-u,-h]),Mt(l,l,-aE/2),St(l,l,[u,h]),(s=s.clone()).applyTransform(l)}var c=n(s),d=n(a.getBoundingRect()),f=n(r.getBoundingRect()),p=a.position,g=r.position;g[0]=p[0]=c[0][0];var m=t.labelPosOpt;if(isNaN(m))o(p,d,c,1,v="+"===m?0:1),o(g,f,c,1,1-v);else{var v=m>=0?0:1;o(p,d,c,1,v),g[1]=p[1]+m}a.attr("position",p),r.attr("position",g),a.rotation=r.rotation=t.rotation,i(a),i(r)},_createAxis:function(t,e){var i=e.getData(),n=e.get("axisType"),o=Wl(e,n);o.getTicks=function(){return i.mapArray(["value"],function(t){return t})};var a=i.getDataExtent("value");o.setExtent(a[0],a[1]),o.niceTicks();var r=new iE("value",o,t.axisExtent,n);return r.model=e,r},_createGroup:function(t){var e=this["_"+t]=new tb;return this.group.add(e),e},_renderAxisLine:function(t,e,i,n){var o=i.getExtent();n.get("lineStyle.show")&&e.add(new _M({shape:{x1:o[0],y1:0,x2:o[1],y2:0},style:a({lineCap:"round"},n.getModel("lineStyle").getLineStyle()),silent:!0,z2:1}))},_renderAxisTick:function(t,e,i,n){var o=n.getData(),a=i.scale.getTicks();oE(a,function(t){var a=i.dataToCoord(t),r=o.getItemModel(t),s=r.getModel("itemStyle"),l=r.getModel("emphasis.itemStyle"),u={position:[a,0],onclick:nE(this._changeTimeline,this,t)},h=zx(r,s,e,u);co(h,l.getItemStyle()),r.get("tooltip")?(h.dataIndex=t,h.dataModel=n):h.dataIndex=h.dataModel=null},this)},_renderAxisLabel:function(t,e,i,n){if(i.getLabelModel().get("show")){var o=n.getData(),a=i.getViewLabels();oE(a,function(n){var a=n.tickValue,r=o.getItemModel(a),s=r.getModel("label"),l=r.getModel("emphasis.label"),u=i.dataToCoord(n.tickValue),h=new rM({position:[u,0],rotation:t.labelRotation-t.rotation,onclick:nE(this._changeTimeline,this,a),silent:!1});go(h.style,s,{text:n.formattedLabel,textAlign:t.labelAlign,textVerticalAlign:t.labelBaseline}),e.add(h),co(h,go({},l))},this)}},_renderControl:function(t,e,i,n){function o(t,i,o,h){if(t){var c=Rx(n,i,u,{position:t,origin:[a/2,0],rotation:h?-r:0,rectHover:!0,style:s,onclick:o});e.add(c),co(c,l)}}var a=t.controlSize,r=t.rotation,s=n.getModel("controlStyle").getItemStyle(),l=n.getModel("emphasis.controlStyle").getItemStyle(),u=[0,-a/2,a,a],h=n.getPlayState(),c=n.get("inverse",!0);o(t.nextBtnPosition,"controlStyle.nextIcon",nE(this._changeTimeline,this,c?"-":"+")),o(t.prevBtnPosition,"controlStyle.prevIcon",nE(this._changeTimeline,this,c?"+":"-")),o(t.playPosition,"controlStyle."+(h?"stopIcon":"playIcon"),nE(this._handlePlayClick,this,!h),!0)},_renderCurrentPointer:function(t,e,i,n){var o=n.getData(),a=n.getCurrentIndex(),r=o.getItemModel(a).getModel("checkpointStyle"),s=this,l={onCreate:function(t){t.draggable=!0,t.drift=nE(s._handlePointerDrag,s),t.ondragend=nE(s._handlePointerDragend,s),Bx(t,a,i,n,!0)},onUpdate:function(t){Bx(t,a,i,n)}};this._currentPointer=zx(r,r,this._mainGroup,{},this._currentPointer,l)},_handlePlayClick:function(t){this._clearTimer(),this.api.dispatchAction({type:"timelinePlayChange",playState:t,from:this.uid})},_handlePointerDrag:function(t,e,i){this._clearTimer(),this._pointerChangeTimeline([i.offsetX,i.offsetY])},_handlePointerDragend:function(t){this._pointerChangeTimeline([t.offsetX,t.offsetY],!0)},_pointerChangeTimeline:function(t,e){var i=this._toAxisCoord(t)[0],n=Go(this._axis.getExtent().slice());i>n[1]&&(i=n[1]),ii.getHeight()&&(n.textPosition="top",l=!0);var u=l?-5-o.height:s+8;a+o.width/2>i.getWidth()?(n.textPosition=["100%",u],n.textAlign="right"):a-o.width/2<0&&(n.textPosition=[0,u],n.textAlign="left")}})}},updateView:function(t,e,i,n){d(this._features,function(t){t.updateView&&t.updateView(t.model,e,i,n)})},remove:function(t,e){d(this._features,function(i){i.remove&&i.remove(t,e)}),this.group.removeAll()},dispose:function(t,e){d(this._features,function(i){i.dispose&&i.dispose(t,e)})}});var sE=sT.toolbox.saveAsImage;Gx.defaultOption={show:!0,icon:"M4.7,22.9L29.3,45.5L54.7,23.4M4.6,43.6L4.6,58L53.8,58L53.8,43.6M29.2,45.1L29.2,0",title:sE.title,type:"png",name:"",excludeComponents:["toolbox"],pixelRatio:1,lang:sE.lang.slice()},Gx.prototype.unusable=!U_.canvasSupported,Gx.prototype.onclick=function(t,e){var i=this.model,n=i.get("name")||t.get("title.0.text")||"echarts",o=document.createElement("a"),a=i.get("type",!0)||"png";o.download=n+"."+a,o.target="_blank";var r=e.getConnectedDataURL({type:a,backgroundColor:i.get("backgroundColor",!0)||t.get("backgroundColor")||"#fff",excludeComponents:i.get("excludeComponents"),pixelRatio:i.get("pixelRatio")});if(o.href=r,"function"!=typeof MouseEvent||U_.browser.ie||U_.browser.edge)if(window.navigator.msSaveOrOpenBlob){for(var s=atob(r.split(",")[1]),l=s.length,u=new Uint8Array(l);l--;)u[l]=s.charCodeAt(l);var h=new Blob([u]);window.navigator.msSaveOrOpenBlob(h,n+"."+a)}else{var c=i.get("lang"),d='';window.open().document.write(d)}else{var f=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!1});o.dispatchEvent(f)}},Ty("saveAsImage",Gx);var lE=sT.toolbox.magicType;Fx.defaultOption={show:!0,type:[],icon:{line:"M4.1,28.9h7.1l9.3-22l7.4,38l9.7-19.7l3,12.8h14.9M4.1,58h51.4",bar:"M6.7,22.9h10V48h-10V22.9zM24.9,13h10v35h-10V13zM43.2,2h10v46h-10V2zM3.1,58h53.7",stack:"M8.2,38.4l-8.4,4.1l30.6,15.3L60,42.5l-8.1-4.1l-21.5,11L8.2,38.4z M51.9,30l-8.1,4.2l-13.4,6.9l-13.9-6.9L8.2,30l-8.4,4.2l8.4,4.2l22.2,11l21.5-11l8.1-4.2L51.9,30z M51.9,21.7l-8.1,4.2L35.7,30l-5.3,2.8L24.9,30l-8.4-4.1l-8.3-4.2l-8.4,4.2L8.2,30l8.3,4.2l13.9,6.9l13.4-6.9l8.1-4.2l8.1-4.1L51.9,21.7zM30.4,2.2L-0.2,17.5l8.4,4.1l8.3,4.2l8.4,4.2l5.5,2.7l5.3-2.7l8.1-4.2l8.1-4.2l8.1-4.1L30.4,2.2z",tiled:"M2.3,2.2h22.8V25H2.3V2.2z M35,2.2h22.8V25H35V2.2zM2.3,35h22.8v22.8H2.3V35z M35,35h22.8v22.8H35V35z"},title:i(lE.title),option:{},seriesIndex:{}};var uE=Fx.prototype;uE.getIcons=function(){var t=this.model,e=t.get("icon"),i={};return d(t.get("type"),function(t){e[t]&&(i[t]=e[t])}),i};var hE={line:function(t,e,i,o){if("bar"===t)return n({id:e,type:"line",data:i.get("data"),stack:i.get("stack"),markPoint:i.get("markPoint"),markLine:i.get("markLine")},o.get("option.line")||{},!0)},bar:function(t,e,i,o){if("line"===t)return n({id:e,type:"bar",data:i.get("data"),stack:i.get("stack"),markPoint:i.get("markPoint"),markLine:i.get("markLine")},o.get("option.bar")||{},!0)},stack:function(t,e,i,o){if("line"===t||"bar"===t)return n({id:e,stack:"__ec_magicType_stack__"},o.get("option.stack")||{},!0)},tiled:function(t,e,i,o){if("line"===t||"bar"===t)return n({id:e,stack:""},o.get("option.tiled")||{},!0)}},cE=[["line","bar"],["stack","tiled"]];uE.onclick=function(t,e,i){var n=this.model,o=n.get("seriesIndex."+i);if(hE[i]){var a={series:[]};d(cE,function(t){l(t,i)>=0&&d(t,function(t){n.setIconStatus(t,"normal")})}),n.setIconStatus(i,"emphasis"),t.eachComponent({mainType:"series",query:null==o?null:{seriesIndex:o}},function(e){var o=e.subType,s=e.id,l=hE[i](o,s,e,n);l&&(r(l,e.option),a.series.push(l));var u=e.coordinateSystem;if(u&&"cartesian2d"===u.type&&("line"===i||"bar"===i)){var h=u.getAxesByScale("ordinal")[0];if(h){var c=h.dim+"Axis",d=t.queryComponents({mainType:c,index:e.get(name+"Index"),id:e.get(name+"Id")})[0].componentIndex;a[c]=a[c]||[];for(var f=0;f<=d;f++)a[c][d]=a[c][d]||{};a[c][d].boundaryGap="bar"===i}}}),e.dispatchAction({type:"changeMagicType",currentType:i,newOption:a})}},Os({type:"changeMagicType",event:"magicTypeChanged",update:"prepareAndUpdate"},function(t,e){e.mergeOption(t.newOption)}),Ty("magicType",Fx);var dE=sT.toolbox.dataView,fE=new Array(60).join("-"),pE="\t",gE=new RegExp("["+pE+"]+","g");$x.defaultOption={show:!0,readOnly:!1,optionToContent:null,contentToOption:null,icon:"M17.5,17.3H33 M17.5,17.3H33 M45.4,29.5h-28 M11.5,2v56H51V14.8L38.4,2H11.5z M38.4,2.2v12.7H51 M45.4,41.7h-28",title:i(dE.title),lang:i(dE.lang),backgroundColor:"#fff",textColor:"#000",textareaColor:"#fff",textareaBorderColor:"#333",buttonColor:"#c23531",buttonTextColor:"#fff"},$x.prototype.onclick=function(t,e){function i(){n.removeChild(a),x._dom=null}var n=e.getDom(),o=this.model;this._dom&&n.removeChild(this._dom);var a=document.createElement("div");a.style.cssText="position:absolute;left:5px;top:5px;bottom:5px;right:5px;",a.style.backgroundColor=o.get("backgroundColor")||"#fff";var r=document.createElement("h4"),s=o.get("lang")||[];r.innerHTML=s[0]||o.get("title"),r.style.cssText="margin: 10px 20px;",r.style.color=o.get("textColor");var l=document.createElement("div"),u=document.createElement("textarea");l.style.cssText="display:block;width:100%;overflow:auto;";var h=o.get("optionToContent"),c=o.get("contentToOption"),d=Ux(t);if("function"==typeof h){var f=h(e.getOption());"string"==typeof f?l.innerHTML=f:M(f)&&l.appendChild(f)}else l.appendChild(u),u.readOnly=o.get("readOnly"),u.style.cssText="width:100%;height:100%;font-family:monospace;font-size:14px;line-height:1.6rem;",u.style.color=o.get("textColor"),u.style.borderColor=o.get("textareaBorderColor"),u.style.backgroundColor=o.get("textareaColor"),u.value=d.value;var p=d.meta,g=document.createElement("div");g.style.cssText="position:absolute;bottom:0;left:0;right:0;";var m="float:right;margin-right:20px;border:none;cursor:pointer;padding:2px 5px;font-size:12px;border-radius:3px",v=document.createElement("div"),y=document.createElement("div");m+=";background-color:"+o.get("buttonColor"),m+=";color:"+o.get("buttonTextColor");var x=this;ht(v,"click",i),ht(y,"click",function(){var t;try{t="function"==typeof c?c(l,e.getOption()):Kx(u.value,p)}catch(t){throw i(),new Error("Data view format error "+t)}t&&e.dispatchAction({type:"changeDataView",newOption:t}),i()}),v.innerHTML=s[1],y.innerHTML=s[2],y.style.cssText=m,v.style.cssText=m,!o.get("readOnly")&&g.appendChild(y),g.appendChild(v),ht(u,"keydown",function(t){if(9===(t.keyCode||t.which)){var e=this.value,i=this.selectionStart,n=this.selectionEnd;this.value=e.substring(0,i)+pE+e.substring(n),this.selectionStart=this.selectionEnd=i+1,mw(t)}}),a.appendChild(r),a.appendChild(l),a.appendChild(g),l.style.height=n.clientHeight-80+"px",n.appendChild(a),this._dom=a},$x.prototype.remove=function(t,e){this._dom&&e.getDom().removeChild(this._dom)},$x.prototype.dispose=function(t,e){this.remove(t,e)},Ty("dataView",$x),Os({type:"changeDataView",event:"dataViewChanged",update:"prepareAndUpdate"},function(t,e){var i=[];d(t.newOption.series,function(t){var n=e.getSeriesByName(t.name)[0];if(n){var o=n.get("data");i.push({name:t.name,data:Jx(t.data,o)})}else i.push(a({type:"scatter"},t))}),e.mergeOption(r({series:i},t.newOption))});var mE=d,vE="\0_ec_hist_store";nO.extend({type:"dataZoom.select"}),oO.extend({type:"dataZoom.select"});var yE=sT.toolbox.dataZoom,xE=d,_E="\0_ec_\0toolbox-dataZoom_";o_.defaultOption={show:!0,icon:{zoom:"M0,13.5h26.9 M13.5,26.9V0 M32.1,13.5H58V58H13.5 V32.1",back:"M22,1.4L9.9,13.5l12.3,12.3 M10.3,13.5H54.9v44.6 H10.3v-26"},title:i(yE.title)};var wE=o_.prototype;wE.render=function(t,e,i,n){this.model=t,this.ecModel=e,this.api=i,s_(t,e,this,n,i),r_(t,e)},wE.onclick=function(t,e,i){bE[i].call(this)},wE.remove=function(t,e){this._brushController.unmount()},wE.dispose=function(t,e){this._brushController.dispose()};var bE={zoom:function(){var t=!this._isZoomActive;this.api.dispatchAction({type:"takeGlobalCursor",key:"dataZoomSelect",dataZoomSelectActive:t})},back:function(){this._dispatchZoomAction(t_(this.ecModel))}};wE._onBrush=function(t,e){function i(t,e,i){var r=e.getAxis(t),s=r.model,l=n(t,s,a),u=l.findRepresentativeAxisProxy(s).getMinMaxSpan();null==u.minValueSpan&&null==u.maxValueSpan||(i=tk(0,i.slice(),r.scale.getExtent(),0,u.minValueSpan,u.maxValueSpan)),l&&(o[l.id]={dataZoomId:l.id,startValue:i[0],endValue:i[1]})}function n(t,e,i){var n;return i.eachComponent({mainType:"dataZoom",subType:"select"},function(i){i.getAxisModel(t,e.componentIndex)&&(n=i)}),n}if(e.isEnd&&t.length){var o={},a=this.ecModel;this._brushController.updateCovers([]),new hy(a_(this.model.option),a,{include:["grid"]}).matchOutputRanges(t,a,function(t,e,n){if("cartesian2d"===n.type){var o=t.brushType;"rect"===o?(i("x",n,e[0]),i("y",n,e[1])):i({lineX:"x",lineY:"y"}[o],n,e)}}),Qx(a,o),this._dispatchZoomAction(o)}},wE._dispatchZoomAction=function(t){var e=[];xE(t,function(t,n){e.push(i(t))}),e.length&&this.api.dispatchAction({type:"dataZoom",from:this.uid,batch:e})},Ty("dataZoom",o_),Ps(function(t){function e(t,e){if(e){var o=t+"Index",a=e[o];null==a||"all"===a||y(a)||(a=!1===a||"none"===a?[]:[a]),i(t,function(e,i){if(null==a||"all"===a||-1!==l(a,i)){var r={type:"select",$fromToolbox:!0,id:_E+t+i};r[o]=i,n.push(r)}})}}function i(e,i){var n=t[e];y(n)||(n=n?[n]:[]),xE(n,i)}if(t){var n=t.dataZoom||(t.dataZoom=[]);y(n)||(t.dataZoom=n=[n]);var o=t.toolbox;if(o&&(y(o)&&(o=o[0]),o&&o.feature)){var a=o.feature.dataZoom;e("xAxis",a),e("yAxis",a)}}});var SE=sT.toolbox.restore;l_.defaultOption={show:!0,icon:"M3.8,33.4 M47,18.9h9.8V8.7 M56.3,20.1 C52.1,9,40.5,0.6,26.8,2.1C12.6,3.7,1.6,16.2,2.1,30.6 M13,41.1H3.1v10.2 M3.7,39.9c4.2,11.1,15.8,19.5,29.5,18 c14.2-1.6,25.2-14.1,24.7-28.5",title:SE.title},l_.prototype.onclick=function(t,e,i){e_(t),e.dispatchAction({type:"restore",from:this.uid})},Ty("restore",l_),Os({type:"restore",event:"restore",update:"prepareAndUpdate"},function(t,e){e.resetOption("recreate")});var ME,IE="urn:schemas-microsoft-com:vml",TE="undefined"==typeof window?null:window,AE=!1,DE=TE&&TE.document;if(DE&&!U_.canvasSupported)try{!DE.namespaces.zrvml&&DE.namespaces.add("zrvml",IE),ME=function(t){return DE.createElement("')}}catch(t){ME=function(t){return DE.createElement("<"+t+' xmlns="'+IE+'" class="zrvml">')}}var CE=ES.CMD,LE=Math.round,kE=Math.sqrt,PE=Math.abs,NE=Math.cos,OE=Math.sin,EE=Math.max;if(!U_.canvasSupported){var RE=21600,zE=RE/2,BE=function(t){t.style.cssText="position:absolute;left:0;top:0;width:1px;height:1px;",t.coordsize=RE+","+RE,t.coordorigin="0,0"},VE=function(t){return String(t).replace(/&/g,"&").replace(/"/g,""")},GE=function(t,e,i){return"rgb("+[t,e,i].join(",")+")"},FE=function(t,e){e&&t&&e.parentNode!==t&&t.appendChild(e)},WE=function(t,e){e&&t&&e.parentNode===t&&t.removeChild(e)},HE=function(t,e,i){return 1e5*(parseFloat(t)||0)+1e3*(parseFloat(e)||0)+i},ZE=function(t,e){return"string"==typeof t?t.lastIndexOf("%")>=0?parseFloat(t)/100*e:parseFloat(t):t},UE=function(t,e,i){var n=Gt(e);i=+i,isNaN(i)&&(i=1),n&&(t.color=GE(n[0],n[1],n[2]),t.opacity=i*n[3])},XE=function(t){var e=Gt(t);return[GE(e[0],e[1],e[2]),e[3]]},jE=function(t,e,i){var n=e.fill;if(null!=n)if(n instanceof IM){var o,a=0,r=[0,0],s=0,l=1,u=i.getBoundingRect(),h=u.width,c=u.height;if("linear"===n.type){o="gradient";var d=i.transform,f=[n.x*h,n.y*c],p=[n.x2*h,n.y2*c];d&&(Q(f,f,d),Q(p,p,d));var g=p[0]-f[0],m=p[1]-f[1];(a=180*Math.atan2(g,m)/Math.PI)<0&&(a+=360),a<1e-6&&(a=0)}else{o="gradientradial";var f=[n.x*h,n.y*c],d=i.transform,v=i.scale,y=h,x=c;r=[(f[0]-u.x)/y,(f[1]-u.y)/x],d&&Q(f,f,d),y/=v[0]*RE,x/=v[1]*RE;var _=EE(y,x);s=0/_,l=2*n.r/_-s}var w=n.colorStops.slice();w.sort(function(t,e){return t.offset-e.offset});for(var b=w.length,S=[],M=[],I=0;I=2){var D=S[0][0],C=S[1][0],L=S[0][1]*e.opacity,k=S[1][1]*e.opacity;t.type=o,t.method="none",t.focus="100%",t.angle=a,t.color=D,t.color2=C,t.colors=M.join(","),t.opacity=k,t.opacity2=L}"radial"===o&&(t.focusposition=r.join(","))}else UE(t,n,e.opacity)},YE=function(t,e){null!=e.lineDash&&(t.dashstyle=e.lineDash.join(" ")),null==e.stroke||e.stroke instanceof IM||UE(t,e.stroke,e.opacity)},qE=function(t,e,i,n){var o="fill"===e,a=t.getElementsByTagName(e)[0];null!=i[e]&&"none"!==i[e]&&(o||!o&&i.lineWidth)?(t[o?"filled":"stroked"]="true",i[e]instanceof IM&&WE(t,a),a||(a=u_(e)),o?jE(a,i,n):YE(a,i),FE(t,a)):(t[o?"filled":"stroked"]="false",WE(t,a))},KE=[[],[],[]],$E=function(t,e){var i,n,o,a,r,s,l=CE.M,u=CE.C,h=CE.L,c=CE.A,d=CE.Q,f=[],p=t.data,g=t.len();for(a=0;a.01?N&&(O+=.0125):Math.abs(E-D)<1e-4?N&&OA?x-=.0125:x+=.0125:N&&ED?y+=.0125:y-=.0125),f.push(R,LE(((A-C)*M+b)*RE-zE),",",LE(((D-L)*I+S)*RE-zE),",",LE(((A+C)*M+b)*RE-zE),",",LE(((D+L)*I+S)*RE-zE),",",LE((O*M+b)*RE-zE),",",LE((E*I+S)*RE-zE),",",LE((y*M+b)*RE-zE),",",LE((x*I+S)*RE-zE)),r=y,s=x;break;case CE.R:var z=KE[0],B=KE[1];z[0]=p[a++],z[1]=p[a++],B[0]=z[0]+p[a++],B[1]=z[1]+p[a++],e&&(Q(z,z,e),Q(B,B,e)),z[0]=LE(z[0]*RE-zE),B[0]=LE(B[0]*RE-zE),z[1]=LE(z[1]*RE-zE),B[1]=LE(B[1]*RE-zE),f.push(" m ",z[0],",",z[1]," l ",B[0],",",z[1]," l ",B[0],",",B[1]," l ",z[0],",",B[1]);break;case CE.Z:f.push(" x ")}if(i>0){f.push(n);for(var V=0;V100&&(eR=0,tR={});var i,n=iR.style;try{n.font=t,i=n.fontFamily.split(",")[0]}catch(t){}e={style:n.fontStyle||"normal",variant:n.fontVariant||"normal",weight:n.fontWeight||"normal",size:0|parseFloat(n.fontSize||12),family:i||"Microsoft YaHei"},tR[t]=e,eR++}return e};!function(t,e){bb[t]=e}("measureText",function(t,e){var i=DE;QE||((QE=i.createElement("div")).style.cssText="position:absolute;top:-20000px;left:0;padding:0;margin:0;border:none;white-space:pre;",DE.body.appendChild(QE));try{QE.style.font=e}catch(t){}return QE.innerHTML="",QE.appendChild(i.createTextNode(t)),{width:QE.offsetWidth}});for(var oR=new de,aR=[Db,di,fi,kn,rM],rR=0;rR=o&&u+1>=a){for(var h=[],c=0;c=o&&c+1>=a)return T_(0,s.components);l[i]=s}else l[i]=void 0}r++}();if(d)return d}},pushComponent:function(t,e,i){var n=t[t.length-1];n&&n.added===e&&n.removed===i?t[t.length-1]={count:n.count+1,added:e,removed:i}:t.push({count:1,added:e,removed:i})},extractCommon:function(t,e,i,n){for(var o=e.length,a=i.length,r=t.newPos,s=r-n,l=0;r+1=0;--n)if(e[n]===t)return!0;return!1}),i):null:i[0]},D_.prototype.update=function(t,e){if(t){var i=this.getDefs(!1);if(t[this._domName]&&i.contains(t[this._domName]))"function"==typeof e&&e(t);else{var n=this.add(t);n&&(t[this._domName]=n)}}},D_.prototype.addDom=function(t){this.getDefs(!0).appendChild(t)},D_.prototype.removeDom=function(t){var e=this.getDefs(!1);e&&t[this._domName]&&(e.removeChild(t[this._domName]),t[this._domName]=null)},D_.prototype.getDoms=function(){var t=this.getDefs(!1);if(!t)return[];var e=[];return d(this._tagNames,function(i){var n=t.getElementsByTagName(i);e=e.concat([].slice.call(n))}),e},D_.prototype.markAllUnused=function(){var t=this;d(this.getDoms(),function(e){e[t._markLabel]="0"})},D_.prototype.markUsed=function(t){t&&(t[this._markLabel]="1")},D_.prototype.removeUnused=function(){var t=this.getDefs(!1);if(t){var e=this;d(this.getDoms(),function(i){"1"!==i[e._markLabel]&&t.removeChild(i)})}},D_.prototype.getSvgProxy=function(t){return t instanceof kn?xR:t instanceof fi?_R:t instanceof rM?wR:xR},D_.prototype.getTextSvgElement=function(t){return t.__textSvgEl},D_.prototype.getSvgElement=function(t){return t.__svgEl},u(C_,D_),C_.prototype.addWithoutUpdate=function(t,e){if(e&&e.style){var i=this;d(["fill","stroke"],function(n){if(e.style[n]&&("linear"===e.style[n].type||"radial"===e.style[n].type)){var o,a=e.style[n],r=i.getDefs(!0);a._dom?(o=a._dom,r.contains(a._dom)||i.addDom(o)):o=i.add(a),i.markUsed(e);var s=o.getAttribute("id");t.setAttribute(n,"url(#"+s+")")}})}},C_.prototype.add=function(t){var e;if("linear"===t.type)e=this.createElement("linearGradient");else{if("radial"!==t.type)return Yw("Illegal gradient type."),null;e=this.createElement("radialGradient")}return t.id=t.id||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-gradient-"+t.id),this.updateDom(t,e),this.addDom(e),e},C_.prototype.update=function(t){var e=this;D_.prototype.update.call(this,t,function(){var i=t.type,n=t._dom.tagName;"linear"===i&&"linearGradient"===n||"radial"===i&&"radialGradient"===n?e.updateDom(t,t._dom):(e.removeDom(t),e.add(t))})},C_.prototype.updateDom=function(t,e){if("linear"===t.type)e.setAttribute("x1",t.x),e.setAttribute("y1",t.y),e.setAttribute("x2",t.x2),e.setAttribute("y2",t.y2);else{if("radial"!==t.type)return void Yw("Illegal gradient type.");e.setAttribute("cx",t.x),e.setAttribute("cy",t.y),e.setAttribute("r",t.r)}t.global?e.setAttribute("gradientUnits","userSpaceOnUse"):e.setAttribute("gradientUnits","objectBoundingBox"),e.innerHTML="";for(var i=t.colorStops,n=0,o=i.length;n0){var n,o,a=this.getDefs(!0),r=e[0],s=i?"_textDom":"_dom";r[s]?(o=r[s].getAttribute("id"),n=r[s],a.contains(n)||a.appendChild(n)):(o="zr"+this._zrId+"-clip-"+this.nextId,++this.nextId,(n=this.createElement("clipPath")).setAttribute("id",o),a.appendChild(n),r[s]=n);var l=this.getSvgProxy(r);if(r.transform&&r.parent.invTransform&&!i){var u=Array.prototype.slice.call(r.transform);bt(r.transform,r.parent.invTransform,r.transform),l.brush(r),r.transform=u}else l.brush(r);var h=this.getSvgElement(r);n.innerHTML="",n.appendChild(h.cloneNode()),t.setAttribute("clip-path","url(#"+o+")"),e.length>1&&this.updateDom(n,e.slice(1),i)}else t&&t.setAttribute("clip-path","none")},L_.prototype.markUsed=function(t){var e=this;t.__clipPaths&&t.__clipPaths.length>0&&d(t.__clipPaths,function(t){t._dom&&D_.prototype.markUsed.call(e,t._dom),t._textDom&&D_.prototype.markUsed.call(e,t._textDom)})},u(k_,D_),k_.prototype.addWithoutUpdate=function(t,e){if(e&&P_(e.style)){var i,n=e.style;n._shadowDom?(i=n._shadowDom,this.getDefs(!0).contains(n._shadowDom)||this.addDom(i)):i=this.add(e),this.markUsed(e);var o=i.getAttribute("id");t.style.filter="url(#"+o+")"}},k_.prototype.add=function(t){var e=this.createElement("filter"),i=t.style;return i._shadowDomId=i._shadowDomId||this.nextId++,e.setAttribute("id","zr"+this._zrId+"-shadow-"+i._shadowDomId),this.updateDom(t,e),this.addDom(e),e},k_.prototype.update=function(t,e){var i=e.style;if(P_(i)){var n=this;D_.prototype.update.call(this,e,function(t){n.updateDom(e,t._shadowDom)})}else this.remove(t,i)},k_.prototype.remove=function(t,e){null!=e._shadowDomId&&(this.removeDom(e),t.style.filter="")},k_.prototype.updateDom=function(t,e){var i=e.getElementsByTagName("feDropShadow");i=0===i.length?this.createElement("feDropShadow"):i[0];var n,o,a,r,s=t.style,l=t.scale?t.scale[0]||1:1,u=t.scale?t.scale[1]||1:1;if(s.shadowBlur||s.shadowOffsetX||s.shadowOffsetY)n=s.shadowOffsetX||0,o=s.shadowOffsetY||0,a=s.shadowBlur,r=s.shadowColor;else{if(!s.textShadowBlur)return void this.removeDom(e,s);n=s.textShadowOffsetX||0,o=s.textShadowOffsetY||0,a=s.textShadowBlur,r=s.textShadowColor}i.setAttribute("dx",n/l),i.setAttribute("dy",o/u),i.setAttribute("flood-color",r);var h=a/2/l+" "+a/2/u;i.setAttribute("stdDeviation",h),e.setAttribute("x","-100%"),e.setAttribute("y","-100%"),e.setAttribute("width",Math.ceil(a/2*200)+"%"),e.setAttribute("height",Math.ceil(a/2*200)+"%"),e.appendChild(i),s._shadowDom=e},k_.prototype.markUsed=function(t){var e=t.style;e&&e._shadowDom&&D_.prototype.markUsed.call(this,e._shadowDom)};var TR=function(t,e,i,n){this.root=t,this.storage=e,this._opts=i=a({},i||{});var o=p_("svg");o.setAttribute("xmlns","http://www.w3.org/2000/svg"),o.setAttribute("version","1.1"),o.setAttribute("baseProfile","full"),o.style.cssText="user-select:none;position:absolute;left:0;top:0;",this.gradientManager=new C_(n,o),this.clipPathManager=new L_(n,o),this.shadowManager=new k_(n,o);var r=document.createElement("div");r.style.cssText="overflow:hidden;position:relative",this._svgRoot=o,this._viewport=r,t.appendChild(r),r.appendChild(o),this.resize(i.width,i.height),this._visibleList=[]};TR.prototype={constructor:TR,getType:function(){return"svg"},getViewportRoot:function(){return this._viewport},getViewportRootOffset:function(){var t=this.getViewportRoot();if(t)return{offsetLeft:t.offsetLeft||0,offsetTop:t.offsetTop||0}},refresh:function(){var t=this.storage.getDisplayList(!0);this._paintList(t)},setBackgroundColor:function(t){this._viewport.style.background=t},_paintList:function(t){this.gradientManager.markAllUnused(),this.clipPathManager.markAllUnused(),this.shadowManager.markAllUnused();var e,i=this._svgRoot,n=this._visibleList,o=t.length,a=[];for(e=0;e=0;--n)if(e[n]===t)return!0;return!1}),i):null:i[0]},resize:function(t,e){var i=this._viewport;i.style.display="none";var n=this._opts;if(null!=t&&(n.width=t),null!=e&&(n.height=e),t=this._getSize(0),e=this._getSize(1),i.style.display="",this._width!==t||this._height!==e){this._width=t,this._height=e;var o=i.style;o.width=t+"px",o.height=e+"px";var a=this._svgRoot;a.setAttribute("width",t),a.setAttribute("height",e)}},getWidth:function(){return this._width},getHeight:function(){return this._height},_getSize:function(t){var e=this._opts,i=["width","height"][t],n=["clientWidth","clientHeight"][t],o=["paddingLeft","paddingTop"][t],a=["paddingRight","paddingBottom"][t];if(null!=e[i]&&"auto"!==e[i])return parseFloat(e[i]);var r=this.root,s=document.defaultView.getComputedStyle(r);return(r[n]||N_(s[i])||N_(r.style[i]))-(N_(s[o])||0)-(N_(s[a])||0)|0},dispose:function(){this.root.innerHTML="",this._svgRoot=this._viewport=this.storage=null},clear:function(){this._viewport&&this.root.removeChild(this._viewport)},pathToDataUrl:function(){return this.refresh(),"data:image/svg+xml;charset=UTF-8,"+this._svgRoot.outerHTML}},d(["getLayer","insertLayer","eachLayer","eachBuiltinLayer","eachOtherLayer","getLayers","modLayer","delLayer","clearLayer","toDataURL","pathToImage"],function(t){TR.prototype[t]=F_(t)}),Ti("svg",TR),t.version="4.2.1",t.dependencies=RT,t.PRIORITY=GT,t.init=function(t,e,i){var n=Ls(t);if(n)return n;var o=new ls(t,e,i);return o.id="ec_"+nA++,eA[o.id]=o,Fi(t,aA,o.id),Ds(o),o},t.connect=function(t){if(y(t)){var e=t;t=null,PT(e,function(e){null!=e.group&&(t=e.group)}),t=t||"g_"+oA++,PT(e,function(e){e.group=t})}return iA[t]=!0,t},t.disConnect=Cs,t.disconnect=rA,t.dispose=function(t){"string"==typeof t?t=eA[t]:t instanceof ls||(t=Ls(t)),t instanceof ls&&!t.isDisposed()&&t.dispose()},t.getInstanceByDom=Ls,t.getInstanceById=function(t){return eA[t]},t.registerTheme=ks,t.registerPreprocessor=Ps,t.registerProcessor=Ns,t.registerPostUpdate=function(t){$T.push(t)},t.registerAction=Os,t.registerCoordinateSystem=Es,t.getCoordinateSystemDimensions=function(t){var e=Ga.get(t);if(e)return e.getDimensionsInfo?e.getDimensionsInfo():e.dimensions.slice()},t.registerLayout=Rs,t.registerVisual=zs,t.registerLoading=Vs,t.extendComponentModel=Gs,t.extendComponentView=Fs,t.extendSeriesModel=Ws,t.extendChartView=Hs,t.setCanvasCreator=function(t){e("createCanvas",t)},t.registerMap=function(t,e,i){CT.registerMap(t,e,i)},t.getMap=function(t){var e=CT.retrieveMap(t);return e&&e[0]&&{geoJson:e[0].geoJSON,specialAreas:e[0].specialAreas}},t.dataTool=sA,t.zrender=Hb,t.number=YM,t.format=iI,t.throttle=kr,t.helper=eD,t.matrix=Sw,t.vector=cw,t.color=Ww,t.parseGeoJSON=nD,t.parseGeoJson=sD,t.util=lD,t.graphic=uD,t.List=yA,t.Model=Po,t.Axis=rD,t.env=U_}); diff --git a/apps/static/js/webterminal.js b/apps/static/js/webterminal.js deleted file mode 100644 index 12e15c0a8..000000000 --- a/apps/static/js/webterminal.js +++ /dev/null @@ -1,154 +0,0 @@ -/** - * Created by liuzheng on 3/3/16. - */ -var rowHeight = 1; -var colWidth = 1; -function WSSHClient() { -} -WSSHClient.prototype._generateEndpoint = function (options) { - console.log(options); - if (window.location.protocol == 'https:') { - var protocol = 'wss://'; - } else { - var protocol = 'ws://'; - } - - var endpoint = protocol + document.URL.match(RegExp('//(.*?)/'))[1] + '/ws/applications' + document.URL.match(/(\?.*)/); - return endpoint; -}; -WSSHClient.prototype.connect = function (options) { - var endpoint = this._generateEndpoint(options); - - if (window.WebSocket) { - this._connection = new WebSocket(endpoint); - } - else if (window.MozWebSocket) { - this._connection = MozWebSocket(endpoint); - } - else { - options.onError('WebSocket Not Supported'); - return; - } - - this._connection.onopen = function () { - options.onConnect(); - }; - - this._connection.onmessage = function (evt) { - try { - options.onData(evt.data); - } catch (e) { - var data = JSON.parse(evt.data.toString()); - options.onError(data.error); - } - }; - - this._connection.onclose = function (evt) { - options.onClose(); - }; -}; - -WSSHClient.prototype.send = function (data) { - this._connection.send(JSON.stringify({'data': data})); -}; - -function openTerminal(options) { - var client = new WSSHClient(); - var rowHeight, colWidth; - try { - rowHeight = localStorage.getItem('term-row'); - colWidth = localStorage.getItem('term-col'); - } catch (err) { - rowHeight = 35; - colWidth = 100 - } - if (rowHeight) { - } else { - rowHeight = 35 - } - if (colWidth) { - } else { - colWidth = 100 - } - - var term = new Terminal({ - rows: rowHeight, - cols: colWidth, - useStyle: true, - screenKeys: true - }); - term.open(); - term.on('data', function (data) { - client.send(data) - }); - $('.applications').detach().appendTo('#term'); - //term.resize(colWidth, rowHeight); - term.write('Connecting...'); - client.connect($.extend(options, { - onError: function (error) { - term.write('Error: ' + error + '\r\n'); - }, - onConnect: function () { - // Erase our connecting message - client.send({'resize': {'rows': rowHeight, 'cols': colWidth}}); - term.write('\r'); - }, - onClose: function () { - term.write('Connection Reset By Peer'); - }, - onData: function (data) { - term.write(data); - } - })); - //rowHeight = 0.0 + 1.00 * $('.applications').height() / 24; - //colWidth = 0.0 + 1.00 * $('.applications').width() / 80; - return {'term': term, 'client': client}; -} - -//function resize() { -// $('.applications').css('width', window.innerWidth - 25); -// console.log(window.innerWidth); -// console.log(window.innerWidth - 10); -// var rows = Math.floor(window.innerHeight / rowHeight) - 2; -// var cols = Math.floor(window.innerWidth / colWidth) - 1; -// -// return {rows: rows, cols: cols}; -//} - -$(document).ready(function () { - var options = {}; - - $('#ssh').show(); - var term_client = openTerminal(options); - console.log(rowHeight); - // by liuzheng712 because it will bring record bug - //window.onresize = function () { - // var geom = resize(); - // console.log(geom); - // term_client.term.resize(geom.cols, geom.rows); - // term_client.client.send({'resize': {'rows': geom.rows, 'cols': geom.cols}}); - // $('#ssh').show(); - //} - try { - $('#term-row')[0].value = localStorage.getItem('term-row'); - $('#term-col')[0].value = localStorage.getItem('term-col'); - } catch (err) { - $('#term-row')[0].value = 35; - $('#term-col')[0].value = 100; - } - $('#col-row').click(function () { - var col = $('#term-col').val(); - var row = $('#term-row').val(); - localStorage.setItem('term-col', col); - localStorage.setItem('term-row', row); - term_client.term.resize(col, row); - term_client.client.send({'resize': {'rows': row, 'cols': col}}); - $('#ssh').show(); - }); - $(".applications").mouseleave(function () { - $(".termChangBar").slideDown(); - }); - $(".applications").mouseenter(function () { - $(".termChangBar").slideUp(); - }) -}); \ No newline at end of file diff --git a/apps/static/js/wssh.js b/apps/static/js/wssh.js deleted file mode 100644 index e538a0a24..000000000 --- a/apps/static/js/wssh.js +++ /dev/null @@ -1,89 +0,0 @@ -/* -WSSH Javascript Client - -Usage: - -var client = new WSSHClient(); - -client.connect({ - // Connection and authentication parameters - username: 'root', - hostname: 'localhost', - authentication_method: 'password', // can either be password or private_key - password: 'secretpassword', // do not provide when using private_key - key_passphrase: 'secretpassphrase', // *may* be provided if the private_key is encrypted - - // Callbacks - onError: function(error) { - // Called upon an error - console.error(error); - }, - onConnect: function() { - // Called after a successful connection to the server - console.debug('Connected!'); - - client.send('ls\n'); // You can send data back to the server by using WSSHClient.send() - }, - onClose: function() { - // Called when the remote closes the connection - console.debug('Connection Reset By Peer'); - }, - onData: function(data) { - // Called when data is received from the server - console.debug('Received: ' + data); - } -}); - -*/ - -function WSSHClient() { -} - -WSSHClient.prototype._generateEndpoint = function(options) { - console.log(options); - if (window.location.protocol == 'https:') { - var protocol = 'wss://'; - } else { - var protocol = 'ws://'; - } - - var endpoint = protocol + window.location.host + ':8080' + '/applications'; - return endpoint; -}; - -WSSHClient.prototype.connect = function(options) { - var endpoint = this._generateEndpoint(options); - - if (window.WebSocket) { - this._connection = new WebSocket(endpoint); - } - else if (window.MozWebSocket) { - this._connection = MozWebSocket(endpoint); - } - else { - options.onError('WebSocket Not Supported'); - return ; - } - - this._connection.onopen = function() { - options.onConnect(); - }; - - this._connection.onmessage = function (evt) { - var data = JSON.parse(evt.data.toString()); - if (data.error !== undefined) { - options.onError(data.error); - } - else { - options.onData(data.data); - } - }; - - this._connection.onclose = function(evt) { - options.onClose(); - }; -}; - -WSSHClient.prototype.send = function(data) { - this._connection.send(JSON.stringify({'data': data})); -}; diff --git a/apps/templates/404.html b/apps/templates/404.html new file mode 100644 index 000000000..3d2e1a1f8 --- /dev/null +++ b/apps/templates/404.html @@ -0,0 +1,10 @@ + + + + + Not found + + +

    Not found

    + + \ No newline at end of file diff --git a/apps/templates/500.html b/apps/templates/500.html new file mode 100644 index 000000000..d0aa990d7 --- /dev/null +++ b/apps/templates/500.html @@ -0,0 +1,10 @@ + + + + + Server error + + +

    Server error occur, contact administrator

    + + \ No newline at end of file diff --git a/apps/templates/_header_bar.html b/apps/templates/_header_bar.html index c2764cce3..7c7f696b3 100644 --- a/apps/templates/_header_bar.html +++ b/apps/templates/_header_bar.html @@ -94,10 +94,10 @@
  • {% trans 'User page' %}
  • {% endif %} {% endif %} -
  • {% trans 'Logout' %}
  • +
  • {% trans 'Logout' %}
  • {% else %} - + {% trans 'Login' %} {% endif %} diff --git a/apps/templates/_modal.html b/apps/templates/_modal.html index e84586d0c..e25fd85fe 100644 --- a/apps/templates/_modal.html +++ b/apps/templates/_modal.html @@ -8,7 +8,7 @@