Skip to content

Commit 908e38b

Browse files
committed
adding country and scheme
1 parent a8640d2 commit 908e38b

2 files changed

Lines changed: 18 additions & 4 deletions

File tree

pis-connect.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@ app.get("/", async (_req, res) => {
3636
customer_address_zip: '',
3737
customer_address_city: '',
3838
customer_address_country: '',
39-
production: process.env.FINTECTURE_ENV === "production"
39+
production: process.env.FINTECTURE_ENV === "production",
40+
scheme: 'auto',
41+
country: 'fr'
4042
});
4143
});
4244

@@ -64,7 +66,8 @@ app.post("/connect", async (req, res) => {
6466
//redirect_uri: you can specify your own redirect_uri as long as it's defined in the console ; default redirect_uri is the one defined in the console
6567
//origin_uri: you can use any origin_uri (in case payeur abandons payment) ; default origin_uri is the last page he was on before redirecting to Connect
6668
psu_type: req.body.psu_type || 'retail',
67-
country: 'fr'
69+
country: req.body.country || 'fr',
70+
scheme: (req.body.scheme == "auto")?'':req.body.scheme,
6871
};
6972

7073
try {

views/pis-connect/index.ejs

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,23 @@
3030
<div class="form-group">
3131
<label for="psu_type">* Type</label>
3232
<select name="psu_type">
33+
<option value="all">All</option>
3334
<option value="retail">Retail</option>
3435
<option value="corporate">Corporate</option>
35-
<option value="all">All</option>
3636
</select>
3737
</div>
38-
38+
<div class="form-group">
39+
<label for="Scheme">* Type</label>
40+
<select name="scheme">
41+
<option value="auto">Auto</option>
42+
<option value="SEPA">SEPA</option>
43+
<option value="INSTANT_SEPA">INST</option>
44+
</select>
45+
</div>
46+
<div class="form-group">
47+
<label for="country">Country</label>
48+
<input type="text" id="country" name="country" value="<%= country %>">
49+
</div>
3950
<div class="form-group">
4051
<label for="customer_ip">*Customer IP</label>
4152
<input type="text" id="customer_ip" name="customer_ip" value="<%= customer_ip %>">

0 commit comments

Comments
 (0)