清理idCardNoUtils,改使用ID对象

This commit is contained in:
aixianling
2022-10-14 13:58:35 +08:00
parent 12b3a48baa
commit cfb0177a45
27 changed files with 193 additions and 162 deletions

View File

@@ -52,6 +52,8 @@
</template>
<script>
import {ID} from "dvcp-ui/lib/js/utils";
export default {
name: 'Detail',
@@ -67,14 +69,13 @@
tabTitle: ['人员信息', '走访记录'],
info: {},
list: [],
idNumberInfo: {}
}
},
created () {
if (this.params && this.params.id) {
this.id = this.params.id
this.dict.load('appSpecialSituation', 'appSpecialPlacement', 'appSpecialDenger', 'appSpecialCrime',
'appSpecialControl', 'appSpecialDebug', 'appSpecialDrug', 'appSpecialChangeType', 'appSpecialCure', 'appSpecialDengerLevel',
'appSpecialDisableLevel', 'appSpecialDisableType', 'appSpecialHealth', 'appSpecialMarriage', 'appSpecialTypeFive','isReflection','yesOrNo').then(() => {
@@ -85,13 +86,14 @@
})
}
},
computed:{
idNumberInfo:v=>new ID(v.info.idNumber)
},
methods: {
getInfo (id) {
this.instance.post(`/app/appspecialmental/queryDetailById?id=${id}`).then(res => {
if (res.code === 0) {
this.info = res.data
this.idNumberInfo = this.idCardNoUtil.getIdCardInfo(res.data.idNumber)
}
})
},