This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Implements hook_entity_type_alter() | |
| * scheduled_update listing page is not providing content related information, | |
| * we have added content related columns in scheduled update listing pages. | |
| */ | |
| //function customizations_entity_type_alter(array &$entity_types) { | |
| // /** @var $entity_types \Drupal\Core\Entity\EntityTypeInterface[] */ | |
| // $entity_types['scheduled_update']->setListBuilderClass('Drupal\customizations\CustomScheduledUpdateListBuilder'); | |
| //} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| braintree-hosted-fields: | |
| remote: https://github.com/braintree/braintree-web | |
| version: "3.19.1" | |
| license: | |
| name: MIT | |
| url: https://github.com/braintree/braintree-web/blob/3.19.1/LICENSE | |
| gpl-compatible: true | |
| js: | |
| "https://js.braintreegateway.com/web/3.19.1/js/hosted-fields.min.js": { minified: true } | |
| dependencies: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| git remote -v | |
| to add upstream url: | |
| git remote add upstream https://gitlab.test.de/drupal/website.git | |
| to modify upstream url: | |
| git remote set-url upstream https://gitlab.test.de/sureshk/website.git | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| use Drupal\Core\Url; | |
| use Drupal\Core\Link; | |
| $url = Url::fromRoute('entity.contact_form.canonical', ['contact_form' => 'ventures_contact_form'], [ | |
| 'query' => ['venture_id' => 3], | |
| 'absolute' => TRUE, | |
| ]); | |
| $project_link = Link::fromTextAndUrl(t('Conatact venture'), $url); | |
| $project_link = $project_link->toRenderable(); | |
| $project_link['#attributes'] = ['class' => ['use-ajax'], 'data-dialog-type' => ['modal']]; | |
| $project_link['#prefix'] = '<div class="btn venture-contact-button" >'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| change node__field_location to your address field table name , column name also | |
| $query = \Drupal::database()->select('node__field_location', 'fa'); | |
| $query->fields('fa', ['field_location_locality']); | |
| $query->condition('bundle', 'venture'); | |
| // $query->condition('field_location_locality', '', 'like'); | |
| // $query->condition('field_location_country_code', ''); | |
| $query->distinct(); | |
| $query->orderBy('field_location_locality'); | |
| $courseRatings = $query->execute()->fetchAll(\PDO::FETCH_ASSOC); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var cellText = "composer require "; jQuery("#edit-missing-module-list > tbody > tr > td:nth-child(1)").each(function() { | |
| var cellText2 = jQuery(this).html(); cellText += ' drupal/' + cellText2; | |
| }); jQuery('#system-breadcrumb').text(cellText); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| echo '<pre>' ;print_r( $query->conditions()); | |
| echo '<pre>' ; print_r($result->getQueryString()); exit; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $user_list[] = "$user->name ($user->mail) last active on " . | |
| \Drupal::service('date.formatter')->format($user->access, 'long'); | |
| $data = ['#theme'=>'item_list','#type'=>'ul','#items'=>$user_list]; | |
| $user_list = \Drupal::service('renderer')->renderRoot($data); | |
| \Drupal\Core\Render\Markup::create(); |