Skip to content
Browse files

Move IMPOSSIBLE data to mongo

  • Loading branch information...
1 parent d753670 commit 30eb9b19d96989e792603621f1b92e9bebfb5ddb @jasonkuhrt committed
View
97 data/works/impossible.co
@@ -1,97 +0,0 @@
-h = require './helpers'
-utils = require '../../utils'
-
-sections = []
-sections.push new h.section do
- column1:
- h.panel_templates.poster("impossible")
- h.panel do
- name: "Contact"
- type: "multi-list"
- content:
- 'Distribution and sales':
- '
- <address>
- <div class=address-name>Travelling Distribution</div>
- <a href=mailto:info@travellingdistribution.com class=address-email>info@travellingdistribution.com</a>
- <div class=address-phone-number>+1 (514) 467-8160</div>
- </address>
- '
- ...
- h.panel_templates.screenings do
- "festivals (2011)":
- "Red Rock Film Festival Part 2"
- "Rhode Island International Film Festival"
- "Le Percéides: Festival International de Cinéma et de l’Art de Percé"
- "Festival du Film Québécois de Kelowna"
- "Fantasia International Film Festival"
- "Edmonton International Film Festival"
- "Regard sur le Court Métrage au Saguenay"
- "Prix Prends Ça Court !"
- "Wiz-Art Festival"
- "Red Rock Film Festival"
- "festivals (2010)":
- "Les Rendez-vous du Cinéma Québécois"
- "River Run International Film Festival"
- "Cinéma du Québec à Paris"
- TV:
- "2011 TFO"
- "2011 CBC"
- Other:
- "2010 Court-Circuit (Outremont Theatre)"
- ...
-
-
- column2:
- h.panel_templates.cover do
- title: "IMPOSSIBLE"
- synopsis: "
- A passionate young painter, lives a regimented life working long hours on little money. Women are seemingly of little interest to him, until he notices a young woman living across the street. His life is soon turned upside down as his days become but quests to catch a glimpse of her.
- "
- h.panel do
- name: 'Details'
- type: 'term-list'
- content:
- 'Genre': 'drama'
- 'Release date': '2010'
- 'Language': 'English'
- 'Production company': 'Central Unit Productions'
- 'Runtime': '0:17:35'
- 'Shooting format': '16mm'
- 'Funding agencies': "SODEC, NFB, CBC"
- h.panel do
- name: "Principal cast"
- type: \term-list
- content:
- "Ian French": "Tyler Hynes"
- "Thin Girl": "Charlotte LeBon"
- Narrator: "Michelle Giroux"
-
-
- column3:
- h.panel do
- name: "Director's Statement"
- content: "
- When I read Katherine Mansfield’s Feuille d’Album I immediately knew I wanted to adapt it. Writing at the turn of the 20th century in Paris, the story had mixes of social realism and symbolism, and of English and French culture – both these aspects drew me to it. I wanted the film to reflect this eclecticism and to avoid expectations. I dove into the idea of “impossibilities” and looked to refer to both cultures on a social and cinematic level.
- "
- h.panel_templates.soundtrack("impossible")
- h.panel do
- name: "Principal crew"
- type: \term-list
- content:
- Director : "Vanya Rose"
- Screenwriter : "Vanya Rose"
- Producers : "Galilé Marion-Gauvin, Jocelyne Perrier"
- "Director of photography" : "Glauco Bermudez"
- Editor : "Dev Singh"
- "Art director" : "Zoë Dominiak"
- "Costume designer" : "Zoë Dominiak"
- Music : "Adam & the Amethysts"
- "Sound designer" : "Olivier Calvert"
- Colourist : "Valeria Petit"
-
- column4:
- h.panel_templates.videos("impossible",151)
- h.panel_templates.stills("impossible")
-
-module.exports = h.work 'Impossible', sections
View
1 data/works/works.co
@@ -1,6 +1,5 @@
module.exports =
require './woman_in_car'
- require './impossible'
require './montreal_stories_1944'
require './montreal_stories_1971'
require './montreal_stories_1912'
View
11 lib/coffee/audio_player.coffee
@@ -24,16 +24,13 @@ $(window).on "load", ->
$soundtrack_pod.addClass "stopped"
tracks = {}
tracks_arr = []
+ formats = $tracks.first().data("formats")
+ root = $tracks.first().data("src")
for track_el in $tracks
$track = $ track_el
- console.log "Track formats", $track.data("formats")
- formats = $track.data("formats")
- src = $track.data("src")
+ #console.log "Track formats", $track.data("formats")
name = $track.data("name")
- root = $track.data("src-root")
- console.log $track.data("files")
- files = _.map $track.data("files"), (file_name)-> root + file_name
- #console.log src, formats
+ files = _.map formats, (format)-> root + name + format
o =
name: name
$item: $(track_el)
View
26 locales/en/credits.json
@@ -1,15 +1,17 @@
{
- "roles": {
- "director" : "Director"
- ,"writer" : "Writer"
- ,"producer" : "Producer"
- ,"associate_producer": "Associate producer"
- ,"editor" : "Editor"
- ,"dop" : "Director of photography"
- ,"art_director": "Art director"
- ,"colourist": "Colourist"
- ,"costume_designer": "Costume designer"
- ,"sound_designer": "Sound designer"
- ,"titles_and_poster": "Titles and poster"
+ "roles" : {
+ "art_director" : "Art director"
+ ,"associate_producer" : "Associate producer"
+ ,"colourist" : "Colourist"
+ ,"costume_designer" : "Costume designer"
+ ,"director" : "Director"
+ ,"dop" : "Director of photography"
+ ,"editor" : "Editor"
+ ,"music" : "Music"
+ ,"producer" : "Producer"
+ ,"titles_and_poster" : "Titles and poster"
+ ,"screenwriter" : "Screenwriter"
+ ,"sound_designer" : "Sound designer"
+ ,"writer" : "Writer"
}
}
View
13 public/js/audio_player.js
@@ -18,22 +18,19 @@
if ($soundtrack_pod.length) {
soundManager.preferFlash = false;
return soundManager.onready(function() {
- var $track, current_track, files, formats, name, o, root, src, track_el, tracks, tracks_arr, _i, _len;
+ var $track, current_track, files, formats, name, o, root, track_el, tracks, tracks_arr, _i, _len;
current_track = null;
$soundtrack_pod.addClass("stopped");
tracks = {};
tracks_arr = [];
+ formats = $tracks.first().data("formats");
+ root = $tracks.first().data("src");
for (_i = 0, _len = $tracks.length; _i < _len; _i++) {
track_el = $tracks[_i];
$track = $(track_el);
- console.log("Track formats", $track.data("formats"));
- formats = $track.data("formats");
- src = $track.data("src");
name = $track.data("name");
- root = $track.data("src-root");
- console.log($track.data("files"));
- files = _.map($track.data("files"), function(file_name) {
- return root + file_name;
+ files = _.map(formats, function(format) {
+ return root + name + format;
});
o = {
name: name,
View
9 routes.coffee
@@ -42,15 +42,16 @@ module.exports = (app)->
getWork = (req,res,next)->
app.db.collection('films').findOne {slug: req.params.work}, (err,work)->
- app.db.dereference work.production_companies[0], (err,r)->
- work.production_companies = r
+ app.db.collection('address_book').find({name: {$in: work.details.production_companies}}).toArray (err,r)->
+ work.details.production_companies = r
res._locals.urls ?= {}
work.urls =
main: "#{res._locals.urls.content}/works/#{req.params.work}"
work.urls.stills = "#{work.urls.main}/stills/280"
work.urls.videos = "#{work.urls.main}/videos"
+ work.urls.soundtrack = "#{work.urls.main}/soundtrack"
- app.db.collection('address_book').find({_id: {"$in": work.contact[0].contacts }}).toArray (err, addresses)->
+ app.db.collection('address_book').find({name: {$in: work.contact[0].contacts }}).toArray (err, addresses)->
work.contact[0].contacts = addresses
res.local 'work', work
next()
@@ -119,4 +120,4 @@ module.exports = (app)->
res.local 'secondary_nav', [res._locals.work] #res._locals.work is assigned by the getWork middleware
res._locals.page_title = " || #{res._locals.work.title}"
- res.render 'work'
+ res.render "work/#{res._locals.work.slug.replace(/-/g,"_")}"
View
82 views/work/at_the_bottom_of_the_hill.jade
@@ -0,0 +1,82 @@
+include ../mixins/lists
+
+.major-section: div.panels
+
+ .column.column-1
+ .panel.poster: img( src="#{work.urls.main}/poster_280.jpg" )
+
+ .panel.screenings.multi-list
+ header: h1.title Screenings
+ .content
+ each screenings_by_type in work.screenings
+ h2= screenings_by_type.type
+ mixin basic_list(screenings_by_type.showings, ["year","name"], ["festival-year","festival-name"])
+
+ .panel.contact.multi-list
+ header: h1.title Contact
+ .content
+ each contact_group in work.contact
+ h2= t(contact_group.type)
+ each contact in contact_group.contacts
+ address
+ div: a(href=contact.website)= contact.name
+ div: a(href=contact.email)= contact.email
+ div: span.phone= contact.phone
+
+
+ .column.column-2
+
+ .panel.synopsis: div.content
+ h1= work.title
+ p!= work.synopsis
+
+ .panel.details.term-list
+ header: h1.title Details
+ .content
+ dl
+ each field in details_fields
+ .ds
+ dt= t(field)
+ if Array.isArray(work.details[field])
+ if typeof work.details[field][0] == "object"
+ each company in work.details[field]
+ dd: a(href=company.website)= company.name
+ else
+ dd= work.details[field].join(", ")
+ else
+ dd= work.details[field]
+
+ .panel.details.term-list
+ header: h1.title Principal Cast
+ .content
+ mixin definition_list(work.principal_cast, {term:"role",desc:"person"})
+
+
+ .column.column-3
+
+ .panel.directors-statement
+ header: h1.title Director's statement
+ .content!= work.directors_statement
+
+ .panel.details.term-list
+ header: h1.title Principal Crew
+ .content
+ mixin definition_list(work.principal_crew, {term:"role",desc:"person"}, true)
+
+
+ .column.column-4
+
+ .panel.videos.raw
+ header: h1.title Moving image
+ .content
+ each video in work.videos
+ video.sublime.movie-player(width="280", height=video.height, preload="none")
+ source(src="#{work.urls.videos}/#{video.name}.mp4")
+ source(src="#{work.urls.videos}/#{video.name}.webm")
+
+ .panel.stills.raw
+ header: h1.title Stills
+ .content
+ each still_id in work.stills
+ img( src="#{work.urls.stills}/#{still_id}.jpg" )
+
View
96 views/work/impossible.jade
@@ -0,0 +1,96 @@
+include ../mixins/lists
+
+.major-section: div.panels
+
+ .column.column-1
+ .panel.poster: img( src="#{work.urls.main}/poster_280.jpg" )
+
+ .panel.screenings.multi-list
+ header: h1.title Screenings
+ .content
+ each screenings_by_type in work.screenings
+ h2= screenings_by_type.type
+ mixin basic_list(screenings_by_type.showings, ["year","name"], ["festival-year","festival-name"])
+
+ .panel.contact.multi-list
+ header: h1.title Contact
+ .content
+ each contact_group in work.contact
+ h2= t(contact_group.type)
+ each contact in contact_group.contacts
+ address
+ div: a(href=contact.website)= contact.name
+ div: a(href=contact.email)= contact.email
+ div: span.phone= contact.phone
+
+
+ .column.column-2
+
+ .panel.synopsis: div.content
+ h1= work.title
+ p!= work.synopsis
+
+ .panel.details.term-list
+ header: h1.title Details
+ .content
+ dl
+ each field in details_fields
+ .ds
+ dt= t(field)
+ if Array.isArray(work.details[field])
+ if typeof work.details[field][0] == "object"
+ each company in work.details[field]
+ dd: a(href=company.website)= company.name
+ else
+ dd= work.details[field].join(", ")
+ else
+ dd= work.details[field]
+
+ .panel.details.term-list
+ header: h1.title Principal Cast
+ .content
+ mixin definition_list(work.principal_cast, {term:"role",desc:"person"})
+
+
+ .column.column-3
+
+ .panel.directors-statement
+ header: h1.title Director's statement
+ .content!= work.directors_statement
+
+
+ .panel.soundtrack.audio-player
+ header
+ h1.title Soundtrack
+ span.audio-player-control.play
+ span.audio-player-control.pause
+ progress(max=100)
+ .content
+ ul.audio-player-tracks
+ each track in work.soundtrack.tracks
+ li.audio-player-track.audio-track(data-formats=JSON.stringify(work.soundtrack.file_types),
+ data-name = track.name,
+ data-src = "#{work.urls.soundtrack}/")= track.name
+
+ .panel.details.term-list
+ header: h1.title Principal Crew
+ .content
+ mixin definition_list(work.principal_crew, {term:"role",desc:"person"}, true)
+
+
+ .column.column-4
+
+ .panel.videos.raw
+ header: h1.title Moving image
+ .content
+ each video in work.videos
+ video.sublime.movie-player(width="280", height=video.height, preload="none")
+ source(src="#{work.urls.videos}/#{video.name}.mp4")
+ source(src="#{work.urls.videos}/#{video.name}.webm")
+
+ .panel.stills.raw
+ header: h1.title Stills
+ .content
+ each still_id in work.stills
+ img( src="#{work.urls.stills}/#{still_id}.jpg" )
+

0 comments on commit 30eb9b1

Please sign in to comment.
Something went wrong with that request. Please try again.