getData

@return array
@throws \Omnipay\Common\Exception\InvalidCreditCardException
@throws \Omnipay\Common\Exception\InvalidRequestException
965869
public function getData()
    {
        // An amount parameter is required, as is a currency.
        $this->validate('amount', 'currency', 'description');
        $data = parent::getData();

        // Some predefined variables that need to be set
        $data['next_phase']         = 'paydata';
        $data['agree2terms']        = '1';

        // Send through the charge amount and description, we will always set
        // the qty to 1
        $data['item1_desc']         = $this->getDescription();
        $data['item1_price']        = $this->getAmount();
        $data['item1_qty']          = 1;

        $data = array_merge($data, $this->getItemData());

        // $data['rebill_amount']      = $this->getAmount();
        $data['valuta_code']        = $this->getCurrency();
        $data['user1']              = $this->getUser1();
        $data['user2']              = $this->getUser2();
        $data['dyn_desc']           = $this->getDynDesc();

        // MultiCards supports card or token payments
        if ($this->getCardReference()) {
            $data['token_id'] = $this->getCardReference();
        } else {
            $this->validate('card');
            $card = $this->getCard();

            // Test Payments in particular use a card number that does not
            // validate against the Luhn algorithm, so don't validate the card.
            // $card->validate();

            /// Card data passed through
            $data['cust_name']          = $card->getName();
            $data['cust_address1']      = $this->stripForbiddenAddressCharacters($card->getBillingAddress1());
            $data['cust_city']          = $card->getBillingCity();
            $data['cust_state']         = $card->getBillingState();
            $data['cust_zip']           = $card->getBillingPostcode();
            $data['cust_phone']         = $card->getBillingPhone();
            $data['cust_email']         = $card->getEmail();
            $data['cust_country']       = $card->getBillingCountry();

            $data['card_num']           = $card->getNumber();
            $data['card_name']          = $card->getName();
            $data['card_exp']           = $card->getExpiryDate('m/y');
            $data['card_code']          = $card->getCvv();

            // This requests a token_id to be returned with the response so that
            // the card reference can be used next time.
            $data['req_trans_token']    = '1';
        }

        return $data;
    }
660956
public function getData()
    {
        $this->validate('merchantId', 'merchantPassword', 'acquirerId', 'transactionId', 'amount');

        $data = [
            'AcquirerId'       => $this->getAcquirerId(),
            'Amount'           => $this->formatAmount(),
            'CurrencyExponent' => $this->getCurrencyDecimalPlaces(),
            'MerchantId'       => $this->getMerchantId(),
            'ModificationType' => $this->getModificationType(),
            'OrderNumber'      => $this->getTransactionId(),
            'Password'         => $this->getMerchantPassword()
        ];

        return $data;
    }
237393
protected function _getData()
    {
        $data = array();

        if (isset($this->_query)) {
            $data = $this->getRepository()->fetch($this->_query, AnDomain::FETCH_ENTITY_LIST);
        }

        return $data;
    }
193677
protected function getCardData()
    {
        $card = $this->getCard();
        $card->validate();

        $data = array();
        $data['object'] = 'card';
        $data['number'] = $card->getNumber();
        $data['exp_month'] = $card->getExpiryMonth();
        $data['exp_year'] = $card->getExpiryYear();
        if ($card->getCvv()) {
            $data['cvc'] = $card->getCvv();
        }
        $data['name'] = $card->getName();
        $data['address_line1'] = $card->getAddress1();
        $data['address_line2'] = $card->getAddress2();
        $data['address_city'] = $card->getCity();
        $data['address_zip'] = $card->getPostcode();
        $data['address_state'] = $card->getState();
        $data['address_country'] = $card->getCountry();
        $data['email'] = $card->getEmail();

        return $data;
    }
958465
public function getCustomerData()
    {
        $data = array(
            'disable_send_mail' => $this->getSendMail(),
            'locale'            => $this->getLocale(),
        );

        if (is_null($this->getCard())) {
            return array_filter($data);
        }

        $cardData = array(
            'address1'         => $this->getCard()->getAddress1(),
            'address2'         => $this->getCard()->getAddress2(),
            'city'              => $this->getCard()->getCity(),
            'country'           => $this->getCard()->getCountry(),
            'email'             => $this->getCard()->getEmail(),
            'first_name'        => $this->getCard()->getFirstName(),
            'house_number'      => $this->getVar1(),
            'last_name'         => $this->getCard()->getLastName(),
            'phone'             => $this->getCard()->getPhone(),
            'state'             => $this->getCard()->getState(),
            'zip_code'          => $this->getCard()->getPostcode(),
        );

        return array_filter(
            array_merge($data, $cardData)
        );
    }
978946
public function getData()
    {
        $this->validate(
            'amount',
            'card',
            'transactionId',
            'clientIp',
            'productId'
        );

        $card = $this->getCard();

        $card->validate();

        $data = [
            'opcode'      => 0,
            'product_id'  => $this->getProductId(),
            'amount'      => $this->getAmount(),
            'cf'          => $this->getTransactionId(),
            'ip_address'  => $this->getClientIp(),
            'pan'         => $card->getNumber(),
            'cardholder'  => $card->getName(),
            'exp_month'   => $card->getExpiryMonth(),
            'exp_year'    => $card->getExpiryYear(),
            'cvv'         => $card->getCvv(),
            'pp_identity' => 'card',
            'token'       => $this->getRequestToken(),
        ];

        if ($this->getPhone()) {
            $data['phone'] = $this->getPhone();
        }
        if ($this->getCf2()) {
            $data['cf2'] = $this->getCf2();
        }
        if ($this->getCf3()) {
            $data['cf3'] = $this->getCf3();
        }
        if ($this->getCallbackUrl()) {
            $data['cb_url'] = $this->getCallbackUrl();
        }

        return $data;
    }
954444
public function getStorableData()
    {
        return [
            'id' => 'Transaction',
            'flat' => [
                'Total' => \Heystack\Ecommerce\convertMoneyToString($this->total),
                'Status' => $this->status,
                'Currency' => $this->currencyService->getActiveCurrencyCode()
            ],
            'related' => []
        ];

    }
1065122
public function getList()
    {
        $request   = $this->getRequest();

        // retrive data ...
        $data = $request->getQuery()->toArray();

        return $this->proccessData($data);
    }
390268
public function getRevCardGet()
    {
        $array = array();
        if (isset($this->_receive['CardId'])) {
            $array['CardId'] = $this->_receive['CardId'];
        }
        if (isset($this->_receive['IsGiveByFriend'])) {
            $array['IsGiveByFriend'] = $this->_receive['IsGiveByFriend'];
        }
        $array['OldUserCardCode'] = $this->_receive['OldUserCardCode'];
        if (isset($this->_receive['UserCardCode']) && !empty($this->_receive['UserCardCode'])) {
            $array['UserCardCode'] = $this->_receive['UserCardCode'];
        }
        return (isset($array) && count($array) > 0) ? $array : false;
    }
330973
protected function GetUserPaymentData()
    {
        $oGlobal = TGlobal::instance();
        if ($oGlobal->UserDataExists(TdbShopPaymentHandler::URL_PAYMENT_USER_INPUT)) {
            $this->aPaymentUserData = $oGlobal->GetUserData(TdbShopPaymentHandler::URL_PAYMENT_USER_INPUT);
            if (!is_array($this->aPaymentUserData)) {
                $this->aPaymentUserData = array();
            }
        } elseif (is_null($this->aPaymentUserData)) {
            $this->aPaymentUserData = $this->GetDefaultUserPaymentData();
        }

        return $this->aPaymentUserData;
    }
79895
public function getData()
    {
        $this->validateParams();

        $data = [
            'service'        => $this->service,
            'partner'        => $this->getPartner(),
            'trade_no'       => $this->getTradeNo(),
            'out_trade_no'   => $this->getOutTradeNo(),
            '_input_charset' => $this->getInputCharset(),
            'sign_type'      => $this->getSignType()
        ];
        $data['sign'] = $this->sign($data, $this->getSignType());
        
        return $data;
    }
1612
protected function getListPayment()
    {
        $id = $this->getParam(0);

        if (!isset($id)) {
            $list = $this->payment->getList();
            $this->limitArray($list);
            return $list;
        }

        $method = $this->payment->get($id);

        if (empty($method)) {
            $this->errorAndExit($this->text('Unexpected result'));
        }

        return array($method);
    }
943478
public function getData()
    {
        $this->validate('merId', 'password', 'merUrlIdx');
        $data = array(
            'mer_id'            => $this->getMerId(),
            'password'          => $this->getPassword(),
            'mer_url_idx'       => $this->getMerUrlIdx(),
            'client_ip'         => $this->getClientIp(),
        );
        return $data;
    }
89646
protected function getRequestData()
    {
        return [
            'request'  => $this->request->toArray(),
            'response' => [
                'content'      => null,
                'content_type' => null,
                'status_code'  => ServiceResponseInterface::HTTP_OK
            ],
            'resource' => $this->resourcePath
        ];
    }
1023875
protected function getPaymentData()
    {
        $data = array(
            'cancel_url'   => $this->getCancelUrl(),
            'close_window' => $this->getCloseWindow(),
            'notification_url' => $this->getNotifyUrl(),
            'redirect_url'   => $this->getReturnUrl(),
        );

        return array_filter($data);
    }
979368
public function getData()
    {
        if (empty($this->data)) {
            $this->data = [
                'entityClassName' => $this->getEntityClassName(),
                'entityName' => $this->getEntityName(),
                'formFilename' => lcfirst($this->getEntityName()).'-form'
            ];
        }
        return $this->data;
    }
319839
public function getData()
    {
        $data = array();

        if ($this->getParameter('customer')) {
            $data['customer'] = $this->getParameter('customer');
        } elseif ($this->getParameter('card')) {
            /* @var $card \OmniPay\Common\CreditCard */
            $card = $this->getParameter('card');
            $card->validate();

            $card_data = array(
                'exp_month' => $card->getExpiryMonth(),
                'exp_year' => $card->getExpiryYear(),
                'number' => $card->getNumber(),
            );

            if ($card->getBillingCity()) {
                $card_data['address_city'] = $card->getBillingCity();
            }

            if ($card->getBillingCountry()) {
                $card_data['address_country'] = $card->getBillingCountry();
            }

            if ($card->getBillingAddress1()) {
                $card_data['address_line1'] = $card->getBillingAddress1();
            }

            if ($card->getBillingAddress2()) {
                $card_data['address_line2'] = $card->getBillingAddress2();
            }

            if ($card->getBillingState()) {
                $card_data['address_state'] = $card->getBillingState();
            }

            if ($card->getBillingPostcode()) {
                $card_data['address_zip'] = $card->getBillingPostcode();
            }

            if ($card->getCvv()) {
                $card_data['cvc'] = $card->getCvv();
            }

            if ($card->getBillingName()) {
                $card_data['name'] = $card->getBillingName();
            }

            $data['card'] = $card_data;
        } else {
            throw new InvalidRequestException("You must pass either the card or the customer");
        }

        return $data;
    }