当前位置: 首页>>代码示例>>PHP>>正文


PHP PaymentModule::getInstalledPaymentModules方法代码示例

本文整理汇总了PHP中PaymentModule::getInstalledPaymentModules方法的典型用法代码示例。如果您正苦于以下问题:PHP PaymentModule::getInstalledPaymentModules方法的具体用法?PHP PaymentModule::getInstalledPaymentModules怎么用?PHP PaymentModule::getInstalledPaymentModules使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在PaymentModule的用法示例。


在下文中一共展示了PaymentModule::getInstalledPaymentModules方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: getCodList

 public function getCodList()
 {
     $modules = PaymentModule::getInstalledPaymentModules();
     $binded = unserialize(Configuration::get(self::KONFIG_PREFIX . self::KONFIG_POBRANIE));
     $list = array();
     foreach ($modules as $key => $c) {
         $list[] = new BindedCod($c['id_module'], $c['name'], is_array($binded) && in_array($c['id_module'], $binded) ? "true" : "false");
     }
     return $list;
 }
开发者ID:nikuta,项目名称:paczkomaty,代码行数:10,代码来源:Pakomato15.php

示例2: __construct

 public function __construct()
 {
     $modules_infos = PaymentModule::getInstalledPaymentModules();
     foreach ($modules_infos as $module_infos) {
         $module = Module::getInstanceByName($module_infos['name']);
         if (!$module) {
             continue;
         }
         if ($module->tab == 'payments_gateways') {
             if ($module->id) {
                 if (!get_class($module) == 'SimpleXMLElement') {
                     $module->country = array();
                 }
                 $countries = Db::getInstance()->ExecuteS('SELECT id_country FROM ' . _DB_PREFIX_ . 'module_country WHERE id_module = ' . (int) $module->id);
                 foreach ($countries as $country) {
                     $module->country[] = $country['id_country'];
                 }
                 if (!get_class($module) == 'SimpleXMLElement') {
                     $module->currency = array();
                 }
                 $currencies = Db::getInstance()->ExecuteS('SELECT id_currency FROM ' . _DB_PREFIX_ . 'module_currency WHERE id_module = ' . (int) $module->id);
                 foreach ($currencies as $currency) {
                     $module->currency[] = $currency['id_currency'];
                 }
                 if (!get_class($module) == 'SimpleXMLElement') {
                     $module->group = array();
                 }
                 $groups = Db::getInstance()->ExecuteS('SELECT id_group FROM ' . _DB_PREFIX_ . 'module_group WHERE id_module = ' . (int) $module->id);
                 foreach ($groups as $group) {
                     $module->group[] = $group['id_group'];
                 }
             } else {
                 $module->country = NULL;
                 $module->currency = NULL;
                 $module->group = NULL;
             }
             $this->paymentModules[] = $module;
         }
     }
     parent::__construct();
 }
开发者ID:Evil1991,项目名称:PrestaShop-1.4,代码行数:41,代码来源:AdminPayment.php

示例3: ajaxProcessChangePaymentMethod

 public function ajaxProcessChangePaymentMethod()
 {
     $customer = new Customer(Tools::getValue('id_customer'));
     $modules = Module::getAuthorizedModules($customer->id_default_group);
     $authorized_modules = array();
     if (!Validate::isLoadedObject($customer) || !is_array($modules)) {
         die(Tools::jsonEncode(array('result' => false)));
     }
     foreach ($modules as $module) {
         $authorized_modules[] = (int) $module['id_module'];
     }
     $payment_modules = array();
     foreach (PaymentModule::getInstalledPaymentModules() as $p_module) {
         if (in_array((int) $p_module['id_module'], $authorized_modules)) {
             $payment_modules[] = Module::getInstanceById((int) $p_module['id_module']);
         }
     }
     $this->context->smarty->assign(array('payment_modules' => $payment_modules));
     die(Tools::jsonEncode(array('result' => true, 'view' => $this->createTemplate('_select_payment.tpl')->fetch())));
 }
开发者ID:evgrishin,项目名称:mh16014,代码行数:20,代码来源:AdminOrdersController.php

示例4: _displayConfiguration

    private function _displayConfiguration()
    {
        $this->_html .= '
		<script type="text/javascript">
			$(document).ready(function() {
				$(\'#submitCreateAccount\').unbind(\'click\').click(function() {
					if (!$(\'#terms_and_conditions\').attr(\'checked\'))
					{
						alert(\'' . addslashes($this->l('Please accept the terms of service.')) . '\');
						return false;
					}
				});										
			});
		</script>
		<fieldset><legend>' . $this->l('PrestaShop Security configuration') . '</legend>
			<div id="choose_account">
				<center>
				<form>
					<input type="radio" ' . (!Configuration::get('PS_TRUST_SHOP_ID') ? 'checked="checked"' : '') . ' onclick="$(\'#create_account\').show(); $(\'#module_configuration\').hide();" id="trust_account_on" name="trust_account" value="0"/> <b>' . $this->l('My shop does not have a PrestaShop Security account yet') . '</b>&nbsp;&nbsp;&nbsp;
					<input type="radio" ' . (Configuration::get('PS_TRUST_SHOP_ID') ? 'checked="checked"' : '') . ' onclick="$(\'#create_account\').hide(); $(\'#module_configuration\').show();"  id="trust_account_off" name="trust_account" value="1" /> <b>' . $this->l('I already have an account') . '</b>
				</form>
				</center>
			</div>
			<div class="clear">&nbsp;</div>
			<div id="create_account" ' . (Configuration::get('PS_TRUST_SHOP_ID') ? 'style="display:none;"' : '') . '>
				<form action="' . Tools::htmlentitiesUTF8($_SERVER['REQUEST_URI']) . '" method="post" name="prestashop_trust" id="prestashop_trust">
					<label>' . $this->l('Your email') . '</label>
					<div class="margin-form">
						<input type="text" style="width:200px;" name="email" value="' . Tools::safeOutput(Tools::getValue('email')) . '" />
					</div>
					<label>' . $this->l('Shop Url') . '</label>
					<div class="margin-form">
						<input type="text" style="width:400px;" name="shop_url" value="http://www.' . Tools::getHttpHost() . __PS_BASE_URI__ . '"/>
					</div>
					<div class="margin-form">
						<input id="terms_and_conditions" type="checkbox" value="1" /> ' . $this->l('I agree with the terms of PrestaShop Security service and I adhere to them unconditionally.') . '</label>
					</div>
					<div id="terms" class="margin-form">';
        $terms = Tools::file_get_contents($this->_trustUrl . 'terms.php?lang=' . $this->context->language->iso_code);
        $this->_html .= '<div style="height:300px;border:1px solid #E0D0B1;overflow-y:scroll;padding:8px;color:black">' . Tools::nl2br(strip_tags($terms)) . '</div>';
        $this->_html .= '</div>
					<div class="margin-form">
						<input class="button" type="submit" id="submitCreateAccount" name="submitCreateAccount" value="' . $this->l('Create account') . '"/>
					</div>
				</form>
				<div class="clear">&nbsp;</div>
			</div>
			<div id="module_configuration" ' . (!Configuration::get('PS_TRUST_SHOP_ID') ? 'style="display:none"' : '') . '>
			<form action="' . Tools::htmlentitiesUTF8($_SERVER['REQUEST_URI']) . '" method="post" name="prestashop_trust" id="prestashop_trust">
				<label>' . $this->l('Shop ID') . '</label>
				<div class="margin-form">
					<input type="text" style="width:150px"  name="shop_id" value="' . Configuration::get('PS_TRUST_SHOP_ID') . '"/>
				</div>
				<label>' . $this->l('Shop KEY') . '</label>
				<div class="margin-form">
					<input type="text" style="width:300px" name="shop_key" value="' . Configuration::get('PS_TRUST_SHOP_KEY') . '"/>
				</div>
				<div class="clear">&nbsp;</div>
				<label>' . $this->l('Shop activity') . '</label>
				<div class="margin-form">
					<select name="shop_activity">';
        foreach ($this->_activities as $k => $activity) {
            $this->_html .= '<option value="' . $k . '" ' . ($k == Configuration::get('PS_SHOP_ACTIVITY') ? 'selected="selected"' : '') . '>' . $activity . '</option>';
        }
        $this->_html .= '</select>
				</div>';
        $carriers = Carrier::getCarriers($this->context->language->id, true);
        $trust_carriers_type = $this->_getPrestaTrustCarriersType();
        $configured_carriers = $this->_getConfiguredCarriers();
        $this->_html .= '
				<label>' . $this->l('Carriers') . '</label>
				<div class="margin-form">
					<table cellspacing="0" cellpadding="0" class="table">
						<thead><tr><th>' . $this->l('Carrier') . '</th><th>' . $this->l('Carrier Type') . '</th></tr></thead><tbody>';
        foreach ($carriers as $carrier) {
            $this->_html .= '<tr><td>' . $carrier['name'] . '</td><td><select name="carrier_' . $carrier['id_carrier'] . '">
			<option value="0">' . $this->l('Choose a carrier type...') . '</option>';
            foreach ($this->_getPrestaTrustCarriersType() as $type => $name) {
                $this->_html .= '<option value="' . $type . '"' . ((isset($configured_carriers[$carrier['id_carrier']]) and $type == $configured_carriers[$carrier['id_carrier']]) ? ' selected="selected"' : '') . '>' . $name . '</option>';
            }
            $this->_html .= '</select></td>';
        }
        $this->_html .= '</tbody></table></margin>
			</div>';
        $modules = PaymentModule::getInstalledPaymentModules();
        $configured_payments = $this->_getConfiguredPayments();
        $this->_html .= '
				<label>' . $this->l('Payments') . '</label>
				<div class="margin-form">
					<table cellspacing="0" cellpadding="0" class="table">
						<thead><tr><th>' . $this->l('Payment Module') . '</th><th>' . $this->l('Payment Type') . '</th></tr></thead><tbody>';
        foreach ($modules as $module) {
            $mod = Module::getInstanceByName($module['name']);
            $this->_html .= '<tr><td>' . $mod->displayName . '</td><td><select name="paymentmodule_' . $mod->id . '">
			<option value="0">' . $this->l('Choose a payment type...') . '</option>';
            foreach ($this->_payment_types as $type => $name) {
                $this->_html .= '<option value="' . $type . '"' . ((isset($configured_payments[$mod->id]) and $type == $configured_payments[$mod->id]) ? ' selected="true"' : '') . '>' . $name . '</option>';
            }
            $this->_html .= '</select></td>';
        }
//.........这里部分代码省略.........
开发者ID:Sosiashvili,项目名称:prestafraud,代码行数:101,代码来源:prestafraud.php

示例5: renderView

 public function renderView()
 {
     $order = new Order(Tools::getValue('id_order'));
     if (!Validate::isLoadedObject($order)) {
         $this->errors[] = Tools::displayError('The order cannot be found within your database.');
     }
     $customer = new Customer($order->id_customer);
     $carrier = new Carrier($order->id_carrier);
     $products = $this->getProducts($order);
     $order_details = AphOrderDetail::getList($order->id);
     foreach ($order_details as &$order_detail) {
         $products[$order_detail['id_order_detail']]['delivery_date'] = $order_detail['delivery_date'];
         $products[$order_detail['id_order_detail']]['delivery_time_from'] = $order_detail['delivery_time_from'];
         $products[$order_detail['id_order_detail']]['delivery_time_to'] = $order_detail['delivery_time_to'];
     }
     $currency = new Currency((int) $order->id_currency);
     // Carrier module call
     $carrier_module_call = null;
     if ($carrier->is_module) {
         $module = Module::getInstanceByName($carrier->external_module_name);
         if (method_exists($module, 'displayInfoByCart')) {
             $carrier_module_call = call_user_func(array($module, 'displayInfoByCart'), $order->id_cart);
         }
     }
     // Retrieve addresses information
     $addressInvoice = new Address($order->id_address_invoice, $this->context->language->id);
     if (Validate::isLoadedObject($addressInvoice) && $addressInvoice->id_state) {
         $invoiceState = new State((int) $addressInvoice->id_state);
     }
     if ($order->id_address_invoice == $order->id_address_delivery) {
         $addressDelivery = $addressInvoice;
         if (isset($invoiceState)) {
             $deliveryState = $invoiceState;
         }
     } else {
         $addressDelivery = new Address($order->id_address_delivery, $this->context->language->id);
         if (Validate::isLoadedObject($addressDelivery) && $addressDelivery->id_state) {
             $deliveryState = new State((int) $addressDelivery->id_state);
         }
     }
     $this->toolbar_title = sprintf($this->l('Order #%1$d (%2$s) - %3$s %4$s'), $order->id, $order->reference, $customer->firstname, $customer->lastname);
     if (Shop::isFeatureActive()) {
         $shop = new Shop((int) $order->id_shop);
         $this->toolbar_title .= ' - ' . sprintf($this->l('Shop: %s'), $shop->name);
     }
     // gets warehouses to ship products, if and only if advanced stock management is activated
     $warehouse_list = null;
     $order_details = $order->getOrderDetailList();
     foreach ($order_details as $order_detail) {
         $product = new Product($order_detail['product_id']);
         if (Configuration::get('PS_ADVANCED_STOCK_MANAGEMENT') && $product->advanced_stock_management) {
             $warehouses = Warehouse::getWarehousesByProductId($order_detail['product_id'], $order_detail['product_attribute_id']);
             foreach ($warehouses as $warehouse) {
                 if (!isset($warehouse_list[$warehouse['id_warehouse']])) {
                     $warehouse_list[$warehouse['id_warehouse']] = $warehouse;
                 }
             }
         }
     }
     $payment_methods = array();
     foreach (PaymentModule::getInstalledPaymentModules() as $payment) {
         $module = Module::getInstanceByName($payment['name']);
         if (Validate::isLoadedObject($module) && $module->active) {
             $payment_methods[] = $module->displayName;
         }
     }
     // display warning if there are products out of stock
     $display_out_of_stock_warning = false;
     $current_order_state = $order->getCurrentOrderState();
     if (Configuration::get('PS_STOCK_MANAGEMENT') && (!Validate::isLoadedObject($current_order_state) || $current_order_state->delivery != 1 && $current_order_state->shipped != 1)) {
         $display_out_of_stock_warning = true;
     }
     // products current stock (from stock_available)
     foreach ($products as &$product) {
         // Get total customized quantity for current product
         $customized_product_quantity = 0;
         if (is_array($product['customizedDatas'])) {
             foreach ($product['customizedDatas'] as $customizationPerAddress) {
                 foreach ($customizationPerAddress as $customizationId => $customization) {
                     $customized_product_quantity += (int) $customization['quantity'];
                 }
             }
         }
         $product['customized_product_quantity'] = $customized_product_quantity;
         $product['current_stock'] = StockAvailable::getQuantityAvailableByProduct($product['product_id'], $product['product_attribute_id'], $product['id_shop']);
         $resume = OrderSlip::getProductSlipResume($product['id_order_detail']);
         $product['quantity_refundable'] = $product['product_quantity'] - $resume['product_quantity'];
         $product['amount_refundable'] = $product['total_price_tax_excl'] - $resume['amount_tax_excl'];
         $product['amount_refundable_tax_incl'] = $product['total_price_tax_incl'] - $resume['amount_tax_incl'];
         $product['amount_refund'] = Tools::displayPrice($resume['amount_tax_incl'], $currency);
         $product['refund_history'] = OrderSlip::getProductSlipDetail($product['id_order_detail']);
         $product['return_history'] = OrderReturn::getProductReturnDetail($product['id_order_detail']);
         // if the current stock requires a warning
         if ($product['current_stock'] <= 0 && $display_out_of_stock_warning) {
             $this->displayWarning($this->l('This product is out of stock: ') . ' ' . $product['product_name']);
         }
         if ($product['id_warehouse'] != 0) {
             $warehouse = new Warehouse((int) $product['id_warehouse']);
             $product['warehouse_name'] = $warehouse->name;
             $warehouse_location = WarehouseProductLocation::getProductLocation($product['product_id'], $product['product_attribute_id'], $product['id_warehouse']);
//.........这里部分代码省略.........
开发者ID:paolobattistella,项目名称:aphro,代码行数:101,代码来源:AdminAphOrdersController.php

示例6: ajaxProcessChangePaymentMethod

 public function ajaxProcessChangePaymentMethod()
 {
     $id_customer = Tools::getValue('id_customer');
     $customer = new Customer(Tools::getValue('id_customer'));
     $this->context->customer = $customer;
     //by webkul code to add id_customer in cart table
     $this->context->customer = new Customer($id_customer);
     if ($id_customer) {
         // setting data in the cart set from book now page by webkul
         $this->context->cart = new Cart(Tools::getValue('id_cart'));
         $this->context->cart->id_customer = $id_customer;
         /*if (Validate::isLoadedObject($this->context->cart) && $this->context->cart->OrderExists())
         		return;*/
         if (!$this->context->cart->secure_key) {
             $this->context->cart->secure_key = $this->context->customer->secure_key;
         }
         if (!$this->context->cart->id_shop) {
             $this->context->cart->id_shop = (int) $this->context->shop->id;
         }
         if (!$this->context->cart->id_lang) {
             $this->context->cart->id_lang = ($id_lang = (int) Tools::getValue('id_lang')) ? $id_lang : Configuration::get('PS_LANG_DEFAULT');
         }
         if (!$this->context->cart->id_currency) {
             $this->context->cart->id_currency = ($id_currency = (int) Tools::getValue('id_currency')) ? $id_currency : Configuration::get('PS_CURRENCY_DEFAULT');
         }
         $addresses = $customer->getAddresses((int) $this->context->cart->id_lang);
         if (!$this->context->cart->id_address_invoice && isset($addresses[0])) {
             $this->context->cart->id_address_invoice = (int) $addresses[0]['id_address'];
         } elseif ($id_address_invoice) {
             $this->context->cart->id_address_invoice = (int) $id_address_invoice;
         }
         if (!$this->context->cart->id_address_delivery && isset($addresses[0])) {
             $this->context->cart->id_address_delivery = $addresses[0]['id_address'];
         }
         $this->context->cart->save();
     }
     //end
     $modules = Module::getAuthorizedModules($customer->id_default_group);
     $authorized_modules = array();
     if (!Validate::isLoadedObject($customer) || !is_array($modules)) {
         die(Tools::jsonEncode(array('result' => false)));
     }
     foreach ($modules as $module) {
         $authorized_modules[] = (int) $module['id_module'];
     }
     $payment_modules = array();
     foreach (PaymentModule::getInstalledPaymentModules() as $p_module) {
         if (in_array((int) $p_module['id_module'], $authorized_modules)) {
             $payment_modules[] = Module::getInstanceById((int) $p_module['id_module']);
         }
     }
     $this->context->smarty->assign(array('payment_modules' => $payment_modules));
     die(Tools::jsonEncode(array('result' => true, 'view' => $this->createTemplate('_select_payment.tpl')->fetch())));
 }
开发者ID:Rohit-jn,项目名称:hotelcommerce,代码行数:54,代码来源:AdminOrdersController.php

示例7: renderView

 public function renderView()
 {
     $neoExchange = new NeoExchanges(Tools::getValue('id_neo_exchange'));
     $order = new Order(Tools::getValue('id_neo_exchange'));
     if (!Validate::isLoadedObject($neoExchange)) {
         $this->errors[] = Tools::displayError('The order cannot be found within your database.');
     }
     $customer = new Customer($neoExchange->id_customer);
     //$carrier = new Carrier($neoExchange->id_carrier);
     $currency = new Currency((int) $neoExchange->id_currency);
     $buys = new NeoItemsBuyCore(Tools::getValue('id_neo_exchange'));
     $sales = new NeoItemsSalesCore(Tools::getValue('id_neo_exchange'));
     $products = $this->getProducts($buys);
     $products2 = $this->getProducts($sales);
     //$products = $this->getProducts($neoExchange);
     // Carrier module call
     /*$carrier_module_call = null;
             if ($carrier->is_module)
             {
                 $module = Module::getInstanceByName($carrier->external_module_name);
                 if (method_exists($module, 'displayInfoByCart'))
                     $carrier_module_call = call_user_func(array($module, 'displayInfoByCart'), $neoExchange->id_cart);
             }
     
             // Retrieve addresses information
             $addressInvoice = new Address($neoExchange->id_address_invoice, $this->context->language->id);
             if (Validate::isLoadedObject($addressInvoice) && $addressInvoice->id_state)
                 $invoiceState = new State((int)$addressInvoice->id_state);
     
             if ($neoExchange->id_address_invoice == $neoExchange->id_address_delivery)
             {
                 $addressDelivery = $addressInvoice;
                 if (isset($invoiceState))
                     $deliveryState = $invoiceState;
             }
             else
             {
                 $addressDelivery = new Address($neoExchange->id_address_delivery, $this->context->language->id);
                 if (Validate::isLoadedObject($addressDelivery) && $addressDelivery->id_state)
                     $deliveryState = new State((int)($addressDelivery->id_state));
             }*/
     $this->toolbar_title = sprintf($this->l('Intercambio #%1$d (%2$s) - %3$s %4$s'), $neoExchange->id, $neoExchange->reference, $customer->firstname, $customer->lastname);
     if (Shop::isFeatureActive()) {
         $shop = new Shop((int) $neoExchange->id_shop);
         $this->toolbar_title .= ' - ' . sprintf($this->l('Shop: %s'), $shop->name);
     }
     // gets warehouses to ship products, if and only if advanced stock management is activated
     $warehouse_list = null;
     $payment_methods = array();
     foreach (PaymentModule::getInstalledPaymentModules() as $payment) {
         $module = Module::getInstanceByName($payment['name']);
         if (Validate::isLoadedObject($module) && $module->active) {
             $payment_methods[] = $module->displayName;
         }
     }
     // display warning if there are products out of stock
     $display_out_of_stock_warning = false;
     $current_order_state = $neoExchange->getCurrentOrderState();
     if (Configuration::get('PS_STOCK_MANAGEMENT') && (!Validate::isLoadedObject($current_order_state) || $current_order_state->delivery != 1 && $current_order_state->shipped != 1)) {
         $display_out_of_stock_warning = true;
     }
     $total_buy = 0;
     $total_sale = 0;
     $products_buy = count($products);
     $products_sale = count($products2);
     // products current stock (from stock_available)
     foreach ($products as &$product) {
         $total_buy += $product['price'];
     }
     foreach ($products2 as &$product) {
         $total_sale += $product['price'];
     }
     $gender = new Gender((int) $customer->id_gender, $this->context->language->id);
     $history = $neoExchange->getHistory($this->context->language->id);
     foreach ($history as &$order_state) {
         $order_state['text-color'] = Tools::getBrightness($order_state['color']) < 128 ? 'white' : 'black';
     }
     // Smarty assign
     $this->tpl_view_vars = array('order' => $neoExchange, 'customer' => $customer, 'gender' => $gender, 'customer_addresses' => $customer->getAddresses($this->context->language->id), 'customerStats' => $customer->getStats(), 'products' => $products, 'products2' => $products2, 'total_buy' => $total_buy, 'total_sale' => $total_sale, 'products_buy' => $products_buy, 'products_sale' => $products_sale, 'neo_order_shipping_price' => 0, 'orders_total_paid_tax_incl' => $neoExchange->getOrdersTotalPaid(), 'total_paid' => $neoExchange->getTotalPaid(), 'returns' => OrderReturn::getOrdersReturn($neoExchange->id_customer, $neoExchange->id), 'customer_thread_message' => CustomerThread::getCustomerMessages($neoExchange->id_customer), 'orderMessages' => OrderMessage::getOrderMessages($neoExchange->id_lang), 'messages' => Message::getMessagesByOrderId($neoExchange->id, true), 'history' => $history, 'neoStatus' => NeoStatusCore::getNeoStatus(), 'warehouse_list' => $warehouse_list, 'sources' => ConnectionsSource::getOrderSources($neoExchange->id), 'currentState' => $neoExchange->getCurrentOrderState(), 'currency' => new Currency($neoExchange->id_currency), 'currencies' => Currency::getCurrenciesByIdShop($neoExchange->id_shop), 'previousOrder' => $neoExchange->getPreviousOrderId(), 'nextOrder' => $neoExchange->getNextOrderId(), 'current_index' => self::$currentIndex, 'iso_code_lang' => $this->context->language->iso_code, 'id_lang' => $this->context->language->id, 'can_edit' => $this->tabAccess['edit'] == 1, 'current_id_lang' => $this->context->language->id, 'invoices_collection' => $neoExchange->getInvoicesCollection(), 'not_paid_invoices_collection' => $neoExchange->getNotPaidInvoicesCollection(), 'payment_methods' => $payment_methods, 'invoice_management_active' => Configuration::get('PS_INVOICE', null, null, $neoExchange->id_shop), 'display_warehouse' => (int) Configuration::get('PS_ADVANCED_STOCK_MANAGEMENT'), 'HOOK_CONTENT_ORDER' => Hook::exec('displayAdminOrderContentOrder', array('order' => $neoExchange, 'products' => $products, 'customer' => $customer)), 'HOOK_CONTENT_SHIP' => Hook::exec('displayAdminOrderContentShip', array('order' => $neoExchange, 'products' => $products, 'customer' => $customer)), 'HOOK_TAB_ORDER' => Hook::exec('displayAdminOrderTabOrder', array('order' => $neoExchange, 'products' => $products, 'customer' => $customer)), 'HOOK_TAB_SHIP' => Hook::exec('displayAdminOrderTabShip', array('order' => $neoExchange, 'products' => $products, 'customer' => $customer)));
     return parent::renderView();
 }
开发者ID:TheTypoMaster,项目名称:neotienda,代码行数:81,代码来源:AdminIntercambioController.php

示例8: createAccountInApp

 public function createAccountInApp($email)
 {
     // Get default language
     $default_lang = (int) Configuration::get('PS_LANG_DEFAULT');
     $lang = new Language($default_lang);
     // Get order states
     $oss = OrderState::getOrderStates($default_lang);
     $states = array();
     foreach ($oss as $os) {
         $states[$os['id_order_state']] = $os['name'];
     }
     // Get payment modules
     $modules = array();
     $pms = PaymentModule::getInstalledPaymentModules();
     foreach ($pms as $pm) {
         $p = Module::getInstanceByName($pm['name']);
         $modules[$pm['id_module']] = $p->displayName;
     }
     $data = array('action' => 'createAccount', 'data' => array('shopUrl' => $this->context->shop->getBaseURL(), 'email' => $email, 'lang' => $lang->iso_code, 'modules' => $modules, 'states' => $states));
     return CheckYourDataWSHelper::send(self::$dcUrl, $data);
 }
开发者ID:adesse,项目名称:checkyourdata,代码行数:21,代码来源:checkyourdata.php

示例9: displayPaymentModules

 protected function displayPaymentModules()
 {
     $modules = PaymentModule::getInstalledPaymentModules();
     $output = '<fieldset><legend>' . $this->l('Payment modules AND COD') . '</legend>';
     $output .= '<table><tr><td>' . $this->l('Payment module') . '</td><td>' . $this->l('Is COD') . '</td></tr>';
     $codModules = Configuration::get($this->uppername . '_COD_MODULES');
     if ($codModules && strlen($codModules)) {
         $codModules = json_decode($codModules, true);
     }
     foreach ($modules as $module) {
         $instance = Module::getInstanceByName($module['name']);
         if ($instance->active) {
             if (isset($codModules[$instance->id])) {
                 $checked = " checked='checked'";
             } else {
                 $checked = "";
             }
             $output .= '<tr><td>' . $instance->displayName . '</td><td>
        <input type="checkbox" name="' . $this->uppername . '_COD_MODULES' . '[' . $instance->id . ']" ' . $checked . ' />
        </td></tr>';
         }
     }
     return $output . '</table></fieldset><br /><br />';
 }
开发者ID:ulozenka,项目名称:prestashop-1-5,代码行数:24,代码来源:ulozenka.php


注:本文中的PaymentModule::getInstalledPaymentModules方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。