title: ionic - changeDetectorRef detectChanges() modifies the model
body: <p>In my page controller at some point i need to update the UI, and it appears that a call to chageDetector.detectChanges() in mandatory at that particular point.
  What happens is: i'm re-assigning a string property in my model whose value changes some of my UI.
  As soon as i call the detectChanges() method, that property acquires <strong><em>its old value</em></strong>.
  I'll only change names and values to my code, but apart from that, the following is what i'm working with:</p>
  
  <p>First of all i have an enum:</p>
  
  <pre><code>enum TypeEnum { TypeA: 'A', TypeB: 'B' }
  </code></pre>
  
  <p>Then my controller:</p>
  
  <pre><code>selectType(type: TypeEnum) {  //type has value 'B'
  
    this.verify = true;
    this.setFieldXOnTypeChange(type);
  
                                            //this.model.type has value 'A'
    this.model.type = type;                 //this.model.type = 'B'
                                            //now this.model.type has value 'B'
  
    //other stuff is calculated
    this.scrollToBottom();
    this.onFieldYReturn(null, true, true);
    this.typeAccordionHeader.value = type;
    if (type == typeEnum.TypeB) {
      this.model.date = this.today;
    }
    this.setPageTitleForType(type);
  
                                          //before call &gt; this.model.type: 'B'
    this.changeDetector.detectChanges();
                                          // after call &gt; this.model.type: 'A'
  }
  </code></pre>
  
  <p>This is a behaviour i never experienced before: i knew changeDetector purpose was to apply model changes to the component, nothing else.
  Can anyone explain the behaviour and, in case, how to avoid it?
  Thanks in advance!</p>