document preview
This commit is contained in:
parent
708a5b1b33
commit
9730b046ce
1 changed files with 21 additions and 14 deletions
|
@ -137,8 +137,10 @@ pandora.ui.collection = function() {
|
||||||
|
|
||||||
that.bindEvent({
|
that.bindEvent({
|
||||||
closepreview: function(data) {
|
closepreview: function(data) {
|
||||||
pandora.$ui.previewDialog.close();
|
if (pandora.$ui.documentDialog) {
|
||||||
delete pandora.$ui.previewDialog;
|
pandora.$ui.documentDialog.close();
|
||||||
|
delete pandora.$ui.documentDialog;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
copy: function(data) {
|
copy: function(data) {
|
||||||
pandora.clipboard.copy(data.ids, 'document');
|
pandora.clipboard.copy(data.ids, 'document');
|
||||||
|
@ -227,20 +229,25 @@ pandora.ui.collection = function() {
|
||||||
pandora.UI.set(set);
|
pandora.UI.set(set);
|
||||||
},
|
},
|
||||||
openpreview: function(data) {
|
openpreview: function(data) {
|
||||||
/*
|
if (!pandora.$ui.documentDialog) {
|
||||||
if (!pandora.$ui.previewDialog) {
|
pandora.$ui.documentDialog = pandora.openDocumentDialog({
|
||||||
pandora.$ui.previewDialog = pandora.ui.previewDialog()
|
documents: that.options('selected').map(function(id) {
|
||||||
.open()
|
return that.value(id);
|
||||||
.bindEvent({
|
})
|
||||||
|
}).bindEvent({
|
||||||
close: function() {
|
close: function() {
|
||||||
that.closePreview();
|
that.closePreview();
|
||||||
delete pandora.$ui.previewDialog;
|
delete pandora.$ui.documentDialog;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
pandora.$ui.previewDialog.update();
|
pandora.$ui.documentDialog.update({
|
||||||
|
index: 0,
|
||||||
|
items: that.options('selected').map(function(id) {
|
||||||
|
return that.value(id);
|
||||||
|
})
|
||||||
|
});
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
},
|
},
|
||||||
paste: function(data) {
|
paste: function(data) {
|
||||||
var items = pandora.clipboard.paste();
|
var items = pandora.clipboard.paste();
|
||||||
|
|
Loading…
Reference in a new issue