public string VerifyFile(int fileId) { if (Xslt.IsMemberInGroup("admin", Members.GetCurrentMember().Id)) { var wikiFile = new WikiFile(fileId) { Verified = true }; wikiFile.Save(); } return(""); }
public static string VerifyFile(int ID) { int _currentMember = HttpContext.Current.User.Identity.IsAuthenticated ? (int)Membership.GetUser().ProviderUserKey : 0; if (Xslt.IsMemberInGroup("admin", _currentMember)) { WikiFile wf = new WikiFile(ID); wf.Verified = true; wf.Save(); } return(""); }
protected void ArchiveFile(object sender, CommandEventArgs e) { WikiFile wf = new WikiFile(int.Parse(e.CommandArgument.ToString())); if (e.CommandName == "Unarchive") { wf.Archived = false; } else { wf.Archived = true; } wf.Save(); RebindFiles(); }