mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
Merge branch '1.5.x' of https://github.com/appwrite/console into fix-wizards-copy
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import type { Client, Models, Query } from '@appwrite.io/console';
|
||||
import type { Client, Models } from '@appwrite.io/console';
|
||||
import type { Organization } from '../stores/organization';
|
||||
import type { PaymentMethod } from '@stripe/stripe-js';
|
||||
import type { Tier } from '$lib/stores/billing';
|
||||
@@ -849,7 +849,7 @@ export class Billing {
|
||||
);
|
||||
}
|
||||
|
||||
async listAddresses(queries: Query[] = []): Promise<AddressesList> {
|
||||
async listAddresses(queries: string[] = []): Promise<AddressesList> {
|
||||
const path = `/account/billing-addresses`;
|
||||
const params = {
|
||||
queries
|
||||
|
||||
@@ -78,7 +78,7 @@
|
||||
},
|
||||
...permanentTabSettings
|
||||
]
|
||||
: permanentTabs;
|
||||
: [...permanentTabs, ...permanentTabSettings];
|
||||
</script>
|
||||
|
||||
{#if $organization?.$id}
|
||||
|
||||
@@ -99,4 +99,6 @@
|
||||
{/if}
|
||||
</Container>
|
||||
|
||||
<Delete bind:showDelete invoices={data.invoices} />
|
||||
{#if isCloud && data.invoices}
|
||||
<Delete bind:showDelete invoices={data.invoices} />
|
||||
{/if}
|
||||
|
||||
@@ -2,12 +2,14 @@ import type { PageLoad } from './$types';
|
||||
import { Dependencies } from '$lib/constants';
|
||||
import { sdk } from '$lib/stores/sdk';
|
||||
import { Query } from '@appwrite.io/console';
|
||||
import { isCloud } from '$lib/system';
|
||||
|
||||
export const load: PageLoad = async ({ depends, parent }) => {
|
||||
const { organization } = await parent();
|
||||
depends(Dependencies.ORGANIZATION);
|
||||
|
||||
return {
|
||||
projects: await sdk.forConsole.projects.list([Query.equal('teamId', organization.$id)]),
|
||||
invoices: await sdk.forConsole.billing.listInvoices(organization.$id)
|
||||
invoices: isCloud ? await sdk.forConsole.billing.listInvoices(organization.$id) : undefined
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user