| | |
| | | override func viewDidLoad() { |
| | | super.viewDidLoad() |
| | | if type == .course{ |
| | | title = "添加学员" |
| | | title = "添加运动营成员" |
| | | if studentInfo != nil{ |
| | | title = "编辑学员" |
| | | title = "编辑运动营成员" |
| | | tf_name.text = studentInfo!.stuName |
| | | tf_idCard.text = studentInfo!.idCard |
| | | tf_height.text = String(format: "%.0lf", studentInfo!.stuHeight) |
| | |
| | | |
| | | @IBAction func completeAction(_ sender: UIButton) { |
| | | if studentInfo == nil{ |
| | | guard profileImg != nil else {alertError(msg: "请上传学员头像");return} |
| | | guard profileImg != nil else {alertError(msg: "请上传运动营成员头像");return} |
| | | } |
| | | |
| | | guard !tf_name.text!.isEmpty else {alertError(msg: tf_name.placeholder!);return} |