Library day in the life - 5 - Day 1

So here we are again. Library Day in the Life number five! Monday is a work from home day. No audacious commute from Toronto to Hamilton today!


Morning soundtrack: BBC World Service podcast, TWiT - It’s The New Sex Talk, CBC Spark Daniel Pink on Motivation 3.0, The Protomen - The Protomen

Catch up a bunch of email from last week, and finally got around to setting up Drush. Don’t know why I never got around to it before, but it definitely worth the time of checking out if you manage a few Drupal sites. Watched a couple of screencasts on Drush by CivicActions to quickly immerse myself, then got around to updating modules for our dev site. Once everything was up to snuff, I started working on the a cuple of our final functional requirements for the new version of our digital collections site before we start theming it; allowing each record to have its own Dublin Core XML output and adding some Dublin Core meta information to each record’s header html output. Mind you, I am a horrible programmer.

The header output code was pulled mostly from this Computed Field php snippet example. I managed to get DC.title, and DC.Date.X-MetadataLastModified working correctly, but the rest of the elements (descriptions, source, format, etc) were another beast entirely. I put off the Dublin Core XML until later in the day when I could rely one of our programmers for assistance, because mind you, I am a horrible programmer.


Afternoon soundtrack: Squarepusher - Hello Everything, Squarepusher - Just a Souvenir, Daft Punk - Discovery, Film Junk - Inception (spoilers portion of the podcast), BBC World Service podcast

Thought out the spec a lot more for the Dublin Core XML. Decided not to use CCK Computed Fields to make it happened. Don’t know why I was thinking it would work, but one of those square peg in a round hold things. Contrary self - I could just make the peg round. Brainstormed a lot more with Matt (one our dynamic duo of programmers) on the Dublin Core XML idea. We agreed we just create a quick module to handle creating the XML. This will be our first custom work with the new version of the site. Due to many problems with the last iteration, while current production version, I wanted to move as far away from custom code as possible and we have been doing very well. But, this makes sense… maybe. There is always a million ways to solve something like this. Maybe tomorrow it will just be a View with a php snippet.

In the background of all wretched coding on my part, I was again working with my favourite module - Views Bulk Operations (VBO)!!! With the first iteration of the site, we made a couple of decisions that I have come to regret. They are not earth shattering or anything, just didn’t setup some of the metadata fields how I would have liked them to be setup. For quite sometime I’ve been trying to thing about an easy way to merge some of them together. Epic mysql query dreams! JOIN, JOIN, INSERT, UPDATE, WHERE, BLERG! Anyway, some wonderful soul wrote a merge fields action for VBO! So, in the background all of today’s work, I updated 14559 rows, a couple of times. It only took an average of 12153468ms each time!

Oh yeah, email was answered. Spheroidally.

Nick Ruest
Associate Librarian


comments powered by Disqus