diff --git a/src/views/components/resiSearch.vue b/src/views/components/resiSearch.vue index 0333e38f7..80c340365 100644 --- a/src/views/components/resiSearch.vue +++ b/src/views/components/resiSearch.vue @@ -56,11 +56,11 @@ - - @@ -858,8 +858,6 @@ export default { // }, handleAgeChange() { - console.log(11 > 5); - console.log(11 > 10); if (this.form.ageStart) { if (this.form.ageStart > this.form.ageEnd) { this.$message.warning('结束年龄不能小于开始年龄') diff --git a/src/views/modules/portrayal/jumin/cpts/staffTag.vue b/src/views/modules/portrayal/jumin/cpts/staffTag.vue index 74fc9c442..a538c9f3e 100644 --- a/src/views/modules/portrayal/jumin/cpts/staffTag.vue +++ b/src/views/modules/portrayal/jumin/cpts/staffTag.vue @@ -202,7 +202,7 @@ export default { if (val === 1) { this.$emit('showDialog', { value: val }, val === 1) this.formData.tableData[0].value= 1 - }else{ + }else if(this.formType != 'add'){ this.$confirm(`确认取消党员标签`, '确认信息', { confirmButtonText: '确认取消', cancelButtonText: '暂不取消', diff --git a/src/views/modules/portrayal/jumin/index.vue b/src/views/modules/portrayal/jumin/index.vue index e2475a368..d62488fa8 100644 --- a/src/views/modules/portrayal/jumin/index.vue +++ b/src/views/modules/portrayal/jumin/index.vue @@ -4,7 +4,7 @@
- {{ resiDetailObj.baseInfoDto.name }}({{ age }}岁) --
@@ -669,7 +669,6 @@ export default { active: 0, menuList: [], score: null, - age: null, nationalityList: [], //国籍字典 marriageArr: [], //婚姻状况字典 @@ -1129,26 +1128,6 @@ export default { console.log(error); } }, - // 计算年龄 - calculateAge(birthdayTimestamp) { - // 获取当前日期 - const currentDate = new Date(); - // 将生日时间戳转换为日期对象 - const birthdayDate = new Date(birthdayTimestamp); - // 计算年龄 - let age = currentDate.getFullYear() - birthdayDate.getFullYear(); - // 检查是否已经过了生日 - const currentMonth = currentDate.getMonth(); - const birthMonth = birthdayDate.getMonth(); - if ( - currentMonth < birthMonth || - (currentMonth === birthMonth && - currentDate.getDate() < birthdayDate.getDate()) - ) { - age--; - } - return age; - }, async getNationalityList() { try { const { data } = await this.$http.post("sys/dict/data/dictlist", { @@ -1244,10 +1223,6 @@ export default { ); this.score = res.data.data.integrityData.score; - const birthdayTimestamp = Date.parse( - res.data.data.baseInfoDto.birthday - ); - this.age = this.calculateAge(birthdayTimestamp); } else if (res.data.code >= 8000) { this.resiDetailObj = {}; this.$message.error(res.data.msg);