compute nameKeys, listKeys from config
This commit is contained in:
parent
f0e3c2775e
commit
b14f729768
3 changed files with 33 additions and 14 deletions
|
|
@ -21,16 +21,19 @@ pandora.ui.infoView = function(data) {
|
|||
isCopyrighted = !data.year || parseInt(data.year) + 60 >= new Date().getFullYear(),
|
||||
listWidth = 0,
|
||||
margin = 16,
|
||||
nameKeys = [
|
||||
'director', 'producer', 'codirector', 'writer', 'cinematographer',
|
||||
'editor', 'composer', 'lyricist', 'actor'
|
||||
],
|
||||
listKeys = nameKeys.concat([
|
||||
'country', 'language', 'color', 'sound', 'genre', 'keyword', 'links'
|
||||
]),
|
||||
posterKeys = ['title', 'director', 'year'],
|
||||
// these may contain commas, and are thus separated by semicolons
|
||||
specialListKeys = ['alternativeTitles', 'productionCompany'],
|
||||
nameKeys = pandora.site.itemKeys.filter(function(key) {
|
||||
return key.sortType == 'person';
|
||||
}).map(function(key) {
|
||||
return key.id;
|
||||
}),
|
||||
listKeys = pandora.site.itemKeys.filter(function(key) {
|
||||
return Ox.isArray(key.type) && !Ox.contains(specialListKeys, key.id);
|
||||
}).map(function(key){
|
||||
return key.id;
|
||||
}),
|
||||
posterKeys = ['title', 'director', 'year'],
|
||||
descriptions = {
|
||||
names: getNames(),
|
||||
studios: getStudios()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue