Skip to content

Commit 8298407

Browse files
authored
Merge pull request #4 from PatronBase/browser-height-width-params
Added browser height and width parameters
2 parents 9bad59e + a262a2e commit 8298407

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

src/Message/PurchaseRequest.php

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -124,6 +124,48 @@ public function setLocale($value)
124124
return $this->setParameter('locale', $value);
125125
}
126126

127+
/**
128+
* Get the browserScreenHeight field
129+
*
130+
* @return null|int
131+
*/
132+
public function getBrowserScreenHeight()
133+
{
134+
return $this->getParameter('browserScreenHeight');
135+
}
136+
137+
/**
138+
* Set the browserScreenHeight field
139+
*
140+
* @param null|int $value
141+
* @return self
142+
*/
143+
public function setBrowserScreenHeight($value)
144+
{
145+
return $this->setParameter('browserScreenHeight', $value);
146+
}
147+
148+
/**
149+
* Get the browserScreenWidth field
150+
*
151+
* @return null|int
152+
*/
153+
public function getBrowserScreenWidth()
154+
{
155+
return $this->getParameter('browserScreenWidth');
156+
}
157+
158+
/**
159+
* Set the browserScreenWidth field
160+
*
161+
* @param null|int $value
162+
* @return self
163+
*/
164+
public function setBrowserScreenWidth($value)
165+
{
166+
return $this->setParameter('browserScreenWidth', $value);
167+
}
168+
127169
/**
128170
* Get the transaction type
129171
*
@@ -175,6 +217,8 @@ public function getData()
175217
// optional fields
176218
$optional_data = array(
177219
'customer_ip_address' => $this->getClientIp(),
220+
'customer_browser_screen_height' => $this->getBrowserScreenHeight(),
221+
'customer_browser_screen_width' => $this->getBrowserScreenWidth(),
178222
// merchant defined data 1-4 are stored with tokens, so transaction-specific data from 5 onwards
179223
'merchant_defined_data5' => $this->getDescription(),
180224
'override_backoffice_post_url' => $this->getNotifyUrl(),

0 commit comments

Comments
 (0)