protected void Page_Load(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null && string.IsNullOrEmpty(Request.Params["RefId"])) { Response.Redirect("~/CommonUI/login.aspx", false); } else if (!string.IsNullOrEmpty(Request.Params["RefId"])) { var pay = _walletBusiness.GetPaymentByRequestKey(Request.Params["RefId"]); if (pay != null) { Session[sessionNames.userID_StudentOstad] = pay.stcode; LoginBusiness lgnB = new LoginBusiness(); LoginDTO stInfo = lgnB.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; } else { Response.Redirect("~/CommonUI/login.aspx", false); } } else if (!IsPostBack) { LoginBusiness lgnB = new LoginBusiness(); LoginDTO stInfo = lgnB.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; } }
protected void Page_Load(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] != null) { DataTable dt = new DataTable(); dt = EmailBuss.GetEmailRequestStatus(Session[sessionNames.userID_StudentOstad].ToString()); if (dt.Rows.Count > 0 && dt.Rows[dt.Rows.Count - 1]["Status"].ToString() == "2") { newrequest.Visible = true; } if (dt.Rows.Count > 0 && dt.Rows[dt.Rows.Count - 1]["Status"].ToString() == "4") { gotoemail.Visible = true; ChangePass.Visible = true; //UserName.InnerText = dt.Rows[dt.Rows.Count - 1]["Email_Address"].ToString(); //Usernameli.Visible = true; } if (!IsPostBack) { LoginBusiness lgnB = new LoginBusiness(); StuImg st = lgnB.User_Img(Session[sessionNames.userID_StudentOstad].ToString()); PersonalImage.DataValue = st.img; LoginDTO stInfo = lgnB.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; //stName.InnerText = stInfo.LastName; } } else { Response.Redirect("~/CommonUI/login.aspx", false); } }
protected void Page_init(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null) { Response.Redirect("~/CommonUI/login.aspx", false); } if (!IsPostBack) { LoginBusiness lgnB = new LoginBusiness(); StuImg st = lgnB.User_Img(Session[sessionNames.userID_StudentOstad].ToString()); PersonalImage.DataValue = st.img; LoginDTO stInfo = lgnB.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; } if (Session[sessionNames.appID_StudentOstad].ToString() == "5") { a_card.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "4") { a_Edit.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "3") { a_eshteghal.Visible = true; a_Vaziat.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "12") { a_tasvieh.Visible = true; } }
protected void Page_Load(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null) { Response.Redirect("~/CommonUI/login.aspx"); } if (Session[sessionNames.userID_StudentOstad] != null) { Label1.Text = Session[sessionNames.userID_StudentOstad].ToString(); if (!IsPostBack) { LoginBusiness lgnB = new LoginBusiness(); StuImg st = lgnB.User_Img(Label1.Text); PersonalImg.DataValue = st.img; LoginDTO stInfo = lgnB.Get_StInfo(Label1.Text); stName.InnerText = stInfo.Name; stLastName.InnerText = stInfo.LastName; stField.InnerText = stInfo.StReshte; Reports rpt = new Reports(); List <ReportDownloadReqDTO> counter = new List <ReportDownloadReqDTO>(); int sum = 0; counter = rpt.Get_SelectedAsset_NotPay(Label1.Text); ShoppingCounter.InnerText = counter.Count.ToString(); grdShopping.DataSource = counter; grdShopping.DataBind(); DownloadRequestBusiness dnlB = new DownloadRequestBusiness(); List <AssetDTO> assetlst = new List <AssetDTO>(); assetlst = dnlB.GetValidAssets(Label1.Text); if (assetlst.Count > 0) { dnlNav.Visible = true; } if (grdShopping.MasterTableView.Items.Count > 0) { Paybtn.Visible = true; } foreach (GridDataItem item in grdShopping.MasterTableView.Items) { if (grdShopping.Columns[2].UniqueName == "SumPrice") { sum += int.Parse(item["SumPrice"].Text.Replace(",", "")); } } Session["Fee"] = sum.ToString(); } Session[sessionNames.userID_StudentOstad] = Label1.Text; } else { Response.Redirect("~/CommonUI/login.aspx", false); } }
protected void btnTesti6_Click(object sender, EventArgs e) { LoginBusiness lgb = new LoginBusiness(); var userAdobe = Session[sessionNames.userID_StudentOstad].ToString(); LoginDTO stInfo = lgb.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); string firtsName = stInfo.Name.Trim() == "" ? "نامشخص" : stInfo.Name; string lastName = stInfo.LastName.Trim() == "" ? "نامشخص" : stInfo.LastName; adobeConnectDTO.SetValueDefult(userAdobe, passAdobeUser, firtsName, lastName); adobeConnectDTO.MeetingUrlPath = "/st99900999_13981107_6"; string link = "http://" + adobeBusiness.OpenMeetingAsView(adobeConnectDTO); Response.Redirect(link); }
protected void Page_init(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null) { Response.Redirect("~/CommonUI/login.aspx"); } else { if (!IsPostBack) { LoginBusiness lgnB = new LoginBusiness(); StuImg st = lgnB.User_Img(Session[sessionNames.userID_StudentOstad].ToString()); PersonalImage.DataValue = st.img; LoginDTO stInfo = lgnB.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; } //برای زمانی که از رزرواسیون به طور مستقیم می یاد if (Session["ComeFromRes"] != null && Session["ComeFromRes"].ToString() == "ok") { Session[sessionNames.appID_StudentOstad] = "4"; Session["ComeFromRes"] = "no"; } if (Session[sessionNames.appID_StudentOstad].ToString() == "5") { a_card.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "4") { a_Edit.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "3") { a_eshteghal.Visible = true; a_Vaziat.Visible = true; } if (Session[sessionNames.appID_StudentOstad].ToString() == "12") { a_tasvieh.Visible = true; } } }
protected void lnkLinkDefence_Click(object sender, EventArgs e) { System.Web.UI.WebControls.Button btn = (System.Web.UI.WebControls.Button)sender; GridDataItem item = (GridDataItem)btn.NamingContainer; Label vazId = (Label)item.FindControl("lblVazId"); if (vazId.Text == "1") { LoginBusiness lgb = new LoginBusiness(); var userAdobe = Session[sessionNames.userID_StudentOstad].ToString(); LoginDTO stInfo = lgb.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); string firtsName = stInfo.Name.Trim() == "" ? "نامشخص" : stInfo.Name; string lastName = stInfo.LastName.Trim() == "" ? "نامشخص" : stInfo.LastName; adobeConnectDTO.SetValueDefult(userAdobe, passAdobeUser, firtsName, lastName); var Link = item.FindControl("resLink") as Label; adobeConnectDTO.MeetingUrlPath = "/" + Link.Text.Replace("/", "");//name.Text; } else { RadWindowManager1.RadAlert("جلسه دفاع در حال حاضر در دسترس نیست", 500, 100, "خطا", ""); return; } stocode = Session[sessionNames.userID_StudentOstad].ToString(); var lblStcode = item.FindControl("lblstudentcode") as Label; string link = ""; if (lblStcode.Text == stocode) { link = "http://" + adobeBusiness.OpenMeetingAsPresnter(adobeConnectDTO); } else { link = "http://" + adobeBusiness.OpenMeetingAsView(adobeConnectDTO); } Response.Redirect(link); }
protected void Page_Init(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null) { Response.Redirect("~/CommonUI/login.aspx"); } else { Session["CountUnRead"] = null; Session["ContactUnread"] = null; LoginBusiness logBusiness = new LoginBusiness(); System.Data.DataTable dt = new System.Data.DataTable(); string userId = Session[sessionNames.userID_StudentOstad].ToString(); user.Text = userId; //if (Request.QueryString["Flag_Grp"] != null ) //{ MessageJs.DeleteUnreadStudent(userId, Request.QueryString["Flag_Grp"] != null? Request.QueryString["Flag_Grp"]: "True", Request.QueryString["Flag_Grp"] != null && Request.QueryString["Flag_Grp"].Trim() != "True" && Request.QueryString["IdGrpOrPerson"] != null ? Request.QueryString["IdGrpOrPerson"] :"-1"); // } if (!IsPostBack) { StuImg st = logBusiness.User_Img(Session[sessionNames.userID_StudentOstad].ToString()); PersonalImage.DataValue = st.img; LoginDTO stInfo = logBusiness.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); stName.InnerText = stInfo.Name + " " + stInfo.LastName; DataTable dtCountUnread; DataTable dtUnReadContact; dtCountUnread = MsgUnReadStudentBuisnes.GetUnReadMsgCountStudent(userId); if (dtCountUnread != null && dtCountUnread.Rows.Count > 0) { Session["CountUnRead"] = dtCountUnread.Rows[0]["CountUnRead"].ToString(); dtUnReadContact = MsgUnReadStudentBuisnes.GetUnReadMsgStudent(userId); Session.Add("ContactUnread", dtUnReadContact); } } } }
public static void CreateMeeting(string stCode, string date, string startTime, int LengthMeeting, string stName, bool flagTotal = false, string requestId = "") { RequestHandler reqH = new RequestHandler(); AdobeConnectDTO adobeConnectDTO = new AdobeConnectDTO(); LoginBusiness lgb = new LoginBusiness(); AdobeDefenceBusiness adobeDefenceBusiness = new AdobeDefenceBusiness(); LoginDTO stInfo = lgb.Get_StInfo(stCode.ToString()); const string pass = "******"; string firtsName = (stInfo == null || stInfo.Name == null || stInfo.Name.Trim() == "") ? "نامشخص" : stInfo.Name; string lastName = (stInfo == null || stInfo.LastName == null || stInfo.LastName.Trim() == "") ? "نامشخص" : stInfo.LastName; adobeConnectDTO.SetValueDefult(stCode.ToString(), pass, firtsName, lastName); adobeConnectDTO.MeetingName = ConvertorFarsi2Arabic.Parse_Farsi2_Arabic(" جلسه دفاع " + (stName != null && stName.Trim() != "" ? stName : "")); string link = adobeDefenceBusiness.CreateLinkMeeting(stCode.ToString(), date, startTime.ToString()); adobeConnectDTO.MeetingUrlPath = link; PersianCalendar PC = new PersianCalendar(); adobeConnectDTO.MeetingDataBegin = PC.ToDateTime(int.Parse(date.Substring(0, 4)), int.Parse(date.Substring(5, 2)), int.Parse(date.Substring(8, 2)), int.Parse(startTime), 0, 0, 0); adobeConnectDTO.MeetingDataEnd = PC.ToDateTime(int.Parse(date.Substring(0, 4)), int.Parse(date.Substring(5, 2)), int.Parse(date.Substring(8, 2)), int.Parse(startTime) + LengthMeeting, 0, 0, 0); if (flagTotal) { adobeDefenceBusiness.CreateMeeting(adobeConnectDTO); } else { DataTable dtExistLink = reqH.GetMeetingDefencesAStudentByStcodeBusinesss(stCode.ToString()); if (dtExistLink != null && dtExistLink.Rows.Count > 0 && dtExistLink.Rows[0]["resLink"].ToString().Trim() != "") { //empty } else { adobeDefenceBusiness.CreateMeeting(adobeConnectDTO); reqH.UpdateRequest_LinkMeeting(requestId.Trim(), link); } } }
protected void Page_Load(object sender, EventArgs e) { if (Session[sessionNames.userID_StudentOstad] == null) { Response.Redirect("login.aspx"); } StCard.Disabled = true; if (Session[sessionNames.userID_StudentOstad] == null) { Session["LogStatus"] = "0-0"; form1.Action = ConfigurationManager.AppSettings["LMS_link"].ToString(); LogStatus.Value = Session["LogStatus"].ToString(); ScriptManager.RegisterStartupScript(this, GetType(), "submitform", "submitform();", true); } //############## //############## //############## #region Evaluation /** * var isUserevaluated = _evaluationBusiness.IsUserevaluated(int.Parse(Session[sessionNames.userID_StudentOstad].ToString())); * var isQuestionExist = _evaluationBusiness.IsQuestionExist(); * var azmoonCallBack = _evaluationBusiness.CallAzmoonApi(int.Parse(Session[sessionNames.userID_StudentOstad].ToString())); * if (!isUserevaluated && isQuestionExist && azmoonCallBack) * { * ShowEvaluationQuestion(); * } */ #endregion #region UpdateStudent //var isStudentUpdate = _studentInfoBusiness.IsStudentUpdate(Session[sessionNames.userID_StudentOstad].ToString()); //if (!isStudentUpdate) //{ // ShowStudentInformation(); //} #endregion if (Session[sessionNames.userID_StudentOstad].ToString().Length < 14) { logBusiness.updatePortalStudentInfo(Session[sessionNames.userID_StudentOstad].ToString());//آپدیت اطلاعات دانشجو روی پرتال } dt_vaz = logBusiness.GetStIdVaz(Session[sessionNames.userID_StudentOstad].ToString()); a_LMS.Visible = true; Session["CountApprove"] = 1; DTO.CommonClasses.LoginDTO stInfo = logBusiness.Get_StInfo(Session[sessionNames.userID_StudentOstad].ToString()); usernamelbl.InnerText = stInfo.Name + " " + stInfo.LastName + " خوش آمدید "; //ISchedule myTask = new SendSmsSchedule(); //myTask.Run(); if (Request["__EVENTARGUMENT"] != null && Request["__EVENTARGUMENT"] == "info") { } /*-----------------Wallet---------------------*/ if (!IsPostBack) { var balance = _walletBusiness.GetStudentCurrentBalance(Session[sessionNames.userID_StudentOstad].ToString()); lblCurrentBalance.Text = String.Format("{0:n0}", balance) + "ريال"; } /*--------------------------------------------*/ }