Developing Appointment Module with Vue 3 and Laravel | Part 23

Posted by






Let’s start working on Appointment Module using Vue 3 and Laravel | Part 23

Let’s start working on Appointment Module using Vue 3 and Laravel | Part 23

Today, we will continue our journey of building an Appointment Module using Vue 3 and Laravel. In the previous parts of this series, we have covered the basics of Vue 3 and Laravel, as well as the setup of our project. Now, it’s time to dive into the actual implementation of the Appointment Module.

Setting up the Appointment Component

First, let’s create a new component for managing appointments. We will use the vue-cli to generate a new component called Appointment.vue. This component will be responsible for displaying a list of appointments, as well as allowing users to create, update, and delete appointments.

Fetching Appointments from the API

Next, we will set up the logic for fetching appointments from the Laravel backend using Axios. We will create a method in our Appointment.vue component that makes a GET request to the Laravel API endpoint for fetching appointments. We will then use this method to populate the appointments list in our component.

Creating and Updating Appointments

Once we have the list of appointments, we can implement the logic for creating and updating appointments. We will add forms to our Appointment.vue component that allow users to input appointment details and submit them to the backend. We will also handle the logic for updating existing appointments.

Deleting Appointments

Finally, we will implement the logic for deleting appointments. We will add a button to each appointment in the list that, when clicked, will send a DELETE request to the Laravel backend to delete the appointment from the database. We will also update the appointments list in real-time to reflect the changes.

By the end of this part, we will have a fully functional Appointment Module that allows users to manage their appointments using Vue 3 and Laravel. Stay tuned for the next part of our series, where we will continue to enhance and refine the functionality of our Appointment Module.


0 0 votes
Article Rating
3 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Дмитрий Лазарев
11 months ago

When I run this:

Client::factory()->create();

I get an error:

Class "Client" not found.

😐 Aliasing don't work for me, for this model

Akmal Sulaymonov
11 months ago

Thanks for lesson. Really appreciate. Could you update github ? thanks

doaa bakhiet
11 months ago

keep going 👏👏👏