0
Good afternoon! I would like to know how I can update an object in my view without having to reload the page. For example, on the main page of the system, I have 3 panels that shows the amount of calls by status: Solved, Pending and Unresolved. I also have a table that lists up to 10 Pending attendances. How can I refresh this without reloading the page? Like Facebook notifications. I am developing this system using Java, Bootstrap, Thymeleaf and Spring Boot
Utilize setInterval and Ajax.
– Oralista de Sistemas
I think the most current solution for this is using
WebSocket
, take a look at the librarysocket.io
– Antonio
I’ll look into it, thank you @Renan !
– Cisino Junior
@Antonio I’ll take a look at this lib too, you would have some example of use?
– Cisino Junior
@Cisinojunior on the website of
socket.io
have an example building a chat https://socket.io/get-started/chat/ , as you are already usingSpring Boot
, has an example on their own website of Websocket, you can take a look https://spring.io/guides/gs/messaging-stomp-websocket/ , works basically the same, maybe changes a bit of thesocket.io
, but the principle is the same– Antonio
@Antonio valeuuuu! I will start studying this now to be able to implement in my system. Thank you!!!
– Cisino Junior