admin
8 months ago
common
9 months ago
components
8 months ago
constants
8 months ago
hooks
9 months ago
admin-subscriptions.tsx
1 year ago
entity.ts
8 months ago
types.ts
9 months ago
utils.ts
8 months ago
entity.ts
23 lines
| 1 | import {store as coreStore} from '@wordpress/core-data'; |
| 2 | import {dispatch} from '@wordpress/data'; |
| 3 | import {__} from '@wordpress/i18n'; |
| 4 | |
| 5 | /** |
| 6 | * @since 4.13.0 added anonymousDonors to baseURLParams |
| 7 | * @since 4.11.0 Added gatewaySubscriptionId to baseURLParams |
| 8 | * @since 4.10.0 added _embed |
| 9 | * @since 4.8.0 |
| 10 | */ |
| 11 | //@ts-ignore |
| 12 | dispatch(coreStore).addEntities([ |
| 13 | { |
| 14 | name: 'subscription', |
| 15 | kind: 'givewp', |
| 16 | baseURL: '/givewp/v3/subscriptions', |
| 17 | baseURLParams: {_embed: true, includeSensitiveData: true, anonymousDonors: 'include'}, |
| 18 | plural: 'subscriptions', |
| 19 | label: __('Subscription', 'give'), |
| 20 | supportsPagination: true, |
| 21 | }, |
| 22 | ]); |
| 23 |