public static ManageStaffController launchInManage() throws IOException { ManageStaffController controller = ManageStaffController.launch(); controller.selfPane.getChildren().remove(controller.back_Btn); controller.back_Btn.setVisible(false); controller.manageblStaffService = StaffFactory.getManageService(); controller.manageblHallService = InstitutionFactory.getManageblHallService(); controller.manageblCenterService = InstitutionFactory.getManageblCenterService(); return controller; }
private static ManageStaffController launch() throws IOException { FXMLLoader fxmlLoader = new FXMLLoader(); fxmlLoader.setLocation(ManageStaffController.class.getResource("manageStaff.fxml")); Pane selfPane = fxmlLoader.load(); ManageStaffController controller = fxmlLoader.getController(); controller.informController = InformController.newInformController(selfPane); controller.selfPane = controller.informController.stackPane; return controller; }
public static ManageStaffController launchInInit(Pane father, Pane before) throws IOException { ManageStaffController controller = ManageStaffController.launch(); controller.back_Btn.setOnAction( actionEvent -> { father.getChildren().clear(); father.getChildren().add(before); }); controller.manageblCenterService = InitBLFactory.getInitializationBLService(); controller.manageblStaffService = InitBLFactory.getInitializationBLService(); controller.manageblHallService = InitBLFactory.getInitializationBLService(); return controller; }