Esempio n. 1
0
        public PartialViewResult getChatnewById(int UserId, int maxid, int aid)
        {
            chatServices _chat  = new Database.chatServices();
            chatModel    _model = new Models.chatModel();

            _model = _chat.getChatByContactId(UserId, aid, maxid);
            return(PartialView("GetNewChat", _model));
        }
Esempio n. 2
0
        public PartialViewResult getChatById(int UserId, int aid)
        {
            chatServices _chat  = new Database.chatServices();
            chatModel    _model = new Models.chatModel();

            _model     = _chat.getChatByContactId(UserId, aid);
            _model.aId = aid;
            return(PartialView("getChatById", _model));
        }
Esempio n. 3
0
        public PartialViewResult getChatBymsgId(int msgId)
        {
            int          adminId = Convert.ToInt16(Session["AdminId"]);
            chatServices _chat   = new Database.chatServices();
            chatModel    _model  = new Models.chatModel();

            _model = _chat.getChatBychatId(msgId, adminId);
            return(PartialView("getChatById", _model));
        }
Esempio n. 4
0
        public ActionResult Index()
        {
            int          adminId = Convert.ToInt16(Session["AdminId"]);
            chatServices _chat   = new Database.chatServices();
            chatModel    _model  = new Models.chatModel();

            _model = _chat.getContactsByAdminid(adminId);
            if (Session["name"] == null)
            {
                userServices _ser     = new userServices();
                var          _profile = _ser.getProfileByUserId(adminId);
                Session["name"]  = _profile.name;
                Session["image"] = !string.IsNullOrEmpty(_profile.image) ? _profile.image : "/assets/images/icon/staff.png";
            }
            _model.name     = Session["name"].ToString();
            _model.imageurl = Session["image"].ToString();
            _model.aId      = adminId;
            return(View(_model));
        }