Skip to content
Snippets Groups Projects
Commit 550e9a05 authored by Szeghy Géza László's avatar Szeghy Géza László
Browse files

deleted redundant print statements

parent 49be3749
Branches demo
No related tags found
No related merge requests found
...@@ -20,7 +20,6 @@ public class Controller { ...@@ -20,7 +20,6 @@ public class Controller {
@PostMapping("/api/login") @PostMapping("/api/login")
public UserLoginDto login(@RequestBody UserLoginDto userLoginDto) { public UserLoginDto login(@RequestBody UserLoginDto userLoginDto) {
System.out.println(userLoginDto);
return noteStoreService.authenticate(userLoginDto.getUsername(), userLoginDto.getPassword()); return noteStoreService.authenticate(userLoginDto.getUsername(), userLoginDto.getPassword());
} }
......
...@@ -38,8 +38,6 @@ public class Document { ...@@ -38,8 +38,6 @@ public class Document {
@Column(name = "filepath", nullable = false) @Column(name = "filepath", nullable = false)
private String filepath; private String filepath;
// Getters and setters
public Long getId() { public Long getId() {
return id; return id;
} }
......
...@@ -15,8 +15,6 @@ public class Subject { ...@@ -15,8 +15,6 @@ public class Subject {
@Column(name = "name", nullable = false) @Column(name = "name", nullable = false)
private String name; private String name;
// Getters and setters
public String getSubjectId() { public String getSubjectId() {
return subjectId; return subjectId;
} }
......
...@@ -21,8 +21,6 @@ public class User { ...@@ -21,8 +21,6 @@ public class User {
@Column(name = "loggedIn") @Column(name = "loggedIn")
private boolean loggedIn; private boolean loggedIn;
// Getters and setters
public String getUsername() { public String getUsername() {
return username; return username;
} }
......
...@@ -47,10 +47,10 @@ function registerUser(credentials, callback) { ...@@ -47,10 +47,10 @@ function registerUser(credentials, callback) {
// prepopulating the database // prepopulating the database
registerUser({fullName: 'Gipsz Jakab', username: 'gipja', password: 'süti'}, function (res) { registerUser({fullName: 'Gipsz Jakab', username: 'gipja', password: 'süti'}, function (res) {
console.log(res) //console.log(res)
}).then(() => { }).then(() => {
registerUser({fullName: 'Kada Zsolt', username: 'kazso', password: 'keksz'}, function (res) { registerUser({fullName: 'Kada Zsolt', username: 'kazso', password: 'keksz'}, function (res) {
console.log(res) //console.log(res)
}) })
}).then(() => { }).then(() => {
return axios.post('http://localhost:8080/api/addsubject', {subjectId: "szofttech", name: "Szoftver Technológia"}) return axios.post('http://localhost:8080/api/addsubject', {subjectId: "szofttech", name: "Szoftver Technológia"})
......
...@@ -11,7 +11,6 @@ let fileName = ref("") ...@@ -11,7 +11,6 @@ let fileName = ref("")
function getDocumentDetails(id) { function getDocumentDetails(id) {
axios.post('http://localhost:8080/api/details', {id: id, subject: "szofttech"}) axios.post('http://localhost:8080/api/details', {id: id, subject: "szofttech"})
.then(response => { .then(response => {
console.log(response.data)
title.value = response.data["title"] title.value = response.data["title"]
userName.value = response.data["user"] userName.value = response.data["user"]
description.value = response.data["description"] description.value = response.data["description"]
...@@ -134,5 +133,4 @@ li { ...@@ -134,5 +133,4 @@ li {
margin-bottom: -2px; margin-bottom: -2px;
} }
</style> </style>
\ No newline at end of file
...@@ -31,9 +31,8 @@ function logoutUser(credentials, callback) { ...@@ -31,9 +31,8 @@ function logoutUser(credentials, callback) {
} }
function logout(user, pass){ function logout(user, pass){
//Itt lesz a kitalált user (Gipsz Jakab, keksz) aki megpróbál bejelentkezni
logoutUser({username: user, password: pass}, function(response) { logoutUser({username: user, password: pass}, function(response) {
console.log(response) //console.log(response)
}) })
} }
</script> </script>
......
...@@ -11,9 +11,8 @@ const emit = defineEmits(['login']); ...@@ -11,9 +11,8 @@ const emit = defineEmits(['login']);
async function loginUser() { async function loginUser() {
try { try {
const response = await axios.post('http://localhost:8080/api/login', credentials.value); const response = await axios.post('http://localhost:8080/api/login', credentials.value);
console.log(response.data);
if (!response.data["loggedIn"]) { if (!response.data["loggedIn"]) {
emit('login', false, ""); // Emit login event with failure value emit('login', false, "");
isFailed.value = true; isFailed.value = true;
logged_in.value = false; logged_in.value = false;
} else { } else {
...@@ -23,7 +22,7 @@ async function loginUser() { ...@@ -23,7 +22,7 @@ async function loginUser() {
} }
} catch (error) { } catch (error) {
console.log(error); console.log(error);
emit('login', false, ""); // Emit login event with failure value emit('login', false, "");
isFailed.value = true; isFailed.value = true;
logged_in.value = false; logged_in.value = false;
} }
......
...@@ -14,7 +14,7 @@ function registerUser(credentials, callback) { ...@@ -14,7 +14,7 @@ function registerUser(credentials, callback) {
function register(){ function register(){
registerUser({fullName: 'Joe', username: 'joe', password: 'Mama'}, function (res) { registerUser({fullName: 'Joe', username: 'joe', password: 'Mama'}, function (res) {
console.log(res) //console.log(res)
}) })
} }
</script> </script>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment