/// <summary> /// 删除面试评测要素信息 /// </summary> /// <param name="elemID">要素ID</param> /// <returns></returns> public static bool DeleteRectCheckElemInfo(string elemID) { //执行删除操作 bool isSucc = RectCheckElemDBHelper.DeleteRectCheckElemInfo(elemID); //定义变量 string remark; //成功时 if (isSucc) { //设置操作成功标识 remark = ConstUtil.LOG_PROCESS_SUCCESS; } else { //设置操作成功标识 remark = ConstUtil.LOG_PROCESS_FAILED; } //操作日志 LogInfoModel logModel = InitLogInfo(elemID); //涉及关键元素 这个需要根据每个页面具体设置,本页面暂时设置为空 logModel.Element = ConstUtil.LOG_PROCESS_DELETE; //设置操作成功标识 logModel.Remark = remark; //登陆日志 LogDBHelper.InsertLog(logModel); return(isSucc); }
/// <summary> /// 校验面试评测要素是否被引用 /// </summary> /// <param name="elemID">要素ID</param> /// <returns></returns> public static bool IsRectCheckElemUsed(string elemID) { UserInfoUtil userInfo = (UserInfoUtil)SessionUtil.Session["UserInfo"]; //获取公司代码 string CompanyCD = userInfo.CompanyCD; //执行删除操作 bool isSucc = RectCheckElemDBHelper.IsRectCheckElemUsed(elemID, CompanyCD); return(isSucc); }
/// <summary> /// 查询面试评测要素信息 /// </summary> /// <param name="deptID">组织机构ID</param> /// <returns></returns> public static DataTable SearchRectCheckElemInfo(RectCheckElemModel model) { //获取登陆用户信息 UserInfoUtil userInfo = (UserInfoUtil)SessionUtil.Session["UserInfo"]; //获取公司代码 model.CompanyCD = userInfo.CompanyCD; //执行查询 return(RectCheckElemDBHelper.SearchCheckElemInfo(model)); }
/// <summary> /// 编辑面试评测要素信息 /// </summary> /// <param name="model">保存信息</param> /// <returns></returns> public static bool SaveRectCheckElemInfo(RectCheckElemModel model) { //获取登陆用户信息 UserInfoUtil userInfo = (UserInfoUtil)SessionUtil.Session["UserInfo"]; //设置公司代码 model.CompanyCD = userInfo.CompanyCD; //设置最后修改者 model.ModifiedUserID = userInfo.UserID; //定义返回变量 bool isSucc = false; //操作日志 LogInfoModel logModel = InitLogInfo(model.ID); //更新 if (ConstUtil.EDIT_FLAG_UPDATE.Equals(model.EditFlag)) { try { logModel.Element = ConstUtil.LOG_PROCESS_UPDATE; //执行更新操作 isSucc = RectCheckElemDBHelper.UpdateCheckElemInfo(model); } catch (Exception ex) { //输出系统日志 WriteSystemLog(userInfo, ex); } } //插入 else { try { logModel.Element = ConstUtil.LOG_PROCESS_INSERT; //执行插入操作 isSucc = RectCheckElemDBHelper.InsertCheckElemInfo(model); logModel.ObjectID = model.ID; } catch (Exception ex) { //输出系统日志 WriteSystemLog(userInfo, ex); } } //更新成功时 if (isSucc) { //设置操作成功标识 logModel.Remark = ConstUtil.LOG_PROCESS_SUCCESS; } //更新不成功 else { //设置操作成功标识 logModel.Remark = ConstUtil.LOG_PROCESS_FAILED; } //登陆日志 LogDBHelper.InsertLog(logModel); return(isSucc); }
/// <summary> /// 查询面试评测要素信息 /// </summary> /// <param name="elemID">要素ID</param> /// <returns></returns> public static DataTable GetRectCheckElemInfoWithID(string elemID) { return(RectCheckElemDBHelper.GetCheckElemInfoWithID(elemID)); }