public GetPersonID ( System.Int64 nodeid ) : int | ||
nodeid | System.Int64 | |
Résultat | int |
public EditObjectTypeProperty(XmlDocument pagedata, List<ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces) : base(pagedata, moduleparams, pagenamespaces) { Edit.Utilities.DataIO data; SessionManagement sm = new SessionManagement(); Profiles.Profile.Utilities.DataIO propdata = new Profiles.Profile.Utilities.DataIO(); data = new Profiles.Edit.Utilities.DataIO(); if (Request.QueryString["subject"] != null) this.SubjectID = Convert.ToInt64(Request.QueryString["subject"]); else if (base.GetRawQueryStringItem("subject") != null) this.SubjectID = Convert.ToInt64(base.GetRawQueryStringItem("subject")); else Response.Redirect("~/search"); this.PredicateURI = Request.QueryString["predicateuri"].Replace("!", "#"); GetSubjectProfile(); this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, PredicateURI, false, true, false); this.PropertyLabel = PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@Label").Value; litBackLink.Text = "<a href='" + Root.Domain + "/edit/" + this.SubjectID.ToString() + "'>Edit Menu</a> > <b>" + this.PropertyLabel + "</b>"; securityOptions.Subject = this.SubjectID; securityOptions.PredicateURI = PredicateURI; this.PredicateID = data.GetStoreNode(this.PredicateURI); securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value); securityOptions.SecurityGroups = new XmlDataDocument(); securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml); this._subject = Convert.ToInt64(Request.QueryString["subject"]); this._personId = data.GetPersonID(_subject); }
public CustomEditAuthorInAuthorship(XmlDocument pagedata, List <ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces) : base(pagedata, moduleparams, pagenamespaces) { SessionManagement sm = new SessionManagement(); Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); propdata = new Profiles.Profile.Utilities.DataIO(); this._subject = Convert.ToInt64(Request.QueryString["subject"]); this._predicateuri = Request.QueryString["predicateuri"].Replace("!", "#"); this._personId = data.GetPersonID(_subject); Session["NodeID"] = this._subject; Session["SessionID"] = sm.Session().SessionID; this.PropertyListXML = propdata.GetPropertyList(pagedata, base.PresentationXML, this._predicateuri, false, true, false); securityOptions.Subject = this._subject; securityOptions.PredicateURI = this._predicateuri; securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value); securityOptions.SecurityGroups = new XmlDataDocument(); securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml); securityOptions.BubbleClick += SecurityDisplayed; }
protected void ProcessUpload(object sender, AjaxControlToolkit.AsyncFileUploadEventArgs e) { System.IO.Stream stream; Edit.Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); stream = AsyncFileUpload1.PostedFile.InputStream; byte[] imageBytes = new byte[AsyncFileUpload1.PostedFile.InputStream.Length + 1]; AsyncFileUpload1.PostedFile.InputStream.Read(imageBytes, 0, imageBytes.Length); data.SaveImage(data.GetPersonID(this.SubjectID), imageBytes); base.GetSubjectProfile(); this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, this.PredicateURI, false, true, false); this.DrawProfilesModule(); InitLinks(); pnlUpload.Visible = false; this.KillCache(); upnlEditSection.Update(); }
public CustomEditAuthorInAuthorship(XmlDocument pagedata, List<ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces) : base(pagedata, moduleparams, pagenamespaces) { SessionManagement sm = new SessionManagement(); Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); this._subject = Convert.ToInt64(Request.QueryString["subject"]); this._predicateuri = Request.QueryString["predicateuri"].Replace("!", "#"); this._personId = data.GetPersonID(_subject); Session["NodeID"] = this._subject; Session["SessionID"] = sm.Session().SessionID; this.PropertyListXML = data.GetPropertyList(pagedata, base.PresentationXML, this._predicateuri, false, true, false); securityOptions.Subject = this._subject; securityOptions.PredicateURI = this._predicateuri; securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value); securityOptions.SecurityGroups = new XmlDataDocument(); securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml); }
public CustomEditAuthorInAuthorship(XmlDocument pagedata, List<ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces) : base(pagedata, moduleparams, pagenamespaces) { SessionManagement sm = new SessionManagement(); Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); propdata = new Profiles.Profile.Utilities.DataIO(); this._subject = Convert.ToInt64(Request.QueryString["subject"]); this._predicateuri = Request.QueryString["predicateuri"].Replace("!", "#"); this._personId = data.GetPersonID(_subject); Session["NodeID"] = this._subject; Session["SessionID"] = sm.Session().SessionID; this.PropertyListXML = propdata.GetPropertyList(pagedata, base.PresentationXML, this._predicateuri, false, true, false); //Quick fix to allow only Admin and Curators to edit Visibility privacy securityOptions.userRole = propdata.GetUserRole(sm.Session().SessionID); if (securityOptions.userRole == -40 || securityOptions.userRole == -50) { securityOptions.FindControl("imbSecurityOptions").Visible = true; securityOptions.FindControl("lbSecurityOptions").Visible = true; } else { securityOptions.FindControl("imbSecurityOptions").Visible = false; securityOptions.FindControl("lbSecurityOptions").Visible = false; } securityOptions.Subject = this._subject; securityOptions.PredicateURI = this._predicateuri; securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value); securityOptions.SecurityGroups = new XmlDataDocument(); securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml); securityOptions.BubbleClick += SecurityDisplayed; }
protected void ProcessUpload(object sender, AjaxControlToolkit.AsyncFileUploadEventArgs e) { try { System.IO.Stream stream; Edit.Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); stream = AsyncFileUpload1.PostedFile.InputStream; byte[] imageBytes = new byte[AsyncFileUpload1.PostedFile.InputStream.Length + 1]; AsyncFileUpload1.PostedFile.InputStream.Read(imageBytes, 0, imageBytes.Length); data.SaveImage(data.GetPersonID(this.SubjectID), imageBytes); base.GetSubjectProfile(); this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, this.PredicateURI, false, true, false); this.DrawProfilesModule(); InitLinks(); pnlUpload.Visible = false; this.KillCache(); upnlEditSection.Update(); } catch (Exception ex) { Framework.Utilities.DebugLogging.Log(ex.Message + " " + ex.StackTrace); throw new Exception(ex.Message); } }
public EditObjectTypeProperty(XmlDocument pagedata, List<ModuleParams> moduleparams, XmlNamespaceManager pagenamespaces) : base(pagedata, moduleparams, pagenamespaces) { Edit.Utilities.DataIO data; SessionManagement sm = new SessionManagement(); Profiles.Profile.Utilities.DataIO propdata = new Profiles.Profile.Utilities.DataIO(); data = new Profiles.Edit.Utilities.DataIO(); if (Request.QueryString["subject"] != null) this.SubjectID = Convert.ToInt64(Request.QueryString["subject"]); else if (base.GetRawQueryStringItem("subject") != null) this.SubjectID = Convert.ToInt64(base.GetRawQueryStringItem("subject")); else Response.Redirect("~/search"); this.PredicateURI = Request.QueryString["predicateuri"].Replace("!", "#"); GetSubjectProfile(); this.PropertyListXML = propdata.GetPropertyList(this.BaseData, base.PresentationXML, PredicateURI, false, true, false); this.PropertyLabel = PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@Label").Value; litBackLink.Text = "<a href='" + Root.Domain + "/edit/" + this.SubjectID.ToString() + "'>Edit Menu</a> > <b>" + this.PropertyLabel + "</b>"; //Quick add for adding a note on the format of grant info when adding manually if (PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/@Label").Value == "Research") { litGrantNote1.Text = "Please use the following format when adding the grant information: "; litGrantNote2.Text = "Funding Agency: Agency Name - Title: Grant Title - Award Number: Grant ID Number - Total direct costs: $amount - Start Date: yyyy-mm-dd - End Date: yyyy-mm-dd <br /> Or for subaward:<br /> Subaward: Name of Pass-Through Institution - Funding Agency: Agency Name - Title: Grant Title - Award Number: Grant ID Number - Total direct costs: $amount - Start Date: yyyy-mm-dd - End Date: yyyy-mm-dd"; } //Quick fix to allow only Admin and Curators to edit Visibility privacy securityOptions.userRole = propdata.GetUserRole(sm.Session().SessionID); if (securityOptions.userRole == -40 || securityOptions.userRole == -50) { securityOptions.FindControl("imbSecurityOptions").Visible = true; securityOptions.FindControl("lbSecurityOptions").Visible = true; } else { securityOptions.FindControl("imbSecurityOptions").Visible = false; securityOptions.FindControl("lbSecurityOptions").Visible = false; } securityOptions.Subject = this.SubjectID; securityOptions.PredicateURI = PredicateURI; this.PredicateID = data.GetStoreNode(this.PredicateURI); securityOptions.PrivacyCode = Convert.ToInt32(this.PropertyListXML.SelectSingleNode("PropertyList/PropertyGroup/Property/@ViewSecurityGroup").Value); securityOptions.SecurityGroups = new XmlDataDocument(); securityOptions.SecurityGroups.LoadXml(base.PresentationXML.DocumentElement.LastChild.OuterXml); this._subject = Convert.ToInt64(Request.QueryString["subject"]); this._personId = data.GetPersonID(_subject); }
protected void ProcessUpload(object sender, AjaxControlToolkit.AsyncFileUploadEventArgs e) { System.IO.Stream stream; Edit.Utilities.DataIO data = new Profiles.Edit.Utilities.DataIO(); stream = AsyncFileUpload1.PostedFile.InputStream; byte[] imageBytes = new byte[AsyncFileUpload1.PostedFile.InputStream.Length + 1]; AsyncFileUpload1.PostedFile.InputStream.Read(imageBytes, 0, imageBytes.Length); data.SaveImage(data.GetPersonID(this.SubjectID), imageBytes, this.PropertyListXML); base.GetSubjectProfile(); this.PropertyListXML = data.GetPropertyList(this.BaseData, base.PresentationXML, this.PredicateURI, false, true, false); this.DrawProfilesModule(); upnlEditSection.Update(); }