毕业论文

打赏
当前位置: 毕业论文 > 计算机论文 >

C#公司考勤管理系统的设计实现+流程图+ER图(11)

时间:2016-11-23 19:05来源:毕业论文
3.4.4 请假登记管理 图10 请假登记管理 调班换班信息的添加、删除、修改的业务逻辑实现如下所示: var LeaveObject = _DbEntities.Leave.SingleOrDefault(p = p.L_ID == th


3.4.4    请假登记管理
图10 请假登记管理
    调班换班信息的添加、删除、修改的业务逻辑实现如下所示:
               var LeaveObject = _DbEntities.Leave.SingleOrDefault(p => p.L_ID == this.textBox1.Text.Trim());
                if (LeaveObject != null)
                {
                    LeaveObject.L_UserName = this.comboBox1.SelectedValue.ToString();
                    LeaveObject.L_XingMing = this.comboBox1.Text;
                    LeaveObject.L_Time = this.dateTimePicker1.Value;
                    LeaveObject.L_Sh = this.comboBox2.Text;
                    LeaveObject.L_Type = "请假";
                    LeaveObject.L_Yy = this.textBox2.Text;

                    try
                    {
                        _DbEntities.SaveChanges();

                        MessageBox.Show("保存成功!");

                        BindDataForGridView();
                        return;
                    }
                    catch
                    {
                        MessageBox.Show("保存失败!");
                        return;
                    }
                }
                else
                {
                    MessageBox.Show("保存失败!");
                    return;
                } C#公司考勤管理系统的设计实现+流程图+ER图(11):http://www.751com.cn/jisuanji/lunwen_195.html
------分隔线----------------------------
推荐内容