private void EditSalaryStructureForm_Load(object sender, EventArgs e) { this.Text = "员工薪酬结构录入 - " + currSalaryStructureEntry.员工编号 + " - " + (currSalaryStructureEntry.是验证录入 ? "验证录入" : "初次录入"); emp = currSalaryStructureEntry.员工信息; ms = MonthlySalary.GetEffective(emp.员工编号, DateTime.Today); if (ms == null) { MessageBox.Show("找不到该员工的执行月薪标准,请录入标准后再试"); Close(); } 满勤奖标准 = PsHelper.GetFullAttendancePayFromCache(emp.薪资体系, emp.薪等, new DateTime(DateTime.Today.Year, DateTime.Today.Month, 1)); 未休年休假工资 = PsHelper.GetVacPayFromCache(emp.薪资体系, emp.薪等, new DateTime(DateTime.Today.Year, DateTime.Today.Month, 1)); 交通餐饮补助标准 = PsHelper.GetTrafficSubsidies(emp.员工编号, new DateTime(DateTime.Today.Year, DateTime.Today.Month, 1)); lbl用户.Text = currSalaryStructureEntry.员工信息.姓名; lbl员工编号.Text = currSalaryStructureEntry.员工编号; comboBoxEdit结构类型.EditValue = currSalaryStructureEntry.类型; LoadData(); }
public EmployeeSalaryStructure(EmployeeInfo empInfo) { DateTime 期间开始 = DateTime.Today; 员工信息 = empInfo; 薪酬结构 = SalaryStructure.GetEffective(empInfo.员工编号, 期间开始); 借款工资 = WageLoan.GetEffective(empInfo.员工编号, 期间开始); 报账工资 = RembursementSalary.GetEffective(empInfo.员工编号, 期间开始); 月薪标准 = MonthlySalary.GetEffective(empInfo.员工编号, 期间开始); //处理,获取相关数据 this.员工编号 = empInfo.员工编号; this.姓名 = empInfo.姓名; this.性别 = empInfo.性别; this.职务 = empInfo.职务名称; this.公司 = empInfo.公司; this.部门 = empInfo.部门名称; this.职等 = empInfo.职等; if (月薪标准 != null) { this.开始执行日期 = 月薪标准.开始执行日期; this.年薪_12个月 = 月薪标准.执行_月薪 * 12; this.年薪_合计 = 月薪标准.执行_月薪 * 12; this.月薪项目_小计 = 月薪标准.执行_月薪; } if (薪酬结构 != null) { this.结构类型 = 薪酬结构.类型; this.年薪_奖励 = 薪酬结构.年薪_奖励; this.年薪_绩效工资 = 薪酬结构.年薪_绩效工资; this.年薪_12个月 = 薪酬结构.年薪_12个月; this.年薪_合计 = 薪酬结构.年薪_合计; this.月薪项目_月工资 = 薪酬结构.月薪项目_月工资; this.月薪项目_年休假 = 薪酬结构.月薪项目_年休假; this.月薪项目_满勤奖 = 薪酬结构.月薪项目_满勤奖; this.月薪项目_交通餐饮补贴 = 薪酬结构.月薪项目_交通餐饮补贴; this.月薪项目_小计 = 薪酬结构.月薪项目_小计; this.月薪项目_减项_绩效工资 = 薪酬结构.月薪项目_减项_绩效工资; this.开始执行日期 = 薪酬结构.开始执行日期; } else { this.结构类型 = "标准"; this.年薪_奖励 = 0; this.月薪项目_交通餐饮补贴 = PsHelper.GetTrafficSubsidies(员工编号, 期间开始); this.月薪项目_满勤奖 = PsHelper.GetFullAttendancePayFromCache(empInfo.薪资体系, empInfo.薪等, 期间开始); this.月薪项目_年休假 = PsHelper.GetVacPayFromCache(empInfo.薪资体系, empInfo.薪等, 期间开始); this.月薪项目_月工资 = 月薪项目_小计 - 月薪项目_满勤奖 - 月薪项目_年休假 - 月薪项目_交通餐饮补贴; } if (借款工资 != null) { 月薪项目_减项_工资借款 = 借款工资.月借款额度; } if (报账工资 != null) { 月薪项目_减项_报账工资 = 报账工资.月度可报账标准_税前; } }