File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -208,6 +208,23 @@ public function sendDeliveryReport($delivery_report)
208
208
curl_close ($ this ->ch );
209
209
}
210
210
211
+ public function orderUpdate ($ order )
212
+ {
213
+ $ uri = $ this ->_endpoint .
214
+ '/merchants/ ' . $ order ['merchant ' ]['id ' ] .
215
+ '/orders/ ' . $ order ['merchant_reference ' ]['order_ref_1 ' ];
216
+ $ this ->initCurl ($ uri );
217
+ $ this ->verbThePayload ('PUT ' , array ('order ' => $ order ));
218
+
219
+ if ($ this ->status >= 200 && $ this ->status <= 299 ) {
220
+ $ this ->success = true ;
221
+ } elseif ($ this ->status == 409 ) {
222
+ $ this ->cart_has_changed = true ;
223
+ $ this ->json = json_decode ($ this ->curl_result , true );
224
+ }
225
+ curl_close ($ this ->ch );
226
+ }
227
+
211
228
public function callCron ($ cron_url )
212
229
{
213
230
$ this ->_user_agent = 'sequra-cron ' ;
You can’t perform that action at this time.
0 commit comments