summaryrefslogtreecommitdiff
path: root/frontend
Side-by-side diff
Diffstat (limited to 'frontend') (more/less context) (ignore whitespace changes)
-rw-r--r--frontend/beta/css/yui-extensions/basic-dialog.css2
-rw-r--r--frontend/beta/js/Clipperz/PM/DataModel/Record.js10
2 files changed, 8 insertions, 4 deletions
diff --git a/frontend/beta/css/yui-extensions/basic-dialog.css b/frontend/beta/css/yui-extensions/basic-dialog.css
index bad0679..5a9f311 100644
--- a/frontend/beta/css/yui-extensions/basic-dialog.css
+++ b/frontend/beta/css/yui-extensions/basic-dialog.css
@@ -1,144 +1,142 @@
/*
Copyright 2008-2011 Clipperz Srl
This file is part of Clipperz Community Edition.
Clipperz Community Edition is an online password manager.
For further information about its features and functionalities please
refer to http://www.clipperz.com.
* Clipperz Community Edition is free software: you can redistribute
it and/or modify it under the terms of the GNU Affero General Public
License as published by the Free Software Foundation, either version
3 of the License, or (at your option) any later version.
* Clipperz Community Edition is distributed in the hope that it will
be useful, but WITHOUT ANY WARRANTY; without even the implied
warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
See the GNU Affero General Public License for more details.
* You should have received a copy of the GNU Affero General Public
License along with Clipperz Community Edition. If not, see
<http://www.gnu.org/licenses/>.
*/
.ydlg-proxy {
- background-image: url(../images/default/gradient-bg.gif);
background-color:#c3daf9;
border:1px solid #6593cf;
z-index:10001;
overflow:hidden;
position:absolute;
left:0;top:0;
}
.ydlg-shadow{
background:#aaaaaa;
position:absolute;
left:0;top:0;
}
.ydlg-focus{
-moz-outline:0 none;
outline:0 none;
width:0;
height:0;
overflow:hidden;
position:absolute;
top:0;
left:0;
}
.ydlg-mask{
z-index:10000;
display:none;
position:absolute;
top:0;
left:0;
-moz-opacity: 0.5;
opacity:.50;
filter: alpha(opacity=50);
background-color:#CCC;
}
body.masked{
}
body.masked select {
visibility:hidden;
}
body.masked .ydlg select {
visibility:visible;
}
.ydlg{
z-index:10001;
overflow:hidden;
position:absolute;
left:300;top:0;
}
.yresizable-proxy{
z-index:10002;
}
.ydlg .ydlg-hd {
background: url(../images/default/basic-dialog/hd-sprite.gif) repeat-x 0 -82px;
background-color:navy;
color:#ffffff;
font:bold 12px "sans serif", tahoma, verdana, helvetica;
overflow:hidden;
padding:5px;
}
.ydlg .ydlg-hd-left {
background: url(../images/default/basic-dialog/hd-sprite.gif) no-repeat 0 -41px;
padding-left:3px;
margin:0px;
}
.ydlg .ydlg-hd-right {
background: url(../images/default/basic-dialog/hd-sprite.gif) no-repeat right 0;
padding-right:3px;
}
.ydlg .ydlg-dlg-body{
- background:url(../images/default/layout/gradient-bg.gif);
border:1px solid #6593cf;
border-top:0 none;
padding:10px;
overflow:hidden;
}
.ydlg .ydlg-bd{
overflow:hidden;
}
.ydlg .ydlg-ft{
overflow:hidden;
padding:5px;
padding-bottom:0;
}
.ydlg .yui-ext-tabbody{
background:white;
overflow:auto;
}
.ydlg .ytabs-top .yui-ext-tabbody{
border:1px solid #6593cf;
border-top:0 none;
}
.ydlg .ytabs-bottom .yui-ext-tabbody{
border:1px solid #6593cf;
border-bottom:0 none;
}
.ydlg .ylayout-container .yui-ext-tabbody{
border:0 none;
}
.ydlg .inner-tab{
margin:5px;
}
.ydlg .ydlg-ft .ybtn{
margin-right:5px;
float:right;
clear:none;
}
.ydlg .ydlg-ft .ydlg-btns td {
border:0;
padding:0;
}
.ydlg .ydlg-ft .ydlg-btns-right table{
float:right;
clear:none;
}
.ydlg .ydlg-ft .ydlg-btns-left table{
float:left;
clear:none;
}
diff --git a/frontend/beta/js/Clipperz/PM/DataModel/Record.js b/frontend/beta/js/Clipperz/PM/DataModel/Record.js
index ffb45de..9e496de 100644
--- a/frontend/beta/js/Clipperz/PM/DataModel/Record.js
+++ b/frontend/beta/js/Clipperz/PM/DataModel/Record.js
@@ -247,98 +247,104 @@ Clipperz.PM.DataModel.Record.prototype = MochiKit.Base.update(null, {
//MochiKit.Logging.logDebug(">>> [" + (new Date()).valueOf() + "] Record.decryptData - this: " + this + " (" + anEncryptedData + ")");
if (this.shouldDecryptData()) {
var deferredResult;
deferredResult = new MochiKit.Async.Deferred();
deferredResult.addCallback(Clipperz.NotificationCenter.deferredNotification, this, 'notify', 'decryptingRecordData');
deferredResult.addCallback(Clipperz.PM.Crypto.deferredDecrypt, this.key(), anEncryptedData['data'], anEncryptedData['version']);
deferredResult.addCallback(function(anEncryptedData, someDecryptedValues) {
var result;
result = anEncryptedData;
result['data'] = someDecryptedValues;
return result;
}, anEncryptedData);
deferredResult.addCallback(MochiKit.Base.method(this, 'setDecryptedData'));
deferredResult.callback();
result = deferredResult;
} else {
result = MochiKit.Async.succeed(this.decryptedData());
}
//MochiKit.Logging.logDebug("<<< [" + (new Date()).valueOf() + "] Record.decryptData");
return result;
},
//-------------------------------------------------------------------------
'processData': function(someValues) {
//MochiKit.Logging.logDebug(">>> [" + (new Date()).valueOf() + "] Record.processData");
//MochiKit.Logging.logDebug("--- Record.processData: " + Clipperz.Base.serializeJSON(someValues));
if (this.shouldProcessData()) {
var currentVersionParameters;
console.log("Record.processData", someValues);
this.processDataToExtractLegacyValues(someValues['data']);
if (typeof(someValues['data']['notes']) != 'undefined') {
this.setNotes(someValues['data']['notes']);
}
if (someValues['data']['currentVersionKey'] != null) {
this.setCurrentVersionKey(someValues['data']['currentVersionKey']);
} else {
this.setCurrentVersionKey(this.key());
}
-// currentVersionParameters = someValues['currentVersion'];
- currentVersionParameters = someValues['versions'][someValues['currentVersion']];
+// community edition doesn't currently pass version
+// information
+ if (someValues['versions'] == null) {
+ currentVersionParameters = someValues['currentVersion'];
+ } else {
+ currentVersionParameters = someValues['versions'][someValues['currentVersion']];
+ }
+
console.log("Record.processData - this.currentVersionKey()", this.currentVersionKey());
console.log("Record.processData - currentVersionParameters", currentVersionParameters);
currentVersionParameters['key'] = this.currentVersionKey();
this.setCurrentVersion(new Clipperz.PM.DataModel.RecordVersion(this, currentVersionParameters));
if (someValues['data']['directLogins'] != null) {
var directLoginReference;
for (directLoginReference in someValues['data']['directLogins']) {
var directLogin;
var directLoginParameters;
directLoginParameters = someValues['data']['directLogins'][directLoginReference];
directLoginParameters.record = this;
directLoginParameters.reference = directLoginReference;
directLogin = new Clipperz.PM.DataModel.DirectLogin(directLoginParameters);
this.addDirectLogin(directLogin, true);
}
}
this.setShouldProcessData(false);
}
Clipperz.NotificationCenter.notify(this, 'recordDataReady');
//MochiKit.Logging.logDebug("<<< [" + (new Date()).valueOf() + "] Record.processData");
//MochiKit.Logging.logDebug("<<< Record.processData");
return this;
},
//-------------------------------------------------------------------------
'processDataToExtractLegacyValues': function(someValues) {
//MochiKit.Logging.logDebug(">>> Record.processDataToExtractLegacyValues");
if (someValues['data'] != null) {
this.setNotes(someValues['data']);
}
if (
(typeof(someValues['loginFormData']) != "undefined")
&& (typeof(someValues['loginBindings'] != "undefined"))
&& (someValues['loginFormData'] != "")
&& (someValues['loginBindings'] != "")
) {
var directLogin;
directLogin = new Clipperz.PM.DataModel.DirectLogin({
record:this,