Laravel & Vue.js Contact Flag Integration
Budget: $30 – $250 AUD
Project Overview:
We have a PHP Laravel backend with a Vue.js frontend. A working API endpoint currently accepts a JSON payload to manage contact records for customers. We now need to include an additional boolean flag in the payload: isPrimaryContact, which designates one contact as the primary for a given customer.
Job Requirements:
Update the frontend (Vue.js) form logic to allow setting isPrimaryContact: true for a contact when creating or editing.
Modify the backend Laravel controller/model logic to:
Accept and process the new isPrimaryContact flag in the JSON payload.
Ensure only one contact per customer can be marked as primary (isPrimaryContact = true) — automatically set all other contacts for that customer to false if a new one is marked primary.
Ensure database is updated correctly and existing endpoint continues to function without regressions.
Validate incoming payloads and respond with appropriate success/failure codes/messages.
Add a simple test case or example payload to demonstrate that the logic works as intended.
Tech Stack:
PHP (Laravel)
Vue.js (likely using Axios or fetch)
MySQL
Deliverables:
Updated Laravel backend logic with support for isPrimaryContact enforcement
Updated Vue.js frontend with checkbox/toggle for primary contact
Example JSON payloads (valid and invalid)
Confirmation that endpoint continues to function as expected
Short test plan or demo screencast
We have a PHP Laravel backend with a Vue.js frontend. A working API endpoint currently accepts a JSON payload to manage contact records for customers. We now need to include an additional boolean flag in the payload: isPrimaryContact, which designates one contact as the primary for a given customer.
Job Requirements:
Update the frontend (Vue.js) form logic to allow setting isPrimaryContact: true for a contact when creating or editing.
Modify the backend Laravel controller/model logic to:
Accept and process the new isPrimaryContact flag in the JSON payload.
Ensure only one contact per customer can be marked as primary (isPrimaryContact = true) — automatically set all other contacts for that customer to false if a new one is marked primary.
Ensure database is updated correctly and existing endpoint continues to function without regressions.
Validate incoming payloads and respond with appropriate success/failure codes/messages.
Add a simple test case or example payload to demonstrate that the logic works as intended.
Tech Stack:
PHP (Laravel)
Vue.js (likely using Axios or fetch)
MySQL
Deliverables:
Updated Laravel backend logic with support for isPrimaryContact enforcement
Updated Vue.js frontend with checkbox/toggle for primary contact
Example JSON payloads (valid and invalid)
Confirmation that endpoint continues to function as expected
Short test plan or demo screencast