using System; using BLL; namespace FineUIPro.Web.HJGL.FileControl { public partial class DomesticLawsRegulationsEdit : PageBase { /// /// 主键 /// public string DomesticLawsRegulationsId { get { return (string)ViewState["DomesticLawsRegulationsId"]; } set { ViewState["DomesticLawsRegulationsId"] = value; } } /// /// 加载页面 /// /// /// protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { this.btnClose.OnClientClick = ActiveWindow.GetHideReference(); this.DomesticLawsRegulationsId = Request.Params["DomesticLawsRegulationsId"]; var domesticLawsRegulations = BLL.HJGL_FileControl_DomesticLawsRegulationsService.GetDomesticLawsRegulationsById(this.DomesticLawsRegulationsId); if (domesticLawsRegulations != null) { this.txtDomesticLawsRegulationsCode.Text = domesticLawsRegulations.DomesticLawsRegulationsCode; this.txtDomesticLawsRegulationsName.Text = domesticLawsRegulations.DomesticLawsRegulationsName; this.txtAbstract.Text = domesticLawsRegulations.Summary; this.txtCompileMan.Text = domesticLawsRegulations.CompileMan; this.txtRemarks.Text = domesticLawsRegulations.Remarks; if (domesticLawsRegulations.CompileDate != null) { this.dpkCompileDate.Text = string.Format("{0:yyyy-MM-dd}", domesticLawsRegulations.CompileDate); } } else { this.txtCompileMan.Text = this.CurrUser.UserName; this.dpkCompileDate.Text = string.Format("{0:yyyy-MM-dd}", DateTime.Now); } } } /// /// 上传附件资源 /// /// /// protected void btnAttachUrl_Click(object sender, EventArgs e) { PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("~/AttachFile/webuploader.aspx?toKeyId={0}&path=FileUpload/FileControl/DomesticLawsRegulations&menuId={1}&edit=0", this.DomesticLawsRegulationsId, BLL.Const.HJGLServer_DomesticLawsRegulationsMenuId))); } } }