From b4849707f7cd990a76061f4fa4bf71b66cae0f76 Mon Sep 17 00:00:00 2001
From: Cristiano Magro <cristiano.magro@vola.it>
Date: Wed, 08 Jan 2025 13:01:02 +0100
Subject: [PATCH] v-model on Custom Components

---
 11 - Forms/xno-forms-01-starting-setup/src/components/TheForm.vue |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/11 - Forms/xno-forms-01-starting-setup/src/components/TheForm.vue b/11 - Forms/xno-forms-01-starting-setup/src/components/TheForm.vue
index 1e57924..1e80ce5 100644
--- a/11 - Forms/xno-forms-01-starting-setup/src/components/TheForm.vue
+++ b/11 - Forms/xno-forms-01-starting-setup/src/components/TheForm.vue
@@ -49,9 +49,7 @@
     </div>
 
     <div class="form-control">
-      <rating-control>
-
-      </rating-control>
+      <rating-control v-model="rating"></rating-control>
     </div>
 
     <div class="form-control">
@@ -80,6 +78,7 @@
       how: null,
       confirm: false,
       usernameValidity: 'pending',
+      rating: null,
     }
   },
   methods: {
@@ -97,14 +96,19 @@
 
       console.log('Checkbox: ');
       console.log(this.interest);
-      console.log('Radio buttons: ');
+      console.log('- Radio buttons: ');
       console.log(this.how);
       this.interest = [];
       this.how = null;
 
-      console.log('Confirm');
+      console.log('- Confirm:');
       console.log(this.confirm);
       this.confirm = false;
+
+      console.log('- Rating:');
+      console.log(this.rating);
+      this.rating = null;
+
     },
     validateInput() {
       if (this.userName === '') {

--
Gitblit v1.8.0