Flocon de toile | Freelance Drupal: Render programmatically a unique field from a node or an entity with Drupal 8
Sometimes you want a View that follows the internal logic of the filters you set up on the View, but also can have some items hand selected or cultivated to the top of the View. Or perhaps the other way to describe it is a Nodequeue View that is backfilled with some other View based logic so that you end up with a full display regardless of how many items are actually in the Nodequeue.
To do this requires three adjustments to the View (assuming you have already built the normal View logic based on filters that are separate from Nodequeue.
- Make the Nodequeue a relationship to the View.
- Add the Nodequeu to the sort criteria.
- Restructure the filter settings to make it the Nodequeue logic OR the Filter logic.
Let's say you have a 3 item View that gets used to display some promoted items on your home page. You want the View to be populated by anything in the Nodequeue and then randomly backfilled with any other item(s) that match some filter criteria if the Nodequeue does not contain three items.
0) To start, create your View that has a maximum of 3 items and set the filter(s) to use your backfil critera (a status of published and limited to whatever entities you are using) and a sort of Global: Random to randomly pick from items that meet the filter criteria.
1) Add your Nodequeue as a relationship.
You want to limited to a specific Nodequeue. The relationship should not be required, or you will not have anything to backfill with.
2) Add the Nodequeue as sort criteria to the View.
Since we want the Nodequeue items to come first, and in order we have to set the sort order in front of the rest of the View sort criteria (which in this case is random).
3) Adjust the filter criteria and break it into logical sections. The first section is the set of filters that must be applied to all items regardless of whether they are in the Nodequeue or not. (the purple region below)
Then you need to create another filter group AND in this group put the items that are either the default logic OR the Nodequeue. The default logic in this case is that audience field matches some criteria. The trick is to set the operator within this filter group to OR.
Now when you add, delete or rearrange items in the Nodequeue the VIew will match the order of the Nodequeue and if you don't have enough items in your que, it will backfill from other items that meet your criteria.
Caching Issues: By default, updating a nodequeue will not cause the cache on the View to expire if the View is cached. If you need the updates to be immediately seen by anonymous users, you can implement a hook_nodequeue_update() to clear the cache.on any changes to that nodequeue.
On the ELMS:LN team, we’ve been working a lot with polymer and webcomponent based development this year. It’s our new workflow for all front-end development and we want Drupal to be the best platform for this type of development. At first, we made little elements and they were good. We stacked them together, and started integrating them into our user interfaces and polyfills made life happy.
As always, Chromatic had a great time at DrupalCon - we brought knowledge to share, and learned a lot!
In 2007, Jay Batson and I wanted to build a software company based on open source and Drupal. I was 29 years old then, and eager to learn how to build a business that could change the world of software, strengthen the Drupal project and help drive the future of the web.
Tom Erickson joined Acquia's board of directors with an outstanding record of scaling and leading technology companies. About a year later, after a lot of convincing, Tom agreed to become our CEO. At the time, Acquia was 30 people strong and we were working out of a small office in Andover, Massachusetts. Nine years later, we can count 16 of the Fortune 100 among our customers, saw our staff grow from 30 to more than 750 employees, have more than $150MM in annual revenue, and have 14 offices across 7 countries. And, importantly, Acquia has also made an undeniable impact on Drupal, as we said we would.
I've been lucky to have had Tom as my business partner and I'm incredibly proud of what we have built together. He has been my friend, my business partner, and my professor. I learned first hand the complexities of growing an enterprise software company; from building a culture, to scaling a global team of employees, to making our customers successful.
Today is an important day in the evolution of Acquia:
- Tom has decided it's time for him step down as CEO, allowing him flexibility with his personal time and act more as an advisor to companies, the role that brought him to Acquia in the first place.
- We're going to search for a new CEO for Acquia. When we find that business partner, Tom will be stepping down as CEO. After the search is completed, Tom will remain on Acquia's Board of Directors, where he can continue to help advise and guide the company.
- We are formalizing the working relationship I've had with Tom during the past 8 years by creating an Office of the CEO. I will focus on product strategy, product development, including product architecture and Acquia's roadmap; technology partnerships and acquisitions; and company-wide hiring and staffing allocations. Tom will focus on sales and marketing, customer success and G&A functions.
The time for these changes felt right to both of us. We spent the first decade of Acquia laying down the foundation of a solid business model for going out to the market and delivering customer success with Drupal – Tom's core strengths from his long career as a technology executive. Acquia's next phase will be focused on building confidently on this foundation with more product innovation, new technology acquisitions and more strategic partnerships – my core strengths as a technologist.
Tom is leaving Acquia in a great position. This past year, the top industry analysts published very positive reviews based on their dealings with our customers. I'm proud that Acquia made the most significant positive move of all vendors in last year's Gartner Magic Quadrant for Web Content Management and that Forrester recognized Acquia as the leader for strategy and vision. We increasingly find ourselves at the center of our customer's technology and digital strategies. At a time when digital experiences means more than just web content management, and data and content intelligence play an increasing role in defining success for our customers, we are well positioned for the next phase of our growth.
I continue to love the work I do at Acquia each day. We have a passionate team of builders and dreamers, doers and makers. To the Acquia team around the world: 2017 will be a year of changes, but you have my commitment, in every way, to lead Acquia with clarity and focus.
It's been a while since I've written a post here (especially, Drupal-related). But today I have something interesting to share.
There's a module called Search API sorts (https://drupal.org/project/search_api_sorts) that provides custom sorts and a global sort block for Search API. The module itself is ok, but ...
Drupal 6 kicked off way back in 2008. For the time it was a major breakthrough in technology, and the platform supported many major websites including whitehouse.gov. Over its lifespan Drupal 6 had more than 700 contributed modules and 600 custom themes. It boasted a nicer menu structure and an easier installation process than its predecessors, as well as improved security and a handy drag and drop menu. Drupal 6 was well ahead of its time. Now it is unsupported, outdated and frankly, old. It’s time for you and your website to move on.
What’s new in Drupal?
Drupal 8 (released November 2015) comes with a whole set of new built-in gadgets, including mobile responsive themes, built in web services to make it an API-first CMS, improved editorial experience, accessibility, powerful multilingual tools (at last), improved performance, HTML5, and better SEO and analytics tools. With over 18 months since releasing, it has become reliably stable, secure, and ready for you to make the switch.
Check out our 7 Reasons why Now is the Right Time to Move to Drupal 8
Why Drupal 6 isn’t a safe bet anymore
Without support from the community, Drupal 6 is going to be opened to more and more security risks. It’s modules will become outdated and unwieldy, and users will struggle to be able to get the performance they’ve come to expect with modern websites. While upgrading may seem like a daunting task, the business risks of remaining with Drupal 6 are far higher.
Migrations - easier than you think?
Believe it or not, Drupal 8 is stacked full of migration modules and toolsets to help you move your content from one platform to another. While many of these focus simply on moving a site between completely different platform, there are some that are designed to assist with moving between versions of Drupal. Depending on how your website was developed these can be tricky to use, and can lead to many hours of rework ‘rebuilding’ your website at the other end. If your website is stacked full of custom features, you may find that stock migration modules don’t quite provide the service you need.
Partners in Migration
If you’re a tech-whizz with a small website and plenty of time, you might find migrating your site on your own an exciting and economically sound venture. However, Drupal has become such a user friendly platform that many of its users skillsets are in marketing, communications and social relations. If that’s you, perhaps the thought of trying to move all your web content to another platform is so daunting you’ve been carefully looking the other way while Drupal 8 was released and took the world by storm.
With our assistance, your migration can not only be smooth and painless, but an opportunity to resolve some of those niggling website issues, and take a step forward into greater customer engagement. A shift to Drupal 8 can help you improve your conversions whilst making site maintenance easier.
Vardot - Drupal experts since 2011
Here at Vardot we’ve been supporting people since 2011. With our specialist team of Drupal experts we’re prepared to help migrate anything from a small two-page website, to a large scale page with multiple custom modules and integrations. Working with our team you’ll be on first name basis with our staff, and there is no shuffling between departments.
We believe in empowering our customers and our community - by giving back to the open source community. We promote a vibrant culture that benefits everyone involved. Working with us goes hand in hand with giving back, and you can be sure we’ll equip you with the skills and knowledge you need for the day-to-day management of your website moving forward.
If you have a site that needs migrating, or just a refresh, get in touch with us, we can’t wait to hear from you.Tags: drupal 8 Drupal Planet Title: Time to level up - Ditch Drupal 6 for the all new Drupal 8
Make your plans to join us for the Drupal Midwest Developer Summit, August 11-13, on the University of Michigan campus, in Ann Arbor MI.
Join us for 3 days this summer in Ann Arbor, Michigan, for the 2017 Midwest Drupal Summit.
For this year’s Summit, we’ll gather on the beautiful University of Michigan campus for three days of code sprints, working on issues such as porting modules and writing, updating documentation and informal presentations. We will start around 10AM and finish around 5PM each day.
Lunch, Coffee and Snacks will be provided each day.
What’s New This Year at MWDS?
This year, we’re adding lightning talks (more Drupal learnings!) and a social outing (more Drupal fun!)
What’s The Same?
Relaxed, low-key sprinting and socializing with Drupal core contributors and security team members.
What you can expect:
- An opportunity to learn from Drupal core contributors and mentors, including Angie “webchick” Byron, Michael Hess, Peter Wolanin, Neil Drumm and xjm.
- Code sprints. Let’s clear out some queues!
- Help Porting modules to Drupal 8.
- Lighting talks
- Security issue sprints
- Documentation writing
- Good food and good community.
Ann Arbor is about 30 minutes by car from Detroit Metro Airport. Ann Arbor is also served by Amtrak.
Questions? Contact email@example.com
Mollom was created by Dries Buytaert and Benjamin Schrauwen, and launched to a few beta testers (including myself) in 2007. Mollom was acquired by Acquia in 2012.
The service worked generally well, with the occasional spam comment getting through. The stated reason for stopping the service is that spammers have gotten more sophisticated, and that perhaps means that Mollom needs to try harder to keep up with the ever changing tactics. Much like computer viruses and malware, spam (email or comments) is an arms race scenario.
But there is a problem with this combinationa: reCAPTCHA, like all modules that depend on the CAPTCHA module, disable the page cache for any form that has CAPTCHA enabled.
This is due to this piece of code in captcha.module:// Prevent caching of the page with CAPTCHA elements.
// This needs to be done even if the CAPTCHA will be ommitted later:
// other untrusted users should not get a cached page when
// the current untrusted user can skip the current CAPTCHA.
Another alternative that we have been using that does not disable the page cache is antibot module.
To install the antibot module, you can use your git repository, or the following drush commands:drush dis mollom
drush dl antibot
drush en antibot
Visit the configuration page for antibot if you want to add more forms that use the module, or disable it from other forms. The default settings work for comments, user registrations, and use logins.
Because of the above mentioned arms race situation, expect spammers to come up with circumvention techniques at some point in the future, and there will be a need to use other measures, be they in antibot, or other alternatives.Contents:
Here is where we bring awareness to Drupal modules running on less than 1% of reporting sites. Today we'll investigate Footermap, a module which renders the results expanded menus in a block.
Setting a clear list of expectation to the client for a project delivery goes a long way to great client relationships. A mismatched and misunderstood project goal and target always leads to dissatisfaction among team members, account head, and all other stakeholders.
I manage a team of a few developers who build web applications in Drupal. While working on projects with my team, I have had the chance to practice a few of the points that I have mentioned in the article. It has not only kept us on track but also kept people happy and motivated.What should you do? Be involved from the beginning
When you begin a project makes sure that you and your team members are involved in the project from the beginning. There are times when the team would expand…
In this post, you will learn how to create a custom date format for Drupal 7.Read more
The benefits of Rich snippets and how to implement structured data in Drupal 8 to enhance the way your pages are listed by search engines.
Lightning has used the Layout Plugin module since before our first beta release. Starting in Drupal 8.3.0, the functionality provided by the Layout Plugin module was largely duplicated in Layout Discovery and released as part of the Core Experimental group. Lightning migrated to Layout Discovery in 2.1.1.
The Lightning team feels like it's a win anytime we can migrate from contrib to core. But another advantage of this is that since Layout Discovery is in Core, security issues can be filed against it in the Core security issue queue which is monitored by the Security Team. Layout Plugin, being alpha, didn't have a security issue queue.
Technically, Layout Discovery is an Experimental core module though. And the new Status Report page warns users if any Experimental modules are enabled. As a result users of Lightning are presented with this unhelpful message when they visit /admin/reports/status:
The problem is, this message isn't actionable. Lightning made the decision to enable it. The only way to disable it would be to completely opt out of all of Lightning's Layout functionality.
To be clear, the Lightning team feels that the Layout Discovery module is certainly stable enough to run predictably and reliably on production websites. This warning from core is supposed to indicate that the underlying API might change or that it might ultimately be removed from the core package. Under either of those circumstances, Lightning would provide a migration script or otherwise support users.
We feel that warning a user after they (or their site builder) has made the decision to use an experimental module is in-actionable nagging. We support warning site builders when installing an experimental module, but not constantly reminding them of that decision.
Starting in 2.1.4, Lightning will include a core patch that removes the warnings for experimental modules on the status page. The patch does not affect the existing warning that is shown during installation of experimental modules.
There are two other "nagging" warnings that Lightning will remove in 2.1.4. Specifically, it will stop warning the user if:
- The config sync directory exists but isn't writable (no reason to write to the config directory on prod, for example)
- The update module isn't enabled (update module creates overhead and updates might be handled by a separate system)
Related, there is also a larger discussion around what the requirements should be for reporting on the status page. Discuss!Summary of new patches related to reporting that will be included in 2.1.4:
To give more insight into Drupal Association financials, we are launching a blog series. This is the first one in the series and it is for all of you who love knowing the inner workings. It provides an overview of:
- Our forecasting process
- How financial statements are approved
- The auditing process
- How we report financials to the U.S. government via 990s
There’s a lot to share in this blog post and we appreciate you taking the time to read it.Replacing Annual Budgets With Rolling Forecasts
Prior to 2016, the Drupal Association produced an annual budget, which is a common practice for non-profits. However, two years ago, we found that the Drupal market was changing quickly and that impacted our projected revenue. Plus, we needed faster and more timely performance analysis of pilot programs so we could adjust projections and evaluate program success throughout the year. In short, we needed to be more agile with our financial planning, so we moved to a rolling forecast model, using conservative amounts.
Using a rolling forecast means we don’t have a set annual budget. Instead, we project revenue and expense two years out into a forecast. Then, we update the forecast several times a year as we learn more. The first forecast of the year is similar to a budget. We study variance against this version throughout the year. As we conduct the additional forecasts during the year, we replace forecasts of completed months with actual expenses and income (“actuals”) and revise forecasts for the remaining months. This allows us to see much more clearly if we are on or off target and to adjust projections as conditions that could impact our financial year change and evolve. For example, if we learn that the community wants us to change a drupal.org ad placement that could impact revenue, we will downgrade the revenue forecast appropriately for this product.
In 2017, we there will be three forecasts:
- December 2016: The initial forecast was created. This serves as our benchmark for the year and we run variances against it.
- May 2017: We updated the forecast after DrupalCon Baltimore since this event has the biggest impact on both our expenses and revenue for the year.
- October 2017: We will reforecast again after DrupalCon Vienna. This is our final update before the end of the year and will be the benchmark forecast for 2018.
Creating and approving the forecasts is a multi-party process.
Staff create the initial forecast much like you would a budget. They are responsible for their income and expense budget line items and insert them into the forecasting worksheet. They use historical financials, vendor contracts and quotes, and more to project the amount for each line item and document all of their assumptions. Each budget line manager reviews those projections and assumptions with me. I provide guidance and challenge assumptions and sign off on the inputs
Our virtual CFO firm, Summit CPA, analyzes the data and provides financial insight including: Income Statement, Balance Sheet, Cash Flow, and Margin Analysis. Through these reports, we can see how we are positioned to perform against our financial KPIs. This insight allows us to make changes or strengthen our focus on certain areas to ensure we are moving towards those KPIs - which I will talk about in another blog post. Once these reports are generated, the Drupal Association board finance committee receives them along with the forecasting assumptions. During a committee meeting, the committee is briefed by Summit and myself. They ask questions to make sure various items are considered in the forecast and they provide advice for me to consider as we work to improve our financial health.
Once the committee reviews the forecast and assumptions, then, the full board reviews it in an Executive Session. The board asks questions and provides advice as well. This review process happens with all three forecasts for the year.
As we move through the year, our Operations Manager and CFO team work together to close the books each month. This ensures our monthly actuals are correct. Then, our CFO team creates a monthly financial report that includes our financial statements (Income Statement and Balance Sheet) for the finance committee to review and approve. Each month the finance committee meets virtually and the entire team reviews the most recently prepared report. After asking questions and providing advice, the committee approves the report.
The full board receives copies of the financial reports quarterly and is asked to review and approve the statements for the preceding three months. Board members can ask questions, provide advice, and approve the statements in Executive Session or in the public board meeting. After approval, I write a blog post so the community can access and review the financial statements. You can see an example of the Q3 2016 financial statement blog here. The board just approved the Q4 2016 financials and I will do a blog post shortly to share the financial statements.Financial Audits
Every two or three years the Association contracts to have the financial practices and transactions audited. For the years that we do not conduct a full audit, we will contract for a “financial review” by our CPA firm (which is separate from our CFO firm) to ensure our financial policies and transactions are in good order.
An audit is an objective examination and evaluation of the financial statements of an organization to make sure that the records are a fair and accurate representation of the transactions they claim to represent. It can be done internally by employees of the organization, or externally by an outside firm. Because we want accountability, we contracted with an external CPA firm, McDonald Jacobs, to handle the audit.
The Drupal Association conducts audits for several reasons:
to demonstrate our commitment to financial transparency.
to assure our community that we follow appropriate procedures to ensure that the community funds are being handled with care.
to give our board of directors outside assurance that the financial statements are free of material misstatements.
What do the auditors look at? For 2016, our auditors will generally focus on three points:
Proper recording of income and expense: Auditors will ensure that our financial statements are an accurate representation of the business we have conducted. Did we record transactions on the right date, to the right account, and the right class? In other words, if we said that 2016 revenue was a certain amount, is that really true?
Financial controls: Preventing fraud is an important part of the audit. It is important to put the kinds of controls in place that can prevent common types of fraud, such as forged checks and payroll changes. Auditors look to see that there are two sets of eyes on every transaction, and that documentation is provided to verify expenses and check requests.
Policies and procedures: There are laws and regulations that require we have certain policies in place at our organization. Our auditors will look at our current policies to ensure they were in place and, in some cases, had been reviewed by the board and staff.
The primary goal of the audit is for the auditor to express an opinion on two aspects of the financial statements of the Association: the financial statements are fairly presented, and they are in accordance with generally accepted accounting principles (GAAP). Generally accepted accounting principles are the accepted body of accounting rules and policies established by the accounting profession. The purpose of these rules is to promote consistency and fairness in financial reporting throughout the business community. These principles provide comparability of financial information.
Once our audit for 2016 is complete and approved by the board (expected in early summer), we can move to have the 990 prepared. We look to have this item completed by September 2016.Tax Filing: The Form 990
As a U.S.-based 501c3 exempt organization, and to maintain this tax-exempt status, the U.S. Internal Revenue Service (IRS) requires us to file a 990 each year. Additionally, this form is also filed with state tax departments as well. The 990 is meant for the IRS and state regulators to ensure that non-profits continue to serve their stated charitable activities. The 990 can be helpful when you are reviewing our programs and finances, but know that it’s only a “snapshot” of our year.
Here are some general points, when reviewing our 990.FORM 990, PART I—REVENUES, EXPENSES, AND CHANGES IN NET ASSETS OR FUND BALANCES
Lines 8-12 indicates our yearly revenue revenue. Not only how much total revenue (line 12), but also where we have earned our income, broken out into four groups. Line 12 is the most important: total income for the year.
Lines 13-18 shows expenses for the year, and where we focused.
Cash Reserves are noted on lines 20-22 on page 1.
The 990 has a comparison of the net assets from last year (or the beginning of the year) and the end of the current year, as well as illustrates the total assets and liabilities of the Association.FORM 990, PART II—STATEMENT OF FUNCTIONAL EXPENSES
Part II shows our expenditures by category and major function (program services, management and general, and fundraising).FORM 990, PART III—STATEMENT OF PROGRAM SERVICE ACCOMPLISHMENTS
In Part III, we describe the activities performed in the previous year that adhere to our 501c3 designation. You can see here that Drupal.org, DrupalCon and our Fiscal Sponsorship programs are noted.FORM 990, PART IV—BALANCE SHEETS
Part IV details our assets and liabilities. Assets are our resources that we have at our disposal to execute on our mission. Liabilities are the outstanding claims against those assets.FORM 990, PART V—LIST OF OFFICERS, DIRECTORS, TRUSTEES AND KEY EMPLOYEES
Part V lists our board and staff who are responsible in whole or in part for the operations of an organization. These entries do include titles and compensation of key employees.FORM 990, PART VI—OTHER INFORMATION
This section contains a number of questions regarding our operations over the year. Any “yes” answers require explanation on the following page.Schedule A, Part II—Compensation of the Five Highest Paid Independent Contractors for Professional Services
We list any of our contractors, if we have paid them more than $50,000, on this schedule.
Once our 990 is complete and filed we are required to post the return publicly, which we do here on our website. We expect to have the 2016 990 return completed, filed and posted by September 2017.
Phew. I know that was long. Thank you for taking the time to read all of the steps we take to ensure financial health and accuracy. We are thankful for the great team work that goes into this process. Most of all we are thankful for our funders who provide the financial fuel for us to do our mission work.
Stay tuned for our next blog in this series: Update on Q4 2016 financial (to follow up on our Q3 2016 financial update)
The important first step for media support in core just landed in Drupal 8.4.x: a new beta experimental Media module to support storing media of various types. While Drupal core already has generic file upload and image upload support, the new module will support asset reuse and be extensible to support video, remote media, embedding, and so on.
This is a huge testament to individuals and organizations with shared interests pulling together, figuring out how to make it happen in core, and getting it done. 89 individuals (both volunteering their own time and from various companies all across the world) contributed both directly in the core patch and via involvement with the contributed Media Entity module:
That said, this is just the first step. (If you go and enable the core Media module, all it can do right now is give you an error message that no media types can be created.) The next steps are to add a file/document media plugin and an image media plugin so these types of media may be created on the site with the module. Then, widgets and formatters for the upload field and image field interfaces will be added so we can reproduce the existing core functionality with media. Adam Hoenich wrote up a concise summary of the next steps, and granular details are listed in the followup roadmap.
There are definitely more tasks than people available, so your contributions would be more than welcome! Now is the time to make sure media is integrated in a way that your projects can best utilize it. Get involved through the media IRC meetings happening at 2pm GMT every week in #drupal-media. (See https://www.drupal.org/irc for more information on Drupal IRC). Or, if you are available at other times, ask in the channel. The issues are listed on the Media Initiative plan.
Let's put the remaining pieces in place together!