client creation bug fixes
This commit is contained in:
parent
cb33d0c3b3
commit
2ea20a86e3
7 changed files with 52 additions and 19 deletions
|
|
@ -148,7 +148,8 @@ const localFormData = computed({
|
|||
set: (value) => emit("update:formData", value),
|
||||
});
|
||||
|
||||
const isNewContact = ref(false);
|
||||
// Default to true for new-client flows; if editing keep it off
|
||||
const isNewContact = ref(!props.isEditMode);
|
||||
const selectedContact = ref(null);
|
||||
const sameAsClientName = ref(false);
|
||||
|
||||
|
|
|
|||
|
|
@ -262,6 +262,7 @@ const formData = ref({
|
|||
onMounted(() => {
|
||||
if (props.isNew) {
|
||||
resetForm();
|
||||
isNewClientMode.value = true; // Set to true for new client mode
|
||||
console.log("Mounted in new client mode - initialized empty form");
|
||||
} else if (props.clientData && Object.keys(props.clientData).length > 0) {
|
||||
populateFormFromClientData();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue