I have an index page, when a user logs in, it shows all tables (button of tables) in the database.Table can have an order. So, it works like when a user clicks a table, it redirects to the create path of order and create an order. Or if a table has an order, it redirects to order show page. Each order has a table_id. And table shows whether it is busy now or not by showing different color.
What I want to do is that changing table button's color real time. So that if one user creates order, the other user can see it immediately as table changes color. How can I achieve this? I am researching gen server and channel but I still am not familiar with those concepts.. any suggestions for this?
Thanks in advance