forked from dmitrirussu/php-sepa-xml-generator
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest_factory.php
58 lines (57 loc) · 2.55 KB
/
test_factory.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
<?php
require_once 'SEPA/Factory/XmlGeneratorFactory.php';
/**
* SEPA Xml Generator Factory
*/
SEPA\Factory\XMLGeneratorFactory::createXmlGeneratorObject()->addXmlMessage(
SEPA\Factory\XMLGeneratorFactory::createXMLMessage()->setMessageGroupHeader(
SEPA\Factory\XMLGeneratorFactory::createXMLGroupHeader()
->setMessageIdentification(1)
->setInitiatingPartyName('Amazing SRL ???? ыаывпавпва'))
->addMessagePaymentInfo(
SEPA\Factory\XMLGeneratorFactory::createXMLPaymentInfo()
->setPaymentInformationIdentification(6222)
->setSequenceType('FRST')
->setCreditorAccountIBAN('MD24 AG00 0225 1000 1310 4168')
->setCreditorAccountBIC('AABAFI42')->setCreditorName('Amazing SRL')
->setCreditorSchemeIdentification('FR07ZZZ519993')
->setRequestedCollectionDate('2013-08-06')
->addDirectDebitTransaction( //First transaction
SEPA\Factory\XmlGeneratorFactory::createXMLDirectDebitTransaction()
->setInstructionIdentification(3)
->setEndToEndIdentification(3)
->setInstructedAmount(100.5)
->setDebtorName('Roy SRL')
->setDebitIBAN('FR14 2004 1010 0505 0001 3M02 606')
->setDebitBIC('AABAFI22')
->setMandateIdentification('SDD000000016PFX0713') //unique Identifier
->setDateOfSignature('2013-08-03')
// ->setCurrency('EUR')
->setDirectDebitInvoice(122)
)
// ->addDirectDebitTransaction( //Second transaction are the same client transaction
// SEPA\Factory\XmlGeneratorFactory::createXMLDirectDebitTransaction()
// ->setInstructionIdentification(4)
// ->setEndToEndIdentification(4)
// ->setInstructedAmount(100.5)
// ->setDebtorName('Roy SRL')
// ->setDebitIBAN('FR14 2004 1010 0505 0001 3M02 606')
// ->setDebitBIC('AABAFI22')
// ->setMandateIdentification('SDD000000016PFX0713') //unique Identifier
// ->setDateOfSignature('2013-08-03')
//// ->setCurrency('EUR')
// ->setDirectDebitInvoice(122))
// ->addDirectDebitTransaction( //An other client Transaction
// SEPA\Factory\XmlGeneratorFactory::createXMLDirectDebitTransaction()
// ->setInstructionIdentification(6)
// ->setEndToEndIdentification(6)
// ->setInstructedAmount(100.5)
// ->setDebtorName('ND SRL')
// ->setDebitIBAN('FR14 2004 1010 0505 0001 3M02 606')
// ->setDebitBIC('AABAFI22')
// ->setMandateIdentification('SDD000000016PFX0714') //unique Identifier
// ->setDateOfSignature('2013-08-03')
//// ->setCurrency('EUR')
// ->setDirectDebitInvoice(122))
)
)->view()->save(realpath(__DIR__) . '/xml_files/sepa_test.xml');