251 lines
10 KiB
Go
251 lines
10 KiB
Go
// Code generated by concurry DO NOT EDIT.
|
|
// https://github.com/angelbeltran/concurry
|
|
// concurry
|
|
package accounts
|
|
|
|
import (
|
|
"context"
|
|
"github.com/google/uuid"
|
|
"github.com/jackc/pgx/v5"
|
|
)
|
|
|
|
type StoreWithContext struct {
|
|
ctx context.Context
|
|
*Store
|
|
}
|
|
|
|
func NewStoreWithContext(ctx context.Context, v *Store) *StoreWithContext {
|
|
return &StoreWithContext{
|
|
ctx: ctx,
|
|
Store: v,
|
|
}
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CreateAccount(userID string, email string) (Account, error) {
|
|
return v_ctx.Store.CreateAccount(v_ctx.ctx, userID, email)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetAccount(id int64) (Account, error) {
|
|
return v_ctx.Store.GetAccount(v_ctx.ctx, id)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetAccountByUserID(userID string) (Account, error) {
|
|
return v_ctx.Store.GetAccountByUserID(v_ctx.ctx, userID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetAccountByEmail(email string) (Account, error) {
|
|
return v_ctx.Store.GetAccountByEmail(v_ctx.ctx, email)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetUserAndAccountByAccessToken(accessToken string) (OAuthUser, *Account, error) {
|
|
return v_ctx.Store.GetUserAndAccountByAccessToken(v_ctx.ctx, accessToken)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetShops(acctID int64) ([]AccountShop, error) {
|
|
return v_ctx.Store.GetShops(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockShops(acctID int64) ([]AccountShop, error) {
|
|
return v_ctx.Store.GetMockShops(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetListingsForShop(acctID int64, platform Platform, shopID string) ([]Listing, error) {
|
|
return v_ctx.Store.GetListingsForShop(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockListingsForShop(acctID int64, platform Platform, shopID string) ([]Listing, error) {
|
|
return v_ctx.Store.GetMockListingsForShop(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockListing(acctID int64, platform Platform, shopID string, listingID string) (*Listing, error) {
|
|
return v_ctx.Store.GetMockListing(v_ctx.ctx, acctID, platform, shopID, listingID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) DeleteMockSyncGroup(acctID int64, syncGroupID int64) error {
|
|
return v_ctx.Store.DeleteMockSyncGroup(v_ctx.ctx, acctID, syncGroupID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) StartEditingMockSyncGroup(acctID int64, syncGroupID int64) (int64, bool, error) {
|
|
return v_ctx.Store.StartEditingMockSyncGroup(v_ctx.ctx, acctID, syncGroupID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SaveMockSyncGroupBeingEdited(acctID int64) (int64, error) {
|
|
return v_ctx.Store.SaveMockSyncGroupBeingEdited(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CancelEditingOfMockSyncGroupForAccount(acctID int64) (int64, bool, error) {
|
|
return v_ctx.Store.CancelEditingOfMockSyncGroupForAccount(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockSyncGroupEditingListings(acctID int64) ([]ListingWithOrderIndex, error) {
|
|
return v_ctx.Store.GetMockSyncGroupEditingListings(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) MockSyncGroupIsBeingEdited(acctID int64, syncGroupID int64) (bool, error) {
|
|
return v_ctx.Store.MockSyncGroupIsBeingEdited(v_ctx.ctx, acctID, syncGroupID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockSyncGroupEditingListing(acctID int64, syncGroupID int64, orderIndex int64) (*Listing, error) {
|
|
return v_ctx.Store.GetMockSyncGroupEditingListing(v_ctx.ctx, acctID, syncGroupID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) AddListingToMockSyncGroupBeingEdited(acctID int64) (int64, int, error) {
|
|
return v_ctx.Store.AddListingToMockSyncGroupBeingEdited(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInListingInMockSyncGroupBeingEdited(acctID int64, syncGroupID int64, orderIndex int, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInListingInMockSyncGroupBeingEdited(v_ctx.ctx, acctID, syncGroupID, orderIndex, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetListingInListingInMockSyncGroupBeingEdited(acctID int64, syncGroupID int64, orderIndex int, listingID string) error {
|
|
return v_ctx.Store.SetListingInListingInMockSyncGroupBeingEdited(v_ctx.ctx, acctID, syncGroupID, orderIndex, listingID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) DeleteListingInListingInMockSyncGroupBeingEdited(acctID int64, orderIndex int) error {
|
|
return v_ctx.Store.DeleteListingInListingInMockSyncGroupBeingEdited(v_ctx.ctx, acctID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInMockSaleForm(acctID int64, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInMockSaleForm(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInMockRefundForm(acctID int64, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInMockRefundForm(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInMockCountForm(acctID int64, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInMockCountForm(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockEventFormValues(acctID int64) (*MockEventFormValues, error) {
|
|
return v_ctx.Store.GetMockEventFormValues(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetAccountPointerByUserID(userID string) (*Account, error) {
|
|
return v_ctx.Store.GetAccountPointerByUserID(v_ctx.ctx, userID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) beginReadonlyTxn(cb func(pgx.Tx) error) error {
|
|
return v_ctx.Store.beginReadonlyTxn(v_ctx.ctx, cb)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) beginTxn(cb func(pgx.Tx) error) error {
|
|
return v_ctx.Store.beginTxn(v_ctx.ctx, cb)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetMockMode(acctID int64, on bool) error {
|
|
return v_ctx.Store.SetMockMode(v_ctx.ctx, acctID, on)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockMode(acctID int64) (bool, error) {
|
|
return v_ctx.Store.GetMockMode(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CreateMockShop(acctID int64, platform Platform, name string) (uuid.UUID, error) {
|
|
return v_ctx.Store.CreateMockShop(v_ctx.ctx, acctID, platform, name)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) ListMockShopsForPlatform(acctID int64, platform Platform) ([]MockShop, error) {
|
|
return v_ctx.Store.ListMockShopsForPlatform(v_ctx.ctx, acctID, platform)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockShop(acctID int64, platform Platform, shopID string) (*MockShop, error) {
|
|
return v_ctx.Store.GetMockShop(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CreateMockListing(listing MockListing) (MockListing, error) {
|
|
return v_ctx.Store.CreateMockListing(v_ctx.ctx, listing)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) UpdateMockListing(listing MockListing) error {
|
|
return v_ctx.Store.UpdateMockListing(v_ctx.ctx, listing)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) DeleteMockListing(ids AccountShopListingIDs) error {
|
|
return v_ctx.Store.DeleteMockListing(v_ctx.ctx, ids)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) ListMockListingsForShop(acctID int64, platform Platform, shopID string) ([]MockListing, error) {
|
|
return v_ctx.Store.ListMockListingsForShop(v_ctx.ctx, acctID, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetOrderOfPlatformOnAccountPage(acctID int64, platform Platform, orderIndex int) ([]Platform, int, error) {
|
|
return v_ctx.Store.SetOrderOfPlatformOnAccountPage(v_ctx.ctx, acctID, platform, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetOrderOfPlatformsOnAccountPage(acctID int64) ([]Platform, error) {
|
|
return v_ctx.Store.GetOrderOfPlatformsOnAccountPage(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetOrderOfPlatformOnAccountPage(acctID int64, platform Platform) (int, error) {
|
|
return v_ctx.Store.GetOrderOfPlatformOnAccountPage(v_ctx.ctx, acctID, platform)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CreateSyncGroupListingDraft(acctID int64) (int, error) {
|
|
return v_ctx.Store.CreateSyncGroupListingDraft(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) CreateMockSyncGroupListingDraft(acctID int64) (int, error) {
|
|
return v_ctx.Store.CreateMockSyncGroupListingDraft(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetSyncGroupListingDraft(acctID int64, orderIndex int) (SyncGroupListingDraft, error) {
|
|
return v_ctx.Store.GetSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockSyncGroupListingDraft(acctID int64, orderIndex int) (SyncGroupListingDraft, error) {
|
|
return v_ctx.Store.GetMockSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInSyncGroupListingDraft(acctID int64, orderIndex int, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetShopInMockSyncGroupListingDraft(acctID int64, orderIndex int, platform Platform, shopID string) error {
|
|
return v_ctx.Store.SetShopInMockSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex, platform, shopID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetListingInSyncGroupListingDraft(acctID int64, orderIndex int, listingID string) error {
|
|
return v_ctx.Store.SetListingInSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex, listingID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SetListingInMockSyncGroupListingDraft(acctID int64, orderIndex int, listingID string) error {
|
|
return v_ctx.Store.SetListingInMockSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex, listingID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) DeleteSyncGroupListingDraft(acctID int64, orderIndex int) (int, error) {
|
|
return v_ctx.Store.DeleteSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) DeleteMockSyncGroupListingDraft(acctID int64, orderIndex int) error {
|
|
return v_ctx.Store.DeleteMockSyncGroupListingDraft(v_ctx.ctx, acctID, orderIndex)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetSyncGroupListingDrafts(acctID int64) ([]SyncGroupListingDraft, error) {
|
|
return v_ctx.Store.GetSyncGroupListingDrafts(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockSyncGroupListingDrafts(acctID int64) ([]SyncGroupListingDraft, error) {
|
|
return v_ctx.Store.GetMockSyncGroupListingDrafts(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SaveNewSyncGroup(acctID int64) (SyncGroup, error) {
|
|
return v_ctx.Store.SaveNewSyncGroup(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) SaveNewMockSyncGroup(acctID int64, name string) (SyncGroup, error) {
|
|
return v_ctx.Store.SaveNewMockSyncGroup(v_ctx.ctx, acctID, name)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) ListMockSyncGroups(acctID int64) ([]SyncGroup, error) {
|
|
return v_ctx.Store.ListMockSyncGroups(v_ctx.ctx, acctID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) GetMockSyncGroup(acctID int64, syncGroupID int64) (*SyncGroup, error) {
|
|
return v_ctx.Store.GetMockSyncGroup(v_ctx.ctx, acctID, syncGroupID)
|
|
}
|
|
|
|
func (v_ctx *StoreWithContext) listMockSyncGroupListings(tx pgx.Tx, acctID int64, syncGroupID int64) ([]SyncGroupListing, error) {
|
|
return v_ctx.Store.listMockSyncGroupListings(v_ctx.ctx, tx, acctID, syncGroupID)
|
|
}
|