Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
th-app-java
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
Amparo Oliver
th-app-java
Commits
a0576b60
Commit
a0576b60
authored
Oct 19, 2023
by
Amparo Oliver
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Ruta Imagen
parent
fb0a519a
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
2 additions
and
2 deletions
+2
-2
curriculumsearch/curriculumsearch-0.0.1-SNAPSHOT.jar
+0
-0
curriculumsearch/src/main/java/com/roshka/ResourceConfig.java
+1
-1
curriculumsearch/src/main/java/com/roshka/controller/BirthdayController.java
+1
-1
curriculumsearch/uploadsBirthday/953eb5b45c1790b4ea9fa236e8fb0892.jpg
+0
-0
No files found.
curriculumsearch/curriculumsearch-0.0.1-SNAPSHOT.jar
View file @
a0576b60
No preview for this file type
curriculumsearch/src/main/java/com/roshka/ResourceConfig.java
View file @
a0576b60
...
...
@@ -8,6 +8,6 @@ import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter
public
class
ResourceConfig
extends
WebMvcConfigurerAdapter
{
@Override
public
void
addResourceHandlers
(
ResourceHandlerRegistry
registry
)
{
registry
.
addResourceHandler
(
"/
images/**"
).
addResourceLocations
(
"file:images
/"
);
registry
.
addResourceHandler
(
"/
uploadsBirthday/**"
).
addResourceLocations
(
"file:./uploadsBirthday
/"
);
}
}
curriculumsearch/src/main/java/com/roshka/controller/BirthdayController.java
View file @
a0576b60
...
...
@@ -96,7 +96,7 @@ public class BirthdayController {
Path
rutaCompleta
=
Paths
.
get
(
rutaAbsoluta
);
Files
.
write
(
rutaCompleta
,
bytesImg
);
// Si todo sale bien, guarda la foto en la base de datos
birthday
.
setFoto
(
"
http://192.168.16.90:8888/
uploadsBirthday/"
+
DigestUtils
.
md5Hex
(
originalFilename
)
+
"."
+
fileExtension
);
birthday
.
setFoto
(
"uploadsBirthday/"
+
DigestUtils
.
md5Hex
(
originalFilename
)
+
"."
+
fileExtension
);
}
catch
(
IOException
e
)
{
throw
new
RuntimeException
(
e
);
}
...
...
curriculumsearch/uploadsBirthday/953eb5b45c1790b4ea9fa236e8fb0892.jpg
0 → 100644
View file @
a0576b60
This diff is collapsed.
Click to expand it.
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