示例#1
0
        public async Task <ProductEntityDomain> GetProductAsync(string id)
        {
            var resultData = await _productSqlDataContext.Connection.GetAsync <ProductEntityData>(id);

            return(ProductEntityData.ToEntityDomain(resultData));
        }
示例#2
0
        public async Task <List <ProductEntityDomain> > GetAllProductsAsync()
        {
            var resultData = await _productSqlDataContext.Connection.GetAllAsync <ProductEntityData>();

            return(resultData.Select(r => ProductEntityData.ToEntityDomain(r)).ToList());
        }