Inheritance: INotifyPropertyChanging, INotifyPropertyChanged
Exemple #1
0
        public FeedEvent(PoliticianLawVote vote)
        {
            var thelaw = vote.LawVote.Law;
            var thevote = vote.LawVote;

            this.date = thevote.Date.Value;
            this.BodyText = thelaw.Summary.PresentText(200);

            this.ActionUrl = thelaw.DetailsLink();
            this.ActionText = GetVoteText(vote) + " til " + thelaw.ShortName.PresentText(35);
        }
Exemple #2
0
 private string GetVoteText(PoliticianLawVote plv)
 {
     switch (plv.Vote)
     {
         case 0: return "Stemte Ja";
         case 1: return "Stemte Nej";
         case 2: return "Afstod fra at stemme";
         default: throw new ArgumentException("Unknown votetype: " + plv.Vote);
     }
 }
Exemple #3
0
 private void detach_PoliticianLawVotes(PoliticianLawVote entity)
 {
     this.SendPropertyChanging();
     entity.LawVote = null;
 }
Exemple #4
0
 private void attach_PoliticianLawVotes(PoliticianLawVote entity)
 {
     this.SendPropertyChanging();
     entity.Politician = this;
 }
Exemple #5
0
 partial void DeletePoliticianLawVote(PoliticianLawVote instance);
Exemple #6
0
 partial void UpdatePoliticianLawVote(PoliticianLawVote instance);
Exemple #7
0
 partial void InsertPoliticianLawVote(PoliticianLawVote instance);