public static string PetitionUrl(Petition aPetition)
 {
     return "/Petition/Details/" + aPetition.Id;
 }
 /// <summary>
 /// Deprecated Method for adding a new object to the Petitions EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToPetitions(Petition petition)
 {
     base.AddObject("Petitions", petition);
 }
 public static bool IsOwner(UserInformationModel<User> aUser, Petition aPetition)
 {
     IPetitionService myPetitionService = new PetitionService(new ModelStateWrapper(new ModelStateDictionary()));
     return myPetitionService.CanView(aUser, aPetition);
 }
 /// <summary>
 /// Create a new Petition object.
 /// </summary>
 /// <param name="id">Initial value of the Id property.</param>
 /// <param name="userId">Initial value of the UserId property.</param>
 /// <param name="title">Initial value of the Title property.</param>
 /// <param name="description">Initial value of the Description property.</param>
 /// <param name="city">Initial value of the City property.</param>
 /// <param name="state">Initial value of the State property.</param>
 /// <param name="zip">Initial value of the Zip property.</param>
 /// <param name="dateTimeStamp">Initial value of the DateTimeStamp property.</param>
 /// <param name="active">Initial value of the Active property.</param>
 public static Petition CreatePetition(global::System.Int32 id, global::System.Int32 userId, global::System.String title, global::System.String description, global::System.String city, global::System.String state, global::System.String zip, global::System.DateTime dateTimeStamp, global::System.Boolean active)
 {
     Petition petition = new Petition();
     petition.Id = id;
     petition.UserId = userId;
     petition.Title = title;
     petition.Description = description;
     petition.City = city;
     petition.State = state;
     petition.Zip = zip;
     petition.DateTimeStamp = dateTimeStamp;
     petition.Active = active;
     return petition;
 }