/// <summary> /// 查找html /// </summary> /// <returns></returns> protected string getFinder() { StringBuilder sb = new StringBuilder(); try { foreach (DataBaseField f1 in valObj.af_GetAvailableDataBaseField()) { //条件对象有赋值 if (finderObj.IsNotNull()) { AttributeItem attr1 = new AttributeItem(f1); if (finderObj.GetInitialized(attr1)) { f1.Value = Convert.ToString(finderObj.GetValue(attr1)); } } string attrHtml = Finder; BuildByTag b1 = new BuildByTag(BuildType.ForHtmlValue); b1.ParseForSwitch标签(ref attrHtml, f1); sb.Append("<dl><dt>").Append(f1.Desc.ZhName).Append(":</dt><!--").Append(f1.FieldName) .Append("--><dd><span>"); sb.Append(attrHtml); sb.Append("</span></dd></dl>"); } } catch (Exception ex) { Cs.Error("34" + ex.ToString()); } return(sb.ToString()); }
/// <summary> /// 查找html /// </summary> /// <returns></returns> protected string getFinder() { StringBuilder sb = new StringBuilder(); try { foreach (DataBaseField f1 in fieldList) { f1.Value = null; bool isNull1 = finderObj.IsNotNull(); bool isInit1 = false; //条件对象有赋值 if (isNull1) { AttributeItem attr1 = new AttributeItem(f1); isInit1 = finderObj.GetInitialized(attr1); if (isInit1) { f1.Value = Convert.ToString(finderObj.GetValue(attr1)); } } if (f1.ZhName == "多选数量") { "".ToString(); } string attrHtml = Finder; //jinsj foreach (string table1 in f1.Desc.OutSource_ChaZhao.Keys) { string selModuleUrl = null; if (f1.Desc.Switch_CtrlType == BaseCtrlType.SelectMultiple) { selModuleUrl = "Sels.aspx?moduleName=" + table1 + "&r=" + DateTime.Now.Ticks; } else { selModuleUrl = "Sel.aspx?moduleName=" + table1 + "&r=" + DateTime.Now.Ticks; } attrHtml = attrHtml.Replace("{首字母大写关联表名}", selModuleUrl); } BuildByTag b1 = new BuildByTag(BuildType.ForHtmlValue); b1.ParseForSwitch标签(ref attrHtml, f1); if (isChaZhao(f1)) { attrHtml = attrHtml.Replace("{字段显示值}", Convert.ToString(finderObj.GetValue(f1.TableName, f1.Desc.FieldCtrlName + "_NAME"))); } sb.Append("<dl><dt>").Append(f1.Desc.ZhName).Append(":</dt><!--").Append(f1.FieldName) .Append("--><dd><span>"); sb.Append(attrHtml); sb.Append("</span></dd></dl>"); } } catch (Exception ex) { Cs.Error("34" + ex.ToString()); } return(sb.ToString()); }
/// <summary> /// 查找html /// </summary> /// <returns></returns> protected string getFinder() { StringBuilder sb = new StringBuilder(); try { foreach (DataBaseField f1 in fieldList) { f1.Value = null; bool isNull1 = finderObj.IsNotNull(); bool isInit1 = false; //条件对象有赋值 if (isNull1) { AttributeItem attr1 = new AttributeItem(f1); isInit1 = finderObj.GetInitialized(attr1); if (isInit1) { f1.Value = Convert.ToString(finderObj.GetValue(attr1)); } } string attrHtml = Finder; BuildByTag b1 = new BuildByTag(BuildType.ForHtmlValue); b1.ParseForSwitch标签(ref attrHtml, f1); if (isChaZhao(f1)) { attrHtml = attrHtml.Replace("{字段显示值}", Convert.ToString(finderObj.GetValue(f1.TableName, f1.Desc.FieldCtrlName + "_NAME"))); } sb.Append("<dl><dt>").Append(f1.Desc.ZhName).Append(":</dt><!--").Append(f1.FieldName) .Append("--><dd><span>"); sb.Append(attrHtml); sb.Append("</span></dd></dl>"); } } catch (Exception ex) { Cs.Error("34" + ex.ToString()); } return(sb.ToString()); }
/// <summary> /// 输入html /// </summary> /// <returns></returns> protected string getInput() { StringBuilder sb = new StringBuilder(); string strChazhaoID = ""; try { DataBaseField[] flist = valObj.af_GetAvailableDataBaseField(); foreach (DataBaseField f1 in flist) { string block = "基础信息"; block = f1.Desc.af_BlockName; string blockid = f1.Desc.af_BlockID; if (f1.TableName != resultObj._TableName) //说明不是本表字段 { block = f1.TableName; //布局名,就是 关联表的父表 表名 if (resultObj.IsOnlyForModuleIDName == true) { break; } else { } } f1.Value = Convert.ToString(resultObj.GetValue(f1)); string attrHtml = Input; BuildByTag b1 = new BuildByTag(BuildType.ForHtmlValue); b1.ParseForSwitch标签(ref attrHtml, f1); if (isChaZhao(f1)) { DataBaseField f2 = f1.DataBaseTable.FatherTable_ChaZhao[0].DataBaseTable.NameField; string html = Convert.ToString(resultObj.GetValue(f2)); attrHtml = attrHtml.Replace("{字段显示值}", html); strChazhaoID = f1.Value; } else if (isSelect(f1))//枚举量 { AttributeItem attr2 = AttributeItem.Factory(f1); string html = BaseFormHelper.Factory(resultObj.ConnectKey).GetOptionText(attr2, f1.Value); attrHtml = html; } else if (f1.Desc.Switch_CtrlType == BaseCtrlType.FileUpImage) { attrHtml = "<img style='height:19px;top:5px;postion:relative;' src ='" + f1.Value + "' style='height:40px' />"; } sb.Append("<dl class=\"dl-horizontal\"><dt><span>").Append(f1.Desc.ZhName).Append("</span></dt><!--").Append(f1.FieldName) .Append("--><dd><span>"); sb.Append(attrHtml); sb.Append("</span></dd></dl>"); } } catch (Exception ex) { Cs.Error("34" + ex.ToString()); } return(sb.ToString()); }