Beispiel #1
0
 /**
  * After send a transaction to be analyzed by FControl,
  * you should capture the risk analysis for this transaction.
  * The transaction can be reviewed by analyst or a specific queue with its rules.
  * And after of complete analysis, the transaction will be available with its results.
  * @param CaptureOrder $order Order to be capture.
  * @return CaptureResponse Service response with capture data when find your order number
  *                         and it was analyzed by an analyst or automatic queue.
  */
 public function captureOrder(CaptureOrder $order)
 {
     $order->setAuthentication($this->getConfiguration());
     try {
         $response = $this->__soapCall('capturarResultadoEspecificoSubLoja3', array($order->toArray()));
     } catch (\SoapFault $fault) {
         $response = new \stdClass();
         $response->capturarResultadoEspecificoSubLoja3Result = new \stdClass();
         $response->capturarResultadoEspecificoSubLoja3Result->Sucesso = false;
         $response->capturarResultadoEspecificoSubLoja3Result->Mensagem = preg_replace('/(.*System\\.Exception: |[\\s]+em WSFControl2.*|[\\s]+ ---.*)/', '', $fault->getMessage());
     }
     return new CaptureResponse($response);
 }
 public function __construct(CaptureOrder $order)
 {
     $this->capturarResultadoEspecificoSubLoja3Result = (object) array('CodigoCompra' => $order->getOrderNumber(), 'Status' => 7, 'CodigoMotivo' => 0, 'Comentario' => '', 'Analista' => '', 'Email' => '', 'Ramal' => '', 'Telefone' => '', 'OpiniaoFcontrol' => 0, 'Score' => 350);
 }