public void Create(string text, DateTime creatiomtime, string categoryname) { var item = new Data { ID=GetNewID(), Text = text, CreationTime= creatiomtime }; datalist.Add(item); manager[getCategoryID(categoryname)].Insert(item); }
private void reBuild(int insertBefore, Data item) { var json = JsonSerializer.Serialize(item); InvokeScript("js_BuildInsertByID", insertBefore.ToString(), json); }
private void reBuild(Data item) { List<string> wo = new List<string>() { "test", "FireBug" }; var words = JsonSerializer.Serialize(wo); var json = JsonSerializer.Serialize(item); InvokeScript("js_BuildByID", json, words); }
private void editContent(Data item) { var json = JsonSerializer.Serialize(item); InvokeScript("js_editContent", json); //InvokeScript("js_editContent", new string[]{json}); }
public int AddItem(Data item) { //items.Add(item); if (search.getSearch().Invoke(item)) { var i = ItemManager.Insert(items, item); this.VirtualListSize = items.Count; return i; } return -1; }
public void DeleteItem(Data item) { if (this.items.Remove(item)) { this.VirtualListSize = items.Count; } }