title: How to reset model in Yii2 to add new/next record?
body: <p>I'm using Yii2 framework. And I need solution how to reset <code>$model</code> to put/create next row from inside that model.</p>
  
  <pre><code>    &lt;?php
  
      namespace app\models;
  
      use Yii;
  
      class Queue extends \yii\db\ActiveRecord {
  
          public function stackOverflow(){
              while(true){
                $this-&gt;text = 'asd';
                $this-&gt;save();
                $this-&gt;resetForNextRecord(); // ????????
              }
          }
      }
      ?&gt;
  </code></pre>