Example #1
0
        public EmployeeResignVO GetByID(int id)
        {
            EmployeeResignVO vo = new EmployeeResignVO();
            DataTable        dt = Select("ID=" + id + "");

            if (dt.Rows.Count > 0)
            {
                vo = b.ConvertObj(dt.Rows[0], new EmployeeResignVO()) as EmployeeResignVO;
            }
            return(vo);
        }
Example #2
0
        public int Create(EmployeeResignVO vo)
        {
            int id;

            if (!dao.isExist(vo.Id.ToString()))
            {
                id = dao.Insert(vo);
            }
            else
            {
                id = dao.Update(vo);
            }
            return(id);
        }
Example #3
0
        public int Insert(EmployeeResignVO vo)
        {
            int lastInsertId = 0;

            try
            {
                lastInsertId = b.Insert("Employee_Resign", b.ConvertColName(vo), b.ConvertValueList(vo));
            }
            catch (SqlException ex)
            {
                throw ex;
            }
            return(lastInsertId);
        }
Example #4
0
        public int Update(EmployeeResignVO vo)
        {
            int AssetID = 0;

            try
            {
                b.Update("Employee_Resign", vo.Id.ToString(), b.ConvertColName(vo), b.ConvertValueList(vo));
                AssetID = vo.Id;
            }
            catch (SqlException ex)
            {
                throw ex;
            }
            return(AssetID);
        }