Beispiel #1
0
        private void gridView1_CellValueChanged(object sender, CellValueChangedEventArgs e)
        {
            EmpSalaryStepInput row = gridView1.GetRow(e.RowHandle) as EmpSalaryStepInput;

            if (row != null)
            {
                if (e.Column.FieldName == "员工编号")
                {
                    EmployeeInfo pInfo = EmployeeInfo.GetEmployeeInfo(row.员工编号);
                    if (pInfo == null)
                    {
                        throw new Exception("找不到指定编号的员工");
                    }
                    else
                    {
                        if (AccessController.CheckPayGroup(pInfo.薪资组))
                        {
                            row.姓名 = pInfo.姓名;
                            gridControl1.RefreshDataSource();
                        }
                        else
                        {
                            throw new Exception("您没有权限录入这个员工的工资职级");
                        }
                    }
                }
                if (e.Column.FieldName == "薪等标识")
                {
                    row.薪级标识 = 0;
                    row.薪级名称 = "";
                }
                row.GetModifiyFields();
            }
        }
Beispiel #2
0
        private void BecomeEffective(EmpSalaryStepInput input)
        {
            EmpSalaryStep m     = new EmpSalaryStep();
            EmpSalaryStep found = EmpSalaryStep.GetEmpSalaryStep(input.员工编号, input.执行日期);

            if (found != null)
            {
                m = found;
            }
            EmployeeInfo emp = EmployeeInfo.GetEmployeeInfo(input.员工编号);

            m.薪资组 = emp.薪资组;
            input.CopyWatchMember(m);

            EmpSalaryStepInput anotherInput = input.另一人录入的记录 as EmpSalaryStepInput;

            m.录入人  = !input.是验证录入 ? input.录入人 : anotherInput.录入人;
            m.录入时间 = !input.是验证录入 ? input.录入时间 : anotherInput.录入时间;
            m.验证人  = input.是验证录入 ? input.录入人 : anotherInput.录入人;
            m.验证时间 = input.是验证录入 ? input.录入时间 : anotherInput.录入时间;
            m.Save();
        }
Beispiel #3
0
 public ActionResult Index()
 {
     return(View(obj.GetEmployeeInfo()));
 }