feat(front) : required sur les champs obligatoires adresse et comptabilite
- bloc adresse : pays, code postal, ville, adresse passes en required - comptabilite : siren, n° compte, mode TVA, n° TVA, delai et type de reglement passes en required (banque deja required si virement, RIB si LCR)
This commit is contained in:
@@ -54,6 +54,7 @@
|
|||||||
:options="countryOptions"
|
:options="countryOptions"
|
||||||
:label="t('commercial.clients.form.address.country')"
|
:label="t('commercial.clients.form.address.country')"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
|
:required="true"
|
||||||
@update:model-value="(v: string | number | null) => update('country', String(v ?? 'France'))"
|
@update:model-value="(v: string | number | null) => update('country', String(v ?? 'France'))"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
@@ -62,6 +63,7 @@
|
|||||||
:label="t('commercial.clients.form.address.postalCode')"
|
:label="t('commercial.clients.form.address.postalCode')"
|
||||||
:mask="POSTAL_CODE_MASK"
|
:mask="POSTAL_CODE_MASK"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
|
:required="true"
|
||||||
:error="errors?.postalCode"
|
:error="errors?.postalCode"
|
||||||
@update:model-value="onPostalCodeChange"
|
@update:model-value="onPostalCodeChange"
|
||||||
/>
|
/>
|
||||||
@@ -75,6 +77,7 @@
|
|||||||
:label="t('commercial.clients.form.address.city')"
|
:label="t('commercial.clients.form.address.city')"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="errors?.city"
|
:error="errors?.city"
|
||||||
@update:model-value="(v: string | number | null) => update('city', v === null ? null : String(v))"
|
@update:model-value="(v: string | number | null) => update('city', v === null ? null : String(v))"
|
||||||
/>
|
/>
|
||||||
@@ -83,6 +86,7 @@
|
|||||||
:model-value="model.city"
|
:model-value="model.city"
|
||||||
:label="t('commercial.clients.form.address.city')"
|
:label="t('commercial.clients.form.address.city')"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
|
:required="true"
|
||||||
:error="errors?.city"
|
:error="errors?.city"
|
||||||
@update:model-value="(v: string) => update('city', v)"
|
@update:model-value="(v: string) => update('city', v)"
|
||||||
/>
|
/>
|
||||||
@@ -103,6 +107,7 @@
|
|||||||
:min-search-length="3"
|
:min-search-length="3"
|
||||||
:label="t('commercial.clients.form.address.street')"
|
:label="t('commercial.clients.form.address.street')"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
|
:required="true"
|
||||||
:error="errors?.street"
|
:error="errors?.street"
|
||||||
@update:model-value="(v: string | number | null) => update('street', v === null ? null : String(v))"
|
@update:model-value="(v: string | number | null) => update('street', v === null ? null : String(v))"
|
||||||
@search="onAddressSearch"
|
@search="onAddressSearch"
|
||||||
@@ -113,6 +118,7 @@
|
|||||||
:model-value="model.street"
|
:model-value="model.street"
|
||||||
:label="t('commercial.clients.form.address.street')"
|
:label="t('commercial.clients.form.address.street')"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
|
:required="true"
|
||||||
:error="errors?.street"
|
:error="errors?.street"
|
||||||
@update:model-value="(v: string) => update('street', v)"
|
@update:model-value="(v: string) => update('street', v)"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -228,12 +228,14 @@
|
|||||||
:label="t('commercial.clients.form.accounting.siren')"
|
:label="t('commercial.clients.form.accounting.siren')"
|
||||||
:mask="SIREN_MASK"
|
:mask="SIREN_MASK"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.siren"
|
:error="accountingErrors.errors.siren"
|
||||||
/>
|
/>
|
||||||
<MalioInputText
|
<MalioInputText
|
||||||
v-model="accounting.accountNumber"
|
v-model="accounting.accountNumber"
|
||||||
:label="t('commercial.clients.form.accounting.accountNumber')"
|
:label="t('commercial.clients.form.accounting.accountNumber')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.accountNumber"
|
:error="accountingErrors.errors.accountNumber"
|
||||||
/>
|
/>
|
||||||
<MalioSelect
|
<MalioSelect
|
||||||
@@ -242,6 +244,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.tvaMode')"
|
:label="t('commercial.clients.form.accounting.tvaMode')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.tvaMode"
|
:error="accountingErrors.errors.tvaMode"
|
||||||
@update:model-value="(v: string | number | null) => accounting.tvaModeIri = v === null ? null : String(v)"
|
@update:model-value="(v: string | number | null) => accounting.tvaModeIri = v === null ? null : String(v)"
|
||||||
/>
|
/>
|
||||||
@@ -249,6 +252,7 @@
|
|||||||
v-model="accounting.nTva"
|
v-model="accounting.nTva"
|
||||||
:label="t('commercial.clients.form.accounting.nTva')"
|
:label="t('commercial.clients.form.accounting.nTva')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.nTva"
|
:error="accountingErrors.errors.nTva"
|
||||||
/>
|
/>
|
||||||
<MalioSelect
|
<MalioSelect
|
||||||
@@ -257,6 +261,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.paymentDelay')"
|
:label="t('commercial.clients.form.accounting.paymentDelay')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.paymentDelay"
|
:error="accountingErrors.errors.paymentDelay"
|
||||||
@update:model-value="(v: string | number | null) => accounting.paymentDelayIri = v === null ? null : String(v)"
|
@update:model-value="(v: string | number | null) => accounting.paymentDelayIri = v === null ? null : String(v)"
|
||||||
/>
|
/>
|
||||||
@@ -266,6 +271,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.paymentType')"
|
:label="t('commercial.clients.form.accounting.paymentType')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.paymentType"
|
:error="accountingErrors.errors.paymentType"
|
||||||
@update:model-value="onPaymentTypeChange"
|
@update:model-value="onPaymentTypeChange"
|
||||||
/>
|
/>
|
||||||
|
|||||||
@@ -226,12 +226,14 @@
|
|||||||
:label="t('commercial.clients.form.accounting.siren')"
|
:label="t('commercial.clients.form.accounting.siren')"
|
||||||
:mask="SIREN_MASK"
|
:mask="SIREN_MASK"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.siren"
|
:error="accountingErrors.errors.siren"
|
||||||
/>
|
/>
|
||||||
<MalioInputText
|
<MalioInputText
|
||||||
v-model="accounting.accountNumber"
|
v-model="accounting.accountNumber"
|
||||||
:label="t('commercial.clients.form.accounting.accountNumber')"
|
:label="t('commercial.clients.form.accounting.accountNumber')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.accountNumber"
|
:error="accountingErrors.errors.accountNumber"
|
||||||
/>
|
/>
|
||||||
<MalioSelect
|
<MalioSelect
|
||||||
@@ -240,6 +242,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.tvaMode')"
|
:label="t('commercial.clients.form.accounting.tvaMode')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.tvaMode"
|
:error="accountingErrors.errors.tvaMode"
|
||||||
@update:model-value="(v: string | number | null) => accounting.tvaModeIri = v === null ? null : String(v)"
|
@update:model-value="(v: string | number | null) => accounting.tvaModeIri = v === null ? null : String(v)"
|
||||||
/>
|
/>
|
||||||
@@ -247,6 +250,7 @@
|
|||||||
v-model="accounting.nTva"
|
v-model="accounting.nTva"
|
||||||
:label="t('commercial.clients.form.accounting.nTva')"
|
:label="t('commercial.clients.form.accounting.nTva')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.nTva"
|
:error="accountingErrors.errors.nTva"
|
||||||
/>
|
/>
|
||||||
<MalioSelect
|
<MalioSelect
|
||||||
@@ -255,6 +259,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.paymentDelay')"
|
:label="t('commercial.clients.form.accounting.paymentDelay')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.paymentDelay"
|
:error="accountingErrors.errors.paymentDelay"
|
||||||
@update:model-value="(v: string | number | null) => accounting.paymentDelayIri = v === null ? null : String(v)"
|
@update:model-value="(v: string | number | null) => accounting.paymentDelayIri = v === null ? null : String(v)"
|
||||||
/>
|
/>
|
||||||
@@ -264,6 +269,7 @@
|
|||||||
:label="t('commercial.clients.form.accounting.paymentType')"
|
:label="t('commercial.clients.form.accounting.paymentType')"
|
||||||
:readonly="accountingReadonly"
|
:readonly="accountingReadonly"
|
||||||
empty-option-label=""
|
empty-option-label=""
|
||||||
|
:required="true"
|
||||||
:error="accountingErrors.errors.paymentType"
|
:error="accountingErrors.errors.paymentType"
|
||||||
@update:model-value="onPaymentTypeChange"
|
@update:model-value="onPaymentTypeChange"
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user