private void ShowInfo(int FuwuTypeID) { Maticsoft.BLL.FuWuTypeInfo bll = new Maticsoft.BLL.FuWuTypeInfo(); Maticsoft.Model.FuWuTypeInfo model = bll.GetModel(FuwuTypeID); this.lblFuwuTypeID.Text = model.FuwuTypeID.ToString(); this.lblFuwuTypeName.Text = model.FuwuTypeName; }
protected void datading_ItemDataBound(object sender, DataListItemEventArgs e) { int index = int.Parse(datafuwu.DataKeys[e.Item.ItemIndex].ToString()); Maticsoft.BLL.FuWuInfo fuwubll = new Maticsoft.BLL.FuWuInfo(); Maticsoft.Model.FuWuInfo fuwumodel = fuwubll.GetModel(index); Maticsoft.BLL.FuWuTypeInfo typebll = new Maticsoft.BLL.FuWuTypeInfo(); Maticsoft.Model.FuWuTypeInfo typemodel = typebll.GetModel(int.Parse(fuwumodel.FuwuTypeID.ToString())); ((Label)e.Item.FindControl("lnltype")).Text = typemodel.FuwuTypeName; }
private void bind(int fuwuID) { Maticsoft.BLL.FuWuInfo fuwubll = new Maticsoft.BLL.FuWuInfo(); Maticsoft.Model.FuWuInfo fuwumodel = fuwubll.GetModel(fuwuID); Maticsoft.BLL.FuWuTypeInfo typebll = new Maticsoft.BLL.FuWuTypeInfo(); Maticsoft.Model.FuWuTypeInfo typemodel = typebll.GetModel(int.Parse(fuwumodel.FuwuTypeID.ToString())); lblFatime.Text = Convert.ToDateTime(fuwumodel.Fatime.ToString()).ToString("yyyy-MM-dd"); lblFuwucontent.Text = fuwumodel.Fuwucontent; lblWrite.Text = fuwumodel.Write; lblFuwuTypeName.Text = typemodel.FuwuTypeName; lbltitle.Text = fuwumodel.fuwuTitle; }
private void bind() { int fuwuid = int.Parse(Request.QueryString["fuwuID"].ToString()); Maticsoft.BLL.FuWuInfo fuwubll = new Maticsoft.BLL.FuWuInfo(); Maticsoft.Model.FuWuInfo fuwumodel = fuwubll.GetModel(fuwuid); Maticsoft.BLL.FuWuTypeInfo fuwutypebll = new Maticsoft.BLL.FuWuTypeInfo(); lblfaren.Text = fuwumodel.Write; lblfatime.Text = Convert.ToDateTime(fuwumodel.Fatime.ToString()).ToString("yyyy-MM-dd"); lbltitle.Text = fuwumodel.fuwuTitle; string fuwutype = fuwutypebll.GetModel(Convert.ToInt32(fuwumodel.FuwuTypeID.ToString())).ToString(); lbltype.Text = fuwutype; if (fuwumodel.ImageURL == "") { tu.Visible = false; } else { tu.Visible = true; Image1.ImageUrl = fuwumodel.ImageURL; } }