private void GetValueFromControl(HRM_EmpFileAttach f)
        {
            f.EmpAttachKey = hfEmpFileKey.Value.ToInt();
            f.EmpKey       = EmpKey.ToInt();

            f.FileName   = txtFileName.Text;
            f.AttachDate = txtDate.Text.ToDateTime(ASL.STATIC.StaticInfo.GridDateFormat);
            f.AttachDesc = txtDescription.Text;

            f.FilePath = GetEmpFile();
        }
        protected void btnAdd_Click(object sender, EventArgs e)
        {
            var eh = new HRM_EmpFileAttach();

            GetValueFromControl(eh);
            if (!string.IsNullOrEmpty(eh.FileName) && !string.IsNullOrEmpty(eh.FilePath))
            {
                EmpFileList.Add(eh);
            }
            else
            {
                ((PageBase)(this.Page)).ErrorMessage = "File name and File path are required";
            }

            Page page = null;

            page = ((Page)this.Page);

            if (page != null)
            {
                page.ClientScript.RegisterClientScriptBlock(GetType(), "selectedtab", "selectedtab=5", true);
            }
        }
예제 #3
0
 public CustomList <HRM_EmpFileAttach> GetAllEmpfile()
 {
     return(HRM_EmpFileAttach.GetAllHRM_EmpFileAttach());
 }
예제 #4
0
 public CustomList <HRM_EmpFileAttach> GetAllEmpfileByEmpKey(string EmpKey)
 {
     return(HRM_EmpFileAttach.GetAllEmpfileByEmpKey(EmpKey));
 }
예제 #5
0
 public HRM_EmpFileAttach GetEmpfileByEmpKey(long empKey)
 {
     return(HRM_EmpFileAttach.GetEmpfileByEmpKey(empKey));
 }