diff --git a/src/pages/newMedicalCard/components/InitialInspectionProtocol/Forms/ToothFormula/DentalConditionForm.vue b/src/pages/newMedicalCard/components/InitialInspectionProtocol/Forms/ToothFormula/DentalConditionForm.vue index c362177..703e6ac 100644 --- a/src/pages/newMedicalCard/components/InitialInspectionProtocol/Forms/ToothFormula/DentalConditionForm.vue +++ b/src/pages/newMedicalCard/components/InitialInspectionProtocol/Forms/ToothFormula/DentalConditionForm.vue @@ -27,6 +27,7 @@ v-for="(type, key) in formConfig.conditions", v-model="isOpenExpansion[key]", :label="type.label", + @click="() => partId = ''" @after-show="()=>jumpToItem()" ) .general-expaction.flex.flex-col.pl-4(v-if="!type?.partsTooth") @@ -137,10 +138,12 @@ export default { } }, jumpToItem() { - this.$refs[this.partId][0].scrollIntoView({ - block: "center", - behavior: "smooth", - }); + if (this.partId) { + this.$refs[this.partId][0].scrollIntoView({ + block: "center", + behavior: "smooth", + }); + } }, updateConditions() { let arraySelected = [...this.getFilledConditions(this.data)];