當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Factory::getRepositoryFactory方法代碼示例

本文整理匯總了PHP中magento\mtf\factory\Factory::getRepositoryFactory方法的典型用法代碼示例。如果您正苦於以下問題:PHP Factory::getRepositoryFactory方法的具體用法?PHP Factory::getRepositoryFactory怎麽用?PHP Factory::getRepositoryFactory使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在magento\mtf\factory\Factory的用法示例。


在下文中一共展示了Factory::getRepositoryFactory方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: _initData

 /**
  * Initialize fixture data
  *
  * @SuppressWarnings(PHPMD.ExcessiveMethodLength)
  */
 protected function _initData()
 {
     $this->_data['checkout'] = ['prices' => ['price_from' => 110, 'price_to' => 120], 'selection' => [0]];
     parent::_initData();
     $this->_data['fields'] = array_merge_recursive($this->_data['fields'], ['sku_type' => ['value' => 'Fixed', 'input_value' => '1', 'group' => static::GROUP_PRODUCT_DETAILS, 'input' => 'select'], 'price_type' => ['value' => 'Fixed', 'input_value' => '1', 'group' => static::GROUP_PRODUCT_DETAILS, 'input' => 'select'], 'price' => ['value' => 100, 'group' => static::GROUP_PRODUCT_DETAILS], 'tax_class_id' => ['value' => 'Taxable Goods', 'input_value' => '2', 'group' => static::GROUP_PRODUCT_DETAILS, 'input' => 'select'], 'weight_type' => ['value' => 'Fixed', 'input_value' => '1', 'group' => static::GROUP_PRODUCT_DETAILS, 'input' => 'select'], 'weight' => ['value' => '1', 'group' => static::GROUP_PRODUCT_DETAILS], 'product_website_1' => ['value' => 'Yes', 'input_value' => [1], 'group' => static::GROUP_PRODUCT_WEBSITE, 'input' => 'checkbox', 'input_name' => 'website_ids'], 'shipment_type' => ['value' => 'Separately', 'input_value' => '1', 'group' => static::GROUP_PRODUCT_DETAILS, 'input' => 'select'], 'bundle_selections' => ['value' => ['bundle_options' => [['title' => 'Drop-down Option', 'type' => 'Drop-down', 'required' => 'Yes', 'assigned_products' => [['search_data' => ['name' => '%item1_simple1::getName%'], 'data' => ['selection_price_value' => 10, 'selection_price_type' => 'Fixed', 'selection_qty' => 1, 'product_id' => '%item1_simple1::getProductId%']], ['search_data' => ['name' => '%item1_virtual2::getName%'], 'data' => ['selection_price_value' => 20, 'selection_price_type' => 'Percent', 'selection_qty' => 1, 'product_id' => '%item1_virtual2::getProductId%']]]]]], 'group' => static::GROUP]]);
     $this->_repository = Factory::getRepositoryFactory()->getMagentoBundleBundle($this->_dataConfig, $this->_data);
 }
開發者ID:,項目名稱:,代碼行數:12,代碼來源:

示例2: _initData

 /**
  * Initialize fixture data
  */
 protected function _initData()
 {
     $this->_data = ['fields' => ['code' => ['value' => 'Test group %isolation%'], 'tax_class' => ['value' => 'Retail Customer', 'input_value' => 3]]];
     $this->_defaultConfig = [];
     $this->_repository = Factory::getRepositoryFactory()->getMagentoCustomerCustomerGroup($this->_dataConfig, $this->_data);
 }
開發者ID:shabbirvividads,項目名稱:magento2,代碼行數:9,代碼來源:CustomerGroup.php

示例3: _initData

 /**
  * {inheritdoc}
  */
 protected function _initData()
 {
     $this->_repository = Factory::getRepositoryFactory()->getMagentoShippingMethod($this->_dataConfig, $this->_data);
     //Default data set
     $this->switchData('flat_rate');
 }
開發者ID:kidaa30,項目名稱:magento2-platformsh,代碼行數:9,代碼來源:Method.php

示例4: _initData

 /**
  * {inheritdoc}
  *
  * @SuppressWarnings(PHPMD.ExcessiveMethodLength)
  */
 protected function _initData()
 {
     $this->_data = ['fields' => ['attribute_code' => ['value' => 'attribute_code_%isolation%', 'group' => self::GROUP_PRODUCT_ATTRIBUTE_MAIN], 'frontend_label' => ['value' => 'Attribute %isolation%', 'input_name' => 'frontend_label[0]', 'group' => self::GROUP_PRODUCT_ATTRIBUTE_MAIN], 'frontend_input' => ['value' => 'Dropdown', 'input' => 'select', 'input_value' => 'select', 'group' => self::GROUP_PRODUCT_ATTRIBUTE_MAIN], 'is_searchable' => ['value' => 'Yes', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT], 'is_visible_in_advanced_search' => ['value' => 'Yes', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT], 'is_comparable' => ['value' => 'Yes', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT], 'is_filterable' => ['value' => 'Filterable (with results)', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT], 'is_visible_on_front' => ['value' => 'Yes', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT], 'is_filterable_in_search' => ['value' => 'Yes', 'input' => 'select', 'input_value' => 1, 'group' => self::GROUP_PRODUCT_ATTRIBUTE_FRONT]], 'options' => ['value' => ['option_1' => ['label' => ['value' => 'Option 1 %isolation%', 'input_name' => 'option[value][option_0][0]', 'selector' => '//*[@id="manage-options-panel"]/table/tbody/tr[1]/td[3]/input', 'strategy' => Locator::SELECTOR_XPATH], 'default' => ['value' => 'Yes', 'input' => 'checkbox', 'input_name' => 'default[0]', 'input_value' => 'option_0', 'selector' => '//*[@id="manage-options-panel"]/table/tbody/tr[1]/td[2]/input', 'strategy' => Locator::SELECTOR_XPATH]], 'option_2' => ['label' => ['value' => 'Option 2 %isolation%', 'input_name' => 'option[value][option_1][0]', 'selector' => '//*[@id="manage-options-panel"]/table/tbody/tr[2]/td[3]/input', 'strategy' => Locator::SELECTOR_XPATH], 'default' => ['value' => 'No', 'input' => 'checkbox', 'input_name' => 'default[1]', 'input_value' => 'option_1', 'selector' => '//*[@id="manage-options-panel"]/table/tbody/tr[2]/td[2]/input', 'strategy' => Locator::SELECTOR_XPATH]]]]];
     $this->_repository = Factory::getRepositoryFactory()->getMagentoCatalogProductAttribute($this->_dataConfig, $this->_data);
 }
開發者ID:shabbirvividads,項目名稱:magento2,代碼行數:10,代碼來源:ProductAttribute.php


注:本文中的magento\mtf\factory\Factory::getRepositoryFactory方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。