title: Checkbox checked if the value is true in angular 4
body: <p>I have a checkbox when on certain condition we need to make the checkbox checked.For eg Whenever <code>accept()</code> function calls, it triggers <code>onApprovedDateChecked()</code> function by passing true as a parameter.Whenever i get <code>true</code> i need to make the checkbox to be checked.Can anyone help me to sort this out??</p>
  
  <p><strong>component.html</strong></p>
  
  <pre><code> &lt;p-checkbox label="dsd" formControlName="fcont" binary="true" 
                                 (onChange)="onChecked($event)"&gt;&lt;/p-checkbox&gt;
  </code></pre>
  
  <p><strong>component.ts</strong></p>
  
  <pre><code>    accept(){
        onChecked(true)
      }
  
     onChecked(e: any){
  
       //make the checkbox to checked
     }
  </code></pre>