Esempio n. 1
0
        public ActionResult ChannelList()
        {
            if (Session["username"] == null)
            {
                BO_Employee obj = new BO_Employee();

                return(RedirectToAction("Index", "Home"));
            }


            List <BO_Message_Recipients_Status> li = new List <BO_Message_Recipients_Status>();

            try
            {
                BO_Message_Recipients_Status MSR_Result = new BO_Message_Recipients_Status();
                MSR_Result = DA_Login.DA_MessageRecipientStatus();

                if (MSR_Result.msg != null)
                {
                    ViewBag.Exception = MSR_Result.msg;
                }
                //  MSR_Result = DB.Channellist();
                li.Add(MSR_Result);
            }
            catch (Exception e)
            {
                ViewBag.Exception = e;
            }
            return(View("ChannelList", "_Layout", li));
        }
Esempio n. 2
0
        public static BO_Message_Recipients_Status DA_MessageRecipientStatus()
        {
            BO_Message_Recipients_Status MSR = new BO_Message_Recipients_Status();
            DataTable dt = new DataTable();

            string[] param       = new string[] { "@Flag", "@EntryBy" };
            string[] paramvalues = new string[] { "GetChennelList", "ravi" };
            dt = SQL_Helper.Select("LongHaul..usp_WhatAppCustomerData", param, paramvalues, "MySqlConnection");
            if (dt.Rows.Count > 0)
            {
                MSR = new BO_Message_Recipients_Status()
                {
                    ChennelID     = Convert.ToString(dt.Rows[0]["ChennelID"]),
                    ChennelName   = Convert.ToString(dt.Rows[0]["ChennelName"]),
                    ReadIncomming = Convert.ToString(dt.Rows[0]["ReadIncomming"]),
                };
            }
            //else
            //{
            //    MSR.msg = "Exception Error";
            //}
            return(MSR);
        }