From 81e529d1f3a8034b9d0e41cb46dfefb157f5d456 Mon Sep 17 00:00:00 2001 From: lion <120344285@qq.com> Date: Thu, 17 Apr 2025 09:19:53 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package_sub/pages/StudentInfo/StudentInfo.vue | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/package_sub/pages/StudentInfo/StudentInfo.vue b/package_sub/pages/StudentInfo/StudentInfo.vue index 4bdf3bd..319991d 100644 --- a/package_sub/pages/StudentInfo/StudentInfo.vue +++ b/package_sub/pages/StudentInfo/StudentInfo.vue @@ -220,12 +220,12 @@ export default { message: '请选择中考年份' } ], - city: [ - { - required: true, - message: '请选择城市' - } - ], + // city: [ + // { + // required: true, + // message: '请选择城市' + // } + // ], area: [ { required: true, @@ -248,6 +248,9 @@ export default { for (let key in this.form) { if (user.hasOwnProperty(key) && key !== 'user_scores') { this.form[key] = user[key] + if(key==='city'){ + this.form[key] = user[key]?user[key]:'苏州市' + } } else if (key === 'user_scores') { this.form['user_scores'].forEach(item => { if (user['user_scores'].find(j => j.name === item.name)) { @@ -257,6 +260,7 @@ export default { }) } } + } catch (err) { console.error(err) } @@ -357,7 +361,7 @@ export default { } }, onReady() { - this.getArea() + this.getArea() this.$refs.uForm.setRules(this.rules) this.getInfo() }