code: public function removeAllRules()
      {
          if (!$this->supportsCascadeUpdate()) {
              $this->db->createCommand()
                  ->update($this->itemTable, ['rule_name' => null])
                  ->execute();
          }
  
          $this->db->createCommand()->delete($this->ruleTable)->execute();
  
          $this->invalidateCache();
      }
docs: {@inheritdoc}