Hi, i'm sending two parameters using GET (through URL) and woul like my request method to receive them like this ...
@RequestMapping("/basketItems")
public String basketItems(
@RequestParam("fname") String firstName,
@RequestParam("lname") String lastName,
Model model) {
Customer customer = customerManager.getCustomer(firstName, lastName);
Basket basket = basketManager.getBasket(customer.getReferenceNumber());
model.addAttribute("basket", basket);
model.addAttribute("totalItems", basketManager.getTotalNumberOfItems(basket));
model.addAttribute("totalPrice", basketManager.getTotalProductPrice(basket));
return "basketItems";
}
I get an error that org.springframework.web.bind.MissingServletRequestParameterException: Required java.lang.String parameter 'lname' is not present