From d587fb260c6118de4707c35a1e312af6a4cfd28c Mon Sep 17 00:00:00 2001
From: 无故事王国 <841720330@qq.com>
Date: 星期四, 12 十月 2023 18:25:36 +0800
Subject: [PATCH] fix BUG

---
 WanPai/Root/Course/VC/AddStudentVC.swift |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/WanPai/Root/Course/VC/AddStudentVC.swift b/WanPai/Root/Course/VC/AddStudentVC.swift
index 39ae03f..0ee53ed 100644
--- a/WanPai/Root/Course/VC/AddStudentVC.swift
+++ b/WanPai/Root/Course/VC/AddStudentVC.swift
@@ -89,6 +89,7 @@
 
         guard !tf_name.text!.isEmpty else {alertError(msg: tf_name.placeholder!);return}
         guard !tf_birthday.text!.isEmpty else {alertError(msg: "请选择生日");return}
+		guard !tf_gender.text!.isEmpty else {alertError(msg: "请选择性别");return}
         guard !tf_height.text!.isEmpty else {alertError(msg: tf_height.placeholder!);return}
         guard !tf_weight.text!.isEmpty else {alertError(msg: tf_weight.placeholder!);return}
         guard tf_height.text != "0" else {alertError(msg: "请输入正确的身高");return}
@@ -163,6 +164,7 @@
 extension AddStudentVC:UITextFieldDelegate{
     func textFieldShouldBeginEditing(_ textField: UITextField) -> Bool {
         if textField == tf_birthday{
+			view.endEditing(true)
             CommonDatePickerView.show(before: 18, after: 0, type: .YMD) { year, month, day,_,_ in
                 textField.text = String(format: "%ld-%02ld-%02ld", year!,month!,day!)
             }

--
Gitblit v1.7.1