public BusinessPhoneDTO Create(BusinessPhoneDTO modelDTO)
        {
            if (modelDTO != null)
            {
                return(BusinessPhoneAssembler.ToDTO(businessPhoneRepos.CreateBusinessPhone(BusinessPhoneAssembler.ToEntity(modelDTO))));
            }

            return(null);
        }
示例#2
0
        public BusinessPhoneDTO Update(BusinessPhoneDTO oBusinessPhoneDTO)
        {
            BusinessPhoneDTO returnPhone = null;

            if (oBusinessPhoneDTO != null && oBusinessPhoneDTO.PhoneID > 0)
            {
                oBusinessPhoneRepos.UpdateBusinessPhone(0, BusinessPhoneAssembler.ToEntity(oBusinessPhoneDTO));
                returnPhone = oBusinessPhoneDTO;
            }

            return(returnPhone);
        }
        public BusinessPhoneDTO Update(BusinessPhoneDTO modelDTO)
        {
            BusinessPhoneDTO returnPhone = null;

            if (modelDTO != null && modelDTO.PhoneID > 0)
            {
                businessPhoneRepos.UpdateBusinessPhone(0, BusinessPhoneAssembler.ToEntity(modelDTO));
                returnPhone = modelDTO;
            }

            return(returnPhone);
        }