CSR-715 Fix validation
This commit is contained in:
parent
173f1b495b
commit
75b1640f70
3 changed files with 5 additions and 5 deletions
|
|
@ -361,7 +361,7 @@ export default {
|
||||||
isWindshieldRepair() {
|
isWindshieldRepair() {
|
||||||
if (!this.isWindshieldDamageLocation) return false;
|
if (!this.isWindshieldDamageLocation) return false;
|
||||||
|
|
||||||
return this.selectedWindshieldOptions.selectedWindshieldDamageType.toUpperCase() === damageLocationsSelected.REPAIR;
|
return this.selectedWindshieldOptions.selectedWindshieldDamageType.toUpperCase() === damageLocationsSelected.REPAIR.toUpperCase();
|
||||||
},
|
},
|
||||||
isDriverSideReplace() {
|
isDriverSideReplace() {
|
||||||
if (!this.isSideDoorDamageLocation) return false;
|
if (!this.isSideDoorDamageLocation) return false;
|
||||||
|
|
|
||||||
|
|
@ -63,6 +63,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { useField } from "vee-validate";
|
import { useField } from "vee-validate";
|
||||||
|
import { toRef } from "vue";
|
||||||
import { queryStrings } from "@/constants/query-strings";
|
import { queryStrings } from "@/constants/query-strings";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
|
|
@ -177,7 +178,7 @@ export default {
|
||||||
},
|
},
|
||||||
selectedValues(newVal) {
|
selectedValues(newVal) {
|
||||||
if (typeof newVal === "string") {
|
if (typeof newVal === "string") {
|
||||||
this.handleChange(this.value);
|
this.handleChange(newVal);
|
||||||
this.checkValue = newVal == this.value;
|
this.checkValue = newVal == this.value;
|
||||||
}
|
}
|
||||||
else if (newVal !== undefined) {
|
else if (newVal !== undefined) {
|
||||||
|
|
@ -203,7 +204,7 @@ export default {
|
||||||
const {
|
const {
|
||||||
handleChange,
|
handleChange,
|
||||||
errors,
|
errors,
|
||||||
} = useField(props.groupName, props.validationRules, fieldOptions);
|
} = useField(toRef(props, "groupName"), toRef(props, "validationRules"), fieldOptions);
|
||||||
|
|
||||||
return {
|
return {
|
||||||
handleChange,
|
handleChange,
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,6 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { toRefs } from "vue";
|
|
||||||
import { useField } from "vee-validate";
|
import { useField } from "vee-validate";
|
||||||
export default {
|
export default {
|
||||||
name: "radio",
|
name: "radio",
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue