Skip to content
This repository has been archived by the owner on Feb 22, 2023. It is now read-only.

Commit

Permalink
Merge pull request #7 from jonyw4/1.2.0
Browse files Browse the repository at this point in the history
1.2.0
  • Loading branch information
jonyw4 authored Jul 16, 2020
2 parents 5459803 + b686cbf commit 71c6f4b
Show file tree
Hide file tree
Showing 9 changed files with 791 additions and 376 deletions.
23 changes: 18 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,16 @@

## 🌟 Features
- A Pagar.me `PaymentMethodHandler` to createPayments
- A `PagarmePostbackController` controller to receive postback request from Pagar.me
- Refund credit card payments

## Roadmap
- Handle refund postback
- Add unit and E2E test
- Cronjob for cancel order after some time
- A query route in Shop GQL to get transaction information in storefront
- CRUD for save bank information for refund
- CRUD for save credit card's ID

## ⚙️ Install
### 1. Install and configure Vendure
Expand All @@ -17,13 +27,13 @@
npm install vendure-pagarme-plugin --save
```

### 3. Add the handler in Vendure configuration
### 3. Add the plugin in Vendure configuration
```typescript
import { pagarmePaymentMethodHandler } from 'vendure-pagarme-plugin';
import { PagarmePlugin } from 'vendure-pagarme-plugin';
const config: VendureConfig = {
...
paymentOptions: [
pagarmePaymentMethodHandler
plugins: [
PagarmePlugin
]
}
```
Expand All @@ -35,7 +45,10 @@ To create a payment with this plugin you will need to fill with metadata in `cre
import { PagarmePaymentMethodMetadata } from 'vendure-pagarme-plugin';
```

### 5. Enjoy!
### 5. Configure Pagar.me
You will need to enable and configure the options to make work. You can edit this in _Payment Method_ section in Vendure Admin UI

### 6. Enjoy!
It's done!

## 😍 Do you like?
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"lint:fix": "eslint --ext .ts,.tsx --fix"
},
"peerDependencies": {
"@vendure/core": ">=0.13.0"
"@vendure/core": ">=0.13.1"
},
"dependencies": {
"pagarme": "4.12.0"
Expand All @@ -30,7 +30,7 @@
"@commitlint/config-conventional": "9.1.1",
"@typescript-eslint/eslint-plugin": "3.6.1",
"@typescript-eslint/parser": "3.6.1",
"@vendure/core": "0.13.0",
"@vendure/core": "0.13.1",
"eslint": "7.4.0",
"eslint-config-prettier": "6.11.0",
"eslint-plugin-prettier": "3.1.4",
Expand Down
Loading

0 comments on commit 71c6f4b

Please sign in to comment.