Exemple #1
0
 def get_questions(self):
     from inquirer.questions import Checkbox as checkbox
     choices = self._get_choices()
     questions = [
         checkbox(
             'rules',
             message=(
                 "= The Rules IDs = (move - UP and DOWN arrows,"
                 " select - SPACE or LEFT and RIGHT arrows, submit - ENTER)"
             ),
             choices=choices,
         ),
     ]
     return questions
Exemple #2
0
 def get_questions(self):
     rules = self.search_rules_id()
     if self.show_fail_rules:
         rules = self.get_only_fail_rule(rules)
     choices_ = []
     for rule in rules:
         choices_.append(rule['id_rule'])
     if self.show_not_selected_rules:
         print('== The not selected rule IDs ==')
         for rule in self._get_wanted_not_selected_rules():
             print(rule['id_rule'] + '(Not selected)')
     from inquirer.questions import Checkbox as checkbox
     questions = [
         checkbox(
             'rules',
             message=(
                 "= The Rules IDs = (move - UP and DOWN arrows,"
                 " select - SPACE or LEFT and RIGHT arrows, submit - ENTER)"
             ),
             choices=choices_,
         ),
     ]
     return questions