2025-03-27 15:05:14 +08:00

65 lines
2.3 KiB
C#
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using Running = SuperMap.RealEstate.Personnel.Running;
using SuperMap.RealEstate.Web.UI;
namespace SuperMap.RealEstate.Personnel.Compents.Employ
{
public partial class EMPLOY : UserControl<Running.Business.EMPLOY>
{
Running.Business.PERSONNELPROINST _PERSONNELPROINST = null;
#region ->
protected void Page_Load(object sender, EventArgs e)
{
}
#endregion
#region ->
protected override void OnInit(EventArgs e)
{
Common.PageHelper.CreateHeaderStyle(Page);
_PERSONNELPROINST = Running.Business.PERSONNELPROINST.CreateInstance(Page);
base.ButtonVisible = true;
base.OnInit(e);
}
#endregion
#region ->
public override bool LoadData()
{
Running.Business.EMPLOY _EMPLOY = new Running.Business.EMPLOY(_PERSONNELPROINST);
_EMPLOY.AddSearchParameter("PERSONNELPROINST_ID", _PERSONNELPROINST.PERSONNELPROINST_ID);
if (_EMPLOY.Search())
{
CurrObject.EMPLOY_ID_Encrypt = _EMPLOY.EMPLOY_ID_Encrypt;
bool isresult= this.Select();
PERSONNELPROINST_ID.Text = CurrObject.PERSONNELPROINST_ID.ToString();
return isresult;
}
else
{
PERSONNELPROINST_ID.Text = _PERSONNELPROINST.PERSONNELPROINST_ID.ToString();
}
//默认返回值工作流组件返回True,功能模块返回False。
return (WorkFlowPage != null);
}
#endregion
#region ->
//OnDataAction_XXXXX 有一个系列可用,在此加入界面的逻辑处理
//e.CancelDataAction 来处理是否取消该动作;
//失败的原因可以用Page.Alert()传递到页面
public override void OnDataAction_BeforeSave(DataActionEventArgs<Running.Business.EMPLOY> e)
{
CurrObject.CREATE_DATE = DateTime.Now;
CurrObject.PERSONNELPROINST_ID = Convert.ToInt32(PERSONNELPROINST_ID.Text);
base.OnDataAction_BeforeSave(e);
}
#endregion
}
}