Skip to content

Commit

Permalink
chore: update configuration and dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
Guhapriya01 committed Sep 12, 2024
1 parent 0111589 commit 57db940
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 9 deletions.
8 changes: 1 addition & 7 deletions JtProject/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -52,16 +52,10 @@
</dependency>


<!--<dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.33</version>
</dependency>-->

<dependency>
<groupId>com.mysql</groupId>
<artifactId>mysql-connector-j</artifactId>
<version>8.3.0</version>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public ModelAndView indexPage()
{
ModelAndView mView = new ModelAndView("index");
String username = SecurityContextHolder.getContext().getAuthentication().getName();
mView.addObject("user", username);
mView.addObject("username", username);
List<Product> products = this.productService.getProducts();

if (products.isEmpty()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ public boolean userExists(String username) {

@Transactional
public User getUserByUsername(String username) {
Query<User> query = sessionFactory.getCurrentSession().createQuery("from CUSTOMER where username = :username");
Query<User> query = sessionFactory.getCurrentSession().createQuery("from User where username = :username", User.class);
query.setParameter("username", username);

try {
Expand Down

0 comments on commit 57db940

Please sign in to comment.