# coding: utf-8
from __future__ import absolute_import, unicode_literals, print_function

from django.core.management import BaseCommand

from api.models.others import SearchKeyword


class Command(BaseCommand):
    def handle(self, *args, **options):
        searchkeywords = SearchKeyword.objects.all()
        for skw in searchkeywords:
            skw.is_online = (skw.is_online ^ True)
            skw.save()

        print('success')
