Code:
// this is my custom ajax event
procedure TdashboardForm.alertChecker(EventParams: TStringList);
var par:Variant;
today:TDate;
begin
par:=VarArrayOf([
EventParams.Values['noticeID'],
UserSession.UserID,
UserSession.UserName
]);
with UserSession do
begin
//p_reg_sel_NewNotice '201805170000001','9/21/2018'
//p_reg_upd_NoticeRead 201809210000005,201805170000001,'munkhdelger'
if AdoTool.RunProcedure('p_reg_upd_NoticeRead',par) = fmResult then
begin
today:=now;
par := VarArrayOf([
UserSession.UserID,
DateToStr(today)
]);
AdoTool.RunProcedure('p_reg_sel_NewNotice',par);
AlertHolder.Text := ExportDataSetToJson(AdoTool.DataResult,0);
//How to call my callme(); in js from here tjhi
WebApplication.ShowNotification('Амжилттай');
end
else
begin
WebApplication.ShowNotification('Амжилтгүй');
end;
end;