In the client scripting object model, we utilize client-side programming to write code that runs on browsers. We can embed our client-side code in different places in Microsoft Dynamics CRM 2015. We can write client-side code to interact with entity forms and their controls. To work with client scripting object models, there are events exposed for forms and controls that we will be discussing in later topics.
Using client scripting object model, we can customize the behavior of command buttons; for example, let's say that we want to enable a command button for specific security role users or we may want to show a button when a specific value is entered in a text box. These types of requirement can be implemented by writing custom JavaScript actions for command buttons with enable and display rules.
Note
We can refer to https://msdn.microsoft.com/en-us/library/gg309639.aspx to get details about enabling and displaying rules.