Edit client classes

This commit is contained in:
cugurlu
2019-03-16 14:14:17 +01:00
parent 31499adc00
commit 20735380e5
2 changed files with 0 additions and 63 deletions

View File

@@ -21,11 +21,6 @@ public class Application extends javafx.application.Application {
launch(args);
}
// @Bean
// public RestTemplate restTemplate(RestTemplateBuilder builder) {
// return builder.build();
// }
@Override
public void init() throws Exception {
springContext = SpringApplication.run(Application.class);
@@ -36,25 +31,9 @@ public class Application extends javafx.application.Application {
@Override
public void start(Stage primaryStage) throws Exception {
fxmlLoader.setLocation(this.getClass().getClassLoader().getResource("fxml/sample.fxml"));
// fxmlLoader.setLocation(
// this.getClass().getClassLoader().getResource("fxml/dashboard.fxml")
// );
rootNode = fxmlLoader.load();
// rootNode = FXMLLoader.load(
// this.getClass().getClassLoader().getResource("fxml/sample.fxml")
// );
primaryStage.setTitle("GoGreen");
Scene scene = new Scene(rootNode);
// scene.getStylesheets().add(
// getClass().getResource("stylesheets/dashboardStyle.css").toExternalForm()
// );
primaryStage.setScene(scene);
primaryStage.show();
}
@@ -63,14 +42,4 @@ public class Application extends javafx.application.Application {
public void stop() {
springContext.stop();
}
// @Bean
// public CommandLineRunner run(RestTemplate restTemplate) throws Exception {
// return args -> {
// User user = restTemplate.getForObject(
// "http://localhost:8080/user", User.class);
// log.info(user.toString());
//
// };
// }
}

View File

@@ -34,21 +34,6 @@ public class UserController {
@FXML
private Button signupButton;
// @Value("${my.url}")
// private String myUrl;
// @FXML
// private void initialize(ActionEvent event) throws IOException {
// Parent parent = FXMLLoader.load(getClass().getResource("sample.fxml"));
// Scene scene = new Scene(parent);
// Stage app_stage = (Stage)((Node) event.getSource()).getScene().getWindow();
// app_stage.setScene(scene);
// app_stage.show();
// }
@FXML
protected void handleLoginButtonAction(ActionEvent event) throws IOException {
Window owner = loginButton.getScene().getWindow();
@@ -70,17 +55,6 @@ public class UserController {
}
userService.registerUser(usernameField.getText(), passwordField.getText());
// load the dashboard stage
// Parent parent = FXMLLoader.load(
// this.getClass().getClassLoader().getResource("/fxml/dashboard.fxml")
// );
//
// Scene scene = new Scene(parent);
// Stage app_stage = (Stage) ((Node) event.getSource()).getScene().getWindow();
// app_stage.setScene(scene);
// app_stage.setFullScreen(true);
// app_stage.show();
openDashboard();
}
@@ -101,12 +75,6 @@ public class UserController {
appStage.show();
}
// public final String getUsernameText() {
//
// return user.getName();
// }
public static class AlertHelper {
/**
* alerts for the login screen.