update primaryid and find by name

This commit is contained in:
j 2016-01-05 10:59:09 +05:30
parent 1e089e1523
commit c52f37d63b
2 changed files with 5 additions and 2 deletions

View file

@ -87,7 +87,7 @@ oml.ui.identifyDialog = function(data) {
label: Ox._('Title, Author etc.'), label: Ox._('Title, Author etc.'),
labelWidth: 128, labelWidth: 128,
width: 608, width: 608,
value: [data.title].concat(data.author || []).join(' ') value: Ox.decodeHTMLEntities([data.title].concat(data.author || []).join(' '))
}) })
.bindEvent({ .bindEvent({
submit: findMetadata submit: findMetadata

View file

@ -170,7 +170,7 @@ oml.ui.infoView = function(identifyData) {
id: ui.item, id: ui.item,
primaryid: data.value ? data.value.split(':') : '' primaryid: data.value ? data.value.split(':') : ''
}, function(result) { }, function(result) {
that.updateElement(result.data, [$data]); that.updateElement(result.data, [$info, $data]);
}); });
} }
}) })
@ -724,6 +724,9 @@ oml.ui.infoView = function(identifyData) {
oml.$ui.browser.value( oml.$ui.browser.value(
result.data.id, key, result.data[key] result.data.id, key, result.data[key]
); );
if (Ox.contains(['title', 'author'], key)) {
that.updateElement(result.data, [$data]);
}
}); });
} }
} }