DrJ Engineering and Certification

A dual-identity site with a blazing-fast customized search

DrJ Engineering provides full-service structural engineering and product certification services to simplify the code compliance process and bring innovative building products to market. DrJ’s Technical Evaluation Reports (TERs) evaluate a product or process and are used frequently to show building officials throughout the U.S. and Canada that a given product (often newly-developed) complies with the applicable building codes.

Technologies Used:
Drupal React

When DrJ told us that they wanted to build a site that could dynamically apply an engineer’s seal to a variety of PDF reports by state, we quickly realized that an off-the shelf solution wasn’t going to cut it. After researching and testing a number of PDF manipulation libraries and a few cost-prohibitive software-as-service solutions, we built a custom Drupal site that allows staff to maintain content for two different domains from a single administrative interface. We also built a custom module that delivers close to 1,000 sealed documents to DrJ customers each month as well as a progressively decoupled single-page application that helps users quickly find the Technical Evaluation Reports they need.

Challenges & Requirements

The DrJ Engineering and DrJ Certification sites highlight professional engineering, product certification, and code compliance services.
  1. To help separate the two sides of their business, the client runs multiple domains (drjengineering.org and drjcertification.org), but content types, permissions and basic CMS functionality were similar for each.
  2. Staff needed to be able to use the same login credentials on each domain and have the ability to manage content for each domain using a unified interface.
  3. TER reports would be uploaded by staff in PDF format and needed to have an engineer’s professional seal applied on request. The seal is a distinguishing mark of the engineering profession and is used as an indication to users of the documents that the contents of the document were prepared by or under the personal supervision of the engineer who sealed it. An important goal of the project was to keep staff from needing to manage multiple copies of the PDF reports for each state as well as to avoid having to store multiple copies of essentially the same document on the server.
  4. When they first started, DrJ’s engineers were not licensed in all states and Canadian provinces. This meant that we had to create a customizable map that visually represents which states could be sealed automatically. Behind the scenes, the site had to be able to calculate which Engineer’s seal to apply to a given report based on where that engineer is licensed as well as whether the report could be sealed in that location.
  5. Due to variations in building codes, some reports were developed for use only in specific states or Canadian provinces.
  6. Staff and licensing changes often and is sometimes specific to the report being served. In some cases, DrJ partners with outside engineers to provide sealed versions of specific reports.
  7. Reports are revised frequently and the client needed to be able to track and revert to previous revisions of reports for both page content and for uploaded reports. The report URLs could not change over time and past revisions needed to be secured to ensure that outdated reports could not be downloaded after they had been updated.
  8. A request form was added for instances when seals are needed for states where DrJ engineers are not licensed.
  9. A feature allowing users to quickly find reports was also important. The search needed to provide filters based on various attributes of the reports as well as a keyword search for the PDF content the reports themselves.

Solutions

A Robust Content Management System

Given that multiple staff members would be making regular changes to reports and content within the site, Drupal was a clear choice for this project. While we knew that some customization would be required, Drupal’s strengths as a content management system and its module ecosystem provided an excellent starting point.

Key Modules

  • Search API, Solr Search and Search API Attachments provide a generic API for searching content including the text of uploaded report files in PDF.
  • jVectorMap provides a wrapper for the jVectorMap library, which helped us create customized interactive US State and Canadian Province maps that help users access sealed reports.
  • Global Redirect helps manage redirects and aliases.
  • Taxonomy provides a structure for categorizing reports and is also used to manage the list of engineers who can seal reports and the list of states where DrJ can provide seals.
  • Domain Access (Domain Path, Domain Source) makes it possible to manage content for multiple domains from the same installation.
  • Path and Pathauto provides options to automatically generate and manage aliases for content.
  • Revisioning and Diff allows content editors to view, compare, and restore past revisions of content.
  • Upload Replace allows the most recent version of uploaded files retain the original file name.
  • Webform handles quote requests, sealed document requests, and contact forms.

A Custom Module and API

  • The Engineer’s seal, along with the current date and state-specific notes, are dynamically added to uploaded PDF reports. A series of validations run each time a new seal is requested to ensure that the report can be sealed.
  • Staff receives reports summarizing the number of sealed reports that have been downloaded in a given period and the states in which they were sealed.
  • An internal API enables various authorized internal and external applications to obtain sealed documents.

A Custom Search Interface

Screenshot of the DrJ TER Directory

To create the TER Directory search, we leveraged Apache Solr, a popular open source search platform, and React, a JavaScript library for building interactive user interfaces, to create an application-like search experience within the existing Drupal site. The approach we used is known as partial decoupling, a process that allowed us to leverage the existing Drupal site and Solr backend to replace Drupal’s default search view with a highly interactive end-user search experience.

The TER Directory is a custom module that includes a keyword search as well as a series of faceted search fields that can be used to refine results. On load, the application queries a series of API endpoints on the Drupal site to get a list of available filters. This includes metadata like the report number, product name, company name, and the Division from Construction Specifications Institute’s MasterFormat to which the report relates. The custom facets make it possible to quickly return all results in a given category. For example, if a user knows the report number they are looking for, they can type it into the corresponding field. Faceted search fields are implemented as searchable select lists, which means that options are narrowed as the user types.

Additional search features include:

  • Keyword searches comb both the report record stored in the Drupal database as well as the contents of the PDF-based report itself.
  • A real-time results widget at the top of the page helps users understand how changes to their search affect results.
  • A toggle filter hides legacy (no longer maintained) documents from search results by default.
  • The Company and Product filters allow users to quickly view all reports related to a specific product or company.

The custom TER Directory search application allowed us to combine Drupal’s strengths as a content management system with a blazing-fast, application-like user experience from React that helps DrJ customers find what they’re looking for quickly and efficiently. The improved search experience we provided is one we think many of our sites would benefit from and we look forward to building and refining it further in the future.