title: Yii2: display dates in user time zone
body: <p>In my DB I store all <code>datetime</code> fields in <strong>UTC format</strong>. Also, I have the ability to change default time zone by users. Each user can have own time zone, <strong>different from UTC</strong>.</p>
  
  <p>How shall I display all model <code>datetime</code> fields in this case?</p>
  
  <p>I have an idea. To do this action for each ActiveRecord model:</p>
  
  <pre><code>public function init()
  {
      parent::init();
  
      $this-&gt;on(ActiveRecord::EVENT_AFTER_FIND, function($event) {
  
          $this-&gt;created_date = (new \DateTime('now', new \DateTimeZone("Europe/Kiev")))-&gt;format("Y-m-d H:i:s");
  
      });
  }
  </code></pre>
  
  <p>But I'm not sure it's the best way for big amount of models...</p>