Level 58
To get the response data in the console, you can simply log the response object in the console using console.log(response.data). This will log the data returned by the server in the console.
Here's the updated code:
watch: {
date(newDate) {
const showType = document.getElementById('showType');
showType.textContent = newDate;
axios.get('{{ route('product.warranty.save') }}', {
date: newDate,
product_id: this.product_id,
warranty_id: this.warranty_id,
})
.then(response => {
console.log('get Response---->: ', response.data);
})
.catch(error => {
console.log('Error:', error);
});
}
},
This will log the warranty_id, product_id, and date in the console. You can then use this data as required.