update estimeate submit button text
This commit is contained in:
parent
82f9b1aac2
commit
208337155a
@ -23,7 +23,7 @@
|
|||||||
:validate-on-submit="true"
|
:validate-on-submit="true"
|
||||||
:loading="isSubmitting"
|
:loading="isSubmitting"
|
||||||
:disable-on-loading="true"
|
:disable-on-loading="true"
|
||||||
submit-button-text="Create Client"
|
submit-button-text="Create Estimate"
|
||||||
cancel-button-text="Cancel"
|
cancel-button-text="Cancel"
|
||||||
@submit="handleSubmit"
|
@submit="handleSubmit"
|
||||||
@cancel="handleCancel"
|
@cancel="handleCancel"
|
||||||
@ -122,7 +122,7 @@ const formFields = computed(() => [
|
|||||||
placeholder: "Select Customer or Business",
|
placeholder: "Select Customer or Business",
|
||||||
cols: 12,
|
cols: 12,
|
||||||
md: 6,
|
md: 6,
|
||||||
options: ["Customer", "Business"]
|
options: ["Customer", "Business"],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "partyName",
|
name: "partyName",
|
||||||
@ -135,7 +135,6 @@ const formFields = computed(() => [
|
|||||||
},
|
},
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
|
||||||
// Show status message to user
|
// Show status message to user
|
||||||
function showStatusMessage(message, type = "info") {
|
function showStatusMessage(message, type = "info") {
|
||||||
statusMessage.value = message;
|
statusMessage.value = message;
|
||||||
@ -206,7 +205,10 @@ async function handleSubmit(formDataFromEvent) {
|
|||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.error("CreateEstimateModal: Error creating client:", error);
|
console.error("CreateEstimateModal: Error creating client:", error);
|
||||||
showStatusMessage(error.message || "Failed to create estimate. Please try again.", "error");
|
showStatusMessage(
|
||||||
|
error.message || "Failed to create estimate. Please try again.",
|
||||||
|
"error",
|
||||||
|
);
|
||||||
} finally {
|
} finally {
|
||||||
isSubmitting.value = false;
|
isSubmitting.value = false;
|
||||||
// Also reset the Form component's internal submission state
|
// Also reset the Form component's internal submission state
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user