Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
SkuciSe
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tim 2 - 2022
SkuciSe
Commits
ec6abfdd
Commit
ec6abfdd
authored
Sep 11, 2022
by
Nikola Markovic
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
KorisnikRepository - ubacene procedure
parent
0fcd2599
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
2 deletions
+0
-2
SkuciSe/src/main/java/com/example/SkuciSe/repository/KorisnikRepository.java
+0
-2
No files found.
SkuciSe/src/main/java/com/example/SkuciSe/repository/KorisnikRepository.java
View file @
ec6abfdd
...
@@ -27,7 +27,6 @@ public class KorisnikRepository
...
@@ -27,7 +27,6 @@ public class KorisnikRepository
try
{
try
{
String
slika
=
Base64
.
getEncoder
().
encodeToString
(
multipartFile
.
getBytes
());
String
slika
=
Base64
.
getEncoder
().
encodeToString
(
multipartFile
.
getBytes
());
String
sql
=
"{call insertKorisnik(?,?,?,?,?,?,?,?)}"
;
String
sql
=
"{call insertKorisnik(?,?,?,?,?,?,?,?)}"
;
//String sql = "insert into korisnik( ime, prezime, telefon, email, sifra, tipId, slika, gradid) values('"+korisnik.getIme()+"','"+korisnik.getPrezime()+"','"+korisnik.getTelefon()+"','"+korisnik.getEmail()+"','"+new BCryptPasswordEncoder().encode(korisnik.getSifra())+"',1, '"+ slika +"', "+korisnik.getGradId()+",false)";
stmt
=
dataBase
.
connection
.
prepareCall
(
sql
);
stmt
=
dataBase
.
connection
.
prepareCall
(
sql
);
stmt
.
setString
(
1
,
korisnik
.
getIme
());
stmt
.
setString
(
1
,
korisnik
.
getIme
());
stmt
.
setString
(
2
,
korisnik
.
getPrezime
());
stmt
.
setString
(
2
,
korisnik
.
getPrezime
());
...
@@ -92,7 +91,6 @@ public class KorisnikRepository
...
@@ -92,7 +91,6 @@ public class KorisnikRepository
public
Korisnik
findByEmail
(
String
email
)
public
Korisnik
findByEmail
(
String
email
)
{
{
//String sql = "select * from korisnik where email = '"+email+"'";
String
sql
=
"{call findByEmail(?)}"
;
String
sql
=
"{call findByEmail(?)}"
;
ResultSet
rs
=
null
;
ResultSet
rs
=
null
;
CallableStatement
stmt
=
null
;
CallableStatement
stmt
=
null
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment