title: Angular date problems
body: <p>Please see the following example: <a href="https://plnkr.co/edit/SGa2xy7M2OuFYOVkeuYe?p=preview" rel="nofollow">https://plnkr.co/edit/SGa2xy7M2OuFYOVkeuYe?p=preview</a></p>
  
  
  
  
  
  <p></p>
  
  <pre><code>&lt;div ng-app="app" ng-controller="MainController"&gt;
      &lt;div class="col-sm-3"&gt;
          &lt;input ng-model="flight.date" name="date" type="date" placeholder="" class="form-control input-md" required="" max="&lt;% Date | date:'yyyy-MM-dd' %&gt;" ng-change="changeDate()"&gt;
      &lt;/div&gt;
      &lt;% flight.date | date %&gt;
      &lt;% flight.date | date : medium : PST %&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>I'm in GMT+2 timezone (CEST) and GMT+1 in winter time (CET).</p>
  
  <p>When I select today from the input field (Jun 30 2016) the output Angular produces is UTC time. So it subtracts 2 hours from the actual time. But because we're only selecting the date the time is always 00:00:00. </p>
  
  <p>So subtracting 2 hours from 00:00:00 will result in a date of the day before.</p>
  
  <p>How do I fix that? I tried manually adding the time to that timestamp which works. But then the problem still exists between midnight and 2 AM.</p>
  
  <p>Thanks!</p>
  
  <p>[EDIT]
  I'm currently using the following workaround:</p>
  
  <p>Since we only need the date I'm just manually setting the time to 6PM so the 1 or 2 hour difference doesnt cause the date to change.</p>
  
  <pre><code>d.setHours('18', '00', '00');
  </code></pre>