Beispiel #1
0
        public static QueuedEmailCollection Search(SearchFilter SearchKey)
        {
            QueuedEmailCollection collection = new QueuedEmailCollection();

            using (var reader = SqlHelper.ExecuteReader("QueuedEmail_Search", SearchFilterManager.SqlSearchParam(SearchKey)))
            {
                while (reader.Read())
                {
                    QueuedEmail obj = new QueuedEmail();
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }
Beispiel #2
0
        public static QueuedEmailCollection ReminderContractEmailList(int CompanyID)
        {
            QueuedEmailCollection collection = new QueuedEmailCollection();

            //var sqlParams = new SqlParameter[1];
            //sqlParams[0] = new SqlParameter("@isActive", isActive);
            using (var reader = SqlHelper.ExecuteLongReaderService(ModuleConfig.MyConnection, 600, "USP_CMS_JOB_Reminder_Fetch_V1", null))
            {
                QueuedEmail obj = new QueuedEmail();
                while (reader.Read())
                {
                    obj = GetQueMessageFromReader(reader, CompanyID);
                    collection.Add(obj);
                }
            }
            return(collection);
        }
Beispiel #3
0
        public static QueuedEmailCollection GetbyUser(string CreatedUser, int CompanyID)
        {
            QueuedEmailCollection collection = new QueuedEmailCollection();
            QueuedEmail           obj;
            var sqlParams = new SqlParameter[]
            {
                new SqlParameter("@CreatedUser", CreatedUser),
                new SqlParameter("@CompanyID", CompanyID),
            };

            using (var reader = SqlHelper.ExecuteReader("QueuedEmail_GetAll_byUser", sqlParams))
            {
                while (reader.Read())
                {
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }
Beispiel #4
0
        public static QueuedEmailCollection GetAllItem(int CompanyID)
        {
            QueuedEmailCollection collection = new QueuedEmailCollection();

            var sqlParams = new SqlParameter[]
            {
                new SqlParameter("@CompanyID", CompanyID),
            };

            using (var reader = SqlHelper.ExecuteReader("QueuedEmail_GetAll", sqlParams))
            {
                while (reader.Read())
                {
                    QueuedEmail obj = new QueuedEmail();
                    obj = GetItemFromReader(reader);
                    collection.Add(obj);
                }
            }
            return(collection);
        }