@reeboot/strapi-payment-plugin 0.0.4 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{Analytics-nBSdLT2v.js → Analytics-CLjtRWYA.js} +68 -51
- package/dist/_chunks/{Analytics-DSJqY9ng.mjs → Analytics-CQmAVKsq.mjs} +68 -51
- package/dist/_chunks/App-DXN62SV6.mjs +118 -0
- package/dist/_chunks/App-Dk7XtjNA.js +120 -0
- package/dist/_chunks/{Customers-BpFzfglV.js → Customers-BNDi4QBH.js} +113 -51
- package/dist/_chunks/{Customers-C6FH7-zG.mjs → Customers-BQzVBQDT.mjs} +114 -52
- package/dist/_chunks/Dashboard-CuHC-dit.mjs +311 -0
- package/dist/_chunks/Dashboard-UUwohHZa.js +311 -0
- package/dist/_chunks/{Orders-CBkT2YfP.mjs → Orders-65mNfu2i.mjs} +140 -80
- package/dist/_chunks/{Orders-OG-pwV-B.js → Orders-CitNCdWE.js} +139 -79
- package/dist/_chunks/PaymentList-B0CAzInT.mjs +137 -0
- package/dist/_chunks/PaymentList-Dy1BAFoD.js +136 -0
- package/dist/_chunks/{Payments-DSDJ-HWm.mjs → Payments-FnhoV_2B.mjs} +175 -136
- package/dist/_chunks/{Payments-BLen1P9N.js → Payments-TOnygGIW.js} +173 -134
- package/dist/_chunks/Settings-BJtDagUs.js +644 -0
- package/dist/_chunks/Settings-EoLSuZLe.mjs +644 -0
- package/dist/_chunks/{index-DS_PYNkf.mjs → index-2Zd_T7bD.mjs} +1 -1
- package/dist/_chunks/{index-BqqrpI6D.js → index-CHEgJ7e5.js} +1 -1
- package/dist/admin/index.js +1 -1
- package/dist/admin/index.mjs +1 -1
- package/dist/admin/src/components/CustomerList.d.ts +1 -13
- package/dist/admin/src/components/IntegrationModal.d.ts +7 -0
- package/dist/admin/src/components/OrderList.d.ts +1 -19
- package/dist/admin/src/components/PaymentCard.d.ts +2 -33
- package/dist/admin/src/components/PaymentList.d.ts +3 -11
- package/dist/admin/src/components/RefundModal.d.ts +2 -8
- package/dist/admin/src/types/index.d.ts +47 -0
- package/dist/server/index.js +241 -96
- package/dist/server/index.mjs +241 -96
- package/dist/server/src/content-types/index.d.ts +9 -2
- package/dist/server/src/content-types/order/index.d.ts +8 -1
- package/dist/server/src/content-types/payment/index.d.ts +1 -1
- package/dist/server/src/index.d.ts +9 -2
- package/dist/server/src/types/api.d.ts +31 -0
- package/dist/server/src/types/customer.d.ts +2 -0
- package/dist/server/src/types/index.d.ts +4 -179
- package/dist/server/src/types/order.d.ts +2 -0
- package/dist/server/src/types/payment.d.ts +2 -0
- package/package.json +8 -7
- package/dist/_chunks/App-B83DZ9NG.js +0 -70
- package/dist/_chunks/App-BUSTbkyy.mjs +0 -68
- package/dist/_chunks/Dashboard-CNMTzSyc.js +0 -180
- package/dist/_chunks/Dashboard-Dbwl0ZBo.mjs +0 -180
- package/dist/_chunks/Settings-Dq1xy32B.js +0 -357
- package/dist/_chunks/Settings-jmGslDsB.mjs +0 -357
- package/dist/admin/src/pages/HomePage.d.ts +0 -2
package/dist/admin/index.js
CHANGED
package/dist/admin/index.mjs
CHANGED
|
@@ -1,17 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
id: string;
|
|
4
|
-
stripeCustomerId: string;
|
|
5
|
-
email: string;
|
|
6
|
-
firstName?: string;
|
|
7
|
-
lastName?: string;
|
|
8
|
-
totalSpent: number;
|
|
9
|
-
currency: string;
|
|
10
|
-
paymentCount: number;
|
|
11
|
-
lastPaymentDate?: string;
|
|
12
|
-
isActive: boolean;
|
|
13
|
-
registrationDate: string;
|
|
14
|
-
}
|
|
2
|
+
import type { Customer } from '../types';
|
|
15
3
|
interface CustomerListProps {
|
|
16
4
|
customers: Customer[];
|
|
17
5
|
onCustomerClick?: (customer: Customer) => void;
|
|
@@ -1,23 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
id: string;
|
|
4
|
-
orderNumber: string;
|
|
5
|
-
customerEmail: string;
|
|
6
|
-
customerName?: string;
|
|
7
|
-
status: 'pending' | 'processing' | 'shipped' | 'delivered' | 'cancelled' | 'refunded';
|
|
8
|
-
totalAmount: number;
|
|
9
|
-
currency: string;
|
|
10
|
-
paymentStatus: 'unpaid' | 'paid' | 'partially_paid' | 'refunded';
|
|
11
|
-
items: OrderItem[];
|
|
12
|
-
createdAt: string;
|
|
13
|
-
}
|
|
14
|
-
interface OrderItem {
|
|
15
|
-
id: string;
|
|
16
|
-
productName: string;
|
|
17
|
-
quantity: number;
|
|
18
|
-
unitPrice: number;
|
|
19
|
-
totalPrice: number;
|
|
20
|
-
}
|
|
2
|
+
import type { Order } from '../types';
|
|
21
3
|
interface OrderListProps {
|
|
22
4
|
orders: Order[];
|
|
23
5
|
onOrderClick?: (order: Order) => void;
|
|
@@ -1,38 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import type { Payment } from '../types';
|
|
2
3
|
interface PaymentCardProps {
|
|
3
|
-
payment:
|
|
4
|
-
id: string;
|
|
5
|
-
stripePaymentId: string;
|
|
6
|
-
amount: number;
|
|
7
|
-
currency: string;
|
|
8
|
-
status: string;
|
|
9
|
-
customerEmail: string;
|
|
10
|
-
customerName?: string;
|
|
11
|
-
paymentMethod: string;
|
|
12
|
-
description?: string;
|
|
13
|
-
metadata?: Record<string, any>;
|
|
14
|
-
createdAt: string;
|
|
15
|
-
updatedAt: string;
|
|
16
|
-
orderId?: string;
|
|
17
|
-
refundAmount?: number;
|
|
18
|
-
failureReason?: string;
|
|
19
|
-
billingAddress?: {
|
|
20
|
-
line1?: string;
|
|
21
|
-
line2?: string;
|
|
22
|
-
city?: string;
|
|
23
|
-
state?: string;
|
|
24
|
-
postal_code?: string;
|
|
25
|
-
country?: string;
|
|
26
|
-
};
|
|
27
|
-
shippingAddress?: {
|
|
28
|
-
line1?: string;
|
|
29
|
-
line2?: string;
|
|
30
|
-
city?: string;
|
|
31
|
-
state?: string;
|
|
32
|
-
postal_code?: string;
|
|
33
|
-
country?: string;
|
|
34
|
-
};
|
|
35
|
-
};
|
|
4
|
+
payment: Payment;
|
|
36
5
|
onClose: () => void;
|
|
37
6
|
}
|
|
38
7
|
declare const PaymentCard: React.FC<PaymentCardProps>;
|
|
@@ -1,18 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
id: string;
|
|
4
|
-
stripePaymentId: string;
|
|
5
|
-
amount: number;
|
|
6
|
-
currency: string;
|
|
7
|
-
status: string;
|
|
8
|
-
customerEmail: string;
|
|
9
|
-
customerName?: string;
|
|
10
|
-
paymentMethod: string;
|
|
11
|
-
createdAt: string;
|
|
12
|
-
}
|
|
2
|
+
import type { Payment } from '../types';
|
|
13
3
|
interface PaymentListProps {
|
|
14
4
|
payments: Payment[];
|
|
15
5
|
onPaymentClick?: (payment: Payment) => void;
|
|
6
|
+
onRefund?: (payment: Payment) => void;
|
|
7
|
+
onViewDetails?: (payment: Payment) => void;
|
|
16
8
|
compact?: boolean;
|
|
17
9
|
}
|
|
18
10
|
declare const PaymentList: React.FC<PaymentListProps>;
|
|
@@ -1,13 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import type { Payment } from '../types';
|
|
2
3
|
interface RefundModalProps {
|
|
3
|
-
payment:
|
|
4
|
-
id: string;
|
|
5
|
-
stripePaymentId: string;
|
|
6
|
-
amount: number;
|
|
7
|
-
currency: string;
|
|
8
|
-
customerEmail: string;
|
|
9
|
-
description?: string;
|
|
10
|
-
};
|
|
4
|
+
payment: Payment;
|
|
11
5
|
onClose: () => void;
|
|
12
6
|
onSuccess: () => void;
|
|
13
7
|
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { Modules } from '@strapi/strapi';
|
|
2
|
+
export type Customer = Modules.Documents.Document<'plugin::payment-plugin.customer'> & {
|
|
3
|
+
id: string | number;
|
|
4
|
+
documentId: string;
|
|
5
|
+
totalSpent: number;
|
|
6
|
+
currency: string;
|
|
7
|
+
paymentCount: number;
|
|
8
|
+
lastPaymentDate?: string;
|
|
9
|
+
registrationDate: string;
|
|
10
|
+
isActive: boolean;
|
|
11
|
+
tags: string[];
|
|
12
|
+
};
|
|
13
|
+
export interface OrderItem {
|
|
14
|
+
id: string;
|
|
15
|
+
productName: string;
|
|
16
|
+
sku?: string;
|
|
17
|
+
quantity: number;
|
|
18
|
+
unitPrice: number;
|
|
19
|
+
totalPrice: number;
|
|
20
|
+
}
|
|
21
|
+
export type Order = Modules.Documents.Document<'plugin::payment-plugin.order'> & {
|
|
22
|
+
id: string | number;
|
|
23
|
+
documentId: string;
|
|
24
|
+
order_number: string;
|
|
25
|
+
total_amount: number;
|
|
26
|
+
currency: string;
|
|
27
|
+
order_status: string;
|
|
28
|
+
payment_status: string;
|
|
29
|
+
customerEmail: string;
|
|
30
|
+
customerName: string;
|
|
31
|
+
paymentStatus: string;
|
|
32
|
+
items: OrderItem[];
|
|
33
|
+
};
|
|
34
|
+
export type Payment = Modules.Documents.Document<'plugin::payment-plugin.payment'> & {
|
|
35
|
+
id: string | number;
|
|
36
|
+
documentId: string;
|
|
37
|
+
amount: number;
|
|
38
|
+
currency: string;
|
|
39
|
+
payment_status: string;
|
|
40
|
+
stripe_payment_intent_id: string;
|
|
41
|
+
customerEmail: string;
|
|
42
|
+
customerName: string;
|
|
43
|
+
orderId?: string;
|
|
44
|
+
};
|
|
45
|
+
export type CustomerInput = Omit<Customer, 'id' | 'documentId' | 'createdAt' | 'updatedAt' | 'publishedAt'>;
|
|
46
|
+
export type OrderInput = Omit<Order, 'id' | 'documentId' | 'createdAt' | 'updatedAt' | 'publishedAt'>;
|
|
47
|
+
export type PaymentInput = Omit<Payment, 'id' | 'documentId' | 'createdAt' | 'updatedAt' | 'publishedAt'>;
|