
kerio.adm.x_17 = kerio.adm.x_17 || {};

kerio.adm.x_17.x_vt = function(x_1j, x_2v) {
var x_2w = x_1j + '_';
var x_x = kerio.lib.x_x;
var x_5c = (true === x_2v.x_5c);
if (x_2v.x_mc) {
this.x_mc = x_2v.x_mc;
}
if (x_2v.x_1wm) {
this.x_1wm = x_2v.x_1wm;
}
if (x_2v.x_2cl) {
this.x_2cl = x_2v.x_2cl;
}
this.x_2cm = {
x_1y:          x_x('Grouping Dialog', 'groupingDialog'),
x_2cn:     x_5c ? x_x('Move to a group', 'groupingDialog') : x_x('Add to a group', 'groupingDialog'),
x_1gu:  x_5c ? x_x('Move to existing:', 'groupingDialog') : x_x('Select existing:', 'groupingDialog'),
x_2co:    x_5c ? x_x('Move to new:', 'groupingDialog') : x_x('Create new:', 'groupingDialog'),
x_1h3:       x_x('New Group',           'groupingDialog'),
x_2cp:       x_x('No groups available', 'groupingDialog'),
x_10n:        x_x('Loading groups…',   'groupingDialog'),
x_2cq:             x_x('OK',                  'groupingDialog'),
x_2cr:         x_x('Cancel',              'groupingDialog'),
x_2cs:          x_x('Close',               'groupingDialog'),
x_2ct:     x_x('No child group', 'groupingDialog'),
x_2cu:   x_x('There is no child group available.', 'groupingDialog'),
x_2cv:     x_x('Validation warning', 'groupingDialog'),
x_1q9: x_x('Specified values are not valid for range.', 'groupingDialog')
};
for (var x_41 in x_2v.x_vr) {
if (this.x_2cm[x_41]) { this.x_2cm[x_41] = x_2v.x_vr[x_41]; }
}
x_x = this.x_2cm; var x_5p = kerio.adm.x_28z('x_27c') === kerio.adm.x_1bc.x_29i;
var x_2cw  = x_2v.x_1gv;
this.x_2cx = (undefined !== x_2v.x_1gv);
var x_vs = x_2v.x_vs;
x_vs.x_1j = 'id';
x_vs.x_a6 = 'name';
x_vs.x_68 = 'groups';
var x_2cy = x_2v.x_2cy || {};
var x_1d = {
x_1e: [
{ x_1f: 'x_79',
x_1j: 'x_2cz',
x_1u: '100%',
x_23: x_x.x_2cn,
x_1e: [
{ x_1f: 'x_b3',
x_1e: [
{
x_1f: 'x_7a',
x_7b: 'x_1cy',
x_1s: x_x.x_1gu,
x_1l: true,
x_31: true,
x_1o: 'x_1gw',

x_9t: function(x_1c, x_7a) {
var x_16 = x_1c.x_16;
var x_1h3 = ('x_2d0' == x_7a.x_2d1().x_2t());
x_1c.x_84(['x_1gu'], x_1h3);
x_1c.x_84(['x_1h3'], !x_1h3);
if (x_1h3) {
x_1c.x_1d3('x_1h3');
}
if (undefined === x_16.x_87 || 0 === x_16.x_87.length) { x_1c.x_84(['x_1gu'], true);
}
x_16.x_2d2.call(x_16);
x_16.x_2d3.call(x_16);
x_16.x_2d4.call(x_16, x_7a);
}
},
{x_1f: 'x_9u',
x_1j: 'x_1gu',
x_5z: {}, x_1o: x_x.x_10n,
x_31: true, x_a5: x_vs.x_a6,
x_a7: x_vs.x_1j,
x_1l: true,

x_9t: function(x_1c, x_9u) {
var x_16 = x_1c.x_16;
x_16.x_2d3.call(x_16);
x_16.x_2d4.call(x_16, x_9u);
}
}] }, { x_1f: 'x_b3',
x_1e: [
{
x_1f: 'x_7a',
x_7b: 'x_1cy',
x_1s: x_x.x_2co,
x_1l: true,
x_1o: 'x_2d0'
},
{x_1j: 'x_1h3',
x_1o: x_x.x_1h3,
x_93: 63,
x_ge: true,
x_1l: true,
x_b6: (x_2cy.x_b6) ? x_2cy.x_b6 : { x_b7: false },

x_9t: function(x_1c, x_g6) {
var x_16 = x_1c.x_16;
x_16.x_2d3.call(x_16);
x_16.x_2d4.call(x_16, x_g6);
}
}] } ] } ] }; if (x_2v.x_1e) {
x_1d.x_1e.push({ x_1f: 'x_1g',
x_1j: 'x_2d5',
x_1e: x_2v.x_1e                                         }); }
else {
kerio.lib.x_nq('Internal error: You haven\'t defined items for the GroupingGrid!!!', 'groupingDialog.js');
}
var x_1c = new kerio.lib.x_1t(x_2w + 'x_1c', x_1d);
this.x_2d6 = x_1c.x_29(x_2cw);
if (this.x_2cx) {
if (this.x_2d6) {
this.x_2d6.x_9w(x_x.x_10n);
}
else {
kerio.lib.x_nq('Internal error: Child group is defined to "' + x_2cw + '" but not found in form "' + x_1j + 'x_2d7"!!!', 'groupingDialog.js');
}
}
if (x_5p) {
x_1c.x_7f(true);
}
var x_2n = x_2v.x_2n ? x_2v.x_2n : {};
var x_10 = {
x_1u: 460,
x_1v: (x_2n.x_1v ? x_2n.x_1v : 485),
x_l0: 460,
x_l1: (x_2n.x_l1 ? x_2n.x_l1 : 485),
x_1y: x_x.x_1y,
x_1x: x_1c,
x_1z: [
{
x_20: !x_5p,
x_1j: 'x_22',
x_23: x_x.x_2cq,
x_2d8: true,
x_1m: x_5p,

x_25: function(x_32) {
var
x_16 = x_32.x_16,
x_1c = x_16.x_1c,
x_1wm = x_16.x_1wm(),
x_x = x_16.x_2cm;
if (x_1wm && x_16.x_2d6.x_31()) {
kerio.lib.x_48(x_x.x_2ct, x_x.x_2cu);
return;
}
x_16.x_mc.call(x_16, x_16); } }, {
x_20: x_5p,
x_21: true,
x_1j: 'x_ji',
x_23: (x_5p) ? x_x.x_2cs : x_x.x_2cr
} ] }; kerio.adm.x_17.x_vt.superclass.constructor.call(this, x_1j, x_10);
this.x_27({
x_1c: x_1c,
x_2d9: x_vs,
x_2da: x_2cw,
x_2db: x_5p,
x_2dc: x_1c.x_29('x_1h3'),
x_2dd: x_1c.x_29('x_1cy'),
x_2de: x_1c.x_29('x_1gu')
});
x_1c.x_27({
x_16: this
});
this.x_2cm = {
x_2cp: 				x_x.x_2cp,
x_1h3: 				x_x.x_1h3,
x_2ct:     x_x.x_2ct,
x_2cu:   x_x.x_2cu,
x_2cv:     x_x.x_2cv,
x_1q9: 	x_x.x_1q9
};
}; 
kerio.lib.x_36(kerio.adm.x_17.x_vt, kerio.lib.x_26,

{

x_2c: function(x_28) {
this.x_2df = x_28.x_47 || {};
this.x_2dg = (this.x_2df.id ? true : false);
this.x_5d = x_28.x_5d;
this.x_2dh = (this.x_2dg && false !== this.x_lh.x_11);
if (this.x_2dg) {
this.x_2dd.x_9w('x_1gw');
this.x_1c.x_29('x_1gu').x_9w(this.x_2df.groupName);
this.x_1c.x_29('x_1h3').x_9w(this.x_2df.groupName);
}
else {
this.x_2dd.x_9w('x_2d0');
}
},

x_jo: function() {
this.x_2h();
},

x_2h: function() {
var x_1c = this.x_1c;
x_1c.x_2h();
this.x_2de.x_8f();
this.x_2dd.x_yw('x_1gw');
this.x_2dd.x_9w('x_2d0'); if (this.x_2cx) {
this.x_2d6.x_8f();
x_1c.x_84([this.x_2da]);
}
},

x_5p: function() {
return this.x_2db;
},

x_2d2: function() {
if ('x_1gw' === this.x_2dd.x_2t()) {
return true; }
else {
return this.x_2dc.x_o4();
}
}, 
x_2d3: function() {
if (!this.x_2d6) {
return; }
if (!this.x_87) {
this.x_1c.x_84([this.x_2da]); return; }
var x_1h7;
if ('x_1gw' == this.x_2dd.x_2t()) {
x_1h7 = this.x_2de.x_vj();
}
else {
x_1h7 = this.x_2dc.x_2t();
}
var x_87 = this.x_87;
var x_1gy = x_87.length;
var x_1h8 = [];
for (var x_41 = 0; x_41 < x_1gy; x_41++) {
if (x_1h7 != x_87[x_41].name) {
x_1h8.push(x_87[x_41]);
}
} x_1gy = x_1h8.length;
var x_1c = this.x_1c;
var x_1gv = this.x_2d6;
if (0 === x_1gy) {
x_1gv.x_9w(this.x_2cm.x_2cp);
x_1c.x_84([this.x_2da]);
} else {
var x_ut = x_1gv.x_2t();
var x_1h9 = x_1gv.x_vj();
x_1gv.x_8f();
x_1gv.x_an(x_1h8);
if (x_1gv.x_31() || '' === x_1h9 || x_1h9 == x_1h7) {
x_1gv.x_1h5(0); }
else {
x_1gv.x_9w(x_ut); }
x_1c.x_84([this.x_2da], false); } }, 
x_2di: function(x_fk, x_1o) {
if (undefined === this.x_87 || undefined === x_1o) {
return undefined; }
else {
for (var x_41 = 0, x_42 = this.x_87.length; x_41 < x_42; x_41++) {
var x_vy = this.x_87[x_41];
if (x_vy[x_fk] === x_1o) {
return x_vy; }
} return undefined; }
},

x_vz: function() {
var x_6q = this.x_2d9;
var x_1cy = ('x_1gw' == this.x_2dd.x_2t()) ? this.x_2de.x_vj() : this.x_2dc.x_2t();
var x_dh = this.x_2di(x_6q.x_a6, x_1cy); var x_vy = {};
x_vy[x_6q.x_a6] = x_1cy;
x_vy[x_6q.x_1j] = (x_dh) ? x_dh[x_6q.x_1j] : '';
return x_vy;
},

x_2d4: function(x_g6) {
var x_vy = this.x_vz();
var x_1cy = x_vy.name || ""; if (x_1cy === this.x_2dj) {
return; }
else {
this.x_2dj = x_1cy;
this.x_2cl(x_1cy, undefined === x_vy.id); }
},

x_vx: function(x_vw, x_1gv) {
var x_6q = this.x_2d9;
this.x_2dk = x_vw || {};
this.x_2dl = x_1gv || {};
if (this.x_5p()) {
var x_a6 = x_vw[x_6q.x_a6];
this.x_2dc.x_9w(x_a6);
this.x_2de.x_9w(x_a6);
if (this.x_2cx) {
this.x_2d6.x_9w(x_1gv[x_6q.x_a6]);
}
this.x_2dd.x_yw('x_1gw', false); this.x_2dd.x_9w('x_1gw');
}
else {
var x_j4 = {
x_6p: 'post',
x_28: {
object: x_6q.x_hi,
method: 'getGroupList'
},
x_2q: this,
x_2e: this.x_2dm
};
if (x_6q.x_28) {
x_j4.x_28.params = kerio.lib.x_6r(x_6q.x_28);
}
kerio.lib.x_6t.x_6u(x_j4);
}
}, 
x_2dm: function(x_6v) {
var x_6q = this.x_2d9;
var x_1j = x_6q.x_1j;
var x_a6 = x_6q.x_a6;
var x_47 = x_6v.x_ac[x_6q.x_68];
var x_1gy = (x_47) ? x_47.length : 0;
var x_vw = this.x_2dk;
var x_1gv  = this.x_2dl;
this.x_87 = (0 < x_1gy) ? x_47 : undefined;
var x_2dn = 'object' === typeof this.x_2di(x_1j, x_vw[x_1j]);
var x_2do = false;
if (this.x_2cx) {
x_2do  = 'object' === typeof this.x_2di(x_1j, x_1gv[x_1j]);
}
var x_dh;
if (this.x_2cx && !x_2do && x_1gv[x_a6]) {
x_dh = {};
if (x_1gv[x_1j]) {
x_dh[x_1j] = x_1gv[x_1j];
x_2do = true;
}
else {
x_dh[x_1j] = '';
}
x_dh[x_a6] = x_1gv[x_a6];
x_47.unshift(x_dh);
} if (!x_2dn && x_vw[x_a6]) {
x_dh = {};
if (x_vw[x_1j]) {
x_dh[x_1j] = x_vw[x_1j];
x_2dn = true;
}
else {
x_dh[x_1j] = '';
}
x_dh[x_a6] = x_vw[x_a6];
x_47.unshift(x_dh);
} x_1gy = (x_47) ? x_47.length : 0; this.x_87 = (0 < x_1gy) ? x_47 : undefined;
var x_1cy = (x_vw[x_a6]) ? x_vw[x_a6] : this.x_2cm.x_1h3;
this.x_2dc.x_9w(x_1cy);
this.x_2dd.x_yw('x_1gw', (0 === x_1gy)); if ('x_1gw' == this.x_2dd.x_2t()) {
this.x_2de.x_84(0 === x_1gy);
}
this.x_2de.x_8f();
this.x_2de.x_an(x_47);
if (x_2dn) { this.x_2de.x_9w(x_vw[x_1j]); this.x_2dd.x_9w('x_1gw'); }
else if (x_vw[x_a6]){ this.x_2de.x_9w(x_vw[x_a6]); this.x_2dd.x_9w('x_1gw'); }
else if (0 < x_1gy){ this.x_2de.x_1h5(0); this.x_2dd.x_9w('x_2d0'); }
else { this.x_2de.x_9w(this.x_2cm.x_2cp);
this.x_2dd.x_9w('x_2d0'); } if (this.x_2cx) {
this.x_2d6.x_8f();
this.x_2d6.x_an(x_47);
if (x_2do) { this.x_2d6.x_9w(x_1gv[x_1j]); }
else if (x_1gv[x_a6]){ this.x_2d6.x_9w(x_1gv[x_a6]); }
else if (0 < x_1gy){ this.x_2d6.x_1h5(0); }
else { this.x_2d6.x_9w(this.x_2cm.x_2cp);
} this.x_2d3(); }
}, 
x_mc: function() {
alert('DEVELOPMENT ERROR, define x_mc method');
},

x_1wm: function() {
return this.x_2cx;
},

x_2cl: function(){}
}); 
kerio.adm.x_17 = kerio.adm.x_17 || {};

kerio.adm.x_17.x_18 = function(x_1j, x_2v) {
var x_x = kerio.lib.x_x;
x_2v.x_vr = x_2v.x_vr || {};
var x_2dp = x_2v.x_vr;
var x_2dq = {
x_1og:			x_x('Properties',     'ipAddressGroupEditor'),
x_1vz:				x_x('Type:',          'ipAddressGroupEditor'),
x_2dr:					x_x('Host',           'ipAddressGroupEditor'),
x_19e:				x_x('Hostname/IP:',   'ipAddressGroupEditor'),
x_17h:				x_x('Network/Mask',   'ipAddressGroupEditor'),
x_1pz:			x_x('IP Address:',    'ipAddressGroupEditor'),
x_1q2:			x_x('Mask:',          'ipAddressGroupEditor'),
x_2ds:				x_x('Address Range',  'ipAddressGroupEditor'),
x_1py:			x_x('From:',          'ipAddressGroupEditor'),
x_1q0:				x_x('To:',            'ipAddressGroupEditor'),
x_vy:				x_x('Address Group',  'ipAddressGroupEditor'),
x_1cy:			x_x('Address Group:', 'ipAddressGroupEditor'),
x_f8:			x_x('Description:',   'ipAddressGroupEditor'),
x_2dt: 			x_x('Firewall', 'ipAddressGroupEditor')
};
for (var x_41 in x_2dp) {
if (x_2dq[x_41]) { x_2dq[x_41] = x_2dp[x_41]; }
}
x_2v.x_5c = true;
if (x_1j == 'ipAddressGroupEdit') {

x_2dq.x_1y = x_x('Edit IP Address', 'ipAddressGroupEditor');
}
else if (x_1j == 'ipAddressGroupEditorView') {
x_2dq.x_1y = x_x('View IP Address', 'ipAddressGroupEditor');
}
else {
x_2v.x_5c = false;
x_2dq.x_1y = x_x('Add IP Address', 'ipAddressGroupEditor');
}
x_x = x_2dq; var x_2du = []; var x_vp = []; var x_2dv = {}; var x_2dw = kerio.adm.x_28z();
var x_2dx = x_2v.x_o9 || x_2dw.kerio_web_Host; this.x_2cx = false; this.x_2dy = false !== x_2v.x_2dz;
kerio.lib.x_10o.x_2dw = x_2dw;

kerio.lib.x_10o.x_20e({

x_nw: function(x_1o) {
return (-1 == x_1o.indexOf(' '));
},

x_t2: function(x_1o) {
var x_2e3 = true;
if ('0.0.0.0' == x_1o || '255.255.255.255' == x_1o) {
x_2e3 = false;
}
else {
if (!this.x_2e4) {
this.x_2e4 = new RegExp(this.x_2dw.kerio_web_IpAddressRegExp);
}
if (!this.x_2e4.test(x_1o)) {
x_2e3 = false;
}
}
return x_2e3;
} });

var x_1q1 = function(x_1c, x_g6) {
var x_1q9 = x_1c.x_16.x_2cm.x_1q9;
var x_2e5 = x_1c.x_16.x_2cm.x_2e5;
var x_1py = x_1c.x_29('x_1py');
var x_1q0 = x_1c.x_29('x_1q0');
if (x_1py.x_o4() && x_1q0.x_o4()) {
var x_1qb = x_1py.x_2t().split('.');
var x_1qd = x_1q0.x_2t().split('.');
for (var x_bl = 0, x_42 = x_1qb.length; x_bl < x_42; x_bl++) {
var x_1qa = parseInt(x_1qb[x_bl], 10);
var x_1qc = parseInt(x_1qd[x_bl], 10);
if ((x_1qc < x_1qa)
|| x_bl == (x_42 - 1) && x_1qc == x_1qa) {
x_1py.x_1g4(true, x_1q9);
x_1q0.x_1g4(true, x_1q9);
return false; }
else if (x_1qc > x_1qa) {
break;
}
}
}
x_1py.x_1g4(false, x_2e5);
x_1q0.x_1g4(false, x_2e5);
x_1py.x_o4(); x_1q0.x_o4();
return true; };

var x_2e6 = function(x_1c, x_g6) {
var x_2e7 = false;
if (x_g6.x_o4()) {
var x_2e8 = x_g6.x_2t().split('.');
if ('0' == x_2e8[0]) {
x_2e7 = true;
}
else {
var x_2e9, x_2ea;
x_2ea = x_2e8[3] % 2;
var x_2eb = 7; for (var x_dj = 3; x_dj >= 0 && true !== x_2e7; x_dj--) {
for (var x_41 = 0; x_41 < x_2eb; x_41++) {
x_2e9 = x_2e8[x_dj] % 2;
if ((1 == x_2ea) && (0 === x_2e9)) {
x_2e7 = true;
break;
}
x_2e8[x_dj] = (x_2e8[x_dj] - x_2e9) / 2;
x_2ea = x_2e9;
}
x_2eb = 8; }
}
}
x_g6.x_1g4(x_2e7);
x_g6.x_o4(); return !x_2e7;
};
if (undefined !== x_2dw.kerio_web_Host) {
x_2du.push({
x_23: x_x.x_2dr,
x_1o: x_2dw.kerio_web_Host
});
x_2dv[x_2dw.kerio_web_Host] = ['x_19e'];
x_vp = x_vp.concat([
{ x_1j: 'x_19e',
x_23: (false === x_2v.x_2dz ? x_x.x_1pz : x_x.x_19e),
x_1m: (x_2dx != x_2dw.kerio_web_Host),
x_93: 127,
x_b6: {
x_nv: (false === x_2v.x_2dz ? 'x_t2' : 'x_nw'),
x_b7: false
}
} ]); } if (undefined !== x_2dw.kerio_web_Network) {
x_2du.push({
x_23: x_x.x_17h,
x_1o: x_2dw.kerio_web_Network
});
x_2dv[x_2dw.kerio_web_Network] = ['x_1pz', 'x_1q2'];
x_vp = x_vp.concat([
{ x_1j: 'x_1pz',
x_1m: (x_2dx != x_2dw.kerio_web_Network),
x_23: x_x.x_1pz,
x_93: 15,
x_b6: {
x_nv: 'x_t2',
x_b7: false
}
}, { x_1j: 'x_1q2',
x_23: x_x.x_1q2,
x_1m: (x_2dx != x_2dw.kerio_web_Network),
x_93: 15,
x_b6: {
x_nv: 'x_t2',
x_b7: false
},
x_9t: x_2e6
} ]); } if (undefined !== x_2dw.kerio_web_Range) {
x_2du.push({
x_23: x_x.x_2ds,
x_1o: x_2dw.kerio_web_Range
});
x_2dv[x_2dw.kerio_web_Range] = ['x_1py', 'x_1q0'];
x_vp = x_vp.concat([
{ x_1j: 'x_1py',
x_23: x_x.x_1py,
x_1m: (x_2dx != x_2dw.kerio_web_Range),
x_93: 15,
x_b6: {
x_nv: 'x_t2',
x_b7: false
},
x_9t: x_1q1
}, { x_1j: 'x_1q0',
x_23: x_x.x_1q0,
x_1m: (x_2dx != x_2dw.kerio_web_Range),
x_93: 15,
x_b6: {
x_nv: 'x_t2',
x_b7: false
},
x_9t: x_1q1
} ]); } if (undefined !== x_2dw.kerio_web_ChildGroup) {
x_2du.push({
x_23: x_x.x_vy,
x_1o: x_2dw.kerio_web_ChildGroup
});
x_2dv[x_2dw.kerio_web_ChildGroup] = ['x_1gv'];
this.x_2cx = true;
x_2v.x_1gv = 'x_1gv';
x_vp = x_vp.concat([
{ x_1f: 'x_9u',
x_1j: 'x_1gv',
x_1m: (x_2dx != x_2dw.kerio_web_ChildGroup),
x_23: x_x.x_1cy,
x_a5: 'name',
x_a7: 'id',
x_5z: {}, x_1o: ''     } ]); } if (undefined !== x_2dw.kerio_web_ThisMachine && x_2v.x_12) {
x_2du.push({
x_23: x_2v.x_12,
x_1o: x_2dw.kerio_web_ThisMachine
});
x_2dv[x_2dw.kerio_web_ThisMachine] = []; } var x_6q;
if (0 === x_2du.length) {
kerio.lib.x_nq('Internal error: You have NOT set any Item Types for dialog ' + x_1j +  '!', 'ipAddressGroupEditor.js');
}
else {
x_6q = x_2v.x_2ec || {};
x_vp.unshift(
{ x_1f: 'x_9u',
x_1j: 'x_1wl',
x_a6: 'x_1wl',
x_23: x_x.x_1vz,
x_31: (true === x_6q.x_31),
x_1m:   (true === x_6q.x_1m),
x_5z: x_2du, x_a5: 'x_23',
x_a7: 'x_1o',
x_9t: this.x_2ed
} ); x_vp.push(
{ x_a6: 'description',
x_1j: 'x_f8',
x_23: x_x.x_f8,
x_93: 255,
x_ge: true
}
); } var x_br = kerio.lib.x_a1(
{	x_a2: 100,
ru: 130,
cs: 145,
pt: 130,
sk: 135
});
var x_1e = [
{ x_1f: 'x_79',
x_1j: 'x_2ee',
x_23: x_x.x_1og,
x_1u: '100%',
x_br: x_br,
x_1p: 'removeFieldsetMargin',
x_1e: x_vp
}  ]; x_2v.x_1e = x_1e;
x_2v.x_2n = {
x_1v: 321,
x_l1: 321
};
x_2v.x_vs = {
x_hi: 'IpAddressGroupManager',
x_6p:  'getGroupList',
x_68:    'groups'
};
if (this.x_2cx) {
x_2v.x_1gv = 'x_1gv';
}
x_2v.x_vr = {
x_1y: x_x.x_1y
};
kerio.adm.x_17.x_18.superclass.constructor.call(this, x_1j, x_2v);
this.x_27({
x_1wl: this.x_1c.x_29('x_1wl'),
x_lh: x_2v,
x_2ef: x_2dw,
x_2eg: x_2dx,
x_2eh: x_2dv,
x_1q1: x_1q1,
x_2e6: x_2e6,
x_2ei: kerio.lib.x_10o.x_2ej('x_t2')
});
};kerio.lib.x_36(kerio.adm.x_17.x_18, kerio.adm.x_17.x_vt,

{

x_2c: function(x_28) {
var x_1c = this.x_1c;
kerio.adm.x_17.x_18.superclass.x_2c.call(this, x_28);
var x_6q, x_1j, x_a6, x_nm;
if (this.x_2dg) {
x_1c.x_2k(['x_2ee'], false); }
else {
x_6q = this.x_2d9;
x_1j = x_6q.x_1j;
x_a6 = x_6q.x_a6;
x_nm = x_28.x_nm;
if (x_nm) {
if (x_nm[x_1j]) {
this.x_2df.groupId = x_nm[x_1j];
}
if (x_nm[x_a6]) {
this.x_2df.groupName = x_nm[x_a6];
}
}
this.x_2df.type = this.x_2eg;
}
this.x_7k(this.x_2df);
x_1c.x_2k(['x_2ee'], true); if (this.x_2dh) {
this.x_2ek();
}
}, 
x_jo: function() {
this.x_1c.x_2k(['x_2ee'], false);
this.x_2h();
}, 
x_2ek:function() {
var x_2dw = this.x_2ef;
var x_1ni = [
'id', 'groupId', 'groupName', 'description', 'type', 'enabled', 'host', 'addr1', 'addr2', 'childGroupName', 'childGroupId'
];
var x_j4 = {
x_6p: 'post',
x_28: {
object: 'IpAddressGroupManager'
},
x_2q: this
};
var x_28 = {
query: {
fields: x_1ni,
conditions: [{
firstOperand: {
operandValue: 'id',
isColumnName: true
},
comparator: x_2dw.kerio_web_Eq,
secondOperand: {
operandValue: this.x_5d.x_3v.x_40[0].x_47.id,
isColumnName: false
}
}],
start: 0,
limit: 1
}
};
x_j4.x_28.method = 'get';
x_j4.x_28.params = kerio.lib.x_6r(x_28);
x_j4.x_2e = this.x_2el;
kerio.lib.x_6t.x_6u(x_j4);
},

x_2el:function(x_6v) {
if (!x_6v.x_6x) {
return;
}
var x_47 = x_6v.x_ac.groups[0];
this.x_2df = x_47;
this.x_7k(x_47);
},

x_7k: function(x_47) {
var x_1c = this.x_1c;
var x_2dw = this.x_2ef;
var x_7h = {
'x_f8': x_47.description || '',
'x_1wl': x_47.type
};
switch (x_47.type) {
case x_2dw.kerio_web_Host:
x_7h.x_19e = x_47.host || '';
break;
case x_2dw.kerio_web_Network:
x_7h.x_1pz = x_47.addr1 || '';
x_7h.x_1q2 = x_47.addr2 || '';
break;
case x_2dw.kerio_web_Range:
x_7h.x_1py = x_47.addr1 || '';
x_7h.x_1q0 = x_47.addr2 || '';
break;
}
x_1c.x_2em(x_7h);
var x_vw = {
id: x_47.groupId,
name: x_47.groupName
};
var x_1gv = {
id: x_47.childGroupId,
name: x_47.childGroupName
};
this.x_vx(x_vw, x_1gv);
}, 
x_2en: function(x_1o) {
var
x_2eo,
x_41;
if (this.x_2dy && false === this.x_2ei.call(kerio.lib.x_10o, x_1o)) {
return x_1o;
}
x_2eo = x_1o.split('.');
for (x_41 = 0; x_41 < x_2eo.length; x_41++) {
x_2eo[x_41] = parseInt(x_2eo[x_41], 10);
}
return x_2eo.join('.');
},

x_mc: function() {
var
x_1b = kerio.lib,
x_x  = x_1b.x_x,
x_1c = this.x_1c;
if (kerio.adm.x_28z('x_27c') === kerio.adm.x_1bc.x_29i) {
return; }
var x_47 = x_1c.x_7i();
var x_1wt = {};
var x_2dw = this.x_2ef;
if (x_47.x_1wl === x_2dw.kerio_web_Range && !this.x_1q1(x_1c)) {
kerio.lib.x_48(
x_x('Invalid range', 'ipAddressGroupEditor'),
x_x('Specified IP addresses are not valid for range.', 'ipAddressGroupEditor')
);
return;
}
if (x_47.x_1wl === x_2dw.kerio_web_Network && !this.x_2e6(x_1c, x_1c.x_29('x_1q2'))) {
kerio.lib.x_48(
x_x('Invalid mask', 'ipAddressGroupEditor'),
x_x('Highlighted field is not valid for network mask.', 'ipAddressGroupEditor')
);
return;
}
var x_vy = this.x_vz();
var x_vs = this.x_2d9;
x_1wt.groupId = x_vy[x_vs.x_1j];
x_1wt.groupName = x_vy[x_vs.x_a6];
switch (x_47.x_1wl) {
case x_2dw.kerio_web_Host:
x_1wt.host = this.x_2en(x_47.x_19e);
break;
case x_2dw.kerio_web_Network:
x_1wt.addr1 = this.x_2en(x_47.x_1pz);
x_1wt.addr2 = this.x_2en(x_47.x_1q2);
break;
case x_2dw.kerio_web_Range:
x_1wt.addr1 = this.x_2en(x_47.x_1py);
x_1wt.addr2 = this.x_2en(x_47.x_1q0);
break;
case x_2dw.kerio_web_ChildGroup:
var x_1cy = this.x_2d6.x_vj();
x_1wt.childGroupId = (x_1cy !== x_47.x_1gv) ? x_47.x_1gv : '';
x_1wt.childGroupName = x_1cy;
break;
case x_2dw.kerio_web_ThisMachine:
break; }
x_1wt.type = x_47.x_1wl;
x_1wt.description = x_47.x_f8;
var x_1wu = (!this.x_2dg || this.x_2df.enabled);
if (false === this.x_lh.x_2ep) {
x_1wu = (x_1wu) ? 1 : 0;
}
x_1wt.enabled = x_1wu;
var x_j4 = {
x_6p: 'post',
x_28: {
object: 'IpAddressGroupManager'
},
x_2q: this
};
var x_28 = {};
var x_6p;
if (this.x_2dg) {
x_28.groupIds = [this.x_2df.id]; x_28.details = x_1wt;
x_6p = 'set';
}
else {
x_28.groups = [x_1wt]; x_6p = 'create';
}
x_j4.x_28.method = x_6p;
x_j4.x_28.params = kerio.lib.x_6r(x_28);
x_j4.x_2e = this.x_2eq;
kerio.lib.x_6t.x_6u(x_j4);
}, 
x_2eq: function(x_6v) {
if (x_6v.x_6x) {
if (this.x_lh.x_13) {
this.x_lh.x_13.call(this.x_5d);
}
this.x_5d.x_6y();
this.x_2r();
} }, 
x_1wm: function() {
var x_2dw = this.x_2ef;
return (x_2dw.kerio_web_ChildGroup === this.x_1wl.x_2t());
},

x_2ed: function (x_1c, x_9u, x_1o) {
if (!x_1c) {
return;
}
var x_16 = x_1c.x_16;
var x_2er = x_16.x_2eh;
var x_2dv, x_41;
for (x_41 in x_2er) {
x_41 = parseInt(x_41, 10);
if (!isNaN(x_41)) {
x_1c.x_2k(x_2er[x_41], false);
}
}
for (x_41 in x_2er) {
x_41 = parseInt(x_41, 10);
if (!isNaN(x_41)) {
x_1c.x_2k(x_2er[x_41], x_41 === x_1o);
}
}
if (x_16.x_1wm()) {
x_16.x_2d3();
}} } ); 
kerio.adm.x_17 = kerio.adm.x_17 || {};

kerio.adm.x_17.x_1pr = function(x_1j, x_2v) {
var x_x = kerio.lib.x_x;
var x_2dw = kerio.adm.x_28z();
var x_1pq = x_2v.x_1pq || 'd/m/Y';
var x_1pp = x_2v.x_1pp || 'H:i';
var x_2es = new RegExp(x_2dw.kerio_web_DateRegExp);
var x_2et = new RegExp(x_2dw.kerio_web_TimeRegExp);
var x_2eu = [
{name: x_x('Daily', 'timeRangeEditor'), value: x_2dw.kerio_web_TimeRangeDaily},
{name: x_x('Weekly', 'timeRangeEditor'), value: x_2dw.kerio_web_TimeRangeWeekly},
{name: x_x('Absolute', 'timeRangeEditor'), value: x_2dw.kerio_web_TimeRangeAbsolute}
];
var x_2ev = [
{name: x_x('Monday', 'timeRangeEditor'), value: x_2dw.kerio_web_Monday},
{name: x_x('Tuesday', 'timeRangeEditor'), value: x_2dw.kerio_web_Tuesday},
{name: x_x('Wednesday', 'timeRangeEditor'), value: x_2dw.kerio_web_Wednesday},
{name: x_x('Thursday', 'timeRangeEditor'), value: x_2dw.kerio_web_Thursday},
{name: x_x('Friday', 'timeRangeEditor'), value: x_2dw.kerio_web_Friday},
{name: x_x('Saturday', 'timeRangeEditor'), value: x_2dw.kerio_web_Saturday},
{name: x_x('Sunday', 'timeRangeEditor'), value: x_2dw.kerio_web_Sunday}
];
var x_2ew = {
'x_2ex':    'kerio_web_Monday',
'x_2ey':   'kerio_web_Tuesday',
'x_2ez': 'kerio_web_Wednesday',
'x_2f0':  'kerio_web_Thursday',
'x_2f1':    'kerio_web_Friday',
'x_2f2':  'kerio_web_Saturday',
'x_2f3':    'kerio_web_Sunday'
}; var x_2f4 = [
{name: x_x('All days', 'timeRangeEditor'), value: 1},
{name: x_x('Weekdays', 'timeRangeEditor'), value: 2},
{name: x_x('Weekend', 'timeRangeEditor'), value: 3},
{name: x_x('Selected days', 'timeRangeEditor'), value: 4}
];
var x_2f5 = {
x_2f6: x_2et,
x_b7: false
};
var x_2f7 = {
x_2f6: x_2es,
x_b7: false
};
var x_2f8 = Math.round(new Date().getTime() / 1000);
var x_1e = [
{
x_23: x_x('Description', 'timeRangeEditor'),
x_1f: 'x_79',
x_1j: 'x_2f9',
x_1e: [
{
x_1l: true,
x_1j: 'x_f8',
x_93: 255,
x_ge: true
}
]
},
{
x_23: x_x('Time settings', 'timeRangeEditor'),
x_1f: 'x_79',
x_br: 90,
x_1j: 'x_2fa',
x_2fb: false,
x_1e: [
{
x_23: x_x('Type:', 'timeRangeEditor'),
x_1f: 'x_9u',
x_1j: 'x_1f',
x_1o: x_2dw.kerio_web_TimeRangeDaily,
x_5z: x_2eu,

x_9t: function(x_1c, x_9u, x_1o) {
var x_2dw = kerio.adm.x_28z();
x_1c.x_2k(['x_ba', 'x_2fc', 'x_bb', 'x_2fd'], false);
x_1c.x_2k(['x_ba', 'x_2fc'], (x_2dw.kerio_web_TimeRangeDaily == x_1o));
x_1c.x_2k(['x_bb'], (x_2dw.kerio_web_TimeRangeWeekly == x_1o));
x_1c.x_2k(['x_2fd'], (x_2dw.kerio_web_TimeRangeAbsolute == x_1o));
var x_2fe = x_1c.x_29('x_2fe');
x_2fe.x_9w(x_2fe.x_2t());
x_1c.x_2p.x_2ff();
}
},
{
x_1f: 'x_1g',
x_1j: 'x_ba',
x_1p: 'inputSpacer',
x_1e: [
{
x_23: x_x('From:', 'timeRangeEditor'),
x_1j: 'x_2fg',
x_1o: '00:00',
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
},
{
x_23: x_x('To:', 'timeRangeEditor'),
x_1j: 'x_2fh',
x_1o: '23:59',
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
}
]
},
{
x_1f: 'x_1g',
x_1j: 'x_bb',
x_1m: true,
x_1p: 'inputSpacer',
x_1e: [
{
x_23: x_x('From:', 'timeRangeEditor'),
x_1f: 'x_b3',
x_1e: [
{
x_1f: 'x_9u',
x_1j: 'x_2fi',
x_1o: x_2dw.kerio_web_Monday,
x_5z: x_2ev,

x_9t: function(x_1c, x_9u, x_1o) {
var x_2fj = x_1c.x_29('x_2fj');
if (x_1o > x_2fj.x_2t()) {
x_2fj.x_9w(x_1o);
}
x_1c.x_2p.x_2ff();
}
},
{
x_1j: 'x_2fk',
x_1o: '00:00',
x_1u: 100,
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
}
]
},
{
x_23: x_x('To:', 'timeRangeEditor'),
x_1f: 'x_b3',
x_1e: [
{
x_1f: 'x_9u',
x_1j: 'x_2fj',
x_1o: x_2dw.kerio_web_Monday,
x_5z: x_2ev,

x_9t: function(x_1c, x_9u, x_1o) {
var x_2fi = x_1c.x_29('x_2fi');
if (x_1o < x_2fi.x_2t()) {
x_2fi.x_9w(x_1o);
}
x_1c.x_2p.x_2ff();
}
},
{
x_1j: 'x_2fl',
x_1o: '23:59',
x_1u: 100,
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
}
]
}
]
},
{
x_1f: 'x_1g',
x_1j: 'x_2fd',
x_1m: true,
x_1p: 'inputSpacer',
x_1e: [
{
x_23: x_x('From:', 'timeRangeEditor'),
x_1f: 'x_b3',
x_1e: [
{
x_1j: 'x_2fm',
x_1f: 'x_1kd',
x_1u: 100,
x_b6: x_2f7,
x_93: 10,
x_1pq: x_1pq,

x_9t: function(x_1c, x_9u, x_1o) {
var x_2fn = x_1c.x_29('x_2fn');
var x_2fo = x_2fn.x_2t();
if (x_2fo) {
if (x_1o > x_2fo) {
x_2fn.x_9w(x_1o);
}
else if (x_1o == x_2fo && x_9u.x_2fp < x_1o && x_1c.x_16.x_2fq < x_1o) {
x_2fn.x_9w(x_1o);
}
}
x_9u.x_2fp = x_1o;
x_1c.x_2p.x_2ff();
}
},
{
x_1j: 'x_2fr',
x_1o: '00:00',
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
}
]
},
{
x_23: x_x('To:', 'timeRangeEditor'),
x_1f: 'x_b3',
x_1e: [
{
x_1j: 'x_2fn',
x_1f: 'x_1kd',
x_1u: 100,
x_b6: x_2f7,
x_93: 10,
x_1pq: x_1pq,

x_9t: function(x_1c, x_2fs, x_1o) {
var x_2fm = x_1c.x_29('x_2fm');
var x_2ft = x_2fm.x_2t();
if (x_2ft) {
if (x_1o < x_2ft) {
x_2fm.x_9w(x_1o);
}
}
x_2fs.x_2fp = x_1o;
x_1c.x_2p.x_2ff();
}
},
{
x_1j: 'x_2fu',
x_1o: '23:59',
x_b6: x_2f5,
x_93: 5,

x_9t: function(x_1c) {
x_1c.x_2p.x_2ff();
}
}
]
}
]
},
{
x_1f: 'x_1g',
x_1j: 'x_2fc',
x_1p: 'inputSpacer',
x_1e: [
{
x_23: x_x('Valid on:', 'timeRangeEditor'),
x_1f: 'x_9u',
x_1o: 1, x_1j: 'x_2fe',
x_5z: x_2f4,

x_9t: function(x_1c, x_9u, x_1o) {
var x_2fv = x_1c.x_2fw;
x_1c.x_2fx = true;
if (4 == x_1o) {
x_1c.x_16.x_2fy(x_1c);
}
else {
var x_2fz = (1 == x_1o);
var x_2g0 = (2 == x_1o);
var x_2g1 = (3 == x_1o);
var x_2g2 = ((x_2fz || x_2g0) && !x_2g1);
var x_2g3 = ((x_2fz || x_2g1) && !x_2g0);
x_1c.x_29('x_2ex').x_9w(x_2g2);
x_1c.x_29('x_2ey').x_9w(x_2g2);
x_1c.x_29('x_2ez').x_9w(x_2g2);
x_1c.x_29('x_2f0').x_9w(x_2g2);
x_1c.x_29('x_2f1').x_9w(x_2g2);
x_1c.x_29('x_2f2').x_9w(x_2g3);
x_1c.x_29('x_2f3').x_9w(x_2g3);
}
x_1c.x_2fx = false;
}
},
{
x_1f: 'x_b3',
x_1j: 'x_2g4',
x_1p: 'validOnSpacer',
x_1e: [
{
x_1l: true,
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Mon', 'timeRangeEditor'),
x_1j: 'x_2ex',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Tue', 'timeRangeEditor'),
x_1j: 'x_2ey',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Wed', 'timeRangeEditor'),
x_1j: 'x_2ez',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Thu', 'timeRangeEditor'),
x_1j: 'x_2f0',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Fri', 'timeRangeEditor'),
x_1j: 'x_2f1',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Sat', 'timeRangeEditor'),
x_1j: 'x_2f2',
x_9t: this.x_2g5
},
{
x_1f: 'x_1q',
x_7d: true,
x_1s: x_x('Sun', 'timeRangeEditor'),
x_1j: 'x_2f3',
x_9t: this.x_2g5
}
]
}
]
},
{
x_1f: 'x_1i',
x_1l: true,
x_1o: x_x('Times set in the dialog correspond with server time zone.', 'timeRangeEditor'),
x_x6: x_2v.x_1po ? x_2v.x_1po : '/weblib/int/lib/img/info',
x_1p: 'timeRangeServerZone'
}
]
}
]; var x_1y;
var x_5c = true;
if (x_1j == 'timeRangeEdit') {
x_1y = x_x('Edit Time Range', 'groupingDialog');
}
else if (x_1j == 'timeRangeEditorView') {
x_1y = x_x('View Time Range', 'groupingDialog');
}
else {
x_5c = false;
x_1y = x_x('Add Time Range', 'groupingDialog');
}
var x_10 = {
x_1e: x_1e,
x_5c: x_5c,
x_1cy: x_2v.x_1cy,
x_vs: {
x_hi: 'TimeRangeManager',
x_6p:  'getGroupList',
x_68:    'groups'
},
x_2n: {
x_1v: 540,
x_l1: 540
},
x_vr: {
x_1y: x_1y,
x_1h3: x_x('New Time Range', 'groupingDialog')
}
};
kerio.adm.x_17.x_1pr.superclass.constructor.call(this, x_1j, x_10);
this.x_27({
x_lh: x_2v,
x_2g6: x_2ew,
x_2ef: x_2dw,
x_2fq: x_2f8,
x_2g7: x_1pp
});
}; kerio.lib.x_36(kerio.adm.x_17.x_1pr, kerio.adm.x_17.x_vt,

{

x_2c: function(x_28) {
this.x_1c.x_2fw = {};
kerio.adm.x_17.x_1pr.superclass.x_2c.call(this, x_28);
if (this.x_2dg) {
this.x_1c.x_2k(['x_2fa'], false); this.x_1c.x_2k(['x_2f9'], false); }
this.x_2g8 = undefined;
if (this.x_2dg) {
this.x_2g9(this.x_2df);
this.x_1c.x_2k(['x_2f9'], true); this.x_1c.x_2k(['x_2fa'], true); }
if (this.x_2dh) {
this.x_2ga();
}
else if (this.x_2dg) {
this.x_2g8 = this.x_2df.enabled;
}
else {
var x_6q = this.x_2d9;
var x_1j = x_6q.x_1j;
var x_1cy = x_6q.x_1cy;
var x_vw = {};
var x_1gv = {};
x_1cy = 'name';
if (x_28.x_nm) {
if (x_28.x_nm[x_1j]) {
x_vw[x_1j] = x_28.x_nm[x_1j];
}
if (x_28.x_nm[x_1cy]) {
x_vw[x_1cy] = x_28.x_nm[x_1cy];
}
} this.x_vx(x_vw, x_1gv);
this.x_2df = {
x_2fm: this.x_2fq,
x_2fn: this.x_2fq
};
this.x_1c.x_7k(this.x_2df);
this.x_1c.x_2k(['x_2f9'], true); this.x_1c.x_2k(['x_2fa'], true);
}
}, 
x_jo: function() {
this.x_1c.x_2k(['x_2f9'], false);
this.x_1c.x_2k(['x_2fa'], false);
this.x_2h();
}, 
x_2ga: function() {
var x_1ni = [
'id', 'groupId', 'groupName', 'description', 'type', 'enabled', 'status', 'fromTime', 'toTime', 'days', 'fromDay', 'toDay',
'fromDate', 'toDate', 'childGroupId', 'childGroupName'
];
var x_28 = {
query: {
fields: x_1ni,
conditions: [{
firstOperand: {
operandValue: 'id',
isColumnName: true
},
comparator: this.x_2ef.kerio_web_Eq,
secondOperand: {
operandValue: this.x_2df.id,
isColumnName: false
}
}],
start: 0,
limit: 1
}
};
var x_j4 = {
x_6p: 'post',
x_28: {
'object': 'TimeRangeManager',
'method': 'get',
params: kerio.lib.x_6r(x_28)
},
x_2e: this.x_2gb,
x_2q: this
};
kerio.lib.x_6t.x_6u(x_j4);
}, 
x_2gb: function(x_6v) {
if (x_6v.x_6x) {
var x_47 = x_6v.x_ac.ranges[0];
this.x_2df = x_47;
this.x_2g9(x_47); this.x_2g8 = x_47.enabled;
}
}, 
x_2g9: function(x_2gc) {
var x_2dw = this.x_2ef;
var x_2gd = Math.round(new Date().getTime() / 1000);
var x_47 = {
x_1f: x_2gc.type,
x_f8: x_2gc.description || '',
x_2fm: x_2gd,
x_2fn: x_2gd
};
var x_2ge = x_2gc.days;
switch (x_2gc.type) {
case x_2dw.kerio_web_TimeRangeDaily:
x_47.x_2ex = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Monday));
x_47.x_2ey = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Tuesday));
x_47.x_2ez = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Wednesday));
x_47.x_2f0 = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Thursday));
x_47.x_2f1 = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Friday));
x_47.x_2f2 = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Saturday));
x_47.x_2f3 = (-1 !== x_2ge.indexOf(x_2dw.kerio_web_Sunday));
var x_2gf = x_2ge.length;
var x_2g3 = (x_47.x_2f2 && x_47.x_2f3) && 2 == x_2gf; var x_2g2 = (!x_47.x_2f2 && !x_47.x_2f3) && 5 == x_2gf; var x_2gg = 7 == x_2gf; var x_2fe = 4; if (x_2g3) {
x_2fe = 3;
}
else if (x_2g2) {
x_2fe = 2;
}
else if (x_2gg) {
x_2fe = 1;
}
x_47.x_2fe = x_2fe;
x_47.x_2fg = this.x_2gh(x_2gc.fromTime);
x_47.x_2fh = this.x_2gh(x_2gc.toTime);
break;
case x_2dw.kerio_web_TimeRangeWeekly:
x_47.x_2fk = this.x_2gh(x_2gc.fromTime);
x_47.x_2fl = this.x_2gh(x_2gc.toTime);
x_47.x_2fi = x_2gc.fromDay;
x_47.x_2fj = x_2gc.toDay;
break;
case x_2dw.kerio_web_TimeRangeAbsolute:
x_47.x_2fm = this.x_2gi(x_2gc.fromDate);
x_47.x_2fn = this.x_2gi(x_2gc.toDate);
x_47.x_2fr = this.x_2gh(x_2gc.fromTime);
x_47.x_2fu = this.x_2gh(x_2gc.toTime);
break;
default:
break;
}
this.x_1c.x_2em(x_47);
var x_vw = {
id: x_2gc.groupId,
name: x_2gc.groupName
};
var x_1gv = {
id: x_2gc.childGroupId,
name: x_2gc.childGroupName
};
this.x_vx(x_vw, x_1gv);
}, 
x_mc: function() {
var
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_2dw = this.x_2ef,
x_1c = this.x_1c,
x_2gj = x_1c.x_7i(true); if (x_2gj.x_1f == x_2dw.kerio_web_TimeRangeDaily && !this.x_2gk()) {
kerio.lib.x_48(
x_x('Validation warning', 'ipAddressGroupEditor'),
x_x('It is required to select at least one Valid on day.', 'ipAddressGroupEditor')
);
return;
}
if (!this.x_2ff()) {
kerio.lib.x_48(
x_x('Invalid range', 'ipAddressGroupEditor'),
x_x('Specified times are not valid for range.', 'ipAddressGroupEditor')
);
return;
}
var x_5c = this.x_2dg;
var x_47 = {
type: x_2gj.x_1f,
description: x_2gj.x_f8
};
var x_vy = this.x_vz();
var x_vs = this.x_2d9;
x_47.groupId = x_vy[x_vs.x_1j];
x_47.groupName = x_vy[x_vs.x_a6];
switch (x_2gj.x_1f) {
case x_2dw.kerio_web_TimeRangeDaily:
x_47.days = [];
var x_2ew = this.x_2g6;
for (var x_41 in x_2ew) { if (x_2gj[x_41]) {
x_47.days.push(x_2dw[x_2ew[x_41]]);
}
} x_47.fromTime = this.x_2gl(x_2gj.x_2fg);
x_47.toTime = this.x_2gl(x_2gj.x_2fh);
break;
case x_2dw.kerio_web_TimeRangeWeekly:
x_47.fromDay = x_2gj.x_2fi;
x_47.toDay = x_2gj.x_2fj;
x_47.fromTime = this.x_2gl(x_2gj.x_2fk);
x_47.toTime = this.x_2gl(x_2gj.x_2fl);
break;
case x_2dw.kerio_web_TimeRangeAbsolute:
x_47.fromDate = this.x_2gm(x_2gj.x_2fm);
x_47.toDate = this.x_2gm(x_2gj.x_2fn);
x_47.fromTime = this.x_2gl(x_2gj.x_2fr);
x_47.toTime = this.x_2gl(x_2gj.x_2fu);
break;
default:
kerio.lib.x_nq('Internal error: Invalid time range type'
+' (value: '+x_2gj.x_1f+', type '+typeof(x_2gj.x_1f)+')',
'TimeRangeEditor', 'x_mc'
); break;
}
var x_1wu = (!this.x_2dg || this.x_2g8);
if (false === this.x_lh.x_2ep) {
x_1wu = (x_1wu) ? 1 : 0;
}
x_47.enabled = x_1wu;
var x_j4 = {
x_6p: 'post',
x_28: {
'object': 'TimeRangeManager'
},
x_2e: this.x_2gn,
x_2q: this
};
var x_28 = {};
var x_6p;
if (x_5c) {
x_28.rangeIds = [this.x_2df.id]; x_28.details = x_47;
x_6p = 'set';
}
else {
x_28.ranges = [x_47]; x_6p = 'create';
}
x_j4.x_28.method = x_6p;
x_j4.x_28.params = kerio.lib.x_6r(x_28);
kerio.lib.x_6t.x_6u(x_j4);
}, 
x_2gn: function(x_6v) {
if (x_6v.x_6x) {
if (this.x_lh.x_13) {
this.x_lh.x_13.call(this.x_5d);
}
this.x_5d.x_6y();
this.x_2r();
} }, 
x_2gh: function(x_1kf) {
var x_1kd = new Date('1/1/2007 ' + x_1kf.hour + ':' + x_1kf.min + ':00');
return x_1kd.format(this.x_2g7);
}, 
x_2gl: function(x_2go) {
var x_1kd = Date.parseDate(x_2go, 'G:i');
if (x_1kd) {
return {hour: x_1kd.format('H'), min: x_1kd.format('i')};
}
else {
return false;
}
}, 
x_2gm: function(x_2gp) {
var x_1kd = Date.parseDate(x_2gp, 'U');
return {'year': x_1kd.getFullYear(), 'month': x_1kd.getMonth(), 'day': x_1kd.getDate()};
},

x_2gi: function(x_1kd) {
return Date.parseDate(x_1kd.year + '-' + (x_1kd.month + 1) + '-' + x_1kd.day, 'Y-n-j').format('U');
},

x_2cl: function(x_1cy, x_2gq) {
this.x_2ff();
},

x_2gr: function(x_nr, x_1fd, x_2gs) {
var x_2gt = x_nr.x_2t().split(':');
var x_2gu = x_1fd.x_2t().split(':');
var x_2gv = parseInt(x_2gt[0], 10);
var x_2gw = parseInt(x_2gt[1], 10);
var x_2gx = parseInt(x_2gu[0], 10);
var x_2gy = parseInt(x_2gu[1], 10);
if (true === x_2gs) {
return (x_2gv !== x_2gx) || (x_2gv === x_2gx && x_2gw !== x_2gy);
}
else {
return (x_2gv  <  x_2gx) || (x_2gv === x_2gx && x_2gw  <  x_2gy);
}
},

x_2gk: function() {
var
x_2ew = this.x_2g6,
x_2gz = 0,
x_41;
for (x_41 in x_2ew) { if (this.x_1c.x_29(x_41).x_2t()) {
x_2gz++;
}
}
return (0 < x_2gz);
},

x_2ff: function() {
if (kerio.adm.x_28z('x_27c') === kerio.adm.x_1bc.x_29i) {
return;
}
var x_1c = this.x_1c;
var x_bg = true;
if (x_1c.x_29('x_bb').x_2fb()) {
var x_2fk = x_1c.x_29('x_2fk');
var x_2fl = x_1c.x_29('x_2fl');
var x_2h0 = false;
if (x_1c.x_29('x_2fi').x_2t() === x_1c.x_29('x_2fj').x_2t()) {
x_2h0 = this.x_2gr(x_2fk, x_2fl);
if (!x_2h0) {
x_bg = false;
}

x_2h0 = !x_2h0;
}
x_2fk.x_1g4(!x_2fk.x_o4() || x_2h0);
x_2fl.x_1g4(!x_2fl.x_o4() || x_2h0);
}
else if (x_1c.x_29('x_ba').x_2fb()) {
var x_2fg = x_1c.x_29('x_2fg');
var x_2fh = x_1c.x_29('x_2fh');
var x_2h1 = this.x_2gr(x_2fg, x_2fh, true); x_2fg.x_1g4(!x_2fg.x_o4() || !x_2h1);
x_2fh.x_1g4(!x_2fh.x_o4() || !x_2h1);
if (!x_2h1) {
x_bg = false;
}
}
else if (x_1c.x_29('x_2fd').x_2fb()) {
var x_2fr = x_1c.x_29('x_2fr');
var x_2fu = x_1c.x_29('x_2fu');
var x_2h2 = false;
if (x_1c.x_29('x_2fm').x_2t() === x_1c.x_29('x_2fn').x_2t()) {
x_2h2 = this.x_2gr(x_2fr, x_2fu);
if (!x_2h2) {
x_bg = false;
}
x_2h2 = !x_2h2;
}
x_2fr.x_1g4(!x_2fr.x_o4() || x_2h2);
x_2fu.x_1g4(!x_2fu.x_o4() || x_2h2);
}
return x_bg;
}, 
x_2g5: function(x_1c, x_g6) {
if (x_1c.x_2fx) {
return;
}
var x_2fe = x_1c.x_29('x_2fe');
var x_2fv = {};
var x_2gz = 0;
var x_2ew = x_1c.x_16.x_2g6;
for (var x_41 in x_2ew) { if (x_1c.x_29(x_41).x_2t()) {
x_2fv[x_2ew[x_41]] = 1;
x_2gz++;
}
}
var x_1f = 4;
if (7 == x_2gz) {
x_1f = 1; }
else {
if (undefined === x_2fv.kerio_web_Saturday &&
undefined === x_2fv.kerio_web_Sunday &&
5 == x_2gz) {x_1f = '2'; }
else {
if (1 == x_2fv.kerio_web_Saturday &&
1 == x_2fv.kerio_web_Sunday &&
2 == x_2gz) {x_1f = '3'; }
}
}
if (4 == x_1f) {
x_1c.x_2fw = x_2fv;
}
else {
x_1c.x_2fw = null;
}
x_2fe.x_9w(x_1f);
}, 
x_2fy: function (x_1c) {
var x_2ew = x_1c.x_16.x_2g6;
var x_2fv = x_1c.x_2fw;
for (var x_41 in x_2ew) {
if (x_2fv && x_2fv[x_2ew[x_41]]) {
x_1c.x_29(x_41).x_9w(true);
}
else {
x_1c.x_29(x_41).x_9w(false);
}
}
} });

kerio.adm.x_17 = kerio.adm.x_17 || {};

kerio.adm.x_17.x_3c = function(x_1j, x_2v){
var x_5p = x_2v.x_5p || false; var x_2h3 = kerio.adm.x_17;

if (undefined === x_2v.x_5v) {
x_2v.x_5v = {};
}
var x_5v = x_2v.x_5v;
var x_59; var x_5t, x_62;
if (x_5v.x_83) { x_59 = x_5v.x_83;
x_59.x_1f = x_59.x_1f || 'x_x5';
x_59.x_6h = x_2v.x_6h;
x_59.x_5p = x_2v.x_5p;
x_59.x_fe = x_2v.x_fe;
x_59.x_3l = this;
x_5v.x_83 = new x_2h3.x_es(x_1j + '_' + 'x_82', x_59);
x_62 = x_5v.x_83.x_2h4; x_5t = x_5v.x_83.x_5u; }
if ((x_5v.x_5w || !x_5v.x_83)) { x_59 = x_5v.x_5w || {}; x_59.x_1f = x_59.x_1f || 'x_x5';
x_59.x_6h = x_2v.x_6h;
x_59.x_5p = x_2v.x_5p;
x_59.x_fe = x_2v.x_fe;
x_59.x_3l = this;
if ('x_cr' == x_59.x_1f) {
delete x_5v.x_5w;
}
else {
x_5v.x_5w = new x_2h3.x_es(x_1j + '_' + 'x_2h5', x_59);
x_62 = x_62 || x_5v.x_5w.x_2h4; x_5t = x_5t || x_5v.x_5w.x_5u; }
}
if (x_5v.x_64) {
x_59 = x_5v.x_64;
switch (x_59.x_1f) {
case 'x_92':
x_59 = new x_2h3.x_90(x_1j + '_' + 'x_5n', x_59.x_2v);
break;
case 'x_9g':
x_59 = new x_2h3.x_9s(x_1j + '_' + 'x_2h6', x_59.x_2v);
break;
case 'x_43':
x_59 = new x_2h3.x_ap(x_1j + '_' + 'x_2h7', x_59.x_2v);
break;
case 'x_gr':	x_59 = x_59.x_2v; break;
default:
kerio.lib.x_nq('Internal error: Undefined type of top toolbar', 'basicList.js');
break;
} x_2v.x_5v.x_64 = x_59;
}
x_59 = null; 
x_2v.x_5t = x_2v.x_5t || x_5t;
x_2v.x_62 = x_2v.x_62 || x_62;
x_2h3.x_3c.superclass.constructor.call(this, x_1j, x_2v);
var x_6b = kerio.lib.x_6b;
var x_4k = x_6b.x_6d.x_6e;
var x_2h8 = {
x_2h9: x_4k,
x_2ha: x_6b.x_6d.x_6f
};
var x_2hb = {
x_32: x_5v.x_5w || x_5v.x_83,
x_2db: x_5p,
x_2hc: x_2h8,
x_2hd: kerio.adm.x_28z()
};
var x_65 = x_2v.x_65;
if (x_65) {
x_2hb.x_2he = x_65.x_2hf;
x_2hb.x_2hg = x_65.x_2hh;
x_2hb.x_2hi = x_65.x_66.object;
}
if (x_5v.x_64) {
x_2hb.x_2hj = x_5v.x_64;
}
this.x_2hb = x_2hb;
var x_6n = [x_4k.x_4l];
if (!x_5p) {	x_6n.push(x_4k.x_4p);
}
var x_6o = kerio.lib.x_6o;
if (x_5v.x_5w) {
x_6o(this, x_5v.x_5w, x_6n);
}
if (x_5v.x_83) {
x_6o(this, x_5v.x_83, x_6n);
}
x_5v = null;
x_2v = null;
x_6b = null;
}; 
kerio.lib.x_36(kerio.adm.x_17.x_3c, kerio.lib.x_4g,

{

x_2hk: function(x_2v) {
var x_a4 = null;
var x_ah = {};
if (this.x_2hl.x_2hm) {
x_ah = this.x_99(''); }
var x_2hj = this.x_2hb.x_2hj;
if (x_2hj && x_2hj.x_9a) {
x_2hj.x_9a.x_9w(''); if (x_2hj.x_2v.x_a4) {
x_a4 = x_2hj.x_2v.x_a4.x_1dw; }
}
this.x_2hb.x_2hn = x_a4;
if (x_a4) {
x_ah.domainId = x_a4.x_1j; }
if (x_2v) {
for (var x_1m7 in x_2v) {
x_ah[x_1m7] = x_2v[x_1m7];
}
}
if (x_2hj && x_2hj.x_9g) {
x_2hj.x_9g.x_8c = x_2v.domainId;
x_2hj.x_9g.x_2ho();
}
else {
this.x_6y(x_ah);
}
},

x_2hp: function(x_28) {
this.x_2hb.x_32.x_2hp(x_28);
},

x_99: function(x_97, x_98) {
var
x_9j,
x_ah = {},
x_2hq = [],
x_2hb = this.x_2hb,
x_2hr = x_2hb.x_2hd,
x_2hj = x_2hb.x_2hj,
x_92 = x_2hj ? x_2hj.x_2v.x_92 : undefined,
x_2hs = x_92 ? x_92.x_2hs : undefined,
x_41;
x_9j = {
'query': {
'fields': x_2hb.x_2hg
}
};
if (x_2hs !== undefined) {
x_2hs = 'string' == typeof x_2hs ? [x_2hs] : x_2hs;
for (x_41 = 0; x_41 < x_2hs.length; x_41++) {
x_2hq.push({
'firstOperand': {
'operandValue': x_2hs[x_41],
'isColumnName': true
},
'comparator': x_2hr.x_278,
'secondOperand': {
'operandValue': x_97,
'isColumnName': false
}
});
}
x_9j.query.conditions = x_2hq;
x_9j.query.combining = undefined !== x_92.x_2ht ? x_92.x_2ht : x_2hr.x_27a;
}
if (x_98) {
var x_2hu = {
'firstOperand': {
'operandValue': x_2hj.x_2v.x_2hv,
'isColumnName': true
},
'comparator': x_2hr.x_276,
'secondOperand': {
'operandValue': 1,
'isColumnName': false
}
};
x_ah.conditions.push(x_2hu);
}
if (undefined !== x_2hj && undefined !== x_2hj.x_2hw) {
x_9j.query.conditions = x_9j.query.conditions.concat(x_2hj.x_2hw);
}
return x_9j;
}}); 
kerio.adm.x_17.x_es = function(x_1j, x_2v){
var x_5p = x_2v.x_5p;
var x_2z;
var x_4f;
if ('function' === typeof(x_2v.x_fe)) {
this.x_2hx = this.x_2hy;
this.x_2hz = x_2v.x_fe;
}
var x_4u = x_2v;
if (x_4u) {
x_4f = x_4u.x_4c; }
else {
x_4u = {};
}
var x_2i0 = x_2v.x_1f ? x_2v.x_1f : 'x_1js';
x_4u.x_4v = x_2v.x_4v || ('x_gr' !== x_2i0);
var x_4c;
var x_3d;
var x_x = kerio.lib.x_x;
var x_2i1 = [];

if ('x_1js' === x_2i0 || 'x_2i2' === x_2i0) {
x_2i1 = [
'->',
{
x_1j: 'x_30',
x_23: x_x('Apply', 'list'),
x_31: true,
x_25: x_2v.x_33 || this.x_2i3,
x_2d8: kerio.lib.x_6b.x_107
},
{
x_1j: 'x_34',
x_23: x_x('Reset', 'list'),
x_31: true,
x_25: x_2v.x_35 || this.x_2i4
}
];
}
if ('x_gr' === x_2i0) {	x_2z = x_4u.x_1e;
x_4c = x_4u.x_4c;
}
else if ('x_1js' === x_2i0) {	x_2z = x_4u.x_1e || [];
x_2z = x_2z.concat(x_2i1);
x_4c = x_4u.x_4c;
}
else {	

x_3d = function(x_2q) {
var x_32 = x_2q.x_3m ? x_2q : this.x_2hb.x_32;	if (!x_32.x_2i5('x_4m')) {
x_32.x_1ny(x_32, true);
}
};
if (x_5p) {

x_4c = function(x_4d, x_4e){
if (x_4d instanceof kerio.lib.x_4g) {
this.x_3b('x_4h', (1 === x_4d.x_3v.x_46));
}
if (this.x_2i6) {
this.x_2i6.call(this, x_4d, x_4e);
}
}; } else {

x_4c = function(x_4d, x_4e) {
var x_4k = x_4d.x_2hb.x_2hc.x_2h9;
var x_32 = this;
if (x_4d instanceof kerio.lib.x_4g) {
switch (x_4e.x_1f) {
case x_4k.x_4l:
var x_46 = x_4d.x_3v.x_46;
var x_2i7 = x_46 === 1;
var x_2i8 = x_46 > 0;
this.x_3b('x_4m', x_2i7);
this.x_3b('x_4n', x_2i8);
break; case x_4k.x_4p:
var x_4i = x_4d.x_2hb.x_2hc.x_2ha;
var x_4j = x_4e.x_4q.keyCode;
if ((x_4i.x_4r === x_4j || x_4i.x_4s === x_4j))
{
x_32.x_2hx();
}
break; }
}
if (x_32.x_2i6) {
x_32.x_2i6.call(this, x_4d, x_4e);
}
};
} if (x_5p) {
x_2z = [
{x_1j: 'x_4h', x_23: x_x('View…', 'list'), x_31: true, x_25: x_3d}
];
}
else {
x_2z = [
{x_1j: 'x_56', x_23: x_x('Add…', 'list'),

x_25: function(x_32) {
x_32.x_1ny(x_32, false);
}
},
{x_1j: 'x_4m', x_23: x_x('Edit…', 'list'), x_31: true, x_25: x_3d},
{x_1j: 'x_4n', x_23: x_x('Remove', 'list'), x_31: true, x_25: this.x_2hx}
]; }
if ('x_x0' === x_2i0) {	x_2z = x_2z.concat(x_4u.x_1e);
}
if ('x_2i2' == x_2i0) {	x_2z = x_2z.concat(x_2i1);
}
}x_4u.x_1e = x_2z;
x_4u.x_4c = x_4c;
var x_2i9 = {	x_55: 'Add',
x_57: 'Edit',
x_54: 'View'
};
var x_2ia = {};
var x_6g = x_2v.x_6h;
if (x_6g) {
var x_5g = x_6g.x_5g;
var x_n = x_6g.x_n || {};
for (var x_2ib in x_2i9) {	if (!x_n[x_2ib]) {
x_n[x_2ib] = x_5g + x_2i9[x_2ib];
}
}
x_2ia = {
x_2ic: x_5g,
x_ha: x_n,
x_2id: x_6g.x_fc
};
}
kerio.adm.x_17.x_es.superclass.constructor.call(this, x_1j, x_4u);
this.x_27({
x_2ie: x_2ia,
x_33: x_2v.x_33,
x_35: x_2v.x_35,
x_2h4: x_3d,
x_3l: x_2v.x_3l	});
this.x_2if = x_2v.x_2ig || {};
if (x_4f) {	this.x_2i6 = x_4f;
}
x_4u = null;
};

kerio.lib.x_36(kerio.adm.x_17.x_es, kerio.lib.x_37,

{

x_2hp: function(x_28) {
this.x_2ie.x_2id = x_28;
},

x_2ih: function(x_28) {
var
x_41,
x_42;
x_28 = ('string' == typeof x_28) ? [x_28] : x_28;
for (x_41 = 0, x_42 = x_28.length; x_41 < x_42; x_41++) {
delete this.x_2ie.x_2id[x_28[x_41]];
}
},

x_2hx: function() {
this.x_3l.x_70();
},

x_2hy: function() {
this.x_2hz(this.x_3l, this.x_3l.x_3v.x_40);
},

x_2i3: function() {
this.x_2ii('apply');
},

x_2i4: function() {
this.x_2ii('reset');
},

x_2ii: function(x_6p) {
var x_2ig = this.x_2if;
var x_28 = x_2ig.x_28 || {};
var x_6q = x_2ig.x_6q || {};
this.x_2ij(x_6p, x_28, x_6q);
},

x_1ny: function(x_32, x_5c) {
var x_3l = x_32.x_3m;
var x_28 = {};
var x_2ia = x_32.x_2ie;
if (x_2ia.x_2id) {
x_28 = kerio.lib.x_9m(x_2ia.x_2id); }
x_28.x_5d = x_3l;
var x_2hb = x_3l.x_2hb;
if (x_2hb.x_2hn) {	x_28.x_a4 = x_2hb.x_2hn;
}
if (x_5c) {	var x_3v = x_3l.x_3v;
var x_b3 = x_3v.x_40[0];
x_28.x_3v = x_3v;
x_28.x_47 = x_b3.x_47;
x_28.x_fl = x_b3.x_fl;
}
var x_5g = x_2ia.x_2ic;
var x_n = x_2ia.x_ha;
var x_6k = x_2hb.x_2db ? x_n.x_54 : x_n.x_57;
var x_5f = {
x_5g: x_5g,
x_n:  (x_5c) ? x_6k : x_n.x_55,
x_28: x_28
};
kerio.lib.x_5l.x_5m(x_5f);
},
x_38: function(x_39, x_3a) {
this.x_3b('x_30', !x_39);
this.x_3b('x_34', !x_3a);
}, 
x_2ij: function(x_6p, x_28, x_6q) {
x_6q = x_6q || {};
var x_66 = {
x_28: {
object: this.x_3m.x_2hb.x_2hi,
method: x_6p,
params: kerio.lib.x_6r(x_28)
},
x_2s: x_6q.x_2s || undefined,
x_2e: x_6q.x_2e,
x_2q: x_6q.x_2q || this
};
kerio.lib.x_6t.x_6u(x_66);
} });

kerio.adm.x_17.x_90 = function(x_1j, x_2v) {
var x_2w = x_1j + '_';
var x_91 = {
x_23: x_2v.x_92.x_23,
x_1j: 'x_92',
x_1o: '',
x_1u: 200,
x_93: 128,

x_94: function(x_32, x_95, x_96) {
if (x_96.ENTER !== x_96.keyCode) {
return;
}
var x_97 = x_95.x_2t();
x_96.stopEvent();
x_32.x_3m.x_6y(x_32.x_3m.x_99(x_97));
}
};
var x_9a = new kerio.lib.x_9b(x_2w + 'x_9a', x_91);
var x_9c = {
x_1e: [
'->',    {x_1x: x_9a}
]
};
kerio.adm.x_17.x_90.superclass.constructor.call(this, x_1j, x_9c);
this.x_9a = x_9a;
this.x_2v = x_2v;
x_9a = null;
x_9c = null;
};
kerio.lib.x_36(kerio.adm.x_17.x_90, kerio.lib.x_37,

{

x_9f: function() {
return this.x_3m.x_2hb.x_2hn;
},

x_2ik: function(x_47) {
this.x_2hw = x_47;
}
});

kerio.adm.x_17.x_9s = function(x_1j, x_2v) {
var
x_2w = x_1j + '_',
x_2il = x_2v.x_a4;
kerio.adm.x_17.x_9s.superclass.constructor.call(this, x_1j, x_2v);

var x_9t = function(x_32, x_9u, x_1o) {
var x_98 = false;
if (x_32.x_1q) {
x_98 = x_32.x_1q.x_2t();
}
var x_3m = x_32.x_3m;
var x_9v = x_3m.x_99('', x_98);
x_9v.domainId = x_1o;
x_32.x_9a.x_9w('');
x_3m.x_2hb.x_2hn = {	x_1j: x_1o,
x_a6: x_9u.x_vj()
};
x_3m.x_6y(x_9v);
if (this.x_2im) {	this.x_2im.call(this, x_32, x_9u, x_1o);
}
};

var x_2in = function() {
var x_32 = this.x_32;
if (!this.x_8c) {
this.x_8c = this.x_2t();
}
this.x_2io.call(x_32, this.x_8c);
if (this.x_2ip) {
this.x_2ip.call(this);
}
};
var x_2iq = x_2il.x_65;
var x_66 = x_2iq.x_66 || {};
x_2v.x_23 = x_2il.x_23;
x_2v.x_1j = 'x_a4';
x_2v.x_9t = x_9t;
x_2v.x_2in = x_2in;
x_2v.x_a5 = 'name';
x_2v.x_a7 = 'id';
x_2v.x_a8 = true;
x_2v.x_65 = {
x_68: x_2iq.x_68 || 'domainList',
x_66: {
object: x_66.x_rw || 'DomainManager',
method: x_66.x_6p || 'get',
params: {
query: {
fields: x_66.x_1ni || ['id', 'name'],
start: 0,
limit: -1
}
}
}
};
var x_9g = new kerio.lib.x_a9(x_2w + 'x_9g', x_2v);
this.x_aa(x_9g, 0);
x_9g.x_27({
x_2ip: x_2iq.x_2e,
x_2io: this.x_2ir,
x_8c: x_2il.x_1dw.x_1j,
x_32: this
});
if (undefined !== x_2il.x_2is) {
x_9g.x_27({
x_2im: x_2il.x_2is
});
}
this.x_27({
x_9g: x_9g
});
x_2v = null;
x_9g = null;
};
kerio.lib.x_36(kerio.adm.x_17.x_9s, kerio.adm.x_17.x_90,

{

x_2ir: function(x_8c) {
var x_9g = this.x_9g;
var x_1dw = x_8c || this.x_2v.x_a4.x_1dw.x_1j;
if (x_9g.x_2t() !== x_1dw) {
if (!x_9g.x_ao(x_1dw)) {
x_9g.x_8c = null;	x_9g.x_2ho();
}
else {
x_9g.x_9w(x_1dw);
}
}
else {
var x_9v = this.x_3m.x_99();
x_9v.domainId = x_1dw;
this.x_3m.x_6y(x_9v);
}
this.x_3m.x_2hb.x_2hn = {	x_1j: x_1dw,
x_a6: x_9g.x_vj()
};
}
});
kerio.adm.x_17.x_ap = function(x_1j, x_2v){
var x_2w = x_1j + '_';
kerio.adm.x_17.x_ap.superclass.constructor.call(this, x_1j, x_2v);

var x_9t = function(x_32, x_1q, x_98) {
var x_3m = x_32.x_3m;
var x_9v = x_3m.x_99(x_32.x_9a.x_2t(), x_98);
x_9v.domainId = x_3m.x_2hn.x_1j;
x_3m.x_6y(x_9v);
};
var x_aq = {
x_1f: 'x_1q',
x_1l: true,
x_1s: kerio.lib.x_x('Hide disabled user accounts', 'userList'),
x_9t: x_9t
};
var x_1q = new kerio.lib.x_ar(x_2w + 'x_1q', x_aq);
x_1q.x_9d = this;
this.x_1q = x_1q;
this.x_aa(x_1q, 3);
x_aq = null;
};
kerio.lib.x_36(kerio.adm.x_17.x_ap, kerio.adm.x_17.x_9s,

{});

kerio.adm.x_17.x_2it = function(x_1j, x_2v) {
var
x_65 = x_2v.x_65,
x_2iu,
x_2hj;
x_2hj = this.x_2iv(x_1j);
x_2v.x_2iw = this.x_2ix;
x_2v.x_2iy = this.x_2iz;
x_2v.x_2j0 = false;
x_2v.x_5v = Ext.apply(x_2v.x_5v || {}, {x_64: x_2hj});
kerio.adm.x_17.x_2it.superclass.constructor.call(this, x_1j, x_2v);
this.x_2j1 = {
x_6a: x_65.x_6a,
x_68: x_65.x_68,
x_28: {},
x_2e: this.x_2j2,
x_2q: this,
x_zr: '',  x_zs: '',    x_ma : true      };
x_2iu = {
x_2j3: 200,
x_2j4: [{
x_1j: 'x_2j5',
x_2j6: this.x_2j7,
x_2q: this,
x_2j8: this.x_2j9
}]
};
this.x_27({
x_2ja: false,
x_2jb: new kerio.lib.x_2jc(x_2iu),
x_9a: x_2hj.x_29('x_9a')
});
x_2hj.x_27({
x_2jd: this
});
this.x_2je();
};
Ext.extend(kerio.adm.x_17.x_2it, kerio.lib.x_2jf,

{
x_67: false,
x_2jg: '<div class="singleRow">{line}</div>',
x_2j9: 2000,  
x_2j7: function() {
var
x_1b = kerio.lib,
x_o5 = this.x_2hl,
x_2jh = x_o5.x_2ji(),
x_j4 = this.x_2j1,
x_2jj = this.x_2jk.x_2jj,
x_2jl = this.x_2jk.x_2jl,
x_28;
x_j4.x_28 = x_2jh;
x_28 = {logName: x_2jh.logName};
x_28[x_2jj] = -1;
x_28[x_2jl] = x_2jh[x_2jl];
x_j4.x_28.params = kerio.lib.x_6r(x_28);
x_2jh[x_2jj] = -1;
x_o5.x_2jm(x_2jh);
x_1b.x_6t.x_6u(x_j4);
},

x_2j2: function(x_6v, x_6w) {
var
x_10q = this.x_2jk,
x_69 = x_10q.x_69,
x_68 = x_10q.x_68,
x_o5 = this.x_2hl,
x_ln = this.x_2jn(),
x_2jo = x_ln.x_2jp,
x_1ct,
x_2jp,
x_2jq,
x_40,
x_41,
x_42;
if (!x_6w || false === x_6v.x_ac.returnValue) {  return;
}
x_2jp = x_6v.x_ac[x_69];
if (x_2jp == x_2jo) {
return;
}

if (x_2jp < x_2jo) {
this.x_2bl(-1);
}
else {
this.x_1za.reader.jsonData = x_6v.x_ac;  x_40 = x_6v.x_ac[x_68];
if (x_40) {
x_42 = x_40.length;
x_2jq = x_42 - (x_2jp - x_2jo);
if (x_2jq < 0) {
x_2jq = 0;
}
for (x_41 = x_2jq; x_41 < x_42; x_41++) {
if (x_2jp > x_ln.x_1g5) {
this.x_1za.remove(this.x_1za.getAt(0));
}
x_o5.x_ih(x_40[x_41]);
}
this.x_2jr._kxp.x_hg.call(this.x_2jr);
}
this.x_2js(x_2jp, x_2jp - x_ln.x_1g5);
this.x_2jt();
}
},

x_2ix: function(x_2ju, x_ln) {
if (x_ln.x_2jv) {
this.x_2jb.x_1ct('x_2j5');
this.x_2ja = true;
}
else {
this.x_2jb.x_lg('x_2j5');
this.x_2ja = false;
}
},

x_2iz: function(x_2ju, x_ln) {
this.x_2jb.x_lg('x_2j5');
this.x_2ja = false;
},

x_2jw: function() {
this.x_2jb.x_2jx('x_2j5');
},

x_2jy: function() {
this.x_2jb.x_2jz('x_2j5');
},

x_2iv: function (x_1j) {
var x_x = kerio.lib.x_x,
x_1uq = 'x_2hj',
x_2k0,
x_9a,
x_32;
x_2k0 = {
x_1j: 'x_9a',
x_2k1: [
{
x_1j: 'x_2k2',
x_25: function (x_32, x_9a) {
x_32.x_2jd.x_2k3(x_9a, true);
},
x_1p: 'findNext',
x_1y: x_x('Find Next', 'logs'),
x_1m: true
},
{
x_1j: 'x_2k4',
x_25: function (x_32, x_9a) {
x_32.x_2jd.x_2k3(x_9a, false);
},
x_1p: 'findPrev',
x_1y: x_x('Find Prev', 'logs'),
x_1m: true
},
{
x_1j: 'x_2k5',
x_25: function (x_32, x_2k6) {
x_32.x_2jd.x_2k7();
},
x_1p: 'stopFind',
x_1y: x_x('Stop Search', 'logs'),
x_1m: true
}
],
x_94: function (x_32, x_9a, x_96) {
if (x_96.ESC == x_96.getKey()) {
if (x_9a.x_2k8()) {
x_96.stopEvent();
x_32.x_2jd.x_2k7();
}
else {
x_9a.x_9w('');
}
}
},
x_2k9: function (x_32, x_2k6, x_96) {
x_32.x_2jd.x_2ka.apply(x_32.x_2jd, arguments);
},
x_23: x_x('Find:', 'logs'),
x_1o: '',
x_1u: 200
};
x_9a = new kerio.lib.x_2kb(x_1j + '_' + x_1uq + '_' + 'x_9a', x_2k0);
x_32 = new kerio.lib.x_37(x_1j + '_' + x_1uq, {
x_1e: [
'->',
{x_1x: x_9a}
]
});
return x_32;
},

x_2kc: function(x_2s) {
var x_j4 = this.x_2kd;
x_j4.x_28.params = kerio.lib.x_6r({
countLines: this.x_2ke(),
searchId: this.x_2kf
});
x_j4.x_2s = {
x_2kg: x_2s.x_2kg
};
this.x_2kh = kerio.lib.x_6t.x_6u(x_j4);
},

x_2ki: function(x_dg, x_2s) {
var
x_3w = null,
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_2kg = x_2s.x_2kg,
x_9a = this.x_9a,
x_154 = this.x_154,
x_2kj = x_dg.firstLine;
switch (x_dg.status) {
case x_154.x_27p: this.x_9a.x_2kk(x_dg.percentage);
this.x_2kc(x_2s);
break;
case x_154.x_27r:
if (0 === this.x_2kl || -1 === this.x_2kl) {
this.x_2km();
}
else { if (true === this.x_2kn) {
if (-1 === x_2kg) {
x_3w = x_x('Text %1 not found. <br> Would you like to search from the beginning?', 'logs', {x_49: [this.x_2ko]});
}
else {
this.x_2km();
}
}
else {
if (0 === x_2kg) {
x_3w = x_x('Text %1 not found. <br> Would you like to search from the end?', 'logs', {x_49: [this.x_2ko]});
}
else {
this.x_2km();
}
}
if (null !== x_3w) {
this.x_2kp(x_3w);
}
}
x_9a.x_2kq(['x_2k2', 'x_2k4'], true);
x_9a.x_2kq('x_2k5', false);
x_9a.x_2kr();
break;
case x_154.x_27o:
this.x_2ks = true;
if (!this.x_2kt(x_2kj)) {
this.x_2ku(x_2kj, true);
var x_10q = this.x_2jk,
x_28 = {};
x_28[x_10q.x_2jl] = this.x_2ke();
x_28[x_10q.x_2jj] = x_2kj;
x_28[x_10q.x_69] = x_dg[x_10q.x_69];
this.x_2hl.x_ez(x_dg, {params: x_28});
this.x_2kv.call(this, this, this.x_2jn());
}
this.x_tz(x_2kj, false);
x_9a.x_2kq(['x_2k2', 'x_2k4'], true);
x_9a.x_2kq('x_2k5', false);
x_9a.x_2kr();
break;
default: }
},

x_2km: function () {
var
x_2kw,
x_1b = kerio.lib,
x_x = x_1b.x_x;
if (true !== this.x_2ks) { this.x_9a.x_se('notFound');
x_2kw = x_x('No occurrences of %1 were found.', 'logs', {x_49: [this.x_2ko]});
x_1b.x_48(x_x('Warning', 'common'), x_2kw);
}
this.x_2ko = null;
this.x_2kl = null;
this.x_2ks = false;
},

x_2kp: function (x_1n) {
var x_1b = kerio.lib;
x_1b.x_4b(x_1b.x_x('Confirm Action', 'common'), x_1n, this.x_2kx, this);
},

x_2kx: function (x_6v) {
if ('yes' === x_6v) {
this.x_2k3(this.x_9a, this.x_2kn, true);
}
},

x_2k3: function(x_9a, x_2ky, x_2kz){
var
x_2l0,
x_2l1 = x_9a.x_2t(),
x_j4 = this.x_2l2,
x_2l3 = this.x_2l4()[0],
x_ln = this.x_2jn(),
x_1ct = x_ln.x_1ct,
x_2kg = x_2ky ? -1 : 0;
this.x_2kn = x_2ky;
if (true !== x_2kz) {
if (undefined === x_2l3 || (undefined !== x_2l3 && !this.x_2kt(x_2l3))) {
x_2l0 = x_ln.x_2l5.x_2l6;
if (x_2ky) {
x_2l3 = (-1 == x_1ct) ? x_ln.x_2jp - x_2l0 - 1 : x_1ct;
if (x_2l3 < 0) {
x_2l3 = 0;
}
}
else {
x_2l3 = (-1 == x_1ct) ? x_1ct : x_1ct + x_2l0 - 1;
}
this.x_2ko = null;
}
if (x_2l1 != this.x_2ko) {
this.x_2kl = x_2l3;
this.x_2ko = x_2l1;
}
if (!x_2ky && x_2l3 > 0) {
x_2l3 -= 1;
}
if (x_2ky && x_2l3 < x_ln.x_2jp - 1) {
x_2l3 += 1;
}
}
else {
if (x_2ky) {
x_2l3 = 0;
x_2kg = this.x_2kl;
}
else {
x_2l3 = -1;
x_2kg = this.x_2kl;
}
}
x_9a.x_2kq(['x_2k2', 'x_2k4'], false);
x_9a.x_2kq('x_2k5', true);
x_9a.x_sd('notFound');
x_j4.x_28.params = kerio.lib.x_6r({
logName: this.x_1j,
what: x_2l1,
fromLine: x_2l3,
toLine: x_2kg
});
x_j4.x_2s = {
x_2kg: x_2kg
};
x_9a.x_2l7();
x_9a.x_2kk(2);
this.x_2kh = kerio.lib.x_6t.x_6u(x_j4);
},

x_2k7: function() {
var
x_j4 = this.x_2l8,
x_1b = kerio.lib;
x_1b.x_6t.x_qf(this.x_2kh);
this.x_2kh = null;
x_j4.x_28.params = kerio.lib.x_6r({
searchId: this.x_2kf
});
x_1b.x_6t.x_6u(x_j4);
},

x_2l9: function () {
var x_9a = this.x_9a;
x_9a.x_sd('notFound');
this.x_2ko = null;
this.x_2kl = null;
this.x_2ks = false;
if (x_9a.x_2la('x_2k5')) {
x_9a.x_2kq(['x_2k2', 'x_2k4'], true);
x_9a.x_2kq('x_2k5', false);
}
x_9a.x_2kr();
},

x_2ka: function (x_32, x_9a, x_96) {
var x_2jd = x_32.x_2jd;
x_9a.x_sd('notFound');
if (x_96.ENTER == x_96.getKey()) {
return;
}
x_2jd.x_2ks = false;
x_2jd.x_2ko = null;
x_2jd.x_2kl = null;
x_9a.x_2kq(['x_2k2', 'x_2k4'], '' !== x_9a.x_2t());
x_9a.x_2kq('x_2k5', false);
},

x_2je: function () {
var
x_2lb,
x_2lc,
x_2ld;
x_2lb = {
x_28: {
object: 'LogManager',
method: 'search'
},

x_2e: function(x_6v, x_6w, x_2s) {
if (x_6v.x_6x) {
this.x_2kf = x_6v.x_ac.searchId;	this.x_2kc(x_2s);	}
},
x_2q: this
};
x_2lc = {
x_28: {
object: 'LogManager',
method: 'getSearchProgress'
},

x_2e: function(x_6v, x_6w, x_2s) {
if (x_6v.x_6x) {
this.x_2ki(x_6v.x_ac, x_2s);
}
},
x_2q: this
};
x_2ld = {
x_28: {
object: 'LogManager',
method: 'cancelSearch'
},

x_2e: function(x_6v) {
if (x_6v.x_6x){
this.x_2l9();
}
},
x_2q: this
};
this.x_27({
x_2l2: x_2lb,
x_2kd: x_2lc,
x_2l8: x_2ld
});
}
});

kerio.adm.x_17.logs = {
x_m: function(x_n) {
var
x_2jd,
x_2le,
x_2lf,
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_2lg = kerio.adm.x_28z('x_27b'),
x_154 = kerio.adm.x_28z();
this.x_ga = x_n;
x_2lf = {
x_2lh: kerio.adm.x_1bc.x_29i,

x_25: function(x_1jp, x_1jq) {
var
x_1b = kerio.lib,
x_x = x_1b.x_x;
if ('clearLog' !== x_1jq.x_1j) {
x_1b.x_5l.x_5m({
x_5g: x_1jq.x_1j,
x_28: {
x_2ju: x_1jp.x_3m,
x_2li: x_1jp.x_3m.x_1j
}
});
}
else {
x_1b.x_4b(x_x('Clear Log', 'logs'),
x_x('The log data will be permanently deleted. Do you want to proceed?', 'logs'),

function (x_sm) {
if ('yes' == x_sm) {
var x_j4 = {
x_28: {
object: 'LogManager',
method: 'clear',
params: kerio.lib.x_6r({
logName: this.x_3m.x_1j
})
},
x_2q: this.x_3m,

x_2e: function (x_6v) {
if (x_6v.x_6x) {
this.x_2bl(-1);
}
}
};
kerio.lib.x_6t.x_6u(x_j4);
}
}, x_1jp);
}
},
x_1e: [
{x_1j: 'logExport'      , x_23: x_x('Save Log…', 'logs')    },
'-',
{x_1j: 'logHighlighting', x_23: x_x('Highlighting…', 'logs')},
{x_1j: 'logSettings'    , x_23: x_x('Log Settings…', 'logs')},
{x_1j: 'logMessages'    , x_23: x_x('Messages…', 'logs')    },
{                         x_23: '-'                          , x_2lj: [x_2lg]},
{x_1j: 'clearLog'       , x_23: x_x('Clear Log', 'logs')    , x_2lj: [x_2lg]}
]
};
if ('debug' != x_n) {
x_2lf.x_1e.splice(4,1);  }
x_2le = {
x_67: false,
x_2lk: 2048,
x_2jg: '<div class="singleRow background{highlight}">{content}</div>',
x_1z3: [
{x_7s: 'content'},
{x_7s: 'highlight'}
],
x_65: {
x_68: 'viewport',
x_69: 'totalItems',
x_2jj: 'fromLine',
x_2jl: 'countLines',
x_hh: false,
x_66: {
'object': 'LogManager',
'method': 'get',
logName : x_n
}
},
x_5t: x_2lf
};
x_2jd = new kerio.adm.x_17.x_2it(x_n, x_2le);
x_2jd.x_27({
x_154: x_154
});
x_2jd.x_2c = function(x_28) {
var x_ln = this.x_2jn();
if (this.x_2ll) {
if (Ext.isGecko) {
if (kerio.lib.x_2lm) {
this.x_2ln.dom.scrollTop = x_ln.x_2lo;
}
if (0 !== x_ln.x_2lp) {
this.x_2lq.x_2lr = true;
}
}
else if (Ext.isSafari) {
this.x_2ln.dom.scrollTop = x_ln.x_2lo;
if (x_ln.x_2lp) {
this.x_2lq.x_2ls = 0;
this.x_2lq.x_2lt(x_ln.x_2lp, true);
}
}
}
else {
this.x_2bl(-1);  }
};
x_2jd.x_2bi = x_2jd.x_2jy;
x_2jd.x_2be = x_2jd.x_2jw;
return x_2jd;
} };

kerio.adm.x_17.logHighlighting = {

x_m: function(x_n) {
var
x_2lu,
x_82,
x_2lv,
x_2lw,
x_2h5,
x_5o,
x_3l,
x_10,
x_16,
x_ft,
x_fu,
x_2lx,
x_fx,
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_ga = x_n + '_',
x_2ly = 'x_3l';
x_2lw = {
x_4v: true,
x_1e: [
{
x_1j: 'x_56',
x_23: x_x('Add', 'common'),

x_25: function(x_32) {
var x_16 = x_32.x_16;
x_16.x_2lz = x_16.x_3l.x_3v;
x_32.x_16.x_2m0(x_32.x_16.x_2m1.x_2d0);
}
},
{
x_1j: 'x_4n',
x_23: x_x('Remove', 'common'),
x_31: true,

x_25: function(x_32) {
x_32.x_3l.x_70();
}
},
{
x_1j: 'x_gw',
x_23: x_x('Duplicate', 'logHighlighting'),
x_31: true,

x_25: function(x_32) {
x_32.x_16.x_2m0(x_32.x_16.x_2m1.x_2m2);
}
},
{
x_1j: 'x_2m3',
x_23: x_x('Change Color', 'logHighlighting'),
x_2m4: true,
x_31: true,

x_2m5: function(x_32, x_1jq) {
var
x_b3,
x_41,
x_3l = x_32.x_3l,
x_3v = x_3l.x_3v,
x_42 = x_3v.x_46;
for (x_41 = 0; x_41 < x_42; x_41++) {
x_b3 = x_3v.x_40[x_41];
x_b3.x_47.color = x_1jq.x_1j;
x_3l.x_fm(x_b3.x_47, x_b3.x_fl);
}
}
}
],

x_4c : function(x_4d, x_4e) {
x_4d.x_16.x_2m6(x_4d, x_4e); }
}; x_2h5 = new x_1b.x_37(x_ga + x_2ly + '_' + 'x_2h5', x_2lw);
x_2lu = {
x_7v: true,
x_1jc: true,
x_1jd: 24,         x_1p: 'toolbarSprite', x_1e: [
{
x_1j: 'x_1je',
x_x6: '/weblib/int/lib/img/moveUp.png',
x_31: true,

x_25: function() {
this.x_3l.x_1jf(true);
}
},
{
x_1j: 'x_1jg',
x_x6: '/weblib/int/lib/img/moveDown.png',
x_31: true,

x_25: function() {
this.x_3l.x_1jf(false);
}
}
],

x_4c : function(x_4d, x_4e) {
x_4d.x_16.x_2m7(x_4d, x_4e); }
}; x_82 = new x_1b.x_37(x_ga + x_2ly + '_' + 'x_82', x_2lu);

x_2lv = function () {
return {
x_47: ''
};
};
x_ft = {
x_1f: 'x_1q',
x_7s: 'enabled'
};
x_fu = {
x_1f: 'x_gc',
x_93: 255,
x_ge: true
};
x_2lx = {
x_1f: 'x_gc',
x_93: 63,
x_ge: true,
x_b6: {
x_b7: false
}
};
x_fx = {
x_1f: 'x_1q',
x_7s: 'isRegex'
};
x_5o = {
x_5x: {
x_1e: [
{	x_7s: 'enabled', x_1m: true, x_gn: true},
{	x_7s: 'description', x_23: x_x('Description', 'logHighlighting'), x_1u: 210,
x_ed: x_fu
},
{	x_7s: 'condition', x_23: x_x('Condition', 'highlightRuleList') , x_1u: 190,
x_ed: x_2lx
},
{	x_7s: 'isRegex',  x_23: x_x('Regular Expression', 'logHighlighting'), x_1u: 40,
x_ed: x_fx, x_7u: x_2lv
},
{	x_7s: 'color', x_1m: true, x_gn: true},
{	x_7s: 'id', x_7t: true}
],
x_d2: false
},
x_5v: {
x_5w: x_2h5,
x_83: x_82
},
x_h2: true,
x_5t: x_2h5.x_5u,

x_h3: function(x_eo) {
return 'background' + x_eo.color;
},
x_65: {
x_66: {
'object': 'LogManager',
'method': 'getHighlightRules'
},
x_68: 'rules',
x_2m8: false,
x_hh: false
}
}; x_3l = new x_1b.x_4g(x_ga + x_2ly, x_5o);

x_10 = {
x_1v: 420,
x_1u: 600,
x_l1: 205,
x_l0: 500,
x_1y: x_x('Highlighting', 'logHighlighting'),
x_1x: x_3l,
x_1z: [{
x_1j: 'x_jh', x_20: true, x_23: x_x('OK', 'common'),

x_25: function(x_32){
x_32.x_16.x_2m9();
}
},
{x_23: x_x('Cancel', 'common'), x_21: true}
]
};
x_16 = new x_1b.x_26(x_n, x_10);
x_3l.x_27({
x_16: x_16
});
x_16.x_27({
x_3l: x_3l,
x_2m1: {
x_2d0: 0,
x_2m2: 1
}
});
x_2h5.x_27({
x_3l: x_3l,
x_16: x_16
});
x_82.x_27({
x_3l: x_3l
});
x_1b.x_6o(x_3l, x_2h5);
x_1b.x_6o(x_3l, x_82);
this.x_2a(x_16);
return x_16;
}, 
x_2a: function(x_2b){

x_2b.x_2c = function(){
this.x_3l.x_6y();
};

x_2b.x_2m6 = function(x_4d, x_4e){
if (!(x_4d instanceof kerio.lib.x_4g)) {
return;
}
var
x_46,
x_4i,
x_4j,
x_1jv,
x_1jw,
x_1ju = kerio.lib.x_6b.x_6d,
x_4k = x_1ju.x_6e,
x_32 = x_4d.x_5v.x_5w;
switch (x_4e.x_1f) {
case x_4k.x_4l:
x_46 = x_4d.x_3v.x_46;
x_1jv   = (1 === x_46);
x_1jw = (0 < x_46);
x_32.x_3b('x_4n', x_1jw);
x_32.x_3b('x_gw', x_1jv);
x_32.x_3b('x_2m3', x_1jw);
break;
case x_4k.x_4p:
x_4i = x_1ju.x_6f;
x_4j = x_4e.x_4q.keyCode;
if ((x_4i.x_4r === x_4j) || (x_4i.x_4s === x_4j)) {
x_4d.x_70();
}
break;
}
};

x_2b.x_2m7 = function(x_4d, x_4e){
var
x_32 = x_4d.x_5v.x_83,
x_1jl = x_4d.x_eq() - 1;
if (0 === x_4d.x_3v.x_46) {
x_32.x_lc(['x_1je', 'x_1jg']);
}
else {
x_32.x_3b('x_1je', !x_4d.x_1jn(0)); x_32.x_3b('x_1jg', !x_4d.x_1jn(x_1jl)); }
};

x_2b.x_2m0 = function(x_6p){
var
x_b3,
x_fk,
x_2ma,
x_3l = this.x_3l;
if (this.x_2m1.x_2d0 === x_6p) {
x_b3 = {
enabled: true,
description: '',
condition: kerio.lib.x_x('New Value', 'logHighlighting'),
isRegex: false,
color: 0	};
if (1 == this.x_2lz.x_46) {
x_fk = this.x_2lz.x_40[0].x_fl;
x_3l.x_ih(x_b3, x_fk, true);
x_3l.x_ik(x_fk, 'description'); }
else {
x_3l.x_ih(x_b3, 0, true);
x_3l.x_ik(0, 'description');
}
}
else {
x_b3 = x_3l.x_3v.x_40[0].x_47;
x_2ma = {
enabled: x_b3.enabled,
description: x_b3.description,
condition: x_b3.condition,
isRegex: x_b3.isRegex,
color: x_b3.color
};
x_3l.x_ih(x_2ma, 0, true);
x_3l.x_tz(0);
}
};

x_2b.x_2m9 = function(){
var
x_j4,
x_47 = this.x_3l.x_7i();
x_j4 = {
x_28: {
object: 'LogManager',
method: 'setHighlightRules',
params: kerio.lib.x_6r({rules: x_47})
},
x_2e: function(x_6v) {
if (x_6v.x_6x){
this.x_2r();
}
},
x_2q: this
};
kerio.lib.x_6t.x_6u(x_j4);
};

x_2b.x_jo = function(){
this.x_3l.x_8f();
};
}
};

kerio.adm.x_17.logExport = {

x_m: function(x_n) {
var
x_1d,
x_1c,
x_10,
x_16,
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_ga = x_n + '_';
x_1d = {
x_1e: [
{
x_1f: 'x_79',
x_23: x_x('Format', 'logExport'),
x_1e: [
{
x_1f: 'x_7a',
x_7b: 'formatGroup',
x_1j: 'plain',
x_1o: kerio.adm.x_28z('x_27h'),
x_1s: x_x('Plain text', 'logExport'),
x_1l: true,
x_7d: true
},
{
x_1f: 'x_7a',
x_7b: 'formatGroup',
x_1j: 'html',
x_1o: kerio.adm.x_28z('x_27i'),
x_1s: x_x('HTML', 'logExport'),
x_1l: true
}
]
},
{
x_1f: 'x_79',
x_23: x_x('Source', 'logExport'),
x_1e: [
{
x_1f: 'x_7a',
x_7b: 'sourceGroup',
x_1j: 'full',
x_1o: 0,
x_1s: x_x('Full file', 'logExport'),
x_1l: true,
x_7d: true
},
{
x_1f: 'x_7a',
x_7b: 'sourceGroup',
x_1j: 'selection',
x_1o: 1,
x_1s: x_x('Only selection', 'logExport'),
x_1l: true
}
]
}
]
};
x_1c = new kerio.lib.x_1t(x_ga + 'x_1c', x_1d);

x_10 = {
x_1v: 265,
x_1u: 240,
x_l1: 260,
x_l0: 220,
x_1y: x_x('Save Log', 'logExport'),
x_1x: x_1c,
x_1z: [
{
x_1j: 'x_jh', x_20: true, x_23: x_x('OK', 'common'),

x_25: function(x_32){
x_32.x_16.x_2mb();
}
},
{x_23: x_x('Cancel', 'common'), x_21: true}
]
};
x_16 = new x_1b.x_26(x_n, x_10);
x_16.x_27({
x_1c: x_1c,
x_2mc: x_1c.x_29('formatGroup'),
x_2md: x_1c.x_29('sourceGroup')
});
this.x_2a(x_16);
return x_16;
}, 
x_2a: function(x_2b){

x_2b.x_2c = function(x_28) {
var
x_g6,
x_2me = x_28.x_2ju.x_2l4(),
x_2mf = x_2me.length;
this.x_2li = x_28.x_2li;
if (0 < x_2mf) {
this.x_2mg = x_2me.shift();
this.x_2mf = x_2mf;
this.x_2md.x_yw(1, false);
this.x_2md.x_9w(1);
}
else {
this.x_2md.x_yw(1);
this.x_2md.x_9w(0);
}
this.x_2mh = Ext.DomHelper.append(document.body, {
id: 'x_2mi',
name: 'x_2mi',
tag: 'iframe',
frameBorder: 0,
width: 0,
height: 0,
css: 'display: none; visibility: hidden; height: 1px;'
}
);
};

x_2b.x_2mb = function() {
var
x_1c,
x_2mj,
x_a6,
x_2mk,
x_2ml = this.x_2ml,
x_2mm = kerio.lib.x_6t.x_2mn();
x_2ml = 1 === this.x_2md.x_2t();
x_1c = Ext.DomHelper.append(document.body, {
tag: 'form',
method: 'post',
style: 'display:none;',
action: x_2mm.x_6a
});
x_2mj = {
'object': 'LogManager',
'method': 'exportLog',
'token': kerio.lib.x_6t.x_2mo(),
'params': kerio.lib.x_6r({
logName: this.x_2li,
fromLine: (x_2ml ? this.x_2mg : 0),
countLines: (x_2ml ? this.x_2mf : -1),
type: this.x_2mc.x_2t()
})
};
for (x_a6 in x_2mj) {
x_2mk = Ext.DomHelper.append(x_1c, {tag: 'input', name: x_a6, type: 'hidden'});
x_2mk.value = x_2mj[x_a6]; }
x_1c.submit();
document.body.removeChild(x_1c);
delete x_1c;
this.x_2r();
};

x_2b.x_jo = function() {
this.x_1c.x_2h();
};
}
};

kerio.adm.x_17.logSettings = {

x_m: function(x_n) {
var
x_2mp,
x_2mq,
x_2mr,
x_2ms,
x_p4,
x_p5,
x_q3,
x_10,
x_16,
x_1z,
x_x = kerio.lib.x_x,
x_ga = x_n + '_',
x_154 = kerio.adm.x_28z(),
x_5p = x_154.x_27c === kerio.adm.x_1bc.x_29i,
x_2mt = x_154.x_27f,
x_2mu = x_154.x_27g;
x_2mp = {
x_br: 235,
x_5p: x_5p,
x_1e: [
{
x_1f: 'x_b3',
x_1e: [
{
x_1f: 'x_1q',
x_1j: 'isLoggingEnabled',
x_1o: 0,
x_1s: x_x('Enable logging to file: ', 'logSettings'),
x_1l: true,
x_1u: 150,

x_9t: function (x_1c, x_g6, x_7d) {
x_1c.x_84(['rotationFieldset', 'fileName'], !x_7d);
if (x_7d) {
x_1c.x_1d3('fileName');
}
}
},
{
x_1j: 'fileName',
x_1o: '',
x_1l: true,
x_31: true,
x_93: 255,
x_ge: true,
x_b6: {
x_b7: false
}
}
]
},
{
x_1f: 'x_79',
x_23: x_x('Rotation', 'logSettings'),
x_1j: 'rotationFieldset',
x_31: true,
x_1e: [
{
x_1f: 'x_1q',
x_1j: 'isRotationEnabled',
x_1l: true,
x_1s: x_x('Rotate regularly', 'logSettings'),

x_9t: function (x_1c, x_g6, x_7d) {
var x_2mv = x_1c.x_29('isOverSizeEnabled').x_7d();
x_1c.x_29('rotateItems').x_84(!x_7d);
x_1c.x_29('rotateCount').x_84(!(x_7d || x_2mv));
}
},
{
x_1f: 'x_1g',
x_1j: 'rotateItems',
x_b2: 1,
x_1l: true,
x_31: true,
x_1e: [
{
x_1f: 'x_7a',
x_7b: 'period',
x_1j: 'hour',
x_1o: x_154.x_27k,
x_1s: x_x('Every hour', 'logSettings')
},
{
x_1f: 'x_7a',
x_7b: 'period',
x_1j: 'day',
x_1o: x_154.x_27l,
x_1s: x_x('Every day', 'logSettings'),
x_7d: true
},
{
x_1f: 'x_7a',
x_7b: 'period',
x_1j: 'week',
x_1o: x_154.x_27m,
x_1s: x_x('Every week', 'logSettings')
},
{
x_1f: 'x_7a',
x_7b: 'period',
x_1j: 'month',
x_1o: x_154.x_27n,
x_1s: x_x('Every month', 'logSettings')
}
]
},
{
x_1f: 'x_b3',
x_1j: 'rotateFileSize',
x_1e: [
{
x_1f: 'x_1q',
x_1s: x_x('Rotate when file size exceeds (MB):', 'logSettings'),
x_1j: 'isOverSizeEnabled',
x_1l: true,
x_1u: 235,

x_9t: function (x_1c, x_g6, x_7d) {
var x_2mw = x_1c.x_29('isRotationEnabled').x_7d();
x_1c.x_84('maxLogSize', !x_7d);
x_1c.x_29('rotateCount').x_84(!(x_7d || x_2mw));
if (x_7d) {
x_1c.x_1d3('maxLogSize');
}
else {
x_1c.x_29('maxLogSize').x_9w(0);
}
}
},
{
x_1j: 'maxLogSize',
x_1f: 'x_b4',
x_1l: true,
x_93: 4,
x_1u: 45,
x_31: true,
x_b6: {
x_b7: false
}
}
]
},
{
x_1j: 'rotateCount',
x_1f: 'x_b4',
x_23: x_x('Number of rotated log files to keep:', 'logSettings'),
x_1o: '1000',
x_93: 6,
x_31: true,
x_1u: 45,
x_b6: {
x_b7: false
}
}
]
}
]
};
x_2mq = new kerio.lib.x_1t(x_ga + 'x_2mq', x_2mp);
x_2mr = {
x_5p: x_5p,
x_1e: [
{
x_1f: 'x_1q',
x_1j: 'isSyslogEnabled',
x_1l: true,
x_1s: x_x('Enable Syslog logging', 'logSettings'),

x_9t: function (x_1c, x_g6, x_7d) {
x_1c.x_29('syslogItems').x_84(!x_7d);
if (x_7d) {
x_1c.x_1d3('serverUrl');
}
}
},
{
x_1f: 'x_79',
x_23: x_x('Syslog service', 'logSettings'),
x_1j: 'syslogItems',
x_31: true,
x_1e: [
{
x_1j: 'serverUrl',
x_23: x_x('Syslog server', 'logSettings'),
x_93: 255,
x_ge: true,
x_b6: {
x_b7: false
}
},
{
x_1j: 'facility',
x_1f: 'x_1i',
x_23: x_x('Facility', 'logSettings'),
x_1o: ''
},
{
x_1j: 'severity',
x_1f: 'x_1i',
x_23: x_x('Severity', 'logSettings'),
x_1o: ''
}
]
}
]
};
x_2ms = new kerio.lib.x_1t(x_ga + 'x_2ms', x_2mr);
x_p4 = {
x_1e: [
{x_23: x_x('File Logging', 'logSettings'),x_1x: x_2mq},
{x_23: x_x('External Logging', 'logSettings'), x_1x: x_2ms}
]
};
x_p5 = new kerio.lib.x_py(x_ga + 'x_p5', x_p4);
x_q3 = new kerio.lib.x_q2(x_ga + 'x_q3',	[x_2mq, x_2ms]);
if (x_5p) {
x_1z = [{x_23: x_x('Close', 'common'), x_21: true}];
}
else {
x_1z =
[{
x_1j: 'x_jh', x_20: true, x_23: x_x('OK', 'common'), x_2d8: true,

x_25: function(x_32){
x_32.x_16.x_2m9();
}
},
{x_23: x_x('Cancel', 'common'), x_21: true}
];
}

x_10 = {
x_1v: 335,
x_1u: 345,
x_l1: 335,
x_l0: 345,
x_1y: x_x('Log Settings', 'logSettings'),
x_1x: x_p5,
x_1z: x_1z
};
x_16 = new kerio.lib.x_26(x_n, x_10);
x_16.x_27({
x_q3: x_q3,
x_p5: x_p5,
x_154: x_154,
x_2mt: x_2mt,
x_2mu: x_2mu
});
x_2mq.x_27({
x_16: x_16
});
this.x_2a(x_16);
return x_16;
}, 
x_2a: function(x_2b){

x_2b.x_2c = function(x_28){
var x_j4 = {
x_28: {
object: 'LogManager',
method: 'getSettings',
params: kerio.lib.x_6r({
logName: x_28.x_2li
})
},
x_2q: this,
x_2e: this.x_2mx
};
kerio.lib.x_6t.x_6u(x_j4);
this.x_2li = x_28.x_2li;
};

x_2b.x_2mx = function(x_6v) {
if (x_6v.x_6x) {
var
x_10q = x_6v.x_ac.currentSettings,
x_16u = x_10q.general,
x_2my = x_10q.rotation,
x_2mz = x_10q.syslog,
x_47 = {
isLoggingEnabled: x_16u.enabled,
fileName: x_16u.fileName,
isRotationEnabled: this.x_154.x_27j !== x_2my.period,
period: x_2my.period,
isOverSizeEnabled: 0 < x_2my.maxLogSize,
maxLogSize: 0 < x_2my.maxLogSize ? x_2my.maxLogSize : 0,
rotateCount: x_2my.rotateCount,
isSyslogEnabled: x_2mz.enabled,
serverUrl: x_2mz.serverUrl,
facility: this.x_2mu[x_2mz.facility],
severity: this.x_2mt[x_2mz.severity]
};
this.x_q3.x_7k(x_47);
}
};

x_2b.x_2m9 = function() {
var
x_j4,
x_47 = this.x_q3.x_7i(true),
x_10q = {
general: {
enabled: x_47.isLoggingEnabled,
fileName: x_47.fileName
},
rotation: {
period: x_47.isRotationEnabled ? x_47.period : this.x_154.x_27j,
maxLogSize: x_47.maxLogSize,
rotateCount: x_47.rotateCount
},
syslog: {
enabled: x_47.isSyslogEnabled,
serverUrl: x_47.serverUrl
}
};
x_j4 = {
x_28: {
object: 'LogManager',
method: 'setSettings',
params: kerio.lib.x_6r({
newSettings: x_10q,
logName: this.x_2li
})
},
x_2q: this,

x_2e: function (x_6v) {
if (x_6v.x_6x) {
this.x_2r();
}
}
};
kerio.lib.x_6t.x_6u(x_j4);
};

x_2b.x_jo = function() {
this.x_p5.x_lf(0);
this.x_q3.x_2h();
};
}
};

kerio.adm.x_17.logMessages = {

x_m: function(x_n) {
var
x_2n0,
x_5o,
x_3l,
x_10,
x_16,
x_1z,
x_1b = kerio.lib,
x_x = x_1b.x_x,
x_5p = kerio.adm.x_28z('x_27c') === kerio.adm.x_1bc.x_29i;
x_2n0 = {
x_1f: 'x_1q',
x_7s: 'enabled'
};
x_5o = {
x_5x: {
x_1e: [
{x_7s: 'description', x_ed: x_2n0},
{x_7s: 'parentName'},
{x_7s: 'enabled', x_7t: true},
{x_7s: 'id', x_7t: true}
],
x_nh: {
x_7s: 'parentName',
x_ni: true
},
x_cp: 'description'
},
x_5s: 'x_cr',
x_5p: x_5p,
x_1p: 'noGridHeader',
x_5r: true,
x_65: {
x_68: 'messages',
x_66: {
'object': 'LogManager',
'method': 'getMessages'
},
x_67: false,
x_hh: false
}
};
x_3l = new x_1b.x_4g(x_n + '_' + 'x_3l', x_5o);
if(x_5p) {
x_1z = [{x_23: x_x('Close', 'common'), x_21: true}];
}
else {
x_1z =
[{
x_1j: 'x_jh', x_20: true, x_23: x_x('OK', 'common'),

x_25: function(x_32){
var x_j4 = {
x_28: {
object: 'LogManager',
method: 'setMessages',
params: kerio.lib.x_6r({
messages: x_32.x_16.x_3l.x_7i()
})
},
x_2e: function(x_6v) {
if (x_6v.x_6x) {
this.x_2r();
}
},
x_2q: x_32.x_16
};
kerio.lib.x_6t.x_6u(x_j4);
}
},
{x_23: x_x('Cancel', 'common'), x_21: true}
];
}

x_10 = {
x_1v: 450,
x_1u: 350,
x_l1: 265,
x_l0: 300,
x_1y: x_x('Logging Messages', 'logMessages'),
x_1x: x_3l,
x_1z: x_1z
};
x_16 = new x_1b.x_26(x_n, x_10);
x_16.x_27({
x_3l: x_3l
});

x_16.x_2c = function(){
this.x_3l.x_6y();
};
return x_16;
}
};
