1
0
mirror of https://github.com/bitwarden/server synced 2026-01-05 18:13:31 +00:00

validate organization licenses

This commit is contained in:
Kyle Spearrin
2017-08-17 00:12:11 -04:00
parent 127ff2d361
commit 4585af5a85
9 changed files with 64 additions and 19 deletions

View File

@@ -19,6 +19,18 @@ namespace Bit.Core.Repositories.SqlServer
: base(connectionString)
{ }
public async Task<ICollection<Organization>> GetManyAsync()
{
using(var connection = new SqlConnection(ConnectionString))
{
var results = await connection.QueryAsync<Organization>(
"[dbo].[Organization_Read]",
commandType: CommandType.StoredProcedure);
return results.ToList();
}
}
public async Task<ICollection<Organization>> GetManyByUserIdAsync(Guid userId)
{
using(var connection = new SqlConnection(ConnectionString))