コード例 #1
0
        public virtual ApiAccountResponseModel MapBOToModel(
            BOAccount boAccount)
        {
            var model = new ApiAccountResponseModel();

            model.SetProperties(boAccount.Id, boAccount.AccountType, boAccount.EnvironmentIds, boAccount.JSON, boAccount.Name, boAccount.TenantIds, boAccount.TenantTags);

            return(model);
        }
コード例 #2
0
        public virtual BOAccount MapEFToBO(
            Account ef)
        {
            var bo = new BOAccount();

            bo.SetProperties(
                ef.Id,
                ef.AccountType,
                ef.EnvironmentIds,
                ef.JSON,
                ef.Name,
                ef.TenantIds,
                ef.TenantTags);
            return(bo);
        }
コード例 #3
0
        public virtual Account MapBOToEF(
            BOAccount bo)
        {
            Account efAccount = new Account();

            efAccount.SetProperties(
                bo.AccountType,
                bo.EnvironmentIds,
                bo.Id,
                bo.JSON,
                bo.Name,
                bo.TenantIds,
                bo.TenantTags);
            return(efAccount);
        }
コード例 #4
0
        public virtual BOAccount MapModelToBO(
            string id,
            ApiAccountRequestModel model
            )
        {
            BOAccount boAccount = new BOAccount();

            boAccount.SetProperties(
                id,
                model.AccountType,
                model.EnvironmentIds,
                model.JSON,
                model.Name,
                model.TenantIds,
                model.TenantTags);
            return(boAccount);
        }