@@ -104,8 +104,8 @@ |
||
| 104 | 104 | $products = entity_load('commerce_product'); |
| 105 | 105 | $products_key = array_keys($products); |
| 106 | 106 | $products_number = count($products_key); |
| 107 | - $count = $products_number < $items_number ? $products_number: $items_number; |
|
| 108 | - for($i = 0; $i < $count; $i++) { |
|
| 107 | + $count = $products_number < $items_number ? $products_number : $items_number; |
|
| 108 | + for ($i = 0; $i < $count; $i++) { |
|
| 109 | 109 | $product = $products[$products_key[rand(0, $products_number - 1)]]; |
| 110 | 110 | $line_item = commerce_product_line_item_new($product, 1, $order->order_id); |
| 111 | 111 | commerce_line_item_save($line_item); |
@@ -137,7 +137,7 @@ |
||
| 137 | 137 | * The machine name of the scenario feature. |
| 138 | 138 | * @param string $rollback |
| 139 | 139 | * Boolean: rollback existing demo content. |
| 140 | - */ |
|
| 140 | + */ |
|
| 141 | 141 | function drush_df_admin_reset_scenario($scenario) { |
| 142 | 142 | $rollback = drush_get_option('rollback', TRUE); |
| 143 | 143 | $seed = drush_get_option('seed', TRUE); |
@@ -17,7 +17,7 @@ |
||
| 17 | 17 | // have control over that file via build scripts. |
| 18 | 18 | // If RestWS had a real way to deal with CORS/preflight, we would use that. |
| 19 | 19 | if ($_SERVER['REQUEST_METHOD'] == 'OPTIONS') { |
| 20 | - echo "";die; |
|
| 20 | + echo ""; die; |
|
| 21 | 21 | } |
| 22 | 22 | } |
| 23 | 23 | |
@@ -21,9 +21,9 @@ discard block |
||
| 21 | 21 | 'category' => 'Add HTML', |
| 22 | 22 | 'reusable' => false, |
| 23 | 23 | 'uuid' => $uuid, |
| 24 | - 'field_raw_html' => array ( |
|
| 25 | - 'und' => array ( |
|
| 26 | - 0 => array ( |
|
| 24 | + 'field_raw_html' => array( |
|
| 25 | + 'und' => array( |
|
| 26 | + 0 => array( |
|
| 27 | 27 | 'value' => $html, |
| 28 | 28 | 'format' => 'raw_html', |
| 29 | 29 | ), |
@@ -50,16 +50,16 @@ discard block |
||
| 50 | 50 | 'category' => 'Add Map', |
| 51 | 51 | 'reusable' => false, |
| 52 | 52 | 'uuid' => $uuid, |
| 53 | - 'field_map_address' => array ( |
|
| 54 | - 'und' => array ( |
|
| 55 | - 0 => array ( |
|
| 53 | + 'field_map_address' => array( |
|
| 54 | + 'und' => array( |
|
| 55 | + 0 => array( |
|
| 56 | 56 | 'value' => $address, |
| 57 | 57 | ), |
| 58 | 58 | ), |
| 59 | 59 | ), |
| 60 | - 'field_map_information' => array ( |
|
| 61 | - 'und' => array ( |
|
| 62 | - 0 => array ( |
|
| 60 | + 'field_map_information' => array( |
|
| 61 | + 'und' => array( |
|
| 62 | + 0 => array( |
|
| 63 | 63 | 'value' => $info, |
| 64 | 64 | 'format' => 'full_html', |
| 65 | 65 | ), |
@@ -3,7 +3,7 @@ |
||
| 3 | 3 | /** |
| 4 | 4 | * Implements of hook_menu() |
| 5 | 5 | */ |
| 6 | -function dfs_med_base_menu(){ |
|
| 6 | +function dfs_med_base_menu() { |
|
| 7 | 7 | $items['empty-page'] = array( |
| 8 | 8 | 'title' => 'Redirect', |
| 9 | 9 | 'description' => 'Redirect user.', |
@@ -89,7 +89,7 @@ |
||
| 89 | 89 | $import_path = drupal_get_path('module', 'dfs_med') . '/import/'; |
| 90 | 90 | $this->source = new MigrateSourceCSV($import_path . 'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
| 91 | 91 | $this->addFieldMapping('value', 'video'); |
| 92 | - } |
|
| 92 | + } |
|
| 93 | 93 | |
| 94 | 94 | function csvcolumns() { |
| 95 | 95 | $columns[10] = array('video', 'Video'); |
@@ -22,10 +22,10 @@ discard block |
||
| 22 | 22 | MigrateDestinationNode::getKeySchema() |
| 23 | 23 | ); |
| 24 | 24 | |
| 25 | - $import_path = drupal_get_path('module', 'dfs_med') . '/import/'; |
|
| 25 | + $import_path = drupal_get_path('module', 'dfs_med').'/import/'; |
|
| 26 | 26 | |
| 27 | 27 | // Create a MigrateSource object. |
| 28 | - $this->source = new MigrateSourceCSV($import_path . 'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 28 | + $this->source = new MigrateSourceCSV($import_path.'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 29 | 29 | $this->destination = new MigrateDestinationNode('episode'); |
| 30 | 30 | |
| 31 | 31 | // Created |
@@ -34,7 +34,7 @@ discard block |
||
| 34 | 34 | // Splash Image |
| 35 | 35 | $this->addFieldMapping('field_splash_image', 'splash'); |
| 36 | 36 | $this->addFieldMapping('field_splash_image:file_replace')->defaultValue(FILE_EXISTS_REPLACE); |
| 37 | - $this->addFieldMapping('field_splash_image:source_dir')->defaultValue($import_path . 'images'); |
|
| 37 | + $this->addFieldMapping('field_splash_image:source_dir')->defaultValue($import_path.'images'); |
|
| 38 | 38 | $this->addFieldMapping('field_splash_image:destination_file', 'filename'); |
| 39 | 39 | |
| 40 | 40 | // Metadata |
@@ -86,8 +86,8 @@ discard block |
||
| 86 | 86 | MigrateDestinationFile::getKeySchema() |
| 87 | 87 | ); |
| 88 | 88 | $this->destination = new MigrateDestinationFile('video', 'MigrateExtrasFileYoutube'); |
| 89 | - $import_path = drupal_get_path('module', 'dfs_med') . '/import/'; |
|
| 90 | - $this->source = new MigrateSourceCSV($import_path . 'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 89 | + $import_path = drupal_get_path('module', 'dfs_med').'/import/'; |
|
| 90 | + $this->source = new MigrateSourceCSV($import_path.'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 91 | 91 | $this->addFieldMapping('value', 'video'); |
| 92 | 92 | } |
| 93 | 93 | |
@@ -6,9 +6,9 @@ |
||
| 6 | 6 | |
| 7 | 7 | class DFToolsBeanBlock extends BeanPlugin { |
| 8 | 8 | |
| 9 | - /** |
|
| 10 | - * Declares default block settings. |
|
| 11 | - */ |
|
| 9 | + /** |
|
| 10 | + * Declares default block settings. |
|
| 11 | + */ |
|
| 12 | 12 | public function values() { |
| 13 | 13 | return array( |
| 14 | 14 | 'view_mode' => 'default', |
@@ -89,7 +89,7 @@ |
||
| 89 | 89 | $import_path = drupal_get_path('module', 'dfs_med') . '/import/'; |
| 90 | 90 | $this->source = new MigrateSourceCSV($import_path . 'dfs_med.nodes.episode.csv', $this->csvcolumns(), array('header_rows' => 1)); |
| 91 | 91 | $this->addFieldMapping('value', 'video'); |
| 92 | - } |
|
| 92 | + } |
|
| 93 | 93 | |
| 94 | 94 | function csvcolumns() { |
| 95 | 95 | $columns[10] = array('video', 'Video'); |
@@ -10,14 +10,14 @@ discard block |
||
| 10 | 10 | public function __construct($arguments) { |
| 11 | 11 | parent::__construct($arguments); |
| 12 | 12 | $this->description = t('Import nodes.'); |
| 13 | - $import_path = drupal_get_path('module', 'dfs_wem') . '/import/'; |
|
| 13 | + $import_path = drupal_get_path('module', 'dfs_wem').'/import/'; |
|
| 14 | 14 | // Create a MigrateSource object. |
| 15 | - $this->source = new MigrateSourceCSV($import_path . 'dfs_wem.nodes.wem_news.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 15 | + $this->source = new MigrateSourceCSV($import_path.'dfs_wem.nodes.wem_news.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 16 | 16 | $this->destination = new MigrateDestinationNode('wem_news'); |
| 17 | 17 | // Image |
| 18 | 18 | $this->addFieldMapping('field_wem_image', 'image'); |
| 19 | 19 | $this->addFieldMapping('field_wem_image:file_replace')->defaultValue(FILE_EXISTS_REPLACE); |
| 20 | - $this->addFieldMapping('field_wem_image:source_dir')->defaultValue($import_path . 'images'); |
|
| 20 | + $this->addFieldMapping('field_wem_image:source_dir')->defaultValue($import_path.'images'); |
|
| 21 | 21 | $this->addFieldMapping('field_wem_image:destination_file', 'filename'); |
| 22 | 22 | // Video |
| 23 | 23 | $this->addFieldMapping('field_wem_video', 'video')->sourceMigration('DFSWEMNewsVideo'); |
@@ -63,8 +63,8 @@ discard block |
||
| 63 | 63 | MigrateDestinationFile::getKeySchema() |
| 64 | 64 | ); |
| 65 | 65 | $this->destination = new MigrateDestinationFile('video', 'MigrateExtrasFileYoutube'); |
| 66 | - $import_path = drupal_get_path('module', 'dfs_wem') . '/import/'; |
|
| 67 | - $this->source = new MigrateSourceCSV($import_path . 'dfs_wem.nodes.wem_news.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 66 | + $import_path = drupal_get_path('module', 'dfs_wem').'/import/'; |
|
| 67 | + $this->source = new MigrateSourceCSV($import_path.'dfs_wem.nodes.wem_news.csv', $this->csvcolumns(), array('header_rows' => 1)); |
|
| 68 | 68 | $this->addFieldMapping('value', 'video'); |
| 69 | 69 | } |
| 70 | 70 | |
@@ -1,1 +1,1 @@ |
||
| 1 | -<span id="views_slideshow_controls_text_previous_<?php print $variables['vss_id']; ?>" class="<?php print $classes;?> slide-nav-wrap"><a href="#"><img src="<?php print base_path() . path_to_theme(); ?>/images/hero-carousel-prev.svg"></a></span> |
|
| 1 | +<span id="views_slideshow_controls_text_previous_<?php print $variables['vss_id']; ?>" class="<?php print $classes; ?> slide-nav-wrap"><a href="#"><img src="<?php print base_path().path_to_theme(); ?>/images/hero-carousel-prev.svg"></a></span> |
|