コード例 #1
0
        private void Listen(object sender, DbNotificationArgs e)
        {
            var notificationReceived = this.NotificationReceived;

            if (notificationReceived != null)
            {
                if (e.Notice == null && !string.IsNullOrWhiteSpace(e.Message))
                {
                    MixERPPGEventArgs args = new MixERPPGEventArgs(e.Message, "error", 0);
                    notificationReceived(this, args);
                    return;
                }

                if (e.Notice != null && e.Notice.Severity.ToUpperInvariant().Equals("INFO"))
                {
                    MixERPPGEventArgs args = new MixERPPGEventArgs(e.Notice.Message, e.Notice.Detail, 0);

                    notificationReceived(this, args);
                }
            }
        }
コード例 #2
0
ファイル: DayOperationHub.cs プロジェクト: roczj/mixerp
 private void EOD_NotificationReceived(object sender, MixERPPGEventArgs e)
 {
     this.Clients.Caller.getNotification(e.AdditionalInformation, e.Condition);
 }