public static DataRow GetCRCManager()
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCManager_Get"));
     }
 }
Пример #2
0
 public static DataRow GetStationDetail(long stationId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_StationDetail_Get",
                    new SqlParameter("@StationId", stationId)));
     }
 }
 public static DataRow GetCRCUserByResetPasswordToken(string token)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCUserByResetPasswordToken_Get",
                    new SqlParameter("@Token", token)));
     }
 }
 public static DataRow GetScheduleNewscast(long scheduleNewscastId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_ScheduleNewscast_Get",
                    new SqlParameter("@ScheduleNewscastId", scheduleNewscastId)));
     }
 }
Пример #5
0
 public static DataRow GetAffiliate(long affiliateId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_Affiliate_Get",
                    new SqlParameter("@AffiliateId", affiliateId)));
     }
 }
 public static DataRow GetCRCUser(long userId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCUser_Get",
                    new SqlParameter("@UserId", userId)));
     }
 }
 public static DataRow GetProgramFormatType(long programFormatTypeId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_ProgramFormatType_Get",
                    new SqlParameter("@ProgramFormatTypeId", programFormatTypeId)));
     }
 }
Пример #8
0
 public static DataRow GetBand(long bandId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_Band_Get",
                    new SqlParameter("@BandId", bandId)));
     }
 }
Пример #9
0
 public static DataRow GetMinorityStatus(long minorityStatusId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_MinorityStatus_Get",
                    new SqlParameter("@MinorityStatusId", minorityStatusId)));
     }
 }
Пример #10
0
 public static DataRow GetDMAMarket(long dmaMarketId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_DMAMarket_Get",
                    new SqlParameter("@DMAMarketId", dmaMarketId)));
     }
 }
Пример #11
0
 public static DataRow GetCarriageType(long carriageTypeId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CarriageType_Get",
                    new SqlParameter("@CarriageTypeId", carriageTypeId)));
     }
 }
Пример #12
0
 /// <summary>
 /// Returns the email template record with the specified name.
 /// </summary>
 public static DataRow GetEmailTemplateByName(string templateName)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_InfEmailTemplateByName_Get",
                    new SqlParameter("@TemplateName", templateName)));
     }
 }
 public static DataRow GetCRCUserByEmail(string email)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCUserByEmail_Get",
                    new SqlParameter("@Email", email)));
     }
 }
Пример #14
0
 public static DataRow GetTimeZone(long timeZoneId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_TimeZone_Get",
                    new SqlParameter("@TimeZoneId", timeZoneId)));
     }
 }
Пример #15
0
 public static DataRow GetRepeaterStatus(long repeaterStatusId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_RepeaterStatus_Get",
                    new SqlParameter("@RepeaterStatusId", repeaterStatusId)));
     }
 }
 public static DataRow GetCRCUserByLogin(string email, string password)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCUserByLogin_Get",
                    new SqlParameter("@Email", email),
                    new SqlParameter("@Password", password)));
     }
 }
 public static DataRow SaveCRCUserPasswordReset(string email, long?lastUpdatedUserId)
 {
     using (var sqlHelper = new InfSqlHelper())
     {
         return(sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_CRCUserPasswordReset_Save",
                    new SqlParameter("@Email", email),
                    new SqlParameter("@LastUpdatedUserId", lastUpdatedUserId)));
     }
 }
Пример #18
0
        public static DataRow GetSchedule(long scheduleId, long userId)
        {
            using (var sqlHelper = new InfSqlHelper())
            {
                return(sqlHelper.ExecuteDataRowProcedure(

                           "dbo.PSP_Schedule_Get",
                           new SqlParameter("@UserId", userId),
                           new SqlParameter("@ScheduleId", scheduleId)));
            }
        }
        public static string GetTextContent(string parentName, string contentName)
        {
            using (var sqlHelper = new InfSqlHelper())
            {
                var dataRow = sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_InfTextContentByName_Get",
                    new SqlParameter("@ParentName", parentName),
                    new SqlParameter("@ContentName", contentName));

                if (dataRow == null)
                {
                    return(string.Format(CultureInfo.InvariantCulture, "WARNING: No content found for parent name = \"{0}\" and content name = \"{1}\".", parentName, contentName));
                }
                else
                {
                    return(dataRow["ContentText"].ToString());
                }
            }
        }
        public static InfDocument GetDocument(long infDocumentId)
        {
            using (var sqlHelper = new InfSqlHelper())
            {
                var dataRow = sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_InfDocument_Get",
                    new SqlParameter("@InfDocumentId", infDocumentId));

                if (dataRow != null)
                {
                    var document = new InfDocument();
                    dataRow.MapTo(document);
                    return(document);
                }
                else
                {
                    return(null);
                }
            }
        }
        public static InfDocument GetDocument(string parentName, string documentFileName)
        {
            using (var sqlHelper = new InfSqlHelper())
            {
                var dataRow = sqlHelper.ExecuteDataRowProcedure(
                    "dbo.PSP_InfDocumentByName_Get",
                    new SqlParameter("@ParentName", parentName),
                    new SqlParameter("@DocumentFileName", documentFileName));

                if (dataRow != null)
                {
                    var document = new InfDocument();
                    dataRow.MapTo(document);
                    return(document);
                }
                else
                {
                    return(null);
                }
            }
        }