Call HTML to Client Script

HTML Code:
<button ng-click="c.useraction(key.sys_id,'open')">Open Record</button><button ng-click="c.useraction(key.sys_id,'close')">Close Incident</button>
Client Script:
c.useraction = function(id,action){ if(action == 'open'){ var url="?id=form&table=incident&sys_id="+id; window.open(url,'_blank'); }else{ alert('Alert'); } }
No responses yet