Skip to content

Commit affe070

Browse files
authored
Merge pull request #38 from engagepeople/feature/account_management
Account Management Updates
2 parents a3bff92 + 728f7cb commit affe070

File tree

4 files changed

+15
-5
lines changed

4 files changed

+15
-5
lines changed

dist/index.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/Api/Shop/Cart.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,18 +10,26 @@ export class ShopCart extends Resource {
1010
this.SetResource('shoppingCart')
1111
}
1212

13-
public Confirm(cartId: number, addressId: number, ledgerId: number): IPodiumPromise<IAPIResponse[]> {
13+
public Confirm(cartId: number,
14+
addressId: number,
15+
ledgerId: number,
16+
accountId: number): IPodiumPromise<IAPIResponse[]> {
1417
this.SetResourceOnce(`shoppingCart/confirm`)
1518
return this.Create({
19+
account_id: accountId,
1620
address_id: addressId,
1721
ledger_id: ledgerId,
1822
shopping_cart_id: cartId,
1923
})
2024
}
2125

22-
public Checkout(cartId: number, addressId: number, ledgerId: number): IPodiumPromise<IAPIResponse[]> {
26+
public Checkout(cartId: number,
27+
addressId: number,
28+
ledgerId: number,
29+
accountId: number): IPodiumPromise<IAPIResponse[]> {
2330
this.SetResourceOnce(`shoppingCart/checkout`)
2431
return this.Create({
32+
account_id: accountId,
2533
address_id: addressId,
2634
ledger_id: ledgerId,
2735
shopping_cart_id: cartId,

src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ export {Filter as PodiumFilter} from './Podium/Filter'
1515
export {Paginator as PodiumPaginator} from './Podium/Paginator'
1616

1717
export class Podium {
18+
public Account: Resource
1819
public Auth: Auth
1920
public Ecards: {
2021
Categories: Resource
@@ -46,6 +47,7 @@ export class Podium {
4647
public Utils: Utils
4748

4849
constructor(settings: Settings) {
50+
this.Account = new Resource(settings).SetResource('member/account')
4951
this.Auth = new Auth(settings)
5052
this.Discretionary = {
5153
DirectReports: new Resource(settings).SetResource('user/reports'),

0 commit comments

Comments
 (0)