Commit ffae8f5c authored by songrui's avatar songrui

筛查身份证查询修改

parent 7dcb754e
......@@ -188,10 +188,11 @@
</template>
<script>
import { fetchDataHandle } from '@/utils/common.js'
import { fetchDataHandle, getInfoByIdCard } from '@/utils/common.js'
import { idCardRule, mobileValidator } from '@/utils/commonReg.js'
import { useStore } from '@/tumour/store/index.js'
import { getResidentInfo } from '@/tumour/api/base.js'
import { getDictValue } from '@/tumour/utils/dictionaries.js'
import DocAddress from '@/tumour/utils/docAddress/DocAddress.vue'
const defaultForm = (info = {}) => {
......@@ -217,7 +218,7 @@ const defaultForm = (info = {}) => {
gender: undefined,
genderTrans: undefined,
// 身份证号
idCard: '530111199706071417',
idCard: '',
// 婚姻状况,[DC00008]
maritalStatus: undefined,
maritalStatusTrans: undefined,
......@@ -311,7 +312,17 @@ export default {
id: null,
species: []
})
return
}
const info = getInfoByIdCard(idCard)
this.form = defaultForm({
gender: info.gender,
genderTrans: getDictValue('DC00005', info.gender),
dataBirth: info.dataBirth,
age: info.age,
species: []
})
console.log(info)
})
},
submit() {
......
import dayjs from 'dayjs'
import { validateIdCard } from './commonReg.js'
// sessionStorage 保存 获取
export function setSessionStorage(key, data) {
if (!key || !data) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment