package com.zhangmeng.online.exam.ui.api.form;

import com.zhangmeng.online.exam.ui.api.form.base.Form;
import com.zhangmeng.online.exam.ui.controller.UserEditController;
import javafx.fxml.FXMLLoader;

import java.io.IOException;

/**
 * @author zm
 * @date 2025/3/14 17:40
 * @version: 1.0
 */
public class UserForm extends Form {

    private UserEditController controller;



    public UserForm() {
        try {
            FXMLLoader fxmlLoader = new FXMLLoader(getClass().getResource("/fxml/user-edit.fxml"));
            this.getChildren().add(fxmlLoader.load());
            this.controller = fxmlLoader.getController();
        } catch (IOException e) {
            throw new RuntimeException(e);
        }
    }

    public UserEditController getController() {
        return controller;
    }

    public void setController(UserEditController controller) {
        this.controller = controller;
    }
}
