79 lines
2.9 KiB
C#
79 lines
2.9 KiB
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Web;
|
|
using System.Web.UI;
|
|
using System.Web.UI.WebControls;
|
|
|
|
namespace FineUIPro.Web.PublicInfo.FileControl
|
|
{
|
|
public partial class CompanyStandardsView : PageBase
|
|
{
|
|
#region 定义变量
|
|
/// <summary>
|
|
/// 主键
|
|
/// </summary>
|
|
private string CompanyStandardsId
|
|
{
|
|
get
|
|
{
|
|
return (string)ViewState["CompanyStandardsId"];
|
|
}
|
|
set
|
|
{
|
|
ViewState["CompanyStandardsId"] = value;
|
|
}
|
|
}
|
|
#endregion
|
|
|
|
#region 加载
|
|
/// <summary>
|
|
///加载页面
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void Page_Load(object sender, EventArgs e)
|
|
{
|
|
if (!IsPostBack)
|
|
{
|
|
this.btnClose.OnClientClick = ActiveWindow.GetHideReference();
|
|
this.CompanyStandardsId = Request.Params["CompanyStandardsId"];
|
|
if (!string.IsNullOrEmpty(this.CompanyStandardsId))
|
|
{
|
|
Model.FileControl_CompanyStandards companyStandards = BLL.FileControl_CompanyStandardsService.GetCompanyStandardsById(this.CompanyStandardsId);
|
|
if (companyStandards != null)
|
|
{
|
|
this.txtCompanyStandardsCode.Text = companyStandards.CompanyStandardsCode;
|
|
this.txtCompanyStandardsName.Text = companyStandards.CompanyStandardsName;
|
|
this.txtAbstract.Text = companyStandards.Abstract;
|
|
if (!string.IsNullOrEmpty(companyStandards.CompileMan))
|
|
{
|
|
this.txtCompileManName.Text = BLL.Sys_UserService.GetUserNameByUserId(companyStandards.CompileMan);
|
|
}
|
|
if (companyStandards.CompileDate.HasValue)
|
|
{
|
|
this.txtCompileDate.Text = string.Format("{0:yyyy-MM-dd}", companyStandards.CompileDate);
|
|
}
|
|
this.txtRemark.Text = companyStandards.Remarks;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
#endregion
|
|
|
|
#region 附件上传
|
|
/// <summary>
|
|
/// 上传附件资源
|
|
/// </summary>
|
|
/// <param name="sender"></param>
|
|
/// <param name="e"></param>
|
|
protected void btnAttachUrl_Click(object sender, EventArgs e)
|
|
{
|
|
if (!string.IsNullOrEmpty(this.CompanyStandardsId))
|
|
{
|
|
PageContext.RegisterStartupScript(WindowAtt.GetShowReference(String.Format("~/AttachFile/webuploader.aspx?toKeyId={0}&path=FileUpload/FileControl/CompanyStandards&menuId={1}&edit=0", this.CompanyStandardsId, BLL.Const.CompanyStandardsMenuId)));
|
|
}
|
|
}
|
|
#endregion
|
|
}
|
|
} |