snappymail/dev/Settings/Filters.js
RainLoop Team 1027f319ed Sieve Filters (Interface first look)
Code refactoring
Small fixes
2014-08-07 01:02:20 +04:00

32 lines
703 B
JavaScript

/* RainLoop Webmail (c) RainLoop Team | Licensed under CC BY-NC-SA 3.0 */
/**
* @constructor
*/
function SettingsFilters()
{
// var oData = RL.data();
this.filters = ko.observableArray([]);
this.filters.loading = ko.observable(false);
this.filters.subscribe(function () {
Utils.windowResize();
});
}
Utils.addSettingsViewModel(SettingsFilters, 'SettingsFilters', 'SETTINGS_LABELS/LABEL_FILTERS_NAME', 'filters');
//SettingsFilters.prototype.onBuild = function ()
//{
//};
SettingsFilters.prototype.deleteFilter = function (oFilter)
{
this.filters.remove(oFilter);
};
SettingsFilters.prototype.addFilter = function ()
{
kn.showScreenPopup(PopupsFilterViewModel, [new FilterModel()]);
};