-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
I wonder what the right approach is to validate if the order is valid and confirmed with bank ID or not?
Below is the result from a retrieved test order. Is it the presence of a value in "pendingReasons" that indicates that the order is not yet confirmed? Or is it orderStatus having the value "pending"? Or is it something else?
object(Svea\WebPay\AdminService\AdminServiceResponse\GetOrdersResponse)#59 (28) {
["changedDate"]=>
NULL
["clientId"]=>
string(5) "79021"
["clientOrderId"]=>
string(5) "17222"
["createdDate"]=>
string(22) "2023-09-29T17:04:34.71"
["creditReportStatusAccepted"]=>
bool(true)
["creditReportStatusCreationDate"]=>
string(22) "2023-09-29T12:50:21.35"
["currency"]=>
string(3) "SEK"
["customer"]=>
object(Svea\WebPay\BuildOrder\RowBuilders\IndividualCustomer)#60 (17) {
["ssn"]=>
string(12) "194605092222"
["initials"]=>
NULL
["birthDate"]=>
NULL
["email"]=>
string(35) "timmy.almroth@tim-international.net"
["phonenumber"]=>
string(12) "+46811111111"
["ipAddress"]=>
NULL
["firstname"]=>
string(4) "Tess"
["lastname"]=>
string(7) "Persson"
["street"]=>
string(11) "Testgatan 1"
["housenumber"]=>
NULL
["coAddress"]=>
string(18) "c/o Eriksson, Erik"
["zipCode"]=>
string(5) "99999"
["locality"]=>
string(4) "Stan"
["publicKey"]=>
NULL
["fullName"]=>
NULL
["streetAddress"]=>
string(11) "Testgatan 1"
["name"]=>
string(15) "Persson, Tess T"
}
["customerId"]=>
string(8) "10023470"
["customerReference"]=>
string(4) "4167"
["isPossibleToAdminister"]=>
bool(false)
["isPossibleToCancel"]=>
bool(true)
["notes"]=>
NULL
["orderDeliveryStatus"]=>
string(7) "Created"
["numberedOrderRows"]=>
array(3) {
[0]=>
object(Svea\WebPay\BuildOrder\RowBuilders\NumberedOrderRow)#61 (16) {
["creditInvoiceId"]=>
NULL
["invoiceId"]=>
NULL
["rowNumber"]=>
string(1) "1"
["status"]=>
string(12) "NotDelivered"
["articleNumber"]=>
string(1) "1"
["quantity"]=>
string(4) "1.00"
["unit"]=>
string(2) "st"
["temporaryReference"]=>
NULL
["amountExVat"]=>
NULL
["vatPercent"]=>
int(25)
["amountIncVat"]=>
string(6) "792.00"
["name"]=>
NULL
["description"]=>
string(29) "Massagepistol Mini - Svart: "
["discountPercent"]=>
string(4) "0.00"
["vatDiscount"]=>
int(0)
["merchantData"]=>
NULL
}
[1]=>
object(Svea\WebPay\BuildOrder\RowBuilders\NumberedOrderRow)#62 (16) {
["creditInvoiceId"]=>
NULL
["invoiceId"]=>
NULL
["rowNumber"]=>
string(1) "2"
["status"]=>
string(12) "NotDelivered"
["articleNumber"]=>
string(1) "2"
["quantity"]=>
string(4) "1.00"
["unit"]=>
string(2) "st"
["temporaryReference"]=>
NULL
["amountExVat"]=>
NULL
["vatPercent"]=>
int(25)
["amountIncVat"]=>
string(6) "100.00"
["name"]=>
NULL
["description"]=>
string(18) "Hanteringsavgift: "
["discountPercent"]=>
string(4) "0.00"
["vatDiscount"]=>
int(0)
["merchantData"]=>
NULL
}
[2]=>
object(Svea\WebPay\BuildOrder\RowBuilders\NumberedOrderRow)#63 (16) {
["creditInvoiceId"]=>
NULL
["invoiceId"]=>
NULL
["rowNumber"]=>
string(1) "3"
["status"]=>
string(12) "NotDelivered"
["articleNumber"]=>
string(1) "3"
["quantity"]=>
string(4) "1.00"
["unit"]=>
string(2) "st"
["temporaryReference"]=>
NULL
["amountExVat"]=>
NULL
["vatPercent"]=>
int(25)
["amountIncVat"]=>
string(5) "20.00"
["name"]=>
NULL
["description"]=>
string(21) "Svea Bank (Invoice): "
["discountPercent"]=>
string(4) "0.00"
["vatDiscount"]=>
int(0)
["merchantData"]=>
NULL
}
}
["orderStatus"]=>
string(7) "Pending"
["orderType"]=>
string(7) "Invoice"
["paymentPlanDetailsContractLengthMonths"]=>
NULL
["paymentPlanDetailsContractNumber"]=>
NULL
["pendingReasonsPendingType"]=>
NULL
["pendingReasonsCreatedDate"]=>
NULL
["orderId"]=>
string(7) "9689745"
["sveaWillBuy"]=>
bool(true)
["accepted"]=>
int(1)
["resultcode"]=>
string(1) "0"
["errormessage"]=>
string(0) ""
["logs"]=>
NULL
["pendingReasons"]=>
object(stdClass)#57 (1) {
["PendingReason"]=>
object(stdClass)#58 (2) {
["CreatedDate"]=>
string(22) "2023-09-29T17:04:35.21"
["PendingType"]=>
string(6) "BankId"
}
}
}
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels