Пример #1
0
        /// <summary>
        /// 编辑
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        void UCPersonnelManager_EditEvent(object sender, EventArgs e)
        {
            if (dgvUser.CurrentRow == null)
            {
                MessageBoxEx.Show("请选择编辑记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
                return;
            }
            UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();

            UCPersonnelAddOrEdit.uc      = this;
            UCPersonnelAddOrEdit.wStatus = WindowStatus.Edit;
            UCPersonnelAddOrEdit.id      = dgvUser.CurrentRow.Cells["user_id"].Value.ToString(); //参数 人员管理ID
            base.addUserControl(UCPersonnelAddOrEdit, "人员管理-编辑", "RoleEdit" + UCPersonnelAddOrEdit.id, this.Tag.ToString(), this.Name);
        }
Пример #2
0
 /// <summary> 转到添加页
 /// </summary>
 void UCPersonnelManager_AddEvent(object sender, EventArgs e)
 {
     try
     {
         UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
         UCPersonnelAddOrEdit.uc = this;
         UCPersonnelAddOrEdit.wStatus = WindowStatus.Add;
         base.addUserControl(UCPersonnelAddOrEdit, "人员管理-新增", "UCPersonnelAdd", this.Tag.ToString(), this.Name);
     }
     catch (Exception ex)
     {
         GlobalStaticObj_Server.GlobalLogService.WriteLog("人员管理", ex);
         MessageBoxEx.ShowWarning("程序异常");
     }
 }
Пример #3
0
 /// <summary> 转到添加页
 /// </summary>
 void UCPersonnelManager_AddEvent(object sender, EventArgs e)
 {
     try
     {
         UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
         UCPersonnelAddOrEdit.uc      = this;
         UCPersonnelAddOrEdit.wStatus = WindowStatus.Add;
         base.addUserControl(UCPersonnelAddOrEdit, "人员管理-新增", "UCPersonnelAdd", this.Tag.ToString(), this.Name);
     }
     catch (Exception ex)
     {
         GlobalStaticObj_Server.GlobalLogService.WriteLog("人员管理", ex);
         MessageBoxEx.ShowWarning("程序异常");
     }
 }
Пример #4
0
        /// <summary>
        /// 转到添加页
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        void UCPersonnelManager_AddEvent(object sender, EventArgs e)
        {
            UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
            DataRowView          drv = tvCompany.SelectedNode.Tag as DataRowView;

            if (drv == null)
            {
                MessageBoxEx.Show("请选择所属公司");
                return;
            }
            UCPersonnelAddOrEdit.comid   = drv["id"].ToString();   //选中公司
            UCPersonnelAddOrEdit.comName = drv["name"].ToString(); //选中公司
            UCPersonnelAddOrEdit.uc      = this;
            UCPersonnelAddOrEdit.wStatus = WindowStatus.Add;
            base.addUserControl(UCPersonnelAddOrEdit, "人员管理-新增", "UCPersonnelAdd", this.Tag.ToString(), this.Name);
        }
Пример #5
0
 /// <summary> 编辑
 /// </summary>
 void UCPersonnelManager_EditEvent(object sender, EventArgs e)
 {
     if (dgvUser.CurrentRow == null)
     {
         MessageBoxEx.Show("请选择编辑记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
         return;
     }
     try
     {
         UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
         UCPersonnelAddOrEdit.uc      = this;
         UCPersonnelAddOrEdit.wStatus = WindowStatus.Edit;
         UCPersonnelAddOrEdit.userid  = dgvUser.CurrentRow.Cells["user_id"].Value.ToString(); //参数 人员管理ID
         base.addUserControl(UCPersonnelAddOrEdit, "人员管理-编辑", "UCPersonnelEdit" + UCPersonnelAddOrEdit.userid, this.Tag.ToString(), this.Name);
     }
     catch (Exception ex)
     {
         GlobalStaticObj_Server.GlobalLogService.WriteLog("人员管理", ex);
         MessageBoxEx.ShowWarning("程序异常");
     }
 }
Пример #6
0
 /// <summary> 编辑
 /// </summary> 
 void UCPersonnelManager_EditEvent(object sender, EventArgs e)
 {
     if (dgvUser.CurrentRow == null)
     {
         MessageBoxEx.Show("请选择编辑记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
         return;
     }
     try
     {
         UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
         UCPersonnelAddOrEdit.uc = this;
         UCPersonnelAddOrEdit.wStatus = WindowStatus.Edit;
         UCPersonnelAddOrEdit.userid = dgvUser.CurrentRow.Cells["user_id"].Value.ToString();  //参数 人员管理ID
         base.addUserControl(UCPersonnelAddOrEdit, "人员管理-编辑", "UCPersonnelEdit" + UCPersonnelAddOrEdit.userid, this.Tag.ToString(), this.Name);
     }
     catch (Exception ex)
     {
         GlobalStaticObj_Server.GlobalLogService.WriteLog("人员管理", ex);
         MessageBoxEx.ShowWarning("程序异常");
     }
 }
Пример #7
0
 /// <summary>
 /// 转到添加页
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 void UCPersonnelManager_AddEvent(object sender, EventArgs e)
 {
     UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
     DataRowView drv = tvCompany.SelectedNode.Tag as DataRowView;
     if (drv == null)
     {
         MessageBoxEx.Show("请选择所属公司");
         return;
     }
     UCPersonnelAddOrEdit.comid = drv["id"].ToString();//选中公司
     UCPersonnelAddOrEdit.comName = drv["name"].ToString();//选中公司
     UCPersonnelAddOrEdit.uc = this;
     UCPersonnelAddOrEdit.wStatus = WindowStatus.Add;
     base.addUserControl(UCPersonnelAddOrEdit, "人员管理-新增", "UCPersonnelAdd", this.Tag.ToString(), this.Name);
 }
Пример #8
0
 /// <summary>
 /// 编辑
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 void UCPersonnelManager_EditEvent(object sender, EventArgs e)
 {
     if (dgvUser.CurrentRow == null)
     {
         MessageBoxEx.Show("请选择编辑记录!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information);
         return;
     }
     UCPersonnelAddOrEdit UCPersonnelAddOrEdit = new UCPersonnelAddOrEdit();
     UCPersonnelAddOrEdit.uc = this;
     UCPersonnelAddOrEdit.wStatus = WindowStatus.Edit;
     UCPersonnelAddOrEdit.id = dgvUser.CurrentRow.Cells["user_id"].Value.ToString();  //参数 人员管理ID
     base.addUserControl(UCPersonnelAddOrEdit, "人员管理-编辑", "RoleEdit" + UCPersonnelAddOrEdit.id, this.Tag.ToString(), this.Name);
 }