调用handlePoliceSituation方法时页面卡住。
form为组件 v-if显示出来的
@blur="handlePoliceSituation"
方法里面什么都没写,只写了个alert,alert提示过后页面就卡主了。
<Form
autoComplete="off"
class="p-f enter-x"
:model="formData"
ref="formRef"
@keypress.enter="handleSubmit"
:label-col="{ span: 5 }"
:wrapper-col="{ span: 17 }"
:selfUpdate="true"
>
<FormItem name="barzjhm" class="enter-x" label="身份证号:">
<Input
size="large"
v-model:value="formData.barzjhm"
placeholder="请输入身份证号"
class="fix-auto-fill"
/>
</FormItem>
<FormItem name="barxm" class="enter-x" label="姓名:">
<Input
style="width: 230px"
size="large"
v-model:value="formData.barxm"
@blur="handlePoliceSituation"
placeholder="请输入姓名"
class="fix-auto-fill"
/>
</FormItem>
<FormItem name="barxb" class="enter-x" label="性别:">
<Input
size="large"
style="width: 230px"
v-model:value="formData.barxb"
placeholder="请输入性别"
class="fix-auto-fill"
/>
</FormItem>
<FormItem name="bargj" class="enter-x" label="联系方式:">
<Input
size="large"
style="width: 230px"
v-model:value="formData.bargj"
placeholder="请输入联系方式"
class="fix-auto-fill"
/>
</FormItem>
<FormItem name="barzz" class="enter-x" label="报案地址:">
<Input
size="large"
v-model:value="formData.barzz"
placeholder="请输入报案地址"
class="fix-auto-fill"
/>
</FormItem>
<FormItem name="jyaq" class="enter-x" label="事项内容:">
<div class="sxnr" v-if="strPage === 'ReceivingReports'">
<Button
v-for="(item, index) in btnList"
:key="item"
class="sx-btn"
@click="onSelectBtn(index, item)"
:class="selectIndex === index ? 'bg-color' : ''"
type="primary"
size="large"
>{{ item.label }}</Button
>
</div>
<div class="textarea-box">
<a-textarea :rows="3" v-model:value="formData.jyaq" />
</div>
</FormItem>
1