| | |
| | | @IBOutlet weak var cons_bottom: NSLayoutConstraint! |
| | | @IBOutlet weak var btn_add: QMUIButton! |
| | | |
| | | private var clickClouse:(()->Void)! |
| | | private var clickClouse:(([CourseDetailStudentModel])->Void)! |
| | | private var needAddClouse:(()->Void)! |
| | | private var itemType:ItemType! |
| | | private var selectStudents = [CourseDetailStudentModel]() |
| | |
| | | |
| | | } |
| | | |
| | | static func show(itemType:ItemType,defaultStu:CourseDetailStudentModel? = nil,clickClouse:@escaping ()->Void,needAddClouse:@escaping ()->Void){ |
| | | static func show(itemType:ItemType,defaultStu:[CourseDetailStudentModel]? = nil,clickClouse:@escaping ([CourseDetailStudentModel])->Void,needAddClouse:@escaping ()->Void){ |
| | | let studentChooseView = StudentChooseView.jq_loadNibView() |
| | | if defaultStu != nil{ |
| | | studentChooseView.selectStudents.append(defaultStu!) |
| | | studentChooseView.selectStudents = defaultStu! |
| | | } |
| | | if itemType == .course{ |
| | | studentChooseView.tableView.register(UINib(nibName: "StudentInfoTCell", bundle: nil), forCellReuseIdentifier: "_StudentInfoTCell") |
| | |
| | | } |
| | | |
| | | @IBAction func completeAction(_ sender: UIButton) { |
| | | clickClouse!() |
| | | clickClouse!(selectStudents) |
| | | closeAction() |
| | | } |
| | | } |