From 2622ab057e7e7c8c746002538c29f63b4938d0af Mon Sep 17 00:00:00 2001 From: rolux Date: Thu, 20 Nov 2014 17:13:49 +0000 Subject: [PATCH] yet another javascript gotcha --- static/js/entitiesDialog.js | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/static/js/entitiesDialog.js b/static/js/entitiesDialog.js index 1c34ea17..8980b61e 100644 --- a/static/js/entitiesDialog.js +++ b/static/js/entitiesDialog.js @@ -345,17 +345,17 @@ pandora.ui.entitiesDialog = function(options) { .css({margin: '2px 2px 4px 2px'}) .appendTo($form), $input; - if (key.type == 'document') { + if (key.type === 'document') { $input = Ox.Input({autovalidate: /^[A-Z]+?$/}); - } else if (key.type == 'float') { + } else if (key.type === 'float') { $input = Ox.Input({type: 'float'}); - } else if (key.type == 'int') { + } else if (key.type === 'int') { $input = Ox.Input({type: 'int'}); - } else if (key.type == 'string') { + } else if (key.type === 'string') { $input = Ox.Input(); - } else if (key.type[0] == 'string') { + } else if (key.type[0] === 'string') { $input = Ox.ArrayInput(); - } else if (key.type == 'text') { + } else if (key.type === 'text') { $input = Ox.Input({ height: 248 - Ox.SCROLLBAR_SIZE, type: 'textarea' @@ -383,6 +383,10 @@ pandora.ui.entitiesDialog = function(options) { }); } + function selectEntities() { + // ... + } + function updateForm() { var width = $content.options('elements')[2].size - 8; $labels.forEach(function($label) {