public ActionResult SaveCfgItemEdit(CfgItem model) { InkeyResult result = new InkeyResult(); _cfgManagerService.EditCfgItem(model); return(Json(result)); }
private void updateTbInfoText(CfgItem sender, string info) { this.tbInfo.Text = info; if (sender.Node.Name == "CityNo") { bool flag1 = this.checkBox1.Checked; } }
public ActionResult CfgItemVerAdd(string ids) { var idVals = ids.Split('#').Select(id => Guid.Parse(id)).ToArray(); CfgItem item = _cfgManagerService.GetCfgItem(idVals[0]); var data = new CfgItemVersionEnvironment(); data.ItemId = item.ItemId; data.Key = item.Key; IList <CfgEnvironment> envData = _cfgManagerService.GetCfgEnvironmentList(); ViewBag.EnvSelectList = new SelectList(envData, "EnvId", "Name"); return(View("CfgItemVerAdd", data)); }
CfgItem[] GetCfgItems() { CfgItem[] items = new CfgItem[9]; items[0] = new CfgItem(this.GetType().GetProperty("UnknownWordsThreshold"), "未登录词阈值,当统计超过这个值时,自动将未登录词加入到字典中"); items[1] = new CfgItem(this.GetType().GetProperty("AutoInsertUnknownWords"), "自动插入超过统计阈值的未登录词"); items[2] = new CfgItem(this.GetType().GetProperty("FreqFirst"), "优先判断词频,如果一个长的单词由多个短的单词组成,而长的单词词频较低则忽略长的单词。如 中央酒店的词频比中央和酒店的词频都要低,则忽略中央酒店。"); items[3] = new CfgItem(this.GetType().GetProperty("AutoStudy"), "自动统计姓名前后缀,自动统计未登录词,自动统计词频"); items[4] = new CfgItem(this.GetType().GetProperty("AutoSaveInterval"), "间隔多少秒自动保存最新的字典和统计信息,AutoStudy = true时有效"); items[5] = new CfgItem(this.GetType().GetProperty("DictPath"), "字典文件所在路径"); items[6] = new CfgItem(this.GetType().GetProperty("LogFileName"), "日志文件名"); items[7] = new CfgItem(this.GetType().GetProperty("MatchName"), "是否匹配汉语人名"); items[8] = new CfgItem(this.GetType().GetProperty("FilterStopWords"), "是否过滤停用词"); return(items); }
protected override bool ProcessDialogKey(Keys keyData) { switch (keyData) { case Keys.Q: case Keys.C: case Keys.T: input += keyData.ToString(); break; case Keys.Return: if (input == "QCT" && !checkBox1.Checked) { //flowLayoutPanel1.SuspendLayout(); btnClear.Visible = true; foreach (XmlNode item in root.ChildNodes) { CfgDescribe cfgd = cfgDess.Find(c => { return(c.Name == item.Name); }); if (cfgd != null && !cfgd.CanSee) { cfgd.CanSee = true; CfgItem cfg = new CfgItem(tbName, tbValue, cfgd.DisplayText, item, cfgd.Whats); cfg.discripInfo += new CfgItem.DiscripInfo(updateTbInfoText); listCfg.Add(cfg); flowLayoutPanel1.Controls.Add(cfg.TName); flowLayoutPanel1.Controls.Add(cfg.TValue); } } //flowLayoutPanel1.ResumeLayout(false); } input = ""; break; default: break; } return(base.ProcessDialogKey(keyData)); }
public void EditCfgItem(CfgItem model) { _cfgManagerDao.UpdateAllCfgItem(model); }