def default_transaction(self, args):
		price_offer = self._offers_getter()
		phone, email, address = self._get_additional_info()
		self._currency_converter._new_currency = args.currency

		# website has no data
		default_rate = FxChangeData(
			self._currency_converter.convert(0),
			self._currency_converter.convert(0),
			info=[phone, email, address],
			website=self._base_url,
			transaction_type=args.transaction_option,
			symbol=self._currency_converter._new_currency.value,
		)

		return default_rate
    def _payoneer_transaction(self, args):

        transaction_offer = self._transaction_helper()[2]
        sell_at, buy_at, transac = self._details_helper(transaction_offer)
        phone, email, address = self._addendum()

        self._currency_converter._new_currency = args.currency

        payoneer_rate = FxChangeData(
            self._currency_converter.convert(buy_at),
            self._currency_converter.convert(sell_at),
            info=[phone, email, address],
            website=self._base_url,
            symbol=self._currency_converter._new_currency.value,
        )

        return payoneer_rate
    def _skrill_transaction(self, args):
        transaction_offer = self._transaction_helper()[0]
        sell_at, buy_at, transac = self._details_helper(transaction_offer)
        phone, email, address = self._addendum()

        self._currency_converter._new_currency = args.currency

        skrill_rate = FxChangeData(
            self._currency_converter.convert(buy_at),
            self._currency_converter.convert(sell_at),
            info=[phone, email, address],
            website=self._base_url,
            transaction_type=TransactionType.SKRILL,
            symbol=self._currency_converter._new_currency.value,
        )

        return skrill_rate
    def _perfect_money_transaction(self, args):

        transaction_offer = self._transaction_helper()[3]
        sell_at, buy_at, transac = self._details_helper(transaction_offer)
        phone, email, address = self._addendum()

        self._currency_converter._new_currency = args.currency

        perfect_money_rate = FxChangeData(
            self._currency_converter.convert(buy_at),
            self._currency_converter.convert(sell_at),
            info=[phone, email, address],
            website=self._base_url,
            transaction_type=TransactionType.PERFECT_MONEY,
            symbol=self._currency_converter._new_currency.value,
        )

        return perfect_money_rate
	def _bitcoin_transaction(self, args):
		
		price_offer = self._offers_getter()[0][0]

		sell_at, buy_at = self._get_details_string(price_offer)
		phone, email, address = self._get_additional_info()

		self._currency_converter._new_currency = args.currency

		bitcoin_rate = FxChangeData(
				self._currency_converter.convert(buy_at),
				self._currency_converter.convert(sell_at),
				info = [phone, email, address],
				website = self._base_url,
				symbol = self._currency_converter._new_currency.value

			)

		return bitcoin_rate
Exemplo n.º 6
0
	def _paypal_transaction(self, args):
		transaction_offer = self._transaction_helper()[0]
		
		sell_at = transaction_offer["perfectmoneybuy"]
		buy_at = transaction_offer["perfectmoneysell"]

		phone, email, address = self._get_additional_info()

		self._currency_converter._new_currency = args.currency

		perfect_money_rate = FxChangeData(
			self._currency_converter.convert(buy_at),
			self._currency_converter.convert(sell_at),
			info=[phone, email, address],
			website=self._base_url,
			transaction_type=TransactionType.PERFECT_MONEY,
			symbol=self._currency_converter._new_currency.value,
		)

		return perfect_money_rate
Exemplo n.º 7
0
	def _bitcoin_transaction(self, args):
		transaction_offer = self._transaction_helper()[0]
		
		sell_at = transaction_offer["bitcoinbuy"]
		buy_at = transaction_offer["bitcoinsell"]

		phone, email, address = self._get_additional_info()

		self._currency_converter._new_currency = args.currency

		bitcoin_rate = FxChangeData(
			self._currency_converter.convert(buy_at),
			self._currency_converter.convert(sell_at),
			info=[phone, email, address],
			website=self._base_url,
			transaction_type=TransactionType.BITCOIN,
			symbol=self._currency_converter._new_currency.value,
		)

		return bitcoin_rate