Skip to content

Commit

Permalink
Merge pull request #114 from UdL-EPS-SoftArch/Fix-Default-Pets
Browse files Browse the repository at this point in the history
Default pet added
  • Loading branch information
rogargon authored Jun 29, 2024
2 parents 4883ae7 + 6de4c6f commit 0e87d60
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,18 @@ public void initializeDatabase() {
pet.setImg("https://www.aon.es/personales/seguro-perro-gato/wp-content/uploads/sites/2/2021/06/pastor-aleman-3.jpg");
petRepository.save(pet);
}
if (!petRepository.existsById(3L)) {
Pet pet = new Pet();
pet.setName("Fifi");
pet.setColor("White");
pet.setSize("Small");
pet.setWeight(12D);
pet.setAge("3 years old");
pet.setDescription("Likes to relax and cuddle");
pet.setBreed("Croatishe pupi");
pet.setImg("https://hips.hearstapps.com/hmg-prod/images/bichon-frise-1660897169.jpg?crop=0.6666666666666666xw:1xh;center,top&resize=980:*");
petRepository.save(pet);
}
//One of them favourited to test functionality
if(!favouritedPetsRepository.existsById(1L)){
FavouritedPets favPets = new FavouritedPets();
Expand Down

0 comments on commit 0e87d60

Please sign in to comment.