Ejemplo n.º 1
0
        public HumanResource GetHumanResourceInformation()
        {
            var rowHuman =
                    sqlHelper.GetDataRow("select * from CompanyCategoryContent where CompanyId =" + Strings.Company.HumanResourceCompanyId);

            var humanResource = new HumanResource()
            {
                Id = Convert.ToInt32(Strings.Company.HumanResourceCompanyId),
                Description = rowHuman["Description"].ToString(),
                ImageUrl = rowHuman["ImageUrl"].ToString(),
                Title = rowHuman["Title"].ToString()
            };

            return humanResource;
        }
Ejemplo n.º 2
0
        public void UpdateHumanResourceInformation(HumanResource humanResourceItem)
        {
            const string sqlInsert =
                "Update CompanyCategoryContent set Title=@Title , Description=@Description ,ImageUrl=@ImageUrl where CompanyId = @CompanyId";

            SqlParameter[] sqlParamArray =
                {
                    new SqlParameter("@Title", SqlDbType.NVarChar)
                        {
                            Value =
                                humanResourceItem.Title
                        },
                    new SqlParameter("@Description", SqlDbType.NVarChar)
                        {
                            Value =
                                humanResourceItem
                                .Description
                        },
                    new SqlParameter("@ImageUrl", SqlDbType.NVarChar)
                        {
                            Value =
                                humanResourceItem
                                .ImageUrl
                        },
                    new SqlParameter("@CompanyId", SqlDbType.Int)
                        {
                            Value =
                                Strings
                                .Company
                                .HumanResourceCompanyId
                        }
                };

            sqlHelper.Cmd(sqlInsert, sqlParamArray);
        }
Ejemplo n.º 3
0
 public void UpdateHumanResourceInformation(HumanResource humanResourceItem)
 {
     _companyRepository.UpdateHumanResourceInformation(humanResourceItem);
 }