public void setvote(int musicid, int vote) { using (var musicct = new DataClassesDataContext()) { SONG song = musicct.SONGs.Single(p => p.SONGID == musicid); song.VOTE += vote; musicct.SubmitChanges(); } }
public decimal getvote(int musicid) { decimal?a; using (var musicct = new DataClassesDataContext()) { SONG song = musicct.SONGs.Single(p => p.SONGID == musicid); a = song.VOTE; } return(decimal.Parse(a.ToString())); }
private void detach_SONGs(SONG entity) { this.SendPropertyChanging(); entity.SINGER = null; }
private void attach_SONGs(SONG entity) { this.SendPropertyChanging(); entity.SINGER = this; }
private void attach_SONGs(SONG entity) { this.SendPropertyChanging(); entity.EMOTION = this; }
partial void DeleteSONG(SONG instance);
partial void UpdateSONG(SONG instance);
partial void InsertSONG(SONG instance);