Skip to content

Instantly share code, notes, and snippets.

@karlkaebnick
Last active December 8, 2017 22:11
Show Gist options
  • Save karlkaebnick/8c5c59c17f1b9228db805b8127a93e7e to your computer and use it in GitHub Desktop.
Save karlkaebnick/8c5c59c17f1b9228db805b8127a93e7e to your computer and use it in GitHub Desktop.
Architecture for city of Detroit's drupal website

Overview:

Our aim is to build a highly-structured database. Doing so will involve a lot more work initially (in comparison with a purely aesthetic redesign) but will make changing the website easier and more fool-proof. This is also in keeping with Drupal website best practices.

Taxonomies:

  • Departments
    • e.g., 'health', 'ddot', 'ocfo', 'dpw'
    • May not always technically be departments - e.g., they may be agencies or authorities.
    • Includes offices / agencies within departments (e.g., 'web team', 'iet', 'office of civil rights')
    • Departments and sub-departments need to be associated with certain pieces of information, e.g.:
      • department contacts
        • Name
        • Position
        • Phone
      • social media specific to the given department
        • can be associated with a topic (e.g., 'police department employment opportunities', 'police department crime & saftety')
      • media & files associated with the given department
  • Initiatives
    • e.g., SisterFriends, Adopt-a-Park, Motor City Makeover, Keep Detroit Beautiful, Detroit Youth Violence Prevention Initiative
    • May be related to more than one department
    • May be relatively (compared with departments) short-lived
  • Content category (?)
    • not sure of correct name for this taxonomy - perhaps 'vertical' or 'audience'? 'target audience'?
    • e.g., 'government', 'residential', 'business'
  • Data Type
    • e.g., 'permit', 'license', 'entertainment', 'property tax', 'how do i', 'socrata', 'esri'
    • question: should 'data source' be a separate taxonomy (especially for things like 'socrata', 'esri')?
  • Interactions
    • e.g., 'payment', 'service', 'appeal'
  • Tags
    • Tags are useful as the site grows, used as a filter for search results
  • Media / Content type
    • these will be handled by the drupal media module

Outstanding questions

  • how do we handle events?
  • would be nice to be able to link to socrata data better
    • avoid stale data / be able to identify stale data easily
    • avoid broken links
    • ideas:
      • instead of linking from detroitmi.gov directly to individual socrata datasets (which are sometimes liable to disappear or go stale), our links could essentially be keyword queries, which would bring back results from socrata related to the links (if this is doable on the socrata end of things)
      • socrata links should live in content types which are labelled consistently by their data source or type of content, so that we can easily identify everywhere where socrata data is used in the site and quickly identify broken / stale links

Files

  • e.g., pdfs, etc.
  • map to new source location: move everything from /portals/0 to a directory on the drupal web server
  • add an htaccess rule to the drupal web server's apache server to point the name 'portals/' to the new directory

Migration-specific stuff

  • how to export redirects
    • have post_row_save create redirect (old url to new url) once the row item has been saved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment