title: How to check checkbox in Vue.js?
body: <p>I'm trying to get the total score by checking the checkbox on Vue.js, but I can't subtract from the total score when the same checkbox is clicked.</p>
  
  <pre class="lang-vue prettyprint-override"><code>&lt;template&gt;
    &lt;div class="container"&gt;
      &lt;ul class="list-group" v-for="(data,key) in questionData" :key="key"&gt;
        &lt;li class="list-item"   style="list-style-type:none;"&gt;
          &lt;h3 class="title"&gt;{{data.title}}&lt;/h3&gt;
        &lt;/li&gt;
        &lt;ul class="list-group" &gt;
            &lt;li class="list-question" v-for="(title,key) in data.questions" :key="key" style="list-style-type:none;"&gt;&lt;input type="checkbox" @click="total(data.id, title.id)" :id="title.id" :value="title.question" v-model="selected"&gt;{{ title.question}} &lt;/li&gt;
          &lt;/ul&gt;
      &lt;/ul&gt;
      &lt;div class="alert"&gt;
        Toplam Puan : {{totalScore}}
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/template&gt;
  &lt;script&gt;
  import {dataMixin} from "./dataMixin"
    export default {
      mixins : [dataMixin],
      data () {
        return{
          checked : false,
          questionData : [],
          selected : [],
          totalScore : 0
  
        }
      },
      methods :{
       total(dataId,titleId){
        this.questionData.forEach(data =&gt; {
  
          data.questions.forEach(element =&gt; {
            if(dataId == data.id &amp;&amp; titleId == element.id){
  
             this.checked = !this.checked;
              if (this.checked  == true){
                this.totalScore += element.score
              }
              else {
                this.totalScore -= element.score
  
              }
  
            }
          });
  
        });
       }
  
      },
      created(){
        this.getDataQuestions()
              .then(response =&gt; {
  
          this.questionData = response.data;
          console.log(this.questionData)
              })
      }
    }
  
  &lt;/script&gt;
  </code></pre>
  
  <p><strong>Example JSON data</strong></p>
  
  <pre class="lang-json prettyprint-override"><code>[
      {
          "id" : 1,
          "title" : "Sözleşme Doğrulaması",
          "questions" : [
              {
                  "id" : 1,
                  "question" : "Geliştirici tüm isterleri karşılayabileceği güvenini vermektedir.",
                  "score" : 5
              },
              {
                  "id" : 2,
                  "question" : "İsterler tutarlı olup kullanıcı gereksinimlerini kapsamaktadır.",
                  "score" : 5
              }
          ]
      }
  ]
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/SdaML.png" alt="Screenshot"></p>