コード例 #1
0
        public void AddComment(string username, int itemId, string comment)
        {
            ItemComment itemComment = new ItemComment();

            itemComment.Username = username;
            itemComment.ItemId = itemId;
            itemComment.Comment = comment;
            itemComment.Date = DateTime.Now;
            itemComment.ThumbsUp = 1;

            db.ItemComments.InsertOnSubmit(itemComment);
            db.SubmitChanges();
        }
コード例 #2
0
		private void detach_ItemComments(ItemComment entity)
		{
			this.SendPropertyChanging();
			entity.Item = null;
		}
コード例 #3
0
		private void attach_ItemComments(ItemComment entity)
		{
			this.SendPropertyChanging();
			entity.Item = this;
		}
コード例 #4
0
 partial void DeleteItemComment(ItemComment instance);
コード例 #5
0
 partial void UpdateItemComment(ItemComment instance);
コード例 #6
0
 partial void InsertItemComment(ItemComment instance);