Conditional UI manipulation

I am recording user responses from users in a database. I am trying to achieve a logic that will assign an object to a user if they reach a certain number of correct responses in a specific category and activate a pop-up in UI for the user that has just achieved it.

I am unsure about what I should use to achieve that. Would that be event handlers after record creation in the table, or must I create that logic in UI?
If it should be an event handler, how do I manipulate UI through handlers? Is that even possible?

Hi @Miroslav_Sedlacek ,

Both ways can work. All depends on your architecture and set of optimizations which you are willing to perform.

For example, if you implement it via event handler, such implementation will produce additional API call (I assume that it will use count to check amount of records). At the same time, if responses are collected in batches then you can use local counter on the UI side and increase counter (db record or atomic counter) on the server side only when batch submitted. Second approach can produce less API calls.

Regards, Andriy