1
0
mirror of http://git.whoc.org.uk/git/password-manager.git synced 2025-10-25 01:37:34 +02:00

Integration of PHP backend with /beta and /gamma front ends

Fixed PHP backend and /beta code to handle request and data format compatible with /gamma.
At the moment adding/deleting/editing records seem to work fine.
This commit is contained in:
Giulio Cesare Solaroli
2011-10-23 18:36:57 +01:00
parent b312e037eb
commit 67455b069c
8 changed files with 205 additions and 288 deletions

View File

@@ -279,18 +279,23 @@ Clipperz.PM.DataModel.Record.prototype = MochiKit.Base.update(null, {
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['currentVersion'];
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));