mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-04 13:06:50 +00:00
refactor: add SqlKata for SQL generation, move connection handling into ModelRepository
This commit is contained in:
parent
6251d29abb
commit
92e45a07ff
60 changed files with 806 additions and 640 deletions
|
|
@ -40,10 +40,10 @@ namespace PluralKit.Core
|
|||
o.Add("avatar_url", system.AvatarUrl);
|
||||
o.Add("timezone", system.UiTz);
|
||||
o.Add("created", system.Created.FormatExport());
|
||||
o.Add("accounts", new JArray((await _repo.GetSystemAccounts(conn, system.Id)).ToList()));
|
||||
o.Add("members", new JArray((await _repo.GetSystemMembers(conn, system.Id).ToListAsync()).Select(m => m.ToJson(LookupContext.ByOwner))));
|
||||
o.Add("accounts", new JArray((await _repo.GetSystemAccounts(system.Id)).ToList()));
|
||||
o.Add("members", new JArray((await _repo.GetSystemMembers(system.Id).ToListAsync()).Select(m => m.ToJson(LookupContext.ByOwner))));
|
||||
|
||||
var groups = (await _repo.GetSystemGroups(conn, system.Id).ToListAsync());
|
||||
var groups = (await _repo.GetSystemGroups(system.Id).ToListAsync());
|
||||
var j_groups = groups.Select(x => x.ToJson(LookupContext.ByOwner, isExport: true)).ToList();
|
||||
|
||||
if (groups.Count > 0)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue