mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-29 20:19:22 +03:00
commit
b22ee660d5
97 changed files with 1235 additions and 1015 deletions
|
|
@ -21,7 +21,7 @@
|
|||
LicenseStore = require('Stores/Admin/License'),
|
||||
PackageStore = require('Stores/Admin/Package'),
|
||||
CoreStore = require('Stores/Admin/Core'),
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractApp = require('App/Abstract')
|
||||
|
|
|
|||
218
dev/App/User.js
218
dev/App/User.js
|
|
@ -21,6 +21,8 @@
|
|||
|
||||
kn = require('Knoin/Knoin'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
SocialStore = require('Stores/Social'),
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
|
|
@ -29,16 +31,16 @@
|
|||
TemplateStore = require('Stores/User/Template'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
PgpStore = require('Stores/User/Pgp'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
ContactStore = require('Stores/User/Contact'),
|
||||
|
||||
Local = require('Storage/Client'),
|
||||
Settings = require('Storage/Settings'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
EmailModel = require('Model/Email'),
|
||||
FolderModel = require('Model/Folder'),
|
||||
MessageModel = require('Model/Message'),
|
||||
AccountModel = require('Model/Account'),
|
||||
IdentityModel = require('Model/Identity'),
|
||||
TemplateModel = require('Model/Template'),
|
||||
|
|
@ -146,11 +148,11 @@
|
|||
|
||||
AppUser.prototype.reloadFlagsCurrentMessageListAndMessageFromCache = function ()
|
||||
{
|
||||
_.each(Data.messageList(), function (oMessage) {
|
||||
_.each(MessageStore.messageList(), function (oMessage) {
|
||||
Cache.initMessageFlagsFromCache(oMessage);
|
||||
});
|
||||
|
||||
Cache.initMessageFlagsFromCache(Data.message());
|
||||
Cache.initMessageFlagsFromCache(MessageStore.message());
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -160,45 +162,45 @@
|
|||
AppUser.prototype.reloadMessageList = function (bDropPagePosition, bDropCurrenFolderCache)
|
||||
{
|
||||
var
|
||||
self = this,
|
||||
iOffset = (Data.messageListPage() - 1) * SettingsStore.messagesPerPage()
|
||||
iOffset = (MessageStore.messageListPage() - 1) * SettingsStore.messagesPerPage()
|
||||
;
|
||||
|
||||
if (Utils.isUnd(bDropCurrenFolderCache) ? false : !!bDropCurrenFolderCache)
|
||||
{
|
||||
Cache.setFolderHash(Data.currentFolderFullNameRaw(), '');
|
||||
Cache.setFolderHash(FolderStore.currentFolderFullNameRaw(), '');
|
||||
}
|
||||
|
||||
if (Utils.isUnd(bDropPagePosition) ? false : !!bDropPagePosition)
|
||||
{
|
||||
Data.messageListPage(1);
|
||||
MessageStore.messageListPage(1);
|
||||
iOffset = 0;
|
||||
}
|
||||
|
||||
Data.messageListLoading(true);
|
||||
MessageStore.messageListLoading(true);
|
||||
Remote.messageList(function (sResult, oData, bCached) {
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
Data.messageListError('');
|
||||
Data.messageListLoading(false);
|
||||
self.setMessageList(oData, bCached);
|
||||
MessageStore.messageListError('');
|
||||
MessageStore.messageListLoading(false);
|
||||
|
||||
MessageStore.setMessageList(oData, bCached);
|
||||
}
|
||||
else if (Enums.StorageResultType.Unload === sResult)
|
||||
{
|
||||
Data.messageListError('');
|
||||
Data.messageListLoading(false);
|
||||
MessageStore.messageListError('');
|
||||
MessageStore.messageListLoading(false);
|
||||
}
|
||||
else if (Enums.StorageResultType.Abort !== sResult)
|
||||
{
|
||||
Data.messageList([]);
|
||||
Data.messageListLoading(false);
|
||||
Data.messageListError(oData && oData.ErrorCode ?
|
||||
MessageStore.messageList([]);
|
||||
MessageStore.messageListLoading(false);
|
||||
MessageStore.messageListError(oData && oData.ErrorCode ?
|
||||
Translator.getNotification(oData.ErrorCode) : Translator.i18n('NOTIFICATIONS/CANT_GET_MESSAGE_LIST')
|
||||
);
|
||||
}
|
||||
|
||||
}, Data.currentFolderFullNameRaw(), iOffset, SettingsStore.messagesPerPage(), Data.messageListSearch());
|
||||
}, FolderStore.currentFolderFullNameRaw(), iOffset, SettingsStore.messagesPerPage(), MessageStore.messageListSearch());
|
||||
};
|
||||
|
||||
AppUser.prototype.recacheInboxMessageList = function ()
|
||||
|
|
@ -217,8 +219,8 @@
|
|||
*/
|
||||
AppUser.prototype.contactsSync = function (fResultFunc)
|
||||
{
|
||||
var oContacts = Data.contacts;
|
||||
if (oContacts.importing() || oContacts.syncing() || !Data.enableContactsSync() || !Data.allowContactsSync())
|
||||
var oContacts = ContactStore.contacts;
|
||||
if (oContacts.importing() || oContacts.syncing() || !ContactStore.enableContactsSync() || !ContactStore.allowContactsSync())
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
|
@ -296,7 +298,7 @@
|
|||
|
||||
AppUser.prototype.moveOrDeleteResponseHelper = function (sResult, oData)
|
||||
{
|
||||
if (Enums.StorageResultType.Success === sResult && Data.currentFolder())
|
||||
if (Enums.StorageResultType.Success === sResult && FolderStore.currentFolder())
|
||||
{
|
||||
if (oData && Utils.isArray(oData.Result) && 2 === oData.Result.length)
|
||||
{
|
||||
|
|
@ -304,7 +306,7 @@
|
|||
}
|
||||
else
|
||||
{
|
||||
Cache.setFolderHash(Data.currentFolderFullNameRaw(), '');
|
||||
Cache.setFolderHash(FolderStore.currentFolderFullNameRaw(), '');
|
||||
|
||||
if (oData && -1 < Utils.inArray(oData.ErrorCode,
|
||||
[Enums.Notification.CantMoveMessage, Enums.Notification.CantCopyMessage]))
|
||||
|
|
@ -313,7 +315,7 @@
|
|||
}
|
||||
}
|
||||
|
||||
this.reloadMessageListHelper(0 === Data.messageList().length);
|
||||
this.reloadMessageListHelper(0 === MessageStore.messageList().length);
|
||||
this.quotaDebounce();
|
||||
}
|
||||
};
|
||||
|
|
@ -325,7 +327,7 @@
|
|||
AppUser.prototype.deleteMessagesFromFolderWithoutCheck = function (sFromFolderFullNameRaw, aUidForRemove)
|
||||
{
|
||||
this.messagesDeleteHelper(sFromFolderFullNameRaw, aUidForRemove);
|
||||
Data.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove);
|
||||
MessageStore.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove);
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -382,14 +384,14 @@
|
|||
kn.showScreenPopup(require('View/Popup/Ask'), [Translator.i18n('POPUPS_ASK/DESC_WANT_DELETE_MESSAGES'), function () {
|
||||
|
||||
self.messagesDeleteHelper(sFromFolderFullNameRaw, aUidForRemove);
|
||||
Data.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove);
|
||||
MessageStore.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove);
|
||||
|
||||
}]);
|
||||
}
|
||||
else if (oMoveFolder)
|
||||
{
|
||||
this.messagesMoveHelper(sFromFolderFullNameRaw, oMoveFolder.fullNameRaw, aUidForRemove);
|
||||
Data.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove, oMoveFolder.fullNameRaw);
|
||||
MessageStore.removeMessagesFromList(sFromFolderFullNameRaw, aUidForRemove, oMoveFolder.fullNameRaw);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
@ -419,7 +421,7 @@
|
|||
this.messagesMoveHelper(oFromFolder.fullNameRaw, oToFolder.fullNameRaw, aUidForMove);
|
||||
}
|
||||
|
||||
Data.removeMessagesFromList(oFromFolder.fullNameRaw, aUidForMove, oToFolder.fullNameRaw, bCopy);
|
||||
MessageStore.removeMessagesFromList(oFromFolder.fullNameRaw, aUidForMove, oToFolder.fullNameRaw, bCopy);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
|
@ -432,12 +434,12 @@
|
|||
*/
|
||||
AppUser.prototype.folders = function (fCallback)
|
||||
{
|
||||
Data.foldersLoading(true);
|
||||
FolderStore.foldersLoading(true);
|
||||
|
||||
Remote.folders(_.bind(function (sResult, oData) {
|
||||
|
||||
var bResult = false;
|
||||
Data.foldersLoading(false);
|
||||
FolderStore.foldersLoading(false);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
|
|
@ -707,11 +709,11 @@
|
|||
}
|
||||
}
|
||||
|
||||
Data.initUidNextAndNewMessages(oFolder.fullNameRaw, oData.Result.UidNext, oData.Result.NewMessages);
|
||||
MessageStore.initUidNextAndNewMessages(oFolder.fullNameRaw, oData.Result.UidNext, oData.Result.NewMessages);
|
||||
|
||||
if (oData.Result.Hash !== sHash || '' === sHash)
|
||||
{
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
self.reloadMessageList();
|
||||
}
|
||||
|
|
@ -722,9 +724,9 @@
|
|||
}
|
||||
else if (bUnreadCountChange)
|
||||
{
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
aList = Data.messageList();
|
||||
aList = MessageStore.messageList();
|
||||
if (Utils.isNonEmptyArray(aList))
|
||||
{
|
||||
self.folderInformation(oFolder.fullNameRaw, aList);
|
||||
|
|
@ -748,7 +750,7 @@
|
|||
var
|
||||
self = this,
|
||||
iUtc = moment().unix(),
|
||||
aFolders = Data.getNextFolderNames(bBoot)
|
||||
aFolders = FolderStore.getNextFolderNames(bBoot)
|
||||
;
|
||||
|
||||
if (Utils.isNonEmptyArray(aFolders))
|
||||
|
|
@ -798,16 +800,16 @@
|
|||
|
||||
if (oItem.Hash !== sHash || '' === sHash)
|
||||
{
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
self.reloadMessageList();
|
||||
}
|
||||
}
|
||||
else if (bUnreadCountChange)
|
||||
{
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
aList = Data.messageList();
|
||||
aList = MessageStore.messageList();
|
||||
if (Utils.isNonEmptyArray(aList))
|
||||
{
|
||||
self.folderInformation(oFolder.fullNameRaw, aList);
|
||||
|
|
@ -941,136 +943,6 @@
|
|||
}, sQuery);
|
||||
};
|
||||
|
||||
AppUser.prototype.setMessageList = function (oData, bCached)
|
||||
{
|
||||
if (oData && oData.Result && 'Collection/MessageCollection' === oData.Result['@Object'] &&
|
||||
oData.Result['@Collection'] && Utils.isArray(oData.Result['@Collection']))
|
||||
{
|
||||
var
|
||||
mLastCollapsedThreadUids = null,
|
||||
iIndex = 0,
|
||||
iLen = 0,
|
||||
iCount = 0,
|
||||
iOffset = 0,
|
||||
aList = [],
|
||||
iUtc = moment().unix(),
|
||||
aStaticList = Data.staticMessageList,
|
||||
oJsonMessage = null,
|
||||
oMessage = null,
|
||||
oFolder = null,
|
||||
iNewCount = 0,
|
||||
bUnreadCountChange = false
|
||||
;
|
||||
|
||||
iCount = Utils.pInt(oData.Result.MessageResultCount);
|
||||
iOffset = Utils.pInt(oData.Result.Offset);
|
||||
|
||||
if (Utils.isNonEmptyArray(oData.Result.LastCollapsedThreadUids))
|
||||
{
|
||||
mLastCollapsedThreadUids = oData.Result.LastCollapsedThreadUids;
|
||||
}
|
||||
|
||||
oFolder = Cache.getFolderFromCacheList(
|
||||
Utils.isNormal(oData.Result.Folder) ? oData.Result.Folder : '');
|
||||
|
||||
if (oFolder && !bCached)
|
||||
{
|
||||
oFolder.interval = iUtc;
|
||||
|
||||
Cache.setFolderHash(oData.Result.Folder, oData.Result.FolderHash);
|
||||
|
||||
if (Utils.isNormal(oData.Result.MessageCount))
|
||||
{
|
||||
oFolder.messageCountAll(oData.Result.MessageCount);
|
||||
}
|
||||
|
||||
if (Utils.isNormal(oData.Result.MessageUnseenCount))
|
||||
{
|
||||
if (Utils.pInt(oFolder.messageCountUnread()) !== Utils.pInt(oData.Result.MessageUnseenCount))
|
||||
{
|
||||
bUnreadCountChange = true;
|
||||
}
|
||||
|
||||
oFolder.messageCountUnread(oData.Result.MessageUnseenCount);
|
||||
}
|
||||
|
||||
Data.initUidNextAndNewMessages(oFolder.fullNameRaw, oData.Result.UidNext, oData.Result.NewMessages);
|
||||
}
|
||||
|
||||
if (bUnreadCountChange && oFolder)
|
||||
{
|
||||
Cache.clearMessageFlagsFromCacheByFolder(oFolder.fullNameRaw);
|
||||
}
|
||||
|
||||
for (iIndex = 0, iLen = oData.Result['@Collection'].length; iIndex < iLen; iIndex++)
|
||||
{
|
||||
oJsonMessage = oData.Result['@Collection'][iIndex];
|
||||
if (oJsonMessage && 'Object/Message' === oJsonMessage['@Object'])
|
||||
{
|
||||
oMessage = aStaticList[iIndex];
|
||||
if (!oMessage || !oMessage.initByJson(oJsonMessage))
|
||||
{
|
||||
oMessage = MessageModel.newInstanceFromJson(oJsonMessage);
|
||||
}
|
||||
|
||||
if (oMessage)
|
||||
{
|
||||
if (Cache.hasNewMessageAndRemoveFromCache(oMessage.folderFullNameRaw, oMessage.uid) && 5 >= iNewCount)
|
||||
{
|
||||
iNewCount++;
|
||||
oMessage.newForAnimation(true);
|
||||
}
|
||||
|
||||
oMessage.deleted(false);
|
||||
|
||||
if (bCached)
|
||||
{
|
||||
Cache.initMessageFlagsFromCache(oMessage);
|
||||
}
|
||||
else
|
||||
{
|
||||
Cache.storeMessageFlagsToCache(oMessage);
|
||||
}
|
||||
|
||||
oMessage.lastInCollapsedThread(mLastCollapsedThreadUids && -1 < Utils.inArray(Utils.pInt(oMessage.uid), mLastCollapsedThreadUids) ? true : false);
|
||||
|
||||
aList.push(oMessage);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Data.messageListCount(iCount);
|
||||
Data.messageListSearch(Utils.isNormal(oData.Result.Search) ? oData.Result.Search : '');
|
||||
Data.messageListPage(window.Math.ceil((iOffset / SettingsStore.messagesPerPage()) + 1));
|
||||
Data.messageListEndFolder(Utils.isNormal(oData.Result.Folder) ? oData.Result.Folder : '');
|
||||
Data.messageListEndSearch(Utils.isNormal(oData.Result.Search) ? oData.Result.Search : '');
|
||||
Data.messageListEndPage(Data.messageListPage());
|
||||
|
||||
Data.messageList(aList);
|
||||
Data.messageListIsNotCompleted(false);
|
||||
|
||||
if (aStaticList.length < aList.length)
|
||||
{
|
||||
Data.staticMessageList = aList;
|
||||
}
|
||||
|
||||
Cache.clearNewMessageCache();
|
||||
|
||||
if (oFolder && (bCached || bUnreadCountChange || SettingsStore.useThreads()))
|
||||
{
|
||||
this.folderInformation(oFolder.fullNameRaw, aList);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Data.messageListCount(0);
|
||||
Data.messageList([]);
|
||||
Data.messageListError(Translator.getNotification(
|
||||
oData && oData.ErrorCode ? oData.ErrorCode : Enums.Notification.CantGetMessageList
|
||||
));
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string} sNamespace
|
||||
* @param {Array} aFolders
|
||||
|
|
@ -1163,13 +1035,13 @@
|
|||
{
|
||||
if (!Utils.isUnd(oData.Result.Namespace))
|
||||
{
|
||||
Data.namespace = oData.Result.Namespace;
|
||||
FolderStore.namespace = oData.Result.Namespace;
|
||||
}
|
||||
|
||||
AppStore.threadsAllowed(!!Settings.settingsGet('UseImapThread') &&
|
||||
oData.Result.IsThreadsSupported && true);
|
||||
|
||||
Data.folderList(this.folderResponseParseRec(Data.namespace, oData.Result['@Collection']));
|
||||
FolderStore.folderList(this.folderResponseParseRec(FolderStore.namespace, oData.Result['@Collection']));
|
||||
|
||||
if (oData.Result['SystemFolders'] && '' === '' +
|
||||
Settings.settingsGet('SentFolder') +
|
||||
|
|
@ -1525,7 +1397,7 @@
|
|||
});
|
||||
|
||||
Events.sub('interval.3m', function () {
|
||||
var sF = Data.currentFolderFullNameRaw();
|
||||
var sF = FolderStore.currentFolderFullNameRaw();
|
||||
if (Cache.getFolderInboxName() !== sF)
|
||||
{
|
||||
self.folderInformation(sF);
|
||||
|
|
@ -1562,7 +1434,7 @@
|
|||
self.accountsAndIdentities(true);
|
||||
|
||||
_.delay(function () {
|
||||
var sF = Data.currentFolderFullNameRaw();
|
||||
var sF = FolderStore.currentFolderFullNameRaw();
|
||||
if (Cache.getFolderInboxName() !== sF)
|
||||
{
|
||||
self.folderInformation(sF);
|
||||
|
|
|
|||
|
|
@ -129,7 +129,15 @@
|
|||
'removeDialogTabs': 'link:advanced;link:target;image:advanced;images:advanced',
|
||||
|
||||
'extraPlugins': 'plain,signature',
|
||||
|
||||
'allowedContent': true,
|
||||
'extraAllowedContent': true,
|
||||
|
||||
'forceEnterMode': true,
|
||||
|
||||
'autoParagraph': false,
|
||||
'fillEmptyBlocks': false,
|
||||
'ignoreEmptyParagraph': true,
|
||||
|
||||
'font_defaultLabel': 'Arial',
|
||||
'fontSize_defaultLabel': '13',
|
||||
|
|
|
|||
|
|
@ -267,6 +267,19 @@
|
|||
window.CKEDITOR.env.isCompatible = true;
|
||||
}
|
||||
|
||||
// oConfig.allowedContent = {
|
||||
// $1: {
|
||||
// elements: window.CKEDITOR.dtd,
|
||||
// attributes: true,
|
||||
// styles: true,
|
||||
// classes: true
|
||||
// }
|
||||
// };
|
||||
//
|
||||
// oConfig.disallowedContent = 'script; style; iframe; frame; *[on*]';
|
||||
|
||||
window.CKEDITOR.dtd.$removeEmpty['p'] = 1;
|
||||
|
||||
self.editor = window.CKEDITOR.appendTo(self.$element[0], oConfig);
|
||||
|
||||
self.editor.on('key', function(oEvent) {
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
FilterConditionModel = require('Model/FilterCondition'),
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
Events = require('Common/Events'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
AbstractModel = require('Knoin/AbstractModel')
|
||||
;
|
||||
|
|
|
|||
|
|
@ -1205,9 +1205,8 @@
|
|||
var
|
||||
aRes = [],
|
||||
mPgpMessage = null,
|
||||
Data = require('Storage/User/Data'),
|
||||
sFrom = this.from && this.from[0] && this.from[0].email ? this.from[0].email : '',
|
||||
aPublicKeys = Data.findPublicKeysByEmail(sFrom),
|
||||
aPublicKeys = PgpStore.findPublicKeysByEmail(sFrom),
|
||||
oValidKey = null,
|
||||
oValidSysKey = null,
|
||||
sPlain = ''
|
||||
|
|
@ -1233,7 +1232,7 @@
|
|||
|
||||
if (oValidKey)
|
||||
{
|
||||
oValidSysKey = Data.findPublicKeyByHex(oValidKey.keyid.toHex());
|
||||
oValidSysKey = PgpStore.findPublicKeyByHex(oValidKey.keyid.toHex());
|
||||
if (oValidSysKey)
|
||||
{
|
||||
sPlain = mPgpMessage.getText();
|
||||
|
|
@ -1269,10 +1268,9 @@
|
|||
aRes = [],
|
||||
mPgpMessage = null,
|
||||
mPgpMessageDecrypted = null,
|
||||
Data = require('Storage/User/Data'),
|
||||
sFrom = this.from && this.from[0] && this.from[0].email ? this.from[0].email : '',
|
||||
aPublicKey = Data.findPublicKeysByEmail(sFrom),
|
||||
oPrivateKey = Data.findSelfPrivateKey(sPassword),
|
||||
aPublicKey = PgpStore.findPublicKeysByEmail(sFrom),
|
||||
oPrivateKey = PgpStore.findSelfPrivateKey(sPassword),
|
||||
oValidKey = null,
|
||||
oValidSysKey = null,
|
||||
sPlain = ''
|
||||
|
|
@ -1305,7 +1303,7 @@
|
|||
|
||||
if (oValidKey)
|
||||
{
|
||||
oValidSysKey = Data.findPublicKeyByHex(oValidKey.keyid.toHex());
|
||||
oValidSysKey = PgpStore.findPublicKeyByHex(oValidKey.keyid.toHex());
|
||||
if (oValidSysKey)
|
||||
{
|
||||
this.pgpSignedVerifyStatus(Enums.SignedVerifyStatus.Success);
|
||||
|
|
|
|||
|
|
@ -21,12 +21,12 @@
|
|||
/**
|
||||
* @constructor
|
||||
*/
|
||||
function AbstractRemoteStorage()
|
||||
function AbstractAjaxRemote()
|
||||
{
|
||||
this.oRequests = {};
|
||||
}
|
||||
|
||||
AbstractRemoteStorage.prototype.oRequests = {};
|
||||
AbstractAjaxRemote.prototype.oRequests = {};
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
|
|
@ -36,7 +36,7 @@
|
|||
* @param {boolean} bCached
|
||||
* @param {*=} oRequestParameters
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.defaultResponse = function (fCallback, sRequestAction, sType, oData, bCached, oRequestParameters)
|
||||
AbstractAjaxRemote.prototype.defaultResponse = function (fCallback, sRequestAction, sType, oData, bCached, oRequestParameters)
|
||||
{
|
||||
var
|
||||
fCall = function () {
|
||||
|
|
@ -134,7 +134,7 @@
|
|||
* @param {Array=} aAbortActions = []
|
||||
* @return {jQuery.jqXHR}
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.ajaxRequest = function (fResultCallback, oParameters, iTimeOut, sGetAdd, aAbortActions)
|
||||
AbstractAjaxRemote.prototype.ajaxRequest = function (fResultCallback, oParameters, iTimeOut, sGetAdd, aAbortActions)
|
||||
{
|
||||
var
|
||||
self = this,
|
||||
|
|
@ -230,7 +230,7 @@
|
|||
* @param {string=} sGetAdd = ''
|
||||
* @param {Array=} aAbortActions = []
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.defaultRequest = function (fCallback, sAction, oParameters, iTimeout, sGetAdd, aAbortActions)
|
||||
AbstractAjaxRemote.prototype.defaultRequest = function (fCallback, sAction, oParameters, iTimeout, sGetAdd, aAbortActions)
|
||||
{
|
||||
oParameters = oParameters || {};
|
||||
oParameters.Action = sAction;
|
||||
|
|
@ -246,7 +246,7 @@
|
|||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.noop = function (fCallback)
|
||||
AbstractAjaxRemote.prototype.noop = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'Noop');
|
||||
};
|
||||
|
|
@ -260,7 +260,7 @@
|
|||
* @param {string} sHtmlCapa
|
||||
* @param {number} iTime
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.jsError = function (fCallback, sMessage, sFileName, iLineNo, sLocation, sHtmlCapa, iTime)
|
||||
AbstractAjaxRemote.prototype.jsError = function (fCallback, sMessage, sFileName, iLineNo, sLocation, sHtmlCapa, iTime)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'JsError', {
|
||||
'Message': sMessage,
|
||||
|
|
@ -278,7 +278,7 @@
|
|||
* @param {Array=} mData = null
|
||||
* @param {boolean=} bIsError = false
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.jsInfo = function (fCallback, sType, mData, bIsError)
|
||||
AbstractAjaxRemote.prototype.jsInfo = function (fCallback, sType, mData, bIsError)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'JsInfo', {
|
||||
'Type': sType,
|
||||
|
|
@ -290,7 +290,7 @@
|
|||
/**
|
||||
* @param {?Function} fCallback
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.getPublicKey = function (fCallback)
|
||||
AbstractAjaxRemote.prototype.getPublicKey = function (fCallback)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'GetPublicKey');
|
||||
};
|
||||
|
|
@ -299,13 +299,13 @@
|
|||
* @param {?Function} fCallback
|
||||
* @param {string} sVersion
|
||||
*/
|
||||
AbstractRemoteStorage.prototype.jsVersion = function (fCallback, sVersion)
|
||||
AbstractAjaxRemote.prototype.jsVersion = function (fCallback, sVersion)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'Version', {
|
||||
'Version': sVersion
|
||||
});
|
||||
};
|
||||
|
||||
module.exports = AbstractRemoteStorage;
|
||||
module.exports = AbstractAjaxRemote;
|
||||
|
||||
}());
|
||||
|
|
@ -6,21 +6,21 @@
|
|||
var
|
||||
_ = require('_'),
|
||||
|
||||
AbstractRemoteStorage = require('Storage/AbstractRemote')
|
||||
AbstractAjaxRemote = require('Remote/AbstractAjax')
|
||||
;
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
* @extends AbstractRemoteStorage
|
||||
* @extends AbstractAjaxRemote
|
||||
*/
|
||||
function RemoteAdminStorage()
|
||||
{
|
||||
AbstractRemoteStorage.call(this);
|
||||
AbstractAjaxRemote.call(this);
|
||||
|
||||
this.oRequests = {};
|
||||
}
|
||||
|
||||
_.extend(RemoteAdminStorage.prototype, AbstractRemoteStorage.prototype);
|
||||
_.extend(RemoteAdminStorage.prototype, AbstractAjaxRemote.prototype);
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
|
|
@ -10,14 +10,15 @@
|
|||
Consts = require('Common/Consts'),
|
||||
Base64 = require('Common/Base64'),
|
||||
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Data = require('Storage/User/Data'),
|
||||
|
||||
AbstractRemoteStorage = require('Storage/AbstractRemote')
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
AbstractAjaxRemote = require('Remote/AbstractAjax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -26,14 +27,14 @@
|
|||
*/
|
||||
function RemoteUserStorage()
|
||||
{
|
||||
AbstractRemoteStorage.call(this);
|
||||
AbstractAjaxRemote.call(this);
|
||||
|
||||
this.oRequests = {};
|
||||
|
||||
this.sSubSubQuery = '&ss=/';
|
||||
}
|
||||
|
||||
_.extend(RemoteUserStorage.prototype, AbstractRemoteStorage.prototype);
|
||||
_.extend(RemoteUserStorage.prototype, AbstractAjaxRemote.prototype);
|
||||
|
||||
/**
|
||||
* @param {?Function} fCallback
|
||||
|
|
@ -348,7 +349,7 @@
|
|||
sFolderHash,
|
||||
Cache.getFolderInboxName() === sFolderFullNameRaw ? Cache.getFolderUidNext(sFolderFullNameRaw) : '',
|
||||
AppStore.threadsAllowed() && SettingsStore.useThreads() ? '1' : '0',
|
||||
AppStore.threadsAllowed() && sFolderFullNameRaw === Data.messageListThreadFolder() ? Data.messageListThreadUids().join(',') : ''
|
||||
AppStore.threadsAllowed() && sFolderFullNameRaw === MessageStore.messageListThreadFolder() ? MessageStore.messageListThreadUids().join(',') : ''
|
||||
].join(String.fromCharCode(0))), bSilent ? [] : ['MessageList']);
|
||||
}
|
||||
else
|
||||
|
|
@ -360,7 +361,7 @@
|
|||
'Search': sSearch,
|
||||
'UidNext': Cache.getFolderInboxName() === sFolderFullNameRaw ? Cache.getFolderUidNext(sFolderFullNameRaw) : '',
|
||||
'UseThreads': AppStore.threadsAllowed() && SettingsStore.useThreads() ? '1' : '0',
|
||||
'ExpandedThreadUid': AppStore.threadsAllowed() && sFolderFullNameRaw === Data.messageListThreadFolder() ? Data.messageListThreadUids().join(',') : ''
|
||||
'ExpandedThreadUid': AppStore.threadsAllowed() && sFolderFullNameRaw === MessageStore.messageListThreadFolder() ? MessageStore.messageListThreadUids().join(',') : ''
|
||||
}, '' === sSearch ? Consts.Defaults.DefaultAjaxTimeout : Consts.Defaults.SearchAjaxTimeout, '', bSilent ? [] : ['MessageList']);
|
||||
}
|
||||
};
|
||||
|
|
@ -619,12 +620,13 @@
|
|||
* @param {(Array|null)} aDraftInfo
|
||||
* @param {string} sInReplyTo
|
||||
* @param {string} sReferences
|
||||
* @param {boolean} bRequestDsn
|
||||
* @param {boolean} bRequestReadReceipt
|
||||
* @param {boolean} bMarkAsImportant
|
||||
*/
|
||||
RemoteUserStorage.prototype.sendMessage = function (fCallback, sIdentityID, sMessageFolder, sMessageUid, sSentFolder,
|
||||
sTo, sCc, sBcc, sReplyTo, sSubject, bTextIsHtml, sText, aAttachments, aDraftInfo, sInReplyTo, sReferences,
|
||||
bRequestReadReceipt, bMarkAsImportant)
|
||||
bRequestDsn, bRequestReadReceipt, bMarkAsImportant)
|
||||
{
|
||||
this.defaultRequest(fCallback, 'SendMessage', {
|
||||
'IdentityID': sIdentityID,
|
||||
|
|
@ -641,6 +643,7 @@
|
|||
'DraftInfo': aDraftInfo,
|
||||
'InReplyTo': sInReplyTo,
|
||||
'References': sReferences,
|
||||
'Dsn': bRequestDsn ? '1' : '0',
|
||||
'ReadReceiptRequest': bRequestReadReceipt ? '1' : '0',
|
||||
'MarkAsImportant': bMarkAsImportant ? '1' : '0',
|
||||
'Attachments': aAttachments
|
||||
|
|
@ -12,11 +12,12 @@
|
|||
Events = require('Common/Events'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
AccountStore = require('Stores/User/Account'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
AbstractScreen = require('Knoin/AbstractScreen')
|
||||
;
|
||||
|
|
@ -48,7 +49,7 @@
|
|||
{
|
||||
var
|
||||
sEmail = AccountStore.email(),
|
||||
nFoldersInboxUnreadCount = Data.foldersInboxUnreadCount()
|
||||
nFoldersInboxUnreadCount = FolderStore.foldersInboxUnreadCount()
|
||||
;
|
||||
|
||||
require('App/User').setTitle(('' === sEmail ? '' :
|
||||
|
|
@ -72,7 +73,7 @@
|
|||
{
|
||||
if (Utils.isUnd(bPreview) ? false : !!bPreview)
|
||||
{
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && !Data.message())
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && !MessageStore.message())
|
||||
{
|
||||
require('App/User').historyBack();
|
||||
}
|
||||
|
|
@ -86,15 +87,13 @@
|
|||
|
||||
if (oFolder)
|
||||
{
|
||||
Data
|
||||
.currentFolder(oFolder)
|
||||
.messageListPage(iPage)
|
||||
.messageListSearch(sSearch)
|
||||
;
|
||||
FolderStore.currentFolder(oFolder);
|
||||
MessageStore.messageListPage(iPage);
|
||||
MessageStore.messageListSearch(sSearch);
|
||||
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && Data.message())
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && MessageStore.message())
|
||||
{
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
}
|
||||
|
||||
require('App/User').reloadMessageList();
|
||||
|
|
@ -104,9 +103,10 @@
|
|||
|
||||
MailBoxUserScreen.prototype.onStart = function ()
|
||||
{
|
||||
Data.folderList.subscribe(Utils.windowResizeCallback);
|
||||
Data.messageList.subscribe(Utils.windowResizeCallback);
|
||||
Data.message.subscribe(Utils.windowResizeCallback);
|
||||
FolderStore.folderList.subscribe(Utils.windowResizeCallback);
|
||||
|
||||
MessageStore.messageList.subscribe(Utils.windowResizeCallback);
|
||||
MessageStore.message.subscribe(Utils.windowResizeCallback);
|
||||
|
||||
_.delay(function () {
|
||||
SettingsStore.layout.valueHasMutated();
|
||||
|
|
@ -114,7 +114,7 @@
|
|||
|
||||
Events.sub('mailbox.inbox-unread-count', function (iCount) {
|
||||
|
||||
Data.foldersInboxUnreadCount(iCount);
|
||||
FolderStore.foldersInboxUnreadCount(iCount);
|
||||
|
||||
var sEmail = AccountStore.email();
|
||||
|
||||
|
|
@ -126,7 +126,7 @@
|
|||
});
|
||||
});
|
||||
|
||||
Data.foldersInboxUnreadCount.subscribe(function () {
|
||||
FolderStore.foldersInboxUnreadCount.subscribe(function () {
|
||||
this.setNewTitle();
|
||||
}, this);
|
||||
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@
|
|||
{
|
||||
var
|
||||
self = this,
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
_.delay(function () {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
function ContactsAdminSettings()
|
||||
{
|
||||
var
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
this.defautOptionsAfterRender = Utils.defautOptionsAfterRender;
|
||||
|
|
@ -178,7 +178,7 @@
|
|||
{
|
||||
var
|
||||
self = this,
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
_.delay(function () {
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
Enums = require('Common/Enums'),
|
||||
|
||||
DomainStore = require('Stores/Admin/Domain'),
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -68,7 +68,7 @@
|
|||
{
|
||||
var
|
||||
self = this,
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
_.delay(function () {
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@
|
|||
{
|
||||
var
|
||||
self = this,
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
_.delay(function () {
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
Translator = require('Common/Translator'),
|
||||
|
||||
PackageStore = require('Stores/Admin/Package'),
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
Settings = require('Storage/Settings'),
|
||||
PluginStore = require('Stores/Admin/Plugin'),
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
CapaAdminStore = require('Stores/Admin/Capa'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -114,10 +114,6 @@
|
|||
|
||||
SecurityAdminSettings.prototype.onBuild = function ()
|
||||
{
|
||||
var
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
;
|
||||
|
||||
this.capaOpenPGP.subscribe(function (bValue) {
|
||||
Remote.saveAdminConfig(Utils.emptyFunction, {
|
||||
'CapaOpenPGP': bValue ? '1' : '0'
|
||||
|
|
|
|||
|
|
@ -59,7 +59,7 @@
|
|||
{
|
||||
var
|
||||
self = this,
|
||||
Remote = require('Storage/Admin/Remote')
|
||||
Remote = require('Remote/Admin/Ajax')
|
||||
;
|
||||
|
||||
_.delay(function () {
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
IdentityStore = require('Stores/User/Identity'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -7,9 +7,9 @@
|
|||
ko = require('ko'),
|
||||
|
||||
AppStore = require('Stores/User/App'),
|
||||
ContactStore = require('Stores/User/Contact'),
|
||||
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Data = require('Storage/User/Data')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -19,11 +19,11 @@
|
|||
{
|
||||
this.contactsAutosave = AppStore.contactsAutosave;
|
||||
|
||||
this.allowContactsSync = Data.allowContactsSync;
|
||||
this.enableContactsSync = Data.enableContactsSync;
|
||||
this.contactsSyncUrl = Data.contactsSyncUrl;
|
||||
this.contactsSyncUser = Data.contactsSyncUser;
|
||||
this.contactsSyncPass = Data.contactsSyncPass;
|
||||
this.allowContactsSync = ContactStore.allowContactsSync;
|
||||
this.enableContactsSync = ContactStore.enableContactsSync;
|
||||
this.contactsSyncUrl = ContactStore.contactsSyncUrl;
|
||||
this.contactsSyncUser = ContactStore.contactsSyncUser;
|
||||
this.contactsSyncPass = ContactStore.contactsSyncPass;
|
||||
|
||||
this.saveTrigger = ko.computed(function () {
|
||||
return [
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
FilterStore = require('Stores/User/Filter'),
|
||||
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -10,11 +10,14 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Local = require('Storage/Client')
|
||||
Local = require('Storage/Client'),
|
||||
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -22,15 +25,15 @@
|
|||
*/
|
||||
function FoldersUserSettings()
|
||||
{
|
||||
this.folderList = Data.folderList;
|
||||
this.folderList = FolderStore.folderList;
|
||||
|
||||
this.loading = ko.computed(function () {
|
||||
|
||||
var
|
||||
bLoading = Data.foldersLoading(),
|
||||
bCreating = Data.foldersCreating(),
|
||||
bDeleting = Data.foldersDeleting(),
|
||||
bRenaming = Data.foldersRenaming()
|
||||
bLoading = FolderStore.foldersLoading(),
|
||||
bCreating = FolderStore.foldersCreating(),
|
||||
bDeleting = FolderStore.foldersDeleting(),
|
||||
bRenaming = FolderStore.foldersRenaming()
|
||||
;
|
||||
|
||||
return bLoading || bCreating || bDeleting || bRenaming;
|
||||
|
|
@ -66,13 +69,13 @@
|
|||
{
|
||||
Local.set(Enums.ClientSideKeyName.FoldersLashHash, '');
|
||||
|
||||
Data.foldersRenaming(true);
|
||||
FolderStore.foldersRenaming(true);
|
||||
Remote.folderRename(function (sResult, oData) {
|
||||
|
||||
Data.foldersRenaming(false);
|
||||
FolderStore.foldersRenaming(false);
|
||||
if (Enums.StorageResultType.Success !== sResult || !oData || !oData.Result)
|
||||
{
|
||||
Data.folderList.error(
|
||||
FolderStore.folderList.error(
|
||||
oData && oData.ErrorCode ? Translator.getNotification(oData.ErrorCode) : Translator.i18n('NOTIFICATIONS/CANT_RENAME_FOLDER'));
|
||||
}
|
||||
|
||||
|
|
@ -98,7 +101,7 @@
|
|||
|
||||
FoldersUserSettings.prototype.onShow = function ()
|
||||
{
|
||||
Data.folderList.error('');
|
||||
FolderStore.folderList.error('');
|
||||
};
|
||||
|
||||
FoldersUserSettings.prototype.createFolder = function ()
|
||||
|
|
@ -135,15 +138,15 @@
|
|||
{
|
||||
Local.set(Enums.ClientSideKeyName.FoldersLashHash, '');
|
||||
|
||||
Data.folderList.remove(fRemoveFolder);
|
||||
FolderStore.folderList.remove(fRemoveFolder);
|
||||
|
||||
Data.foldersDeleting(true);
|
||||
FolderStore.foldersDeleting(true);
|
||||
Remote.folderDelete(function (sResult, oData) {
|
||||
|
||||
Data.foldersDeleting(false);
|
||||
FolderStore.foldersDeleting(false);
|
||||
if (Enums.StorageResultType.Success !== sResult || !oData || !oData.Result)
|
||||
{
|
||||
Data.folderList.error(
|
||||
FolderStore.folderList.error(
|
||||
oData && oData.ErrorCode ? Translator.getNotification(oData.ErrorCode) : Translator.i18n('NOTIFICATIONS/CANT_DELETE_FOLDER'));
|
||||
}
|
||||
|
||||
|
|
@ -156,7 +159,7 @@
|
|||
}
|
||||
else if (0 < oFolderToRemove.privateMessageCountAll())
|
||||
{
|
||||
Data.folderList.error(Translator.getNotification(Enums.Notification.CantDeleteNonEmptyFolder));
|
||||
FolderStore.folderList.error(Translator.getNotification(Enums.Notification.CantDeleteNonEmptyFolder));
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -17,9 +17,9 @@
|
|||
LanguageStore = require('Stores/Language'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
NotificationStore = require('Stores/User/Notification'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -163,7 +163,7 @@
|
|||
|
||||
self.useThreads.subscribe(function (bValue) {
|
||||
|
||||
Data.messageList([]);
|
||||
MessageStore.messageList([]);
|
||||
|
||||
Remote.saveSettings(null, {
|
||||
'UseThreads': bValue ? '1' : '0'
|
||||
|
|
@ -172,7 +172,7 @@
|
|||
|
||||
self.layout.subscribe(function (nValue) {
|
||||
|
||||
Data.messageList([]);
|
||||
MessageStore.messageList([]);
|
||||
|
||||
Remote.saveSettings(f2, {
|
||||
'Layout': nValue
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
|
||||
Settings = require('Storage/Settings'),
|
||||
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
TemplateStore = require('Stores/User/Template'),
|
||||
|
||||
Remote = require('Storage/User/Remote')
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
ThemeStore = require('Stores/Theme'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/User/Remote')
|
||||
|
||||
Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -21,6 +21,8 @@
|
|||
this.projectHash = ko.observable('');
|
||||
this.threadsAllowed = ko.observable(false);
|
||||
|
||||
this.composeInEdit = ko.observable(false);
|
||||
|
||||
this.contactsAutosave = ko.observable(false);
|
||||
this.useLocalProxyForExternalImages = ko.observable(false);
|
||||
|
||||
|
|
|
|||
43
dev/Stores/User/Contact.js
Normal file
43
dev/Stores/User/Contact.js
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
|
||||
(function () {
|
||||
|
||||
'use strict';
|
||||
|
||||
var
|
||||
ko = require('ko'),
|
||||
|
||||
Settings = require('Storage/Settings')
|
||||
;
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
*/
|
||||
function ContactUserStore()
|
||||
{
|
||||
this.contacts = ko.observableArray([]);
|
||||
this.contacts.loading = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.importing = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.syncing = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.exportingVcf = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.exportingCsv = ko.observable(false).extend({'throttle': 200});
|
||||
|
||||
this.allowContactsSync = ko.observable(false);
|
||||
this.enableContactsSync = ko.observable(false);
|
||||
this.contactsSyncUrl = ko.observable('');
|
||||
this.contactsSyncUser = ko.observable('');
|
||||
this.contactsSyncPass = ko.observable('');
|
||||
}
|
||||
|
||||
ContactUserStore.prototype.populate = function ()
|
||||
{
|
||||
this.allowContactsSync(!!Settings.settingsGet('ContactsSyncIsAllowed'));
|
||||
this.enableContactsSync(!!Settings.settingsGet('EnableContactsSync'));
|
||||
|
||||
this.contactsSyncUrl(Settings.settingsGet('ContactsSyncUrl'));
|
||||
this.contactsSyncUser(Settings.settingsGet('ContactsSyncUser'));
|
||||
this.contactsSyncPass(Settings.settingsGet('ContactsSyncPassword'));
|
||||
};
|
||||
|
||||
module.exports = new ContactUserStore();
|
||||
|
||||
}());
|
||||
|
|
@ -4,12 +4,16 @@
|
|||
'use strict';
|
||||
|
||||
var
|
||||
_ = require('_'),
|
||||
ko = require('ko'),
|
||||
moment = require('moment'),
|
||||
|
||||
Enums = require('Common/Enums'),
|
||||
Consts = require('Common/Consts'),
|
||||
Globals = require('Common/Globals'),
|
||||
Utils = require('Common/Utils'),
|
||||
|
||||
Cache = require('Storage/User/Cache')
|
||||
Cache = require('Common/Cache')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -23,6 +27,25 @@
|
|||
this.trashFolder = ko.observable('');
|
||||
this.archiveFolder = ko.observable('');
|
||||
|
||||
this.namespace = '';
|
||||
|
||||
this.folderList = ko.observableArray([]);
|
||||
this.folderList.focused = ko.observable(false);
|
||||
this.folderList.optimized = ko.observable(false);
|
||||
this.folderList.error = ko.observable('');
|
||||
|
||||
this.foldersLoading = ko.observable(false);
|
||||
this.foldersCreating = ko.observable(false);
|
||||
this.foldersDeleting = ko.observable(false);
|
||||
this.foldersRenaming = ko.observable(false);
|
||||
|
||||
this.foldersInboxUnreadCount = ko.observable(0);
|
||||
|
||||
this.currentFolder = ko.observable(null).extend({'toggleSubscribe': [null,
|
||||
function (oPrev) { if (oPrev) { oPrev.selected(false); }},
|
||||
function (oNext) { if (oNext) { oNext.selected(true); }}
|
||||
]});
|
||||
|
||||
this.computers();
|
||||
this.subscribers();
|
||||
}
|
||||
|
|
@ -32,6 +55,96 @@
|
|||
this.draftFolderNotEnabled = ko.computed(function () {
|
||||
return '' === this.draftFolder() || Consts.Values.UnuseOptionValue === this.draftFolder();
|
||||
}, this);
|
||||
|
||||
this.foldersListWithSingleInboxRootFolder = ko.computed(function () {
|
||||
return !_.find(this.folderList(), function (oFolder) {
|
||||
return oFolder && !oFolder.isSystemFolder() && oFolder.visible();
|
||||
});
|
||||
}, this);
|
||||
|
||||
this.currentFolderFullNameRaw = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullNameRaw : '';
|
||||
}, this);
|
||||
|
||||
this.currentFolderFullName = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullName : '';
|
||||
}, this);
|
||||
|
||||
this.currentFolderFullNameHash = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullNameHash : '';
|
||||
}, this);
|
||||
|
||||
this.foldersChanging = ko.computed(function () {
|
||||
var
|
||||
bLoading = this.foldersLoading(),
|
||||
bCreating = this.foldersCreating(),
|
||||
bDeleting = this.foldersDeleting(),
|
||||
bRenaming = this.foldersRenaming()
|
||||
;
|
||||
return bLoading || bCreating || bDeleting || bRenaming;
|
||||
}, this);
|
||||
|
||||
this.folderListSystemNames = ko.computed(function () {
|
||||
|
||||
var
|
||||
aList = [Cache.getFolderInboxName()],
|
||||
aFolders = this.folderList(),
|
||||
sSentFolder = this.sentFolder(),
|
||||
sDraftFolder = this.draftFolder(),
|
||||
sSpamFolder = this.spamFolder(),
|
||||
sTrashFolder = this.trashFolder(),
|
||||
sArchiveFolder = this.archiveFolder()
|
||||
;
|
||||
|
||||
if (Utils.isArray(aFolders) && 0 < aFolders.length)
|
||||
{
|
||||
if ('' !== sSentFolder && Consts.Values.UnuseOptionValue !== sSentFolder)
|
||||
{
|
||||
aList.push(sSentFolder);
|
||||
}
|
||||
if ('' !== sDraftFolder && Consts.Values.UnuseOptionValue !== sDraftFolder)
|
||||
{
|
||||
aList.push(sDraftFolder);
|
||||
}
|
||||
if ('' !== sSpamFolder && Consts.Values.UnuseOptionValue !== sSpamFolder)
|
||||
{
|
||||
aList.push(sSpamFolder);
|
||||
}
|
||||
if ('' !== sTrashFolder && Consts.Values.UnuseOptionValue !== sTrashFolder)
|
||||
{
|
||||
aList.push(sTrashFolder);
|
||||
}
|
||||
if ('' !== sArchiveFolder && Consts.Values.UnuseOptionValue !== sArchiveFolder)
|
||||
{
|
||||
aList.push(sArchiveFolder);
|
||||
}
|
||||
}
|
||||
|
||||
return aList;
|
||||
|
||||
}, this);
|
||||
|
||||
this.folderListSystem = ko.computed(function () {
|
||||
return _.compact(_.map(this.folderListSystemNames(), function (sName) {
|
||||
return Cache.getFolderFromCacheList(sName);
|
||||
}));
|
||||
}, this);
|
||||
|
||||
this.folderMenuForMove = ko.computed(function () {
|
||||
return Utils.folderListOptionsBuilder(this.folderListSystem(), this.folderList(), [
|
||||
this.currentFolderFullNameRaw()
|
||||
], null, null, null, null, function (oItem) {
|
||||
return oItem ? oItem.localName() : '';
|
||||
});
|
||||
}, this);
|
||||
|
||||
this.folderMenuForFilters = ko.computed(function () {
|
||||
return Utils.folderListOptionsBuilder(this.folderListSystem(), this.folderList(),
|
||||
['INBOX'], [['', '']], null, null, null, function (oItem) {
|
||||
return oItem ? oItem.localName() : '';
|
||||
}
|
||||
);
|
||||
}, this);
|
||||
};
|
||||
|
||||
FolderUserStore.prototype.subscribers = function ()
|
||||
|
|
@ -68,6 +181,76 @@
|
|||
this.spamFolder.subscribe(fSetSystemFolderType(Enums.FolderType.Spam), this);
|
||||
this.trashFolder.subscribe(fSetSystemFolderType(Enums.FolderType.Trash), this);
|
||||
this.archiveFolder.subscribe(fSetSystemFolderType(Enums.FolderType.Archive), this);
|
||||
|
||||
this.folderList.focused.subscribe(function (bValue) {
|
||||
if (bValue)
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.FolderList);
|
||||
}
|
||||
else if (Enums.KeyState.FolderList === Globals.keyScope())
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageList);
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {boolean=} bBoot = false
|
||||
* @returns {Array}
|
||||
*/
|
||||
FolderUserStore.prototype.getNextFolderNames = function (bBoot)
|
||||
{
|
||||
bBoot = Utils.isUnd(bBoot) ? false : !!bBoot;
|
||||
|
||||
var
|
||||
aResult = [],
|
||||
iLimit = 5,
|
||||
iUtc = moment().unix(),
|
||||
iTimeout = iUtc - 60 * 5,
|
||||
aTimeouts = [],
|
||||
sInboxFolderName = Cache.getFolderInboxName(),
|
||||
fSearchFunction = function (aList) {
|
||||
_.each(aList, function (oFolder) {
|
||||
if (oFolder && sInboxFolderName !== oFolder.fullNameRaw &&
|
||||
oFolder.selectable && oFolder.existen &&
|
||||
iTimeout > oFolder.interval &&
|
||||
(!bBoot || oFolder.subScribed()))
|
||||
{
|
||||
aTimeouts.push([oFolder.interval, oFolder.fullNameRaw]);
|
||||
}
|
||||
|
||||
if (oFolder && 0 < oFolder.subFolders().length)
|
||||
{
|
||||
fSearchFunction(oFolder.subFolders());
|
||||
}
|
||||
});
|
||||
}
|
||||
;
|
||||
|
||||
fSearchFunction(this.folderList());
|
||||
|
||||
aTimeouts.sort(function(a, b) {
|
||||
if (a[0] < b[0]) {
|
||||
return -1;
|
||||
} else if (a[0] > b[0]) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
});
|
||||
|
||||
_.find(aTimeouts, function (aItem) {
|
||||
var oFolder = Cache.getFolderFromCacheList(aItem[1]);
|
||||
if (oFolder)
|
||||
{
|
||||
oFolder.interval = iUtc;
|
||||
aResult.push(aItem[1]);
|
||||
}
|
||||
|
||||
return iLimit <= aResult.length;
|
||||
});
|
||||
|
||||
return _.uniq(aResult);
|
||||
};
|
||||
|
||||
module.exports = new FolderUserStore();
|
||||
|
|
|
|||
|
|
@ -4,180 +4,35 @@
|
|||
'use strict';
|
||||
|
||||
var
|
||||
window = require('window'),
|
||||
_ = require('_'),
|
||||
$ = require('$'),
|
||||
ko = require('ko'),
|
||||
window = require('window'),
|
||||
moment = require('moment'),
|
||||
$ = require('$'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
|
||||
Consts = require('Common/Consts'),
|
||||
Enums = require('Common/Enums'),
|
||||
Consts = require('Common/Consts'),
|
||||
Globals = require('Common/Globals'),
|
||||
Utils = require('Common/Utils'),
|
||||
Links = require('Common/Links'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
|
||||
MessageModel = require('Model/Message')
|
||||
;
|
||||
|
||||
/**
|
||||
* @constructor
|
||||
*/
|
||||
function DataUserStorage()
|
||||
function MessageUserStore()
|
||||
{
|
||||
// contacts
|
||||
this.contacts = ko.observableArray([]);
|
||||
this.contacts.loading = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.importing = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.syncing = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.exportingVcf = ko.observable(false).extend({'throttle': 200});
|
||||
this.contacts.exportingCsv = ko.observable(false).extend({'throttle': 200});
|
||||
|
||||
this.allowContactsSync = ko.observable(false);
|
||||
this.enableContactsSync = ko.observable(false);
|
||||
this.contactsSyncUrl = ko.observable('');
|
||||
this.contactsSyncUser = ko.observable('');
|
||||
this.contactsSyncPass = ko.observable('');
|
||||
|
||||
this.allowContactsSync = ko.observable(!!Settings.settingsGet('ContactsSyncIsAllowed'));
|
||||
this.enableContactsSync = ko.observable(!!Settings.settingsGet('EnableContactsSync'));
|
||||
this.contactsSyncUrl = ko.observable(Settings.settingsGet('ContactsSyncUrl'));
|
||||
this.contactsSyncUser = ko.observable(Settings.settingsGet('ContactsSyncUser'));
|
||||
this.contactsSyncPass = ko.observable(Settings.settingsGet('ContactsSyncPassword'));
|
||||
|
||||
// folders
|
||||
this.namespace = '';
|
||||
this.folderList = ko.observableArray([]);
|
||||
this.folderList.focused = ko.observable(false);
|
||||
this.folderList.optimized = ko.observable(false);
|
||||
this.folderList.error = ko.observable('');
|
||||
|
||||
this.foldersLoading = ko.observable(false);
|
||||
this.foldersCreating = ko.observable(false);
|
||||
this.foldersDeleting = ko.observable(false);
|
||||
this.foldersRenaming = ko.observable(false);
|
||||
|
||||
this.foldersListWithSingleInboxRootFolder = ko.computed(function () {
|
||||
var aList = this.folderList();
|
||||
return !_.find(aList, function (oFolder) {
|
||||
return oFolder && !oFolder.isSystemFolder() && oFolder.visible();
|
||||
});
|
||||
}, this);
|
||||
|
||||
this.foldersChanging = ko.computed(function () {
|
||||
var
|
||||
bLoading = this.foldersLoading(),
|
||||
bCreating = this.foldersCreating(),
|
||||
bDeleting = this.foldersDeleting(),
|
||||
bRenaming = this.foldersRenaming()
|
||||
;
|
||||
return bLoading || bCreating || bDeleting || bRenaming;
|
||||
}, this);
|
||||
|
||||
this.foldersInboxUnreadCount = ko.observable(0);
|
||||
|
||||
this.currentFolder = ko.observable(null).extend({'toggleSubscribe': [null,
|
||||
function (oPrev) {
|
||||
if (oPrev)
|
||||
{
|
||||
oPrev.selected(false);
|
||||
}
|
||||
}, function (oNext) {
|
||||
if (oNext)
|
||||
{
|
||||
oNext.selected(true);
|
||||
}
|
||||
}
|
||||
]});
|
||||
|
||||
this.currentFolderFullNameRaw = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullNameRaw : '';
|
||||
}, this);
|
||||
|
||||
this.currentFolderFullName = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullName : '';
|
||||
}, this);
|
||||
|
||||
this.currentFolderFullNameHash = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().fullNameHash : '';
|
||||
}, this);
|
||||
|
||||
this.currentFolderName = ko.computed(function () {
|
||||
return this.currentFolder() ? this.currentFolder().name() : '';
|
||||
}, this);
|
||||
|
||||
this.folderListSystemNames = ko.computed(function () {
|
||||
|
||||
var
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
|
||||
aList = [Cache.getFolderInboxName()],
|
||||
aFolders = this.folderList(),
|
||||
sSentFolder = FolderStore.sentFolder(),
|
||||
sDraftFolder = FolderStore.draftFolder(),
|
||||
sSpamFolder = FolderStore.spamFolder(),
|
||||
sTrashFolder = FolderStore.trashFolder(),
|
||||
sArchiveFolder = FolderStore.archiveFolder()
|
||||
;
|
||||
|
||||
if (Utils.isArray(aFolders) && 0 < aFolders.length)
|
||||
{
|
||||
if ('' !== sSentFolder && Consts.Values.UnuseOptionValue !== sSentFolder)
|
||||
{
|
||||
aList.push(sSentFolder);
|
||||
}
|
||||
if ('' !== sDraftFolder && Consts.Values.UnuseOptionValue !== sDraftFolder)
|
||||
{
|
||||
aList.push(sDraftFolder);
|
||||
}
|
||||
if ('' !== sSpamFolder && Consts.Values.UnuseOptionValue !== sSpamFolder)
|
||||
{
|
||||
aList.push(sSpamFolder);
|
||||
}
|
||||
if ('' !== sTrashFolder && Consts.Values.UnuseOptionValue !== sTrashFolder)
|
||||
{
|
||||
aList.push(sTrashFolder);
|
||||
}
|
||||
if ('' !== sArchiveFolder && Consts.Values.UnuseOptionValue !== sArchiveFolder)
|
||||
{
|
||||
aList.push(sArchiveFolder);
|
||||
}
|
||||
}
|
||||
|
||||
return aList;
|
||||
|
||||
}, this);
|
||||
|
||||
this.folderListSystem = ko.computed(function () {
|
||||
return _.compact(_.map(this.folderListSystemNames(), function (sName) {
|
||||
return Cache.getFolderFromCacheList(sName);
|
||||
}));
|
||||
}, this);
|
||||
|
||||
this.folderMenuForMove = ko.computed(function () {
|
||||
return Utils.folderListOptionsBuilder(this.folderListSystem(), this.folderList(), [
|
||||
this.currentFolderFullNameRaw()
|
||||
], null, null, null, null, function (oItem) {
|
||||
return oItem ? oItem.localName() : '';
|
||||
});
|
||||
}, this);
|
||||
|
||||
this.folderMenuForFilters = ko.computed(function () {
|
||||
return Utils.folderListOptionsBuilder(this.folderListSystem(), this.folderList(),
|
||||
['INBOX'], [['', '']], null, null, null, function (oItem) {
|
||||
return oItem ? oItem.localName() : '';
|
||||
}
|
||||
);
|
||||
}, this);
|
||||
|
||||
// message list
|
||||
this.staticMessage = new MessageModel();
|
||||
this.staticMessageList = [];
|
||||
|
||||
this.messageList = ko.observableArray([]).extend({'rateLimit': 0});
|
||||
|
|
@ -185,147 +40,34 @@
|
|||
this.messageListCount = ko.observable(0);
|
||||
this.messageListSearch = ko.observable('');
|
||||
this.messageListPage = ko.observable(1);
|
||||
this.messageListError = ko.observable('');
|
||||
|
||||
this.messageListThreadFolder = ko.observable('');
|
||||
this.messageListThreadUids = ko.observableArray([]);
|
||||
|
||||
this.messageListThreadFolder.subscribe(function () {
|
||||
this.messageListThreadUids([]);
|
||||
}, this);
|
||||
|
||||
this.messageListEndFolder = ko.observable('');
|
||||
this.messageListEndSearch = ko.observable('');
|
||||
this.messageListEndPage = ko.observable(1);
|
||||
|
||||
this.messageListEndHash = ko.computed(function () {
|
||||
return this.messageListEndFolder() + '|' + this.messageListEndSearch() + '|' + this.messageListEndPage();
|
||||
}, this);
|
||||
|
||||
this.messageListPageCount = ko.computed(function () {
|
||||
var iPage = window.Math.ceil(this.messageListCount() /
|
||||
SettingsStore.messagesPerPage());
|
||||
return 0 >= iPage ? 1 : iPage;
|
||||
}, this);
|
||||
|
||||
this.mainMessageListSearch = ko.computed({
|
||||
'read': this.messageListSearch,
|
||||
'write': function (sValue) {
|
||||
kn.setHash(Links.mailBox(
|
||||
this.currentFolderFullNameHash(), 1, Utils.trim(sValue.toString())
|
||||
));
|
||||
},
|
||||
'owner': this
|
||||
});
|
||||
|
||||
this.messageListError = ko.observable('');
|
||||
|
||||
this.messageListLoading = ko.observable(false);
|
||||
this.messageListIsNotCompleted = ko.observable(false);
|
||||
this.messageListCompleteLoadingThrottle = ko.observable(false).extend({'throttle': 200});
|
||||
|
||||
this.messageListCompleteLoading = ko.computed(function () {
|
||||
var
|
||||
bOne = this.messageListLoading(),
|
||||
bTwo = this.messageListIsNotCompleted()
|
||||
;
|
||||
return bOne || bTwo;
|
||||
}, this);
|
||||
|
||||
this.messageListCompleteLoading.subscribe(function (bValue) {
|
||||
this.messageListCompleteLoadingThrottle(bValue);
|
||||
}, this);
|
||||
|
||||
this.messageList.subscribe(_.debounce(function (aList) {
|
||||
_.each(aList, function (oItem) {
|
||||
if (oItem.newForAnimation())
|
||||
{
|
||||
oItem.newForAnimation(false);
|
||||
}
|
||||
});
|
||||
}, 500));
|
||||
|
||||
// message preview
|
||||
this.staticMessageList = new MessageModel();
|
||||
// message viewer
|
||||
this.message = ko.observable(null);
|
||||
this.messageLoading = ko.observable(false);
|
||||
this.messageLoadingThrottle = ko.observable(false).extend({'throttle': 50});
|
||||
this.currentMessage = ko.observable(null);
|
||||
|
||||
this.message.focused = ko.observable(false);
|
||||
|
||||
this.message.subscribe(function (oMessage) {
|
||||
if (!oMessage)
|
||||
{
|
||||
this.message.focused(false);
|
||||
this.messageFullScreenMode(false);
|
||||
this.hideMessageBodies();
|
||||
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() &&
|
||||
-1 < window.location.hash.indexOf('message-preview'))
|
||||
{
|
||||
require('App/User').historyBack();
|
||||
}
|
||||
}
|
||||
else if (Enums.Layout.NoPreview === SettingsStore.layout())
|
||||
{
|
||||
this.message.focused(true);
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.message.focused.subscribe(function (bValue) {
|
||||
if (bValue)
|
||||
{
|
||||
this.folderList.focused(false);
|
||||
Globals.keyScope(Enums.KeyState.MessageView);
|
||||
}
|
||||
else if (Enums.KeyState.MessageView === Globals.keyScope())
|
||||
{
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && this.message())
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageView);
|
||||
}
|
||||
else
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageList);
|
||||
}
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.folderList.focused.subscribe(function (bValue) {
|
||||
if (bValue)
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.FolderList);
|
||||
}
|
||||
else if (Enums.KeyState.FolderList === Globals.keyScope())
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageList);
|
||||
}
|
||||
});
|
||||
|
||||
this.messageLoading.subscribe(function (bValue) {
|
||||
this.messageLoadingThrottle(bValue);
|
||||
}, this);
|
||||
this.messageError = ko.observable('');
|
||||
this.messageLoading = ko.observable(false);
|
||||
this.messageLoadingThrottle = ko.observable(false).extend({'throttle': 50});
|
||||
|
||||
this.messageFullScreenMode = ko.observable(false);
|
||||
|
||||
this.messageError = ko.observable('');
|
||||
|
||||
this.messagesBodiesDom = ko.observable(null);
|
||||
|
||||
this.messagesBodiesDom.subscribe(function (oDom) {
|
||||
if (oDom && !(oDom instanceof $))
|
||||
{
|
||||
this.messagesBodiesDom($(oDom));
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.messageActiveDom = ko.observable(null);
|
||||
|
||||
this.isMessageSelected = ko.computed(function () {
|
||||
return null !== this.message();
|
||||
}, this);
|
||||
|
||||
this.currentMessage = ko.observable(null);
|
||||
|
||||
this.messageListChecked = ko.computed(function () {
|
||||
return _.filter(this.messageList(), function (oItem) {
|
||||
return oItem.checked();
|
||||
|
|
@ -362,13 +104,126 @@
|
|||
return aList;
|
||||
}, this);
|
||||
|
||||
// other
|
||||
this.composeInEdit = ko.observable(false);
|
||||
|
||||
this.computers();
|
||||
this.subscribers();
|
||||
|
||||
this.purgeMessageBodyCacheThrottle = _.throttle(this.purgeMessageBodyCache, 1000 * 30);
|
||||
}
|
||||
|
||||
DataUserStorage.prototype.purgeMessageBodyCache = function()
|
||||
MessageUserStore.prototype.computers = function ()
|
||||
{
|
||||
this.messageListEndHash = ko.computed(function () {
|
||||
return this.messageListEndFolder() + '|' + this.messageListEndSearch() + '|' + this.messageListEndPage();
|
||||
}, this);
|
||||
|
||||
this.messageListPageCount = ko.computed(function () {
|
||||
var iPage = window.Math.ceil(this.messageListCount() /
|
||||
SettingsStore.messagesPerPage());
|
||||
return 0 >= iPage ? 1 : iPage;
|
||||
}, this);
|
||||
|
||||
this.mainMessageListSearch = ko.computed({
|
||||
'read': this.messageListSearch,
|
||||
'write': function (sValue) {
|
||||
kn.setHash(Links.mailBox(
|
||||
FolderStore.currentFolderFullNameHash(), 1, Utils.trim(sValue.toString())
|
||||
));
|
||||
},
|
||||
'owner': this
|
||||
});
|
||||
|
||||
this.messageListCompleteLoading = ko.computed(function () {
|
||||
var
|
||||
bOne = this.messageListLoading(),
|
||||
bTwo = this.messageListIsNotCompleted()
|
||||
;
|
||||
return bOne || bTwo;
|
||||
}, this);
|
||||
|
||||
this.isMessageSelected = ko.computed(function () {
|
||||
return null !== this.message();
|
||||
}, this);
|
||||
};
|
||||
|
||||
MessageUserStore.prototype.subscribers = function ()
|
||||
{
|
||||
this.messageListThreadFolder.subscribe(function () {
|
||||
this.messageListThreadUids([]);
|
||||
}, this);
|
||||
|
||||
this.messageListCompleteLoading.subscribe(function (bValue) {
|
||||
this.messageListCompleteLoadingThrottle(bValue);
|
||||
}, this);
|
||||
|
||||
this.messageList.subscribe(_.debounce(function (aList) {
|
||||
_.each(aList, function (oItem) {
|
||||
if (oItem && oItem.newForAnimation())
|
||||
{
|
||||
oItem.newForAnimation(false);
|
||||
}
|
||||
});
|
||||
}, 500));
|
||||
|
||||
this.message.subscribe(function (oMessage) {
|
||||
if (!oMessage)
|
||||
{
|
||||
this.message.focused(false);
|
||||
this.messageFullScreenMode(false);
|
||||
this.hideMessageBodies();
|
||||
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() &&
|
||||
-1 < window.location.hash.indexOf('message-preview'))
|
||||
{
|
||||
require('App/User').historyBack();
|
||||
}
|
||||
}
|
||||
else if (Enums.Layout.NoPreview === SettingsStore.layout())
|
||||
{
|
||||
this.message.focused(true);
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.message.focused.subscribe(function (bValue) {
|
||||
if (bValue)
|
||||
{
|
||||
FolderStore.folderList.focused(false);
|
||||
Globals.keyScope(Enums.KeyState.MessageView);
|
||||
}
|
||||
else if (Enums.KeyState.MessageView === Globals.keyScope())
|
||||
{
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout() && this.message())
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageView);
|
||||
}
|
||||
else
|
||||
{
|
||||
Globals.keyScope(Enums.KeyState.MessageList);
|
||||
}
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.messageLoading.subscribe(function (bValue) {
|
||||
this.messageLoadingThrottle(bValue);
|
||||
}, this);
|
||||
|
||||
this.messagesBodiesDom.subscribe(function (oDom) {
|
||||
if (oDom && !(oDom instanceof $))
|
||||
{
|
||||
this.messagesBodiesDom($(oDom));
|
||||
}
|
||||
}, this);
|
||||
|
||||
this.messageListEndFolder.subscribe(function (sFolder) {
|
||||
var oMessage = this.message();
|
||||
if (oMessage && sFolder && sFolder !== oMessage.folderFullNameRaw)
|
||||
{
|
||||
this.message(null);
|
||||
}
|
||||
}, this);
|
||||
};
|
||||
|
||||
MessageUserStore.prototype.purgeMessageBodyCache = function()
|
||||
{
|
||||
var
|
||||
iCount = 0,
|
||||
|
|
@ -400,7 +255,7 @@
|
|||
}
|
||||
};
|
||||
|
||||
DataUserStorage.prototype.initUidNextAndNewMessages = function (sFolder, sUidNext, aNewMessages)
|
||||
MessageUserStore.prototype.initUidNextAndNewMessages = function (sFolder, sUidNext, aNewMessages)
|
||||
{
|
||||
if (Cache.getFolderInboxName() === sFolder && Utils.isNormal(sUidNext) && sUidNext !== '')
|
||||
{
|
||||
|
|
@ -445,7 +300,7 @@
|
|||
}
|
||||
};
|
||||
|
||||
DataUserStorage.prototype.hideMessageBodies = function ()
|
||||
MessageUserStore.prototype.hideMessageBodies = function ()
|
||||
{
|
||||
var oMessagesBodiesDom = this.messagesBodiesDom();
|
||||
if (oMessagesBodiesDom)
|
||||
|
|
@ -454,72 +309,13 @@
|
|||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {boolean=} bBoot = false
|
||||
* @returns {Array}
|
||||
*/
|
||||
DataUserStorage.prototype.getNextFolderNames = function (bBoot)
|
||||
{
|
||||
bBoot = Utils.isUnd(bBoot) ? false : !!bBoot;
|
||||
|
||||
var
|
||||
aResult = [],
|
||||
iLimit = 5,
|
||||
iUtc = moment().unix(),
|
||||
iTimeout = iUtc - 60 * 5,
|
||||
aTimeouts = [],
|
||||
sInboxFolderName = Cache.getFolderInboxName(),
|
||||
fSearchFunction = function (aList) {
|
||||
_.each(aList, function (oFolder) {
|
||||
if (oFolder && sInboxFolderName !== oFolder.fullNameRaw &&
|
||||
oFolder.selectable && oFolder.existen &&
|
||||
iTimeout > oFolder.interval &&
|
||||
(!bBoot || oFolder.subScribed()))
|
||||
{
|
||||
aTimeouts.push([oFolder.interval, oFolder.fullNameRaw]);
|
||||
}
|
||||
|
||||
if (oFolder && 0 < oFolder.subFolders().length)
|
||||
{
|
||||
fSearchFunction(oFolder.subFolders());
|
||||
}
|
||||
});
|
||||
}
|
||||
;
|
||||
|
||||
fSearchFunction(this.folderList());
|
||||
|
||||
aTimeouts.sort(function(a, b) {
|
||||
if (a[0] < b[0]) {
|
||||
return -1;
|
||||
} else if (a[0] > b[0]) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
});
|
||||
|
||||
_.find(aTimeouts, function (aItem) {
|
||||
var oFolder = Cache.getFolderFromCacheList(aItem[1]);
|
||||
if (oFolder)
|
||||
{
|
||||
oFolder.interval = iUtc;
|
||||
aResult.push(aItem[1]);
|
||||
}
|
||||
|
||||
return iLimit <= aResult.length;
|
||||
});
|
||||
|
||||
return _.uniq(aResult);
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string} sFromFolderFullNameRaw
|
||||
* @param {Array} aUidForRemove
|
||||
* @param {string=} sToFolderFullNameRaw = ''
|
||||
* @param {bCopy=} bCopy = false
|
||||
*/
|
||||
DataUserStorage.prototype.removeMessagesFromList = function (
|
||||
MessageUserStore.prototype.removeMessagesFromList = function (
|
||||
sFromFolderFullNameRaw, aUidForRemove, sToFolderFullNameRaw, bCopy)
|
||||
{
|
||||
sToFolderFullNameRaw = Utils.isNormal(sToFolderFullNameRaw) ? sToFolderFullNameRaw : '';
|
||||
|
|
@ -535,7 +331,7 @@
|
|||
aMessageList = this.messageList(),
|
||||
oFromFolder = Cache.getFolderFromCacheList(sFromFolderFullNameRaw),
|
||||
oToFolder = '' === sToFolderFullNameRaw ? null : Cache.getFolderFromCacheList(sToFolderFullNameRaw || ''),
|
||||
sCurrentFolderFullNameRaw = this.currentFolderFullNameRaw(),
|
||||
sCurrentFolderFullNameRaw = FolderStore.currentFolderFullNameRaw(),
|
||||
oCurrentMessage = this.message(),
|
||||
aMessages = sCurrentFolderFullNameRaw === sFromFolderFullNameRaw ? _.filter(aMessageList, function (oMessage) {
|
||||
return oMessage && -1 < Utils.inArray(Utils.pInt(oMessage.uid), aUidForRemove);
|
||||
|
|
@ -616,7 +412,7 @@
|
|||
/**
|
||||
* @param {Object} oMessageTextBody
|
||||
*/
|
||||
DataUserStorage.prototype.initBlockquoteSwitcher = function (oMessageTextBody)
|
||||
MessageUserStore.prototype.initBlockquoteSwitcher = function (oMessageTextBody)
|
||||
{
|
||||
if (oMessageTextBody)
|
||||
{
|
||||
|
|
@ -648,7 +444,7 @@
|
|||
}
|
||||
};
|
||||
|
||||
DataUserStorage.prototype.setMessage = function (oData, bCached)
|
||||
MessageUserStore.prototype.setMessage = function (oData, bCached)
|
||||
{
|
||||
var
|
||||
bIsHtml = false,
|
||||
|
|
@ -805,92 +601,145 @@
|
|||
* @param {Array} aList
|
||||
* @returns {string}
|
||||
*/
|
||||
DataUserStorage.prototype.calculateMessageListHash = function (aList)
|
||||
MessageUserStore.prototype.calculateMessageListHash = function (aList)
|
||||
{
|
||||
return _.map(aList, function (oMessage) {
|
||||
return '' + oMessage.hash + '_' + oMessage.threadsLen() + '_' + oMessage.flagHash();
|
||||
}).join('|');
|
||||
};
|
||||
|
||||
DataUserStorage.prototype.findPublicKeyByHex = function (sHash)
|
||||
MessageUserStore.prototype.setMessageList = function (oData, bCached)
|
||||
{
|
||||
return _.find(require('Stores/User/Pgp').openpgpkeysPublic(), function (oItem) {
|
||||
return oItem && sHash === oItem.id;
|
||||
});
|
||||
};
|
||||
if (oData && oData.Result && 'Collection/MessageCollection' === oData.Result['@Object'] &&
|
||||
oData.Result['@Collection'] && Utils.isArray(oData.Result['@Collection']))
|
||||
{
|
||||
var
|
||||
mLastCollapsedThreadUids = null,
|
||||
iIndex = 0,
|
||||
iLen = 0,
|
||||
iCount = 0,
|
||||
iOffset = 0,
|
||||
aList = [],
|
||||
iUtc = moment().unix(),
|
||||
aStaticList = this.staticMessageList,
|
||||
oJsonMessage = null,
|
||||
oMessage = null,
|
||||
oFolder = null,
|
||||
iNewCount = 0,
|
||||
bUnreadCountChange = false
|
||||
;
|
||||
|
||||
DataUserStorage.prototype.findPublicKeysByEmail = function (sEmail)
|
||||
{
|
||||
var PgpStore = require('Stores/User/Pgp');
|
||||
return _.compact(_.map(PgpStore.openpgpkeysPublic(), function (oItem) {
|
||||
iCount = Utils.pInt(oData.Result.MessageResultCount);
|
||||
iOffset = Utils.pInt(oData.Result.Offset);
|
||||
|
||||
var oKey = null;
|
||||
if (oItem && sEmail === oItem.email)
|
||||
if (Utils.isNonEmptyArray(oData.Result.LastCollapsedThreadUids))
|
||||
{
|
||||
try
|
||||
mLastCollapsedThreadUids = oData.Result.LastCollapsedThreadUids;
|
||||
}
|
||||
|
||||
oFolder = Cache.getFolderFromCacheList(
|
||||
Utils.isNormal(oData.Result.Folder) ? oData.Result.Folder : '');
|
||||
|
||||
if (oFolder && !bCached)
|
||||
{
|
||||
oFolder.interval = iUtc;
|
||||
|
||||
Cache.setFolderHash(oData.Result.Folder, oData.Result.FolderHash);
|
||||
|
||||
if (Utils.isNormal(oData.Result.MessageCount))
|
||||
{
|
||||
oKey = PgpStore.openpgp.key.readArmored(oItem.armor);
|
||||
if (oKey && !oKey.err && oKey.keys && oKey.keys[0])
|
||||
oFolder.messageCountAll(oData.Result.MessageCount);
|
||||
}
|
||||
|
||||
if (Utils.isNormal(oData.Result.MessageUnseenCount))
|
||||
{
|
||||
if (Utils.pInt(oFolder.messageCountUnread()) !== Utils.pInt(oData.Result.MessageUnseenCount))
|
||||
{
|
||||
return oKey.keys[0];
|
||||
bUnreadCountChange = true;
|
||||
}
|
||||
|
||||
oFolder.messageCountUnread(oData.Result.MessageUnseenCount);
|
||||
}
|
||||
|
||||
this.initUidNextAndNewMessages(oFolder.fullNameRaw, oData.Result.UidNext, oData.Result.NewMessages);
|
||||
}
|
||||
|
||||
if (bUnreadCountChange && oFolder)
|
||||
{
|
||||
Cache.clearMessageFlagsFromCacheByFolder(oFolder.fullNameRaw);
|
||||
}
|
||||
|
||||
for (iIndex = 0, iLen = oData.Result['@Collection'].length; iIndex < iLen; iIndex++)
|
||||
{
|
||||
oJsonMessage = oData.Result['@Collection'][iIndex];
|
||||
if (oJsonMessage && 'Object/Message' === oJsonMessage['@Object'])
|
||||
{
|
||||
oMessage = aStaticList[iIndex];
|
||||
if (!oMessage || !oMessage.initByJson(oJsonMessage))
|
||||
{
|
||||
oMessage = MessageModel.newInstanceFromJson(oJsonMessage);
|
||||
}
|
||||
|
||||
if (oMessage)
|
||||
{
|
||||
if (Cache.hasNewMessageAndRemoveFromCache(oMessage.folderFullNameRaw, oMessage.uid) && 5 >= iNewCount)
|
||||
{
|
||||
iNewCount++;
|
||||
oMessage.newForAnimation(true);
|
||||
}
|
||||
|
||||
oMessage.deleted(false);
|
||||
|
||||
if (bCached)
|
||||
{
|
||||
Cache.initMessageFlagsFromCache(oMessage);
|
||||
}
|
||||
else
|
||||
{
|
||||
Cache.storeMessageFlagsToCache(oMessage);
|
||||
}
|
||||
|
||||
oMessage.lastInCollapsedThread(mLastCollapsedThreadUids && -1 < Utils.inArray(Utils.pInt(oMessage.uid), mLastCollapsedThreadUids) ? true : false);
|
||||
|
||||
aList.push(oMessage);
|
||||
}
|
||||
}
|
||||
catch (e) {}
|
||||
}
|
||||
|
||||
return null;
|
||||
this.messageListCount(iCount);
|
||||
this.messageListSearch(Utils.isNormal(oData.Result.Search) ? oData.Result.Search : '');
|
||||
this.messageListPage(window.Math.ceil((iOffset / SettingsStore.messagesPerPage()) + 1));
|
||||
|
||||
}));
|
||||
};
|
||||
this.messageListEndFolder(Utils.isNormal(oData.Result.Folder) ? oData.Result.Folder : '');
|
||||
this.messageListEndSearch(Utils.isNormal(oData.Result.Search) ? oData.Result.Search : '');
|
||||
this.messageListEndPage(this.messageListPage());
|
||||
|
||||
/**
|
||||
* @param {string} sEmail
|
||||
* @param {string=} sPassword
|
||||
* @returns {?}
|
||||
*/
|
||||
DataUserStorage.prototype.findPrivateKeyByEmail = function (sEmail, sPassword)
|
||||
{
|
||||
var
|
||||
PgpStore = require('Stores/User/Pgp'),
|
||||
oPrivateKey = null,
|
||||
oKey = _.find(PgpStore.openpgpkeysPrivate(), function (oItem) {
|
||||
return oItem && sEmail === oItem.email;
|
||||
})
|
||||
;
|
||||
this.messageList(aList);
|
||||
this.messageListIsNotCompleted(false);
|
||||
|
||||
if (oKey)
|
||||
{
|
||||
try
|
||||
if (aStaticList.length < aList.length)
|
||||
{
|
||||
oPrivateKey = PgpStore.openpgp.key.readArmored(oKey.armor);
|
||||
if (oPrivateKey && !oPrivateKey.err && oPrivateKey.keys && oPrivateKey.keys[0])
|
||||
{
|
||||
oPrivateKey = oPrivateKey.keys[0];
|
||||
oPrivateKey.decrypt(Utils.pString(sPassword));
|
||||
}
|
||||
else
|
||||
{
|
||||
oPrivateKey = null;
|
||||
}
|
||||
this.staticMessageList = aList;
|
||||
}
|
||||
catch (e)
|
||||
|
||||
Cache.clearNewMessageCache();
|
||||
|
||||
if (oFolder && (bCached || bUnreadCountChange || SettingsStore.useThreads()))
|
||||
{
|
||||
oPrivateKey = null;
|
||||
require('App/User').folderInformation(oFolder.fullNameRaw, aList);
|
||||
}
|
||||
}
|
||||
|
||||
return oPrivateKey;
|
||||
else
|
||||
{
|
||||
this.messageListCount(0);
|
||||
this.messageList([]);
|
||||
this.messageListError(Translator.getNotification(
|
||||
oData && oData.ErrorCode ? oData.ErrorCode : Enums.Notification.CantGetMessageList
|
||||
));
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string=} sPassword
|
||||
* @returns {?}
|
||||
*/
|
||||
DataUserStorage.prototype.findSelfPrivateKey = function (sPassword)
|
||||
{
|
||||
return this.findPrivateKeyByEmail(require('Stores/User/Account').email(), sPassword);
|
||||
};
|
||||
|
||||
module.exports = new DataUserStorage();
|
||||
module.exports = new MessageUserStore();
|
||||
|
||||
}());
|
||||
|
||||
|
|
@ -3,7 +3,10 @@
|
|||
'use strict';
|
||||
|
||||
var
|
||||
ko = require('ko')
|
||||
_ = require('_'),
|
||||
ko = require('ko'),
|
||||
|
||||
Utils = require('Common/Utils')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
@ -35,6 +38,84 @@
|
|||
return !!this.openpgp;
|
||||
};
|
||||
|
||||
PgpUserStore.prototype.findPublicKeyByHex = function (sHash)
|
||||
{
|
||||
return _.find(this.openpgpkeysPublic(), function (oItem) {
|
||||
return oItem && sHash === oItem.id;
|
||||
});
|
||||
};
|
||||
|
||||
PgpUserStore.prototype.findPublicKeysByEmail = function (sEmail)
|
||||
{
|
||||
var self = this;
|
||||
return _.compact(_.map(this.openpgpkeysPublic(), function (oItem) {
|
||||
|
||||
var oKey = null;
|
||||
if (oItem && sEmail === oItem.email)
|
||||
{
|
||||
try
|
||||
{
|
||||
oKey = self.openpgp.key.readArmored(oItem.armor);
|
||||
if (oKey && !oKey.err && oKey.keys && oKey.keys[0])
|
||||
{
|
||||
return oKey.keys[0];
|
||||
}
|
||||
}
|
||||
catch (e) {}
|
||||
}
|
||||
|
||||
return null;
|
||||
|
||||
}));
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string} sEmail
|
||||
* @param {string=} sPassword
|
||||
* @returns {?}
|
||||
*/
|
||||
PgpUserStore.prototype.findPrivateKeyByEmail = function (sEmail, sPassword)
|
||||
{
|
||||
var
|
||||
oPrivateKey = null,
|
||||
oKey = _.find(this.openpgpkeysPrivate(), function (oItem) {
|
||||
return oItem && sEmail === oItem.email;
|
||||
})
|
||||
;
|
||||
|
||||
if (oKey)
|
||||
{
|
||||
try
|
||||
{
|
||||
oPrivateKey = this.openpgp.key.readArmored(oKey.armor);
|
||||
if (oPrivateKey && !oPrivateKey.err && oPrivateKey.keys && oPrivateKey.keys[0])
|
||||
{
|
||||
oPrivateKey = oPrivateKey.keys[0];
|
||||
oPrivateKey.decrypt(Utils.pString(sPassword));
|
||||
}
|
||||
else
|
||||
{
|
||||
oPrivateKey = null;
|
||||
}
|
||||
}
|
||||
catch (e)
|
||||
{
|
||||
oPrivateKey = null;
|
||||
}
|
||||
}
|
||||
|
||||
return oPrivateKey;
|
||||
};
|
||||
|
||||
/**
|
||||
* @param {string=} sPassword
|
||||
* @returns {?}
|
||||
*/
|
||||
PgpUserStore.prototype.findSelfPrivateKey = function (sPassword)
|
||||
{
|
||||
return this.findPrivateKeyByEmail(require('Stores/User/Account').email(), sPassword);
|
||||
};
|
||||
|
||||
module.exports = new PgpUserStore();
|
||||
|
||||
}());
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
_ = require('_'),
|
||||
ko = require('ko')
|
||||
|
||||
// Remote = require('Storage/User/Remote')
|
||||
// Remote = require('Remote/User/Ajax')
|
||||
;
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -56,6 +56,9 @@
|
|||
opacity: 1;
|
||||
color: #fff;
|
||||
border-color: #eee;
|
||||
|
||||
font-size: 28px;
|
||||
line-height: 28px;
|
||||
}
|
||||
|
||||
.btn.disabled {
|
||||
|
|
|
|||
|
|
@ -139,7 +139,7 @@ html.ssm-state-tablet, html.ssm-state-mobile {
|
|||
}
|
||||
|
||||
.b-compose.modal {
|
||||
width: 700px;
|
||||
width: 720px;
|
||||
}
|
||||
|
||||
.b-contacts-content.modal {
|
||||
|
|
@ -156,7 +156,7 @@ html.ssm-state-tablet, html.ssm-state-mobile {
|
|||
html.ssm-state-tablet {
|
||||
|
||||
.b-compose.modal {
|
||||
width: 700px;
|
||||
width: 720px;
|
||||
}
|
||||
|
||||
.b-contacts-content.modal {
|
||||
|
|
|
|||
|
|
@ -74,7 +74,7 @@ select {
|
|||
}
|
||||
|
||||
.btn.btn-thin {
|
||||
padding: 3px 9px;
|
||||
padding: 4px 9px;
|
||||
}
|
||||
|
||||
.btn.btn-ellipsis {
|
||||
|
|
|
|||
|
|
@ -108,11 +108,10 @@
|
|||
padding-left: 5px;
|
||||
}
|
||||
|
||||
blockquote * {
|
||||
font-family: arial,sans-serif;
|
||||
font-size: 13px;
|
||||
line-height: 16px;
|
||||
color: #333;
|
||||
blockquote p {
|
||||
margin: 0 0 10px;
|
||||
font-size: 14px;
|
||||
line-height: 20px;
|
||||
}
|
||||
|
||||
img {
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
Translator = require('Common/Translator'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@
|
|||
ko = require('ko'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
Translator = require('Common/Translator'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
LicenseStore = require('Stores/Admin/License'),
|
||||
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
|
||||
Utils = require('Common/Utils'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -41,7 +41,7 @@
|
|||
var sSearch = this.buildSearchString();
|
||||
if ('' !== sSearch)
|
||||
{
|
||||
Data.mainMessageListSearch(sSearch);
|
||||
MessageStore.mainMessageListSearch(sSearch);
|
||||
}
|
||||
|
||||
this.cancelCommand();
|
||||
|
|
|
|||
|
|
@ -21,18 +21,19 @@
|
|||
HtmlEditor = require('Common/HtmlEditor'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
IdentityStore = require('Stores/User/Identity'),
|
||||
AccountStore = require('Stores/User/Account'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
PgpStore = require('Stores/User/Pgp'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
SocialStore = require('Stores/Social'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
ComposeAttachmentModel = require('Model/ComposeAttachment'),
|
||||
|
||||
|
|
@ -87,7 +88,7 @@
|
|||
this.allowContacts = !!AppStore.contactsIsAllowed();
|
||||
|
||||
this.bSkipNextHide = false;
|
||||
this.composeInEdit = Data.composeInEdit;
|
||||
this.composeInEdit = AppStore.composeInEdit;
|
||||
this.editorDefaultType = SettingsStore.editorDefaultType;
|
||||
|
||||
this.capaOpenPGP = PgpStore.capaOpenPGP;
|
||||
|
|
@ -121,6 +122,7 @@
|
|||
this.subject = ko.observable('');
|
||||
this.isHtml = ko.observable(false);
|
||||
|
||||
this.requestDsn = ko.observable(false);
|
||||
this.requestReadReceipt = ko.observable(false);
|
||||
this.markAsImportant = ko.observable(false);
|
||||
|
||||
|
|
@ -366,6 +368,7 @@
|
|||
this.aDraftInfo,
|
||||
this.sInReplyTo,
|
||||
this.sReferences,
|
||||
this.requestDsn(),
|
||||
this.requestReadReceipt(),
|
||||
this.markAsImportant()
|
||||
);
|
||||
|
|
@ -433,8 +436,6 @@
|
|||
|
||||
var self = this;
|
||||
|
||||
window.console.log(this.sLastFocusedField);
|
||||
|
||||
_.delay(function () {
|
||||
kn.showScreenPopup(require('View/Popup/Contacts'),
|
||||
[true, self.sLastFocusedField]);
|
||||
|
|
@ -578,7 +579,7 @@
|
|||
if ('' !== sDraftFolder)
|
||||
{
|
||||
Cache.setFolderHash(sDraftFolder, '');
|
||||
if (Data.currentFolderFullNameRaw() === sDraftFolder)
|
||||
if (FolderStore.currentFolderFullNameRaw() === sDraftFolder)
|
||||
{
|
||||
require('App/User').reloadMessageList(true);
|
||||
}
|
||||
|
|
@ -701,10 +702,10 @@
|
|||
|
||||
if (this.bFromDraft)
|
||||
{
|
||||
oMessage = Data.message();
|
||||
oMessage = MessageStore.message();
|
||||
if (oMessage && this.draftFolder() === oMessage.folderFullNameRaw && this.draftUid() === oMessage.uid)
|
||||
{
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -741,7 +742,7 @@
|
|||
|
||||
if (!this.bSkipNextHide)
|
||||
{
|
||||
this.composeInEdit(false);
|
||||
AppStore.composeInEdit(false);
|
||||
this.reset();
|
||||
}
|
||||
|
||||
|
|
@ -883,7 +884,7 @@
|
|||
|
||||
this.autosaveStart();
|
||||
|
||||
if (this.composeInEdit())
|
||||
if (AppStore.composeInEdit())
|
||||
{
|
||||
sType = sType || Enums.ComposeType.Empty;
|
||||
|
||||
|
|
@ -969,7 +970,7 @@
|
|||
ComposePopupView.prototype.initOnShow = function (sType, oMessageOrArray,
|
||||
aToEmails, aCcEmails, aBccEmails, sCustomSubject, sCustomPlainText)
|
||||
{
|
||||
this.composeInEdit(true);
|
||||
AppStore.composeInEdit(true);
|
||||
|
||||
var
|
||||
self = this,
|
||||
|
|
@ -2012,6 +2013,7 @@
|
|||
this.replyTo('');
|
||||
this.subject('');
|
||||
|
||||
this.requestDsn(false);
|
||||
this.requestReadReceipt(false);
|
||||
this.markAsImportant(false);
|
||||
|
||||
|
|
|
|||
|
|
@ -12,7 +12,6 @@
|
|||
Enums = require('Common/Enums'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
PgpStore = require('Stores/User/Pgp'),
|
||||
|
||||
EmailModel = require('Model/Email'),
|
||||
|
|
@ -66,7 +65,7 @@
|
|||
|
||||
if (bResult && this.sign())
|
||||
{
|
||||
oPrivateKey = Data.findPrivateKeyByEmail(this.from(), this.password());
|
||||
oPrivateKey = PgpStore.findPrivateKeyByEmail(this.from(), this.password());
|
||||
if (!oPrivateKey)
|
||||
{
|
||||
this.notification(Translator.i18n('PGP_NOTIFICATIONS/NO_PRIVATE_KEY_FOUND_FOR', {
|
||||
|
|
@ -87,7 +86,7 @@
|
|||
{
|
||||
aPublicKeys = [];
|
||||
_.each(this.to(), function (sEmail) {
|
||||
var aKeys = Data.findPublicKeysByEmail(sEmail);
|
||||
var aKeys = PgpStore.findPublicKeysByEmail(sEmail);
|
||||
if (0 === aKeys.length && bResult)
|
||||
{
|
||||
self.notification(Translator.i18n('PGP_NOTIFICATIONS/NO_PUBLIC_KEYS_FOUND_FOR', {
|
||||
|
|
|
|||
|
|
@ -19,9 +19,9 @@
|
|||
Translator = require('Common/Translator'),
|
||||
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
ContactStore = require('Stores/User/Contact'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
EmailModel = require('Model/Email'),
|
||||
ContactModel = require('Model/Contact'),
|
||||
|
|
@ -52,13 +52,13 @@
|
|||
this.bBackToCompose = false;
|
||||
this.sLastComposeFocusedField = '';
|
||||
|
||||
this.allowContactsSync = Data.allowContactsSync;
|
||||
this.enableContactsSync = Data.enableContactsSync;
|
||||
this.allowContactsSync = ContactStore.allowContactsSync;
|
||||
this.enableContactsSync = ContactStore.enableContactsSync;
|
||||
this.allowExport = !Globals.bMobileDevice;
|
||||
|
||||
this.search = ko.observable('');
|
||||
this.contactsCount = ko.observable(0);
|
||||
this.contacts = Data.contacts;
|
||||
this.contacts = ContactStore.contacts;
|
||||
|
||||
this.currentContact = ko.observable(null);
|
||||
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@
|
|||
|
||||
CapaAdminStore = require('Stores/Admin/Capa'),
|
||||
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -12,9 +12,8 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
|
||||
FilterStore = require('Stores/User/Filter'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -38,7 +37,7 @@
|
|||
this.allowMarkAsRead = ko.observable(false);
|
||||
|
||||
this.defautOptionsAfterRender = Utils.defautOptionsAfterRender;
|
||||
this.folderSelectList = Data.folderMenuForFilters;
|
||||
this.folderSelectList = FolderStore.folderMenuForFilters;
|
||||
this.selectedFolderValue = ko.observable('');
|
||||
|
||||
this.selectedFolderValue.subscribe(function() {
|
||||
|
|
|
|||
|
|
@ -11,9 +11,11 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -56,8 +58,8 @@
|
|||
|
||||
if (oFolderToClear)
|
||||
{
|
||||
Data.message(null);
|
||||
Data.messageList([]);
|
||||
MessageStore.message(null);
|
||||
MessageStore.messageList([]);
|
||||
|
||||
this.clearingProcess(true);
|
||||
|
||||
|
|
|
|||
|
|
@ -13,8 +13,9 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -43,7 +44,7 @@
|
|||
aTop = [],
|
||||
fDisableCallback = null,
|
||||
fVisibleCallback = null,
|
||||
aList = Data.folderList(),
|
||||
aList = FolderStore.folderList(),
|
||||
fRenameCallback = function (oItem) {
|
||||
return oItem ? (oItem.isSystemFolder() ? oItem.name() + ' ' + oItem.manageFolderSystemName() : oItem.name()) : '';
|
||||
}
|
||||
|
|
@ -51,11 +52,11 @@
|
|||
|
||||
aTop.push(['', this.sNoParentText]);
|
||||
|
||||
if ('' !== Data.namespace)
|
||||
if ('' !== FolderStore.namespace)
|
||||
{
|
||||
fDisableCallback = function (oItem)
|
||||
{
|
||||
return Data.namespace !== oItem.fullNameRaw.substr(0, Data.namespace.length);
|
||||
return FolderStore.namespace !== oItem.fullNameRaw.substr(0, FolderStore.namespace.length);
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -70,22 +71,22 @@
|
|||
sParentFolderName = this.selectedParentValue()
|
||||
;
|
||||
|
||||
if ('' === sParentFolderName && 1 < Data.namespace.length)
|
||||
if ('' === sParentFolderName && 1 < FolderStore.namespace.length)
|
||||
{
|
||||
sParentFolderName = Data.namespace.substr(0, Data.namespace.length - 1);
|
||||
sParentFolderName = FolderStore.namespace.substr(0, FolderStore.namespace.length - 1);
|
||||
}
|
||||
|
||||
Data.foldersCreating(true);
|
||||
FolderStore.foldersCreating(true);
|
||||
Remote.folderCreate(function (sResult, oData) {
|
||||
|
||||
Data.foldersCreating(false);
|
||||
FolderStore.foldersCreating(false);
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
require('App/User').folders();
|
||||
}
|
||||
else
|
||||
{
|
||||
Data.folderList.error(
|
||||
FolderStore.folderList.error(
|
||||
oData && oData.ErrorCode ? Translator.getNotification(oData.ErrorCode) : Translator.i18n('NOTIFICATIONS/CANT_CREATE_FOLDER'));
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -15,8 +15,7 @@
|
|||
FolderStore = require('Stores/User/Folder'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -38,7 +37,7 @@
|
|||
this.notification = ko.observable('');
|
||||
|
||||
this.folderSelectList = ko.computed(function () {
|
||||
return Utils.folderListOptionsBuilder([], Data.folderList(), Data.folderListSystemNames(), [
|
||||
return Utils.folderListOptionsBuilder([], FolderStore.folderList(), FolderStore.folderListSystemNames(), [
|
||||
['', this.sChooseOnText],
|
||||
[Consts.Values.UnuseOptionValue, this.sUnuseText]
|
||||
], null, null, null, null, null, true);
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
Translator = require('Common/Translator'),
|
||||
HtmlEditor = require('Common/HtmlEditor'),
|
||||
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
Utils = require('Common/Utils'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Remote = require('Storage/Admin/Remote'),
|
||||
Remote = require('Remote/Admin/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@
|
|||
Translator = require('Common/Translator'),
|
||||
HtmlEditor = require('Common/HtmlEditor'),
|
||||
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
Globals = require('Common/Globals'),
|
||||
Utils = require('Common/Utils'),
|
||||
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@
|
|||
|
||||
Local = require('Storage/Client'),
|
||||
Settings = require('Storage/Settings'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -351,7 +352,7 @@
|
|||
{
|
||||
case Enums.LoginSignMeTypeAsString.DefaultOff:
|
||||
case Enums.LoginSignMeTypeAsString.DefaultOn:
|
||||
|
||||
|
||||
this.signMeType(Enums.LoginSignMeTypeAsString.DefaultOn === sSignMe ?
|
||||
Enums.LoginSignMeType.DefaultOn : Enums.LoginSignMeType.DefaultOff);
|
||||
|
||||
|
|
|
|||
|
|
@ -15,11 +15,12 @@
|
|||
Globals = require('Common/Globals'),
|
||||
Links = require('Common/Links'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
AppStore = require('Stores/User/App'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Data = require('Storage/User/Data'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -36,14 +37,14 @@
|
|||
this.oContentVisible = null;
|
||||
this.oContentScrollable = null;
|
||||
|
||||
this.composeInEdit = Data.composeInEdit;
|
||||
this.composeInEdit = AppStore.composeInEdit;
|
||||
|
||||
this.messageList = Data.messageList;
|
||||
this.folderList = Data.folderList;
|
||||
this.folderListSystem = Data.folderListSystem;
|
||||
this.foldersChanging = Data.foldersChanging;
|
||||
this.messageList = MessageStore.messageList;
|
||||
this.folderList = FolderStore.folderList;
|
||||
this.folderListSystem = FolderStore.folderListSystem;
|
||||
this.foldersChanging = FolderStore.foldersChanging;
|
||||
|
||||
this.foldersListWithSingleInboxRootFolder = Data.foldersListWithSingleInboxRootFolder;
|
||||
this.foldersListWithSingleInboxRootFolder = FolderStore.foldersListWithSingleInboxRootFolder;
|
||||
|
||||
this.leftPanelDisabled = Globals.leftPanelDisabled;
|
||||
|
||||
|
|
@ -94,10 +95,10 @@
|
|||
{
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout())
|
||||
{
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
}
|
||||
|
||||
if (oFolder.fullNameRaw === Data.currentFolderFullNameRaw())
|
||||
if (oFolder.fullNameRaw === FolderStore.currentFolderFullNameRaw())
|
||||
{
|
||||
Cache.setFolderHash(oFolder.fullNameRaw, '');
|
||||
}
|
||||
|
|
@ -143,7 +144,7 @@
|
|||
var $items = $('.b-folders .e-item .e-link:not(.hidden).focused', oDom);
|
||||
if ($items.length && $items[0])
|
||||
{
|
||||
self.folderList.focused(false);
|
||||
FolderStore.folderList.focused(false);
|
||||
$items.click();
|
||||
}
|
||||
|
||||
|
|
@ -167,11 +168,11 @@
|
|||
});
|
||||
|
||||
key('esc, tab, shift+tab, right', Enums.KeyState.FolderList, function () {
|
||||
self.folderList.focused(false);
|
||||
FolderStore.folderList.focused(false);
|
||||
return false;
|
||||
});
|
||||
|
||||
self.folderList.focused.subscribe(function (bValue) {
|
||||
FolderStore.folderList.focused.subscribe(function (bValue) {
|
||||
$('.b-folders .e-item .e-link.focused', oDom).removeClass('focused');
|
||||
if (bValue)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -20,14 +20,15 @@
|
|||
Selector = require('Common/Selector'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
QuotaStore = require('Stores/User/Quota'),
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
Settings = require('Storage/Settings'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -49,24 +50,24 @@
|
|||
|
||||
this.popupVisibility = Globals.popupVisibility;
|
||||
|
||||
this.message = Data.message;
|
||||
this.messageList = Data.messageList;
|
||||
this.folderList = Data.folderList;
|
||||
this.currentMessage = Data.currentMessage;
|
||||
this.isMessageSelected = Data.isMessageSelected;
|
||||
this.messageListSearch = Data.messageListSearch;
|
||||
this.messageListError = Data.messageListError;
|
||||
this.folderMenuForMove = Data.folderMenuForMove;
|
||||
this.message = MessageStore.message;
|
||||
this.messageList = MessageStore.messageList;
|
||||
this.folderList = FolderStore.folderList;
|
||||
this.currentMessage = MessageStore.currentMessage;
|
||||
this.isMessageSelected = MessageStore.isMessageSelected;
|
||||
this.messageListSearch = MessageStore.messageListSearch;
|
||||
this.messageListError = MessageStore.messageListError;
|
||||
this.folderMenuForMove = FolderStore.folderMenuForMove;
|
||||
|
||||
this.useCheckboxesInList = SettingsStore.useCheckboxesInList;
|
||||
|
||||
this.mainMessageListSearch = Data.mainMessageListSearch;
|
||||
this.messageListEndFolder = Data.messageListEndFolder;
|
||||
this.mainMessageListSearch = MessageStore.mainMessageListSearch;
|
||||
this.messageListEndFolder = MessageStore.messageListEndFolder;
|
||||
|
||||
this.messageListChecked = Data.messageListChecked;
|
||||
this.messageListCheckedOrSelected = Data.messageListCheckedOrSelected;
|
||||
this.messageListCheckedOrSelectedUidsWithSubMails = Data.messageListCheckedOrSelectedUidsWithSubMails;
|
||||
this.messageListCompleteLoadingThrottle = Data.messageListCompleteLoadingThrottle;
|
||||
this.messageListChecked = MessageStore.messageListChecked;
|
||||
this.messageListCheckedOrSelected = MessageStore.messageListCheckedOrSelected;
|
||||
this.messageListCheckedOrSelectedUidsWithSubMails = MessageStore.messageListCheckedOrSelectedUidsWithSubMails;
|
||||
this.messageListCompleteLoadingThrottle = MessageStore.messageListCompleteLoadingThrottle;
|
||||
|
||||
Translator.initOnStartOrLangChange(function () {
|
||||
this.emptySubjectValue = Translator.i18n('MESSAGE_LIST/EMPTY_SUBJECT_TEXT');
|
||||
|
|
@ -91,20 +92,21 @@
|
|||
});
|
||||
|
||||
this.messageListSearchDesc = ko.computed(function () {
|
||||
var sValue = Data.messageListEndSearch();
|
||||
var sValue = MessageStore.messageListEndSearch();
|
||||
return '' === sValue ? '' : Translator.i18n('MESSAGE_LIST/SEARCH_RESULT_FOR', {'SEARCH': sValue});
|
||||
});
|
||||
|
||||
this.messageListPagenator = ko.computed(Utils.computedPagenatorHelper(Data.messageListPage, Data.messageListPageCount));
|
||||
this.messageListPagenator = ko.computed(Utils.computedPagenatorHelper(
|
||||
MessageStore.messageListPage, MessageStore.messageListPageCount));
|
||||
|
||||
this.checkAll = ko.computed({
|
||||
'read': function () {
|
||||
return 0 < Data.messageListChecked().length;
|
||||
return 0 < MessageStore.messageListChecked().length;
|
||||
},
|
||||
|
||||
'write': function (bValue) {
|
||||
bValue = !!bValue;
|
||||
_.each(Data.messageList(), function (oMessage) {
|
||||
_.each(MessageStore.messageList(), function (oMessage) {
|
||||
oMessage.checked(bValue);
|
||||
});
|
||||
}
|
||||
|
|
@ -123,8 +125,8 @@
|
|||
|
||||
this.isIncompleteChecked = ko.computed(function () {
|
||||
var
|
||||
iM = Data.messageList().length,
|
||||
iC = Data.messageListChecked().length
|
||||
iM = MessageStore.messageList().length,
|
||||
iC = MessageStore.messageListChecked().length
|
||||
;
|
||||
return 0 < iM && 0 < iC && iM > iC;
|
||||
}, this);
|
||||
|
|
@ -173,48 +175,48 @@
|
|||
this.canBeMoved = this.hasCheckedOrSelectedLines;
|
||||
|
||||
this.clearCommand = Utils.createCommand(this, function () {
|
||||
kn.showScreenPopup(require('View/Popup/FolderClear'), [Data.currentFolder()]);
|
||||
kn.showScreenPopup(require('View/Popup/FolderClear'), [FolderStore.currentFolder()]);
|
||||
});
|
||||
|
||||
this.multyForwardCommand = Utils.createCommand(this, function () {
|
||||
kn.showScreenPopup(require('View/Popup/Compose'), [
|
||||
Enums.ComposeType.ForwardAsAttachment, Data.messageListCheckedOrSelected()]);
|
||||
Enums.ComposeType.ForwardAsAttachment, MessageStore.messageListCheckedOrSelected()]);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.deleteWithoutMoveCommand = Utils.createCommand(this, function () {
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.Trash,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), false);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), false);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.deleteCommand = Utils.createCommand(this, function () {
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.Trash,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.archiveCommand = Utils.createCommand(this, function () {
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.Archive,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.spamCommand = Utils.createCommand(this, function () {
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.Spam,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.notSpamCommand = Utils.createCommand(this, function () {
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.NotSpam,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), true);
|
||||
}, this.canBeMoved);
|
||||
|
||||
this.moveCommand = Utils.createCommand(this, Utils.emptyFunction, this.canBeMoved);
|
||||
|
||||
this.reloadCommand = Utils.createCommand(this, function () {
|
||||
if (!Data.messageListCompleteLoadingThrottle())
|
||||
if (!MessageStore.messageListCompleteLoadingThrottle())
|
||||
{
|
||||
require('App/User').reloadMessageList(false, true);
|
||||
}
|
||||
|
|
@ -229,18 +231,19 @@
|
|||
this.selector.on('onItemSelect', _.bind(function (oMessage) {
|
||||
if (oMessage)
|
||||
{
|
||||
Data.message(Data.staticMessageList.populateByMessageListItem(oMessage));
|
||||
this.populateMessageBody(Data.message());
|
||||
MessageStore.message(MessageStore.staticMessage.populateByMessageListItem(oMessage));
|
||||
|
||||
this.populateMessageBody(MessageStore.message());
|
||||
|
||||
if (Enums.Layout.NoPreview === SettingsStore.layout())
|
||||
{
|
||||
kn.setHash(Links.messagePreview(), true);
|
||||
Data.message.focused(true);
|
||||
MessageStore.message.focused(true);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
}
|
||||
}, this));
|
||||
|
||||
|
|
@ -248,23 +251,14 @@
|
|||
return oMessage ? oMessage.generateUid() : '';
|
||||
});
|
||||
|
||||
Data.messageListEndHash.subscribe(function () {
|
||||
MessageStore.messageListEndHash.subscribe(function () {
|
||||
this.selector.scrollToTop();
|
||||
}, this);
|
||||
|
||||
Data.messageListEndFolder.subscribe(function (sFolder) {
|
||||
var oMessage = Data.message();
|
||||
if (oMessage && sFolder && sFolder !== oMessage.folderFullNameRaw)
|
||||
{
|
||||
Data.message(null);
|
||||
}
|
||||
}, this);
|
||||
|
||||
SettingsStore.layout.subscribe(function (mValue) {
|
||||
this.selector.autoSelect(Enums.Layout.NoPreview !== mValue);
|
||||
}, this);
|
||||
|
||||
|
||||
SettingsStore.layout.valueHasMutated();
|
||||
|
||||
Events
|
||||
|
|
@ -318,8 +312,8 @@
|
|||
if (this.canBeMoved())
|
||||
{
|
||||
require('App/User').moveMessagesToFolder(
|
||||
Data.currentFolderFullNameRaw(),
|
||||
Data.messageListCheckedOrSelectedUidsWithSubMails(), sToFolderFullNameRaw, bCopy);
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
MessageStore.messageListCheckedOrSelectedUidsWithSubMails(), sToFolderFullNameRaw, bCopy);
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -334,15 +328,15 @@
|
|||
|
||||
var
|
||||
oEl = Utils.draggablePlace(),
|
||||
aUids = Data.messageListCheckedOrSelectedUidsWithSubMails()
|
||||
aUids = MessageStore.messageListCheckedOrSelectedUidsWithSubMails()
|
||||
;
|
||||
|
||||
oEl.data('rl-folder', Data.currentFolderFullNameRaw());
|
||||
oEl.data('rl-folder', FolderStore.currentFolderFullNameRaw());
|
||||
oEl.data('rl-uids', aUids);
|
||||
oEl.find('.text').text('' + aUids.length);
|
||||
|
||||
_.defer(function () {
|
||||
var aUids = Data.messageListCheckedOrSelectedUidsWithSubMails();
|
||||
var aUids = MessageStore.messageListCheckedOrSelectedUidsWithSubMails();
|
||||
|
||||
oEl.data('rl-uids', aUids);
|
||||
oEl.find('.text').text('' + aUids.length);
|
||||
|
|
@ -358,22 +352,22 @@
|
|||
*/
|
||||
MessageListMailBoxUserView.prototype.onMessageResponse = function (sResult, oData, bCached)
|
||||
{
|
||||
Data.hideMessageBodies();
|
||||
Data.messageLoading(false);
|
||||
MessageStore.hideMessageBodies();
|
||||
MessageStore.messageLoading(false);
|
||||
|
||||
if (Enums.StorageResultType.Success === sResult && oData && oData.Result)
|
||||
{
|
||||
Data.setMessage(oData, bCached);
|
||||
MessageStore.setMessage(oData, bCached);
|
||||
}
|
||||
else if (Enums.StorageResultType.Unload === sResult)
|
||||
{
|
||||
Data.message(null);
|
||||
Data.messageError('');
|
||||
MessageStore.message(null);
|
||||
MessageStore.messageError('');
|
||||
}
|
||||
else if (Enums.StorageResultType.Abort !== sResult)
|
||||
{
|
||||
Data.message(null);
|
||||
Data.messageError((oData && oData.ErrorCode ?
|
||||
MessageStore.message(null);
|
||||
MessageStore.messageError((oData && oData.ErrorCode ?
|
||||
Translator.getNotification(oData.ErrorCode) :
|
||||
Translator.getNotification(Enums.Notification.UnknownError)));
|
||||
}
|
||||
|
|
@ -385,7 +379,7 @@
|
|||
{
|
||||
if (Remote.message(this.onMessageResponse, oMessage.folderFullNameRaw, oMessage.uid))
|
||||
{
|
||||
Data.messageLoading(true);
|
||||
MessageStore.messageLoading(true);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -409,7 +403,7 @@
|
|||
|
||||
if (Utils.isUnd(aMessages))
|
||||
{
|
||||
aMessages = Data.messageListChecked();
|
||||
aMessages = MessageStore.messageListChecked();
|
||||
}
|
||||
|
||||
aUids = _.map(aMessages, function (oMessage) {
|
||||
|
|
@ -484,7 +478,7 @@
|
|||
{
|
||||
var
|
||||
oFolder = null,
|
||||
aMessages = Data.messageList()
|
||||
aMessages = MessageStore.messageList()
|
||||
;
|
||||
|
||||
if ('' !== sFolderFullNameRaw)
|
||||
|
|
@ -530,27 +524,31 @@
|
|||
|
||||
MessageListMailBoxUserView.prototype.listSetSeen = function ()
|
||||
{
|
||||
this.setAction(Data.currentFolderFullNameRaw(), Enums.MessageSetAction.SetSeen, Data.messageListCheckedOrSelected());
|
||||
this.setAction(FolderStore.currentFolderFullNameRaw(), Enums.MessageSetAction.SetSeen,
|
||||
MessageStore.messageListCheckedOrSelected());
|
||||
};
|
||||
|
||||
MessageListMailBoxUserView.prototype.listSetAllSeen = function ()
|
||||
{
|
||||
this.setActionForAll(Data.currentFolderFullNameRaw(), Enums.MessageSetAction.SetSeen);
|
||||
this.setActionForAll(FolderStore.currentFolderFullNameRaw(), Enums.MessageSetAction.SetSeen);
|
||||
};
|
||||
|
||||
MessageListMailBoxUserView.prototype.listUnsetSeen = function ()
|
||||
{
|
||||
this.setAction(Data.currentFolderFullNameRaw(), Enums.MessageSetAction.UnsetSeen, Data.messageListCheckedOrSelected());
|
||||
this.setAction(FolderStore.currentFolderFullNameRaw(), Enums.MessageSetAction.UnsetSeen,
|
||||
MessageStore.messageListCheckedOrSelected());
|
||||
};
|
||||
|
||||
MessageListMailBoxUserView.prototype.listSetFlags = function ()
|
||||
{
|
||||
this.setAction(Data.currentFolderFullNameRaw(), Enums.MessageSetAction.SetFlag, Data.messageListCheckedOrSelected());
|
||||
this.setAction(FolderStore.currentFolderFullNameRaw(), Enums.MessageSetAction.SetFlag,
|
||||
MessageStore.messageListCheckedOrSelected());
|
||||
};
|
||||
|
||||
MessageListMailBoxUserView.prototype.listUnsetFlags = function ()
|
||||
{
|
||||
this.setAction(Data.currentFolderFullNameRaw(), Enums.MessageSetAction.UnsetFlag, Data.messageListCheckedOrSelected());
|
||||
this.setAction(FolderStore.currentFolderFullNameRaw(), Enums.MessageSetAction.UnsetFlag,
|
||||
MessageStore.messageListCheckedOrSelected());
|
||||
};
|
||||
|
||||
MessageListMailBoxUserView.prototype.flagMessages = function (oCurrentMessage)
|
||||
|
|
@ -649,9 +647,9 @@
|
|||
|
||||
if (oMessage && !oMessage.lastInCollapsedThreadLoading())
|
||||
{
|
||||
Data.messageListThreadFolder(oMessage.folderFullNameRaw);
|
||||
MessageStore.messageListThreadFolder(oMessage.folderFullNameRaw);
|
||||
|
||||
aList = Data.messageListThreadUids();
|
||||
aList = MessageStore.messageListThreadUids();
|
||||
|
||||
if (oMessage.lastInCollapsedThread())
|
||||
{
|
||||
|
|
@ -662,7 +660,7 @@
|
|||
aList = _.without(aList, 0 < oMessage.parentUid() ? oMessage.parentUid() : oMessage.uid);
|
||||
}
|
||||
|
||||
Data.messageListThreadUids(_.uniq(aList));
|
||||
MessageStore.messageListThreadUids(_.uniq(aList));
|
||||
|
||||
oMessage.lastInCollapsedThreadLoading(true);
|
||||
oMessage.lastInCollapsedThread(!oMessage.lastInCollapsedThread());
|
||||
|
|
@ -687,9 +685,9 @@
|
|||
if (oPage)
|
||||
{
|
||||
kn.setHash(Links.mailBox(
|
||||
Data.currentFolderFullNameHash(),
|
||||
FolderStore.currentFolderFullNameHash(),
|
||||
oPage.value,
|
||||
Data.messageListSearch()
|
||||
MessageStore.messageListSearch()
|
||||
));
|
||||
}
|
||||
})
|
||||
|
|
@ -733,7 +731,7 @@
|
|||
key('delete, shift+delete, shift+3', Enums.KeyState.MessageList, function (event, handler) {
|
||||
if (event)
|
||||
{
|
||||
if (0 < Data.messageListCheckedOrSelected().length)
|
||||
if (0 < MessageStore.messageListCheckedOrSelected().length)
|
||||
{
|
||||
if (handler && 'shift+delete' === handler.shortcut)
|
||||
{
|
||||
|
|
@ -815,7 +813,7 @@
|
|||
key('tab, shift+tab, left, right', Enums.KeyState.MessageList, function (event, handler) {
|
||||
if (event && handler && ('shift+tab' === handler.shortcut || 'left' === handler.shortcut))
|
||||
{
|
||||
self.folderList.focused(true);
|
||||
FolderStore.folderList.focused(true);
|
||||
}
|
||||
else if (self.message())
|
||||
{
|
||||
|
|
@ -904,7 +902,7 @@
|
|||
'disableFolderDragAndDrop': true,
|
||||
'hidden': {
|
||||
'Folder': function () {
|
||||
return Data.currentFolderFullNameRaw();
|
||||
return FolderStore.currentFolderFullNameRaw();
|
||||
}
|
||||
},
|
||||
'dragAndDropElement': this.dragOverArea(),
|
||||
|
|
@ -933,13 +931,15 @@
|
|||
this.dragOver(false);
|
||||
}, this))
|
||||
.on('onSelect', _.bind(function (sUid, oData) {
|
||||
|
||||
if (sUid && oData && 'message/rfc822' === oData['Type'])
|
||||
{
|
||||
Data.messageListLoading(true);
|
||||
MessageStore.messageListLoading(true);
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
|
||||
}, this))
|
||||
.on('onComplete', _.bind(function () {
|
||||
require('App/User').reloadMessageList(true, true);
|
||||
|
|
|
|||
|
|
@ -19,14 +19,15 @@
|
|||
Events = require('Common/Events'),
|
||||
Translator = require('Common/Translator'),
|
||||
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
SettingsStore = require('Stores/User/Settings'),
|
||||
AccountStore = require('Stores/User/Account'),
|
||||
FolderStore = require('Stores/User/Folder'),
|
||||
MessageStore = require('Stores/User/Message'),
|
||||
|
||||
Local = require('Storage/Client'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Data = require('Storage/User/Data'),
|
||||
Remote = require('Storage/User/Remote'),
|
||||
Remote = require('Remote/User/Ajax'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
@ -56,23 +57,23 @@
|
|||
|
||||
this.pswp = null;
|
||||
|
||||
this.message = Data.message;
|
||||
this.currentMessage = Data.currentMessage;
|
||||
this.messageListChecked = Data.messageListChecked;
|
||||
this.hasCheckedMessages = Data.hasCheckedMessages;
|
||||
this.messageListCheckedOrSelectedUidsWithSubMails = Data.messageListCheckedOrSelectedUidsWithSubMails;
|
||||
this.messageLoading = Data.messageLoading;
|
||||
this.messageLoadingThrottle = Data.messageLoadingThrottle;
|
||||
this.messagesBodiesDom = Data.messagesBodiesDom;
|
||||
this.message = MessageStore.message;
|
||||
this.currentMessage = MessageStore.currentMessage;
|
||||
this.messageListChecked = MessageStore.messageListChecked;
|
||||
this.hasCheckedMessages = MessageStore.hasCheckedMessages;
|
||||
this.messageListCheckedOrSelectedUidsWithSubMails = MessageStore.messageListCheckedOrSelectedUidsWithSubMails;
|
||||
this.messageLoading = MessageStore.messageLoading;
|
||||
this.messageLoadingThrottle = MessageStore.messageLoadingThrottle;
|
||||
this.messagesBodiesDom = MessageStore.messagesBodiesDom;
|
||||
this.useThreads = SettingsStore.useThreads;
|
||||
this.replySameFolder = SettingsStore.replySameFolder;
|
||||
this.layout = SettingsStore.layout;
|
||||
this.usePreviewPane = SettingsStore.usePreviewPane;
|
||||
this.isMessageSelected = Data.isMessageSelected;
|
||||
this.messageActiveDom = Data.messageActiveDom;
|
||||
this.messageError = Data.messageError;
|
||||
this.isMessageSelected = MessageStore.isMessageSelected;
|
||||
this.messageActiveDom = MessageStore.messageActiveDom;
|
||||
this.messageError = MessageStore.messageError;
|
||||
|
||||
this.fullScreenMode = Data.messageFullScreenMode;
|
||||
this.fullScreenMode = MessageStore.messageFullScreenMode;
|
||||
|
||||
this.lastReplyAction_ = ko.observable('');
|
||||
this.lastReplyAction = ko.computed({
|
||||
|
|
@ -113,7 +114,7 @@
|
|||
|
||||
// commands
|
||||
this.closeMessage = Utils.createCommand(this, function () {
|
||||
Data.message(null);
|
||||
MessageStore.message(null);
|
||||
});
|
||||
|
||||
this.replyCommand = createCommandHelper(Enums.ComposeType.Reply);
|
||||
|
|
@ -141,7 +142,7 @@
|
|||
if (this.message())
|
||||
{
|
||||
require('App/User').deleteMessagesFromFolder(Enums.FolderType.Trash,
|
||||
Data.currentFolderFullNameRaw(),
|
||||
FolderStore.currentFolderFullNameRaw(),
|
||||
[this.message().uid], false);
|
||||
}
|
||||
}, this.messageVisibility);
|
||||
|
|
@ -395,7 +396,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.replyOrforward = function (sType)
|
||||
{
|
||||
kn.showScreenPopup(require('View/Popup/Compose'), [sType, Data.message()]);
|
||||
kn.showScreenPopup(require('View/Popup/Compose'), [sType, MessageStore.message()]);
|
||||
};
|
||||
|
||||
MessageViewMailBoxUserView.prototype.onBuild = function (oDom)
|
||||
|
|
@ -619,7 +620,7 @@
|
|||
|
||||
// reply
|
||||
key('r', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function () {
|
||||
if (Data.message())
|
||||
if (MessageStore.message())
|
||||
{
|
||||
self.replyCommand();
|
||||
return false;
|
||||
|
|
@ -628,7 +629,7 @@
|
|||
|
||||
// replaAll
|
||||
key('a', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function () {
|
||||
if (Data.message())
|
||||
if (MessageStore.message())
|
||||
{
|
||||
self.replyAllCommand();
|
||||
return false;
|
||||
|
|
@ -637,7 +638,7 @@
|
|||
|
||||
// forward
|
||||
key('f', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function () {
|
||||
if (Data.message())
|
||||
if (MessageStore.message())
|
||||
{
|
||||
self.forwardCommand();
|
||||
return false;
|
||||
|
|
@ -646,7 +647,7 @@
|
|||
|
||||
// message information
|
||||
// key('i', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function () {
|
||||
// if (oData.message())
|
||||
// if (MessageStore.message())
|
||||
// {
|
||||
// self.showFullInfo(!self.showFullInfo());
|
||||
// return false;
|
||||
|
|
@ -655,9 +656,9 @@
|
|||
|
||||
// toggle message blockquotes
|
||||
key('b', [Enums.KeyState.MessageList, Enums.KeyState.MessageView], function () {
|
||||
if (Data.message() && Data.message().body)
|
||||
if (MessageStore.message() && MessageStore.message().body)
|
||||
{
|
||||
Data.message().body.find('.rlBlockquoteSwitcher').click();
|
||||
MessageStore.message().body.find('.rlBlockquoteSwitcher').click();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
|
@ -731,7 +732,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isDraftFolder = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.draftFolder() === Data.message().folderFullNameRaw;
|
||||
return MessageStore.message() && FolderStore.draftFolder() === MessageStore.message().folderFullNameRaw;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -739,7 +740,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isSentFolder = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.sentFolder() === Data.message().folderFullNameRaw;
|
||||
return MessageStore.message() && FolderStore.sentFolder() === MessageStore.message().folderFullNameRaw;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -747,7 +748,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isSpamFolder = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.spamFolder() === Data.message().folderFullNameRaw;
|
||||
return MessageStore.message() && FolderStore.spamFolder() === MessageStore.message().folderFullNameRaw;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -755,7 +756,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isSpamDisabled = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.spamFolder() === Consts.Values.UnuseOptionValue;
|
||||
return MessageStore.message() && FolderStore.spamFolder() === Consts.Values.UnuseOptionValue;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -763,7 +764,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isArchiveFolder = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.archiveFolder() === Data.message().folderFullNameRaw;
|
||||
return MessageStore.message() && FolderStore.archiveFolder() === MessageStore.message().folderFullNameRaw;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -771,7 +772,7 @@
|
|||
*/
|
||||
MessageViewMailBoxUserView.prototype.isArchiveDisabled = function ()
|
||||
{
|
||||
return Data.message() && FolderStore.archiveFolder() === Consts.Values.UnuseOptionValue;
|
||||
return MessageStore.message() && FolderStore.archiveFolder() === Consts.Values.UnuseOptionValue;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -789,9 +790,9 @@
|
|||
|
||||
MessageViewMailBoxUserView.prototype.editMessage = function ()
|
||||
{
|
||||
if (Data.message())
|
||||
if (MessageStore.message())
|
||||
{
|
||||
kn.showScreenPopup(require('View/Popup/Compose'), [Enums.ComposeType.Draft, Data.message()]);
|
||||
kn.showScreenPopup(require('View/Popup/Compose'), [Enums.ComposeType.Draft, MessageStore.message()]);
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
Globals = require('Common/Globals'),
|
||||
Links = require('Common/Links'),
|
||||
|
||||
Cache = require('Storage/User/Cache'),
|
||||
Cache = require('Common/Cache'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
|
|
|
|||
|
|
@ -6,11 +6,6 @@
|
|||
var
|
||||
_ = require('_'),
|
||||
|
||||
Links = require('Common/Links'),
|
||||
|
||||
Data = require('Storage/User/Data'),
|
||||
Cache = require('Storage/User/Cache'),
|
||||
|
||||
kn = require('Knoin/Knoin'),
|
||||
AbstractView = require('Knoin/AbstractView')
|
||||
;
|
||||
|
|
@ -31,12 +26,13 @@
|
|||
|
||||
PaneSettingsUserView.prototype.onShow = function ()
|
||||
{
|
||||
Data.message(null);
|
||||
require('Stores/User/Message').message(null);
|
||||
};
|
||||
|
||||
PaneSettingsUserView.prototype.backToMailBoxClick = function ()
|
||||
{
|
||||
kn.setHash(Links.inbox(Cache.getFolderInboxName()));
|
||||
kn.setHash(require('Common/Links').inbox(
|
||||
require('Common/Cache').getFolderInboxName()));
|
||||
};
|
||||
|
||||
module.exports = PaneSettingsUserView;
|
||||
|
|
|
|||
|
|
@ -160,7 +160,7 @@ cfg.paths.js = {
|
|||
'vendors/routes/signals.min.js',
|
||||
'vendors/routes/hasher.min.js',
|
||||
'vendors/routes/crossroads.min.js',
|
||||
'vendors/knockout/knockout-3.2.0.js',
|
||||
'vendors/knockout/knockout-3.3.0.js',
|
||||
// 'vendors/knockout-punches/knockout.punches.min.js',
|
||||
'vendors/knockout-projections/knockout-projections-1.0.0.min.js',
|
||||
'vendors/knockout-sortable/knockout-sortable.min.js',
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
"name": "RainLoop",
|
||||
"title": "RainLoop Webmail",
|
||||
"version": "1.8.1",
|
||||
"release": "266",
|
||||
"release": "267",
|
||||
"description": "Simple, modern & fast web-based email client",
|
||||
"homepage": "http://rainloop.net",
|
||||
"main": "gulpfile.js",
|
||||
|
|
|
|||
|
|
@ -306,13 +306,14 @@ class SmtpClient extends \MailSo\Net\NetClient
|
|||
/**
|
||||
* @param string $sFrom
|
||||
* @param string $sSizeIfSupported = ''
|
||||
* @param bool $bDsn = false
|
||||
*
|
||||
* @return \MailSo\Smtp\SmtpClient
|
||||
*
|
||||
* @throws \MailSo\Net\Exceptions\Exception
|
||||
* @throws \MailSo\Smtp\Exceptions\Exception
|
||||
*/
|
||||
public function MailFrom($sFrom, $sSizeIfSupported = '')
|
||||
public function MailFrom($sFrom, $sSizeIfSupported = '', $bDsn = false)
|
||||
{
|
||||
$sFrom = \MailSo\Base\Utils::IdnToAscii($sFrom, true);
|
||||
$sCmd = 'FROM:<'.$sFrom.'>';
|
||||
|
|
@ -323,6 +324,11 @@ class SmtpClient extends \MailSo\Net\NetClient
|
|||
$sCmd .= ' SIZE='.$sSizeIfSupported;
|
||||
}
|
||||
|
||||
if ($bDsn && $this->IsSupported('DSN'))
|
||||
{
|
||||
$sCmd .= ' RET=HDRS';
|
||||
}
|
||||
|
||||
$this->sendRequestWithCheck('MAIL', 250, $sCmd);
|
||||
|
||||
$this->bMail = true;
|
||||
|
|
@ -334,13 +340,14 @@ class SmtpClient extends \MailSo\Net\NetClient
|
|||
|
||||
/**
|
||||
* @param string $sTo
|
||||
* @param bool $bDsn = false
|
||||
*
|
||||
* @return \MailSo\Smtp\SmtpClient
|
||||
*
|
||||
* @throws \MailSo\Net\Exceptions\Exception
|
||||
* @throws \MailSo\Smtp\Exceptions\Exception
|
||||
*/
|
||||
public function Rcpt($sTo)
|
||||
public function Rcpt($sTo, $bDsn = false)
|
||||
{
|
||||
if (!$this->bMail)
|
||||
{
|
||||
|
|
@ -350,7 +357,14 @@ class SmtpClient extends \MailSo\Net\NetClient
|
|||
}
|
||||
|
||||
$sTo = \MailSo\Base\Utils::IdnToAscii($sTo, true);
|
||||
$this->sendRequestWithCheck('RCPT', array(250, 251), 'TO:<'.$sTo.'>');
|
||||
$sCmd = 'TO:<'.$sTo.'>';
|
||||
|
||||
if ($bDsn && $this->IsSupported('DSN'))
|
||||
{
|
||||
$sCmd .= ' NOTIFY=SUCCESS,FAILURE';
|
||||
}
|
||||
|
||||
$this->sendRequestWithCheck('RCPT', array(250, 251), $sCmd);
|
||||
|
||||
$this->bRcpt = true;
|
||||
|
||||
|
|
|
|||
|
|
@ -5752,12 +5752,14 @@ class Actions
|
|||
* @param \RainLoop\Model\Account $oAccount
|
||||
* @param \MailSo\Mime\Message $oMessage
|
||||
* @param resource $rMessageStream
|
||||
* @param bool $bDsn = false
|
||||
* @param bool $bAddHiddenRcpt = true
|
||||
*
|
||||
* @throws \RainLoop\Exceptions\ClientException
|
||||
* @throws \MailSo\Net\Exceptions\ConnectionException
|
||||
*/
|
||||
private function smtpSendMessage($oAccount, $oMessage, &$rMessageStream, &$iMessageStreamSize, $bAddHiddenRcpt = true)
|
||||
private function smtpSendMessage($oAccount, $oMessage,
|
||||
&$rMessageStream, &$iMessageStreamSize, $bDsn = false, $bAddHiddenRcpt = true)
|
||||
{
|
||||
$oRcpt = $oMessage->GetRcpt();
|
||||
if ($oRcpt && 0 < $oRcpt->Count())
|
||||
|
|
@ -5773,9 +5775,9 @@ class Actions
|
|||
$sFrom = $oFrom instanceof \MailSo\Mime\Email ? $oFrom->GetEmail() : '';
|
||||
$sFrom = empty($sFrom) ? $oAccount->Email() : $sFrom;
|
||||
|
||||
$aHiddenRcpt = array();
|
||||
$this->Plugins()->RunHook('filter.smtp-from', array($oAccount, $oMessage, &$sFrom));
|
||||
|
||||
$aHiddenRcpt = array();
|
||||
if ($bAddHiddenRcpt)
|
||||
{
|
||||
$this->Plugins()->RunHook('filter.smtp-hidden-rcpt', array($oAccount, $oMessage, &$aHiddenRcpt));
|
||||
|
|
@ -5806,9 +5808,9 @@ class Actions
|
|||
list($sMailHeaders, $sMailBody) = \explode("\r\n\r\n", $sRawBody, 2);
|
||||
unset($sRawBody);
|
||||
|
||||
$this->Logger()->WriteDump(array(
|
||||
$sMailTo, $sMailSubject, $sMailBody, $sMailHeaders
|
||||
));
|
||||
// $this->Logger()->WriteDump(array(
|
||||
// $sMailTo, $sMailSubject, $sMailBody, $sMailHeaders
|
||||
// ));
|
||||
|
||||
if (!\mail($sMailTo, $sMailSubject, $sMailBody, $sMailHeaders/*, '-f'.$oFrom->GetEmail()*/))
|
||||
{
|
||||
|
|
@ -5826,13 +5828,13 @@ class Actions
|
|||
{
|
||||
if (!empty($sFrom))
|
||||
{
|
||||
$oSmtpClient->MailFrom($sFrom);
|
||||
$oSmtpClient->MailFrom($sFrom, '', $bDsn);
|
||||
}
|
||||
|
||||
$aRcpt =& $oRcpt->GetAsArray();
|
||||
foreach ($aRcpt as /* @var $oEmail \MailSo\Mime\Email */ $oEmail)
|
||||
{
|
||||
$oSmtpClient->Rcpt($oEmail->GetEmail());
|
||||
$oSmtpClient->Rcpt($oEmail->GetEmail(), $bDsn);
|
||||
}
|
||||
|
||||
if ($bAddHiddenRcpt && \is_array($aHiddenRcpt) && 0 < \count($aHiddenRcpt))
|
||||
|
|
@ -5902,6 +5904,7 @@ class Actions
|
|||
$sDraftUid = $this->GetActionParam('MessageUid', '');
|
||||
$sSentFolder = $this->GetActionParam('SentFolder', '');
|
||||
$aDraftInfo = $this->GetActionParam('DraftInfo', null);
|
||||
$bDsn = '1' === (string) $this->GetActionParam('Dsn', '0');
|
||||
|
||||
$oMessage = $this->buildMessage($oAccount, false);
|
||||
|
||||
|
|
@ -5922,7 +5925,7 @@ class Actions
|
|||
|
||||
if (false !== $iMessageStreamSize)
|
||||
{
|
||||
$this->smtpSendMessage($oAccount, $oMessage, $rMessageStream, $iMessageStreamSize);
|
||||
$this->smtpSendMessage($oAccount, $oMessage, $rMessageStream, $iMessageStreamSize, $bDsn, true);
|
||||
|
||||
$this->deleteMessageAttachmnets($oAccount);
|
||||
|
||||
|
|
@ -6096,7 +6099,7 @@ class Actions
|
|||
|
||||
if (false !== $iMessageStreamSize)
|
||||
{
|
||||
$this->smtpSendMessage($oAccount, $oMessage, $rMessageStream, $iMessageStreamSize);
|
||||
$this->smtpSendMessage($oAccount, $oMessage, $rMessageStream, $iMessageStreamSize, false, false);
|
||||
|
||||
if (\is_resource($rMessageStream))
|
||||
{
|
||||
|
|
|
|||
|
|
@ -182,7 +182,7 @@
|
|||
<i class="icon-pencil icon-white"></i>
|
||||
</a>
|
||||
</div>
|
||||
<!-- <div class="btn-group pull-right" data-bind="visible: true" style="margin-right: 5px">
|
||||
<div class="btn-group pull-right" data-bind="visible: false" style="margin-right: 5px">
|
||||
<a class="btn btn-thin" data-tooltip-placement="bottom">
|
||||
<i class="icon-left-middle"></i>
|
||||
</a>
|
||||
|
|
@ -192,7 +192,7 @@
|
|||
<a class="btn btn-thin" data-tooltip-placement="bottom">
|
||||
<i class="icon-right-middle"></i>
|
||||
</a>
|
||||
</div>-->
|
||||
</div>
|
||||
</nobr>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -60,6 +60,13 @@
|
|||
<span class="i18n" data-i18n-text="COMPOSE/BUTTON_REQUEST_READ_RECEIPT"></span>
|
||||
</a>
|
||||
</li>
|
||||
<li class="e-item" data-bind="click: function () { requestDsn(!requestDsn()); }">
|
||||
<a class="e-link">
|
||||
<i class="icon-checkbox-unchecked" data-bind="css: {'icon-checkbox-checked': requestDsn(), 'icon-checkbox-unchecked': !requestDsn() }"></i>
|
||||
|
||||
<span class="i18n" data-i18n-text="COMPOSE/BUTTON_REQUEST_DSN"></span>
|
||||
</a>
|
||||
</li>
|
||||
<li class="e-item" data-bind="click: function () { markAsImportant(!markAsImportant()); }">
|
||||
<a class="e-link">
|
||||
<i class="icon-checkbox-unchecked" data-bind="css: {'icon-checkbox-checked': markAsImportant(), 'icon-checkbox-unchecked': !markAsImportant() }"></i>
|
||||
|
|
@ -192,7 +199,7 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<div class="attachmentAreaParent b-content" style="height: 200px; min-height: 200px" data-bind="nano: true, visible: attachmentsPlace, initResizeTrigger: [resizer(), 200, 47]">
|
||||
<div class="attachmentAreaParent b-content" style="height: 200px; min-height: 200px" data-bind="nano: true, visible: attachmentsPlace, initResizeTrigger: [resizer(), 200, 57]">
|
||||
<div class="content g-scrollbox">
|
||||
<div class="content-wrapper">
|
||||
<ul class="attachmentList" data-bind="template: { name: 'ComposeAttachment', foreach: attachments }"></ul>
|
||||
|
|
@ -204,7 +211,7 @@
|
|||
</div>
|
||||
|
||||
<div class="textAreaParent" style="height: 200px; min-height: 200px"
|
||||
data-bind="visible: !attachmentsPlace(), initDom: composeEditorArea, initResizeTrigger: [resizer(), 200, 30]"></div>
|
||||
data-bind="visible: !attachmentsPlace(), initDom: composeEditorArea, initResizeTrigger: [resizer(), 200, 40]"></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="row" data-bind="visible: inited() && !serverError()">
|
||||
<div class="span4">
|
||||
<div class="span5">
|
||||
<a class="btn" data-bind="click: addFilter">
|
||||
<i class="icon-plus"></i>
|
||||
|
||||
|
|
@ -25,7 +25,7 @@
|
|||
<span class="i18n" data-i18n-text="SETTINGS_FILTERS/BUTTON_SAVE"></span>
|
||||
</a>
|
||||
</div>
|
||||
<div class="span4" style="margin-left: 0;">
|
||||
<div class="span3" style="margin-left: 0;">
|
||||
<span data-bind="text: saveErrorText"style="color:red"></span>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Все още не са качени всичк
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Поискайте разписка за прочитане на съобщението"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Да"
|
||||
|
|
|
|||
|
|
@ -232,6 +232,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Některé přílohy ještě nebyly nahrány"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Vyžádat si potvrzení o příjetí"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Označit jako důležité"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (jen Plain Text)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Ano"
|
||||
|
|
|
|||
|
|
@ -5,7 +5,7 @@ LABEL_LOGIN = "Login"
|
|||
LABEL_PASSWORD = "Passwort"
|
||||
LABEL_SIGN_ME = "Anmeldung merken"
|
||||
LABEL_VERIFICATION_CODE = "Verifizierungscode"
|
||||
LABEL_DONT_ASK_VERIFICATION_CODE = "Für 2 Wochen nicht nach dem Code fragen"
|
||||
LABEL_DONT_ASK_VERIFICATION_CODE = "Für zwei Wochen nicht nach dem Code fragen"
|
||||
BUTTON_SIGN_IN = "Anmelden"
|
||||
TITLE_SIGN_IN_GOOGLE = "Mit Google anmelden"
|
||||
TITLE_SIGN_IN_FACEBOOK = "Mit Facebook anmelden"
|
||||
|
|
@ -45,7 +45,7 @@ FULLSCREEN = "Vollbild umschalten"
|
|||
ZOOM = "Herein-/Herauszoomen"
|
||||
CLOSE = "Schließen (Esc)"
|
||||
LOADING = "Wird geladen ..."
|
||||
GALLERY_PREV = "Vorher (Linke Pfeil-Taste)"
|
||||
GALLERY_PREV = "Zurück (Linke Pfeil-Taste)"
|
||||
GALLERY_NEXT = "Weiter (Rechte Pfeil-Taste)"
|
||||
GALLERY_COUNTER = "%curr% von %total%"
|
||||
IMAGE_ERROR = "<a href=\"%url%\" target=\"_blank\">Die Grafikdatei</a> konnte nicht geladen werden."
|
||||
|
|
@ -62,7 +62,7 @@ TRASH_NAME = "Papierkorb"
|
|||
ARCHIVE_NAME = "Archiv"
|
||||
|
||||
[QUOTA]
|
||||
TITLE = "Speicherplatz-Verbrauch"
|
||||
TITLE = "Speicherplatz-Nutzung"
|
||||
|
||||
[MESSAGE_LIST]
|
||||
BUTTON_RELOAD = "Nachrichtenliste neu laden"
|
||||
|
|
@ -119,7 +119,7 @@ BUTTON_NOTIFY_READ_RECEIPT = "Der Absender hat darum gebeten, benachrichtigt zu
|
|||
BUTTON_IN_NEW_WINDOW = "In neuem Fenster anzeigen"
|
||||
MENU_HEADERS = "Kopfzeilen anzeigen"
|
||||
MENU_VIEW_ORIGINAL = "Original anzeigen"
|
||||
MENU_DOWNLOAD_ORIGINAL = "Als .eml - Datei herunterladen"
|
||||
MENU_DOWNLOAD_ORIGINAL = "Als .eml-Datei herunterladen"
|
||||
MENU_FILTER_SIMILAR = "Ähnliche Nachrichten"
|
||||
MENU_PRINT = "Drucken"
|
||||
EMPTY_SUBJECT_TEXT = "(Kein Betreff)"
|
||||
|
|
@ -131,20 +131,20 @@ LABEL_TO = "An"
|
|||
LABEL_TO_SHORT = "an"
|
||||
LABEL_CC = "CC"
|
||||
LABEL_BCC = "BCC"
|
||||
LABEL_REPLY_TO = "Reply-To"
|
||||
LABEL_REPLY_TO = "Antwort an"
|
||||
PRINT_LABEL_FROM = "Von"
|
||||
PRINT_LABEL_TO = "An"
|
||||
PRINT_LABEL_CC = "CC"
|
||||
PRINT_LABEL_BCC = "BCC"
|
||||
PRINT_LABEL_REPLY_TO = "Reply-To"
|
||||
PRINT_LABEL_REPLY_TO = "Antwort an"
|
||||
PRINT_LABEL_DATE = "Datum"
|
||||
PRINT_LABEL_SUBJECT = "Betreff"
|
||||
PRINT_LABEL_ATTACHMENTS = "Anhänge"
|
||||
MESSAGE_LOADING = "Nachricht wird geladen"
|
||||
MESSAGE_VIEW_DESC = "Wählen Sie eine Nachricht aus der Liste aus, um sie anzuzeigen."
|
||||
PGP_PASSWORD_INPUT_PLACEHOLDER = "Passwort"
|
||||
PGP_SIGNED_MESSAGE_DESC = "OpenPGP signierte Nachricht (Klicken, um zu überprüfen)"
|
||||
PGP_ENCRYPTED_MESSAGE_DESC = "OpenPGP verschlüsselte Nachricht (Klicken, um zu entschlüsseln)"
|
||||
PGP_SIGNED_MESSAGE_DESC = "OpenPGP-signierte Nachricht (klicken, um zu überprüfen)"
|
||||
PGP_ENCRYPTED_MESSAGE_DESC = "OpenPGP-verschlüsselte Nachricht (klicken, um zu entschlüsseln)"
|
||||
|
||||
[READ_RECEIPT]
|
||||
SUBJECT = "Empfangsbestätigung (angezeigt) - %SUBJECT%"
|
||||
|
|
@ -165,7 +165,7 @@ BUTTON_UPDATE_CONTACT = "Kontakt aktualisieren"
|
|||
BUTTON_IMPORT = "Import (csv, vcf, vCard)"
|
||||
BUTTON_EXPORT_VCARD = "Export (vcf, vCard)"
|
||||
BUTTON_EXPORT_CSV = "Export (csv)"
|
||||
ERROR_IMPORT_FILE = "Import-Fehler (ungültiges Dateiformat)"
|
||||
ERROR_IMPORT_FILE = "Importfehler (ungültiges Dateiformat)"
|
||||
LIST_LOADING = "Kontakte werden geladen"
|
||||
EMPTY_LIST = "Keine Kontakte"
|
||||
EMPTY_SEARCH = "Keine Kontakte gefunden"
|
||||
|
|
@ -212,7 +212,7 @@ BUTTON_DELETE = "Löschen"
|
|||
BUTTON_CANCEL = "Abbrechen"
|
||||
BUTTON_MINIMIZE = "Minimieren"
|
||||
SAVED_TIME = "Gespeichert um %TIME%"
|
||||
SAVED_ERROR_ON_SEND = "Die Nachricht wurde gesendet, konnte aber nicht im Ordner gespeichert werden."
|
||||
SAVED_ERROR_ON_SEND = "Die Nachricht wurde gesendet, konnte aber nicht im Gesendet-Ordner gespeichert werden."
|
||||
DISCARD_UNSAVED_DATA = "Nicht gespeicherte Daten löschen?"
|
||||
ATTACH_FILES = "Dateien anhängen"
|
||||
ATTACH_DROP_FILES_DESC = "Fügen Sie hier Dateien ein"
|
||||
|
|
@ -227,12 +227,13 @@ FORWARD_MESSAGE_TOP_CC = "CC"
|
|||
FORWARD_MESSAGE_TOP_SENT = "Gesendet"
|
||||
FORWARD_MESSAGE_TOP_SUBJECT = "Betreff"
|
||||
EMPTY_TO_ERROR_DESC = "Geben Sie bitte mindestens einen Empfänger an"
|
||||
NO_ATTACHMENTS_HERE_DESC = "No attachments here."
|
||||
NO_ATTACHMENTS_HERE_DESC = "Keine Anhänge vorhanden."
|
||||
ATTACHMENTS_ERROR_DESC = "Warnung! Nicht alle Anhänge wurden hochgeladen."
|
||||
ATTACHMENTS_UPLOAD_ERROR_DESC = "Es wurden noch nicht alle Anhänge hochgeladen."
|
||||
BUTTON_REQUEST_READ_RECEIPT = "Empfangsbestätigung anfordern"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Als Wichtig markieren"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Nur Text)"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (nur bei unformatiertem Text)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Ja"
|
||||
|
|
@ -257,15 +258,15 @@ BUTTON_UPDATE_IDENTITY = "Aktualisieren"
|
|||
LABEL_EMAIL = "E-Mail"
|
||||
LABEL_NAME = "Name"
|
||||
LABEL_REPLY_TO = "Antwort an"
|
||||
LABEL_SIGNATURE = "Signature"
|
||||
LABEL_CC = "Cc"
|
||||
LABEL_SIGNATURE = "Signatur"
|
||||
LABEL_CC = "CC"
|
||||
LABEL_BCC = "BCC"
|
||||
LABEL_SIGNATURE_INSERT_BEFORE = "Insert this signature before quoted text in replies"
|
||||
LABEL_SIGNATURE_INSERT_BEFORE = "Diese Signatur in Antworten vor dem zitierten Text einfügen"
|
||||
|
||||
[POPUPS_CREATE_FOLDER]
|
||||
TITLE_CREATE_FOLDER = "Ordner anlegen?"
|
||||
SELECT_NO_PARENT = ""
|
||||
LABEL_NAME = "Ordner-Name"
|
||||
LABEL_NAME = "Ordnername"
|
||||
LABEL_PARENT = "Übergeordneter Ordner"
|
||||
BUTTON_CREATE = "Anlegen"
|
||||
BUTTON_CANCEL = "Abbrechen"
|
||||
|
|
@ -283,16 +284,16 @@ DANGER_DESC_HTML_2 = "Einmal begonnen, kann dieser Vorgang nicht mehr abgebroche
|
|||
TITLE_CLEARING_PROCESS = "Ordner wird gelöscht ..."
|
||||
|
||||
[POPUPS_IMPORT_OPEN_PGP_KEY]
|
||||
TITLE_IMPORT_OPEN_PGP_KEY = "Import OpenPGP Schlüssel"
|
||||
BUTTON_IMPORT_OPEN_PGP_KEY = "Import"
|
||||
TITLE_IMPORT_OPEN_PGP_KEY = "OpenPGP-Schlüssel importieren"
|
||||
BUTTON_IMPORT_OPEN_PGP_KEY = "Importieren"
|
||||
|
||||
[POPUPS_VIEW_OPEN_PGP_KEY]
|
||||
TITLE_VIEW_OPEN_PGP_KEY = "OpenPGP Schlüssel anzeigen"
|
||||
TITLE_VIEW_OPEN_PGP_KEY = "OpenPGP-Schlüssel anzeigen"
|
||||
BUTTON_SELECT = "Auswählen"
|
||||
BUTTON_CLOSE = "Schließen"
|
||||
|
||||
[POPUPS_GENERATE_OPEN_PGP_KEYS]
|
||||
TITLE_GENERATE_OPEN_PGP_KEYS = "OpenPGP Schlüssel generieren"
|
||||
TITLE_GENERATE_OPEN_PGP_KEYS = "OpenPGP-Schlüssel generieren"
|
||||
LABEL_EMAIL = "E-Mail"
|
||||
LABEL_NAME = "Name"
|
||||
LABEL_PASSWORD = "Passwort"
|
||||
|
|
@ -309,7 +310,7 @@ BUTTON_ENCRYPT = "Verschlüsseln"
|
|||
BUTTON_SIGN_AND_ENCRYPT = "Unterschreiben und verschlüsseln"
|
||||
|
||||
[POPUPS_TWO_FACTOR_TEST]
|
||||
TITLE_TEST_CODE = "Zwei-Faktor-Autehntifizierung"
|
||||
TITLE_TEST_CODE = "Zwei-Faktor-Authentifizierung"
|
||||
LABEL_CODE = "Code"
|
||||
BUTTON_TEST = "Testen"
|
||||
|
||||
|
|
@ -330,7 +331,7 @@ SELECT_ACTION_DISCARD = "Verwerfen"
|
|||
SELECT_FIELD_FROM = "Von"
|
||||
SELECT_FIELD_RECIPIENTS = "Empfänger (An oder CC)"
|
||||
SELECT_FIELD_SUBJECT = "Betreff"
|
||||
SELECT_FIELD_HEADER = "Header"
|
||||
SELECT_FIELD_HEADER = "Nachrichtenkopf"
|
||||
SELECT_FIELD_SIZE = "Größe"
|
||||
SELECT_TYPE_CONTAINS = "Enthält"
|
||||
SELECT_TYPE_NOT_CONTAINS = "Enthält nicht"
|
||||
|
|
@ -350,10 +351,10 @@ EMAIL_LABEL = "E-Mail"
|
|||
VACATION_SUBJECT_LABEL = "Betreff (optional)"
|
||||
VACATION_MESSAGE_LABEL = "Nachricht"
|
||||
REJECT_MESSAGE_LABEL = "Ablehnnachricht"
|
||||
ALL_INCOMING_MESSAGES_DESC = "Alle ankommende E-Mails"
|
||||
ALL_INCOMING_MESSAGES_DESC = "Alle eingehenden Nachrichten"
|
||||
|
||||
[POPUPS_SYSTEM_FOLDERS]
|
||||
TITLE_SYSTEM_FOLDERS = "Wählen Sie den System-Ordner aus"
|
||||
TITLE_SYSTEM_FOLDERS = "Wählen Sie die Systemordner aus"
|
||||
SELECT_CHOOSE_ONE = "Wählen Sie einen aus"
|
||||
SELECT_UNUSE_NAME = "Nicht anwenden"
|
||||
LABEL_SENT = "Gesendet"
|
||||
|
|
@ -363,29 +364,29 @@ LABEL_TRASH = "Papierkorb"
|
|||
LABEL_ARCHIVE = "Archiv"
|
||||
BUTTON_CANCEL = "Abbrechen"
|
||||
BUTTON_CLOSE = "Schließen"
|
||||
NOTIFICATION_SENT = "Sie haben keinen \"Gesendet\" System-Ordner gewählt, in dem Nachrichten nach dem Versenden gespeichert werden.
|
||||
NOTIFICATION_SENT = "Sie haben keinen \"Gesendet\"-Systemordner gewählt, in dem Nachrichten nach dem Versenden gespeichert werden.
|
||||
Falls Sie versandte Nachrichten nicht speichern möchten, wählen Sie die Option \"Nicht anwenden\"."
|
||||
NOTIFICATION_DRAFTS = "Sie haben keinen \"Entwürfe\" System-Ordner, in dem Nachrichten beim Erstellen gespeichert werden, gewählt."
|
||||
NOTIFICATION_SPAM = "Sie haben keinen \"Spam\" System-Ordner gewählt, in dem die Spam-Nachrichten landen.
|
||||
Falls Sie diese Nachrichten endgültig löschen möchten, wählen Sie die Option \"Nicht anwenden\"."
|
||||
NOTIFICATION_TRASH = "Sie haben keinen \"Papierkorb\" System-Ordner gewählt, in dem die gelöschten Nachrichten abgelegt werden.
|
||||
NOTIFICATION_DRAFTS = "Sie haben keinen \"Entwürfe\"-Systemordner gewählt, in dem Nachrichten beim Erstellen gespeichert werden."
|
||||
NOTIFICATION_SPAM = "Sie haben keinen \"Spam\"-Systemordner gewählt, in dem die Spam-Nachrichten abgelegt werden.
|
||||
Falls Sie Spam-Nachrichten endgültig löschen möchten, wählen Sie die Option \"Nicht anwenden\"."
|
||||
NOTIFICATION_TRASH = "Sie haben keinen \"Papierkorb\"-Systemordner gewählt, in dem die gelöschten Nachrichten abgelegt werden.
|
||||
Falls Sie gelöschte Nachrichten endgültig löschen möchten, wählen Sie die Option \"Nicht anwenden\"."
|
||||
NOTIFICATION_ARCHIVE = "Sie haben keinen \"Archiv\" System-Ordner gewählt, in dem die archivierten Nachrichten landen."
|
||||
NOTIFICATION_ARCHIVE = "Sie haben keinen \"Archiv\"-Systemordner gewählt, in dem die archivierten Nachrichten abgelegt werden."
|
||||
|
||||
[TITLES]
|
||||
LOADING = "Wird geladen"
|
||||
LOGIN = "Login"
|
||||
LOGIN = "Anmeldung"
|
||||
MAILBOX = "Postfach"
|
||||
SETTINGS = "Einstellungen"
|
||||
COMPOSE = "Erstellen"
|
||||
|
||||
[UPLOAD]
|
||||
ERROR_FILE_IS_TOO_BIG = "Datei ist zu groß"
|
||||
ERROR_FILE_PARTIALLY_UPLOADED = "Die Datei wurde aus einem nicht bekannten Grund unvollständig hochgeladen."
|
||||
ERROR_FILE_PARTIALLY_UPLOADED = "Die Datei wurde aus einem unbekannten Grund unvollständig hochgeladen."
|
||||
ERROR_NO_FILE_UPLOADED = "Keine Datei hochgeladen"
|
||||
ERROR_MISSING_TEMP_FOLDER = "Die temporäre Datei fehlt"
|
||||
ERROR_ON_SAVING_FILE = "Ein unbekannter Fehler trat beim Speichern auf"
|
||||
ERROR_FILE_TYPE = "Ungültiger Datei-Typ"
|
||||
ERROR_ON_SAVING_FILE = "Ein unbekannter Fehler trat beim Hochladen auf"
|
||||
ERROR_FILE_TYPE = "Ungültiger Dateityp"
|
||||
ERROR_UNKNOWN = "Ein unbekannter Fehler trat beim Hochladen auf"
|
||||
|
||||
[EDITOR]
|
||||
|
|
@ -401,11 +402,11 @@ LABEL_FOLDERS_NAME = "Ordner"
|
|||
LABEL_ACCOUNTS_NAME = "Konten"
|
||||
LABEL_IDENTITY_NAME = "Identität"
|
||||
LABEL_IDENTITIES_NAME = "Identitäten"
|
||||
LABEL_FILTERS_NAME = "Filters"
|
||||
LABEL_TEMPLATES_NAME = "Templates"
|
||||
LABEL_FILTERS_NAME = "Filter"
|
||||
LABEL_TEMPLATES_NAME = "Vorlagen"
|
||||
LABEL_SECURITY_NAME = "Sicherheit"
|
||||
LABEL_SOCIAL_NAME = "Sozial"
|
||||
LABEL_THEMES_NAME = "Vorlagen"
|
||||
LABEL_SOCIAL_NAME = "Social"
|
||||
LABEL_THEMES_NAME = "Themen"
|
||||
LABEL_CHANGE_PASSWORD_NAME = "Passwort"
|
||||
LABEL_OPEN_PGP_NAME = "OpenPGP"
|
||||
BUTTON_BACK = "Zurück"
|
||||
|
|
@ -415,7 +416,7 @@ LEGEND_FILTERS = "Filter"
|
|||
BUTTON_SAVE = "Speichern"
|
||||
BUTTON_ADD_FILTER = "Filter hinzufügen"
|
||||
BUTTON_DELETE = "Löschen"
|
||||
BUTTON_RAW_SCRIPT = "Benutzerdefiniertes Script verwenden"
|
||||
BUTTON_RAW_SCRIPT = "Benutzerdefiniertes Skript verwenden"
|
||||
SUBNAME_NONE = "Keine"
|
||||
SUBNAME_MOVE_TO = "Verschieben nach \"%FOLDER%\""
|
||||
SUBNAME_FORWARD_TO = "Weiterleiten nach \"%EMAIL%\""
|
||||
|
|
@ -435,16 +436,16 @@ LABEL_SIGNATURE = "Signatur"
|
|||
LABEL_ADD_SIGNATURE_TO_ALL = "Signatur zu allen ausgehenden Nachrichten hinzufügen"
|
||||
|
||||
[SETTINGS_SECURITY]
|
||||
LEGEND_SECURITY = "Security"
|
||||
LEGEND_TWO_FACTOR_AUTH = "2-Faktor-Authentifizierung"
|
||||
LABEL_ENABLE_TWO_FACTOR = "2-Faktor-Authentifizierung aktivieren"
|
||||
LEGEND_SECURITY = "Sicherheit"
|
||||
LEGEND_TWO_FACTOR_AUTH = "Zwei-Faktor-Authentifizierung"
|
||||
LABEL_ENABLE_TWO_FACTOR = "Zwei-Faktor-Authentifizierung aktivieren"
|
||||
LABEL_TWO_FACTOR_USER = "Benutzer"
|
||||
LABEL_TWO_FACTOR_STATUS = "Status"
|
||||
LABEL_TWO_FACTOR_SECRET = "Secret"
|
||||
LABEL_TWO_FACTOR_BACKUP_CODES = "Backup-Codes"
|
||||
LABEL_AUTOLOGOUT = "Auto Logout"
|
||||
AUTOLOGIN_NEVER_OPTION_NAME = "Never"
|
||||
AUTOLOGIN_MINUTES_OPTION_NAME = "%MINUTES% minute(s)"
|
||||
LABEL_AUTOLOGOUT = "Automatische Abmeldung"
|
||||
AUTOLOGIN_NEVER_OPTION_NAME = "Nie"
|
||||
AUTOLOGIN_MINUTES_OPTION_NAME = "%MINUTES% Minute(n)"
|
||||
BUTTON_CREATE = "Neuen Secret erstellen"
|
||||
BUTTON_CLEAR = "Zurücksetzen"
|
||||
BUTTON_TEST = "Testen"
|
||||
|
|
@ -452,9 +453,9 @@ BUTTON_SHOW_SECRET = "Secret anzeigen"
|
|||
BUTTON_HIDE_SECRET = "Secret verbergen"
|
||||
TWO_FACTOR_SECRET_CONFIGURED_DESC = "Konfiguriert"
|
||||
TWO_FACTOR_SECRET_NOT_CONFIGURED_DESC = "Nicht konfiguriert"
|
||||
TWO_FACTOR_SECRET_DESC = "Importieren Sie diese Informationen in Ihren Google Authenticator-Client (oder andere TOTP-Clienten) mit Hilfe des mitgelieferten QR-Code unten oder durch manuelle Eingabe des Codes."
|
||||
TWO_FACTOR_SECRET_DESC = "Importieren Sie diese Informationen in Ihren Google-Authenticator-Client (oder andere TOTP-Clients) mit Hilfe des mitgelieferten QR-Codes unten oder durch manuelle Eingabe des Codes."
|
||||
TWO_FACTOR_BACKUP_CODES_DESC = "Wenn Sie keine Codes via Google Authenticator erhalten können, können Sie Backup-Codes für die Anmeldung verwenden. Nachdem Sie einen Backup-Code verwendet haben, um sich anzumelden, wird dieser inaktiv."
|
||||
TWO_FACTOR_SECRET_TEST_BEFORE_DESC = "You can't change this setting before test."
|
||||
TWO_FACTOR_SECRET_TEST_BEFORE_DESC = "Sie können diese Einstellung nicht vor einer Prüfung ändern."
|
||||
|
||||
[SETTINGS_GENERAL]
|
||||
LEGEND_GENERAL = "Allgemein"
|
||||
|
|
@ -463,19 +464,19 @@ LABEL_LAYOUT = "Layout"
|
|||
LABEL_LAYOUT_NO_SPLIT = "Keine Aufteilung"
|
||||
LABEL_LAYOUT_VERTICAL_SPLIT = "Vertikale Aufteilung"
|
||||
LABEL_LAYOUT_HORIZONTAL_SPLIT = "Horizontale Aufteilung"
|
||||
LABEL_EDITOR = "Standard-Text-Editor"
|
||||
LABEL_EDITOR = "Standard-Texteditor"
|
||||
LABEL_EDITOR_HTML = "HTML"
|
||||
LABEL_EDITOR_PLAIN = "Text"
|
||||
LABEL_EDITOR_PLAIN = "Unformatierter Text"
|
||||
LABEL_EDITOR_HTML_FORCED = "HTML (erzwungen)"
|
||||
LABEL_EDITOR_PLAIN_FORCED = "Text (erzwungen)"
|
||||
LABEL_EDITOR_PLAIN_FORCED = "Unformatierter Text (erzwungen)"
|
||||
LABEL_ANIMATION = "Interface-Animation"
|
||||
LABEL_ANIMATION_FULL = "Komplett"
|
||||
LABEL_ANIMATION_NORMAL = "Normal"
|
||||
LABEL_ANIMATION_NONE = "Keine"
|
||||
LABEL_VIEW_OPTIONS = "Optionen anzeigen"
|
||||
LABEL_USE_PREVIEW_PANE = "Vorschau-Fenster nutzen"
|
||||
LABEL_USE_PREVIEW_PANE = "Vorschaufenster nutzen"
|
||||
LABEL_USE_CHECKBOXES_IN_LIST = "Kontrollkästchen in der Liste anzeigen"
|
||||
LABEL_USE_THREADS = "Thread-förmig anzeigen"
|
||||
LABEL_USE_THREADS = "Als Unterhaltungen anzeigen"
|
||||
LABEL_REPLY_SAME_FOLDER = "Antworten im gleichen Ordner wie die Nachricht, auf die geantwortet wurde, abspeichern"
|
||||
LABEL_SHOW_IMAGES = "In der Nachricht enthaltene Bilder immer anzeigen"
|
||||
LABEL_SHOW_ANIMATION = "Animation anzeigen"
|
||||
|
|
@ -487,65 +488,65 @@ LABEL_CHROME_NOTIFICATION_DESC_DENIED = "(Vom Browser blockiert.)"
|
|||
|
||||
[SETTINGS_CONTACTS]
|
||||
LEGEND_CONTACTS = "Kontakte"
|
||||
LABEL_CONTACTS_AUTOSAVE = "Automatisch Empfänger zu Ihrem Adressbuch hinzuzufügen"
|
||||
LABEL_CONTACTS_AUTOSAVE = "Empfänger automatisch zu Ihrem Adressbuch hinzuzufügen"
|
||||
LEGEND_CONTACTS_SYNC = "Remote-Synchronisierung (CardDAV)"
|
||||
LABEL_CONTACTS_SYNC_ENABLE = "Remote-Synchronisierung aktivieren"
|
||||
LABEL_CONTACTS_SYNC_SERVER = "Server"
|
||||
LABEL_CONTACTS_SYNC_AB_URL = "Adressbuch URL"
|
||||
LABEL_CONTACTS_SYNC_AB_URL = "Adressbuch-URL"
|
||||
LABEL_CONTACTS_SYNC_USER = "Benutzer"
|
||||
LABEL_CONTACTS_SYNC_PASSWORD = "Passwort"
|
||||
|
||||
[SETTINGS_THEMES]
|
||||
LEGEND_THEMES = "Vorlagen"
|
||||
LEGEND_THEMES_CUSTOM = "Konfiguration der selbst-definierten Vorlagen"
|
||||
LEGEND_THEMES = "Themen"
|
||||
LEGEND_THEMES_CUSTOM = "Konfiguration der selbsterstellten Themen"
|
||||
LABEL_CUSTOM_TYPE = "Typ"
|
||||
LABEL_CUSTOM_TYPE_LIGHT = "Hell"
|
||||
LABEL_CUSTOM_TYPE_DARK = "Dunkel"
|
||||
LABEL_CUSTOM_BACKGROUND_IMAGE = "Hintergrund"
|
||||
BUTTON_UPLOAD_BACKGROUND_IMAGE = "Hintergrundvild hochladen(JPG, PNG)"
|
||||
BUTTON_UPLOAD_BACKGROUND_IMAGE = "Hintergrundbild hochladen (JPG, PNG)"
|
||||
ERROR_FILE_IS_TOO_BIG = "Datei ist zu groß"
|
||||
ERROR_FILE_TYPE_ERROR = "Ungültiger Datei-Typ! (nur JPG und PNG)"
|
||||
ERROR_FILE_TYPE_ERROR = "Ungültiger Dateityp (nur JPG und PNG)"
|
||||
ERROR_UNKNOWN = "Ein unbekannter Fehler trat beim Hochladen auf"
|
||||
|
||||
[SETTINGS_SOCIAL]
|
||||
LEGEND_GOOGLE = "Google"
|
||||
BUTTON_GOOGLE_CONNECT = "Mit Google verbinden"
|
||||
BUTTON_GOOGLE_DISCONNECT = "Von Google abmelden"
|
||||
MAIN_GOOGLE_DESC = "Nach der Aktivierung der Anmeldung per Google können Sie sich hier mit dem Google-Button im Anmelde-Dialog anmelden."
|
||||
MAIN_GOOGLE_DESC = "Nach der Aktivierung der Anmeldung per Google können Sie sich hier mit dem Google-Button im Anmeldedialog anmelden."
|
||||
LEGEND_FACEBOOK = "Facebook"
|
||||
BUTTON_FACEBOOK_CONNECT = "Mit Facebook verbinden"
|
||||
BUTTON_FACEBOOK_DISCONNECT = "Von Facebook abmelden"
|
||||
MAIN_FACEBOOK_DESC = "Nach der Aktivierung der Anmeldung per Facebook können Sie sich hier mit dem Facebook-Button im Anmelde-Dialog anmelden."
|
||||
MAIN_FACEBOOK_DESC = "Nach der Aktivierung der Anmeldung per Facebook können Sie sich hier mit dem Facebook-Button im Anmeldedialog anmelden."
|
||||
LEGEND_TWITTER = "Twitter"
|
||||
BUTTON_TWITTER_CONNECT = "Mit Twitter verbinden"
|
||||
BUTTON_TWITTER_DISCONNECT = "Von Twitter abmelden"
|
||||
MAIN_TWITTER_DESC = "Nach der Aktivierung der Anmeldung per Twitter können Sie sich hier mit dem Twitter-Button im Anmelde-Dialog anmelden."
|
||||
MAIN_TWITTER_DESC = "Nach der Aktivierung der Anmeldung per Twitter können Sie sich hier mit dem Twitter-Button im Anmeldedialog anmelden."
|
||||
|
||||
[SETTINGS_FOLDERS]
|
||||
LEGEND_FOLDERS = "Ordner-Liste"
|
||||
LEGEND_FOLDERS = "Ordnerliste"
|
||||
BUTTON_CREATE = "Ordner anlegen"
|
||||
BUTTON_SYSTEM = "System-Ordner wählen"
|
||||
BUTTON_SYSTEM = "Systemordner wählen"
|
||||
BUTTON_DELETE = "Löschen"
|
||||
BUTTON_SUBSCRIBE = "Abonnieren"
|
||||
BUTTON_UNSUBSCRIBE = "Abonnement beenden"
|
||||
LOADING_PROCESS = "Ordner-Liste wird geladen"
|
||||
LOADING_PROCESS = "Ordnerliste wird geladen"
|
||||
CREATING_PROCESS = "Ordner wird angelegt"
|
||||
DELETING_PROCESS = "Ordner wird gelöscht"
|
||||
RENAMING_PROCESS = "Ordner wird umbenannt"
|
||||
DELETING_ASK = "Sind Sie sicher?"
|
||||
TO_MANY_FOLDERS_DESC_1 = "Sie haben zu viele Ordner!"
|
||||
TO_MANY_FOLDERS_DESC_2 = "Wir zeigen aus Leistungsgründen nur einen Teil von ihnen."
|
||||
TO_MANY_FOLDERS_DESC_2 = "Aus Leistungsgründen zeigen wir nur einen Teil davon an."
|
||||
|
||||
[SETTINGS_ACCOUNTS]
|
||||
LEGEND_ACCOUNTS = "Liste der Konten"
|
||||
LEGEND_IDENTITIES = "Identities"
|
||||
LEGEND_ACCOUNTS_AND_IDENTITIES = "Accounts and Identities"
|
||||
LEGEND_ACCOUNTS = "Konten"
|
||||
LEGEND_IDENTITIES = "Identitäten"
|
||||
LEGEND_ACCOUNTS_AND_IDENTITIES = "Konten und Identitäten"
|
||||
BUTTON_ADD_ACCOUNT = "Konto hinzufügen"
|
||||
BUTTON_ADD_IDENTITY = "Add an Identity"
|
||||
BUTTON_ADD_IDENTITY = "Identität hinzufügen"
|
||||
BUTTON_DELETE = "Löschen"
|
||||
LOADING_PROCESS = "Liste der Konten wird geladen"
|
||||
LOADING_PROCESS = "Aktualisiere Kontenliste"
|
||||
DELETING_ASK = "Sind Sie sicher?"
|
||||
DEFAULT_IDENTITY_LABEL = "default"
|
||||
DEFAULT_IDENTITY_LABEL = "Standard"
|
||||
|
||||
[SETTINGS_IDENTITIES]
|
||||
LEGEND_IDENTITY = "Identität"
|
||||
|
|
@ -564,65 +565,65 @@ DELETING_ASK = "Sind Sie sicher?"
|
|||
LEGEND_CHANGE_PASSWORD = "Passwort ändern"
|
||||
LABEL_CURRENT_PASSWORD = "Aktuelles Passwort"
|
||||
LABEL_NEW_PASSWORD = "Neues Passwort"
|
||||
LABEL_REPEAT_PASSWORD = "Neues Passwort wiederholen"
|
||||
LABEL_REPEAT_PASSWORD = "Neues Passwort bestätigen"
|
||||
BUTTON_UPDATE_PASSWORD = "Neues Passwort setzen"
|
||||
ERROR_PASSWORD_MISMATCH = "Passwörter stimmen nicht überein. Versuchen Sie es bitte erneut."
|
||||
ERROR_PASSWORD_MISMATCH = "Passwörter stimmen nicht überein; versuchen Sie es bitte erneut"
|
||||
|
||||
[SETTINGS_OPEN_PGP]
|
||||
LEGEND_OPEN_PGP = "OpenPGP"
|
||||
BUTTON_ADD_OPEN_PGP_KEY = "Import OpenPGP Schlüssel"
|
||||
BUTTON_GENERATE_OPEN_PGP_KEYS = "OpenPGP Schlüssel generieren"
|
||||
BUTTON_ADD_OPEN_PGP_KEY = "OpenPGP-Schlüssel importieren"
|
||||
BUTTON_GENERATE_OPEN_PGP_KEYS = "OpenPGP-Schlüssel generieren"
|
||||
TITLE_PRIVATE = "Privat"
|
||||
TITLE_PUBLIC = "Öffentlich"
|
||||
DELETING_ASK = "Sind Sie sicher?"
|
||||
|
||||
[SHORTCUTS_HELP]
|
||||
LEGEND_SHORTCUTS_HELP = "Tastaturkürzel Hilfe"
|
||||
LEGEND_SHORTCUTS_HELP = "Tastaturkürzel-Hilfe"
|
||||
TAB_MAILBOX = "Postfach"
|
||||
TAB_MESSAGE_LIST = "Nachrichtenliste"
|
||||
TAB_MESSAGE_VIEW = "Nachrichtenansicht"
|
||||
TAB_COMPOSE = "Nachricht schreiben"
|
||||
LABEL_OPEN_USER_DROPDOWN = "Benutzer-Auswahl öffnen"
|
||||
LABEL_OPEN_USER_DROPDOWN = "Benutzerauswahl öffnen"
|
||||
LABEL_REPLY = "Antworten"
|
||||
LABEL_REPLY_ALL = "Allen Antworten"
|
||||
LABEL_FORWARD = "Weiterleiten"
|
||||
LABEL_FORWARD_MULTIPLY = "Weiterleiten (mehrfach)"
|
||||
LABEL_FORWARD_MULTIPLY = "Als Anhang/Anhänge weiterleiten"
|
||||
LABEL_HELP = "Hilfe"
|
||||
LABEL_CHECK_ALL = "Alle Nachrichten auswählen"
|
||||
LABEL_ARCHIVE = "Archivieren"
|
||||
LABEL_DELETE = "Löschen"
|
||||
LABEL_MOVE = "Verschieben"
|
||||
LABEL_READ = "Ausgewählte Nachrichten gelesen"
|
||||
LABEL_UNREAD = "Ausgewählte Nachrichten ungelesen"
|
||||
LABEL_IMPORTANT = "Wichtig, Markiere ausgewählte Nachrichten"
|
||||
LABEL_READ = "Ausgewählte Nachrichten als gelesen markieren"
|
||||
LABEL_UNREAD = "Ausgewählte Nachrichten als ungelesen markieren"
|
||||
LABEL_IMPORTANT = "Wichtig, ausgewählte Nachrichten markieren"
|
||||
LABEL_SEARCH = "Suchen"
|
||||
LABEL_CANCEL_SEARCH = "Suche abbrechen"
|
||||
LABEL_FULLSCREEN_ENTER = "Vollbild (Vorschaubereich-Layout)"
|
||||
LABEL_VIEW_MESSAGE_ENTER = "Nachricht anzeigen (Kein Vorschaubereich-Layout)"
|
||||
LABEL_VIEW_MESSAGE_ENTER = "Nachricht anzeigen (kein Vorschaubereich-Layout)"
|
||||
LABEL_SWITCH_TO_MESSAGE = "Fokus auf ausgewählte Nachricht schalten"
|
||||
LABEL_SWITCH_TO_FOLDER_LIST = "Fokus auf Ordner-Liste schalten"
|
||||
LABEL_SWITCH_TO_FOLDER_LIST = "Fokus auf Ordnerliste schalten"
|
||||
LABEL_FULLSCREEN_TOGGLE = "Vollbildmodus umschalten"
|
||||
LABEL_BLOCKQUOTES_TOGGLE = "Nachricht-Blockzitate umschalten"
|
||||
LABEL_BLOCKQUOTES_TOGGLE = "Nachrichten-Blockzitate umschalten"
|
||||
LABEL_PRINT = "Drucken"
|
||||
LABEL_EXIT_FULLSCREEN = "Vollbildmodus verlassen"
|
||||
LABEL_CLOSE_MESSAGE = "Nachricht schließen (Kein Vorschaubereich-Layout)"
|
||||
LABEL_CLOSE_MESSAGE = "Nachricht schließen (kein Vorschaubereich-Layout)"
|
||||
LABEL_SWITCH_TO_LIST = "Fokus auf Nachrichtenliste zurückschalten"
|
||||
LABEL_OPEN_COMPOSE_POPUP = "Öffne Erstellen Popup"
|
||||
LABEL_OPEN_IDENTITIES_DROPDOWN = "Öffne Identitätenauswahl"
|
||||
LABEL_OPEN_COMPOSE_POPUP = "Erstellen-Popup öffnen"
|
||||
LABEL_OPEN_IDENTITIES_DROPDOWN = "Identitätsauswahl öffnen"
|
||||
LABEL_SAVE_MESSAGE = "Nachricht speichern"
|
||||
LABEL_SEND_MESSAGE = "Nachricht senden"
|
||||
LABEL_CLOSE_COMPOSE = "Popup schließen"
|
||||
|
||||
[PGP_NOTIFICATIONS]
|
||||
NO_PUBLIC_KEYS_FOUND = "Keine öffentlichen Schlüssel gefunden"
|
||||
NO_PUBLIC_KEYS_FOUND_FOR = "Keine öffentlichen Schlüssel für E-Mail \"%EMAIL%\" gefunden"
|
||||
NO_PUBLIC_KEYS_FOUND_FOR = "Keine öffentlichen Schlüssel für die E-Mail \"%EMAIL%\" gefunden"
|
||||
NO_PRIVATE_KEY_FOUND = "Keine privaten Schlüssel gefunden"
|
||||
NO_PRIVATE_KEY_FOUND_FOR = "Keine privaten Schlüssel für E-Mail \"%EMAIL%\" gefunden"
|
||||
UNVERIFIRED_SIGNATURE = "Unverifizierte Unterschrift"
|
||||
DECRYPTION_ERROR = "OpenPGP Entschlüsselungsfehler"
|
||||
NO_PRIVATE_KEY_FOUND_FOR = "Keine privaten Schlüssel für die E-Mail \"%EMAIL%\" gefunden"
|
||||
UNVERIFIRED_SIGNATURE = "Nich verifizierte Unterschrift"
|
||||
DECRYPTION_ERROR = "OpenPGP-Entschlüsselungsfehler"
|
||||
GOOD_SIGNATURE = "Gültige Unterschrift von %USER%"
|
||||
PGP_ERROR = "OpenPGP Fehler: %ERROR%"
|
||||
SPECIFY_FROM_EMAIL = "Bitte VON E-Mail-Adresse angeben"
|
||||
PGP_ERROR = "OpenPGP-Fehler: %ERROR%"
|
||||
SPECIFY_FROM_EMAIL = "Bitte die VON-E-Mail-Adresse angeben"
|
||||
SPECIFY_AT_LEAST_ONE_RECIPIENT = "Bitte geben Sie mindestens einen Empfänger an"
|
||||
|
||||
[NOTIFICATIONS]
|
||||
|
|
@ -631,26 +632,26 @@ AUTH_ERROR = "Authentifizierung fehlgeschlagen"
|
|||
ACCESS_ERROR = "Zugriffsfehler"
|
||||
CONNECTION_ERROR = "Kann nicht mit dem Server verbinden"
|
||||
CAPTCHA_ERROR = "Falsche CAPTCHA-Eingabe."
|
||||
SOCIAL_FACEBOOK_LOGIN_ACCESS_DISABLE = "Diese Social ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Daten an und aktivieren Sie dieses Feature in Ihren Konten-Einstellungen."
|
||||
SOCIAL_TWITTER_LOGIN_ACCESS_DISABLE = "Diese Social ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Daten an und aktivieren Sie dieses Feature in Ihren Konten-Einstellungen."
|
||||
SOCIAL_GOOGLE_LOGIN_ACCESS_DISABLE = "Diese Social ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Daten an und aktivieren Sie dieses Feature in Ihren Konten-Einstellungen."
|
||||
SOCIAL_FACEBOOK_LOGIN_ACCESS_DISABLE = "Diese Social-ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Anmeldedaten an und aktivieren Sie diese Funktion in Ihren Konteneinstellungen."
|
||||
SOCIAL_TWITTER_LOGIN_ACCESS_DISABLE = "Diese Social-ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Anmeldedaten an und aktivieren Sie diese Funktion in Ihren Konteneinstellungen."
|
||||
SOCIAL_GOOGLE_LOGIN_ACCESS_DISABLE = "Diese Social-ID ist bisher mit keinem E-Mail-Konto verbunden. Melden Sie sich mit Ihren E-Mail-Anmeldedaten an und aktivieren Sie diese Funktion in Ihren Konteneinstellungen."
|
||||
DOMAIN_NOT_ALLOWED = "Diese Domain ist nicht zugelassen."
|
||||
ACCOUNT_NOT_ALLOWED = "Konto ist nicht zugelassen."
|
||||
ACCOUNT_TWO_FACTOR_AUTH_REQUIRED = "Zwei-Faktor-Authentifizierung erforderlich"
|
||||
ACCOUNT_TWO_FACTOR_AUTH_ERROR = "Zwei-Faktor-Authentifizierung Fehler"
|
||||
ACCOUNT_TWO_FACTOR_AUTH_ERROR = "Fehler bei Zwei-Faktor-Authentifizierung"
|
||||
COULD_NOT_SAVE_NEW_PASSWORD = "Neues Passwort konnte nicht gespeichert werden"
|
||||
CURRENT_PASSWORD_INCORRECT = "Aktuelles Passwort inkorrekt"
|
||||
CURRENT_PASSWORD_INCORRECT = "Aktuelles Passwort falsch"
|
||||
NEW_PASSWORD_SHORT = "Passwort ist zu kurz"
|
||||
NEW_PASSWORD_WEAK = "Passwort ist zu einfach"
|
||||
NEW_PASSWORD_FORBIDDENT = "Passwort enthält verbotene Zeichen"
|
||||
CONTACTS_SYNC_ERROR = "Kontakte Synchronisationsfehler"
|
||||
NEW_PASSWORD_FORBIDDENT = "Passwort enthält unzulässige Zeichen"
|
||||
CONTACTS_SYNC_ERROR = "Fehler bei Kontakte-Synchronisierung"
|
||||
CANT_GET_MESSAGE_LIST = "Die Nachrichtenliste ist nicht verfügbar"
|
||||
CANT_GET_MESSAGE = "Diese Nachricht ist nicht verfügbar"
|
||||
CANT_DELETE_MESSAGE = "Diese Nachricht kann nicht gelöscht werden"
|
||||
CANT_MOVE_MESSAGE = "Diese Nachricht kann nicht verschoben werden"
|
||||
CANT_SAVE_MESSAGE = "Diese Nachricht kann nicht gespeichert werden"
|
||||
CANT_SEND_MESSAGE = "Diese Nachricht kann nicht gesendet werden"
|
||||
INVALID_RECIPIENTS = "Ungültige Empfänger-Adresse"
|
||||
INVALID_RECIPIENTS = "Ungültige Empfängeradressen"
|
||||
CANT_SAVE_FILTERS = "Die Filter können nicht gespeichert werden"
|
||||
CANT_GET_FILTERS = "Die Filter sind nicht verfügbar"
|
||||
FILTERS_ARE_NOT_CORRECT = "Die Filter sind fehlerhaft"
|
||||
|
|
@ -662,19 +663,19 @@ CANT_SUBSCRIBE_FOLDER = "Dieser Ordner kann nicht abonniert werden"
|
|||
CANT_UNSUBSCRIBE_FOLDER = "Das Abonnement dieses Ordners kann nicht gelöscht werden"
|
||||
CANT_SAVE_SETTINGS = "Einstellungen können nicht gespeichert werden"
|
||||
CANT_SAVE_PLUGIN_SETTINGS = "Einstellungen können nicht gespeichert werden"
|
||||
DOMAIN_ALREADY_EXISTS = "Diese Domain gibt es schon"
|
||||
CANT_INSTALL_PACKAGE = "Package konnte nicht installiert werden"
|
||||
CANT_DELETE_PACKAGE = "Package konnte nicht entfernt werden"
|
||||
INVALID_PLUGIN_PACKAGE = "Plugin-Package ist ungültig"
|
||||
UNSUPPORTED_PLUGIN_PACKAGE = "Plugin-Package wird nicht unterstützt"
|
||||
LICENSING_SERVER_IS_UNAVAILABLE = "Abonnement-Server kann nicht erreicht werden"
|
||||
LICENSING_DOMAIN_EXPIRED = "Das Abonnement dieser Domain ist ausgelaufen"
|
||||
LICENSING_DOMAIN_BANNED = "Das Abonnement dieser Domain ist gesperrt."
|
||||
DEMO_SEND_MESSAGE_ERROR = "Dieser Demo-Account darf aus Sicherheitsgründen keine Nachrichten an externe E-Mail-Adressen versenden!"
|
||||
DOMAIN_ALREADY_EXISTS = "Diese Domain existiert bereits"
|
||||
CANT_INSTALL_PACKAGE = "Paket konnte nicht installiert werden"
|
||||
CANT_DELETE_PACKAGE = "Paket konnte nicht entfernt werden"
|
||||
INVALID_PLUGIN_PACKAGE = "Plugin-Paket ist ungültig"
|
||||
UNSUPPORTED_PLUGIN_PACKAGE = "Plugin-Paket wird nicht unterstützt"
|
||||
LICENSING_SERVER_IS_UNAVAILABLE = "Subscription-Server kann nicht erreicht werden"
|
||||
LICENSING_DOMAIN_EXPIRED = "Die Subscription dieser Domain ist ausgelaufen."
|
||||
LICENSING_DOMAIN_BANNED = "Die Subscription dieser Domain ist gesperrt."
|
||||
DEMO_SEND_MESSAGE_ERROR = "Dieses Demokonto darf aus Sicherheitsgründen keine Nachrichten an externe E-Mail-Adressen versenden!"
|
||||
DEMO_ACCOUNT_ERROR = "Aus Sicherheitsgründen ist dieses Konto nicht zu dieser Aktion berechtigt!"
|
||||
ACCOUNT_ALREADY_EXISTS = "Dieses Konto gibt es schon."
|
||||
ACCOUNT_ALREADY_EXISTS = "Dieses Konto existiert bereits"
|
||||
MAIL_SERVER_ERROR = "Beim Zugriff auf den E-Mail-Server trat ein Fehler auf."
|
||||
INVALID_INPUT_ARGUMENT = "Fehlerhafte Eingabe"
|
||||
INVALID_INPUT_ARGUMENT = "Ungültige Eingabe"
|
||||
UNKNOWN_ERROR = "Unbekannter Fehler"
|
||||
|
||||
[STATIC]
|
||||
|
|
@ -684,10 +685,10 @@ PHP_EXSTENSIONS_ERROR_DESC = "Notwendige PHP-Erweiterungen sind in Ihrer PHP-Kon
|
|||
PHP_VERSION_ERROR_DESC = "Ihre PHP Version (%VERSION%) ist älter als die notwendige Version: 5.3.0!"
|
||||
NO_SCRIPT_TITLE = "Diese Anwendung benötigt JavaScript."
|
||||
NO_SCRIPT_DESC = "Ihr Browser unterstützt JavaScript nicht.
|
||||
Aktivieren Sie bitte die Javascript-Unterstützung in Ihrem Browser und versuchen Sie es noch einmal."
|
||||
Aktivieren Sie bitte die JavaScript-Unterstützung in Ihrem Browser und versuchen Sie es erneut."
|
||||
NO_COOKIE_TITLE = "Diese Anwendung benötigt Cookies."
|
||||
NO_COOKIE_DESC = "Ihr Browser unterstützt Cookies nicht.
|
||||
Aktivieren Sie bitte die Cookie-Unterstützung in Ihrem Browser und versuchen Sie es noch einmal."
|
||||
Aktivieren Sie bitte die Cookie-Unterstützung in Ihrem Browser und versuchen Sie es erneut."
|
||||
BAD_BROWSER_TITLE = "Ihr Browser ist veraltet."
|
||||
BAD_BROWSER_DESC = "Um alle Features dieser Anwendung nutzen zu können,
|
||||
sollten Sie einen aktuellen Browser installieren!"
|
||||
BAD_BROWSER_DESC = "Um alle Funktionen dieser Anwendung nutzen zu können,
|
||||
sollten Sie einen der folgenden Browser herunterladen und installieren:"
|
||||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet."
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Yes"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Solicitar confirmación de lectura"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Sí"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Demander une confirmation de lecture"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Oui"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Igen"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Yes"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Non tutti gli allegati sono stati caricati al m
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Richiedi conferma di lettura"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Marca come importante"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Solo testo semplice)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Si"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "開封確認を要求しますか?"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "はい"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Yes"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Dar ne visi priedai buvo įkelti"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Prašyti pranešti kada bus perskaitytas"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Žymėti svarbiu"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Tik paprastas tekstas)"
|
||||
BUTTON_REQUEST_DSN = "Prašyti laiško gavimo pažymos"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Taip"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Yes"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Toevoegen van bijlage(n) is nog niet gereed"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Leesbevestiging vragen"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Marker als belangrijk"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (allen bij Platte Tekst)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Ja"
|
||||
|
|
@ -690,4 +691,4 @@ NO_COOKIE_DESC = "Cookies ondersteuning is niet beschikbaar in uw browser.
|
|||
Gelieve Cookies in te schakelen en opnieuw te proberen."
|
||||
BAD_BROWSER_TITLE = "Uw browser is verouderd"
|
||||
BAD_BROWSER_DESC = "Om alle functies van deze applicatie te gebruiken,
|
||||
download en installeer een van de volgende browsers:"
|
||||
download en installeer een van de volgende browsers:"
|
||||
|
|
@ -232,6 +232,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Alle vedleggene er ikke lastet opp ennå"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Be om en lesebekreftelse når meldingen er lest"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Ja"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Nie przesłano jeszcze wszystkich załącznikó
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Żądaj potwierdzenia odbioru"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Oznacz jako ważną"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Tylko zwykły tekst)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Tak"
|
||||
|
|
@ -690,4 +691,4 @@ NO_COOKIE_DESC = "Obsługa Cookies jest wyłączona w twojej przeglądarce
|
|||
Proszę o umożliwienie obsługi plików Cookie w przeglądarce oraz ponowne uruchomienie tej strony."
|
||||
BAD_BROWSER_TITLE = "Twoja przeglądarka jest przestarzała!"
|
||||
BAD_BROWSER_DESC = "W celu wykorzystania wszystkich funkcji tej aplikacji,
|
||||
zaktualizuj aktualnie używaną lub pobierz i zainstaluj jedną z poniższych przeglądarek:"
|
||||
zaktualizuj aktualnie używaną lub pobierz i zainstaluj jedną z poniższych przeglądarek:"
|
||||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Alguns anexos ainda não foram completamente en
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Pedir recibo de leitura"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Marcar como importante"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Somente Texto)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Sim"
|
||||
|
|
@ -690,4 +691,4 @@ NO_COOKIE_DESC = "Os Cookies não estão disponíveis em seu navegador.
|
|||
Por favor ative o suporte a Cookies nas configurações do seu navegador e tente novamente."
|
||||
BAD_BROWSER_TITLE = "Seu navegador está desatualizado."
|
||||
BAD_BROWSER_DESC = "Para usar todos os recursos do aplicativo,
|
||||
baixe e instale um desses navegadores:"
|
||||
baixe e instale um desses navegadores:"
|
||||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Ainda não foram carregados todos os anexos"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Pedir um recibo de leitura"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Marcar como importante"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (apenas texto simples)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Sim"
|
||||
|
|
@ -690,4 +691,4 @@ NO_COOKIE_DESC = "O suport de Cookies não está disponível no seu navegador.
|
|||
Por favor ative o suporte de Cookies nas definições do seu navegador e tente novamente."
|
||||
BAD_BROWSER_TITLE = "O seu navegador está desatualizado."
|
||||
BAD_BROWSER_DESC = "Para usar todas as funções da aplicação,
|
||||
transfira e instale um destes navegadores:"
|
||||
transfira e instale um destes navegadores:"
|
||||
|
|
@ -232,6 +232,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Cere confirmare de citire"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Da"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Запрос о прочтении письма"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Да"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Vyžiadať potvrdenie o prečítaní"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Áno"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Alla bilagor är inte uppladddade än"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Begär mottagningskvitto"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Markera som viktigt"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Endast enkel text)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Ja"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Okundu bilgisi iste"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Evet"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Запит про прочитання листа"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "Так"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "是"
|
||||
|
|
|
|||
|
|
@ -233,6 +233,7 @@ ATTACHMENTS_UPLOAD_ERROR_DESC = "Not all attachments have been uploaded yet"
|
|||
BUTTON_REQUEST_READ_RECEIPT = "Request a read receipt"
|
||||
BUTTON_MARK_AS_IMPORTANT = "Mark as important"
|
||||
BUTTON_OPEN_PGP = "OpenPGP (Plain Text Only)"
|
||||
BUTTON_REQUEST_DSN = "Request a delivery receipt"
|
||||
|
||||
[POPUPS_ASK]
|
||||
BUTTON_YES = "是"
|
||||
|
|
|
|||
115
vendors/knockout/knockout-3.3.0.js
vendored
Normal file
115
vendors/knockout/knockout-3.3.0.js
vendored
Normal file
|
|
@ -0,0 +1,115 @@
|
|||
/*!
|
||||
* Knockout JavaScript library v3.3.0
|
||||
* (c) Steven Sanderson - http://knockoutjs.com/
|
||||
* License: MIT (http://www.opensource.org/licenses/mit-license.php)
|
||||
*/
|
||||
|
||||
(function() {(function(p){var y=this||(0,eval)("this"),w=y.document,M=y.navigator,u=y.jQuery,E=y.JSON;(function(p){"function"===typeof define&&define.amd?define(["exports","require"],p):"function"===typeof require&&"object"===typeof exports&&"object"===typeof module?p(module.exports||exports):p(y.ko={})})(function(N,O){function J(a,d){return null===a||typeof a in Q?a===d:!1}function R(a,d){var c;return function(){c||(c=setTimeout(function(){c=p;a()},d))}}function S(a,d){var c;return function(){clearTimeout(c);
|
||||
c=setTimeout(a,d)}}function K(b,d,c,e){a.d[b]={init:function(b,k,h,l,g){var m,x;a.w(function(){var q=a.a.c(k()),n=!c!==!q,r=!x;if(r||d||n!==m)r&&a.Z.oa()&&(x=a.a.la(a.e.childNodes(b),!0)),n?(r||a.e.T(b,a.a.la(x)),a.Ja(e?e(g,q):g,b)):a.e.ma(b),m=n},null,{q:b});return{controlsDescendantBindings:!0}}};a.h.ka[b]=!1;a.e.R[b]=!0}var a="undefined"!==typeof N?N:{};a.b=function(b,d){for(var c=b.split("."),e=a,f=0;f<c.length-1;f++)e=e[c[f]];e[c[c.length-1]]=d};a.D=function(a,d,c){a[d]=c};a.version="3.3.0";
|
||||
a.b("version",a.version);a.a=function(){function b(a,b){for(var c in a)a.hasOwnProperty(c)&&b(c,a[c])}function d(a,b){if(b)for(var c in b)b.hasOwnProperty(c)&&(a[c]=b[c]);return a}function c(a,b){a.__proto__=b;return a}function e(b,c,g,d){var e=b[c].match(m)||[];a.a.o(g.match(m),function(b){a.a.ga(e,b,d)});b[c]=e.join(" ")}var f={__proto__:[]}instanceof Array,k={},h={};k[M&&/Firefox\/2/i.test(M.userAgent)?"KeyboardEvent":"UIEvents"]=["keyup","keydown","keypress"];k.MouseEvents="click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave".split(" ");
|
||||
b(k,function(a,b){if(b.length)for(var c=0,g=b.length;c<g;c++)h[b[c]]=a});var l={propertychange:!0},g=w&&function(){for(var a=3,b=w.createElement("div"),c=b.getElementsByTagName("i");b.innerHTML="\x3c!--[if gt IE "+ ++a+"]><i></i><![endif]--\x3e",c[0];);return 4<a?a:p}(),m=/\S+/g;return{Bb:["authenticity_token",/^__RequestVerificationToken(_.*)?$/],o:function(a,b){for(var c=0,g=a.length;c<g;c++)b(a[c],c)},m:function(a,b){if("function"==typeof Array.prototype.indexOf)return Array.prototype.indexOf.call(a,
|
||||
b);for(var c=0,g=a.length;c<g;c++)if(a[c]===b)return c;return-1},vb:function(a,b,c){for(var g=0,d=a.length;g<d;g++)if(b.call(c,a[g],g))return a[g];return null},ya:function(b,c){var g=a.a.m(b,c);0<g?b.splice(g,1):0===g&&b.shift()},wb:function(b){b=b||[];for(var c=[],g=0,d=b.length;g<d;g++)0>a.a.m(c,b[g])&&c.push(b[g]);return c},Ka:function(a,b){a=a||[];for(var c=[],g=0,d=a.length;g<d;g++)c.push(b(a[g],g));return c},xa:function(a,b){a=a||[];for(var c=[],g=0,d=a.length;g<d;g++)b(a[g],g)&&c.push(a[g]);
|
||||
return c},ia:function(a,b){if(b instanceof Array)a.push.apply(a,b);else for(var c=0,g=b.length;c<g;c++)a.push(b[c]);return a},ga:function(b,c,g){var d=a.a.m(a.a.cb(b),c);0>d?g&&b.push(c):g||b.splice(d,1)},za:f,extend:d,Fa:c,Ga:f?c:d,A:b,pa:function(a,b){if(!a)return a;var c={},g;for(g in a)a.hasOwnProperty(g)&&(c[g]=b(a[g],g,a));return c},Ra:function(b){for(;b.firstChild;)a.removeNode(b.firstChild)},Jb:function(b){b=a.a.O(b);for(var c=(b[0]&&b[0].ownerDocument||w).createElement("div"),g=0,d=b.length;g<
|
||||
d;g++)c.appendChild(a.S(b[g]));return c},la:function(b,c){for(var g=0,d=b.length,e=[];g<d;g++){var m=b[g].cloneNode(!0);e.push(c?a.S(m):m)}return e},T:function(b,c){a.a.Ra(b);if(c)for(var g=0,d=c.length;g<d;g++)b.appendChild(c[g])},Qb:function(b,c){var g=b.nodeType?[b]:b;if(0<g.length){for(var d=g[0],e=d.parentNode,m=0,f=c.length;m<f;m++)e.insertBefore(c[m],d);m=0;for(f=g.length;m<f;m++)a.removeNode(g[m])}},na:function(a,b){if(a.length){for(b=8===b.nodeType&&b.parentNode||b;a.length&&a[0].parentNode!==
|
||||
b;)a.splice(0,1);if(1<a.length){var c=a[0],g=a[a.length-1];for(a.length=0;c!==g;)if(a.push(c),c=c.nextSibling,!c)return;a.push(g)}}return a},Sb:function(a,b){7>g?a.setAttribute("selected",b):a.selected=b},ib:function(a){return null===a||a===p?"":a.trim?a.trim():a.toString().replace(/^[\s\xa0]+|[\s\xa0]+$/g,"")},Dc:function(a,b){a=a||"";return b.length>a.length?!1:a.substring(0,b.length)===b},jc:function(a,b){if(a===b)return!0;if(11===a.nodeType)return!1;if(b.contains)return b.contains(3===a.nodeType?
|
||||
a.parentNode:a);if(b.compareDocumentPosition)return 16==(b.compareDocumentPosition(a)&16);for(;a&&a!=b;)a=a.parentNode;return!!a},Qa:function(b){return a.a.jc(b,b.ownerDocument.documentElement)},tb:function(b){return!!a.a.vb(b,a.a.Qa)},v:function(a){return a&&a.tagName&&a.tagName.toLowerCase()},n:function(b,c,d){var m=g&&l[c];if(!m&&u)u(b).bind(c,d);else if(m||"function"!=typeof b.addEventListener)if("undefined"!=typeof b.attachEvent){var e=function(a){d.call(b,a)},f="on"+c;b.attachEvent(f,e);a.a.C.fa(b,
|
||||
function(){b.detachEvent(f,e)})}else throw Error("Browser doesn't support addEventListener or attachEvent");else b.addEventListener(c,d,!1)},qa:function(b,c){if(!b||!b.nodeType)throw Error("element must be a DOM node when calling triggerEvent");var g;"input"===a.a.v(b)&&b.type&&"click"==c.toLowerCase()?(g=b.type,g="checkbox"==g||"radio"==g):g=!1;if(u&&!g)u(b).trigger(c);else if("function"==typeof w.createEvent)if("function"==typeof b.dispatchEvent)g=w.createEvent(h[c]||"HTMLEvents"),g.initEvent(c,
|
||||
!0,!0,y,0,0,0,0,0,!1,!1,!1,!1,0,b),b.dispatchEvent(g);else throw Error("The supplied element doesn't support dispatchEvent");else if(g&&b.click)b.click();else if("undefined"!=typeof b.fireEvent)b.fireEvent("on"+c);else throw Error("Browser doesn't support triggering events");},c:function(b){return a.F(b)?b():b},cb:function(b){return a.F(b)?b.B():b},Ia:function(b,c,g){var d;c&&("object"===typeof b.classList?(d=b.classList[g?"add":"remove"],a.a.o(c.match(m),function(a){d.call(b.classList,a)})):"string"===
|
||||
typeof b.className.baseVal?e(b.className,"baseVal",c,g):e(b,"className",c,g))},Ha:function(b,c){var g=a.a.c(c);if(null===g||g===p)g="";var d=a.e.firstChild(b);!d||3!=d.nodeType||a.e.nextSibling(d)?a.e.T(b,[b.ownerDocument.createTextNode(g)]):d.data=g;a.a.mc(b)},Rb:function(a,b){a.name=b;if(7>=g)try{a.mergeAttributes(w.createElement("<input name='"+a.name+"'/>"),!1)}catch(c){}},mc:function(a){9<=g&&(a=1==a.nodeType?a:a.parentNode,a.style&&(a.style.zoom=a.style.zoom))},kc:function(a){if(g){var b=a.style.width;
|
||||
a.style.width=0;a.style.width=b}},Bc:function(b,c){b=a.a.c(b);c=a.a.c(c);for(var g=[],d=b;d<=c;d++)g.push(d);return g},O:function(a){for(var b=[],c=0,g=a.length;c<g;c++)b.push(a[c]);return b},Hc:6===g,Ic:7===g,M:g,Db:function(b,c){for(var g=a.a.O(b.getElementsByTagName("input")).concat(a.a.O(b.getElementsByTagName("textarea"))),d="string"==typeof c?function(a){return a.name===c}:function(a){return c.test(a.name)},m=[],e=g.length-1;0<=e;e--)d(g[e])&&m.push(g[e]);return m},yc:function(b){return"string"==
|
||||
typeof b&&(b=a.a.ib(b))?E&&E.parse?E.parse(b):(new Function("return "+b))():null},jb:function(b,c,g){if(!E||!E.stringify)throw Error("Cannot find JSON.stringify(). Some browsers (e.g., IE < 8) don't support it natively, but you can overcome this by adding a script reference to json2.js, downloadable from http://www.json.org/json2.js");return E.stringify(a.a.c(b),c,g)},zc:function(c,g,d){d=d||{};var m=d.params||{},e=d.includeFields||this.Bb,f=c;if("object"==typeof c&&"form"===a.a.v(c))for(var f=c.action,
|
||||
l=e.length-1;0<=l;l--)for(var k=a.a.Db(c,e[l]),h=k.length-1;0<=h;h--)m[k[h].name]=k[h].value;g=a.a.c(g);var s=w.createElement("form");s.style.display="none";s.action=f;s.method="post";for(var p in g)c=w.createElement("input"),c.type="hidden",c.name=p,c.value=a.a.jb(a.a.c(g[p])),s.appendChild(c);b(m,function(a,b){var c=w.createElement("input");c.type="hidden";c.name=a;c.value=b;s.appendChild(c)});w.body.appendChild(s);d.submitter?d.submitter(s):s.submit();setTimeout(function(){s.parentNode.removeChild(s)},
|
||||
0)}}}();a.b("utils",a.a);a.b("utils.arrayForEach",a.a.o);a.b("utils.arrayFirst",a.a.vb);a.b("utils.arrayFilter",a.a.xa);a.b("utils.arrayGetDistinctValues",a.a.wb);a.b("utils.arrayIndexOf",a.a.m);a.b("utils.arrayMap",a.a.Ka);a.b("utils.arrayPushAll",a.a.ia);a.b("utils.arrayRemoveItem",a.a.ya);a.b("utils.extend",a.a.extend);a.b("utils.fieldsIncludedWithJsonPost",a.a.Bb);a.b("utils.getFormFields",a.a.Db);a.b("utils.peekObservable",a.a.cb);a.b("utils.postJson",a.a.zc);a.b("utils.parseJson",a.a.yc);a.b("utils.registerEventHandler",
|
||||
a.a.n);a.b("utils.stringifyJson",a.a.jb);a.b("utils.range",a.a.Bc);a.b("utils.toggleDomNodeCssClass",a.a.Ia);a.b("utils.triggerEvent",a.a.qa);a.b("utils.unwrapObservable",a.a.c);a.b("utils.objectForEach",a.a.A);a.b("utils.addOrRemoveItem",a.a.ga);a.b("utils.setTextContent",a.a.Ha);a.b("unwrap",a.a.c);Function.prototype.bind||(Function.prototype.bind=function(a){var d=this;if(1===arguments.length)return function(){return d.apply(a,arguments)};var c=Array.prototype.slice.call(arguments,1);return function(){var e=
|
||||
c.slice(0);e.push.apply(e,arguments);return d.apply(a,e)}});a.a.f=new function(){function a(b,k){var h=b[c];if(!h||"null"===h||!e[h]){if(!k)return p;h=b[c]="ko"+d++;e[h]={}}return e[h]}var d=0,c="__ko__"+(new Date).getTime(),e={};return{get:function(c,d){var e=a(c,!1);return e===p?p:e[d]},set:function(c,d,e){if(e!==p||a(c,!1)!==p)a(c,!0)[d]=e},clear:function(a){var b=a[c];return b?(delete e[b],a[c]=null,!0):!1},I:function(){return d++ +c}}};a.b("utils.domData",a.a.f);a.b("utils.domData.clear",a.a.f.clear);
|
||||
a.a.C=new function(){function b(b,d){var e=a.a.f.get(b,c);e===p&&d&&(e=[],a.a.f.set(b,c,e));return e}function d(c){var e=b(c,!1);if(e)for(var e=e.slice(0),l=0;l<e.length;l++)e[l](c);a.a.f.clear(c);a.a.C.cleanExternalData(c);if(f[c.nodeType])for(e=c.firstChild;c=e;)e=c.nextSibling,8===c.nodeType&&d(c)}var c=a.a.f.I(),e={1:!0,8:!0,9:!0},f={1:!0,9:!0};return{fa:function(a,c){if("function"!=typeof c)throw Error("Callback must be a function");b(a,!0).push(c)},Pb:function(d,e){var f=b(d,!1);f&&(a.a.ya(f,
|
||||
e),0==f.length&&a.a.f.set(d,c,p))},S:function(b){if(e[b.nodeType]&&(d(b),f[b.nodeType])){var c=[];a.a.ia(c,b.getElementsByTagName("*"));for(var l=0,g=c.length;l<g;l++)d(c[l])}return b},removeNode:function(b){a.S(b);b.parentNode&&b.parentNode.removeChild(b)},cleanExternalData:function(a){u&&"function"==typeof u.cleanData&&u.cleanData([a])}}};a.S=a.a.C.S;a.removeNode=a.a.C.removeNode;a.b("cleanNode",a.S);a.b("removeNode",a.removeNode);a.b("utils.domNodeDisposal",a.a.C);a.b("utils.domNodeDisposal.addDisposeCallback",
|
||||
a.a.C.fa);a.b("utils.domNodeDisposal.removeDisposeCallback",a.a.C.Pb);(function(){a.a.ca=function(b,d){var c;if(u)if(u.parseHTML)c=u.parseHTML(b,d)||[];else{if((c=u.clean([b],d))&&c[0]){for(var e=c[0];e.parentNode&&11!==e.parentNode.nodeType;)e=e.parentNode;e.parentNode&&e.parentNode.removeChild(e)}}else{(e=d)||(e=w);c=e.parentWindow||e.defaultView||y;var f=a.a.ib(b).toLowerCase(),e=e.createElement("div"),f=f.match(/^<(thead|tbody|tfoot)/)&&[1,"<table>","</table>"]||!f.indexOf("<tr")&&[2,"<table><tbody>",
|
||||
"</tbody></table>"]||(!f.indexOf("<td")||!f.indexOf("<th"))&&[3,"<table><tbody><tr>","</tr></tbody></table>"]||[0,"",""],k="ignored<div>"+f[1]+b+f[2]+"</div>";for("function"==typeof c.innerShiv?e.appendChild(c.innerShiv(k)):e.innerHTML=k;f[0]--;)e=e.lastChild;c=a.a.O(e.lastChild.childNodes)}return c};a.a.gb=function(b,d){a.a.Ra(b);d=a.a.c(d);if(null!==d&&d!==p)if("string"!=typeof d&&(d=d.toString()),u)u(b).html(d);else for(var c=a.a.ca(d,b.ownerDocument),e=0;e<c.length;e++)b.appendChild(c[e])}})();
|
||||
a.b("utils.parseHtmlFragment",a.a.ca);a.b("utils.setHtml",a.a.gb);a.H=function(){function b(c,d){if(c)if(8==c.nodeType){var f=a.H.Lb(c.nodeValue);null!=f&&d.push({ic:c,wc:f})}else if(1==c.nodeType)for(var f=0,k=c.childNodes,h=k.length;f<h;f++)b(k[f],d)}var d={};return{$a:function(a){if("function"!=typeof a)throw Error("You can only pass a function to ko.memoization.memoize()");var b=(4294967296*(1+Math.random())|0).toString(16).substring(1)+(4294967296*(1+Math.random())|0).toString(16).substring(1);
|
||||
d[b]=a;return"\x3c!--[ko_memo:"+b+"]--\x3e"},Wb:function(a,b){var f=d[a];if(f===p)throw Error("Couldn't find any memo with ID "+a+". Perhaps it's already been unmemoized.");try{return f.apply(null,b||[]),!0}finally{delete d[a]}},Xb:function(c,d){var f=[];b(c,f);for(var k=0,h=f.length;k<h;k++){var l=f[k].ic,g=[l];d&&a.a.ia(g,d);a.H.Wb(f[k].wc,g);l.nodeValue="";l.parentNode&&l.parentNode.removeChild(l)}},Lb:function(a){return(a=a.match(/^\[ko_memo\:(.*?)\]$/))?a[1]:null}}}();a.b("memoization",a.H);
|
||||
a.b("memoization.memoize",a.H.$a);a.b("memoization.unmemoize",a.H.Wb);a.b("memoization.parseMemoText",a.H.Lb);a.b("memoization.unmemoizeDomNodeAndDescendants",a.H.Xb);a.Sa={throttle:function(b,d){b.throttleEvaluation=d;var c=null;return a.j({read:b,write:function(a){clearTimeout(c);c=setTimeout(function(){b(a)},d)}})},rateLimit:function(a,d){var c,e,f;"number"==typeof d?c=d:(c=d.timeout,e=d.method);f="notifyWhenChangesStop"==e?S:R;a.Za(function(a){return f(a,c)})},notify:function(a,d){a.equalityComparer=
|
||||
"always"==d?null:J}};var Q={undefined:1,"boolean":1,number:1,string:1};a.b("extenders",a.Sa);a.Ub=function(b,d,c){this.da=b;this.La=d;this.hc=c;this.Gb=!1;a.D(this,"dispose",this.p)};a.Ub.prototype.p=function(){this.Gb=!0;this.hc()};a.Q=function(){a.a.Ga(this,a.Q.fn);this.G={};this.rb=1};var z={U:function(b,d,c){var e=this;c=c||"change";var f=new a.Ub(e,d?b.bind(d):b,function(){a.a.ya(e.G[c],f);e.ua&&e.ua(c)});e.ja&&e.ja(c);e.G[c]||(e.G[c]=[]);e.G[c].push(f);return f},notifySubscribers:function(b,
|
||||
d){d=d||"change";"change"===d&&this.Yb();if(this.Ba(d))try{a.k.xb();for(var c=this.G[d].slice(0),e=0,f;f=c[e];++e)f.Gb||f.La(b)}finally{a.k.end()}},Aa:function(){return this.rb},pc:function(a){return this.Aa()!==a},Yb:function(){++this.rb},Za:function(b){var d=this,c=a.F(d),e,f,k;d.ta||(d.ta=d.notifySubscribers,d.notifySubscribers=function(a,b){b&&"change"!==b?"beforeChange"===b?d.pb(a):d.ta(a,b):d.qb(a)});var h=b(function(){c&&k===d&&(k=d());e=!1;d.Wa(f,k)&&d.ta(f=k)});d.qb=function(a){e=!0;k=a;
|
||||
h()};d.pb=function(a){e||(f=a,d.ta(a,"beforeChange"))}},Ba:function(a){return this.G[a]&&this.G[a].length},nc:function(b){if(b)return this.G[b]&&this.G[b].length||0;var d=0;a.a.A(this.G,function(a,b){d+=b.length});return d},Wa:function(a,d){return!this.equalityComparer||!this.equalityComparer(a,d)},extend:function(b){var d=this;b&&a.a.A(b,function(b,e){var f=a.Sa[b];"function"==typeof f&&(d=f(d,e)||d)});return d}};a.D(z,"subscribe",z.U);a.D(z,"extend",z.extend);a.D(z,"getSubscriptionsCount",z.nc);
|
||||
a.a.za&&a.a.Fa(z,Function.prototype);a.Q.fn=z;a.Hb=function(a){return null!=a&&"function"==typeof a.U&&"function"==typeof a.notifySubscribers};a.b("subscribable",a.Q);a.b("isSubscribable",a.Hb);a.Z=a.k=function(){function b(a){c.push(e);e=a}function d(){e=c.pop()}var c=[],e,f=0;return{xb:b,end:d,Ob:function(b){if(e){if(!a.Hb(b))throw Error("Only subscribable things can act as dependencies");e.La(b,b.ac||(b.ac=++f))}},u:function(a,c,e){try{return b(),a.apply(c,e||[])}finally{d()}},oa:function(){if(e)return e.w.oa()},
|
||||
Ca:function(){if(e)return e.Ca}}}();a.b("computedContext",a.Z);a.b("computedContext.getDependenciesCount",a.Z.oa);a.b("computedContext.isInitial",a.Z.Ca);a.b("computedContext.isSleeping",a.Z.Jc);a.b("ignoreDependencies",a.Gc=a.k.u);a.r=function(b){function d(){if(0<arguments.length)return d.Wa(c,arguments[0])&&(d.X(),c=arguments[0],d.W()),this;a.k.Ob(d);return c}var c=b;a.Q.call(d);a.a.Ga(d,a.r.fn);d.B=function(){return c};d.W=function(){d.notifySubscribers(c)};d.X=function(){d.notifySubscribers(c,
|
||||
"beforeChange")};a.D(d,"peek",d.B);a.D(d,"valueHasMutated",d.W);a.D(d,"valueWillMutate",d.X);return d};a.r.fn={equalityComparer:J};var H=a.r.Ac="__ko_proto__";a.r.fn[H]=a.r;a.a.za&&a.a.Fa(a.r.fn,a.Q.fn);a.Ta=function(b,d){return null===b||b===p||b[H]===p?!1:b[H]===d?!0:a.Ta(b[H],d)};a.F=function(b){return a.Ta(b,a.r)};a.Da=function(b){return"function"==typeof b&&b[H]===a.r||"function"==typeof b&&b[H]===a.j&&b.qc?!0:!1};a.b("observable",a.r);a.b("isObservable",a.F);a.b("isWriteableObservable",a.Da);
|
||||
a.b("isWritableObservable",a.Da);a.ba=function(b){b=b||[];if("object"!=typeof b||!("length"in b))throw Error("The argument passed when initializing an observable array must be an array, or null, or undefined.");b=a.r(b);a.a.Ga(b,a.ba.fn);return b.extend({trackArrayChanges:!0})};a.ba.fn={remove:function(b){for(var d=this.B(),c=[],e="function"!=typeof b||a.F(b)?function(a){return a===b}:b,f=0;f<d.length;f++){var k=d[f];e(k)&&(0===c.length&&this.X(),c.push(k),d.splice(f,1),f--)}c.length&&this.W();return c},
|
||||
removeAll:function(b){if(b===p){var d=this.B(),c=d.slice(0);this.X();d.splice(0,d.length);this.W();return c}return b?this.remove(function(c){return 0<=a.a.m(b,c)}):[]},destroy:function(b){var d=this.B(),c="function"!=typeof b||a.F(b)?function(a){return a===b}:b;this.X();for(var e=d.length-1;0<=e;e--)c(d[e])&&(d[e]._destroy=!0);this.W()},destroyAll:function(b){return b===p?this.destroy(function(){return!0}):b?this.destroy(function(d){return 0<=a.a.m(b,d)}):[]},indexOf:function(b){var d=this();return a.a.m(d,
|
||||
b)},replace:function(a,d){var c=this.indexOf(a);0<=c&&(this.X(),this.B()[c]=d,this.W())}};a.a.o("pop push reverse shift sort splice unshift".split(" "),function(b){a.ba.fn[b]=function(){var a=this.B();this.X();this.yb(a,b,arguments);a=a[b].apply(a,arguments);this.W();return a}});a.a.o(["slice"],function(b){a.ba.fn[b]=function(){var a=this();return a[b].apply(a,arguments)}});a.a.za&&a.a.Fa(a.ba.fn,a.r.fn);a.b("observableArray",a.ba);a.Sa.trackArrayChanges=function(b){function d(){if(!c){c=!0;var g=
|
||||
b.notifySubscribers;b.notifySubscribers=function(a,b){b&&"change"!==b||++k;return g.apply(this,arguments)};var d=[].concat(b.B()||[]);e=null;f=b.U(function(c){c=[].concat(c||[]);if(b.Ba("arrayChange")){var g;if(!e||1<k)e=a.a.Ma(d,c,{sparse:!0});g=e}d=c;e=null;k=0;g&&g.length&&b.notifySubscribers(g,"arrayChange")})}}if(!b.yb){var c=!1,e=null,f,k=0,h=b.ja,l=b.ua;b.ja=function(a){h&&h.call(b,a);"arrayChange"===a&&d()};b.ua=function(a){l&&l.call(b,a);"arrayChange"!==a||b.Ba("arrayChange")||(f.p(),c=!1)};
|
||||
b.yb=function(b,d,f){function l(a,b,c){return h[h.length]={status:a,value:b,index:c}}if(c&&!k){var h=[],r=b.length,v=f.length,t=0;switch(d){case "push":t=r;case "unshift":for(d=0;d<v;d++)l("added",f[d],t+d);break;case "pop":t=r-1;case "shift":r&&l("deleted",b[t],t);break;case "splice":d=Math.min(Math.max(0,0>f[0]?r+f[0]:f[0]),r);for(var r=1===v?r:Math.min(d+(f[1]||0),r),v=d+v-2,t=Math.max(r,v),G=[],A=[],p=2;d<t;++d,++p)d<r&&A.push(l("deleted",b[d],d)),d<v&&G.push(l("added",f[p],d));a.a.Cb(A,G);break;
|
||||
default:return}e=h}}}};a.w=a.j=function(b,d,c){function e(a,b,c){if(I&&b===g)throw Error("A 'pure' computed must not be called recursively");B[a]=c;c.sa=F++;c.ea=b.Aa()}function f(){var a,b;for(a in B)if(B.hasOwnProperty(a)&&(b=B[a],b.da.pc(b.ea)))return!0}function k(){!s&&B&&a.a.A(B,function(a,b){b.p&&b.p()});B=null;F=0;G=!0;s=r=!1}function h(){var a=g.throttleEvaluation;a&&0<=a?(clearTimeout(z),z=setTimeout(function(){l(!0)},a)):g.nb?g.nb():l(!0)}function l(b){if(!v&&!G){if(y&&y()){if(!t){w();return}}else t=
|
||||
!1;v=!0;try{var c=B,m=F,f=I?p:!F;a.k.xb({La:function(a,b){G||(m&&c[b]?(e(b,a,c[b]),delete c[b],--m):B[b]||e(b,a,s?{da:a}:a.U(h)))},w:g,Ca:f});B={};F=0;try{var l=d?A.call(d):A()}finally{a.k.end(),m&&!s&&a.a.A(c,function(a,b){b.p&&b.p()}),r=!1}g.Wa(n,l)&&(s||q(n,"beforeChange"),n=l,s?g.Yb():b&&q(n));f&&q(n,"awake")}finally{v=!1}F||w()}}function g(){if(0<arguments.length){if("function"===typeof C)C.apply(d,arguments);else throw Error("Cannot write a value to a ko.computed unless you specify a 'write' option. If you wish to read the current value, don't pass any parameters.");
|
||||
return this}a.k.Ob(g);(r||s&&f())&&l();return n}function m(){(r&&!F||s&&f())&&l();return n}function x(){return r||0<F}function q(a,b){g.notifySubscribers(a,b)}var n,r=!0,v=!1,t=!1,G=!1,A=b,I=!1,s=!1;A&&"object"==typeof A?(c=A,A=c.read):(c=c||{},A||(A=c.read));if("function"!=typeof A)throw Error("Pass a function that returns the value of the ko.computed");var C=c.write,D=c.disposeWhenNodeIsRemoved||c.q||null,u=c.disposeWhen||c.Pa,y=u,w=k,B={},F=0,z=null;d||(d=c.owner);a.Q.call(g);a.a.Ga(g,a.j.fn);
|
||||
g.B=m;g.oa=function(){return F};g.qc="function"===typeof C;g.p=function(){w()};g.$=x;var T=g.Za;g.Za=function(a){T.call(g,a);g.nb=function(){g.pb(n);r=!0;g.qb(g)}};c.pure?(s=I=!0,g.ja=function(b){if(!G&&s&&"change"==b){s=!1;if(r||f())B=null,F=0,r=!0,l();else{var c=[];a.a.A(B,function(a,b){c[b.sa]=a});a.a.o(c,function(a,b){var c=B[a],g=c.da.U(h);g.sa=b;g.ea=c.ea;B[a]=g})}G||q(n,"awake")}},g.ua=function(b){G||"change"!=b||g.Ba("change")||(a.a.A(B,function(a,b){b.p&&(B[a]={da:b.da,sa:b.sa,ea:b.ea},b.p())}),
|
||||
s=!0,q(p,"asleep"))},g.bc=g.Aa,g.Aa=function(){s&&(r||f())&&l();return g.bc()}):c.deferEvaluation&&(g.ja=function(a){"change"!=a&&"beforeChange"!=a||m()});a.D(g,"peek",g.B);a.D(g,"dispose",g.p);a.D(g,"isActive",g.$);a.D(g,"getDependenciesCount",g.oa);D&&(t=!0,D.nodeType&&(y=function(){return!a.a.Qa(D)||u&&u()}));s||c.deferEvaluation||l();D&&x()&&D.nodeType&&(w=function(){a.a.C.Pb(D,w);k()},a.a.C.fa(D,w));return g};a.sc=function(b){return a.Ta(b,a.j)};z=a.r.Ac;a.j[z]=a.r;a.j.fn={equalityComparer:J};
|
||||
a.j.fn[z]=a.j;a.a.za&&a.a.Fa(a.j.fn,a.Q.fn);a.b("dependentObservable",a.j);a.b("computed",a.j);a.b("isComputed",a.sc);a.Nb=function(b,d){if("function"===typeof b)return a.w(b,d,{pure:!0});b=a.a.extend({},b);b.pure=!0;return a.w(b,d)};a.b("pureComputed",a.Nb);(function(){function b(a,f,k){k=k||new c;a=f(a);if("object"!=typeof a||null===a||a===p||a instanceof Date||a instanceof String||a instanceof Number||a instanceof Boolean)return a;var h=a instanceof Array?[]:{};k.save(a,h);d(a,function(c){var g=
|
||||
f(a[c]);switch(typeof g){case "boolean":case "number":case "string":case "function":h[c]=g;break;case "object":case "undefined":var d=k.get(g);h[c]=d!==p?d:b(g,f,k)}});return h}function d(a,b){if(a instanceof Array){for(var c=0;c<a.length;c++)b(c);"function"==typeof a.toJSON&&b("toJSON")}else for(c in a)b(c)}function c(){this.keys=[];this.mb=[]}a.Vb=function(c){if(0==arguments.length)throw Error("When calling ko.toJS, pass the object you want to convert.");return b(c,function(b){for(var c=0;a.F(b)&&
|
||||
10>c;c++)b=b();return b})};a.toJSON=function(b,c,d){b=a.Vb(b);return a.a.jb(b,c,d)};c.prototype={save:function(b,c){var d=a.a.m(this.keys,b);0<=d?this.mb[d]=c:(this.keys.push(b),this.mb.push(c))},get:function(b){b=a.a.m(this.keys,b);return 0<=b?this.mb[b]:p}}})();a.b("toJS",a.Vb);a.b("toJSON",a.toJSON);(function(){a.i={s:function(b){switch(a.a.v(b)){case "option":return!0===b.__ko__hasDomDataOptionValue__?a.a.f.get(b,a.d.options.ab):7>=a.a.M?b.getAttributeNode("value")&&b.getAttributeNode("value").specified?
|
||||
b.value:b.text:b.value;case "select":return 0<=b.selectedIndex?a.i.s(b.options[b.selectedIndex]):p;default:return b.value}},Y:function(b,d,c){switch(a.a.v(b)){case "option":switch(typeof d){case "string":a.a.f.set(b,a.d.options.ab,p);"__ko__hasDomDataOptionValue__"in b&&delete b.__ko__hasDomDataOptionValue__;b.value=d;break;default:a.a.f.set(b,a.d.options.ab,d),b.__ko__hasDomDataOptionValue__=!0,b.value="number"===typeof d?d:""}break;case "select":if(""===d||null===d)d=p;for(var e=-1,f=0,k=b.options.length,
|
||||
h;f<k;++f)if(h=a.i.s(b.options[f]),h==d||""==h&&d===p){e=f;break}if(c||0<=e||d===p&&1<b.size)b.selectedIndex=e;break;default:if(null===d||d===p)d="";b.value=d}}}})();a.b("selectExtensions",a.i);a.b("selectExtensions.readValue",a.i.s);a.b("selectExtensions.writeValue",a.i.Y);a.h=function(){function b(b){b=a.a.ib(b);123===b.charCodeAt(0)&&(b=b.slice(1,-1));var c=[],d=b.match(e),x,h=[],n=0;if(d){d.push(",");for(var r=0,v;v=d[r];++r){var t=v.charCodeAt(0);if(44===t){if(0>=n){c.push(x&&h.length?{key:x,
|
||||
value:h.join("")}:{unknown:x||h.join("")});x=n=0;h=[];continue}}else if(58===t){if(!n&&!x&&1===h.length){x=h.pop();continue}}else 47===t&&r&&1<v.length?(t=d[r-1].match(f))&&!k[t[0]]&&(b=b.substr(b.indexOf(v)+1),d=b.match(e),d.push(","),r=-1,v="/"):40===t||123===t||91===t?++n:41===t||125===t||93===t?--n:x||h.length||34!==t&&39!==t||(v=v.slice(1,-1));h.push(v)}}return c}var d=["true","false","null","undefined"],c=/^(?:[$_a-z][$\w]*|(.+)(\.\s*[$_a-z][$\w]*|\[.+\]))$/i,e=RegExp("\"(?:[^\"\\\\]|\\\\.)*\"|'(?:[^'\\\\]|\\\\.)*'|/(?:[^/\\\\]|\\\\.)*/w*|[^\\s:,/][^,\"'{}()/:[\\]]*[^\\s,\"'{}()/:[\\]]|[^\\s]",
|
||||
"g"),f=/[\])"'A-Za-z0-9_$]+$/,k={"in":1,"return":1,"typeof":1},h={};return{ka:[],V:h,bb:b,Ea:function(e,g){function m(b,g){var e;if(!r){var l=a.getBindingHandler(b);if(l&&l.preprocess&&!(g=l.preprocess(g,b,m)))return;if(l=h[b])e=g,0<=a.a.m(d,e)?e=!1:(l=e.match(c),e=null===l?!1:l[1]?"Object("+l[1]+")"+l[2]:e),l=e;l&&k.push("'"+b+"':function(_z){"+e+"=_z}")}n&&(g="function(){return "+g+" }");f.push("'"+b+"':"+g)}g=g||{};var f=[],k=[],n=g.valueAccessors,r=g.bindingParams,v="string"===typeof e?b(e):e;
|
||||
a.a.o(v,function(a){m(a.key||a.unknown,a.value)});k.length&&m("_ko_property_writers","{"+k.join(",")+" }");return f.join(",")},vc:function(a,b){for(var c=0;c<a.length;c++)if(a[c].key==b)return!0;return!1},ra:function(b,c,d,e,f){if(b&&a.F(b))!a.Da(b)||f&&b.B()===e||b(e);else if((b=c.get("_ko_property_writers"))&&b[d])b[d](e)}}}();a.b("expressionRewriting",a.h);a.b("expressionRewriting.bindingRewriteValidators",a.h.ka);a.b("expressionRewriting.parseObjectLiteral",a.h.bb);a.b("expressionRewriting.preProcessBindings",
|
||||
a.h.Ea);a.b("expressionRewriting._twoWayBindings",a.h.V);a.b("jsonExpressionRewriting",a.h);a.b("jsonExpressionRewriting.insertPropertyAccessorsIntoJson",a.h.Ea);(function(){function b(a){return 8==a.nodeType&&k.test(f?a.text:a.nodeValue)}function d(a){return 8==a.nodeType&&h.test(f?a.text:a.nodeValue)}function c(a,c){for(var e=a,f=1,l=[];e=e.nextSibling;){if(d(e)&&(f--,0===f))return l;l.push(e);b(e)&&f++}if(!c)throw Error("Cannot find closing comment tag to match: "+a.nodeValue);return null}function e(a,
|
||||
b){var d=c(a,b);return d?0<d.length?d[d.length-1].nextSibling:a.nextSibling:null}var f=w&&"\x3c!--test--\x3e"===w.createComment("test").text,k=f?/^\x3c!--\s*ko(?:\s+([\s\S]+))?\s*--\x3e$/:/^\s*ko(?:\s+([\s\S]+))?\s*$/,h=f?/^\x3c!--\s*\/ko\s*--\x3e$/:/^\s*\/ko\s*$/,l={ul:!0,ol:!0};a.e={R:{},childNodes:function(a){return b(a)?c(a):a.childNodes},ma:function(c){if(b(c)){c=a.e.childNodes(c);for(var d=0,e=c.length;d<e;d++)a.removeNode(c[d])}else a.a.Ra(c)},T:function(c,d){if(b(c)){a.e.ma(c);for(var e=c.nextSibling,
|
||||
f=0,l=d.length;f<l;f++)e.parentNode.insertBefore(d[f],e)}else a.a.T(c,d)},Mb:function(a,c){b(a)?a.parentNode.insertBefore(c,a.nextSibling):a.firstChild?a.insertBefore(c,a.firstChild):a.appendChild(c)},Fb:function(c,d,e){e?b(c)?c.parentNode.insertBefore(d,e.nextSibling):e.nextSibling?c.insertBefore(d,e.nextSibling):c.appendChild(d):a.e.Mb(c,d)},firstChild:function(a){return b(a)?!a.nextSibling||d(a.nextSibling)?null:a.nextSibling:a.firstChild},nextSibling:function(a){b(a)&&(a=e(a));return a.nextSibling&&
|
||||
d(a.nextSibling)?null:a.nextSibling},oc:b,Fc:function(a){return(a=(f?a.text:a.nodeValue).match(k))?a[1]:null},Kb:function(c){if(l[a.a.v(c)]){var m=c.firstChild;if(m){do if(1===m.nodeType){var f;f=m.firstChild;var h=null;if(f){do if(h)h.push(f);else if(b(f)){var k=e(f,!0);k?f=k:h=[f]}else d(f)&&(h=[f]);while(f=f.nextSibling)}if(f=h)for(h=m.nextSibling,k=0;k<f.length;k++)h?c.insertBefore(f[k],h):c.appendChild(f[k])}while(m=m.nextSibling)}}}}})();a.b("virtualElements",a.e);a.b("virtualElements.allowedBindings",
|
||||
a.e.R);a.b("virtualElements.emptyNode",a.e.ma);a.b("virtualElements.insertAfter",a.e.Fb);a.b("virtualElements.prepend",a.e.Mb);a.b("virtualElements.setDomNodeChildren",a.e.T);(function(){a.L=function(){this.ec={}};a.a.extend(a.L.prototype,{nodeHasBindings:function(b){switch(b.nodeType){case 1:return null!=b.getAttribute("data-bind")||a.g.getComponentNameForNode(b);case 8:return a.e.oc(b);default:return!1}},getBindings:function(b,d){var c=this.getBindingsString(b,d),c=c?this.parseBindingsString(c,
|
||||
d,b):null;return a.g.sb(c,b,d,!1)},getBindingAccessors:function(b,d){var c=this.getBindingsString(b,d),c=c?this.parseBindingsString(c,d,b,{valueAccessors:!0}):null;return a.g.sb(c,b,d,!0)},getBindingsString:function(b){switch(b.nodeType){case 1:return b.getAttribute("data-bind");case 8:return a.e.Fc(b);default:return null}},parseBindingsString:function(b,d,c,e){try{var f=this.ec,k=b+(e&&e.valueAccessors||""),h;if(!(h=f[k])){var l,g="with($context){with($data||{}){return{"+a.h.Ea(b,e)+"}}}";l=new Function("$context",
|
||||
"$element",g);h=f[k]=l}return h(d,c)}catch(m){throw m.message="Unable to parse bindings.\nBindings value: "+b+"\nMessage: "+m.message,m;}}});a.L.instance=new a.L})();a.b("bindingProvider",a.L);(function(){function b(a){return function(){return a}}function d(a){return a()}function c(b){return a.a.pa(a.k.u(b),function(a,c){return function(){return b()[c]}})}function e(d,g,e){return"function"===typeof d?c(d.bind(null,g,e)):a.a.pa(d,b)}function f(a,b){return c(this.getBindings.bind(this,a,b))}function k(b,
|
||||
c,d){var g,e=a.e.firstChild(c),f=a.L.instance,m=f.preprocessNode;if(m){for(;g=e;)e=a.e.nextSibling(g),m.call(f,g);e=a.e.firstChild(c)}for(;g=e;)e=a.e.nextSibling(g),h(b,g,d)}function h(b,c,d){var e=!0,f=1===c.nodeType;f&&a.e.Kb(c);if(f&&d||a.L.instance.nodeHasBindings(c))e=g(c,null,b,d).shouldBindDescendants;e&&!x[a.a.v(c)]&&k(b,c,!f)}function l(b){var c=[],d={},g=[];a.a.A(b,function I(e){if(!d[e]){var f=a.getBindingHandler(e);f&&(f.after&&(g.push(e),a.a.o(f.after,function(c){if(b[c]){if(-1!==a.a.m(g,
|
||||
c))throw Error("Cannot combine the following bindings, because they have a cyclic dependency: "+g.join(", "));I(c)}}),g.length--),c.push({key:e,Eb:f}));d[e]=!0}});return c}function g(b,c,g,e){var m=a.a.f.get(b,q);if(!c){if(m)throw Error("You cannot apply bindings multiple times to the same element.");a.a.f.set(b,q,!0)}!m&&e&&a.Tb(b,g);var h;if(c&&"function"!==typeof c)h=c;else{var k=a.L.instance,x=k.getBindingAccessors||f,n=a.j(function(){(h=c?c(g,b):x.call(k,b,g))&&g.K&&g.K();return h},null,{q:b});
|
||||
h&&n.$()||(n=null)}var u;if(h){var w=n?function(a){return function(){return d(n()[a])}}:function(a){return h[a]},y=function(){return a.a.pa(n?n():h,d)};y.get=function(a){return h[a]&&d(w(a))};y.has=function(a){return a in h};e=l(h);a.a.o(e,function(c){var d=c.Eb.init,e=c.Eb.update,f=c.key;if(8===b.nodeType&&!a.e.R[f])throw Error("The binding '"+f+"' cannot be used with virtual elements");try{"function"==typeof d&&a.k.u(function(){var a=d(b,w(f),y,g.$data,g);if(a&&a.controlsDescendantBindings){if(u!==
|
||||
p)throw Error("Multiple bindings ("+u+" and "+f+") are trying to control descendant bindings of the same element. You cannot use these bindings together on the same element.");u=f}}),"function"==typeof e&&a.j(function(){e(b,w(f),y,g.$data,g)},null,{q:b})}catch(m){throw m.message='Unable to process binding "'+f+": "+h[f]+'"\nMessage: '+m.message,m;}})}return{shouldBindDescendants:u===p}}function m(b){return b&&b instanceof a.N?b:new a.N(b)}a.d={};var x={script:!0,textarea:!0};a.getBindingHandler=function(b){return a.d[b]};
|
||||
a.N=function(b,c,d,g){var e=this,f="function"==typeof b&&!a.F(b),m,l=a.j(function(){var m=f?b():b,h=a.a.c(m);c?(c.K&&c.K(),a.a.extend(e,c),l&&(e.K=l)):(e.$parents=[],e.$root=h,e.ko=a);e.$rawData=m;e.$data=h;d&&(e[d]=h);g&&g(e,c,h);return e.$data},null,{Pa:function(){return m&&!a.a.tb(m)},q:!0});l.$()&&(e.K=l,l.equalityComparer=null,m=[],l.Zb=function(b){m.push(b);a.a.C.fa(b,function(b){a.a.ya(m,b);m.length||(l.p(),e.K=l=p)})})};a.N.prototype.createChildContext=function(b,c,d){return new a.N(b,this,
|
||||
c,function(a,b){a.$parentContext=b;a.$parent=b.$data;a.$parents=(b.$parents||[]).slice(0);a.$parents.unshift(a.$parent);d&&d(a)})};a.N.prototype.extend=function(b){return new a.N(this.K||this.$data,this,null,function(c,d){c.$rawData=d.$rawData;a.a.extend(c,"function"==typeof b?b():b)})};var q=a.a.f.I(),n=a.a.f.I();a.Tb=function(b,c){if(2==arguments.length)a.a.f.set(b,n,c),c.K&&c.K.Zb(b);else return a.a.f.get(b,n)};a.va=function(b,c,d){1===b.nodeType&&a.e.Kb(b);return g(b,c,m(d),!0)};a.cc=function(b,
|
||||
c,d){d=m(d);return a.va(b,e(c,d,b),d)};a.Ja=function(a,b){1!==b.nodeType&&8!==b.nodeType||k(m(a),b,!0)};a.ub=function(a,b){!u&&y.jQuery&&(u=y.jQuery);if(b&&1!==b.nodeType&&8!==b.nodeType)throw Error("ko.applyBindings: first parameter should be your view model; second parameter should be a DOM node");b=b||y.document.body;h(m(a),b,!0)};a.Oa=function(b){switch(b.nodeType){case 1:case 8:var c=a.Tb(b);if(c)return c;if(b.parentNode)return a.Oa(b.parentNode)}return p};a.gc=function(b){return(b=a.Oa(b))?
|
||||
b.$data:p};a.b("bindingHandlers",a.d);a.b("applyBindings",a.ub);a.b("applyBindingsToDescendants",a.Ja);a.b("applyBindingAccessorsToNode",a.va);a.b("applyBindingsToNode",a.cc);a.b("contextFor",a.Oa);a.b("dataFor",a.gc)})();(function(b){function d(d,e){var g=f.hasOwnProperty(d)?f[d]:b,m;g?g.U(e):(g=f[d]=new a.Q,g.U(e),c(d,function(a,b){var c=!(!b||!b.synchronous);k[d]={definition:a,tc:c};delete f[d];m||c?g.notifySubscribers(a):setTimeout(function(){g.notifySubscribers(a)},0)}),m=!0)}function c(a,b){e("getConfig",
|
||||
[a],function(c){c?e("loadComponent",[a,c],function(a){b(a,c)}):b(null,null)})}function e(c,d,g,f){f||(f=a.g.loaders.slice(0));var k=f.shift();if(k){var q=k[c];if(q){var n=!1;if(q.apply(k,d.concat(function(a){n?g(null):null!==a?g(a):e(c,d,g,f)}))!==b&&(n=!0,!k.suppressLoaderExceptions))throw Error("Component loaders must supply values by invoking the callback, not by returning values synchronously.");}else e(c,d,g,f)}else g(null)}var f={},k={};a.g={get:function(c,e){var g=k.hasOwnProperty(c)?k[c]:
|
||||
b;g?g.tc?a.k.u(function(){e(g.definition)}):setTimeout(function(){e(g.definition)},0):d(c,e)},zb:function(a){delete k[a]},ob:e};a.g.loaders=[];a.b("components",a.g);a.b("components.get",a.g.get);a.b("components.clearCachedDefinition",a.g.zb)})();(function(){function b(b,c,d,e){function k(){0===--v&&e(h)}var h={},v=2,t=d.template;d=d.viewModel;t?f(c,t,function(c){a.g.ob("loadTemplate",[b,c],function(a){h.template=a;k()})}):k();d?f(c,d,function(c){a.g.ob("loadViewModel",[b,c],function(a){h[l]=a;k()})}):
|
||||
k()}function d(a,b,c){if("function"===typeof b)c(function(a){return new b(a)});else if("function"===typeof b[l])c(b[l]);else if("instance"in b){var e=b.instance;c(function(){return e})}else"viewModel"in b?d(a,b.viewModel,c):a("Unknown viewModel value: "+b)}function c(b){switch(a.a.v(b)){case "script":return a.a.ca(b.text);case "textarea":return a.a.ca(b.value);case "template":if(e(b.content))return a.a.la(b.content.childNodes)}return a.a.la(b.childNodes)}function e(a){return y.DocumentFragment?a instanceof
|
||||
DocumentFragment:a&&11===a.nodeType}function f(a,b,c){"string"===typeof b.require?O||y.require?(O||y.require)([b.require],c):a("Uses require, but no AMD loader is present"):c(b)}function k(a){return function(b){throw Error("Component '"+a+"': "+b);}}var h={};a.g.register=function(b,c){if(!c)throw Error("Invalid configuration for "+b);if(a.g.Xa(b))throw Error("Component "+b+" is already registered");h[b]=c};a.g.Xa=function(a){return a in h};a.g.Ec=function(b){delete h[b];a.g.zb(b)};a.g.Ab={getConfig:function(a,
|
||||
b){b(h.hasOwnProperty(a)?h[a]:null)},loadComponent:function(a,c,d){var e=k(a);f(e,c,function(c){b(a,e,c,d)})},loadTemplate:function(b,d,f){b=k(b);if("string"===typeof d)f(a.a.ca(d));else if(d instanceof Array)f(d);else if(e(d))f(a.a.O(d.childNodes));else if(d.element)if(d=d.element,y.HTMLElement?d instanceof HTMLElement:d&&d.tagName&&1===d.nodeType)f(c(d));else if("string"===typeof d){var l=w.getElementById(d);l?f(c(l)):b("Cannot find element with ID "+d)}else b("Unknown element type: "+d);else b("Unknown template value: "+
|
||||
d)},loadViewModel:function(a,b,c){d(k(a),b,c)}};var l="createViewModel";a.b("components.register",a.g.register);a.b("components.isRegistered",a.g.Xa);a.b("components.unregister",a.g.Ec);a.b("components.defaultLoader",a.g.Ab);a.g.loaders.push(a.g.Ab);a.g.$b=h})();(function(){function b(b,e){var f=b.getAttribute("params");if(f){var f=d.parseBindingsString(f,e,b,{valueAccessors:!0,bindingParams:!0}),f=a.a.pa(f,function(d){return a.w(d,null,{q:b})}),k=a.a.pa(f,function(d){var e=d.B();return d.$()?a.w({read:function(){return a.a.c(d())},
|
||||
write:a.Da(e)&&function(a){d()(a)},q:b}):e});k.hasOwnProperty("$raw")||(k.$raw=f);return k}return{$raw:{}}}a.g.getComponentNameForNode=function(b){b=a.a.v(b);return a.g.Xa(b)&&b};a.g.sb=function(c,d,f,k){if(1===d.nodeType){var h=a.g.getComponentNameForNode(d);if(h){c=c||{};if(c.component)throw Error('Cannot use the "component" binding on a custom element matching a component');var l={name:h,params:b(d,f)};c.component=k?function(){return l}:l}}return c};var d=new a.L;9>a.a.M&&(a.g.register=function(a){return function(b){w.createElement(b);
|
||||
return a.apply(this,arguments)}}(a.g.register),w.createDocumentFragment=function(b){return function(){var d=b(),f=a.g.$b,k;for(k in f)f.hasOwnProperty(k)&&d.createElement(k);return d}}(w.createDocumentFragment))})();(function(b){function d(b,c,d){c=c.template;if(!c)throw Error("Component '"+b+"' has no template");b=a.a.la(c);a.e.T(d,b)}function c(a,b,c,d){var e=a.createViewModel;return e?e.call(a,d,{element:b,templateNodes:c}):d}var e=0;a.d.component={init:function(f,k,h,l,g){function m(){var a=x&&
|
||||
x.dispose;"function"===typeof a&&a.call(x);q=null}var x,q,n=a.a.O(a.e.childNodes(f));a.a.C.fa(f,m);a.w(function(){var l=a.a.c(k()),h,t;"string"===typeof l?h=l:(h=a.a.c(l.name),t=a.a.c(l.params));if(!h)throw Error("No component name specified");var p=q=++e;a.g.get(h,function(e){if(q===p){m();if(!e)throw Error("Unknown component '"+h+"'");d(h,e,f);var l=c(e,f,n,t);e=g.createChildContext(l,b,function(a){a.$component=l;a.$componentTemplateNodes=n});x=l;a.Ja(e,f)}})},null,{q:f});return{controlsDescendantBindings:!0}}};
|
||||
a.e.R.component=!0})();var P={"class":"className","for":"htmlFor"};a.d.attr={update:function(b,d){var c=a.a.c(d())||{};a.a.A(c,function(c,d){d=a.a.c(d);var k=!1===d||null===d||d===p;k&&b.removeAttribute(c);8>=a.a.M&&c in P?(c=P[c],k?b.removeAttribute(c):b[c]=d):k||b.setAttribute(c,d.toString());"name"===c&&a.a.Rb(b,k?"":d.toString())})}};(function(){a.d.checked={after:["value","attr"],init:function(b,d,c){function e(){var e=b.checked,f=x?k():e;if(!a.Z.Ca()&&(!l||e)){var h=a.k.u(d);g?m!==f?(e&&(a.a.ga(h,
|
||||
f,!0),a.a.ga(h,m,!1)),m=f):a.a.ga(h,f,e):a.h.ra(h,c,"checked",f,!0)}}function f(){var c=a.a.c(d());b.checked=g?0<=a.a.m(c,k()):h?c:k()===c}var k=a.Nb(function(){return c.has("checkedValue")?a.a.c(c.get("checkedValue")):c.has("value")?a.a.c(c.get("value")):b.value}),h="checkbox"==b.type,l="radio"==b.type;if(h||l){var g=h&&a.a.c(d())instanceof Array,m=g?k():p,x=l||g;l&&!b.name&&a.d.uniqueName.init(b,function(){return!0});a.w(e,null,{q:b});a.a.n(b,"click",e);a.w(f,null,{q:b})}}};a.h.V.checked=!0;a.d.checkedValue=
|
||||
{update:function(b,d){b.value=a.a.c(d())}}})();a.d.css={update:function(b,d){var c=a.a.c(d());null!==c&&"object"==typeof c?a.a.A(c,function(c,d){d=a.a.c(d);a.a.Ia(b,c,d)}):(c=String(c||""),a.a.Ia(b,b.__ko__cssValue,!1),b.__ko__cssValue=c,a.a.Ia(b,c,!0))}};a.d.enable={update:function(b,d){var c=a.a.c(d());c&&b.disabled?b.removeAttribute("disabled"):c||b.disabled||(b.disabled=!0)}};a.d.disable={update:function(b,d){a.d.enable.update(b,function(){return!a.a.c(d())})}};a.d.event={init:function(b,d,c,
|
||||
e,f){var k=d()||{};a.a.A(k,function(h){"string"==typeof h&&a.a.n(b,h,function(b){var g,m=d()[h];if(m){try{var k=a.a.O(arguments);e=f.$data;k.unshift(e);g=m.apply(e,k)}finally{!0!==g&&(b.preventDefault?b.preventDefault():b.returnValue=!1)}!1===c.get(h+"Bubble")&&(b.cancelBubble=!0,b.stopPropagation&&b.stopPropagation())}})})}};a.d.foreach={Ib:function(b){return function(){var d=b(),c=a.a.cb(d);if(!c||"number"==typeof c.length)return{foreach:d,templateEngine:a.P.Va};a.a.c(d);return{foreach:c.data,as:c.as,
|
||||
includeDestroyed:c.includeDestroyed,afterAdd:c.afterAdd,beforeRemove:c.beforeRemove,afterRender:c.afterRender,beforeMove:c.beforeMove,afterMove:c.afterMove,templateEngine:a.P.Va}}},init:function(b,d){return a.d.template.init(b,a.d.foreach.Ib(d))},update:function(b,d,c,e,f){return a.d.template.update(b,a.d.foreach.Ib(d),c,e,f)}};a.h.ka.foreach=!1;a.e.R.foreach=!0;a.d.hasfocus={init:function(b,d,c){function e(e){b.__ko_hasfocusUpdating=!0;var f=b.ownerDocument;if("activeElement"in f){var g;try{g=f.activeElement}catch(m){g=
|
||||
f.body}e=g===b}f=d();a.h.ra(f,c,"hasfocus",e,!0);b.__ko_hasfocusLastValue=e;b.__ko_hasfocusUpdating=!1}var f=e.bind(null,!0),k=e.bind(null,!1);a.a.n(b,"focus",f);a.a.n(b,"focusin",f);a.a.n(b,"blur",k);a.a.n(b,"focusout",k)},update:function(b,d){var c=!!a.a.c(d());b.__ko_hasfocusUpdating||b.__ko_hasfocusLastValue===c||(c?b.focus():b.blur(),a.k.u(a.a.qa,null,[b,c?"focusin":"focusout"]))}};a.h.V.hasfocus=!0;a.d.hasFocus=a.d.hasfocus;a.h.V.hasFocus=!0;a.d.html={init:function(){return{controlsDescendantBindings:!0}},
|
||||
update:function(b,d){a.a.gb(b,d())}};K("if");K("ifnot",!1,!0);K("with",!0,!1,function(a,d){return a.createChildContext(d)});var L={};a.d.options={init:function(b){if("select"!==a.a.v(b))throw Error("options binding applies only to SELECT elements");for(;0<b.length;)b.remove(0);return{controlsDescendantBindings:!0}},update:function(b,d,c){function e(){return a.a.xa(b.options,function(a){return a.selected})}function f(a,b,c){var d=typeof b;return"function"==d?b(a):"string"==d?a[b]:c}function k(d,e){if(r&&
|
||||
m)a.i.Y(b,a.a.c(c.get("value")),!0);else if(n.length){var g=0<=a.a.m(n,a.i.s(e[0]));a.a.Sb(e[0],g);r&&!g&&a.k.u(a.a.qa,null,[b,"change"])}}var h=b.multiple,l=0!=b.length&&h?b.scrollTop:null,g=a.a.c(d()),m=c.get("valueAllowUnset")&&c.has("value"),x=c.get("optionsIncludeDestroyed");d={};var q,n=[];m||(h?n=a.a.Ka(e(),a.i.s):0<=b.selectedIndex&&n.push(a.i.s(b.options[b.selectedIndex])));g&&("undefined"==typeof g.length&&(g=[g]),q=a.a.xa(g,function(b){return x||b===p||null===b||!a.a.c(b._destroy)}),c.has("optionsCaption")&&
|
||||
(g=a.a.c(c.get("optionsCaption")),null!==g&&g!==p&&q.unshift(L)));var r=!1;d.beforeRemove=function(a){b.removeChild(a)};g=k;c.has("optionsAfterRender")&&"function"==typeof c.get("optionsAfterRender")&&(g=function(b,d){k(0,d);a.k.u(c.get("optionsAfterRender"),null,[d[0],b!==L?b:p])});a.a.fb(b,q,function(d,e,g){g.length&&(n=!m&&g[0].selected?[a.i.s(g[0])]:[],r=!0);e=b.ownerDocument.createElement("option");d===L?(a.a.Ha(e,c.get("optionsCaption")),a.i.Y(e,p)):(g=f(d,c.get("optionsValue"),d),a.i.Y(e,a.a.c(g)),
|
||||
d=f(d,c.get("optionsText"),g),a.a.Ha(e,d));return[e]},d,g);a.k.u(function(){m?a.i.Y(b,a.a.c(c.get("value")),!0):(h?n.length&&e().length<n.length:n.length&&0<=b.selectedIndex?a.i.s(b.options[b.selectedIndex])!==n[0]:n.length||0<=b.selectedIndex)&&a.a.qa(b,"change")});a.a.kc(b);l&&20<Math.abs(l-b.scrollTop)&&(b.scrollTop=l)}};a.d.options.ab=a.a.f.I();a.d.selectedOptions={after:["options","foreach"],init:function(b,d,c){a.a.n(b,"change",function(){var e=d(),f=[];a.a.o(b.getElementsByTagName("option"),
|
||||
function(b){b.selected&&f.push(a.i.s(b))});a.h.ra(e,c,"selectedOptions",f)})},update:function(b,d){if("select"!=a.a.v(b))throw Error("values binding applies only to SELECT elements");var c=a.a.c(d());c&&"number"==typeof c.length&&a.a.o(b.getElementsByTagName("option"),function(b){var d=0<=a.a.m(c,a.i.s(b));a.a.Sb(b,d)})}};a.h.V.selectedOptions=!0;a.d.style={update:function(b,d){var c=a.a.c(d()||{});a.a.A(c,function(c,d){d=a.a.c(d);if(null===d||d===p||!1===d)d="";b.style[c]=d})}};a.d.submit={init:function(b,
|
||||
d,c,e,f){if("function"!=typeof d())throw Error("The value for a submit binding must be a function");a.a.n(b,"submit",function(a){var c,e=d();try{c=e.call(f.$data,b)}finally{!0!==c&&(a.preventDefault?a.preventDefault():a.returnValue=!1)}})}};a.d.text={init:function(){return{controlsDescendantBindings:!0}},update:function(b,d){a.a.Ha(b,d())}};a.e.R.text=!0;(function(){if(y&&y.navigator)var b=function(a){if(a)return parseFloat(a[1])},d=y.opera&&y.opera.version&&parseInt(y.opera.version()),c=y.navigator.userAgent,
|
||||
e=b(c.match(/^(?:(?!chrome).)*version\/([^ ]*) safari/i)),f=b(c.match(/Firefox\/([^ ]*)/));if(10>a.a.M)var k=a.a.f.I(),h=a.a.f.I(),l=function(b){var c=this.activeElement;(c=c&&a.a.f.get(c,h))&&c(b)},g=function(b,c){var d=b.ownerDocument;a.a.f.get(d,k)||(a.a.f.set(d,k,!0),a.a.n(d,"selectionchange",l));a.a.f.set(b,h,c)};a.d.textInput={init:function(b,c,l){function h(c,d){a.a.n(b,c,d)}function k(){var d=a.a.c(c());if(null===d||d===p)d="";w!==p&&d===w?setTimeout(k,4):b.value!==d&&(u=d,b.value=d)}function v(){A||
|
||||
(w=b.value,A=setTimeout(t,4))}function t(){clearTimeout(A);w=A=p;var d=b.value;u!==d&&(u=d,a.h.ra(c(),l,"textInput",d))}var u=b.value,A,w;10>a.a.M?(h("propertychange",function(a){"value"===a.propertyName&&t()}),8==a.a.M&&(h("keyup",t),h("keydown",t)),8<=a.a.M&&(g(b,t),h("dragend",v))):(h("input",t),5>e&&"textarea"===a.a.v(b)?(h("keydown",v),h("paste",v),h("cut",v)):11>d?h("keydown",v):4>f&&(h("DOMAutoComplete",t),h("dragdrop",t),h("drop",t)));h("change",t);a.w(k,null,{q:b})}};a.h.V.textInput=!0;a.d.textinput=
|
||||
{preprocess:function(a,b,c){c("textInput",a)}}})();a.d.uniqueName={init:function(b,d){if(d()){var c="ko_unique_"+ ++a.d.uniqueName.fc;a.a.Rb(b,c)}}};a.d.uniqueName.fc=0;a.d.value={after:["options","foreach"],init:function(b,d,c){if("input"!=b.tagName.toLowerCase()||"checkbox"!=b.type&&"radio"!=b.type){var e=["change"],f=c.get("valueUpdate"),k=!1,h=null;f&&("string"==typeof f&&(f=[f]),a.a.ia(e,f),e=a.a.wb(e));var l=function(){h=null;k=!1;var e=d(),g=a.i.s(b);a.h.ra(e,c,"value",g)};!a.a.M||"input"!=
|
||||
b.tagName.toLowerCase()||"text"!=b.type||"off"==b.autocomplete||b.form&&"off"==b.form.autocomplete||-1!=a.a.m(e,"propertychange")||(a.a.n(b,"propertychange",function(){k=!0}),a.a.n(b,"focus",function(){k=!1}),a.a.n(b,"blur",function(){k&&l()}));a.a.o(e,function(c){var d=l;a.a.Dc(c,"after")&&(d=function(){h=a.i.s(b);setTimeout(l,0)},c=c.substring(5));a.a.n(b,c,d)});var g=function(){var e=a.a.c(d()),f=a.i.s(b);if(null!==h&&e===h)setTimeout(g,0);else if(e!==f)if("select"===a.a.v(b)){var l=c.get("valueAllowUnset"),
|
||||
f=function(){a.i.Y(b,e,l)};f();l||e===a.i.s(b)?setTimeout(f,0):a.k.u(a.a.qa,null,[b,"change"])}else a.i.Y(b,e)};a.w(g,null,{q:b})}else a.va(b,{checkedValue:d})},update:function(){}};a.h.V.value=!0;a.d.visible={update:function(b,d){var c=a.a.c(d()),e="none"!=b.style.display;c&&!e?b.style.display="":!c&&e&&(b.style.display="none")}};(function(b){a.d[b]={init:function(d,c,e,f,k){return a.d.event.init.call(this,d,function(){var a={};a[b]=c();return a},e,f,k)}}})("click");a.J=function(){};a.J.prototype.renderTemplateSource=
|
||||
function(){throw Error("Override renderTemplateSource");};a.J.prototype.createJavaScriptEvaluatorBlock=function(){throw Error("Override createJavaScriptEvaluatorBlock");};a.J.prototype.makeTemplateSource=function(b,d){if("string"==typeof b){d=d||w;var c=d.getElementById(b);if(!c)throw Error("Cannot find template with ID "+b);return new a.t.l(c)}if(1==b.nodeType||8==b.nodeType)return new a.t.ha(b);throw Error("Unknown template type: "+b);};a.J.prototype.renderTemplate=function(a,d,c,e){a=this.makeTemplateSource(a,
|
||||
e);return this.renderTemplateSource(a,d,c,e)};a.J.prototype.isTemplateRewritten=function(a,d){return!1===this.allowTemplateRewriting?!0:this.makeTemplateSource(a,d).data("isRewritten")};a.J.prototype.rewriteTemplate=function(a,d,c){a=this.makeTemplateSource(a,c);d=d(a.text());a.text(d);a.data("isRewritten",!0)};a.b("templateEngine",a.J);a.kb=function(){function b(b,c,d,h){b=a.h.bb(b);for(var l=a.h.ka,g=0;g<b.length;g++){var m=b[g].key;if(l.hasOwnProperty(m)){var x=l[m];if("function"===typeof x){if(m=
|
||||
x(b[g].value))throw Error(m);}else if(!x)throw Error("This template engine does not support the '"+m+"' binding within its templates");}}d="ko.__tr_ambtns(function($context,$element){return(function(){return{ "+a.h.Ea(b,{valueAccessors:!0})+" } })()},'"+d.toLowerCase()+"')";return h.createJavaScriptEvaluatorBlock(d)+c}var d=/(<([a-z]+\d*)(?:\s+(?!data-bind\s*=\s*)[a-z0-9\-]+(?:=(?:\"[^\"]*\"|\'[^\']*\'|[^>]*))?)*\s+)data-bind\s*=\s*(["'])([\s\S]*?)\3/gi,c=/\x3c!--\s*ko\b\s*([\s\S]*?)\s*--\x3e/g;return{lc:function(b,
|
||||
c,d){c.isTemplateRewritten(b,d)||c.rewriteTemplate(b,function(b){return a.kb.xc(b,c)},d)},xc:function(a,f){return a.replace(d,function(a,c,d,e,m){return b(m,c,d,f)}).replace(c,function(a,c){return b(c,"\x3c!-- ko --\x3e","#comment",f)})},dc:function(b,c){return a.H.$a(function(d,h){var l=d.nextSibling;l&&l.nodeName.toLowerCase()===c&&a.va(l,b,h)})}}}();a.b("__tr_ambtns",a.kb.dc);(function(){a.t={};a.t.l=function(a){this.l=a};a.t.l.prototype.text=function(){var b=a.a.v(this.l),b="script"===b?"text":
|
||||
"textarea"===b?"value":"innerHTML";if(0==arguments.length)return this.l[b];var d=arguments[0];"innerHTML"===b?a.a.gb(this.l,d):this.l[b]=d};var b=a.a.f.I()+"_";a.t.l.prototype.data=function(c){if(1===arguments.length)return a.a.f.get(this.l,b+c);a.a.f.set(this.l,b+c,arguments[1])};var d=a.a.f.I();a.t.ha=function(a){this.l=a};a.t.ha.prototype=new a.t.l;a.t.ha.prototype.text=function(){if(0==arguments.length){var b=a.a.f.get(this.l,d)||{};b.lb===p&&b.Na&&(b.lb=b.Na.innerHTML);return b.lb}a.a.f.set(this.l,
|
||||
d,{lb:arguments[0]})};a.t.l.prototype.nodes=function(){if(0==arguments.length)return(a.a.f.get(this.l,d)||{}).Na;a.a.f.set(this.l,d,{Na:arguments[0]})};a.b("templateSources",a.t);a.b("templateSources.domElement",a.t.l);a.b("templateSources.anonymousTemplate",a.t.ha)})();(function(){function b(b,c,d){var e;for(c=a.e.nextSibling(c);b&&(e=b)!==c;)b=a.e.nextSibling(e),d(e,b)}function d(c,d){if(c.length){var e=c[0],f=c[c.length-1],h=e.parentNode,k=a.L.instance,r=k.preprocessNode;if(r){b(e,f,function(a,
|
||||
b){var c=a.previousSibling,d=r.call(k,a);d&&(a===e&&(e=d[0]||b),a===f&&(f=d[d.length-1]||c))});c.length=0;if(!e)return;e===f?c.push(e):(c.push(e,f),a.a.na(c,h))}b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.ub(d,b)});b(e,f,function(b){1!==b.nodeType&&8!==b.nodeType||a.H.Xb(b,[d])});a.a.na(c,h)}}function c(a){return a.nodeType?a:0<a.length?a[0]:null}function e(b,e,f,h,q){q=q||{};var n=(b&&c(b)||f||{}).ownerDocument,r=q.templateEngine||k;a.kb.lc(f,r,n);f=r.renderTemplate(f,h,q,n);if("number"!=
|
||||
typeof f.length||0<f.length&&"number"!=typeof f[0].nodeType)throw Error("Template engine must return an array of DOM nodes");n=!1;switch(e){case "replaceChildren":a.e.T(b,f);n=!0;break;case "replaceNode":a.a.Qb(b,f);n=!0;break;case "ignoreTargetNode":break;default:throw Error("Unknown renderMode: "+e);}n&&(d(f,h),q.afterRender&&a.k.u(q.afterRender,null,[f,h.$data]));return f}function f(b,c,d){return a.F(b)?b():"function"===typeof b?b(c,d):b}var k;a.hb=function(b){if(b!=p&&!(b instanceof a.J))throw Error("templateEngine must inherit from ko.templateEngine");
|
||||
k=b};a.eb=function(b,d,h,x,q){h=h||{};if((h.templateEngine||k)==p)throw Error("Set a template engine before calling renderTemplate");q=q||"replaceChildren";if(x){var n=c(x);return a.j(function(){var k=d&&d instanceof a.N?d:new a.N(a.a.c(d)),p=f(b,k.$data,k),k=e(x,q,p,k,h);"replaceNode"==q&&(x=k,n=c(x))},null,{Pa:function(){return!n||!a.a.Qa(n)},q:n&&"replaceNode"==q?n.parentNode:n})}return a.H.$a(function(c){a.eb(b,d,h,c,"replaceNode")})};a.Cc=function(b,c,h,k,q){function n(a,b){d(b,v);h.afterRender&&
|
||||
h.afterRender(b,a);v=null}function r(a,c){v=q.createChildContext(a,h.as,function(a){a.$index=c});var d=f(b,a,v);return e(null,"ignoreTargetNode",d,v,h)}var v;return a.j(function(){var b=a.a.c(c)||[];"undefined"==typeof b.length&&(b=[b]);b=a.a.xa(b,function(b){return h.includeDestroyed||b===p||null===b||!a.a.c(b._destroy)});a.k.u(a.a.fb,null,[k,b,r,h,n])},null,{q:k})};var h=a.a.f.I();a.d.template={init:function(b,c){var d=a.a.c(c());if("string"==typeof d||d.name)a.e.ma(b);else{if("nodes"in d){if(d=
|
||||
d.nodes||[],a.F(d))throw Error('The "nodes" option must be a plain, non-observable array.');}else d=a.e.childNodes(b);d=a.a.Jb(d);(new a.t.ha(b)).nodes(d)}return{controlsDescendantBindings:!0}},update:function(b,c,d,e,f){var k=c(),r;c=a.a.c(k);d=!0;e=null;"string"==typeof c?c={}:(k=c.name,"if"in c&&(d=a.a.c(c["if"])),d&&"ifnot"in c&&(d=!a.a.c(c.ifnot)),r=a.a.c(c.data));"foreach"in c?e=a.Cc(k||b,d&&c.foreach||[],c,b,f):d?(f="data"in c?f.createChildContext(r,c.as):f,e=a.eb(k||b,f,c,b)):a.e.ma(b);f=
|
||||
e;(r=a.a.f.get(b,h))&&"function"==typeof r.p&&r.p();a.a.f.set(b,h,f&&f.$()?f:p)}};a.h.ka.template=function(b){b=a.h.bb(b);return 1==b.length&&b[0].unknown||a.h.vc(b,"name")?null:"This template engine does not support anonymous templates nested within its templates"};a.e.R.template=!0})();a.b("setTemplateEngine",a.hb);a.b("renderTemplate",a.eb);a.a.Cb=function(a,d,c){if(a.length&&d.length){var e,f,k,h,l;for(e=f=0;(!c||e<c)&&(h=a[f]);++f){for(k=0;l=d[k];++k)if(h.value===l.value){h.moved=l.index;l.moved=
|
||||
h.index;d.splice(k,1);e=k=0;break}e+=k}}};a.a.Ma=function(){function b(b,c,e,f,k){var h=Math.min,l=Math.max,g=[],m,p=b.length,q,n=c.length,r=n-p||1,v=p+n+1,t,u,w;for(m=0;m<=p;m++)for(u=t,g.push(t=[]),w=h(n,m+r),q=l(0,m-1);q<=w;q++)t[q]=q?m?b[m-1]===c[q-1]?u[q-1]:h(u[q]||v,t[q-1]||v)+1:q+1:m+1;h=[];l=[];r=[];m=p;for(q=n;m||q;)n=g[m][q]-1,q&&n===g[m][q-1]?l.push(h[h.length]={status:e,value:c[--q],index:q}):m&&n===g[m-1][q]?r.push(h[h.length]={status:f,value:b[--m],index:m}):(--q,--m,k.sparse||h.push({status:"retained",
|
||||
value:c[q]}));a.a.Cb(l,r,10*p);return h.reverse()}return function(a,c,e){e="boolean"===typeof e?{dontLimitMoves:e}:e||{};a=a||[];c=c||[];return a.length<=c.length?b(a,c,"added","deleted",e):b(c,a,"deleted","added",e)}}();a.b("utils.compareArrays",a.a.Ma);(function(){function b(b,d,f,k,h){var l=[],g=a.j(function(){var g=d(f,h,a.a.na(l,b))||[];0<l.length&&(a.a.Qb(l,g),k&&a.k.u(k,null,[f,g,h]));l.length=0;a.a.ia(l,g)},null,{q:b,Pa:function(){return!a.a.tb(l)}});return{aa:l,j:g.$()?g:p}}var d=a.a.f.I();
|
||||
a.a.fb=function(c,e,f,k,h){function l(b,d){s=u[d];t!==d&&(z[b]=s);s.Ua(t++);a.a.na(s.aa,c);r.push(s);y.push(s)}function g(b,c){if(b)for(var d=0,e=c.length;d<e;d++)c[d]&&a.a.o(c[d].aa,function(a){b(a,d,c[d].wa)})}e=e||[];k=k||{};var m=a.a.f.get(c,d)===p,u=a.a.f.get(c,d)||[],q=a.a.Ka(u,function(a){return a.wa}),n=a.a.Ma(q,e,k.dontLimitMoves),r=[],v=0,t=0,w=[],y=[];e=[];for(var z=[],q=[],s,C=0,D,E;D=n[C];C++)switch(E=D.moved,D.status){case "deleted":E===p&&(s=u[v],s.j&&s.j.p(),w.push.apply(w,a.a.na(s.aa,
|
||||
c)),k.beforeRemove&&(e[C]=s,y.push(s)));v++;break;case "retained":l(C,v++);break;case "added":E!==p?l(C,E):(s={wa:D.value,Ua:a.r(t++)},r.push(s),y.push(s),m||(q[C]=s))}g(k.beforeMove,z);a.a.o(w,k.beforeRemove?a.S:a.removeNode);for(var C=0,m=a.e.firstChild(c),H;s=y[C];C++){s.aa||a.a.extend(s,b(c,f,s.wa,h,s.Ua));for(v=0;n=s.aa[v];m=n.nextSibling,H=n,v++)n!==m&&a.e.Fb(c,n,H);!s.rc&&h&&(h(s.wa,s.aa,s.Ua),s.rc=!0)}g(k.beforeRemove,e);g(k.afterMove,z);g(k.afterAdd,q);a.a.f.set(c,d,r)}})();a.b("utils.setDomNodeChildrenFromArrayMapping",
|
||||
a.a.fb);a.P=function(){this.allowTemplateRewriting=!1};a.P.prototype=new a.J;a.P.prototype.renderTemplateSource=function(b,d,c,e){if(d=(9>a.a.M?0:b.nodes)?b.nodes():null)return a.a.O(d.cloneNode(!0).childNodes);b=b.text();return a.a.ca(b,e)};a.P.Va=new a.P;a.hb(a.P.Va);a.b("nativeTemplateEngine",a.P);(function(){a.Ya=function(){var a=this.uc=function(){if(!u||!u.tmpl)return 0;try{if(0<=u.tmpl.tag.tmpl.open.toString().indexOf("__"))return 2}catch(a){}return 1}();this.renderTemplateSource=function(b,
|
||||
e,f,k){k=k||w;f=f||{};if(2>a)throw Error("Your version of jQuery.tmpl is too old. Please upgrade to jQuery.tmpl 1.0.0pre or later.");var h=b.data("precompiled");h||(h=b.text()||"",h=u.template(null,"{{ko_with $item.koBindingContext}}"+h+"{{/ko_with}}"),b.data("precompiled",h));b=[e.$data];e=u.extend({koBindingContext:e},f.templateOptions);e=u.tmpl(h,b,e);e.appendTo(k.createElement("div"));u.fragments={};return e};this.createJavaScriptEvaluatorBlock=function(a){return"{{ko_code ((function() { return "+
|
||||
a+" })()) }}"};this.addTemplate=function(a,b){w.write("<script type='text/html' id='"+a+"'>"+b+"\x3c/script>")};0<a&&(u.tmpl.tag.ko_code={open:"__.push($1 || '');"},u.tmpl.tag.ko_with={open:"with($1) {",close:"} "})};a.Ya.prototype=new a.J;var b=new a.Ya;0<b.uc&&a.hb(b);a.b("jqueryTmplTemplateEngine",a.Ya)})()})})();})();
|
||||
Loading…
Add table
Add a link
Reference in a new issue