コード例 #1
0
ファイル: Sms.cs プロジェクト: LavoTP/Arad.SMS.Gateway
        public static DataTable GetUncertainDeleviryStatusSmsTable(Business.SmsSenderAgentReference smsSenderAgentRefrence)
        {
            Business.Sms smsController = new Business.Sms();
            List <long>  smsesInfoList = new List <long>();

            return(smsController.GetUncertainDeleviryStatusSms(smsSenderAgentRefrence));
        }
コード例 #2
0
ファイル: Sms.cs プロジェクト: LavoTP/Arad.SMS.Gateway
        public static void GiveBackCreditToUser(Guid userGuid, SmsSendType smsSendType, Business.Operators operators,
                                                int smsPartCount, int encoding,
                                                int smsCount, Business.SmsSenderAgentReference agent, Guid smsSentGuid)
        {
            Business.Sms smsController = new Business.Sms();

            Business.SmsTypes smsType = encoding == (int)Business.Encoding.Utf8 ? Business.SmsTypes.Farsi : Business.SmsTypes.Latin;

            smsController.BeginTransaction();
            try
            {
                Transaction.IncreaseCostOfFaildSend(userGuid, smsSendType, operators, smsPartCount, smsType, smsCount, agent, smsSentGuid, smsController.DataAccessProvider);

                if (!smsController.UpdateBlackListSms(userGuid, smsSentGuid, agent, operators, smsPartCount, smsSendType, encoding))
                {
                    throw new Exception("ErrorRecord");
                }
                smsController.CommitTransaction();
            }
            catch (InnerTransactionException ex)
            {
                throw ex;
            }
            catch (Exception ex)
            {
                smsController.RollbackTransaction();
                throw ex;
            }
        }
コード例 #3
0
ファイル: Sms.cs プロジェクト: LavoTP/Arad.SMS.Gateway
        public static List <long> GetUncertainDeleviryStatusSms(Business.SmsSenderAgentReference smsSenderAgentRefrence)
        {
            Business.Sms smsController = new Business.Sms();
            List <long>  smsesInfoList = new List <long>();
            DataTable    dtSmses       = smsController.GetUncertainDeleviryStatusSms(smsSenderAgentRefrence);

            foreach (DataRow item in dtSmses.Rows)
            {
                smsesInfoList.Add(Helper.GetLong(item["OuterSystemSmsID"]));
                smsesInfoList.Add(Helper.GetLong(item["DeliveryStatus"]));
            }
            return(smsesInfoList);
        }